Advanced Camera
by Thomas \"Man of Ice\" Lund · 04/03/2008 (11:57 am) · 480 comments
Download Code File
Description
Over time a lot of people have released camera resources, but some do not work anymore, others are hard to implement etc.
I've tried to assemble a single class to add to the engine that implements them all in one go using the same basic architecture. This enables minimum code bloat and makes it way easier to keep the code up to date.
Change log
March 3rd, 2005
Manoel made some changes to the orbit camera. Works in multiplayer now and is much nicer by using console variables
February 3rd, 2005
Fixed small big in interpolation.
February 2nd, 2005
Major changes in this one with various contributors.
* Static camera mode
* Smooth interpolation and transition between modes
* Smooth orbit camera!!!
* Vertical freedom mode when in 3rd person
* Better collision check with terrain and interiors
* Mouse control of orbit camera
* Totally reworked codebase and lots of cleanups. Much more readable now
Manoel Neto contributed the new orbit camera and the interpolation
Zik Saleeba contributed the vertical freedom mode and better collision check
Thanks a lot!!!!
I have marked changes with a New in the text below for those who upgrade
January 23rd, 2005
Minor changes. Larger update soon with new functionality
* Now takes GameBase objects as target + player
* Removed debug message in orbit camera
* Added getters for player and target object
June 25th, 2004
Updated the bindings for orbit camera. Switched left+right.
June 23rd, 2004
A big thanks to Stephen Zepp for contributing with an orbit camera mode. Its added to the resource, and is perfect for RTS games and action adventures. It allows for a camera to rotate around a user as if placed on a sphere. The user can zoom in/out, rotate and tilt the camera.
June 9th, 2004
Added getter/setter for the 3 offset values accessible from script
Added a "follow terrain" mode for the third person camera, so the camera follows the terrain slope - doesnt work perfectly
April 5th, 2004
All camera modes now use a raycast to not get hidden behind terrain or interiors
April 3rd, 2004
This release is the first release, and might not be as "advanced" as the author would like, but its time to release it and get some feedback to further enhance it down the road.
Camera Modes Implemented
The resource currently implements the following camera systems:
* Track Mode
This is the same as the tracking camera resource posted by Cory Osborn. A stationary camera tracks the player and keeps him in focus.
* New Static Mode
Camera stays in its position and rotation. Useful for e.g. scene based adventures where the camera doesnt move with the players
* Third Person Mode
The camera is placed at an offset behind the player and rotates with the player. The camera itself is not controllable
* Third Person Track Mode
The camera is placed in third person mode but rotated so it always looks at a specified object, but with the player in full view
* God View
Camera is placed at an offset from the player and does not rotate with the player. This is your typical "Diablo" kind of camera.
* New Orbit Mode
Camera is placed on a sphere looking at the player, and can rotate/tilt and zoom controlled by the player. There are bindings to the mouse when in single player game (server and client on same machine)
Movie
Here is a small movie displaying the different camera modes (3 MB)
www.codejar.com/advancedcamerademo.wmv
How to Add
First off all you need to take the attached advancedCamera.cc/h files and add to engine\game and add them to the project.
Then you need to expose the camera object in GameConnection as described in Cory's resource www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=4720
I took the liberty to paste the relevant parts in here too
Exposing mCameraObject
The first thing you want to do is add console method's to access the GameConnection setCameraObject/getCameraObject methods. I added these to GameConnection.cc right after the console method for getControlObject:
After playing around with it, I also found you need some adjustments to the setCameraObject and setControlObject methods - otherwise the client connection can screw things up if you bounce the same object from your connection's control to camera or vice versa. Here is my GameConnection::setControlObject:
and here is my GameConnection::setCameraObject:
Camera read/write packets
None of this will work unless the client copy of the camera object gets packets updated. Here we're going to modify GameConnection::readPacket and GameConnection::writePacket.
In GameConnection::readPacket, find this block of code:
and change it to
In GameConnection::writePacket, find this block of code:
and change it to:
Recompile it all and the engine is ready to go.
Script
To use the camera you need to follow some of Corys resource, but with some modifications. Datablock and naming has changed
First, add a datablock for the tracking camera to /fps/server/scripts/camera.cs:
Next, add it to the connection just like is currently done with the base camera class. Add this inside GameConnection::onClientEnterGame (/fps/server/scripts/game.cs), right after %this.camera is set up:
We'll need to clean it up after the client leaves the game, so add this to GameConnection::onClientLeaveGame
We need to tell it what to do when added and assign the connection's camera object, so add this to the end of GameConnection::createPlayer:
And we'll want to unhook it when the player dies. Insert this at the beginning of GameConnection::onDeath:
The last thing to know, is if you're in first-person mode, GameConnection automatically uses the control object to render the engine rather than the camera object. So if you don't see this working when you first enter a mission, toggle out of first-person.
Orbit mode
To use the orbit camera, one needs to add some key binds to manipulating the camera.
All you need to do, is add the following to your client\config.cs or better to your client\scripts\default.bind.cs
Remember to comment out the mouse commands for the player movement, as these are overwritten by the orbit camera controls
Script API
To use the different camera modes you can use the following API
Selecting the camera mode is done with e.g.:
Prior to calling the above modes you have to set the PlayerObject using
To use the 3rd person target mode you also need to set a TargetObject using
To use the static or tracking camera you need to set the position the camera should be placed suing
To use the follow terrain mode in 3rd person you give a bool to
To use the vertical freedom mode in 3rd person you give a bool to
The offset values in the datablock can be changed for the camera object via script using
The orbit camera can be manipulated from script using
You can also manipulate the orbit camera directly by assigning values to the following variables
[code]
$advCamera::Yaw
$advCamera::Pitch
$advCamera::Zoom
$advCamera::azimuth
$advCamera::declination
$advCamera::zoomDistance
[code]
All camera modes coexist, so you can set the position, player object and target object once and then switch camera modes around as you see fit. Switching mode will not clear the old objects/positions.
Description
Over time a lot of people have released camera resources, but some do not work anymore, others are hard to implement etc.
I've tried to assemble a single class to add to the engine that implements them all in one go using the same basic architecture. This enables minimum code bloat and makes it way easier to keep the code up to date.
Change log
March 3rd, 2005
Manoel made some changes to the orbit camera. Works in multiplayer now and is much nicer by using console variables
February 3rd, 2005
Fixed small big in interpolation.
February 2nd, 2005
Major changes in this one with various contributors.
* Static camera mode
* Smooth interpolation and transition between modes
* Smooth orbit camera!!!
* Vertical freedom mode when in 3rd person
* Better collision check with terrain and interiors
* Mouse control of orbit camera
* Totally reworked codebase and lots of cleanups. Much more readable now
Manoel Neto contributed the new orbit camera and the interpolation
Zik Saleeba contributed the vertical freedom mode and better collision check
Thanks a lot!!!!
I have marked changes with a New in the text below for those who upgrade
January 23rd, 2005
Minor changes. Larger update soon with new functionality
* Now takes GameBase objects as target + player
* Removed debug message in orbit camera
* Added getters for player and target object
June 25th, 2004
Updated the bindings for orbit camera. Switched left+right.
June 23rd, 2004
A big thanks to Stephen Zepp for contributing with an orbit camera mode. Its added to the resource, and is perfect for RTS games and action adventures. It allows for a camera to rotate around a user as if placed on a sphere. The user can zoom in/out, rotate and tilt the camera.
June 9th, 2004
Added getter/setter for the 3 offset values accessible from script
Added a "follow terrain" mode for the third person camera, so the camera follows the terrain slope - doesnt work perfectly
April 5th, 2004
All camera modes now use a raycast to not get hidden behind terrain or interiors
April 3rd, 2004
This release is the first release, and might not be as "advanced" as the author would like, but its time to release it and get some feedback to further enhance it down the road.
Camera Modes Implemented
The resource currently implements the following camera systems:
* Track Mode
This is the same as the tracking camera resource posted by Cory Osborn. A stationary camera tracks the player and keeps him in focus.
* New Static Mode
Camera stays in its position and rotation. Useful for e.g. scene based adventures where the camera doesnt move with the players
* Third Person Mode
The camera is placed at an offset behind the player and rotates with the player. The camera itself is not controllable
* Third Person Track Mode
The camera is placed in third person mode but rotated so it always looks at a specified object, but with the player in full view
* God View
Camera is placed at an offset from the player and does not rotate with the player. This is your typical "Diablo" kind of camera.
* New Orbit Mode
Camera is placed on a sphere looking at the player, and can rotate/tilt and zoom controlled by the player. There are bindings to the mouse when in single player game (server and client on same machine)
Movie
Here is a small movie displaying the different camera modes (3 MB)
www.codejar.com/advancedcamerademo.wmv
How to Add
First off all you need to take the attached advancedCamera.cc/h files and add to engine\game and add them to the project.
Then you need to expose the camera object in GameConnection as described in Cory's resource www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=4720
I took the liberty to paste the relevant parts in here too
Exposing mCameraObject
The first thing you want to do is add console method's to access the GameConnection setCameraObject/getCameraObject methods. I added these to GameConnection.cc right after the console method for getControlObject:
ConsoleMethod( GameConnection, setCameraObject, bool, 3, 3, "(ShapeBase object)")
{
ShapeBase *gb;
if(!Sim::findObject(argv[2], gb))
return false;
object->setCameraObject(gb);
return true;
}
ConsoleMethod( GameConnection, getCameraObject, S32, 2, 2, "")
{
argv;
SimObject* cp = object->getCameraObject();
return cp ? cp->getId(): 0;
}
ConsoleMethod( GameConnection, clearCameraObject, void, 2, 2, "")
{
object->setCameraObject(NULL);
}After playing around with it, I also found you need some adjustments to the setCameraObject and setControlObject methods - otherwise the client connection can screw things up if you bounce the same object from your connection's control to camera or vice versa. Here is my GameConnection::setControlObject:
void GameConnection::setControlObject(ShapeBase *obj)
{
if(mControlObject == obj)
return;
if(mControlObject && mControlObject != mCameraObject)
mControlObject->setControllingClient(0);
if(obj)
{
// Nothing else is permitted to control this object.
if (ShapeBase* coo = obj->getControllingObject())
coo->setControlObject(0);
if (GameConnection *con = obj->getControllingClient())
{
if (this != con)
{
// was it controlled via camera or control?
if (con->getControlObject() == obj)
con->setControlObject(0);
else
con->setCameraObject(0);
}
}
// We are now the controlling client of this object.
obj->setControllingClient(this);
}
// Okay, set our control object.
mControlObject = obj;
if (mCameraObject.isNull())
setScopeObject(mControlObject);
}and here is my GameConnection::setCameraObject:
void GameConnection::setCameraObject(ShapeBase *obj)
{
if(mCameraObject == obj)
return;
if(mCameraObject && mCameraObject != mControlObject)
mCameraObject->setControllingClient(0);
if (obj) {
// Nothing else is permitted to control this object.
if (ShapeBase* coo = obj->getControllingObject())
coo->setControlObject(0);
if (GameConnection *con = obj->getControllingClient())
{
if (this != con)
{
// was it controlled via camera or control?
if (con->getControlObject() == obj)
con->setControlObject(0);
else
con->setCameraObject(0);
}
}
// We are now the controlling client of this object.
obj->setControllingClient(this);
}
// Okay, set our camera object.
mCameraObject = obj;
if (mCameraObject.isNull()) {
setScopeObject(mControlObject);
} else {
setScopeObject(mCameraObject);
// if this is a client then set the fov and active image
if(isServerConnection())
{
F32 fov = mCameraObject->getDefaultCameraFov();
GameSetCameraFov(fov);
}
}
}Camera read/write packets
None of this will work unless the client copy of the camera object gets packets updated. Here we're going to modify GameConnection::readPacket and GameConnection::writePacket.
In GameConnection::readPacket, find this block of code:
if (bstream->readFlag())
{
S32 gIndex = bstream->readInt(10);
ShapeBase* obj = static_cast<ShapeBase*>(resolveGhost(gIndex));
setCameraObject(obj);
}
else
setCameraObject(0);and change it to
if (bstream->readFlag())
{
S32 gIndex = bstream->readInt(NetConnection::GhostIdBitSize);
ShapeBase* obj = static_cast<ShapeBase*>(resolveGhost(gIndex));
setCameraObject(obj);
obj->readPacketData(this, bstream);
}
else
setCameraObject(0);In GameConnection::writePacket, find this block of code:
if (!mCameraObject.isNull() && mCameraObject != mControlObject)
{
gIndex = getGhostIndex(mCameraObject);
if (bstream->writeFlag(gIndex != -1))
bstream->writeInt(gIndex, 10);
}
else
bstream->writeFlag( false );and change it to:
if (!mCameraObject.isNull() && mCameraObject != mControlObject)
{
gIndex = getGhostIndex(mCameraObject);
if (bstream->writeFlag(gIndex != -1)) {
bstream->writeInt(gIndex, NetConnection::GhostIdBitSize);
mCameraObject->writePacketData(this, bstream);
}
}
else
bstream->writeFlag( false );Recompile it all and the engine is ready to go.
Script
To use the camera you need to follow some of Corys resource, but with some modifications. Datablock and naming has changed
First, add a datablock for the tracking camera to /fps/server/scripts/camera.cs:
...
datablock AdvancedCameraData(AdvCameraData)
{
lookAtOffset = "0 0 2";
thirdPersonOffset = "0 -3 3";
godViewOffset = "0 -20 20";
maxTerrainDiff = 2;
orbitMinMaxZoom = "5 100";
orbitMinMaxDeclination = "10 80";
damping = 0.25;
};
...Next, add it to the connection just like is currently done with the base camera class. Add this inside GameConnection::onClientEnterGame (/fps/server/scripts/game.cs), right after %this.camera is set up:
...
// create advanced camera
%this.advCamera = new AdvancedCamera() {
dataBlock = AdvCameraData;
};
MissionCleanup.add(%this.advCamera);
%this.advCamera.scopeToClient(%this);
...We'll need to clean it up after the client leaves the game, so add this to GameConnection::onClientLeaveGame
...
if (isObject(%this.advCamera))
%this.advCamera.delete();
...We need to tell it what to do when added and assign the connection's camera object, so add this to the end of GameConnection::createPlayer:
... // We set the camera system to run in 3rd person mode around the %player %this.advCamera.setPlayerObject(%player); %this.advCamera.setThirdPersonMode(); %this.advCamera.setFollowTerrainMode(false); %this.advCamera.setVerticalFreedomMode(false); %this.setCameraObject(%this.advCamera); ...
And we'll want to unhook it when the player dies. Insert this at the beginning of GameConnection::onDeath:
... // clear connections camera %this.advCamera.clearPlayerObject(); %this.advCamera.clearTargetObject(); %this.clearCameraObject(); ...
The last thing to know, is if you're in first-person mode, GameConnection automatically uses the control object to render the engine rather than the camera object. So if you don't see this working when you first enter a mission, toggle out of first-person.
Orbit mode
To use the orbit camera, one needs to add some key binds to manipulating the camera.
All you need to do, is add the following to your client\config.cs or better to your client\scripts\default.bind.cs
//------------------------------------------------------------------------------
// Advanced Camera Movement
//------------------------------------------------------------------------------
$cameraYawSpeed = -100.0;
$cameraPitchSpeed = -50.0;
$cameraZoomSpeed = -5.0;
function rotateCameraHorizontal(%val)
{
$advCamera::Yaw = getMouseAdjustAmount(%val)*$cameraYawSpeed ;
}
function rotateCameraVertical(%val)
{
$advCamera::Pitch = getMouseAdjustAmount(%val)*$cameraPitchSpeed;
}
function zoomCamera(%val)
{
$advCamera::Zoom = getMouseAdjustAmount(%val)*$cameraZoomSpeed;
}
moveMap.bind( mouse, xaxis, rotateCameraHorizontal);
moveMap.bind( mouse, yaxis, rotateCameraVertical );
moveMap.bind( mouse, zaxis, zoomCamera );Remember to comment out the mouse commands for the player movement, as these are overwritten by the orbit camera controls
//moveMap.bind( mouse, xaxis, yaw ); //moveMap.bind( mouse, yaxis, pitch );
Script API
To use the different camera modes you can use the following API
Selecting the camera mode is done with e.g.:
%this.advCamera.setTrackMode(); %this.advCamera.setThirdPersonMode(); %this.advCamera.setThirdPersonTargetMode(); %this.advCamera.setGodViewMode(); %this.advCamera.setOrbitMode(); %this.advCamera.setStaticMode();
Prior to calling the above modes you have to set the PlayerObject using
setPlayerObject();
To use the 3rd person target mode you also need to set a TargetObject using
setTargetObject();
To use the static or tracking camera you need to set the position the camera should be placed suing
setCameraPosition(Point3F pos);
To use the follow terrain mode in 3rd person you give a bool to
setFollowTerrainMode(true/false);
To use the vertical freedom mode in 3rd person you give a bool to
setVerticalFreedomMode(true/false);This only works if the player object is a Player, because it uses the head movement.
The offset values in the datablock can be changed for the camera object via script using
get/setLookAtOffset(); get/setThirdPersonOffset(); get/setGodViewOffset();The setters take a Point3F as argument.
The orbit camera can be manipulated from script using
get/setOrbitMinMaxZoom() get/setOrbitMinMaxDeclination()The min/max take a Point2F
You can also manipulate the orbit camera directly by assigning values to the following variables
[code]
$advCamera::Yaw
$advCamera::Pitch
$advCamera::Zoom
$advCamera::azimuth
$advCamera::declination
$advCamera::zoomDistance
[code]
All camera modes coexist, so you can set the position, player object and target object once and then switch camera modes around as you see fit. Switching mode will not clear the old objects/positions.
#42
This resource allows you script control of the camera, and thus makes it way way more flexible
Hope that answers your question
09/22/2004 (10:39 pm)
The existing code in stock TGE allows you to have a first person view and a 3rd person view. You can move (within Max) the eye and cam nodes and thus create different angles. But they are static yes.This resource allows you script control of the camera, and thus makes it way way more flexible
Hope that answers your question
#43
I believe that the networking code in the original camera is present because camera transforms result in player movement which must be handled by the server. In instances where the camera movement has no relationship to the player (ie: rts camera) the overhead of sending camera data through the network is unnacceptable. Does anyone know of an existing resource that implements a completely client-side camera?
09/27/2004 (9:37 am)
Networking - I believe that the networking code in the original camera is present because camera transforms result in player movement which must be handled by the server. In instances where the camera movement has no relationship to the player (ie: rts camera) the overhead of sending camera data through the network is unnacceptable. Does anyone know of an existing resource that implements a completely client-side camera?
#44
I think/hope that the camera in the upcomming RTS pack is client side only - else try to hack up this resource. A few have done it successfully it seems.
09/27/2004 (9:41 am)
afaik there are none DonnyI think/hope that the camera in the upcomming RTS pack is client side only - else try to hack up this resource. A few have done it successfully it seems.
#45
If anyone DOES hack this resource for client-side, as Donny reqested, that'd be good. I might try it myself at some point though I'm not really proficient with Torque at the moment :-\
10/04/2004 (6:14 pm)
Excellent resource Thomas! Thanks a heap. Just plugged it into the latest HEAD last night. Works great! Very easy to customise too.If anyone DOES hack this resource for client-side, as Donny reqested, that'd be good. I might try it myself at some point though I'm not really proficient with Torque at the moment :-\
#46
10/11/2004 (8:51 am)
I hear ya Todd. I've relagated this to the optimization phase at which point I 'spect I'll be able to remove the networking without breaking too much.
#47
(0): Unable to find object " attempting to call function 'setGodViewMode'....
it sends back a similar error for each of the different camera modes. I am also getting a syntax error when the mission boots up from line 35 of my client.cs file:
command to server(##1##80;MouseBounceUp&180;); ..... the #'s are mostly from the console... my file looks like this:
function AvatarCamPitchUp(%val)
{
if (%val)
commandToServer(´MouseBounceUp´);
}
any ideas? Would appreciate advice...
Daniel.
10/11/2004 (5:05 pm)
I've implemented all the code, but when I try to select a camera mode in the console it sends back an error:(0): Unable to find object " attempting to call function 'setGodViewMode'....
it sends back a similar error for each of the different camera modes. I am also getting a syntax error when the mission boots up from line 35 of my client.cs file:
command to server(##1##80;MouseBounceUp&180;); ..... the #'s are mostly from the console... my file looks like this:
function AvatarCamPitchUp(%val)
{
if (%val)
commandToServer(´MouseBounceUp´);
}
any ideas? Would appreciate advice...
Daniel.
#48
Man of Ice is on vacation in Miami, otherwise he would respond. Here is what you want to know:
The website doesn't like single quotes for some reason. It converts them to ´ .... Using your text editor, do a find and replace for the funky ´ stuff and replace it with a single quote. Everything will work fine then.
Joe
10/11/2004 (6:26 pm)
Daniel,Man of Ice is on vacation in Miami, otherwise he would respond. Here is what you want to know:
The website doesn't like single quotes for some reason. It converts them to ´ .... Using your text editor, do a find and replace for the funky ´ stuff and replace it with a single quote. Everything will work fine then.
Joe
#49
Daniel
10/12/2004 (7:04 am)
Thanks Joe... that fixed the error that was popping up. The camera modes still don't seem to work though, although something is definitely happening. 1st person mode works like always, but when I press tab, the camera remains fixed in one position and I can still move my player around. When I do the setPlayerObject(); or try to set any of the camera modes it says it can't find the function and nothing changes. Any ideas?Daniel
#50
ClientGroup.getObject(0).getCameraObject().setThirdPersonMode();
ClientGroup.getObject(0).getCameraObject().setOrbitMode();
ClientGroup.getObject(0).getCameraObject().setGodViewMode();
10/12/2004 (1:44 pm)
tab away from first person, and from the console try the following 3 commands to switch between advanced camera modes:ClientGroup.getObject(0).getCameraObject().setThirdPersonMode();
ClientGroup.getObject(0).getCameraObject().setOrbitMode();
ClientGroup.getObject(0).getCameraObject().setGodViewMode();
#51
thanks for all your help
Daniel.
10/12/2004 (5:27 pm)
hmmm... well, that is the first thing I've been able to enter into the console without a "cannot find" error, but still no change. The camera just stays fixed in one position. I can still move the player around, but no matter what, in 3rd person mode the camera will not move. Maybe it's the release I'm using? I've got a clean build of a recent head. Would this have an affect on anything? I've had absolutely zero luck trying to use any of these camera resources. I'm desperately trying to learn how they work, as it is vital to my emotional well-being, but to no avail. I just wish I knew what I was doing wrong...thanks for all your help
Daniel.
#52
10/12/2004 (9:39 pm)
@Daniel: Can you give me your Player files? I'll have a look for ya.
#53
Daniel.
10/13/2004 (4:19 am)
That would be notably altruistic. What files do you mean specifically? All the changes I made were to the files suggested above. How do you want me to send them?Daniel.
#54
I had the same problem though
In onClientEnterGame (/fps/server/scripts/game.cs) delete %this.camera... and then replace all things using %this.camera with %this.advCamera...
10/13/2004 (4:42 am)
Nevermind... I'm being a dumba55...I had the same problem though
In onClientEnterGame (/fps/server/scripts/game.cs) delete %this.camera... and then replace all things using %this.camera with %this.advCamera...
#55
Replace this in your god view mode in both tick functions:
setPosition(cameraPos);
With:
10/13/2004 (4:49 pm)
If you would like to enhance your god view mode to turn a little bit while your moving(cool efffect).Replace this in your god view mode in both tick functions:
setPosition(cameraPos);
With:
F32 lag = F32(TickMs) * 0.0001f; Point3F position; mObjToWorld.getColumn(3, &position); Point3F movePos; movePos.interpolate(position, cameraPos, lag); setPosition(movePos);
#56
I have started with a clean build twice now and no matter what I do, I can't seem to get this to work. It's likely something small that I'm missing, but I was just wondering if there were other things taht people had to do in order to get things to work for them. Could someone tell me what exactly they are typing into the console to toggle the new camera on? If I type in setPlayerObject(); or the %this.advCamera commands from the resource it just sends back a generic error saying that it can't find that function or something. I get the same thing when I try what Vicki suggested above.
As always, (especially with this camera business) I would appreciate any insight
Daniel.
10/15/2004 (5:07 am)
Has anyone else had problems implementing this resource with a recent HEAD (or 1.3 for that matter)???I have started with a clean build twice now and no matter what I do, I can't seem to get this to work. It's likely something small that I'm missing, but I was just wondering if there were other things taht people had to do in order to get things to work for them. Could someone tell me what exactly they are typing into the console to toggle the new camera on? If I type in setPlayerObject(); or the %this.advCamera commands from the resource it just sends back a generic error saying that it can't find that function or something. I get the same thing when I try what Vicki suggested above.
As always, (especially with this camera business) I would appreciate any insight
Daniel.
#57
the ThirdPerson mode, however, isn't very good.. there are many clipping bugs inside interiors =)
best regards,
JackTheDipper ;o)
P.S.: i'm looking forward to a smoother and perhaps even 100% on client side working orbit cam mode ;o)
10/18/2004 (1:51 pm)
it's working with the (almost) latest head for me... i modified the orbit cam to be controlled by mouse (while right mouse button is being pressed), and except that this camera runs on the server's side and zooming/moving isn't smooth, it's really working like a charm! ;o)the ThirdPerson mode, however, isn't very good.. there are many clipping bugs inside interiors =)
best regards,
JackTheDipper ;o)
P.S.: i'm looking forward to a smoother and perhaps even 100% on client side working orbit cam mode ;o)
#58
12/01/2004 (1:25 pm)
I can't get this camera system to work with a clean HEAD. All I get is a stationary camera on the spawnsphere and nothing else. Actually all moving objects except the client player are not visible tho there really are there...
#59
12/01/2004 (2:22 pm)
nevermind...
#60
I'm trying to get a camera like the thirdPerson mode included in this resource but when it turn it shouldn't turn the character too, the character should remain standing and when I press the back key instead of the character running backwards he should turn in that direction and run forward, I hope am being clear in what I wish to achive.
Any pointers on how to acomplish this or where to start are very apreciated.
Also am getting something strange, when I run the floor starts blinking to black, any ideas?
Thanks
12/01/2004 (9:03 pm)
Thanks for the great resource Thomas.I'm trying to get a camera like the thirdPerson mode included in this resource but when it turn it shouldn't turn the character too, the character should remain standing and when I press the back key instead of the character running backwards he should turn in that direction and run forward, I hope am being clear in what I wish to achive.
Any pointers on how to acomplish this or where to start are very apreciated.
Also am getting something strange, when I run the floor starts blinking to black, any ideas?
Thanks

Torque Owner Jordan Thompson
Thanks