Thirdperson-OrangeBox: Difference between revisions
Jump to navigation
Jump to search
(Created page that people can find when searching for how to do third-person in orangebox. Consolidated some info from the discussion page into a stub.) |
(→Spawning players in thirdperson: added <tt> tags to the sv_cheats convar) |
||
Line 22: | Line 22: | ||
Then, to keep Source from changing it back to firstperson, disable the sv_cheats check by commenting out the following lines in <tt>CAM_Think</tt> | Then, to keep Source from changing it back to firstperson, disable the <tt>sv_cheats</tt> check by commenting out the following lines in <tt>CAM_Think</tt> | ||
<code>// If cheats have been disabled, pull us back out of third-person view. | <code>// If cheats have been disabled, pull us back out of third-person view. | ||
if ( sv_cheats && !sv_cheats->GetBool() ) | if ( sv_cheats && !sv_cheats->GetBool() ) |
Revision as of 05:25, 26 October 2010
Enabling thirdperson
in the developer console,
sv_cheats 1
thirdperson
Spawning players in thirdperson
Make the following changes to in_camera.cpp:
- change
void CInput::Init_Camera( void )
{
m_CameraIsOrthographic = false;
}
to
void CInput::Init_Camera( void )
{
m_CameraIsOrthographic = false;
m_fCameraInThirdPerson = true;
}
Then, to keep Source from changing it back to firstperson, disable the sv_cheats check by commenting out the following lines in CAM_Think
// If cheats have been disabled, pull us back out of third-person view.
if ( sv_cheats && !sv_cheats->GetBool() )
{
CAM_ToFirstPerson();
return;
}
change to:
/* We're using a third-person camera, don't mess with it
// If cheats have been disabled, pull us back out of third-person view.
if ( sv_cheats && !sv_cheats->GetBool() )
{
CAM_ToFirstPerson();
return;
}
*/
Credits:
AndreZero
and
Bluestrike
http://developer.valvesoftware.com/wiki/Talk:Third-person_camera#Start_the_player_in_Third_Person