Mittens 2018 will be in Boston this September. There are three spaces left, so check out the thread for details!

Author Topic: AGS 3.4.0  (Read 17480 times)

Crimson Wizard

  • Local Moderator
  • AGS Project Tracker Admins
    • Best Innovation Award Winner 2013, for spearheading the AGS 3.3.0 project
    •  
    • Lifetime Achievement Award Winner
    •  
    • Crimson Wizard worked on a game that was nominated for an AGS Award!
      Crimson Wizard worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #40 on: 10 Oct 2016, 16:24 »
I noticed too that Direct3D renderer does not show all the resolutions my monitor supports, but DirectDraw5 does.

I can create a 1280x720 game, and set it to run at 'game resolution'. This runs 1280x720 successfully, however when I run setup again, it defaults back to 'desktop resolution'.
Are you sure it runs at 1280x720? Engine tries other resolutions silently if the one you requested does not work. Try pressing Ctrl+V (or Ctrl+Alt+V) in the game to see actual window size.

Ali

  • What will become of the baron?
    • Ali worked on a game that was nominated for an AGS Award!
      Ali worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #41 on: 10 Oct 2016, 16:30 »
I just checked, and it is actually running at 1280x720. Neither Direct Draw 5 nor Direct3D show all the resolutions for me.

Crimson Wizard

  • Local Moderator
  • AGS Project Tracker Admins
    • Best Innovation Award Winner 2013, for spearheading the AGS 3.3.0 project
    •  
    • Lifetime Achievement Award Winner
    •  
    • Crimson Wizard worked on a game that was nominated for an AGS Award!
      Crimson Wizard worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #42 on: 10 Oct 2016, 16:54 »
If you game is 1280x720, then it should be listed as "Game resolution". What about games with lower resolutions, do they have this resolution listed normally?


I can create a 1280x720 game, and set it to run at 'game resolution'. This runs 1280x720 successfully, however when I run setup again, it defaults back to 'desktop resolution'.
This might be a bug in setup program, it cannot restore the option to saved value (or does not save it properly, idk yet). That happens to me too, even if setup mentions this resolution as supported otherwise.

Ali

  • What will become of the baron?
    • Ali worked on a game that was nominated for an AGS Award!
      Ali worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #43 on: 10 Oct 2016, 16:59 »
If I set the game's actual size to 320x200, then 1280x720 is not listed. As you say, it only seems to appear as 'Game resolution' when the game is 1280x720.

Enforce object based scripting
« Reply #44 on: 20 Oct 2016, 20:09 »
Do we still need to turn off object based scripting?
What if your blessings come through raindrops
What if your healing comes through tears...

Crimson Wizard

  • Local Moderator
  • AGS Project Tracker Admins
    • Best Innovation Award Winner 2013, for spearheading the AGS 3.3.0 project
    •  
    • Lifetime Achievement Award Winner
    •  
    • Crimson Wizard worked on a game that was nominated for an AGS Award!
      Crimson Wizard worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #45 on: 20 Oct 2016, 21:53 »
Do we still need to turn off object based scripting?
That depends on what scripting commands you want to use in your game. If you want to continue using old commands, like MoveCharacter instead of Character.Walk, or SetVoiceMode instead of Speech.VoiceMode, then you should turn "enforce object-based scripting" off.

Re: AGS 3.4.0
« Reply #46 on: 22 Oct 2016, 10:39 »
Looks good. However my current develop proyect run in 3.35 version and i'm afraid new version break something. I think it shouldn't happen, i tried alpha version to compile a Linux version and go well (changing Processclick to Room.Processclick).
So i don't know if change to the new version.

Edit. Forget give my thanks for the new version to all develop team.
Edit 2. Alpha version the Linux game version can't play videos. It's fixed?
« Last Edit: 22 Oct 2016, 16:04 by Neo_One »

Edmundito

  • Mittens Serf
    • Best Innovation Award Winner 2014, for 'Tween Module'
    •  
    • I can help with scripting
    •  
    • Edmundito worked on a game that was nominated for an AGS Award!
Re: AGS 3.4.0
« Reply #47 on: 22 Oct 2016, 19:47 »
Found a documentation mistake for Character and Object LightLevel while implementing new Tweens. Here's an example for the Character doc, but the Object is also the same:

Quote
SetLightLevel (character)
void Character.SetLightLevel(int light_level)

Sets individual light level for this character.
The light level is from -100 to 100.

In 8-bit games you cannot use positive light level for brightening effect, but you may still use negative values to produce darkening effect.

