Remove title screen and menu?

Deklaration

Villager
Member
Joined
Jul 23, 2013
Messages
10
Reaction score
5
First Language
Swedish
Hi

New to javascript.

How do I disable the menu and title screen? I want the game to start without the "Start, option & exit"-options. I also would like to disable the pause menu. Been searching, but haven't found anyhting yet.

Oh, and if someone knows the new way to use the scriptline SceneManager.exit to just quit the game, it would be great!

Thanks!  :D
 

NoTaku

Villager
Member
Joined
Nov 10, 2015
Messages
6
Reaction score
3
First Language
English
 I also would like to disable the pause menu. Been searching, but haven't found anyhting yet.

I'm not sure what a pause menu is. I'm hoping you mean the Menu (when you press 'cancel").

 I want the game to start without the "Start, option & exit"-options.

Should be easy enough.


The SceneManager object is what you want to look at.

When the game is loaded, the Boot_Scene is initialized, which loads all the resources for the game and then calls SceneManager.goto(Scene_Title).

There are two ways of going about this.

1) You can modify rpg_scenes.js (Cleaner)
2) You can create a plug-in that will modify the Scene_Boot prototype object. (Safer)

Method #1:

Open rpg_scenes.js and browse to line 200. (I like Sublime Text 3)
 

Scene_Boot.prototype.start = function() { Scene_Base.prototype.start.call(this); SoundManager.preloadImportantSounds(); if (DataManager.isBattleTest()) { DataManager.setupBattleTest(); SceneManager.goto(Scene_Battle); } else if (DataManager.isEventTest()) { DataManager.setupEventTest(); SceneManager.goto(Scene_Map); } else { this.checkPlayerLocation(); DataManager.setupNewGame(); SceneManager.goto(Scene_Title); Window_TitleCommand.initCommandPosition(); } this.updateDocumentTitle();};You will want to modify the last else clause in this function, which would otherwise set up the title scene.

 

Scene_Boot.prototype.start = function() { Scene_Base.prototype.start.call(this); SoundManager.preloadImportantSounds(); if (DataManager.isBattleTest()) { DataManager.setupBattleTest(); SceneManager.goto(Scene_Battle); } else if (DataManager.isEventTest()) { DataManager.setupEventTest(); SceneManager.goto(Scene_Map); } else { this.checkPlayerLocation(); DataManager.setupNewGame(); SceneManager.goto(Scene_Map); } this.updateDocumentTitle();};The menu can be disabled using an event: "Change Menu Access...", or via script: $gameSystem.disableMenu(); You can add the script line to the above code, or you can trigger it in an event if you want.


Now, there's another way. It's a bit safer than just modifying the javascript files all willy nilly. It uses a plugin.

Plugins are actually really neat, and allow you to do a lot of things if you understand the javascript module pattern. This plugin is slightly problematic because it doesn't extend the Scene_Boot.start function, it completely replaces it. If you are using another plugin that changes the Scene_Boot.start function, you will need to make sure that they load in order so that the new Scene_Boot.start function is modified by the later plugins. Plugin load order is important to pay attention to when you are fully overriding. Not very important when you are just modifying. (See the modification I did to the DataManager.createGameObjects function for an example of modification vs overriding.)

 

//=============================================================================// CleanSlate.js//=============================================================================/*: * @plugindesc Optionally disables the title screen or the menu screen. * @author NoTaku * * @param Disable Title Screen * @desc Skips the title screen and goes straight into a new game. 0: Show Title, 1: Skip Title * @default 1 * * @param Disable Menu Screen * @desc Immediately disables the menu screen on game start. 0: Allow Menu, 1: Disable Menu * @default 1 * * @help This plugin does not provide plugin commands. */(function() { var parameters = PluginManager.parameters('CleanSlate'); var disableTitleScreen = Number(parameters['Disable Title Screen'] || 1); var disableMenuScreen = Number(parameters['Disable Menu Screen'] || 1); if(disableTitleScreen) { Scene_Boot.prototype.start = function() { Scene_Base.prototype.start.call(this); SoundManager.preloadImportantSounds(); if (DataManager.isBattleTest()) { DataManager.setupBattleTest(); SceneManager.goto(Scene_Battle); } else if (DataManager.isEventTest()) { DataManager.setupEventTest(); SceneManager.goto(Scene_Map); } else { this.checkPlayerLocation(); DataManager.setupNewGame(); SceneManager.goto(Scene_Map); } this.updateDocumentTitle(); }; } if(disableMenuScreen) { var _DataManager_createGameObjects = DataManager.createGameObjects; DataManager.createGameObjects = function() { _DataManager_createGameObjects.call(this); $gameSystem.disableMenu(); }; }})();Be aware, this is my first day with RMMV. I still have very little idea what I'm doing. I've just been picking through the source code trying to figure things out. Luckily, I've got an HTML5/Javascript background to begin with, and am an old RMXP veteran from a decade ago, so I'm making quick work of the engine so far.

Oh, and if someone knows the new way to use the scriptline SceneManager.exit to just quit the game, it would be great!

Just insert a script event somewhere that calls SceneManager.exit(). It will immediately quit the game without saving.
 

Marsigne

Veteran
Veteran
Joined
Sep 7, 2013
Messages
1,834
Reaction score
4,642
First Language
No
Primarily Uses
N/A
To disable menu: Use the "Change Menu Access" (in event commands tab 3) command and change it to "Disable" before the player have control of the main character. Anything before that can work.

To disable title screen: Just use a script to skip the title screen. Here is one (click on link after "Skip Title:").

About the scriptline thing, I don't know about that, sorry :(
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,098
Reaction score
13,704
First Language
English
Primarily Uses
RMMV
I've moved this thread to JS/Plugin Support. Please be sure to post your threads in the correct forum next time. Thank you.
 

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

Latest Threads

Latest Profile Posts

People3_5 and People3_8 added!

so hopefully tomorrow i get to go home from the hospital i've been here for 5 days already and it's driving me mad. I miss my family like crazy but at least I get to use my own toiletries and my own clothes. My mom is coming to visit soon i can't wait to see her cause i miss her the most. :kaojoy:
Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.

Forum statistics

Threads
105,868
Messages
1,017,081
Members
137,582
Latest member
Spartacraft
Top