Gain Stats on Level Up

Mr. Trivel

Glasses
Veteran
Joined
Jun 9, 2014
Messages
284
Reaction score
467
First Language
Lithuanian
Primarily Uses
Author: Mr. Trivel


Name: Gain Stats on Level Up


Created: 2016-03-15


Version: 1.1




 


What does it do?


Actors gain stats on level up depending on their class.


 


Screenshots:


It's just numbers.


 


How to use?





All stats go into class note field:



<STAT>


formula


</STAT>


 


Stats:


MHP, MMP, ATK, DEF, MAT, MDF, AGI, LUK


v = variables


a = actor


 


Examples:


<ATK>


v[10];


</ATK>


<DEF>


Math.randomInt(5);


</DEF>


<LUK>


-1


</LUK>







 


Plugin: <Link: Github>


How to download the Plugin: Click the link above, there will be a button named Raw, press Right Click -> Save As.


 


Terms of Use:


Don't remove the header or claim that you wrote this plugin.


Credit Mr. Trivel if using this plugin in your project.


Free for commercial and non-commercial projects.
 
Last edited by a moderator:

Maliki79

Veteran
Veteran
Joined
Mar 13, 2012
Messages
739
Reaction score
318
First Language
English
Primarily Uses
N/A
Cool.  If you could have this usable with equips as well, this would be awesome!
 

Mr. Trivel

Glasses
Veteran
Joined
Jun 9, 2014
Messages
284
Reaction score
467
First Language
Lithuanian
Primarily Uses
@Maliki79,


As in, when actor has some equipment equipped - he gains more stats at level up?
 

Henryetha

Veteran
Veteran
Joined
Jan 14, 2016
Messages
388
Reaction score
206
First Language
german
Primarily Uses
Would be cool, if the player could choose which stat to lvl up ^^
 

lokirafael

Veteran
Veteran
Joined
Jun 25, 2012
Messages
152
Reaction score
78
First Language
Portuguese
Primarily Uses
RMMV
Can I use any valid condition? I was thinking in make a param system based on Fire Emblem. I will need to look up, but the logic would be.


<STAT>


if STAT < X then


Math.randomInt(y);


else


0


</STAT>
 
Last edited by a moderator:

Mr. Trivel

Glasses
Veteran
Joined
Jun 9, 2014
Messages
284
Reaction score
467
First Language
Lithuanian
Primarily Uses
@lokirafael,


Yes, multi line conditions work just fine. Example to yours:


<LUK>
if (this.luk < 20)
Math.randomInt(3)+1;
else
0
</LUK>


@Henryetha,


That'd be a different plugin for that.


@Maliki79,


You could just extend condition to accommodate that, even though it'd probably be kind of a mess.


Version 1.1


 - Fixed crash with some multi-line stat evaluations.
 

Forthright

Veteran
Veteran
Joined
Mar 9, 2016
Messages
60
Reaction score
10
First Language
English
Primarily Uses
Is there anyway to modify the code to pull information from Bobstah's CustomStat Plugin as well.  I'm using it to define stats like Str, Dex, Vit and such.  I'm using those to calculate my base parameters like mhp, mmp. and so on.   So far, no script I tried seems to pull these parameters.  I'm not sure if I am unsure how they are injected or if I am making a mistake, but I lack the skills to make the changes to implement it myself.  Any help would be greatly appreciated.  I have pasted a link to Bobstah's CustomStats plugin.


https://www.dropbox.com/s/9ec4iwp2qvezibu/BOB_CustomStats.js?dl=0
 

Mr. Trivel

Glasses
Veteran
Joined
Jun 9, 2014
Messages
284
Reaction score
467
First Language
Lithuanian
Primarily Uses
@Forthright,


You can cheat the system since my stat gains are being eval'd on level up.


Example:


<ATK>
this.customStats.spower.modifier += 10;
0
</ATK>


Gives 10 spower stat from BOB's Custom Stats, but gives 0 extra ATK, since 0 is the last number.
 
Last edited by a moderator:

Mega Man Volnutt

