Game Development Community

Rotate the Cam

by Kiyaku · in Torque Game Builder · 07/08/2007 (1:14 pm) · 2 replies

Hi,

well the topic says everything. Is it possible to rotate the camera somehow?

#1
07/08/2007 (8:56 pm)
Kiyaku, possible? Yes ... through TorqueScript with the Stock Engine, no.

The camera in TGB is basically just a standard OpenGL/DirectX camera that is locked on the Z axis ... with a bit of modifications (possibly a resource already available, not sure), you could have this camera rotate for you --


Alternatively though, you could create a very large scene object that covers your entire game level, and then mount all the objects in the level to this object and then rotate this object ... using the 'track rotation' functionality of the mount.

Depending on your game, however, the second option may not even be an option -- also, you'll have to remember that when you mount the objects to this 'rotational object', you'll be doing so in object space and not world space ... so your coordinates may differ from the actual coordinates of the objects -- but if your 'rotational object' is placed at 0,0 ... and scaled out to fit the entire level (make sure this object is a perfect square, equal width and height, to ensure proper rotation ... unless you want it to rotate in an 'egg' shape).


#2
07/09/2007 (2:19 am)
Hi David,

i was thinking about mounting the objects too, but i can't use this for my game, there would be too many problems.

So if i want to write a modification, do i need the Pro edition of the TGB?