A whole bunch of Suggestions

Started by SSH, Tue 08/06/2004 20:28:52

Previous topic - Next topic

SSH

Firstly,

Extra interactions for characters (or alternately, on_event calls or somesuch):

Before Speaking and
After Speaking

this would make it easy to run a little animation, etc. before (or after) a character spoke. FOr example, if you're talking to a wheezy old man, he might (randomly) have a coughing fit or spit before he speaks. Obviously, you can do this in scripting OK, but not during dialogs, without lots of run-scripts...

Secondly:

on_event global function to be called separately for Enter_Room_Before_Fadein and Enter_Room_After_FadeIn. Currently, it only gets called once, and I'm not entirely sure if it is before or after fadein.


Next, to make the old Unhandled Event stuff a bit more sophisticated, how about a function like:

int GetHotspotHeight(int hotsspotnum)... returns the height in pixels of the hotspot. That way, your unhandled event can give a different message depending on how big the hotspot is. Ditto for objects, characters, etc.

12

Ishmael

Good suggestions, I'd find atleast the first one useful rather often, I imagine.
I used to make games but then I took an IRC in the knee.

<Calin> Ishmael looks awesome all the time
\( Ö)/ ¬(Ö ) | Ja minähän en keskellä kirkasta päivää lähden minnekään juoksentelemaan ilman housuja.

Pumaman

1. Yeah, some sort of Pre-speech and Post-speech script would be handy. The problem is that due to the blocking nature of the script system, the script wouldn't normally get a chance to run since the main script would already be blocked on DisplaySpeech. I guess it could be implemented similarly to rep_exec_always though.

2. Sounds like a good iea, I'll add it to my list.

3. This would be possible to add, but I'm not sure how many people would really find it useful?

Rui 'Trovatore' Pires

CJ, about 3, if you consider the example of trying to move a non-moveable object and having the game return "It's too big to move!" or "It's too small, I can't get a grip!" (lame example, but serviceable), it might seem a bit more... useable.

All the same, however, I do agree that it's a very limited advantage.
Reach for the moon. Even if you miss, you'll land among the stars.

Kneel. Now.

Never throw chicken at a Leprechaun.

MrColossal

maybe i'm missing the point of 3 but couldn't this be easily done by checking the mouse x and y coordinates before displaying a message from the hotspot?

or do you just want it done with a function CJ built himself?

or am i missing the point?
"This must be a good time to live in, since Eric bothers to stay here at all"-CJ also: ACHTUNG FRANZ!

Phemar


While we're on the subject of suggestions:

1. Move Sprite to Folder when right-clicking on a sprite. The sprites number of course stays the same...

2. [] Compile minimum checkbox. The editor for alll things not being used and cuts them out the compiled game. This could reduce file size.
For example, if the editor sees the text-parser is not being, there are no added words aside from the defaults, no text-input things on any GUI, it will cut that functionality out of the compiled game. Same with sprites. It can check all scripts, views, objects etc...and cut that out...

Radiant

#6
MrColossal -> I believe the point was that he was trying to determine the height of a hotspot. This can feasibly be coded using GetHotspotAt () and iterating over a bunch of Y values until you find it, though.

Zoro(c) -> You could manually delete all sprites (and words) you aren't using. That's what I do. For a decent game the AGS runtime is a lot smaller than the compiled graphics folders. Maybe an option 'move all unused sprites to folder X' would be useful, though.

SSH -> on_event (enter_room) is actually before the fade in. I would find another event for after the fadein very useful, actually.

Scorpiorus

Yeah, with the GetHotspotAt() you can write a script function like:

function GetHotspotHeight(int hotspotNum) {

   int y1 = 0;
   int y2 = game.room_height-1;

   int bFoundY1 = 0;
   int bFoundY2 = 0;

   int vx = GetViewportX();
   int vy = GetViewportY();

   while (y2 >= y1) {

      int x=0
      while (x < game.room_width) {

         if (bFoundY1==0) if (GetHotspotAt(x-vx, y1-vy)==hotspotNum) bFoundY1 = 1;
         if (bFoundY2==0) if (GetHotspotAt(x-vx, y2-vy)==hotspotNum) bFoundY2 = 1;

         if ((bFoundY1) && (bFoundY2)) return (y2-y1)+1;

         x++;
      }
      if (bFoundY1==0) y1++;
      if (bFoundY2==0) y2--;
   }

   return 0;
}


