Turned trainer intro MEs into BGMs

This commit is contained in:
Maruno17
2022-04-20 22:11:04 +01:00
parent 144ad91bc1
commit d3b61a64ef
9 changed files with 25 additions and 18 deletions

View File

@@ -453,8 +453,6 @@ def pbTrainerBattleCore(*args)
# Set various other properties in the battle class
pbPrepareBattle(battle)
$game_temp.clear_battle_rules
# End the trainer intro music
Audio.me_stop
# Perform the battle itself
decision = 0
pbBattleAnimation(pbGetTrainerBattleBGM(foeTrainers), (battle.singleBattle?) ? 1 : 3, foeTrainers) {

View File

@@ -68,10 +68,11 @@ def pbBattleAnimation(bgm = nil, battletype = 0, foe = nil)
playingBGM = $game_system.getPlayingBGM
$game_system.bgm_pause
$game_system.bgs_pause
if $game_temp.memorized_bgm
playingBGM = $game_temp.memorized_bgm
$game_system.bgm_position = $game_temp.memorized_bgm_position
end
end
pbMEFade(0.25)
pbWait(Graphics.frame_rate / 4)
pbMEStop
# Play battle music
bgm = pbGetWildBattleBGM([]) if !bgm
pbBGMPlay(bgm)
@@ -129,6 +130,8 @@ def pbBattleAnimation(bgm = nil, battletype = 0, foe = nil)
$game_system.bgm_resume(playingBGM)
$game_system.bgs_resume(playingBGS)
end
$game_temp.memorized_bgm = nil
$game_temp.memorized_bgm_position = 0
$PokemonGlobal.nextBattleBGM = nil
$PokemonGlobal.nextBattleME = nil
$PokemonGlobal.nextBattleCaptureME = nil