Game Over Screen Change

Omega Five

Advanced Meember
Veteran
Joined
Aug 13, 2016
Messages
63
Reaction score
12
First Language
Italian
Primarily Uses
Is there a way to change the file used for the Game Over Screen with a script command?


Also, is there a way to change its music?


Please reply ASAP.
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,299
Reaction score
11,712
First Language
English
Primarily Uses
RMVXA
Are these global changes that you want, or do you want screens and music which are for specific maps/battles?
 

Omega Five

Advanced Meember
Veteran
Joined
Aug 13, 2016
Messages
63
Reaction score
12
First Language
Italian
Primarily Uses
Global changes.
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,299
Reaction score
11,712
First Language
English
Primarily Uses
RMVXA
Open your game file, then Graphics folder, then System.  Drop in the image you would like.  It must be called GameOver.


On the Systems tab of the Editor, left column, 4th box, click on the ... and select which track you want from the music you've installed in BGM folder.
 
Last edited by a moderator:

Omega Five

Advanced Meember
Veteran
Joined
Aug 13, 2016
Messages
63
Reaction score
12
First Language
Italian
Primarily Uses
I already know that, I was asking for a script command that could change the file used mid-game.


(also, small note: the music used for the Game Over screen is a ME, not a BGM.)
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,299
Reaction score
11,712
First Language
English
Primarily Uses
RMVXA
That is why I asked if it was global or specific, and when you said global I assume that that was what you meant.


First you need a snippet like this (credit Shaz)



class Scene_Gameover < Scene_Base


  def create_background


    @sprite = Sprite.new


    if <insert condition here>


      @sprite.bitmap = Cache.system("GameOver")


    else


      @sprite.bitmap = Cache.system("AlternateGameOver")


    end


  end


end

The <insert condition here> is the line where a variety of possibilities can go. 


If you want it to change for the map, then put either of these as the condition:

if it's only one map:



$game_map.map_id == x

where x is the map number (no leading zeros)

or if it's several maps that you want to show that image:



[1,2,3,4,5].include?($game_map.map_id)

where that image will be shown for maps 1, 2, 3, 4 and 5
However, if it's going to be for the rest of the game, then a switch would probably be much easier than listing all the (many) maps remaining. 


Turn it on when you reach the areas where you want the 'alternate' image to be shown, and use this condition:



!$game_switches[id]

That will show the default gameover when the switch is off, and the alternate one when it's on. As far as I am aware, it is either map or switch, it can't be both.


I haven't seen a method for changing the music.  You will need to start a fresh thread in Script requests, specifying that it is to change the music partway through the game, as that cannot be done by pure eventing.
 
Last edited by a moderator:

Omega Five

Advanced Meember
Veteran
Joined
Aug 13, 2016
Messages
63
Reaction score
12
First Language
Italian
Primarily Uses
What is [SIZE=10pt]@sprite[/SIZE][SIZE=10pt].[/SIZE][SIZE=10pt]bitmap [/SIZE][SIZE=10pt]=[/SIZE][SIZE=10pt] [/SIZE][SIZE=10pt]Cache[/SIZE][SIZE=10pt].[/SIZE][SIZE=10pt]system[/SIZE][SIZE=10pt]([/SIZE][SIZE=10pt]"GameOver"[/SIZE][SIZE=10pt])[/SIZE] supposed to be?
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,299
Reaction score
11,712
First Language
English
Primarily Uses
RMVXA
That is how it calls up the Game Over image.  It therefore follows that AlternateGameOver is the new one.
 

Omega Five

Advanced Meember
Veteran
Joined
Aug 13, 2016
Messages
63
Reaction score
12
First Language
Italian
Primarily Uses
After using the code and activating the switch, the screen just fades black and nothing happens...


what to do?
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,299
Reaction score
11,712
First Language
English
Primarily Uses
RMVXA
No idea.  Have you dropped an image into Graphics/System called AlternateGameOver?  That's the only thing I can think of.


If you have, then I think the best course of action is for this thread to be moved to Script Support and see if any of the scripters there can come up with a solution.
 

Kes

Veteran
Veteran
Joined
Aug 3, 2012
Messages
22,299
Reaction score
11,712
First Language
English
Primarily Uses
RMVXA
Moving this to RSGGx Script Support.
 

Omega Five

Advanced Meember
Veteran
Joined
Aug 13, 2016
Messages
63
Reaction score
12
First Language
Italian
Primarily Uses
oh. originally read it as "make a new thread" instead of "wait for the thread to be moved".


well, this is a request for a sprite that lets you change the image and ME files used for the game over screen mid-game, with switches.


EDIT: i messed up.


i inserted the code in a event and not in the script editor.


once i realized that, it worked.


this is not cancelling the request for the script, because i still need a way to change the ME file used, and a way to have multiple options.
 
Last edited by a moderator:

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

Latest Threads

Latest Posts

Latest Profile Posts

How many parameters is 'too many'??
Yay, now back in action Happy Christmas time, coming back!






Back in action to develop the indie game that has been long overdue... Final Fallacy. A game that keeps on giving! The development never ends as the developer thinks to be the smart cookie by coming back and beginning by saying... "Oh bother, this indie game has been long overdue..." How could one resist such? No-one c
So I was playing with filters and this looked interesting...

Versus the normal look...

Kind of gives a very different feel. :LZSexcite:
To whom ever person or persons who re-did the DS/DS+ asset packs for MV (as in, they are all 48x48, and not just x2 the pixel scale) .... THANK-YOU!!!!!!!!! XwwwwX

Forum statistics

Threads
105,853
Messages
1,016,986
Members
137,561
Latest member
visploo100
Top