ID:261689
 
My login code consist of new /mob/blah. Then when i put in the statpanel, it says these errors...

Main.dm:68:error:HP:undefined var
Main.dm:68:error:Max_HP:undefined var
Main.dm:69:error:MP:undefined var
Main.dm:69:error:Max_MP:undefined var
Main.dm:70:error:Ammo:undefined var
Main.dm:70:error:Max_Ammo:undefined var

How can I make it so they find the vars in the /mob/blah's?
Remove the usr. before the variable.
In response to Garthor (#1)
But there is no usr. This is the code.....
mob
Stat()
stat("Your Stats:",src.desc)
stat(src)
stat("Your Name: ",name)
stat("Your Class: ",class)
stat("Your Gender: ",gender)
stat(" ","---------------------")
stat("Your HP: ","[HP] / [Max_HP]")
stat("Your MP: ","[MP] / [Max_MP]")
stat("Your Ammo: ","[Ammo] / [Max_Ammo]")
In response to Unknown Person (#2)
Oh well, too late, i changed the way... Ya don't need to post but if you do, it'll keep me from posting again if i had that trouble...
In response to Unknown Person (#3)
Well, Did you define the vars? If not then its probably a spelling error. remember. To define a var you should put somting like...
mob/blah
var
HP
MaxHp
MP
MaxMp


(the >'s are how many indents before the line incase you wanted to know.)
You dont have to make your vars like taht. Just make them like the ones in your stat panel.