AGS 3.0 Final - it's been a long road

Started by Pumaman, Sun 10/06/2007 18:24:35

Previous topic - Next topic

Ghost

Quote from: Pumaman on Sun 18/11/2007 22:37:07

QuoteAnd something that has often puzzled me: If I save a room as a 16bit BMP and import it into AGS, set to 16bit too, all I get is a blank screen. Saving it as 24bit then works. Is that me misunderstanding something about colour depth?

Not sure what you're saying here, can you clarify? Does AGS appear to import the image but actually just give you a black screen?


Exactly: Saving as bitmap gives me the option to save as 16/24/32. Saving a room background as 16bit and then importing gives me the black screen. Saving as 24bit works fine. AGS compiled game file size also remains the same. It never really bothered me since file compression in AGS is so good that with a zip file you won't run into much trouble, but I like to understand the things I do.

Pumaman

QuoteI'm just asking you to please not force me to use 32-bit backgrounds just because the final game will run in 32-bit mode. I appreciate that you might not consider it important enough to make a special checkbox for it when importing my art, but please don't force the editor to convert all my backgrounds to the game's color depth automatically (as you said in your reply to monkey and dkh), bloating the size of my distribution file for no good reason.

Well, the other option would be to automatically convert the backgrounds to the game colour depth at run-time, rather than the editor. This might make room transitions a bit slower, but it would mean that there'd be no need to worry about colour depth mismatches screwing up RawDraw.

QuoteI just wanted to clarify that the system freeze didn't probably depend on AGS: it was a total Windows freeze

Ah, ok then!

QuoteAs a small request, could you make the Sprite Manager window (the one that appears when you're selecting which sprite to use for GUI graphics, views and such) resizable, or at least a bit bigger? I find it too small to browse through lots of sprites right now.

Sounds easy enough, I'll look into that.

QuoteExactly: Saving as bitmap gives me the option to save as 16/24/32. Saving a room background as 16bit and then importing gives me the black screen. Saving as 24bit works fine. AGS compiled game file size also remains the same. It never really bothered me since file compression in AGS is so good that with a zip file you won't run into much trouble, but I like to understand the things I do.

Can you post a sample 16-bit BMP file that imports as a black screen into beta 15?

GarageGothic

Quote from: Pumaman on Mon 19/11/2007 22:36:12Well, the other option would be to automatically convert the backgrounds to the game colour depth at run-time, rather than the editor. This might make room transitions a bit slower, but it would mean that there'd be no need to worry about colour depth mismatches screwing up RawDraw.

That would be awesome. I suggested exactly that in one of my previous posts, but didn't think it would be possible for speed reasons. But I guess with DynamicSprite now converting the sprites to the game's color depth, it'd be pretty much the same process.

LimpingFish

Quote from: GarageGothic on Sun 18/11/2007 22:54:06
A lot of games that don't even use gradients - pretty much anything with hi-res line-drawings - would benefit from anti-aliased characters while 32-bit backgrounds are not really necessary.

This is a confusing sentence.

More sense:

"A lot of games that don't even use gradients - pretty much anything with hi-res line-drawings - would benefit from anti-aliased characters, but 32-bit backgrounds may not really be necessary to them."

Regardless, my bad.


ProgZ:

Because, as I'm sure you know, importing pre-rendered 32-bit images into a 16-bit game results in colour banding.

And, depending on the image, this effect can range from minor banding in dark areas to fairly extreme banding in images with low contrast. Overall, it's something I'd rather avoid. :)

Steam: LimpingFish
PSN: LFishRoller
XB: TheActualLimpingFish
Spotify: LimpingFish

GarageGothic

#624
Does anybody else have problems with DynamicSprite.CreateFromScreenshot creating only black sprites when running the Direct3D version? I haven't had time to test with previous betas, so it might have been there since the start, but I don't remember seeing the issue before. My game is 640x480 with 32-bit color.

Edit: I should add that this happens no matter whether I run the game windowed or full-screen. If I run the game in DirectX everything looks like it should. I also made sure to test with CreateFromBackground, which worked normally.

Ghost

Quote from: Pumaman on Mon 19/11/2007 22:36:12
Can you post a sample 16-bit BMP file that imports as a black screen into beta 15?

Here it is.
http://www.2dadventure.com/ags/faulty.bmp


monkey0506

#626
I have a few items of personal interest, though not really anything terribly important.

1) Should the old RawDraw- functions be considered "old-style-"/"non-object-oriented"/"non-strict" scripting? I've noticed that whether object-oriented scripting is enforced or not these functions are still available.

