PlayerDeath not woking

So i have this simple code:
[lua]
function DeathNoticeWithUniqueName( victim, inflictor, attacker )
victim:SendLua([[Derma_Message( “You are currently dead”, “Death Notice”, “OK” )]])
end
hook.Add(“PlayerDeath”, “DeathNoticeWithUniqueName”, DeathNoticeWithUniqueName)
[/lua]
and the hook is not running when i suicide

It’s working for me
Can you check if you are running this on serverside and not on clientside?

Thank you, changed it to
[lua]
if SERVER then
function DeathNoticeWithUniqueName( victim, inflictor, attacker )
victim:SendLua([[Derma_Message( “You are currently dead”, “Death Notice”, “OK” )]])
end
hook.Add(“PlayerDeath”, “DeathNoticeWithUniqueName”, DeathNoticeWithUniqueName)
end
[/lua] and its working perfectly now!