Entity/SnatchModelInstance

From Garry's Mod
(Difference between revisions)
Jump to: navigation, search
Line 1: Line 1:
 
{{Func
 
{{Func
|Description={{NextUpdate}}Moves the model instance from this entity to another. An example use case is moving a player's playermodel to a ragdoll while preserving decals. Note that the model instance cannot exist on two entities at once, and will be removed from the source entity.
+
|Description=Moves the model instance from the source entity to this entity. This can be used to transfer decals that have been applied on one entity to another.
 +
 
 +
Both entities must have the same model.
 +
 
 +
{{NextUpdate}}
 
|Realm=Shared
 
|Realm=Shared
 
|IsClass=Yes
 
|IsClass=Yes
Line 6: Line 10:
 
{{Arg
 
{{Arg
 
|type=Entity
 
|type=Entity
|name=toEntity
+
|name=srcEntity
|desc=Entity to move the model instance to.
+
|desc=Entity to move the model instance from.
 +
}}
 +
{{Ret
 +
|type=boolean
 +
|desc=success
 
}}
 
}}

Revision as of 03:36, 26 March 2016

 Entity:SnatchModelInstance( )

Description

Moves the model instance from the source entity to this entity. This can be used to transfer decals that have been applied on one entity to another.

Both entities must have the same model.


Next Update Change

This feature is only available in the next update.

Arguments

Entity srcEntity

Entity to move the model instance from.

Returns

boolean

success
Personal tools
Navigation