2) What exactly is the default parameter for DrawingSurface.Clear? I figured it would be our old friend "magic pink", 63519 (RGB: 255,0,255). However this color no longer appears to be magic when using the DrawingSurface functions. Next I tried the new constant: COLOR_TRANSPARENT. In place of this I just got pure white. Finally I tried SCR_NO_VALUE, the 'default' default value for AGS. Here I just got a light blue color. Finally I just set up an if/else clause to avoid passing anything when I needed transparency.

3) AFAIK it's not possible to use escaped character constants in AGS, but for some reason it seems possible to escape the apostrophe:

Code: ags
char c = '\'';


However it doesn't actually yield the result you might expect to find in this case:

Code: ags
Display("c: %d %c", c, c);


Displays:
c: 92 \
This becomes even more interesting when I realized that A) this only works in (improperly) escaping the apostrophe (which always yields \ instead) and B) it's possible to escape the apostrophe multiple times within a single character constant. I find it somewhat unsettling when the following actually compiles:

Code: ags
char c = '\'\'\'\'\'\'\'\'\'\'\'\'\'\'\'\'\'\'';


Even more unsettling that it still yields keycode 92.

4) Regarding this bit of sillyness:

Quote from: monkey_05_06 on Tue 13/11/2007 05:44:22Now this might be a silly question, but the DrawingSurface functions aren't really suited to (i.e., even feasible for a future version), say, creating an alpha channel are they?

I think the actual question here should be:

Would it be possible for DrawingSurface.DrawImage to support alpha channels?

The way it stands now if a DrawingSurface is cleared out (DrawingSurface.Clear()) and then a sprite with an alpha channel is drawn or a sprite is drawn at partial transparency using DrawingSurface.DrawImage, the alpha channel you might expect (or at least I might ;)) is destroyed and the pixels are merged with the pink background of the DrawingSurface. I understand that this too could lead to other issues, but it would make DrawingSurface.DrawImage function much more powerful if it supported alpha channels.

It does seem that simply getting/using the DrawingSurface functions with a sprite which already has an alpha channel works okay, you simply can't use DrawImage to merge alpha channel'd sprites with anything and maintain the channel (in 'transparent' areas of the DrawingSurface being drawn onto).

Khris

I've noticed something that seems to be a bug. It's probably been there since Lip sync was introduced (but at least since 2.72):
If Lip Sync is activated and the VoiceMode is set to VoiceOnly, talking characters don't animate (using their TalkingView).
My guess is that the speech routine replaces the to-be-displayed String with "" and thus LipSync, trying to match the frame characters to "", always returns the default frame (0).

Pumaman

QuoteDoes anybody else have problems with DynamicSprite.CreateFromScreenshot creating only black sprites when running the Direct3D version? I haven't had time to test with previous betas, so it might have been there since the start, but I don't remember seeing the issue before. My game is 640x480 with 32-bit color.

Hmm, I'll look into this.

QuoteHere it is.
http://www.2dadventure.com/ags/faulty.bmp

I just imported this with beta 15 and it looked fine. Can anyone else reproduce this problem?

Quote1) Should the old RawDraw- functions be considered "old-style-"/"non-object-oriented"/"non-strict" scripting? I've noticed that whether object-oriented scripting is enforced or not these functions are still available.

It's a good question. The problem is that the "enforce object based script" setting can vary in which commands are available depending on your AGS version -- this can make it quite hard for module authors to code a module that works across multiple versions.

For this reason I'm tempted to leave them for now, but I'll reconsider at a later date.

Quote2) What exactly is the default parameter for DrawingSurface.Clear? I figured it would be our old friend "magic pink", 63519 (RGB: 255,0,255). However this color no longer appears to be magic when using the DrawingSurface functions. Next I tried the new constant: COLOR_TRANSPARENT. In place of this I just got pure white. Finally I tried SCR_NO_VALUE, the 'default' default value for AGS. Here I just got a light blue color. Finally I just set up an if/else clause to avoid passing anything when I needed transparency.

Fair point, I guess COLOR_TRANSPARENT should work in this situation. I'll look into it.

Quote3) AFAIK it's not possible to use escaped character constants in AGS, but for some reason it seems possible to escape the apostrophe:

How bizarre. It's not something I'm going to investigate now because of its minor nature, but I should come back and fix it at some point.

QuoteIt does seem that simply getting/using the DrawingSurface functions with a sprite which already has an alpha channel works okay, you simply can't use DrawImage to merge alpha channel'd sprites with anything and maintain the channel (in 'transparent' areas of the DrawingSurface being drawn onto).

