Garry's Mod Wiki

constraint.Rope

constraint.Rope

  Entity, Entity constraint.Rope( Entity Ent1, Entity Ent2, number Bone1, number Bone2, Vector LPos1, Vector LPos2, number length, number addlength, number forcelimit, number width, string material, boolean rigid, table color )

Description

Creates a rope constraint - with rope!

Arguments

1 Entity Ent1
First entity
2 Entity Ent2
Second entity
3 number Bone1
Bone of first entity (0 for non-ragdolls)
4 number Bone2
Bone of second entity (0 for non-ragdolls)
5 Vector LPos1
Position of first end of the rope. Local to Ent1.
6 Vector LPos2
Position of second end of the rope. Local to Ent2.
7 number length
Length of the rope.
8 number addlength
Amount to add to the length of the rope. Works as it does in the Rope tool.
9 number forcelimit
Amount of force until it breaks (0 = unbreakable).
10 number width
Width of the rope.
11 string material
Material of the rope.
12 boolean rigid
Whether the constraint is rigid.
13 table color
The color of the rope. See Color.

Returns

1 Entity
Constraint. Will be a keyframe_rope if you roping to the same bone on the same entity. Will return false if the constraint could not be created.
2 Entity
rope. Will return nil if "Constraint" is a keyframe_rope or if the constraint could not be created.

Special Pages


Wikis

?

Render Time: 34ms

DB GetPage 2
Generate Html 16
SaveChanges (1) 6
Render Body 0
Render Sidebar 7