- Joined
- Jan 26, 2014
- Messages
- 1,281
- Reaction score
- 106
- First Language
- Irish
- Primarily Uses
- N/A
I am replicating Battle Processing through a code like this:
def call_battle_screen $game_system.battle_bgm = $game_temp.newbgm BattleManager.setup($game_temp.battle_enemy, true, true) BattleManager.event_proc = Proc.new {|n| @branch[@indent] = n } $game_player.make_encounter_count SceneManager.call(Scene_Battle) endwhere $game_temp.newbgm is an attribute accessor where newbgm = Battle2.
But whenever I call that on the scene I made, it never calls the new BGM (it means that my Scene_Battle) just plays silent. It doesn't have a BGM, whereas I wanted it to play Battle2.
The Scene_Battle works fine, but whenever I escape or win, an error saying replay method is unidenfitied for nil NilClass. It is rooted down under the BattleManager's
#-------------------------------------------------------------------------- # * Resume BGM and BGS #-------------------------------------------------------------------------- def self.replay_bgm_and_bgs @map_bgm.replay unless $BTEST @map_bgs.replay unless $BTEST endmethod.
What am I missing here?
def call_battle_screen $game_system.battle_bgm = $game_temp.newbgm BattleManager.setup($game_temp.battle_enemy, true, true) BattleManager.event_proc = Proc.new {|n| @branch[@indent] = n } $game_player.make_encounter_count SceneManager.call(Scene_Battle) endwhere $game_temp.newbgm is an attribute accessor where newbgm = Battle2.
But whenever I call that on the scene I made, it never calls the new BGM (it means that my Scene_Battle) just plays silent. It doesn't have a BGM, whereas I wanted it to play Battle2.
The Scene_Battle works fine, but whenever I escape or win, an error saying replay method is unidenfitied for nil NilClass. It is rooted down under the BattleManager's
#-------------------------------------------------------------------------- # * Resume BGM and BGS #-------------------------------------------------------------------------- def self.replay_bgm_and_bgs @map_bgm.replay unless $BTEST @map_bgs.replay unless $BTEST endmethod.
What am I missing here?
