Right click when toggling cursor
by Mehmet Kizil · in Torque Game Engine · 09/26/2005 (9:35 pm) · 1 replies
I have this very simple toggle cursor function attached to my "m" key.
What I would like to do is when the cursor is on, have the right key act like it does in the mission editor. As in, when the cursor is on, I can move left and right, forward and back, but I cannot change the view as in up and down. How do I implement this?
// Setting up a toggle mouse button
function toggleMouseLook(%val)
{
if(%val)
{
if(Canvas.isCursorOn())
CursorOff();
else
CursorOn();
}
}What I would like to do is when the cursor is on, have the right key act like it does in the mission editor. As in, when the cursor is on, I can move left and right, forward and back, but I cannot change the view as in up and down. How do I implement this?
About the author
Associate Kyle Carter