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

Method setTransform

Engine/source/T3D/player.cpp:5552–5564  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5550//----------------------------------------------------------------------------
5551
5552void Player::setTransform(const MatrixF& mat)
5553{
5554 // This method should never be called on the client.
5555
5556 // This currently converts all rotation in the mat into
5557 // rotations around the z axis.
5558 Point3F pos,vec;
5559 mat.getColumn(1,&vec);
5560 mat.getColumn(3,&pos);
5561 Point3F rot(0.0f, 0.0f, -mAtan2(-vec.x,vec.y));
5562 setPosition(pos,rot);
5563 setMaskBits(MoveMask | NoWarpMask);
5564}
5565
5566void Player::getEyeTransform(MatrixF* mat)
5567{

Callers 5

onAddMethod · 0.45
setPositionMethod · 0.45
buildPolyListMethod · 0.45
updateWaterSoundsMethod · 0.45
createSplashMethod · 0.45

Calls 3

mAtan2Function · 0.85
getColumnMethod · 0.80
setPositionFunction · 0.50

Tested by

no test coverage detected