From a813ceacbfb5f886db24c01f99b7f4c564a0e39b Mon Sep 17 00:00:00 2001 From: havoc Date: Fri, 30 Aug 2002 02:20:42 +0000 Subject: [PATCH] fixed bug which caused all models to be untextured if they used internal skins git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2313 d7cf8633-e32d-0410-b094-e92efae38249 --- model_alias.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/model_alias.c b/model_alias.c index 6e765549..c62cb9c9 100644 --- a/model_alias.c +++ b/model_alias.c @@ -224,12 +224,12 @@ static int Mod_LoadExternalSkin (char *basename, skinframe_t *skinframe, int pre skinframe->shirt = loadtextureimage(loadmodel->texturepool, va("%s_shirt" , basename), 0, 0, false, r_mipskins.integer, precache); skinframe->glow = loadtextureimage(loadmodel->texturepool, va("%s_glow" , basename), 0, 0, false, r_mipskins.integer, precache); skinframe->merged = NULL; - return skinframe->base != NULL || skinframe->pants != NULL || skinframe->shirt != NULL || skinframe->glow != NULL || skinframe->merged != NULL || skinframe->fog != NULL; + return skinframe->base != NULL || skinframe->pants != NULL || skinframe->shirt != NULL || skinframe->glow != NULL; } static int Mod_LoadInternalSkin (char *basename, qbyte *skindata, qbyte *skintemp, int width, int height, skinframe_t *skinframe, int precache) { - if (skindata && skintemp) + if (!skindata || !skintemp) return false; skinframe->pants = GL_SkinSplitShirt(skindata, skintemp, width, height, 0x0040, va("%s_pants", basename), false); // pants skinframe->shirt = GL_SkinSplitShirt(skindata, skintemp, width, height, 0x0002, va("%s_shirt", basename), false); // shirt -- 2.39.2