I can figure it out by when i compile my code, it says
that usr.equip is a bad var. Here's my code:
verb
Equip()
set src in usr
if(usr.equip >= 1)
usr << "[src.name] is allready equiped" //instead of typing the name just copy and paste this into where is needed.src.name will show Sword is allready equiped!
else
usr.Attack += 6
usr.equip += 1
suffix += "{-Equiped-}" //Makes the suffix appear beside it
usr << "[src.name] is now equiped"
Un_Equip()
if(usr.equip == 0)
usr << "You don't have anything equiped"
else
usr.Attack -= 6
usr.equip = 0
suffix = "" //Note*This only works if you have 1 suffix
usr << "Unequiped [src.name]"
ID:179815
Oct 29 2001, 6:33 pm
|
|
In response to Nadrew
|
|
o opps you have to get it defined, well what should i put and where?
|
Tazor07 wrote:
I can figure it out by when i compile my code, it says You cant put usr.anything inside an if statement. You can't have any uhhh... whatever theyre called that go before a var inside an if statement. If you made the verb a mob then it will automaticly affect the user. I think. |
In response to Tazor07
|
|
usr and src belong to a mob so you have to define the var under the mobs vars:
mob That defined equiped under mob. |
In response to Nadrew
|
|
ok thanks i think i got it fixed
|
In response to BurningIce
|
|
BurningIce wrote:
You cant put usr.anything inside an if statement. You can't have any uhhh... whatever theyre called that go before a var inside an if statement. If you made the verb a mob then it will automaticly affect the user. I think. Burning Ice, please don't try to help anyone anymore. You have absolutely no idea what's going on here. |
I don't see where you have usr.equiped defined.