I am creating a roguelike rpg in rpg maker mv and I would like the ability to initialize a character after a dungeon run. However I don't want to have to make the play input their name every time. What script do I use to save a characters name into a variable and what do I use to change that variable into character name input?
Change a name into a variable and back again.
RPG Maker MV SupportUse Event Command Control Variables.
Operator is Set
Operand is Script
Script command is: $gameVariables[005]="Alice";
This command will store "Alice" in the variable with ID = 5.
Operator is Set
Operand is Script
Script command is: $gameVariables[005]="Alice";
This command will store "Alice" in the variable with ID = 5.
Store actor 1's name in a variable:
- Control Variables > Set > Script:
Code:$gameActors.actor(1).name()
- Script:
Code:$gameActors.actor(1).setName($gameVariables.value(5));
Thank you caethyril you fixed my problem.
This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.
Original thread: https://forums.rpgmakerweb.com/threads/change-a-name-into-a-variable-and-back-again.109752/