Mr.Mo Add-on: On-Map Battle Music
Version: 1.2
Introduction
This is probably without a doubt not the best script in the world, I made it for my game and... well, it's probably not the best way of doing this. But I thought I should share it as others might find it useful. It's dead simple so no credit is required unless you want to.
Made for Mr.Mo's SBABS, but it might work with his ABS too, I dunno if the method names are the same.
Script
Instructions
Above main but below Mr.Mo's SBABS.
FAQ
What does it do?
When the enemy attacks you, battle music starts playing (whether it's a miss or not). If the enemy doesn't attack you for 40 frames, the music stops playing. Simple as that. It just adds a little bit of extraness so on-map battles feel like... battles.
Where do I edit to set the map or battle music?
It uses the map's default music and the battle music from the editor.
Compatibility
I aliased, so it should be compatible with most things though I'm not sure entirely.
Only compatible with Mr.Mo's SBABS and possibly his ABS and ABS-lite.
Credits and Thanks
Don't bother creditting me please, unless you really want to. Free or commercial (but check with the terms in Mr.Mo's ABS for his terms).
Thanks to Mr.Mo for making the battle system(s), and thanks to Tibuda for helping me a bit.
Author's Notes
Yes, I know it's a really short script. But a script is still a script.
Version: 1.2
1.0 - Works for Mr.Mo's ABS
1.1 - Fixed bug (initialize method added)
1.2 - Works with Near's SBABS
1.1 - Fixed bug (initialize method added)
1.2 - Works with Near's SBABS
Introduction
This is probably without a doubt not the best script in the world, I made it for my game and... well, it's probably not the best way of doing this. But I thought I should share it as others might find it useful. It's dead simple so no credit is required unless you want to.
Made for Mr.Mo's SBABS, but it might work with his ABS too, I dunno if the method names are the same.
Script
Code:
class MrMo_ABS
alias wy_mbm_ea update_enemy_attack
def update_enemy_attack(e, actor)
wy_mbm_ea(e, actor)
$bm_counter = 40
end
end
class Scene_Map
alias wy_mbm_update update
alias wy_mbm_init initialize
def initialize
$bm_counter = 0
wy_mbm_init
end
def update
if $bm_counter == 0
$game_map.autoplay
else
$game_system.bgm_play($game_system.battle_bgm)
end
$bm_counter -= 1 unless $bm_counter == 0
wy_mbm_update
end
end
Code:
class Action_Battle_System
alias wy_mbm_ea enemy_attack
def enemy_attack(enemy)
wy_mbm_ea(enemy)
$bm_counter = 40
end
end
class Scene_Map
alias wy_mbm_update update
alias wy_mbm_init initialize
def initialize
$bm_counter = 0
wy_mbm_init
end
def update
if $bm_counter == 0
$game_map.autoplay
else
$game_system.bgm_play($game_system.battle_bgm)
end
$bm_counter -= 1 unless $bm_counter == 0
wy_mbm_update
end
end
Instructions
Above main but below Mr.Mo's SBABS.
FAQ
What does it do?
When the enemy attacks you, battle music starts playing (whether it's a miss or not). If the enemy doesn't attack you for 40 frames, the music stops playing. Simple as that. It just adds a little bit of extraness so on-map battles feel like... battles.
Where do I edit to set the map or battle music?
It uses the map's default music and the battle music from the editor.
Compatibility
I aliased, so it should be compatible with most things though I'm not sure entirely.
Only compatible with Mr.Mo's SBABS and possibly his ABS and ABS-lite.
Credits and Thanks
Don't bother creditting me please, unless you really want to. Free or commercial (but check with the terms in Mr.Mo's ABS for his terms).
Thanks to Mr.Mo for making the battle system(s), and thanks to Tibuda for helping me a bit.
Author's Notes
Yes, I know it's a really short script. But a script is still a script.