1
0

Step_0.gml 405 B

12345678910111213
  1. if bgm_fade_timer > 0
  2. {
  3. if --bgm_fade_timer == 0 && bgm_next != noone
  4. {
  5. if audio_is_playing(bgm_current)
  6. audio_stop_sound(bgm_current);
  7. bgm_current = audio_play_sound(bgm_next, 0, true);
  8. audio_sound_gain(bgm_current, 0, 0); // 从0开始
  9. audio_sound_gain(bgm_current, bgm_volume, 500); // 500ms淡入
  10. bgm_next = noone;
  11. }
  12. }