#==========================================================================
# ** SG Optional Battle Music
#==========================================================================
# sandgolem
# Version 1
# 24.06.06
#==========================================================================
# Switch number to activate the Even Music
#
#Also note, in Event enabling this switch, change battle win ME to null
Scene_Map::SG_Disable_BattleMusic = 5
#==========================================================================
#
# To check for updates or find more scripts, visit:
#
http://www.gamebaker.com/rmxp/scripts/
#
# To use this script, copy it and insert it in a new section above "Main",
# under the default scripts, and the SDK if you're using it.
#
# Have problems? Official topic:
#
http://forums.gamebaker.com/showthread.php?t=13
#
#==========================================================================
begin
SDK.log('SG Optional Battle Music', 'sandgolem', 1, '24.06.06')
if SDK.state('SG Optional Battle Music') != true
@sg_nobattlebgm_disabled = true
end
rescue
end
if !@sg_nobattlebgm_disabled
#--------------------------------------------------------------------------
class Game_System
alias sandgolem_nobattlebgm_system_bgm bgm_play
def bgm_play(bgm)
if !$sg_keep_music
sandgolem_nobattlebgm_system_bgm(bgm)
end
end
alias sandgolem_nobattlebgm_system_bgmstop bgm_stop
def bgm_stop
if !$sg_keep_music
sandgolem_nobattlebgm_system_bgmstop
end
end
end
class Scene_Map
alias sandgolem_nobattlebgm_map_callbattle call_battle
def call_battle
if $game_switches[SG_Disable_BattleMusic]
$sg_keep_music = true
end
sandgolem_nobattlebgm_map_callbattle
$sg_keep_music = nil
end
end
#--------------------------------------------------------------------------
end