MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / getMountTransform

Method getMountTransform

Engine/source/Verve/VPath/VPath.cpp:457–483  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

455}
456
457void VPath::getMountTransform( S32 pIndex, const MatrixF &pInTransform, MatrixF *pTransform )
458{
459 // Fetch the Scene Object.
460 VPathObject *pathObject = NULL;
461 for ( SceneObject *itr = getMountList(); itr != NULL; itr = itr->getMountLink() )
462 {
463 if ( itr->getMountNode() == pIndex )
464 {
465 pathObject = getPathObject( itr );
466 break;
467 }
468 }
469
470 if ( !pathObject )
471 {
472 // Reset Transform.
473 *pTransform = pInTransform;
474 // Sanity!
475 return;
476 }
477
478 // Advance the Object.
479 advanceObject( pathObject, TickSec );
480
481 // Apply Transform.
482 *pTransform = pathObject->getTransform();
483}
484
485void VPath::getRenderMountTransform( F32 pDelta, S32 pIndex, const MatrixF &pInTransform, MatrixF *pTransform )
486{

Callers 1

postTickUpdateMethod · 0.45

Calls 3

getMountLinkMethod · 0.80
getMountNodeMethod · 0.80
getTransformMethod · 0.45

Tested by

no test coverage detected