Suspended Object Trap: Difference between revisions
Nfpartridge (talk | contribs) (creation of initial tutorial) |
Nfpartridge (talk | contribs) m (polish and grammar/spelling) |
||
Line 1: | Line 1: | ||
[[Category:Level Design Tutorials]] | [[Category:Level Design Tutorials]] | ||
====Introduction==== | ====Introduction==== | ||
[[Image:Falling_object.jpg|frame| An example of what this tutorial will accomplish]] | |||
This tutorial explains the process of creating a trap consisting of a heavy object suspended by a dynamic rope which can then be triggered to fall with devastating effect. This is an advanced tutorial covering entity creation, parenting, I/O configuration, keyframe editing, and flag manipulation. Overall completion time is estimated at fourty-five minutes to one hour. | This tutorial explains the process of creating a trap consisting of a heavy object suspended by a dynamic rope which can then be triggered to fall with devastating effect. This is an advanced tutorial covering entity creation, parenting, I/O configuration, keyframe editing, and flag manipulation. Overall completion time is estimated at fourty-five minutes to one hour. | ||
Line 41: | Line 42: | ||
**set the '''Name''' keyvalue to : '''dynamic01_func_button''' | **set the '''Name''' keyvalue to : '''dynamic01_func_button''' | ||
As you can see, each entity has the prefix dynamicXX and a descriptive suffix. This is a useful naming system when you have several dynamic systems and need to keep them | As you can see, each entity has the prefix dynamicXX and a descriptive suffix. This is a useful naming system when you have several dynamic systems and need to keep them separate. | ||
=====Key Values for Rope Workaround:===== | =====Key Values for Rope Workaround:===== |
Revision as of 04:53, 12 September 2006
Introduction
This tutorial explains the process of creating a trap consisting of a heavy object suspended by a dynamic rope which can then be triggered to fall with devastating effect. This is an advanced tutorial covering entity creation, parenting, I/O configuration, keyframe editing, and flag manipulation. Overall completion time is estimated at fourty-five minutes to one hour.
The Source Hammer editor does not allow a user to directly attach an object to a rope. However, there is a workaround. The basic idea involves parenting the end of a rope to a secondary entity. This secondary entity is then used in conjunction with a few physics entities that measure the movement of the secondary entity and translate its movements back to the rope. We'll also be creating a trigger that will break the rope when it gets damaged causing the previously suspended object to crash down! Sounds complicated but don't worry, it'll make sense once it's done. Let's get started!
Entity Creation
- Create the following entities and brushes:
- move_rope
- keyframe_rope
- phys_lengthconstraint
- env_spark
- prop_physics_override or func_physbox
- logic_measure_movement
- a brush with the same or as-near-as-possible dimensions of the prop_physics_override or func_physbox
Entity Placement
- Place the following entities or brushes:
- Place the move_rope to where you'd like to anchor the rope.
- Place the prop_physics_override or func_physbox to where you'd like the object to hang from.
- This tutorial will be using a prop instead of a physbox, but both can be used.
- Place the keyframe_rope to where you'd like to anchor the rope to the prop_physics_override or func_physbox.
- Hint: Just inside the surface of the prop or brush works best.
- Remember your physics: once in game, the center of gravity of the prop and the anchor point will interact and your prop will reach a balance point accordingly.
- Place the phys_lengthconstraint in the exact same location of the keyframe_rope and drag the lengthconstraint's small white circle to the center of the move_rope.
- Place the env_spark in the exact same location of the keyframe_rope.
- Place the logic_measure_movement off to the side for easy access.
- Place the brush in the same location of the prop_physics_override or func_physbox.
Entity Properties Configuration
Naming:
Naming your entities is arbitrary- you can chose what names you want. For the purposes of this tutorial the nomenclature is:
- move_rope : dynamic01_move_rope
- keyframe_rope : dynamic01_keyframe_rope
- phys_lengthconstraint : dynamic01_phys_lengthconstraint
- env_spark : dynamic01_env_spark
- prop_physics_override or func_physbox : dynamic01_prop_phyics_override
- logic_measure_movement : dynamic01_logic_measuremovement
- the brush :
- Tie, (Ctrl+T) the brush to a func_button entity.
- set the Name keyvalue to : dynamic01_func_button
As you can see, each entity has the prefix dynamicXX and a descriptive suffix. This is a useful naming system when you have several dynamic systems and need to keep them separate.
Key Values for Rope Workaround:
Here comes the tricky part where most errors are made.
- set the dynamic01_move_rope's Next KeyFrame to dynamic01_keyframe_rope
- set the dynamic01_move_rope's Slack to 0
- set the dynamic01_keyframe_rope's Slack to 0
- set the dynamic01_env_spark's parent to dynamic01_prop_phyics_override
- set the dynamic01_phys_lengthconstraint Entity1 to dynamic01_prop_phyics_override
- set the following values of the dynamic01_logic_measuremovement to:
- Entity to Measure to dynamic01_env_spark
- Measure Reference to dynamic01_move_rope
- Entity to Move to dynamic01_keyframe_rope
- Movement Reference to dynamic01_move_rope
Trap Trigger Creation
Select the dynamic01_func_button entity and:
- set the Parent to dynamic01_prop_phyics_override
- set the Disable Receiving Shadows to Yes
- set the Move Direction (Pitch Yaw Roll) to 0 0 0
- set the Speed to 0
- set the Lip to 0
- configure the Flags tab like in the image below:
- configure the Outputs tab like in the image below: