phys_hinge

From Source Entities
Jump to navigation Jump to search

Code classes:

phys_hinge is a point entity present in all Source games. It forces one or two entities to rotate only on a single axis, but otherwise move as normal.

Flags[edit | edit source]

  • 8: Change mass to keep stable attachment to world[Clarify]

Keyvalues[edit | edit source]

Friction (hingefriction) <float>
How stiff the hinge is. Note: No amount of friction will stop the Hl2.pnggravity gun from bending the hinge, but hinges with extremely high friction will bounce back to their original angle.
Hinge Axis (hingeaxis) <vecline>
The "other" end of the rotation axis.
Load Scale (SystemLoadScale) <float>
"Scale of the load connected to this hinge (1=just the objects directly connected)"[Clarify]
Travel sound (forward) (slidesoundfwd) <sound> (only available in Hl2.pngEpisodicP1.png)
Sound to make when the hinge is rotating clockwise.
Travel sound (backward) (slidesoundback) <sound> (only available in Hl2.pngEpisodicP1.png)
Sound to make when the hinge is rotating counter-clockwise.
Minimum Sound Velocity (minSoundThreshold) <float> (only available in Hl2.pngEpisodicP1.png)
When rotating below this speed, don't play any sounds.
Full Sound Velocity (maxSoundThreshold) <float> (only available in Hl2.pngEpisodicP1.png)
When rotating above this speed, play sounds at full volume.
Reversal sound (small) (reversalsoundSmall) <sound> (only available in Hl2.pngEpisodicP1.png)
Sound to play when the hinge makes a reversal at a speed between the small and medium Reversal sound thresholds.
Reversal sound (medium) (reversalsoundMedium) <sound> (only available in Hl2.pngEpisodicP1.png)
Sound to play when the hinge makes a reversal at a speed between the medium and large Reversal sound thresholds.
Reversal sound (large) (reversalsoundLarge) <sound> (only available in Hl2.pngEpisodicP1.png)
Sound to play when the hinge makes a reversal at a speed above the Reversal sound threshold (large).
Reversal sound threshold (small) (reversalsoundthresholdSmall) <float> (only available in Hl2.pngEpisodicP1.png)
If the hinge makes a reversal with at least this much angular acceleration/deceleration, the Reversal sound (small) will play.
Reversal sound threshold (medium) (reversalsoundthresholdMedium) <float> (only available in Hl2.pngEpisodicP1.png)
If the hinge makes a reversal with at least this much angular acceleration/deceleration, the Reversal sound (medium) will play.
Reversal sound threshold (large) (reversalsoundthresholdLarge) <float> (only available in Hl2.pngEpisodicP1.png)
If the hinge makes a reversal with at least this much angular acceleration/deceleration, the Reversal sound (large) will play.

Inputs[edit | edit source]

SetAngularVelocity <float>
Makes the hinge begin rotating this many degrees per second.
SetHingeFriction (Not in FGD) <float>
Sets Friction.

See Also[edit | edit source]