From e204f05726a9af21290bb502287b1bc6abadea91 Mon Sep 17 00:00:00 2001 From: SNMetamorph <25657591+SNMetamorph@users.noreply.github.com> Date: Tue, 22 Nov 2022 18:54:01 +0400 Subject: [PATCH] engine: client: fixed players spray textures not being updated --- engine/client/cl_tent.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/engine/client/cl_tent.c b/engine/client/cl_tent.c index 8158ce2c..451eab3d 100644 --- a/engine/client/cl_tent.c +++ b/engine/client/cl_tent.c @@ -2928,8 +2928,10 @@ void CL_PlayerDecal( int playernum, int customIndex, int entityIndex, float *pos { if( !pCust->nUserData1 ) { + qboolean updateSprayTexture; const char *decalname = va( "player%dlogo%d", playernum, customIndex ); - pCust->nUserData1 = GL_LoadTextureInternal( decalname, pCust->pInfo, TF_DECAL ); + updateSprayTexture = ref.dllFuncs.GL_FindTexture( decalname ) != 0; + pCust->nUserData1 = ref.dllFuncs.GL_LoadTextureFromBuffer( decalname, pCust->pInfo, TF_DECAL, updateSprayTexture ); } textureIndex = pCust->nUserData1; }