MCPcopy Create free account
hub / github.com/TombEngine/TombEngine / SetPendulumPoint

Function SetPendulumPoint

TombEngine/Objects/Generic/Object/rope.cpp:462–477  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

460 }
461
462 void SetPendulumPoint(ROPE_STRUCT* rope, int node)
463 {
464 CurrentPendulum.position.x = rope->segment[node].x;
465 CurrentPendulum.position.y = rope->segment[node].y;
466 CurrentPendulum.position.z = rope->segment[node].z;
467
468 if (CurrentPendulum.node == -1)
469 {
470 CurrentPendulum.velocity.x += rope->velocity[node].x;
471 CurrentPendulum.velocity.y += rope->velocity[node].y;
472 CurrentPendulum.velocity.z += rope->velocity[node].z;
473 }
474
475 CurrentPendulum.node = node;
476 CurrentPendulum.rope = rope;
477 }
478
479 void ModelRigidRope(ROPE_STRUCT* rope, PENDULUM* pendulumPointer, Vector3i* ropeVelocity, Vector3i* pendulumVelocity, int value)
480 {

Callers 1

RopeDynamicsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected