Advertisement

RPG Mathematics: HP and MP equations

Started by June 01, 2003 03:26 PM
10 comments, last by hogosha 21 years, 8 months ago
Ok, i was sitting around today and the equations for this popped into my head. Ok, for this to make sense you should have taken geometry or algebra 2. ok first off you need to decided a few things. the list of things to decide are these: Max HP Min HP How many levels Ok, for example lets say you wanted a max hp of 9999, min hp of 100, and 100 levels. you need to first set up your ratio which is going to be (maxhp-minhp)/levels . you need to subtract the min hp becuase that will make your angle wrong, so you need to re-add that back in when you go to actually calculate your hp. but next you need to do the inverse tangent of your ratio. that will give you the angle 89.4212 degress. or just 89 degrees. but now you take that and use this equation: hp= (tan(89.4212)*level)+100; this would give you a good algorithm for your rpg. to make this for mp, simply change the hp to your mp min and max. simple as that. enjoy! Brought to you by Hogosha < http://www.hforces.com >
What on earth are you banging on about?
Advertisement
I''d just have all stats be exponential and then use logs to figure out the factor between each level.
delete this;
it''s another way of figuring out max hp, by using a triangle. the highest point of the triangle being your highest hp possible. the width being your level. you can go about it anyway that you wish. but this is a rather simple way that if you think about it, doesn''t require that much work and is quick.
Usually HP is dependent on some other stats too, like constitution or endurance, as well as level. Also, in FF3 for example, you could equip espers that gave bonuses(such as +HP) when you leveled up. I thought that was quite cool for tuning characters.
yeah, but thats where the angle is transformed. if you take this basic a step further to where it recalculates the angle, then you have this change do to stats. i''m just posting this as a step, because i sat for a few days figuring out the best basic way that doesn''t require a lot of work.

Higher Forces
Advertisement
It all sounds needlesly complicated to me. Are you just trying to show off?
no,it''s really simple. 2 equations is all you need. one to figure out your angle. and then from there your another to use your angle.
I''d prefer to use a logistic equation for stat growth. I''d set it up so that stat growth accelerates slightly in the early game, but is much slower in the late game.
Hey, guys, hogosha just registered, let''s be a little nicer to him and not scare him away. I think what he is trying to do is use the shape of the inverse tangent graph to slow down the accumulation of HP, and the post was just a bit too convoluted.
You know what I never noticed before?

This topic is closed to new replies.

Advertisement