Adventure Game Studio

AGS Support => Advanced Technical Forum => Topic started by: Radiant on Fri 03/03/2006 12:49:20

Title: Speed of Fadein() / Fadeout()
Post by: Radiant on Fri 03/03/2006 12:49:20
Is there a meaningful way to convert between the time taken by a FadeIn/FadeOut call, and the time taken by a game clock cycle?

(specifically, if music is synchronized to a sequence containing some fades, how does one convert this to a sequence not containing fades but using SetTransparency and Wait commands, without losing sync in the process)?
Title: Re: Speed of Fadein() / Fadeout()
Post by: Pumaman on Sat 04/03/2006 11:28:01
The game cycles are paused while a FadeIn/FadeOut is in progress -- but in theory a fade speed of 1 should take 64 game cycles to fade, a speed of 2 should take 32 cycles, etc.

However this is not an exact science since as I say, game cycles are not actually running during a fade.
Title: Re: Speed of Fadein() / Fadeout()
Post by: GarageGothic on Sun 05/03/2006 14:39:16
This reminds me of something I was wondering about. Does AGS use a linear fade or some kind of sine curve (fading quicker at the far end of the fade)? I wrote my own script using a full screen black gui to make fades non-blocking and  more controllable, but it feels slightly different than AGS' own fade function. Is it just my imagination?
Title: Re: Speed of Fadein() / Fadeout()
Post by: Pumaman on Sun 05/03/2006 17:16:12
It's just a simple linear fade :)
Title: Re: Speed of Fadein() / Fadeout()
Post by: GarageGothic on Mon 06/03/2006 08:45:46
So, just my imagination then  ;D
Thanks for the reply CJ!