Random stat distribution at level up

Well, I was playing Shining Force and I was wondering how I could go about making a random stat distribution like that game has at level up. If you haven't played it, when you level up, all of your stats increase by a rough range of 0-5. With this you can have some sucky level ups like 1 speed, and some awesome level ups like 5 Attack, 2 Defense, 3 Speed, 4 HP, and 5 MP. I've looked around and I can't seem to find anything about this on the forums. Does anyone have any ideas?
Well you could simply do it yourself by randomizing a variable (say 1 through 5), and then using that variable to 'change parameters', and choose the 'increase' option.


Of course, this has to happen when the player levels up (you can also check this with variables). Have you tried out the Variables Guide?
I'm still fairly new to VX Ace but I know how to use variables pretty well. It's just making it happen at level up that's the issue.
Run a common event (parallel process), and check to see if the player has leveled up by setting a variable to the player's level. To see if the player has leveled up, you must set a variable to 1 in the beginning of the game (this is a one-time event only). Then, have the common event check to see if that variable is lower than the player's current level (which means they leveled up). If yes, add the random stat distribution, and set the player's current level to the other variable so that the process can continue.


Add a 10 frame wait command in there so that it doesn't lag your game.
Celianna's solution will work okay, but you will have some quirks, such as needing extra eventing to detect if a character has leveled up multiple times, and only being able to run the event once the player is back on the map after a battle.  It's a good evented solution, so it will get the job done if you think through all the possibilities, but it's a bit clumsy and inefficient.

This kind of thing would be pretty easy to script from a functionality point of view.  You just alias the level_up method in Game_Actor to add lines like add_param(3, rand(6).to_i), which would add 0-5 DEF to the character when they level up.  If you don't do any scripting yourself, this is probably something that a scripter would be willing to make for you in RGSS Requests.
Sigh... People never look...

http://forums.rpgmakerweb.com/index.php?/topic/5701-random-param-gain-on-lvl-up/
Thanks, but I'm wanting to try my hand at a commercial game so I can't use your script.



Yeah...this only adjusts parameters based on what's set in the script and completely ignores the values set in your note tags, meaning, yes, I can make it so that my character's parameters advance randomly at level up, but all of the characters have to use the the same min max values.  Unless, this  <rpg: par_id, gain, min, max> isn't the right note tag.  Put whatever you want in the gain, min, and max spots.  It won't work.  It'll only read the par_id, and then plug in whatever's in the script default settings.  I wish I could find Tsukihime's Parameter Levels.  I've been looking for days.

Original thread: https://forums.rpgmakerweb.com/threads/random-stat-distribution-at-level-up.37497/