How do I force 3rd person view?
by Nicolai Dutka · in Torque Game Engine · 09/02/2007 (11:44 pm) · 3 replies
As the topic title suggests, I want the player to start out the mission in 3rd person view and not allow switching to first person. How would I do this?
#2
and
I dont think it's possible to remove Firstperson totally without code changes though, without removing the console.
A player can just type ServerConnection.setFirstPerson(true); into the console.
09/03/2007 (1:49 am)
To make sure they users dont switch back, remove:$firstPerson = true;
function toggleFirstPerson(%val)
{
if (%val)
{
$firstPerson = !$firstPerson;
ServerConnection.setFirstPerson($firstPerson);
}
}and
moveMap.bind(keyboard, tab, toggleFirstPerson );
I dont think it's possible to remove Firstperson totally without code changes though, without removing the console.
A player can just type ServerConnection.setFirstPerson(true); into the console.
#3
I added
to my game.cs where you said to and it works like a charm.
I commented out the
in my default.bind.cs just in case I want to use it later
09/03/2007 (6:26 am)
I posted in public because it said if this is something that the public could benefit from seeing, it should go here. I have an Indie License with the 1.5.2 SDK of TGE.I added
%this.setFirstPerson(false);
to my game.cs where you said to and it works like a charm.
I commented out the
//moveMap.bind(keyboard, tab, toggleFirstPerson );
in my default.bind.cs just in case I want to use it later
Torque Owner James Laker (BurNinG)
So in function GameConnection::onClientEnterGame(%this) add this:
You might want to check out client/scripts/default.bind.cs and change this:
$firstperson = false;
$firstperson is only used to keep track (since TGE 1.4 I think)