ID:270512
 
I'm not sure if thats the right thing to call it, but I was wondering how i would make it so anyone under level 10 would get crappy stat boosts, like +2 on strength, but people over level 10 to about 20 would get +7 or soemthing. would i be forced to do this?
mob
proc
Levelup()
if(src.level=1)
Level1_statboost()
if(src.level=2)
Level2_statboost()

Something along the lines liek that, i know that wasn't perfect or even good, but i was just trying to get the whole calling procs idea out there. If you have an idea, or know exactly what im talking about and know how to do it, please reply on how to make these "pre-defined"-like levels. Thank you.

If you can't help me with the above part, could you atleast help me with the 4th adn 6th part of the code? im sure the
if(src.level=2)
thing wouldnt work, so could ya help me with that thing? vars woulld have to be involved.. maybe
proc/levelup(mob/m)
++m.level
if(m.level <= 10)
crappy_statboost(m)
else
good_statboost(m)
proc/crappy_statboost(mob/m)
m.str += 2
m.speed += 2
m.luck += 1
proc/good_statboost(mob/m)
m.str += 7
m.speed += 10
m.luck += 2


See how that works?
In response to PirateHead
haha yeaaaaaaah thanks man! now im :)
In response to Oblivon_2
Why not upgrade it?

proc/levelup(mob/m)
++level
if(m.level>=10)
str+=3;agi+=4;int+=5
str+=2;agi+=2;int+=2
In response to DivineO'peanut
That block isn't as readable, for me at least. I like to sacrafice a little space for readability, especially when helping new BYOND users.