From cd20d707d435f561c1fbe17a3acc0442029110d8 Mon Sep 17 00:00:00 2001 From: Marisa the Magician Date: Mon, 25 Jul 2022 10:45:59 +0200 Subject: [PATCH] Fix incorrect mapping of texture indices for UE1 models. --- src/common/models/models_ue1.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/common/models/models_ue1.cpp b/src/common/models/models_ue1.cpp index f76f13eff1..0f4ae7f43a 100644 --- a/src/common/models/models_ue1.cpp +++ b/src/common/models/models_ue1.cpp @@ -246,8 +246,9 @@ void FUE1Model::RenderFrame( FModelRenderer *renderer, FGameTexture *skin, int f FGameTexture *sskin = skin; if ( !sskin ) { - if (surfaceskinids && surfaceskinids[i].isValid()) - sskin = TexMan.GetGameTexture(surfaceskinids[i], true); + int ssIndex = groups[i].texNum; + if (surfaceskinids && surfaceskinids[ssIndex].isValid()) + sskin = TexMan.GetGameTexture(surfaceskinids[ssIndex], true); if ( !sskin ) { vofs += vsize;