C()
set hidden = 1
if(usr.resting == 0)
usr.resting = 1
while(usr.resting == 1)
usr.move = 0
spawn(20)
usr.hp += rand(2,10)
if(src.hp >= src.maxhp)
src.move = 1
src.hp = src.maxhp
src.resting = 0
if(usr.resting == 1)
usr.resting = 0
usr.move = 1
if(src.hp >= src.maxhp)
src.move = 1
src.hp = src.maxhp
src.resting = 0
Problem description:
I have a feeling I'm creating a loop and crashing it but I can't find out where the loop is. I set the C() verb ad the macro and it's a basic rest command. I want it to check if their hp is less than maxhp and if so, heal. And when they hit C again it stops even ig they aren't full.