Does anybody have a script for a message before the main menu ?

Joined
May 18, 2018
Messages
6
Reaction score
0
First Language
French
Primarily Uses
RMVXA
Sorry if this isn't in the right category. But basically i'd want to put a message before the main menu screen, but the only script I found was a broken link. Does anybody have a new script for it to work ? Sorry if my english sucks btw orz
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,299
Reaction score
11,713
First Language
English
Primarily Uses
RMVXA
If you want to do your message via splash screens, then you could try the script I've posted below. The original link for it has vanished.
Code:
#=============================================================================#
#-----------------------------------------------------------------------------#
#---------------------IBG Flash Screen/Skip Title V2.0------------------------#
#=============================================================================#
#--------------------------------Free to use----------------------------------#                
#-----------------------------No credit needed--------------------------------#
#----------Special Thanks to Doctor Todd for his contribution on BGM----------#
#=============================================================================#
#-----------------------------------Setup-------------------------------------#
#---Just place below materials and specify image to be used as flash screen.--#
#-------------------(Must be in Graphics/System folder)-----------------------#
#=============================================================================#
class IBG_PT < Scene_Base
  module IBG
  
#=============================================================================#
#------------------------------------Setup------------------------------------#
#=============================================================================#
# Flash: Flash image filenames. (must be in Graphics/System)                  #
# Ex. ["Flash1",Flash2",Flash3",]                                             #
# NumF: Number of flash screens. (Be sure to add all of them to Flash)        #
# Delay: How long to display flash screens in frames. (60 frames = 1 Second)  #
# Skip: Skip title if no save exists.                                         #
# MUS: Play music with flash screens.                                         #
# FAD: Fade out music before Title Screen.                                    #
# BGM: Name of music file to play.                                            #
# Skip_Key: Key to skip flash screens, nil to disallow.                       #
# Ex. :A, :B, or :C (Default :C)                                              #
#=============================================================================#
    Flash    = ["intro-1","intro-2","intro-3",] #Change these to your file names
    NumF     = 3 #This must be the same as the number of file names in the above line
    Delay    = 180
    Skip     = false
    MUS      = true
    FAD      = false
    BGM      = "Run" #Change to the title of the music track you want to be played
    Skip_Key = :C
  end
 
#=============================================================================#
#---------------------------------Processing----------------------------------#
#=============================================================================#

  def initialize
    @time = IBG::Delay
    @screen = 0
    @shown = 0
  end

  def start
    super 
    create_background
    if IBG::MUS
      Audio.bgm_play("Audio/BGM/" + IBG::BGM, 100, 100) #(DoctorTodd edit)
    end
  end

  def create_background
    @time = IBG::Delay
    @sprite = Sprite.new
    @sprite.bitmap = Cache.system(IBG::Flash[@screen])
    @screen += 1
    @shown += 1
  end

  def update
    super
    if Input.press?(IBG::Skip_Key)
      goto_title
    end
    if  @shown == IBG::NumF and @time == 0
      goto_title
    else
      if @time == 0 and @shown <= IBG::NumF
        create_background
      else
        @time -= 1
      end
    end
  end

  def dispose_background
    @sprite.bitmap.dispose
    @sprite.dispose
  end

  def goto_title
    if IBG::Skip
      if DataManager.save_file_exists?
        if IBG::FAD
          fadeout_all
        end
        SceneManager.goto(Scene_Title)
        else
          DataManager.setup_new_game
        if IBG::FAD
          fadeout_all
        end
        $game_map.autoplay
        SceneManager.goto(Scene_Map)
      end
      else
      DataManager.save_file_exists?
        if IBG::FAD
          fadeout_all
        end
      SceneManager.goto(Scene_Title)
    end
  end
end

module SceneManager

  def self.first_scene_class
    $BTEST ? Scene_Battle : IBG_PT
  end
end
 
Last edited:
Joined
May 18, 2018
Messages
6
Reaction score
0
First Language
French
Primarily Uses
RMVXA
If you want to do your message via splash screens, then you could try the script I've posted below. The original link for it has vanished.
Code:
#=============================================================================#
#-----------------------------------------------------------------------------#
#---------------------IBG Flash Screen/Skip Title V2.0------------------------#
#=============================================================================#
#--------------------------------Free to use----------------------------------#                
#-----------------------------No credit needed--------------------------------#
#----------Special Thanks to Doctor Todd for his contribution on BGM----------#
#=============================================================================#
#-----------------------------------Setup-------------------------------------#
#---Just place below materials and specify image to be used as flash screen.--#
#-------------------(Must be in Graphics/System folder)-----------------------#
#=============================================================================#
class IBG_PT < Scene_Base
  module IBG
  
#=============================================================================#
#------------------------------------Setup------------------------------------#
#=============================================================================#
# Flash: Flash image filenames. (must be in Graphics/System)                  #
# Ex. ["Flash1",Flash2",Flash3",]                                             #
# NumF: Number of flash screens. (Be sure to add all of them to Flash)        #
# Delay: How long to display flash screens in frames. (60 frames = 1 Second)  #
# Skip: Skip title if no save exists.                                         #
# MUS: Play music with flash screens.                                         #
# FAD: Fade out music before Title Screen.                                    #
# BGM: Name of music file to play.                                            #
# Skip_Key: Key to skip flash screens, nil to disallow.                       #
# Ex. :A, :B, or :C (Default :C)                                              #
#=============================================================================#
    Flash    = ["intro-1","intro-2","Gemelle Screen",]
    NumF     = 3
    Delay    = 180
    Skip     = false
    MUS      = true
    FAD      = false
    BGM      = "Run"
    Skip_Key = :C
  end
 
#=============================================================================#
#---------------------------------Processing----------------------------------#
#=============================================================================#

  def initialize
    @time = IBG::Delay
    @screen = 0
    @shown = 0
  end

  def start
    super 
    create_background
    if IBG::MUS
      Audio.bgm_play("Audio/BGM/" + IBG::BGM, 100, 100) #(DoctorTodd edit)
    end
  end

  def create_background
    @time = IBG::Delay
    @sprite = Sprite.new
    @sprite.bitmap = Cache.system(IBG::Flash[@screen])
    @screen += 1
    @shown += 1
  end

  def update
    super
    if Input.press?(IBG::Skip_Key)
      goto_title
    end
    if  @shown == IBG::NumF and @time == 0
      goto_title
    else
      if @time == 0 and @shown <= IBG::NumF
        create_background
      else
        @time -= 1
      end
    end
  end

  def dispose_background
    @sprite.bitmap.dispose
    @sprite.dispose
  end

  def goto_title
    if IBG::Skip
      if DataManager.save_file_exists?
        if IBG::FAD
          fadeout_all
        end
        SceneManager.goto(Scene_Title)
        else
          DataManager.setup_new_game
        if IBG::FAD
          fadeout_all
        end
        $game_map.autoplay
        SceneManager.goto(Scene_Map)
      end
      else
      DataManager.save_file_exists?
        if IBG::FAD
          fadeout_all
        end
      SceneManager.goto(Scene_Title)
    end
  end
end

module SceneManager

  def self.first_scene_class
    $BTEST ? Scene_Battle : IBG_PT
  end
end
so i put it in Materials, right ? im sorry for asking, im still new to this :kaocry:
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,100
Reaction score
13,705
First Language
English
Primarily Uses
RMMV
Yes, and you have to change these two lines:

Code:
   Flash    = ["intro-1","intro-2","Gemelle Screen",]
   NumF     = 3
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,299
Reaction score
11,713
First Language
English
Primarily Uses
RMVXA
@Jinxschoiceweapon Oops - you will also have to change the lines
Code:
Delay    = 180
    Skip     = false
    MUS      = true
    FAD      = false
    BGM      = "Run"
The delay is the number of frames I want, and 'Run' is the BGM music I'm using. The other lines are my preferences. I forgot to set everything back to default before copy/pasting from my own project. You will need to check the header to see how to configure it.

I also didn't spot that this thread is in the wrong place.

[mod]Moving to RGSS3 Script Requests[/mod]
 

Roninator2

Gamer
Veteran
Joined
May 22, 2016
Messages
2,661
Reaction score
563
First Language
English
Primarily Uses
RMVXA
What is the script that you could not get, maybe someone else has it.
 
Joined
May 18, 2018
Messages
6
Reaction score
0
First Language
French
Primarily Uses
RMVXA
upload_2018-5-29_17-2-56.png
hmm... i tried it, but for some reasons it does this whenever i try to playtest it. im not sure what it is (im so sorry once again), can someone help me ?
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,299
Reaction score
11,713
First Language
English
Primarily Uses
RMVXA
2 things
Always, always name your scripts.
As I posted above, you have to change the BGM from the track title Run, which you don't have, to whatever track you are using for your title, or pre-title section. It will crash with that, even if everything else is perfect. Did you do any other editing in that little section e.g. accidentally remove the end on line 38?
 
Joined
May 18, 2018
Messages
6
Reaction score
0
First Language
French
Primarily Uses
RMVXA
2 things
Always, always name your scripts.
As I posted above, you have to change the BGM from the track title Run, which you don't have, to whatever track you are using for your title, or pre-title section. It will crash with that, even if everything else is perfect. Did you do any other editing in that little section e.g. accidentally remove the end on line 38?
oh shoot, you're right ! i forgot to name it and i put a track that i have.
im still a bit confused. whenever i try to playtest it, it doesn't show the splash screen (i have saved it in the graphics/system folders) upload_2018-5-29_18-28-23.png
(i've changed some stuff too due to it only be one frame, and I don't necessarily want background music.)
 

TheoAllen

Self-proclaimed jack of all trades
Veteran
Joined
Mar 16, 2012
Messages
5,594
Reaction score
6,527
First Language
Indonesian
Primarily Uses
RMVXA
Why you suddenly add 'end' on line 39 when the original script posted by Kes doesn't have it?
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,299
Reaction score
11,713
First Language
English
Primarily Uses
RMVXA
Nope, scroll down in the 'Code' section and you'll find the whole script.
That's why nothing is working, you only have the header in.

EDIT
For the benefit of anyone who wants this script in the future, I am editing it to make it clearer exactly what the user does, so don't be disconcerted if it looks different to what you originally copy/pasted.
 
Last edited:

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

"You can thank my later", "But you haven't done anything", "Well, that's why ..."
Are we allowed to post about non-RPG Maker games?
I should realize that error was produced by a outdated version of MZ so that's why it pop up like that
Ami
i can't wait to drink some ice after struggling with my illness in 9 days. 9 days is really bad for me,i can't focus with my shop and even can't do something with my project
How many hours have you got in mz so far?

Forum statistics

Threads
105,884
Messages
1,017,243
Members
137,609
Latest member
shododdydoddy
Top