To disable character lighting and tinting effects, call SetLightLevel with parameter light_level 0.

NOTE: Setting a light level will disable any RGB tint set for the character.

NOTE: Character's individual light level OVERRIDES both ambient light level and local region light level.

Example:

cEgo.LightLevel = 100;

This will give character EGO maximal individual brightness.
Compatibility: Supported by AGS 3.4.0 and later versions.

Note that the example implies that the usage is:
Code: Adventure Game Studio
  1. cEgo.LightLevel = 100;

But in reality, this will cause an error. The correct way of doing this is:
Code: Adventure Game Studio
  1. cEgo.SetLightLevel(100);

I am also surprised that:
1. There is no way to get the light level for character or object, but you can for region.
2. The API for character and object light level do not match region (which is region[ x ].LightLevel = y; and int regionLightLevel = region[ x ].LightLevel;)
Start using the Tween 2 Module!

Crimson Wizard

  • Local Moderator
  • AGS Project Tracker Admins
    • Best Innovation Award Winner 2013, for spearheading the AGS 3.3.0 project
    •  
    • Lifetime Achievement Award Winner
    •  
    • Crimson Wizard worked on a game that was nominated for an AGS Award!
      Crimson Wizard worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #48 on: 22 Oct 2016, 22:37 »
1. There is no way to get the light level for character or object, but you can for region.
2. The API for character and object light level do not match region (which is region[ x ].LightLevel = y; and int regionLightLevel = region[ x ].LightLevel;)

I am sorry, this might have dropped from my mind.
I created issues in bug tracker; these properties should be very easy to add.

I wish someone could create general checklist for the missing properties that has to be added.
« Last Edit: 23 Oct 2016, 02:01 by Crimson Wizard »

Crimson Wizard

  • Local Moderator
  • AGS Project Tracker Admins
    • Best Innovation Award Winner 2013, for spearheading the AGS 3.3.0 project
    •  
    • Lifetime Achievement Award Winner
    •  
    • Crimson Wizard worked on a game that was nominated for an AGS Award!
      Crimson Wizard worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #49 on: 25 Oct 2016, 15:06 »
By the way, I was testing this stuff out and noticed that there is another mistake in the manual (not engine):

Quote
To disable character lighting and tinting effects, call SetLightLevel with parameter light_level 0.

In fact, setting character's (and object's) light level to 0 will enforce individual light level 0, which would override region and ambient light levels, similar to how calling Tint() with saturation 0 still overrides region and ambient tints.
The only real way to disable character's individual lighting is to call RemoveTint().


This makes me wonder if changing SetLightLevel into LightLevel property will be a good decision. Because character's LightLevel = 0 will not be the same as "light level disabled".
We would need to add separate property LightLevelEnabled (similar to TintEnabled) to let user know whether character has individual light level set.
« Last Edit: 25 Oct 2016, 15:09 by Crimson Wizard »

cat

  • Mittens Baronet
  • AGS Baker
  • Can you write alcohol in Japanese?
    • cat worked on a game that was nominated for an AGS Award!
      cat worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #50 on: 31 Oct 2016, 11:07 »
Is there a known problem with AGS cutting audio files?

With our current project, we are using very short sound effects (~160ms) in ogg format. When played, nothing can be heard although the file works fine in the editor preview.
For testing purposes, we made a file that contains the short sound twice. When using it in AGS, it is now played but cut off.

My guess would be that AGS does not play sounds till the end. So with very short sounds nothing can be heard. Our current workaround is to add 200ms silence to the end of the sound. However, I think this is worth investigation (or at least adding a caveat in the manual because this is very hard to figure out).

Edit: I just realized that I already posted about this before but noone answered yet:
http://www.adventuregamestudio.co.uk/forums/index.php?topic=51050.msg636529615#msg636529615
« Last Edit: 31 Oct 2016, 11:18 by cat »

Danvzare

  • The Man with No Name
    • I can help with AGS tutoring
    •  
    • I can help with play testing
    •  
    • I can help with proof reading
    •  
    • I can help with story design
    •  
    • I can help with voice acting
    •  
Re: AGS 3.4.0
« Reply #51 on: 31 Oct 2016, 11:23 »
I've encountered the problem myself. I figured out straight away that I needed to add some silence to the start and end.
Also, maybe it's just me (I've yet to test this theory), but it doesn't seem to cut off the sound when it's in WAV format.

I must admit though, the sound cutting off is a little bit annoying.

