mob/proc
Levelup()
if(exp >= maxexp)
level ++
exp -= exp
maxexp *=1.1
src<<"You have gained a level!"
verb
Punch(Punchingbag in oview(1))
usr<<output("You hit the bag","system")
exp += 10
stamina += 4
Levelup()
Error:
Train.dm:13:error: exp: undefined var
Train.dm:14:error: stamina: undefined var
Train.dm:15:error: Levelup: undefined proc
Where it was defined
mob
var
title = "Hero"
rank = "C Class"
level = 1
exp = 0
maxexp = 5
money = 25000
tnl = 1500
strength = 50
power = 50
speed = 50
Hit_Bag = 0
defense = 50
stamina = 0
maxstamina = 100
Problem in words
Although the variables are obviously defined and work very well with other code they don't seem to register in the punching bag snip. I've tried using src.exp mob.exp and just plain old exp and non of the above work. I restarted the source, because sometimes errors occur and can only be fixed with a good reboot, however it also did not work. Any help would be appreciated.
Try mob/verb/Punch().