Game Development Community

How to detemine a pathcamera has arrived at the last markers?

by FanZhang · in Torque Game Engine · 04/24/2009 (1:51 am) · 4 replies

How to detemine a pathcamera has arrived at the last markers?
Now I intend to make a function that when a pathCamera arrives the last
path markers and call up some methods?
How could i determine it has gotten the last path markers?Thnx.

#1
04/24/2009 (2:39 am)
TGB has an onPathFinished callback, I have no idea if TGE/TGEA have something like this as well.
#2
04/24/2009 (3:18 am)
Thanks:)I have looked for the original code but i think that TGE/TGEA do not have this function.
Are There any other method to get this way?
#3
04/24/2009 (10:36 am)
You would use the onNode() callback. Count the number of nodes in the path. The highest node# would be the end of the path. When you get to that node then do what needs to be done.

Take a look scene.cs in the Demo (TGE/TGEa) for an example of "node counting" in function LoopingCam::onNode()
#4
04/26/2009 (7:00 pm)
That is a good idea.I finished this function by your point:)thank you.Michael Hall