Actor Name change/restore

is there a way to store an actors name and then later "restore" that name if i change the persons name in game?

an example of this would be: you get a characters introduction and name him (simple enough), at some point down the line, you have to say your name is something else, so you change it (also simple), my question is; is there a way to change the name back to what you originally named the character?

this idea came from Breath of Fire 2, where the main character "takes" on the name of someone else and both the menu and save screens reflect this name, then later you get back your original name.

i know there are was around this like when referring to that person in text to use the "fake" name, but with what i have in mind, it would be better if i could do it the other way.
Easy enough using a couple script calls:

Code:
// to store the original name for later for actor #X
$gameActors.actor(X)._originalName = $gameActors.actor(X).name();

Code:
// to restore the name of actor #X
$gameActors.actor(X).setName($gameActors.actor(X)._originalName);
that worked perfectly
thanks a lot for the help 🙂

Original thread: https://forums.rpgmakerweb.com/threads/actor-name-change-restore.104781/