Phys slideconstraint

From Valve Developer Community
Revision as of 08:05, 4 October 2005 by Maven (talk | contribs) (cleanup tag)
Jump to: navigation, search


A constraint that constrains an entity along a line segment.


Name targetname <target_source> The name that other entities refer to this entity by.

spawnflags spawnflags <flags>

Entity 1 attach1 <target_destination>

Entity 2 attach2 <target_destination>

Constraint System Manager constraintsystem <target_destination> The name of a phys_constraintsystem that this constraint should be a part of. All constraints on a set of entities should be placed in the same system, or they will fight each other during simulation.

Force Limit to Break (lbs) forcelimit <float> The amount of force an impact must apply to the constraint to break it. A way of calculating this is to set it to the mass of an object that would break this constraint if it were resting on the constrainted objects.

Torque Limit to Break (lbs * distance) torquelimit <float> The amount of torque required to break the constraint. A way of calculating this is to multiply any reference mass by the resting distance (from the center of mass of the object) needed to break the constraint.

Play Sound on Break breaksound <sound> A sound played when the constraint is broken.

Sliding Axis slideaxis <vecline>

Friction slidefriction <float> Resistance/friction in the constraint

Load Scale SystemLoadScale <float> Scale of the mass load connected to this constraint (1=just the objects directly connected)


Kill Removes this entity from the world.

KillHierarchy Removes this entity and all its children from the world.

AddOutput <string> Adds an entity I/O connection to this entity. Format: <output name> <targetname>:<inputname>:<parameter>:<delay>:<max times to fire (-1 == infinite)>. Very dangerous, use with care.

FireUser1 Causes this entity's OnUser1 output to be fired.

FireUser2 Causes this entity's OnUser2 output to be fired.

FireUser3 Causes this entity's OnUser3 output to be fired.

FireUser4 Causes this entity's OnUser4 output to be fired.

Break Force the constraint to break.

TurnOn Enable the constraint. Do this when the objects don't exist when the constraint spawns - or when you have deactivated the constraint. Broken constraints can NOT be turned on. They have been deleted.

TurnOff Disable this constraint.

SetVelocity <float> Set linear velocity along the constraint


OnUser1 Fired in response to FireUser1 input.

OnUser2 Fired in response to FireUser2 input.

OnUser3 Fired in response to FireUser3 input.

OnUser4 Fired in response to FireUser4 input.

OnBreak Fired when the constraint breaks.