mirror of https://github.com/FWGS/hlsdk-xash3d
Fix warnings.
This commit is contained in:
parent
4b5e94a986
commit
b22ea2889f
|
@ -463,7 +463,7 @@ void Dmc_TouchTeleporters ( struct local_state_s *player, dmc_tele_t *pTeles, i
|
|||
//This comes via an event when the player connects.
|
||||
if ( !g_bLoadedTeles )
|
||||
{
|
||||
for ( int j = 0; j < 3; j++ )
|
||||
for( j = 0; j < 3; j++ )
|
||||
{
|
||||
pTele->absmin[ j ] = g_vecTeleMins[ iTeleNum ][ j ] - 1.0;
|
||||
pTele->absmax[ j ] = g_vecTeleMaxs[ iTeleNum ][ j ] + 1.0;
|
||||
|
|
|
@ -716,13 +716,11 @@ void EV_FireLightning( event_args_t *args )
|
|||
int idx;
|
||||
vec3_t origin, endorigin;
|
||||
vec3_t angles;
|
||||
vec3_t vecEnd;
|
||||
vec3_t up, right, forward;
|
||||
int iShutDown;
|
||||
|
||||
cl_entity_t *player;
|
||||
|
||||
pmtrace_t tr;
|
||||
int modelIndex;
|
||||
|
||||
bool bSound = false;
|
||||
|
@ -750,7 +748,7 @@ void EV_FireLightning( event_args_t *args )
|
|||
|
||||
V_PunchAxis( 0, Q_SMALL_PUNCHANGLE_KICK );
|
||||
|
||||
cl_entity_t *player = gEngfuncs.GetViewModel();
|
||||
player = gEngfuncs.GetViewModel();
|
||||
origin = player->attachment[0];
|
||||
}
|
||||
else
|
||||
|
@ -767,7 +765,7 @@ void EV_FireLightning( event_args_t *args )
|
|||
|
||||
if ( iShutDown == 0 && EV_IsLocal( idx ) && pBeam == NULL )
|
||||
{
|
||||
vec3_t vecSrc, vecEnd, origin, angles, forward, right, up;
|
||||
vec3_t vecSrc, vecEnd;
|
||||
pmtrace_t tr;
|
||||
|
||||
cl_entity_t *pl = gEngfuncs.GetEntityByIndex( idx );
|
||||
|
|
|
@ -448,7 +448,7 @@ BOOL CQuakeGun::Deploy( )
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
int HUD_GetModelIndex( char *modelname )
|
||||
int HUD_GetModelIndex( const char *modelname )
|
||||
{
|
||||
int retval = 0;
|
||||
gEngfuncs.CL_LoadModel( modelname, &retval );
|
||||
|
|
|
@ -1373,7 +1373,6 @@ void V_CalcSpectatorRefdef( struct ref_params_s *pparams )
|
|||
if( i < ORIGIN_MASK && ViewInterp.OriginTime[foundidx & ORIGIN_MASK] != 0.0 )
|
||||
{
|
||||
// Interpolate
|
||||
vec3_t delta;
|
||||
double frac;
|
||||
double dt;
|
||||
vec3_t neworg;
|
||||
|
|
|
@ -103,7 +103,7 @@ CBasePlayer* AgPlayerByIndex(int iPlayerIndex )
|
|||
CBaseEntity* pEnt = (CBaseEntity *)CBaseEntity::Instance( pPlayerEdict );
|
||||
if (pEnt && pEnt->pev && CLASS_PLAYER == pEnt->Classify())
|
||||
{
|
||||
if (pEnt->pev->netname && 0 != STRING(pEnt->pev->netname)[0])
|
||||
if (pEnt->pev->netname && 0 != ( STRING( pEnt->pev->netname ) )[0])
|
||||
{
|
||||
pPlayer = (CBasePlayer*)pEnt;
|
||||
}
|
||||
|
|
|
@ -94,7 +94,7 @@ void CBasePlayer::Spectate_Start()
|
|||
|
||||
EnableControl(TRUE);
|
||||
|
||||
if ( m_pTank != NULL )
|
||||
if ( m_pTank != 0 )
|
||||
{
|
||||
m_pTank->Use( this, this, USE_OFF, 0 );
|
||||
m_pTank = NULL;
|
||||
|
|
|
@ -783,7 +783,7 @@ public:
|
|||
};
|
||||
|
||||
// QUAKECLASSIC
|
||||
extern char *g_szDeathType;
|
||||
extern const char *g_szDeathType;
|
||||
|
||||
//++ BulliT
|
||||
#endif //_CBASE_H_
|
||||
|
|
|
@ -113,12 +113,12 @@ void CBasePlayer::Observer_SetMode( int iMode )
|
|||
iMode = OBS_IN_EYE; // now it is
|
||||
|
||||
// if we are not roaming, we need a valid target to track
|
||||
if ( (iMode != OBS_ROAMING) && (m_hObserverTarget == NULL) )
|
||||
if ( (iMode != OBS_ROAMING) && (m_hObserverTarget == 0) )
|
||||
{
|
||||
Observer_FindNextPlayer();
|
||||
|
||||
// if we didn't find a valid target switch to roaming
|
||||
if (m_hObserverTarget == NULL)
|
||||
if (m_hObserverTarget == 0)
|
||||
{
|
||||
ClientPrint( pev, HUD_PRINTCENTER, "#Spec_NoTarget" );
|
||||
iMode = OBS_ROAMING;
|
||||
|
@ -139,4 +139,4 @@ void CBasePlayer::Observer_SetMode( int iMode )
|
|||
char modemsg[16];
|
||||
sprintf(modemsg,"#Spec_Mode%i", iMode);
|
||||
ClientPrint( pev, HUD_PRINTCENTER, modemsg );
|
||||
}
|
||||
}
|
||||
|
|
|
@ -132,9 +132,9 @@ void CBasePlayer::W_SetCurrentAmmo( int sendanim /* = 1 */ )
|
|||
{
|
||||
m_iQuakeItems &= ~(IT_SHELLS | IT_NAILS | IT_ROCKETS | IT_CELLS);
|
||||
int iszViewModel = 0;
|
||||
char *viewmodel = "";
|
||||
const char *viewmodel = "";
|
||||
int iszWeaponModel = 0;
|
||||
char *szAnimExt;
|
||||
const char *szAnimExt;
|
||||
|
||||
// Find out what weapon the player's using
|
||||
if (m_iQuakeWeapon == IT_AXE)
|
||||
|
@ -223,7 +223,8 @@ void CBasePlayer::W_SetCurrentAmmo( int sendanim /* = 1 */ )
|
|||
#else
|
||||
{
|
||||
|
||||
int HUD_GetModelIndex( char *modelname );
|
||||
extern int HUD_GetModelIndex( const char *modelname );
|
||||
|
||||
pev->viewmodel = HUD_GetModelIndex( viewmodel );
|
||||
|
||||
cl_entity_t *view;
|
||||
|
|
|
@ -47,7 +47,7 @@ bool g_bHaveMOTD;
|
|||
#define WEAPON_RESPAWN_TIME 20
|
||||
#define AMMO_RESPAWN_TIME 20
|
||||
|
||||
char *g_szDeathType;
|
||||
const char *g_szDeathType;
|
||||
float g_flIntermissionStartTime = 0;
|
||||
|
||||
#ifndef NO_VOICEGAMEMGR
|
||||
|
|
|
@ -4716,7 +4716,7 @@ bool CBasePlayer::RespawnMatch()
|
|||
//Remove all weapons/items
|
||||
RemoveAllItemsNoClientMessage();
|
||||
|
||||
if( m_pTank != NULL )
|
||||
if( m_pTank != 0 )
|
||||
{
|
||||
m_pTank->Use( this, this, USE_OFF, 0 );
|
||||
m_pTank = NULL;
|
||||
|
|
|
@ -446,7 +446,7 @@ public:
|
|||
//++ BulliT
|
||||
inline const char *CBasePlayer::GetName()
|
||||
{
|
||||
return pev->netname ? STRING( pev->netname )[0] ? STRING( pev->netname ) : "" : "";
|
||||
return pev->netname ? ( ( STRING( pev->netname ) )[0] ? STRING( pev->netname ) : "" ) : "";
|
||||
};
|
||||
|
||||
inline bool CBasePlayer::IsIngame()
|
||||
|
|
Loading…
Reference in New Issue