How can i make it where each npc gives a different amount of points in pointshop?

I tried OnNPCKilled but this gives me points for every npc i kill. I want points for specific npc deaths.

if ( ent:GetClass() == “specialNPC” ) then else end

i keep getting this error
attempt to index global ‘entity’ (a function value)

Here is my code
function GM:OnNPCKilled( victim, killer, weapon )
if ( Entity:GetClass() == “npc_zombie” ) then


hook.Add(“OnNPCKilled”, “GivePoints”, OnNPCKilled)

You are attempting to use an undefined variable. Entity should be victim.


holy dicks it works, thank you.