Setting initial camera position
by Guy Allard · in RTS Starter Kit · 10/07/2006 (1:37 am) · 0 replies
I'm trying to specify where each player starts in a multiplayer session, using a system like the spawnSpheres used in the standard torque games.
I have it so that each players units are spawning at the correct locations, but I can't figure out how to get the players camera to start there too. The problem seems to arise from the fact that the camera is only controlled on the client.
If I set the camera position from within RTSConnection::onClientEnterGame, only the camera on the instance that is hosting the game is set to the correct position.
So, I tried making a client command that sets the camera position in serverConnection.cs, but If I call that from the end of onClientEnterGame, the game cannot find the control object at that time.
How would I go about doing this?
//***********************************************
To answer my own question - do some research!
http://www.garagegames.com/mg/forums/result.thread.php?qt=24383
I have it so that each players units are spawning at the correct locations, but I can't figure out how to get the players camera to start there too. The problem seems to arise from the fact that the camera is only controlled on the client.
If I set the camera position from within RTSConnection::onClientEnterGame, only the camera on the instance that is hosting the game is set to the correct position.
So, I tried making a client command that sets the camera position in serverConnection.cs, but If I call that from the end of onClientEnterGame, the game cannot find the control object at that time.
How would I go about doing this?
//***********************************************
To answer my own question - do some research!
http://www.garagegames.com/mg/forums/result.thread.php?qt=24383
About the author