Entity/SetTransmitWithParent

From Garry's Mod
(Difference between revisions)
Jump to: navigation, search
(Created page with "{{Func |Name=SetTransmitWithParent |Parent=Entity |Description=When this flag is set the entity will only transmit to the player when its parent is transmitted. This is use...")
 
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
{{Func
 
{{Func
|Name=SetTransmitWithParent
 
|Parent=Entity
 
 
|Description=When this flag is set the entity will only transmit to the player when its parent is transmitted. This is useful for things like viewmodel attachments since without this flag they will transmit to everyone (and cause the viewmodels to transmit to everyone too).
 
|Description=When this flag is set the entity will only transmit to the player when its parent is transmitted. This is useful for things like viewmodel attachments since without this flag they will transmit to everyone (and cause the viewmodels to transmit to everyone too).
|Realm=
+
 
 +
{{Note|In the case of scripted entities, this will override {{HookFunction|ENTITY|UpdateTransmitState}}}}
 +
|Realm=Shared
 
|IsClass=Yes
 
|IsClass=Yes
 +
|Name=SetTransmitWithParent
 +
|Parent=Entity
 
|File_Name=src/garrysmod/Objects/lua_entity.cpp
 
|File_Name=src/garrysmod/Objects/lua_entity.cpp
 
|File_Line=5390
 
|File_Line=5390
 
}}
 
}}
 
{{Arg
 
{{Arg
|type=bool
+
|type=boolean
 
|name=onoff
 
|name=onoff
 
|desc=Will set the TransmitWithParent flag on or off
 
|desc=Will set the TransmitWithParent flag on or off
 
}}
 
}}

Latest revision as of 08:10, 28 April 2016

 Entity:SetTransmitWithParent( )

Description

When this flag is set the entity will only transmit to the player when its parent is transmitted. This is useful for things like viewmodel attachments since without this flag they will transmit to everyone (and cause the viewmodels to transmit to everyone too).

NOTE

In the case of scripted entities, this will override ENTITY:UpdateTransmitState

Arguments

boolean onoff

Will set the TransmitWithParent flag on or off
Personal tools
Navigation