Player Killed

Ok so i been working on this. Im finish with everything else then this :


hook.Add( "PlayerDeath", "ScoreStreaksGiveScore", function ( killer, victim )
local _Score = killer:GetNWInt( "SCORE" )
	if ( killer:GetUserGroup( ) == "user" ) then
			killer:SetNWInt( "SCORE", Scoreperkill);
			elseif ( table.HasValue ( _VIPGroups, killer:GetUserGroup( ) ) || killer:IsAdmin( ) || killer:IsSuperAdmin( ) ) then
			killer:SetNWInt( "SCORE", VIPScoreperkill );
end
end)

It works but a other hook like if a player gets killed then run the function. Is that possible. I did look at Gmod wiki and maurits but couldnt find anything.

What do you mean with if a player gets killed? That’s what that hook does.

Yes but it only works IF i die. It want it to run then the victim dies

Why can’t you google it yourself?
http://wiki.garrysmod.com/page/GM/PlayerDeath

You have the arguments wrong.

This seems to be a common theme today, this is the third time I’ve seen someone with wrong arguments for PlayerDeath. Is there a page somewhere that’s showing them the wrong arguments?

Then learn to look through it. It’s not so damn hard. People will eventually stop giving you links, and you’ll have to use the wiki.