Crimson Wizard

  • Local Moderator
  • AGS Project Tracker Admins
    • Best Innovation Award Winner 2013, for spearheading the AGS 3.3.0 project
    •  
    • Lifetime Achievement Award Winner
    •  
    • Crimson Wizard worked on a game that was nominated for an AGS Award!
      Crimson Wizard worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #52 on: 31 Oct 2016, 18:04 »
@cat, I met some issues with OGG audio being cut before, but not exactly what you describe. I could maybe check what is going on under debugger if you send me the OGG file (or both short and log files).

Re: AGS 3.4.0
« Reply #53 on: 31 Oct 2016, 23:32 »
Out of curiosity I tried to build the demo game to Linux from within Windows and it doesn't copy any of the libraries or ags32 to ags64 to the compiled directory. Though it does copy the initial bash script and the directory structure. Odd

Crimson Wizard

  • Local Moderator
  • AGS Project Tracker Admins
    • Best Innovation Award Winner 2013, for spearheading the AGS 3.3.0 project
    •  
    • Lifetime Achievement Award Winner
    •  
    • Crimson Wizard worked on a game that was nominated for an AGS Award!
      Crimson Wizard worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #54 on: 01 Nov 2016, 06:58 »
Out of curiosity I tried to build the demo game to Linux from within Windows and it doesn't copy any of the libraries or ags32 to ags64 to the compiled directory. Though it does copy the initial bash script and the directory structure.
Could you tell where is your game project located (user documents folder, disk C, another disk)? Might be permissions issue.

Crimson Wizard

  • Local Moderator
  • AGS Project Tracker Admins
    • Best Innovation Award Winner 2013, for spearheading the AGS 3.3.0 project
    •  
    • Lifetime Achievement Award Winner
    •  
    • Crimson Wizard worked on a game that was nominated for an AGS Award!
      Crimson Wizard worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #55 on: 03 Nov 2016, 20:15 »
So, regarding small OGGs not playing. Cat sent me couple of OGG files and upon investigation I can confirm that the sound library which AGS uses has this issue with OGG and MP3 files. This is related to how it handles audio streams: when it sends final sound partition to device, it cannot know when the sound actually stopped playing there, so it sets some arbitrary "counter" value and waits until counter ends, then tells device to stop. Apparently for very small sounds this counter is not enough to make any of it being actually heard. In the sake of experiment I rised this counter x3 times, and those clips started playing.

I do not feel confident enough to meddle with this right now. Besides I heard Nick Sonneveld is working on replacing audio libraries with OpenAL (which is more up-to-date).

Dave Gilbert

  • Mittens Vassal
  • AGS Baker
  • Hi. Our names are FRIGGING ADORABLE.
    • Lifetime Achievement Award Winner
    •  
    • Dave Gilbert worked on a game that was nominated for an AGS Award!
      Dave Gilbert worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #56 on: 03 Nov 2016, 20:17 »
Hm. Interesting. I can confirm this has never happened to me. I use hundreds of short ogg sound effects per game and I have never added silence to the end. Maybe I have just been lucky?

cat

  • Mittens Baronet
  • AGS Baker
  • Can you write alcohol in Japanese?
    • cat worked on a game that was nominated for an AGS Award!
      cat worked on a game that won an AGS Award!
Re: AGS 3.4.0
« Reply #57 on: 04 Nov 2016, 08:58 »
Thanks for the analysis, CW!
I understand that there wont be a fix. But maybe we should make a note in the documentation that very short audio files can cause problems and people should make them longer by adding silence to them?

@Dave Gilbert: Maybe your audio files are longer - it only seems to happen if they are less than, say, 300ms long.

Danvzare

  • The Man with No Name
    • I can help with AGS tutoring
    •  
    • I can help with play testing
    •  
    • I can help with proof reading
    •  
    • I can help with story design
    •  
    • I can help with voice acting
    •  
Re: AGS 3.4.0
« Reply #58 on: 04 Nov 2016, 10:05 »
It's nice to finally know what's causing the problem. Thankfully it's easy to work around.

Thanks CW. :-D

Khris

    • Lifetime Achievement Award Winner
    •  
    • I can help with play testing
    •  
    • I can help with scripting
    •  
    • I can help with translating
    •  
    • Khris worked on a game that was nominated for an AGS Award!
Re: AGS 3.4.0
« Reply #59 on: 23 Nov 2016, 23:34 »
- Added support for dynamic array as return value of the struct's member
- Fixed Ctrl+Tab did not work for the first time when cycling through opened editor tabs.

This is so awesome, thanks a ton, CW! I can finally ditch 3.2.1 :-D