DayZ 1.29
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ CreateSlider() [2/2]

static proto PhysicsSliderJoint PhysicsJoint::CreateSlider ( notnull IEntity ent1,
IEntity ent2,
vector matrix1[4],
vector matrix2[4],
bool disableCollisions,
float breakThreshold = -1 )
staticprivate

Creates slider joint. Entities must be dynamic objects. Using only ent1 anchors it to the world.

IEntity entity1 = GetWorld().FindEntityByName("entity1");
IEntity entity2 = GetWorld().FindEntityByName("entity1");
vector mat1[4] = { vector.Right, vector.Up, vector.Forward, vector.Right };
vector mat2[4] = { vector.Right, vector.Up, vector.Forward, -vector.Right };
PhysicsJoint.CreateSlider(entity1, entity2, mat1, mat2, false);
Определения EnEntity.c:165
static const vector Forward
Определения EnConvert.c:122
static const vector Up
Определения EnConvert.c:120
Определения EnConvert.c:119
int[] PhysicsJoint
Определения PhysicsJoint.c:21
Аргументы
ent1Entity that will be part of the joint, mandatory
ent2Other entity that will be part of the joint, optional
matrix1Joint transformation in reference frame of ent1 (slide is x-axis)
matrix2Joint transformation in reference frame of ent2 (slide is x-axis)
disableCollisionsTrue to disable collisions between connected entities
breakThresholdMaximum impulse to break the joint. Use -1 for unbreakable joint