Entity/SetPhysicsAttacker

From Garry's Mod
(Difference between revisions)
Jump to: navigation, search
(Added explanation for upcoming patch.)
Line 2: Line 2:
 
|Name=SetPhysicsAttacker
 
|Name=SetPhysicsAttacker
 
|Parent=Entity
 
|Parent=Entity
|Description=Sets the player who gets credit if this entity kills something with physics damage.
+
|Description=Sets the player who gets credit if this entity kills something with physics damage within the time limit.
 +
 
 +
'''NOTE''': This can only be called on props.
 
|Realm=Server
 
|Realm=Server
 
|IsClass=Yes
 
|IsClass=Yes
Line 10: Line 12:
 
|name=ent
 
|name=ent
 
|desc=Player who gets the kills. Setting this to a non-player entity will not work.
 
|desc=Player who gets the kills. Setting this to a non-player entity will not work.
 +
}}
 +
{{Arg
 +
|type=number
 +
|name=timeLimit
 +
|desc=Time in seconds until the entity forgets its physics attacker and prevents it from getting the kill credit.
 +
|default=5
 
}}
 
}}

Revision as of 09:05, 21 May 2014

 Entity:SetPhysicsAttacker( )

Description

Sets the player who gets credit if this entity kills something with physics damage within the time limit.

NOTE: This can only be called on props.

Arguments

Player ent

Player who gets the kills. Setting this to a non-player entity will not work.

Arguments

number timeLimit=5

Time in seconds until the entity forgets its physics attacker and prevents it from getting the kill credit.
Personal tools
Navigation