- Feb 29, 2020
- Reaction score
- First Language
- Primarily Uses
When using the Select Item command script
$gameMessage.setItemChoice(varID, n);, how do I make the game wait for the selection to be made?
I've put the code in a Custom Apply Effect (I'm addicted to these), and the
console.log()command I put right after (to monitor the new value of the variable) displays 0 (the default value I set up) in the console immediately.
Here's the portion of code where it goes wrong. I'm supposed to process the value of variable number 20 right after that.
$gameVariables.setValue(20, 0); //the default value $gameMessage.add("selection"); //it displays along with the item choice window $gameMessage.setItemChoice(20, 3); //the user has to select a hidden item A $gameParty._interpreter.setWaitMode('message'); //I looked things up and this was supposed to work console.log($gameVariables.value(20)); //that's how it displays a 0 while the item choice window is still open
Note: it's only going to be executed in battle, nowhere else.
If you want the battle scene to wait on you, this could be super difficult if you are not familiar with it.
The battle flow is partially dependent on whether or not a certain window is open or not. As soon as one window closes, the battle process continues until the next window is open. It's very counter-intuitive, I had my fair share of frustration with the battle system.
That being said, I did a quick check to see if there is a simple "pause switch" for the battle scene.
This will probably freeze everything on screen, including your game message, but I think it's worth a shot.
Try setting the battle scene to inactive by using:
SceneManager._scene._active = false;
Then, once the item is chosen set it back to true.
Another possible way could be to go to the Scene_Battle.prototype.update Method and insert a condition for it
to pause the updating whenever you want. I don't know how familliar you are with the core code, let me know and I could help.
Is there any way I can make the texts and icons on the top bigger and the ones at the bottom smaller?
I know you can change the font in the setting, but that's for all the texts in the game and I'm not sure if I want to make it any lower. Just wanna change the text size in the menu.
You can't change that without coding. If you want some guidance on how to do that let me know.