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

Method pushFront

Engine/source/T3D/pathShape.cpp:318–336  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

316}
317
318void PathShape::pushFront(CameraSpline::Knot *knot)
319{
320 // Make room at the front
321 if (mNodeCount == NodeWindow)
322 delete mSpline.remove(mSpline.getKnot(mNodeCount));
323 else
324 mNodeCount++;
325 mNodeBase--;
326
327 // Fill in the new node
328 mSpline.push_front(knot);
329 setMaskBits(WindowMask);
330
331 // Make sure the position doesn't fall off
332 if (mPosition > mNodeBase + (NodeWindow - 1)) {
333 mPosition = mNodeBase + (NodeWindow - 1);
334 setMaskBits(PositionMask);
335 }
336}
337
338void PathShape::popFront()
339{

Callers 2

pathShape.cppFile · 0.45
addFXMethod · 0.45

Calls 3

getKnotMethod · 0.80
removeMethod · 0.45
push_frontMethod · 0.45

Tested by

no test coverage detected