I have been working on a securtiy system and other stuff for my game but i cant figure out how to fix my codes.Here are my codes:
Security System:
turf/security_system
icon = 'security.dmi'
turf/security_system
icon = 'security.dmi'
verb
shock(mob/M in world)
var/damage = 2
M << "The floor shocks you?!" M << "[damage] damage!"
M.HP -= damage
M.DeathCheck()
if(M in oview(5))
else
usr << "" //The security system does not shock you unless u click a shock verb but when i take out the word verb i get something like "var is not being used"
And my other code is a gun that I managed to mess up on accident this is the code:
obj/rifle
icon = 'rifle.dmi'
verb
shoot(mob/M in world)
var/damage = 2
usr << "shoot at [M]!"
usr << "[damage] damage!"
M << "[usr] attacks you!"
M << "[damage] damage!"
M.HP -= damage
M.DeathCheck()
if(M in oview(5))
else
usr << "Out of range!"
//for some reason the when u click the shoot verb it tells u u shot yourself and then it tells you the gun shot you.
please write somin back if u can help me fix the codes.
ID:149629
Mar 23 2002, 4:46 pm
|
|
Mar 23 2002, 4:54 pm
|
|
I dont know how to help but if u make it verb well then its gonna be a verb
|
In response to Strange Kidd
|
|
For the shock use Bump()
|
In response to Strange Kidd
|
|
thanks
|