Can I just clarify what you're wanting to do here? Do you want DrawImage to copy across the alpha channel if you draw a source image with alpha onto a destination with alpha?

QuoteIf Lip Sync is activated and the VoiceMode is set to VoiceOnly, talking characters don't animate (using their TalkingView).
My guess is that the speech routine replaces the to-be-displayed String with "" and thus LipSync, trying to match the frame characters to "", always returns the default frame (0).

I just tried this and it seemed fine. Are you using Sierra-style speech?

monkey0506

Quote from: Pumaman on Wed 21/11/2007 20:19:16
Quote1) Should the old RawDraw- functions be considered "old-style-"/"non-object-oriented"/"non-strict" scripting? I've noticed that whether object-oriented scripting is enforced or not these functions are still available.

It's a good question. The problem is that the "enforce object based script" setting can vary in which commands are available depending on your AGS version -- this can make it quite hard for module authors to code a module that works across multiple versions.

For this reason I'm tempted to leave them for now, but I'll reconsider at a later date.

Yes but that didn't stop you trashing the GetGameParameter and RunDialog functions. := I imagine simply adding a few more imports to the BackwardsCompatible module would fix it if you do decide to enforce the DrawingSurface methods.

Quote from: Pumaman on Wed 21/11/2007 20:19:16
Quote2) What exactly is the default parameter for DrawingSurface.Clear? I figured it would be our old friend "magic pink", 63519 (RGB: 255,0,255). However this color no longer appears to be magic when using the DrawingSurface functions. Next I tried the new constant: COLOR_TRANSPARENT. In place of this I just got pure white. Finally I tried SCR_NO_VALUE, the 'default' default value for AGS. Here I just got a light blue color. Finally I just set up an if/else clause to avoid passing anything when I needed transparency.

Fair point, I guess COLOR_TRANSPARENT should work in this situation. I'll look into it.

Okay, thanks.

Quote from: Pumaman on Wed 21/11/2007 20:19:16
Quote3) AFAIK it's not possible to use escaped character constants in AGS, but for some reason it seems possible to escape the apostrophe:

How bizarre. It's not something I'm going to investigate now because of its minor nature, but I should come back and fix it at some point.

Definitely fair. I actually just came across it by being very stupid, so I doubt it actually poses a real threat. ;)

Quote from: Pumaman on Wed 21/11/2007 20:19:16
QuoteIt does seem that simply getting/using the DrawingSurface functions with a sprite which already has an alpha channel works okay, you simply can't use DrawImage to merge alpha channel'd sprites with anything and maintain the channel (in 'transparent' areas of the DrawingSurface being drawn onto).

Can I just clarify what you're wanting to do here? Do you want DrawImage to copy across the alpha channel if you draw a source image with alpha onto a destination with alpha?

Yes, basically I think that's what I want to do. As in the previous example, if I wanted to merge multiple sprites together into a single DynamicSprite which had been created using DynamicSprite.Create(WIDTH, HEIGHT, true) then the alpha channel wouldn't be copied onto the destination image where (it would seem IMO) appropriate. Not sure how feasible it might be and it's probably not a high-priority issue, but I would find it useful.

Once more, thanks CJ! 8)

Khris

Quote from: Pumaman on Wed 21/11/2007 20:19:16
QuoteIf Lip Sync is activated and the VoiceMode is set to VoiceOnly, talking characters don't animate (using their TalkingView)
[...]
I just tried this and it seemed fine. Are you using Sierra-style speech?

No, LucasArts-style. I tested it with a game template that was made for 2.62 and has been messed around with pretty excessively, so I created a default game using 3.0B15, added a talking view to Roger using two distinctive sprites, activated Lip Sync and put "A/E/I/O/U" in the 1-field.
Everything works fine until I put "SetVoiceMode(eSpeechVoiceOnly);" in game_start.
As intended, there's no textual overlay above Roger & I can hear the samples play, yet the frame stays at #0.
If you want to take a look, here's the "game" download.

tristan78

Quote from: KhrisMUC on Thu 22/11/2007 00:18:40
No, LucasArts-style.

Hi KhrisMUC,

lip sync isn't as easy as it sounds. The manual says that the voice sync feature only supports Sierra-style.

In your Default\Speech folder aren't any .PAM files.  They are necessary to make the sync. You have to set up the phenomes in Pamela. Then open the wave file with Pamela and place the phenomes on the wave file. Save the pam file with the same name as the wave file. When you rebuild VOX Files, this pam file is compiled into the speech.vox and will be used to sync the animation of the talking frames during the game.

