Sell(var/obj/Equipment/O in usr)
set src in oview(2)
set category = null
if(usr.sell == 0)
switch(alert("[src]: Are you sure you want to sell [O.name] for [O.value] PokeDollars?","Selling","Yes","No"))
if("Yes")
if(istype(O,/obj/Equipment))
if(O.equiped == 0)
usr.PokeDollars += O.value
del(O)
usr.sell = 1
sleep(7)
usr.sell = 0
else
usr << "<B>You need to unequip [O.name] first!"
return
else
return
if("No")
return
if(usr.sell == 1)
usr << "<font color = white><font face = 'Comic Sans MS'> Selling items will not work at this speed, it will crash the server, so this has been programmed in to stop that from happening."
return
Thats the code I am using for my sell verb, anyway to fix the runtime error or block the macros, all help appreciated.
No.
Then indeed, you should fix your code instead of trying to work around the problem. Basically, you need to validate the variables (arguments) on the beginning of the verb, to see if they're still valid. For more info, use the forum search. Or I'll dig up some older posts later if you do need it.