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.

Modified Game Over

Script Request Template
This is not technically a request for a whole script, just a modified one.
RMXP or RMVX:
RPG:XP
Detailed Description:
I'm not that good at creating my own scripts. All I need is:
1. BGM to play ( this is in the default Scene_Gameover Script of course)
2. The Script needs to wait a few seconds (ex. Wait (40) Frames,doesn't matter at the moment, I will fix it) You can replace the number in the wait with 'x'
3. To return to the Title Screen without waiting for the player to click a button.
This is just a modification for the Scene_Gameover Script; Nothing Big.
Please Help

If you don't have the Game Application and want to help, the script is right here.
Code:
<div id="{CB}" style="font-family: monospace;"><ol> 

#==============================================================================

# ** Scene_Gameover

#------------------------------------------------------------------------------

#  This class performs game over screen processing.

#==============================================================================

 

class Scene_Gameover

  #--------------------------------------------------------------------------

  # * Main Processing

  #--------------------------------------------------------------------------

  def main

    # Make game over graphic

    @sprite = Sprite.new

    @sprite.bitmap = RPG::Cache.gameover($data_system.gameover_name)

    # Stop BGM and BGS

    $game_system.bgm_play(nil)

    $game_system.bgs_play(nil)

    # Play game over ME

    $game_system.me_play($data_system.gameover_me)

    # Execute transition

    Graphics.transition(120)

    # Main loop

    loop do

      # Update game screen

      Graphics.update

      # Update input information

      Input.update

      # Frame update

      update

      # Abort loop if screen is changed

      if $scene != self

        break

      end

    end

    # Prepare for transition

    Graphics.freeze

    # Dispose of game over graphic

    @sprite.bitmap.dispose

    @sprite.dispose

    # Execute transition

    Graphics.transition(40)

    # Prepare for transition

    Graphics.freeze

    # If battle test

    if $BTEST

      $scene = nil

    end

  end

  #--------------------------------------------------------------------------

  # * Frame Update

  #--------------------------------------------------------------------------

  def update

    # If C button was pressed

    if Input.trigger?(Input::C)

      # Switch to title screen

      $scene = Scene_Title.new

    end

  end

end

 
 

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