Prop dynamic: Difference between revisions
Jump to navigation
Jump to search
Tip:If your model is never going to move and/or requires detailed lighting, consider using prop_static (which is cheaper).
Note:To enforce consistency, models with embedded physics data cannot by default be used by prop_dynamic. Use the Hammer model browser's Info tab to check for support.
TomEdwards (talk | contribs) (cleanup) |
TomEdwards (talk | contribs) mNo edit summary |
||
Line 5: | Line 5: | ||
Dynamic props receive "point lighting": one value, re-sampled every frame, is applied to the entire model. [[point_spotlight]]s (per-vertex) and [[env_projectedtexture]]s (per-pixel) can overcome this. | Dynamic props receive "point lighting": one value, re-sampled every frame, is applied to the entire model. [[point_spotlight]]s (per-vertex) and [[env_projectedtexture]]s (per-pixel) can overcome this. | ||
{{tip|If your model is never going to move and/or requires detailed lighting, consider using [[prop_static]] (which is [[ | {{tip|If your model is never going to move and/or requires detailed lighting, consider using [[prop_static]] (which is [[cheap]]er).}} | ||
{{note|To enforce consistency, models with [[prop_data|embedded physics data]] cannot by default be used by prop_dynamic. Use the Hammer model browser's [[:Image:Model_info.gif|Info tab]] to check for support.}} | {{note|To enforce consistency, models with [[prop_data|embedded physics data]] cannot by default be used by prop_dynamic. Use the Hammer model browser's [[:Image:Model_info.gif|Info tab]] to check for support.}} | ||
Line 11: | Line 11: | ||
== Uses == | == Uses == | ||
* '''Buttons''' can be created by enveloping a prop_dynamic | * '''Buttons''' can be created by enveloping a prop_dynamic inside an invisible [[func_button]] brush, then using the ''SetAnimation'' input to play a switching animation. | ||
* Similarly, '''levers''' can be created by enveloping a prop_dynamic | * Similarly, '''levers''' can be created by enveloping a prop_dynamic inside a [[func_rot_button]] (or [[momentary_rot_button]]) brush. No animation needed this time - the brush will rotate the prop by itself. | ||
* A prop_dynamic can be configured to '''break apart''' after receiving damage. {{bug|Health set [[prop_data|inside the model]] will override health set in Hammer!}} | * A prop_dynamic can be configured to '''break apart''' after receiving damage. {{bug|Health set [[prop_data|inside the model]] will override health set in Hammer!}} | ||
Revision as of 04:43, 18 September 2009
Template:Base point It is used to add an arbitrary model to the world that can animate itself and move between positions.
A prop_dynamic cannot move around on its own however: it must be parented to an entity that can. For instance, to create a functional Razortrain you would parent the various engines and carriages, as prop_dynamic, to an invisible func_tracktrain brush entity.
Dynamic props receive "point lighting": one value, re-sampled every frame, is applied to the entire model. point_spotlights (per-vertex) and env_projectedtextures (per-pixel) can overcome this.


Uses
- Buttons can be created by enveloping a prop_dynamic inside an invisible func_button brush, then using the SetAnimation input to play a switching animation.
- Similarly, levers can be created by enveloping a prop_dynamic inside a func_rot_button (or momentary_rot_button) brush. No animation needed this time - the brush will rotate the prop by itself.
- A prop_dynamic can be configured to break apart after receiving damage.
Bug:Health set inside the model will override health set in Hammer! [todo tested in ?]