From 331b1945a068a0f017228d9f07d96af1102ec657 Mon Sep 17 00:00:00 2001 From: Lee Salzman Date: Wed, 6 Mar 2013 05:09:24 +0200 Subject: [PATCH] texture slot spec fix --- src/engine/texture.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/engine/texture.cpp b/src/engine/texture.cpp index b2304ff..2b65616 100644 --- a/src/engine/texture.cpp +++ b/src/engine/texture.cpp @@ -1694,6 +1694,8 @@ const struct slottex } slottexs[] = { {"0", TEX_DIFFUSE}, + {"1", TEX_UNKNOWN}, + {"c", TEX_DIFFUSE}, {"d", TEX_DECAL}, {"n", TEX_NORMAL}, @@ -1717,7 +1719,7 @@ void texture(char *type, char *name, int *rot, int *xoffset, int *yoffset, float if(slots.length()>=0x10000) return; static int lastmatslot = -1; int tnum = findslottex(type), matslot = findmaterial(type); - if(tnum<0) tnum = atoi(type) ? TEX_UNKNOWN : 0; + if(tnum<0) tnum = TEX_UNKNOWN; if(tnum==TEX_DIFFUSE) lastmatslot = matslot; else if(lastmatslot>=0) matslot = lastmatslot; else if(slots.empty()) return;