Camera offset?
by William M. Johnson · in Torque Game Engine · 06/20/2002 (7:43 am) · 9 replies
In third person mode I want my camera offset from the player to simply be a little bit higher. I just want to raise the camera a tad bit up above the players head, and still have him aim towards the camera's veiw vector.
The affect of this camera adjustment on First Person View isn't a factor, as I'm removing the option to go First Person completely. Kinda like Max Payne.
Maybe this isn't as simple as it seems? Anyone have any advice for me? I searched through some of the playerview files, yet I didn't see anything obvious that seemed to relate to my problem.
The affect of this camera adjustment on First Person View isn't a factor, as I'm removing the option to go First Person completely. Kinda like Max Payne.
Maybe this isn't as simple as it seems? Anyone have any advice for me? I searched through some of the playerview files, yet I didn't see anything obvious that seemed to relate to my problem.
About the author
#2
I suggest having a look in the vehicle.cc file as an example of how to implement this.
10/29/2002 (12:03 pm)
The vehicle objects have a datablock property that adjusts the camera 3rd person offset but the player does not.I suggest having a look in the vehicle.cc file as an example of how to implement this.
#3
I have the zoom out code in a resource, and the nice guys at 21-6 sent me some of their camera code which I believe contains the ability to go up and down, left and right on the camera, but I'll have to check that before I promise anything.
Let me know what you want :)
-Jared
10/29/2002 (11:35 pm)
Do you want to physically move the camera UP so that you're looking more over the players head, or do you want to zoom out some?I have the zoom out code in a resource, and the nice guys at 21-6 sent me some of their camera code which I believe contains the ability to go up and down, left and right on the camera, but I'll have to check that before I promise anything.
Let me know what you want :)
-Jared
#4
Thanks
Chris
10/30/2002 (10:51 am)
I am also very interested in this. I am simply trying to make my players and bots 3rd person. I have looked around a bit in the forums and the docs (I could have totally missed it), but can't find out how one does this.Thanks
Chris
#5
If you could share the code to physically move the camera UP a bit, I think that should be all that's needed to solve our problems.
Thanks!
11/04/2002 (8:38 am)
Jared, I'm also having the exact same problem as William. My game would be using the 3rd person viewpoint exclusively, much like typical 3rd person action games such as Tomb Raider, Oni, Max Payne and such.If you could share the code to physically move the camera UP a bit, I think that should be all that's needed to solve our problems.
Thanks!
#6
In the mean time, you may want to simply take a look in the scripts for a value called:
maxZoomDist;
Change that to a bigger number and it'll be zoomed out more when you start.
You can force your game to start in 3rd person mode every time by changing gameconnection.cc
search for
bool GameConnection::mFirstPerson = true;
change it to
bool GameConnection::mFirstPerson = false;
11/06/2002 (9:58 pm)
I don't have the code to move the camera around left/right up/down in yet, but I'll give it a shot, and if it works, I'll definatly tell you how to do it.In the mean time, you may want to simply take a look in the scripts for a value called:
maxZoomDist;
Change that to a bigger number and it'll be zoomed out more when you start.
You can force your game to start in 3rd person mode every time by changing gameconnection.cc
search for
bool GameConnection::mFirstPerson = true;
change it to
bool GameConnection::mFirstPerson = false;
#7
I tried changing the maxZoom settings, but even if the camera's zoomed out further it still focuses on the player model - and still pretty hard to aim in 3rd person.
If only there was a way to "tilt" the camera angle a bit up the Y axis so that it will be focusing at a spot a few meters in front of the player...
11/08/2002 (4:28 am)
Thanks Jared.I tried changing the maxZoom settings, but even if the camera's zoomed out further it still focuses on the player model - and still pretty hard to aim in 3rd person.
If only there was a way to "tilt" the camera angle a bit up the Y axis so that it will be focusing at a spot a few meters in front of the player...
Torque Owner Bendik Stang
I'd personally like to change the viewfustrum to orthogonal to make a radarmap image.
Is there some command one can use ingame to change these settings?