Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Play the same BGM that was played in the last battle

Status
Not open for further replies.

A J

Member

what is the code for playing the same BGM that was played in the last battle

coz when I go back to the battle that I have just left the battle BGM is not working

Thanks
 

A J

Member

ok here is another problem
I've found up the code to play the BGM I wanted
Code:
    $game_system.bgm_play($game_system.battle_bgm)
ok the problem now is when I choose the command start_battle and the ME haven't finish yet it won't work even though I have put $game_system.me_play(nil) and I've tried alot of other codes to stop it but it didn't work I have to wait till the ME stop by it self than choose the command

this is the code for the start battle command

Code:
  def start_battle
    # Play decision SE
    $game_system.me_play(nil)
    for i in 0..$game_party.actors.size - 1
      $game_party.actors[i].hp = $game_party.actors[i].maxhp
    end
    $game_temp.gameover = false
    $game_system.se_play($data_system.battle_start_se)
    # Play battle BGM
    $game_system.bgm_play($game_system.battle_bgm)
    $scene = Scene_Battle.new
  end
 

ccoa

Member

No need to triple post, use the edit button and only bump once every 72 hours.

This topic has been resolved. If A J or any other users have any questions or further problems regarding this topic, please create a new thread about them.

Thank you!
 
Status
Not open for further replies.

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top