mob
AI
icon = 'mob.dmi'
proc
checkspeed(obj/weapon/O in oview(1))
O.sleep = O.speed - O.delay
if(O.sleep < 0)
O.sleep = 0
sleep(O.sleep)
kill()
kill(mob/M in oview(),obj/weapon/O in oview(1))
M.health -= O.damage
checkdead(M)
checkdead(mob/M)
if(M.health < 1)
M << "BANG! You're dead!"
usr << "BANG! You kill [M]!"
usr.kills ++
else
..()
and here's my error:
runtime error: Cannot read null.speed
proc name: checkspeed (/proc/checkspeed)
usr: Dragon of Ice (/mob)
src: null
call stack:
checkspeed(null)
Machine Gun (/obj/weapon/gun/Machine_Gun): shoot()
so what is the problem?
No put usr in procs. Ungh.