From fa690896e59c129681762b28cbec45bc00670b33 Mon Sep 17 00:00:00 2001 From: Dethrace Labs <78985374+dethrace-labs@users.noreply.github.com> Date: Mon, 3 Nov 2025 10:19:27 +1300 Subject: [PATCH] LoadMaterial matching --- src/DETHRACE/common/loading.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/DETHRACE/common/loading.c b/src/DETHRACE/common/loading.c index 31dba56f..492c1cca 100644 --- a/src/DETHRACE/common/loading.c +++ b/src/DETHRACE/common/loading.c @@ -617,18 +617,21 @@ br_pixelmap* LoadShadeTable(char* pName) { // FUNCTION: CARM95 0x0041d4c8 br_material* LoadMaterial(char* pName) { tPath_name the_path; +#ifdef DETHRACE_3DFX_PATCH br_material* result; +#endif PossibleService(); PathCat(the_path, gApplication_path, "MATERIAL"); PathCat(the_path, the_path, pName); - result = BrMaterialLoad(the_path); + return BrMaterialLoad(the_path); #ifdef DETHRACE_3DFX_PATCH + result = BrMaterialLoad(the_path); if (result != NULL) { GlorifyMaterial(&result, 1); } -#endif return result; +#endif } // IDA: br_model* __usercall LoadModel@(char *pName@)