ID:142505
 
Code:
runtime error: Cannot read null.name
proc name: deathcheck (/mob/proc/deathcheck)
source file: Battlesystem.dm,447
usr: Matt (/mob)
src: Matt (/mob)
call stack:
Matt (/mob): deathcheck(null)
Matt (/mob): Bump(null)

Sakon//Mob Coding
name = "Sakon (NPC)"
icon = 'icons/enemies/Sakon.dmi'
atkstr = 50000
health = 10000
expgive= 50000
exp = 5000
village="Sound Org 5"
level= 1000
Def = 1000
speed= 10000

mob/Bump(mob/src)
if(src.level<=5)
return
else if(usr.inchidori == 1)//Chidori Coding
var/Damage = round(usr.chakra)
if(Damage <= 0)
Damage = 1
src.health -= Damage
usr.overlays-= 'chidori.dmi'
usr.chidorihits+=1
usr.chidoricharge=0
usr.sexy=0
usr.loc = locate(src.x,src.y,src.z)
usr.inchidori=0
usr.deathcheck(src)
else
src.health -= Damage
usr.loc = locate(src.x,src.y,src.z)
usr.overlays-= 'chidori.dmi'
usr.chidorihits+=1
usr.chidoricharge=0
usr.inchidori=0
usr.sexy=0
usr.deathcheck(src)


Problem description:
Well...I've been having this problem for a while now, and
yes, I've made sure that the Mob Being hit has a Name...
it would be kinda pointless if it didnt. Anyways, the problem is when I use a Jutsu Such as Chidori (a Bump=Damage type of Jutsu) it pops up this error

1) Don't use usr in procs.

2) Don't name variables src, because (in this case) src is what you should be using instead of usr.

3) Read the damn error message. It's pretty clear. You're calling Bump (because this would never happen without you calling it yourself) with a null argument that doesn't exist. Therefore, error. In fact, you shouldn't even be calling Bump() yourself at all.