Bug: AGS crashes when playing audio while skipping a cutscene

Started by tzachs, Sun 01/01/2012 21:24:51

Previous topic - Next topic

tzachs

I've encountered a bug with the new audio system.
If the user is skipping a cutscene which plays a sound, it can crash AGS (it has like 50% chance to crash).
If you use cutscenes, and the new audio system, you can workaround it by creating a workaround function in the global script:

Code: ags

AudioChannel* PlaySound(this AudioClip*,  AudioPriority priority, 
  RepeatStyle repeatStyle)
{
  if (Game.SkippingCutscene) return null;
  return this.Play(priority, repeatStyle);
}


Declare it in the header:
Code: ags

import AudioChannel* PlaySound(this AudioClip*,  AudioPriority priority=eAudioPriorityHigh, 
  RepeatStyle repeatStyle=eOnce);


And then replace all usages of the kind aMyAudio.Play, with aMyAudio.PlaySound.


Calin Leafshade

Might be worth adding bugs to Bero's tracker since thats the only active repos currently.

tzachs

I tried to search but failed miserably. The one tracker that I did see has bugs up until 2009...
Where is that magical tracker you're talking about?

SMF spam blocked by CleanTalk