I'm very new to RPG Maker, just started 2 days ago.
For my game, I want to make NPCs that give you the option to change your class if you meet the level requirements (simple enough, I know how to do that bit). But what if the player decides they don't like their new class and wants to change back to their old one? Is there a way I can make them whatever level they were before they switched to the new class?
I'm not sure if my explanation made sense, so here's an example of what I want:
Lvl 23 Swordsman decides to become Lvl 20 Hunter
Hunter doesn't impress the player
Lvl 20 Hunter switches back to Lvl 23 Swordsman.
I know I can use events to change the player's level, but I only know how to make them specific levels. I wouldn't want someone who got Swordsman to lvl 50 to have to start over from, say, lvl 10 just because they wanted to try a different class which they ended up not liking.
The best way to make the game remember anything is through variables and switches. Switches will not help in your situation as they only 'remember' if something is "on" or "off"/"true" or "false" kind of logic. But variables store numerical information which allows math to be performed on them very easily. Now...my caveat here is that I am deep into my first game which technically does not have true 'classes' except for some of the enemies. But the player's character and potential party members (this game is essentially a solo mission with some characters possibly joining the party for a short time) have no specific classes assigned to them. So as far as programmatically using my thoughts here as far as how/when to store new level and use that variable when switching back to a previous class I would be of little help but perhaps with you having more experience with manipulating classes
you may be able to use what I am discussing. You may need someone else to chime in but I felt that I can answer the main question you asked in the thread title.
My basic idea would be to create a variable for the highest achieved level of each class of the character. So with your example I'd create a variable Max Swordsman Level and Max Hunter Level (obviously one for each class that you set up in your game). Then as a character achieves a new level
in a class you'd create an event which increments that classes Max Level by one. So the game would retain what level you the character reached in each class. Then this variable can be accessed when switching back to a previous class. Without having done this I just assumed that the engine might
handle the class levels but since you state that this is not the case then I would suggest something like this. Due to my unfamiliarity with using/switching character classes I cannot tell you the best time/way to increment the variable and how to retrieve it to be used when switching to a previous class. But since no one else had answered yet when I saw this thread I'd hoped that this little bit of info might give you a better idea of an approach since you have at least a bit more familiarity than I do with class manipulation and may be some food for thought until someone offers a more knowledgeable solution.
Good luck!
I believed that the engine had core options to allow this behavior when reverting back to a previous class but I haven't worked with it yet to be certain. I figured that my answer would at least give additional info regarding switches/variables being how the engine/game "remembers" data. But I am glad to see your response as I am sure that I will implement classes in a game I develop in the future.
It's also worth noting that if you don't retain exp, it stays at the same value. So changing from one class to another, gaining some levels, then going back to the original will put you back at the original class's level if you don't check the box.
I've got it now, everything is working exactly how I want it to!
I didn't know what I was describing was already built into RPG Maker, but that saves me a lot of trouble haha
Just noticed I made a typo, I meant the "Change Class" command, but it seems you've got it sorted now. 🙂