ID:171694
 
I want to make a click proc where you click on a mob (npc) and it will desplay its stats and the verbs the troop has, which are the commands you give him.

mob
Soldier
var/Life = 30
var/Magic = 0
var/Attack = 10
var/Defence = 5
var/Speed = 2
Stat()
statpanel("Soldier's Stats")
stat("Life:", "[src.Life]")
stat("Magic:", "[src.Magic]")
stat("Attack:", "[src.Attack]")
stat("Defence:", "[src.Defence]")
stat("Speed:", "[src.Speed]")
that is the code for one of the troops, can someone please help me make the proc. (I didnt put in the commands he has yet)
Considering your code is correct:

mob
Soldier
var/Life = 30
var/Magic = 0
var/Attack = 10
var/Defence = 5
var/Speed = 2
Stat()
statpanel("Soldier's Stats")
stat("Life:", "[src.Life]")
stat("Magic:", "[src.Magic]")
stat("Attack:", "[src.Attack]")
stat("Defence:", "[src.Defence]")
stat("Speed:", "[src.Speed]")
Click()
usr << "Life: [src.Life]"
usr << "Magic: [src.Magic]"
usr << "Attack: [src.Attack]"
usr << "Defence: [src.Defence]"
usr << "Speed: [src.Speed]"


That should display stats i think.