Phys convert: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(Filled in "Model Swap Entity" keyvalue and questioned the bug about where the converted object may spawn.)
Line 3: Line 3:
== Keyvalues ==
== Keyvalues ==
{{KV|Entity to convert|target_destination|Name of the entity that will be converted to a physics object when the <code>ConvertTarget</code> input is fired.}}
{{KV|Entity to convert|target_destination|Name of the entity that will be converted to a physics object when the <code>ConvertTarget</code> input is fired.}}
{{KV|Model Swap Entity|string}}
{{KV|Model Swap Entity|string|Name of the entity whose model will replace the model of the converted object when the conversion takes place. (this is optional) {{tip|Use this when the converted object has a separate model used for physics props.}}}}
{{KV|Mass Override|float|Sets the mass when the object(s) are converted (0 means auto-calculate)}}
{{KV|Mass Override|float|Sets the mass when the object(s) are converted (0 means auto-calculate)}}
{{KV Targetname}}
{{KV Targetname}}
Line 13: Line 13:
== Inputs ==
== Inputs ==
{{IO|ConvertTarget|Converts this entity's target to a physically simulated object.}}
{{IO|ConvertTarget|Converts this entity's target to a physically simulated object.}}
{{bug|The new prop_physics object will spawn at the original position of the model regardles of whether it was moved somewhere else (example: it´s parented to another entity).}}
{{bug|The new prop_physics object will spawn at the original position of the model regardles of whether it was moved somewhere else (example: it´s parented to another entity). {{todo|Was this fixed in Source 2013?}}}}
{{I Targetname}}
{{I Targetname}}



Revision as of 12:29, 29 June 2017

Template:Base point It turns an arbitrary entity into a physically simulated entity. i.e. brush entities will behave like func_physbox, model entities behave like prop_physics.

Keyvalues

Entity to convert ([todo internal name (i)]) <targetname>
Name of the entity that will be converted to a physics object when the ConvertTarget input is fired.
Model Swap Entity ([todo internal name (i)]) <string>
Name of the entity whose model will replace the model of the converted object when the conversion takes place. (this is optional)
Tip.pngTip:Use this when the converted object has a separate model used for physics props.
Mass Override ([todo internal name (i)]) <float>
Sets the mass when the object(s) are converted (0 means auto-calculate)
Name (targetname) <string>[ Edit ]
The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g. parentname or target).
Also displayed in Hammer's 2D views and Entity Report.
See also:  Generic Keyvalues, Inputs and Outputs available to all entities

Flags

  • 1 : Convert Asleep
  • 2 : Convert As Debris

Inputs

ConvertTarget
Converts this entity's target to a physically simulated object.
Icon-Bug.pngBug:The new prop_physics object will spawn at the original position of the model regardles of whether it was moved somewhere else (example: it´s parented to another entity).
Todo: Was this fixed in Source 2013?
  [todo tested in ?]


Outputs

OnConvert
Fires after the conversion has taken place.


See also