AGS v2.7 Final: Yet Another Edition

Started by Pumaman, Sat 13/11/2004 21:02:00

Previous topic - Next topic

Pumaman

Quote from: RickJ on Wed 23/02/2005 17:02:18
I just noticed that GUI control script names aren't allowed to contain digits 0..9. I can undestand not wanting a name to begin with a numeral but why not allow them in subsequent character positions. For example it's not possible to use button1, button2, button3, etc for script names. There are a few cases where it makes sense to have names of this form. I was wondeing if this were an oversight or if there were some other motivation to make this restriction.

Yeah this has been commented on before, it's basically because I've been too lazy to add a text box validator that allows numbers only after the first character.

QuoteA user in the Beginner's Forum made the suggestion to rename the help file to agshelp.chm to make clear it is the help file and not program-related data.

I guess that can't do any harm -- but since you'd normally open the help file from within AGS, I'm not sure why you really need to access it directly.

strazer

QuoteI guess that can't do any harm -- but since you'd normally open the help file from within AGS, I'm not sure why you really need to access it directly.

- Accessing it without the editor running
- ALT-Tabbing between it and the editor
- Opening it in Linux :)

TheMagician

Hi everybody.

Here are a few things which I encountered during my testing of the newest beta of AGS.

====

The following code in the repeatedly execute should move a character (not standing on a walkable area) from one spot to another and then back to the original spot.

if (character[AMB].x == 300) {
Ã,  MoveCharacterDirect(AMB,100,220);
Ã,  }
else if (character[AMB].x == 100) {
Ã,  MoveCharacterDirect(AMB, 300, 220);
}

The character starts at 300,220. It does the very first move to 100,220Ã,  as it should. However it get's stuck when it reaches the point. It does not move back again.

====

Why are all my characters walking so slowly? I use the same speed-value as in the previous versions but it looks like slow-motion. Am I the only one with this problem?

====

What evil hardware combination causes the "Test-Game" Feature not to work anymore? If I accidently push "Test-Game" (which I do very often because I am so used to it) not only the game but my whole computer freezes ...

====

I think I mentioned something like this a year ago, however I coudn't find it on the Bug Tracker, so ... what about SetChannelVolume for channel 1 ... it just changes the volume of the abient sound for a split second but it doesn't last.
Is this on the to-do list?

====

When trying to compile an old game (version 2.62) to the newest beta I always get an error in the global script. It says something like

"Error in line 35: 'Object' is a global variable. You can't use it in rooms"

If I look in my global script line 35 ... it's a blank line (between two of these "Section start/end ... do not remove" lines)Ã,  ... and I definitly have no global variable called "Object" in my entire script.

====

The "Character solid" checkbox doesn't seem to work for me. I can walk right through the other character as if it were thin airÃ,  ;)

====

I hope I didn't sound too harsh.
I am looking forward to your ideas.

Stefan

Pumaman

Quote from: TheMagician on Thu 24/02/2005 14:52:36
The character starts at 300,220. It does the very first move to 100,220  as it should. However it get's stuck when it reaches the point. It does not move back again.

Did this work in 2.62 -- ie. is it related to the beta?

Basically, you have no guarantee that the character will end on the exact co-ordinate you asked it to move to -- it might actually end on X=99 or 101 instead. A better method is to check cAmb.Moving to determine when the character has finished walking.

QuoteWhy are all my characters walking so slowly? I use the same speed-value as in the previous versions but it looks like slow-motion. Am I the only one with this problem?

Character speed hasn't changed in the new version; are you sure you haven't changed the "Anti glide mode" setting?

QuoteWhat evil hardware combination causes the "Test-Game" Feature not to work anymore? If I accidently push "Test-Game" (which I do very often because I am so used to it) not only the game but my whole computer freezes ...

The Test Game feature works for some people but doesn't for others -- this is a long-standing issue and we haven't yet been able to work out what the problem is, unfortunately.

QuoteI think I mentioned something like this a year ago, however I coudn't find it on the Bug Tracker, so ... what about SetChannelVolume for channel 1 ... it just changes the volume of the abient sound for a split second but it doesn't last.
Is this on the to-do list?

Well spotted, I don't believe this is currently on the bug list. I'll get it fixed.

