Home > Tutorials > RPG Maker 2003 > Adaptive Leveling
Adaptive Leveling 
If you've played Elder Scrolls series, you probably know more or less what I mean. If you use stuff, it gets stronger. If you get hit alot of times, or use alot of magic, HP and MP also goes up. I guess it's more like Final Fantasy 2 Japanese (and the Saga series), than Elder Scrolls, but anyway...
You will need to do this for each party member, and have alot of variables and switches for each party member probably (although, possibly you can double up on some variables, if you can figure something out). Let's just do the basic one character for this.
So, anyway you will need about 8+ variables, 6 switches, and 6 common events.
Make a code to put inside the battle events.
Turn 1x:
If (Char1 is able to act)
Common Event: Hp Gain
Common Event: Mp Gain
If (Char1, Attack command)
Common Event: Str Gain
End
If (Char1, Defend command)
Common Event: Vit Gain
End
If (Char1, Magic command)
Common Event: Mag Gain
End
End
Alright, now in Hp Gain it should look like:
Variable Char1HP Set, Char1 HP
Variable Char1HP10% Set, Char1 HP
Variable Char1HP10% Divide 10
If Char1HP Less/Equal Char1HP10%
Switch (Hp Up) ON
Else
Switch (Hp Up) OFF
End
(the latter part is in case you heal before the end of the battle)
(do pretty much the same for Mp Gain)
The next three common events are like this:
Variable MagTrain +1
If Variable MagicTain Greater/Equal 30
Switch (Mag Up) ON
End
For Attack and Defend, in addition to the code above add in a random Agility boost since you're (in theory anyway) moving around more than while spellcasting.
Variable RandomNum 1-20
If RandomNum Greater/Equal 15
Switch (Agi Up) ON
End
All this however, doesn't really do anything.
You need another common event.
Make it Parallel Process, and have it ON all the time.
(Common Events do NOT call during battle, unless they are called as a call event, so it will activate AFTER battle)
Pretty simple, just have
If Char1 is in the party
If HP Up is ON
Change Stats: Max HP up (however much)
End
(same for pretty all these, you can also make a random number variable to this)
And that's it! Just repeat this code for each party member. Keep this simple, leave it a four member party.
|
|
Details
|
|
Tutorial:
|
Adaptive Leveling |
|
Date Listed:
|
Tue, 15 Feb 2011 21:06:38 -0500 |
|
Author:
|
bulmabriefs144
|
|
Total Hits:
|
2305 |
|
|