How do I change someone's class in the game?

If anyone wants to know the context: a character starts as a certain class (let's say thief). After you progressed in the game at a certain point, he switches classes to another one (assassin).

Anyone know how?
there is an event command for changing classes
Note - if you use the event command to change classes, your character will lose all their EXP (if you switch back and forth between the classes, each one will retain its own EXP but it won't transfer over to the new class).


If you want them to keep their EXP when they change, you'll have to use a script call instead:

$game_actors[actor_id].change_class(new_class_id, true)
It's exactly the same script call that the event command uses, but the event command doesn't pass the keep_exp parameter, so it defaults to false. Something makes me think there actually should have been a checkbox on the command so you could say whether or not to keep the EXP, as there's nothing else that calls this method.

Original thread: https://forums.rpgmakerweb.com/threads/how-do-i-change-someones-class-in-the-game.25357/