Billtcm
Newbie
- Joined
- Nov 23, 2004
- Messages
- 92
- Reaction score
- 0
Hey guys just started messing around with the code trying to get a third-person view and I'm having a little trouble. I'm using the microsoft visual .net 2003 and I've opened the "in_camera.cpp" in client/source files. I have noticed that when I compile it says with the build that 1 has failed, yet I have managed to get third person view and it even fails when I have not altered the code. Now I've done a few things and have only gotten one small effect, the first thing I did was comment out
After that I changed a few values, the values underneath are what I got after a bunch of tries.
yet with all these changes I've only managed to get this effect so far
By the way after I compile a ".cpp" do I have to completely exit out of the mod and restart it, or can I just type "restart", or "reload" in console. If you guys can help me I'd appreciate it.
Code:
if ( gpGlobals->maxClients > 1 )
{
// no thirdperson in multiplayer.
return;
}
After that I changed a few values, the values underneath are what I got after a bunch of tries.
Code:
#define CAM_DIST_DELTA 1.0
#define CAM_ANGLE_DELTA 2.5
#define CAM_ANGLE_SPEED 2.5
#define CAM_MIN_DIST 30.0
#define CAM_ANGLE_MOVE .5
#define MAX_ANGLE_DIFF 10.0
#define PITCH_MAX 180.0
#define PITCH_MIN 0
#define YAW_MAX 180.0
#define YAW_MIN -135.0
//-------------------------------------------------- Global Variables
static ConVar cam_command( "cam_command", "0", FCVAR_CHEAT | FCVAR_ARCHIVE ); // tells camera to go to thirdperson
static ConVar cam_snapto( "cam_snapto", "0", FCVAR_ARCHIVE ); // snap to thirdperson view
static ConVar cam_idealyaw( "cam_idealyaw", "90", FCVAR_ARCHIVE ); // thirdperson yaw
static ConVar cam_idealpitch( "cam_idealpitch", "180", FCVAR_ARCHIVE ); // thirperson pitch
static ConVar cam_idealdist( "cam_idealdist", "300", FCVAR_ARCHIVE ); // thirdperson distance
static ConVar c_maxpitch( "c_maxpitch", "180", FCVAR_ARCHIVE );
static ConVar c_minpitch( "c_minpitch", "0", FCVAR_ARCHIVE );
static ConVar c_maxyaw( "c_maxyaw", "135", FCVAR_ARCHIVE );
static ConVar c_minyaw( "c_minyaw", "-135", FCVAR_ARCHIVE );
static ConVar c_maxdistance( "c_maxdistance", "200", FCVAR_ARCHIVE );
static ConVar c_mindistance( "c_mindistance", "30", FCVAR_ARCHIVE );
static ConVar c_orthowidth( "c_orthowidth", "100", FCVAR_ARCHIVE );
static ConVar c_orthoheight( "c_orthoheight", "100", FCVAR_ARCHIVE );
yet with all these changes I've only managed to get this effect so far
By the way after I compile a ".cpp" do I have to completely exit out of the mod and restart it, or can I just type "restart", or "reload" in console. If you guys can help me I'd appreciate it.