Shane 'ProgZmax' Stevens

Uh?  What KhrisMUC is doing is perfectly right.  I tested his project file with VoiceAndText and with just Voice, and it definitely works with voice and text and definitely not with just voice.  You don't need pamela to have lip syncing work in ags at all, just the built-in editor.

Khris

#633
tristan78, I'm aware of all that.
I don't want true Pamela-lip sync but AGS's built-in character-frame-method.
Open my game, comment out the line in game_start and test it. Interact with Roger and you'll find that Roger animates fine using the two talking view frames.
That's all I want, except I want it to also work with the game set to VoiceOnly (which it doesn't).
(It's not urgent or anything and I wouldn't use VoiceOnly myself for the obvious reasons, but I thought I'd mention it.)

Edit: ProgZmax: Glad you confirmed it, I was afraid I was overlooking something obvious :)

tristan78

Quote from: ProgZmax on Thu 22/11/2007 22:04:19
You don't need pamela to have lip syncing work in ags at all, just the built-in editor.

Why I allways use the Pamela lip sync, when it's much easier  ???

Sorry for confusing...

IceMan

KhrisMUC:
If you want pamela support for a voice-only game, you can fake it by loading the speech font into an editor and removing all the letters.  Then if you set it to "text and voice" mode you can't see the text!  (Be sure to use a separate font for everything else though!)

Khris

Iceman:
1. I don't want pamela support. (Read my posts.)
2. I'm aware there are workarounds. I'd set the font color to transparent though.
3. I'm not looking for a workaround; I'm reporting what seems to be a bug.

Pumaman

Ah ok, I didn't realise anybody was actually using the non-pamela lip sync feature. I'll look into it.

JD

#638
Loading up the latest 3.0 editor beta gives me:

Quote
---------------------------
Error
---------------------------
An unexpected error occurred trying to start up the AGS Editor. Please consult the details below and post the error to the AGS Technical Forum.

System.BadImageFormatException: Could not load file or assembly 'AGS.Native, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.

File name: 'AGS.Native, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'

   at AGS.Editor.NativeProxy..ctor()

   at AGS.Editor.NativeProxy.get_Instance()

   at AGS.Editor.ApplicationController..ctor()

   at AGS.Editor.Program.startupTimer_Tick(Object sender, EventArgs e)

   at System.Windows.Forms.Timer.OnTick(EventArgs e)

   at System.Windows.Forms.Timer.TimerNativeW indow.WndProc(Message& m)

   at System.Windows.Forms.NativeWindow.Callb ack(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)



WRN: Assembly binding logging is turned OFF.

To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.

Note: There is some performance penalty associated with assembly bind failure logging.

To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

2.72 runs without any trouble though. Running Vista x64 with the latest .NET Framework installed.




edit:

Some more information. When I load up the AGS beta, it shows the splashscreen for about a second before the error shows up. When I close the error window the splashscreen is still there, and nothing happens. I have to manually close the process using the task-manager, which results in the following error:

---------------------------
Application Error
---------------------------
An unexpected error occurred. See below for details.

System.NullReferenceException: Object reference not set to an instance of an object.

   at AGS.Editor.Program.RunApplication(String[] args)
---------------------------
OK   
---------------------------

VK Dan

Quote from: def on Fri 23/11/2007 20:08:36
Loading up the latest 3.0 editor beta gives me:

Quote
---------------------------
Error
---------------------------
An unexpected error occurred trying to start up the AGS Editor. Please consult the details below and post the error to the AGS Technical Forum.

System.BadImageFormatException: Could not load file or assembly 'AGS.Native, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. An attempt was made to load a program with an incorrect format.

File name: 'AGS.Native, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null'

   at AGS.Editor.NativeProxy..ctor()

   at AGS.Editor.NativeProxy.get_Instance()

   at AGS.Editor.ApplicationController..ctor()

   at AGS.Editor.Program.startupTimer_Tick(Object sender, EventArgs e)

   at System.Windows.Forms.Timer.OnTick(EventArgs e)

   at System.Windows.Forms.Timer.TimerNativeW indow.WndProc(Message& m)

   at System.Windows.Forms.NativeWindow.Callb ack(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)



WRN: Assembly binding logging is turned OFF.

To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.

Note: There is some performance penalty associated with assembly bind failure logging.

To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

2.72 runs without any trouble though. Running Vista x64 with the latest .NET Framework installed.

It looks to me like it can't find AGS.Native.dll. Try re-extracting AGS, and make sure you get all the files. ;)

SMF spam blocked by CleanTalk