QuoteWhen trying to compile an old game (version 2.62) to the newest beta I always get an error in the global script. It says something like
"Error in line 35: 'Object' is a global variable. You can't use it in rooms"

This is because "object" is now a reserved keyword, so if you have any variables called "object" in your script you need to rename them.

Quote
The "Character solid" checkbox doesn't seem to work for me. I can walk right through the other character as if it were thin air  ;)

Both characters must be solid to block each other -- if either character is not solid, they can pass through each other. This behaviour has not changed since 2.62.

TheMagician

#484
Thanks for your reply CJ!

QuoteThe character starts at 300,220. It does the very first move to 100,220  as it should. However it get's stuck when it reaches the point. It does not move back again.

Did this work in 2.62 -- ie. is it related to the beta?

Basically, you have no guarantee that the character will end on the exact co-ordinate you asked it to move to -- it might actually end on X=99 or 101 instead. A better method is to check cAmb.Moving to determine when the character has finished walking.

Ok, I must admit it didn't work in 2.62 as well.  However, I made a string which showed me the current x position of the character on the screen ... it was 100, not 99 or 101 .... however ... I'll use the way you suggested with cAmb.Moving.
Actually I am only going through this trouble with a character moving from one point to another back and forth to program a non-blocking Wait command .... you now an invisible character walks from left to right and back and then something is triggered.
... perhaps there is a much better way of doing this which I don't know?



Edit by strazer:

I was able to help him with this by suggesting to use timers:

Interaction:
Code: ags

  SetTimer(1, 400);


rep_ex:
Code: ags

  if (IsTimerExpired(1) == true) {
    // do stuff
  }




QuoteCharacter speed hasn't changed in the new version; are you sure you haven't changed the "Anti glide mode" setting?

Grrrrrr ...  :P  sorry, i didn't check that ... of couse I had the wrong setting.

Quote
This is because "object" is now a reserved keyword, so if you have any variables called "object" in your script you need to rename them.

Ah ... good to know. Are there any more keywords which I should know of?  Are they mentioned in the manual?

QuoteBoth characters must be solid to block each other -- if either character is not solid, they can pass through each other. This behaviour has not changed since 2.62.

That's odd. It used to work for me in previous versions but it doesn't in the beta. I checked both characters ... they are solid. I can upload the file tomorrow so you can have a look at it.

EDIT:

I uploaded the room here.

SSH

I found a couple of things:

After doing automatic numbering, then dumping dialog scripts, global scripts, etc. and reimporting, the numbering on my first dialog topic's options disappeared. i.e. my five options were numbere &1 to &5 but the &n all disappeared, but just on the options on the first dialog.

Also, it would be nice if leading 0s in sound/voice/room names were not significant: i.e. sound001.ogg would get picked up as sound 1. Obviously there would need to be a priority in case both existed, but I don't care which way around it is.

12

strazer

Quote from: SSH on Fri 25/02/2005 08:58:49
Also, it would be nice if leading 0s in sound/voice/room names were not significant: i.e. sound001.ogg would get picked up as sound 1. Obviously there would need to be a priority in case both existed, but I don't care which way around it is.

http://www.adventuregamestudio.co.uk/tracker.php?action=detail&id=139

Pumaman

Quote from: TheMagician on Thu 24/02/2005 20:57:45
Ok, I must admit it didn't work in 2.62 as well.  However, I made a string which showed me the current x position of the character on the screen ... it was 100, not 99 or 101

In that case, the problem is probably because you are calling MoveCharacter every game loop if X=100, and because he might not move a pixel on the first frame of the move, it will keep resetting the move and get nowhere. You can use the debug console to check if this is happening.

QuoteActually I am only going through this trouble with a character moving from one point to another back and forth to program a non-blocking Wait command .... you now an invisible character walks from left to right and back and then something is triggered.

An easier approach might just be to do this:

  if (!cAmb.Moving) {
    cAmb.Walk(100, 220, eNoBlock, eAnywhere);
    cAmb.AddWaypoint(300, 220);
  }

that will set it up to walk between the two points continuously.

Quote
Ah ... good to know. Are there any more keywords which I should know of?  Are they mentioned in the manual?

Yes, they are listed in the Upgrading to 2.7 section:
http://www.adventuregamestudio.co.uk/manual/UpgradingTo27.htm

