summaryrefslogtreecommitdiff
path: root/src/cgame
diff options
context:
space:
mode:
Diffstat (limited to 'src/cgame')
-rw-r--r--src/cgame/cg_draw.c2
-rw-r--r--src/cgame/cg_local.h2
-rw-r--r--src/cgame/cg_players.c4
3 files changed, 4 insertions, 4 deletions
diff --git a/src/cgame/cg_draw.c b/src/cgame/cg_draw.c
index f97bf9b6..0eab8bef 100644
--- a/src/cgame/cg_draw.c
+++ b/src/cgame/cg_draw.c
@@ -2261,7 +2261,7 @@ static void CG_DrawLocation( rectDef_t *rect, float scale, int textalign, vec4_t
float tx = rect->x, ty = rect->y;
maxX = rect->x + rect->w;
- locent = CG_GetLocation( &cg_entities[ cg.clientNum ] );
+ locent = CG_GetPlayerLocation( );
if( locent )
location = CG_ConfigString( CS_LOCATIONS + locent->currentState.generic1 );
else
diff --git a/src/cgame/cg_local.h b/src/cgame/cg_local.h
index 0169ff77..cb638702 100644
--- a/src/cgame/cg_local.h
+++ b/src/cgame/cg_local.h
@@ -1663,7 +1663,7 @@ void CG_PrecacheClientInfo( class_t class, char *model, char *skin );
sfxHandle_t CG_CustomSound( int clientNum, const char *soundName );
void CG_PlayerDisconnect( vec3_t org );
void CG_Bleed( vec3_t origin, vec3_t normal, int entityNum );
-centity_t *CG_GetLocation( centity_t *cent );
+centity_t *CG_GetPlayerLocation( void );
//
// cg_buildable.c
diff --git a/src/cgame/cg_players.c b/src/cgame/cg_players.c
index 8bd0457c..bd53eb20 100644
--- a/src/cgame/cg_players.c
+++ b/src/cgame/cg_players.c
@@ -2370,7 +2370,7 @@ void CG_PlayerDisconnect( vec3_t org )
}
}
-centity_t *CG_GetLocation( centity_t *cent )
+centity_t *CG_GetPlayerLocation( void )
{
centity_t *eloc, *best;
float bestlen, len;
@@ -2379,7 +2379,7 @@ centity_t *CG_GetLocation( centity_t *cent )
best = NULL;
bestlen = 3.0f * 8192.0f * 8192.0f;
- VectorCopy( cent->lerpOrigin, origin );
+ VectorCopy( cg.predictedPlayerState.origin, origin );
for( eloc = cg.locationHead; eloc; eloc = eloc->nextLocation )
{