diff --git a/src/shared/client/cg_api.cpp b/src/shared/client/cg_api.cpp index da4c679f54..c530c58dd6 100644 --- a/src/shared/client/cg_api.cpp +++ b/src/shared/client/cg_api.cpp @@ -295,14 +295,9 @@ void trap_R_ClearScene() cmdBuffer.SendMsg(); } -/* HACK: We need the entityNum to get the correct positions for entities that need to be attached to another entity's bone -This must be equal to the r_numEntities in engine at the time of adding the entity */ -static int entityNum; -int trap_R_AddRefEntityToScene( const refEntity_t *re ) +void trap_R_AddRefEntityToScene( const refEntity_t *re ) { cmdBuffer.SendMsg(*re); - entityNum++; - return entityNum - 1; } void trap_R_SyncRefEntities( const std::vector& ents ) { @@ -380,7 +375,6 @@ void trap_R_AddLightToScene( const vec3_t origin, float radius, float intensity, void trap_R_RenderScene( const refdef_t *fd ) { - entityNum = 0; cmdBuffer.SendMsg(*fd); } diff --git a/src/shared/client/cg_api.h b/src/shared/client/cg_api.h index 69a2087035..bce1150daa 100644 --- a/src/shared/client/cg_api.h +++ b/src/shared/client/cg_api.h @@ -65,7 +65,7 @@ qhandle_t trap_R_RegisterModel( const char *name ); qhandle_t trap_R_RegisterSkin( const char *name ); qhandle_t trap_R_RegisterShader( const char *name, int flags ); void trap_R_ClearScene(); -int trap_R_AddRefEntityToScene( const refEntity_t *re ); +void trap_R_AddRefEntityToScene( const refEntity_t *re ); void trap_R_SyncRefEntities( const std::vector& ents ); std::vector trap_R_SyncLerpTags( const std::vector& lerpTags ); void trap_R_AddPolyToScene( qhandle_t hShader, int numVerts, const polyVert_t *verts );