Player onkill

From Fortress Forever Wiki
Jump to navigationJump to search


player_onkill( player )

This function is called whenever a player uses the kill command. Return true or false to allow/disallow.

Inputs

player(CFFPlayer) The player who's trying to off himself

Examples

function player_onkill( player )
	-- Don't let blue hunted suicide.
	if player:GetTeamId() == Team.kBlue then
		return false
	end
	return true
end