I would too find it very useful to have the after fade-in event in the on_event function.


The problem with automatic removing of sprites is that it's not reliable as we can refer to sprites within the text scripts.

MrColossal

It seems to me the point was he was trying to determine the placement of a mouse click on a hotspot because he mentions unhandled event.

And how would it work if you had 2 blobs of different heights and different placement on the screen but were the same hotspot number?
"This must be a good time to live in, since Eric bothers to stay here at all"-CJ also: ACHTUNG FRANZ!

Gilbert

Quote from: Zor© Ver. 2.3 on Thu 10/06/2004 14:31:25
2. [] Compile minimum checkbox. The editor for alll things not being used and cuts them out the compiled game. This could reduce file size.

Well it isn't that easy to implement I think, as teh AGS engine files are not currently destributed as separated modules, but single executable files, so it's not possible to remove some of the features of the engine under current condition (as when you "compile" a game in AGSEdit, what it actually does is just pack all the game resources with the engine executable). Furthermore, it'll require some real smart detection routine for the editor to decide what is redundent, and what is not, which would be quite difficult.
The same goes for sprites, views, etc., and it's even more difficult to check their usage (especially when they may be used in a script, they you may not be aware of). So I don't think this is a good idea.

strazer

QuoteMaybe an option 'move all unused sprites to folder X' would be useful, though.

That's a nice idea.
This way all potentially unused sprites are in one place and it would be up to the user to decide which ones can safely be deleted.

GarageGothic

I think the whole HotspotHeight suggestion is weird. Haven't you heard about perspective? What if you try to pick up a tree off in the distance: "I can't get a grip, it's too small"?

Why don't you rather just set custom hotspot properties (IsTooSmall, IsTooBig, IsTooSlippery etc.) for all hotspots you don't want to write proper interactions for, and then check for those when displaying the message?

Gilbert

* Gilbot V7000a seconds GG.

And it's more flexible. Of course it can be annoying setting the properties one by one, but I think there aren't many practical use for obtaining the hotspot height in general currently.

jetxl

Quote from: SSH on Tue 08/06/2004 20:28:52
Extra interactions for characters (or alternately, on_event calls or somesuch):

Before Speaking and
After Speaking

this would make it easy to run a little animation, etc. before (or after) a character spoke. FOr example, if you're talking to a wheezy old man, he might (randomly) have a coughing fit or spit before he speaks. Obviously, you can do this in scripting OK, but not during dialogs, without lots of run-scripts...

The dialog script is a bit simple. I preform a run-scrip with every dialog option you can choose. You have more freedom in global script (character walks and talk at the same time, etc). Maybe dialog script should be just as advanced as global/local script.

Scorpiorus

Quote from: MrColossal on Fri 11/06/2004 01:15:35
It seems to me the point was he was trying to determine the placement of a mouse click on a hotspot because he mentions unhandled event.
To be honest, I'm not sure how exactly SSH want the GetHotspotHeight() function to be utilized with the unhandled event but it won't obviously tell anything about the location of the mouse cursor over that hotspot.

QuoteAnd how would it work if you had 2 blobs of different heights and different placement on the screen but were the same hotspot number?
It just finds the minimum and the maximum within the range of Y-values and then substracts to obtain the height. And that's the only implementation reasonable since the parameter is a hotspot number.
But maybe, yes, what he was refering to is a GetHotspotBlobHeight(int x, int y) function with x,y being passed as parameters (not hotspotNum). I see it could be possible to implement (with scripting) as well but would suffer a performace loss because of running of a heavy time critical pathfinder-like routine.

SSH

I meant to say "It's too heavy" for big objects taht were unhandled and "It's too small" for small objects... so GG's suggestion solves the problem and would be better. You could even have a string property just called "Too" which is the advjective

But 1 and 2 (especially the after fadein event) still stand as requests.
12

Munk

I know this is a bit off topic but what if A.G.S. added .it (ImpulseTracker v2.14) support for music as well as the ones already supported (.mid, .xm, .mod, .ogg, .s3m and .mp3) for music?Ã,  I have found a few .it music files which i would like to add to my game.

Thanks :)

Pumaman

I presume it should be fairly easy to convert a .it file to one of the other tracker formats - they're all pretty similar.

Kennedym

Perhaps there should be a thread just for suggestions people want to see most in the next editor. The thing I want most is probably giving rooms there own inventory like characters, so players can drop things in them and pick them up later.


SMF spam blocked by CleanTalk