GM/PlayerSpray

From Garry's Mod
Revision as of 19:35, 20 February 2016 by Shendow (Talk | contribs)
Jump to: navigation, search
 GM:PlayerSpray( )

Contents

Description

Determines if the player can spray using the "impulse 201" console command.

Arguments

Player sprayer

The player who sprayed.

Returns

boolean

Return false to allow spraying, return true to prevent spraying.

Examples

Example

Makes so that only Admins can spray.

hook.Add( "PlayerSpray", "DisablePlayerSpray", function( ply )
	return !ply:IsAdmin()
end )


Personal tools
Navigation