Mega Man Volnutt
Veteran
Joined
Dec 7, 2015
Messages
397
Reaction score
124
First Language
English
Primarily Uses
N/A
Would be cool, if the player could choose which stat to lvl up ^^
I remember seeing this as a plugin in RPG VXACE somewhere. A couple games used it.
 
Last edited by a moderator:

BloodletterQ

Chaotic Neutral Assassin
Veteran
Joined
Aug 15, 2012
Messages
1,526
Reaction score
1,171
First Language
English
Primarily Uses
N/A
Do you think it can be done Fire Emblem style where a stat can go up depending on how much higher it is than an interger?
 

Mr. Trivel

Glasses
Veteran
Joined
Jun 9, 2014
Messages
284
Reaction score
467
First Language
Lithuanian
Primarily Uses
@BloodletterQ,


Since what's written is getting evaluated on level up, as long as you write the logic in the level up note tag, it'll evaluate it. So, yes.
 

Forthright

Veteran
Veteran
Joined
Mar 9, 2016
Messages
60
Reaction score
10
First Language
English
Primarily Uses
Thank you for your idea.  It worked like a charm.  Now, is there anything in particular that I would need to do if I wanted this to re-evaluate on multiple level up events.  So it picks a random interger for each level gained.  I found out that my math was wrong.  I needed to round as well as use random so it rounded up or down based on where it landed.
 
Last edited by a moderator:

Mr. Trivel

Glasses
Veteran
Joined
Jun 9, 2014
Messages
284
Reaction score
467
First Language
Lithuanian
Primarily Uses
@Forthright,


It evaluates a code on every single changed level. So if you jumped from level 3 to level 5 (2 levels), it'll be evaluated twice.
 

dombo813

Veteran
Veteran
Joined
May 3, 2014
Messages
42
Reaction score
3
First Language
English
Primarily Uses
A little late to the party, but would it be possible to have stat gains that can be placed in the Actor box too (so say, Harold always gains +1 ATK on leveling, regardless of his class)?
 

Sissel Cabanela

Veteran
Veteran
Joined
Mar 28, 2016
Messages
104
Reaction score
19
First Language
English
Primarily Uses
I would like to bump the topic to bring attention again to Dombo's question of being able to put notetags in the Actor box to further increase unique stat gains.
 

Tedrainbow

Villager
Member
Joined
Oct 28, 2014
Messages
13
Reaction score
0
First Language
French
Primarily Uses
RMMV
Hello Mr. Trivel
Is this formula correct?

<MHP>
if (this.level < 25)
Math.randomInt(5)+5;
</MHP>

<MHP>
if (this.level < 55)
Math.randomInt(10)+10;
</MHP>

<MHP>
if (this.level < 90)
Math.randomInt(15)+15;
</MHP>

<MHP>
if (this.level < 130)
Math.randomInt(20)+20;
</MHP>

<MHP>
if (this.level < 175)
Math.randomInt(25)+25;
</MHP>

<MHP>
if (this.level < 225)
Math.randomInt(30)+30;
</MHP>

<MHP>
if (this.level < 255)
Math.randomInt(35)+35;
</MHP>

To create pokemon game with a system of dragon quest monster joker.
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

I've been debating on this as the title screen for a while now...
Ami
--- Dialog Filter ---

Gunner: Yo! my ****** friend?
Hero: Uhh,what happen with your mouth?
Gunner: Huh? what ****** happen with my mouth? i just speech as usual.
Hero: But,your mouth are like the garbage!
Gunner: Hey,what the **** are you say? you want the piece of **** with my ****** Gun!
(Meanwhile,The Dialog Filter In The Option Is Off)
Demo for Maze of the Lost MZ released. I would appreciate any and all feedback and constructive criticism. If you like Dungeon Crawlers and JRPG's with a hint of Metroidvania and Shadowgate/Uninvited you might like it. https://forums.rpgmakerweb.com/index.php?threads/maze-of-the-lost-mz-demo-port-from-mv.127971/
Well, here it is, colored. :kaoslp:

Forum statistics

Threads
103,389
Messages
998,961
Members
134,907
Latest member
zelda3469
Top