QuoteThat's odd. It used to work for me in previous versions but it doesn't in the beta. I checked both characters ... they are solid. I can upload the file tomorrow so you can have a look at it.

You're quite right, a bug was introduced in beta 6 which stopped solid characters from blocking properly. I'm surprised it's taken this long to be spotted -- but well done for doing so! I'll get it fixed.

QuoteAfter doing automatic numbering, then dumping dialog scripts, global scripts, etc. and reimporting, the numbering on my first dialog topic's options disappeared. i.e. my five options were numbere &1 to &5 but the &n all disappeared, but just on the options on the first dialog.

That's odd -- I just tried it myself but I couldn't replicate the problem. Rather strange one.

strazer

#488
Would it be possible for the autocomplete feature to display custom enums according to the order they were written in the enum definition instead of alphabetically?
I like to group them according to what is used most often.

Edit:

Also, it would be nice if we could do this with global/room variables:

enum_doorstatus door1status = eDoorClosed;

instead of having to provide a number.

Edit 2:

The manual entry for Character.Walk still refers to the character[charid].walking variable.
And for the example, it says the script would not continue until the character has reached his destination. Isn't the default eNoBlock now?

Pumaman

QuoteWould it be possible for the autocomplete feature to display custom enums according to the order they were written in the enum definition instead of alphabetically?
I like to group them according to what is used most often.

Unfortunately I don't think this is possible. The scintilla text editor control that AGS uses requires that the autocomplete list is in alphabetical order.

QuoteAlso, it would be nice if we could do this with global/room variables:

enum_doorstatus door1status = eDoorClosed;

Oops good point, I'll fix that.

QuoteThe manual entry for Character.Walk still refers to the character[charid].walking variable.
And for the example, it says the script would not continue until the character has reached his destination. Isn't the default eNoBlock now?

Well spotted, thanks, I'll fix it.

Pumaman

Ok, RC1 is up -- this fixes a few minor things, and brings the plugin API up to date by adding functions to allow plugins to create objects for the script.

strazer

Quote
* Enum variables can now be initialized using the enum options.

Hm, I have this in a script module header:

Code: ags

enum enum_doorstatus {
	eDoorOpen, 
	eDoorClosed, 
	eDoorLocked
};


and this on top of room 1:

Code: ags
enum_doorstatus door1status = eDoorClosed;


It says:

Quote
'Room 1' script
Error (line3): Expected ',' or ';', not 'eDoorClosed'

Pumaman

ah, hmm, you're right; well spotted, it doesn't work with global variables. I'll fix that -- it currently only works with local variables declared inside a function.

edmundito

Thanks, Chris, for the pages on how to get back up to speed with all these new and improved changes.... now I'm not that afraid to start with 2.7 without getting lost and crying like a little girl.
The Tween Module now supports AGS 3.6.0!

Sektor 13

tell me, is this version safe now?? To start work in it, as at the begining was written that better not rush with new beta  ;D

Pumaman

It's not guaranteed to be "safe" until the Final version is released.

However, now that it has reached the RC stage it is recognised to be more stable than a beta -- but even so, use it at your own risk.

TheMagician

#496
My problem with compiling my game to the newest version of AGS still exists.

The error message reads:

"In 'Plugin definitions' Error (line 35) 'object' is a global var; cannot use as name for local"

I checked every single room script, the global script and the script headers ... there are NO variables called 'object'.
There are also no characters, objects, GUIs, views or anything called 'object'

Another stange thing is that the error occurs in EVERY room of the game if I try to save it in the new version. It always says "Error (line 35)" even if there IS NO line 35 in that room script because it's only 10 lines long.

-- by the way: now that AGS has this big version change ... isn't there a possibility to include at least two ambient sound channels? It would enhance gameplay so much!! --

SSH

Which plugins do you have installed? Try removing them and see if it works.
12

Pumaman

Yeah, it looks like one of your plugins isn't compatible with 2.7 -- try un-selecting each plugin one by one until you find the culprit, then request that the plugin author updates their plugin.

RickJ

Quote
Script names can now contain the digit 0-9 after the first character.
Was this intended to include GUI buttons as well?  Still can't use "gMenu0..gMenu9" for a GUI button script names.

SMF spam blocked by CleanTalk