This script allows you to use a random battle bgm instead of the same one over and over again. Instructions in the script.
CODE
######################## Breadlords Random Battle BGM ##########################
## This allows the BGM in battles to be chosen randomly from the BGM's you ##
## set. You set a BGM like this : number => RPG::BGM.new("bgm name", volume, ##
## pitch)] *all on one line*, were number is the number 1 higher than the ##
## number of the previous one (starting at zero, 1 for the next bgm ect), bgm ##
## name is were you will put in the name of the BGM, volume is it's volume, I ##
## recomend that if you do not know what your doing you should just leave it ##
## at 100, the same for pitch - if you do not know what your doing leave this ##
## at 100. ##
## ##
## Finally, if you want to stop the random BGM use the command $stop_random = ##
## true, to set the random BGMs back on again use $stop_random = false ##
################################################################################
################################################################################
class Scene_Map < Scene_Base
alias add_music_battle call_battle unless $@
def call_battle
random_BGM ={ # Insert custom BGMs here
0 => RPG::BGM.new("Battle1", 100, 100), # BGM I've set up, you can remove
1 => RPG::BGM.new("Battle2", 100, 100), # BGM I've set up, you can remove
2 => RPG::BGM.new("Battle3", 100, 100), # BGM I've set up, you can remove
3 => RPG::BGM.new("Battle4", 100, 100), # BGM I've set up, you can remove
4 => RPG::BGM.new("Battle5", 100, 100), # BGM I've set up, you can remove
5 => RPG::BGM.new("Battle6", 100, 100), # BGM I've set up, you can remove
6 => RPG::BGM.new("Battle7", 100, 100), # BGM I've set up, you can remove
7 => RPG::BGM.new("Battle8", 100, 100), # BGM I've set up, you can remove
}
########################### Do not edit past here ##############################
i = random_BGM.keys
wich_one = rand(i.size - 1)
music = random_BGM[wich_one]
unless $stop_random
$game_system.battle_bgm = music
end
add_music_battle
end
end