Mercurial > mm7
comparison Items.cpp @ 2495:7b076fe64f23
GetItemTextureFilename fix
author | Ritor1 |
---|---|
date | Wed, 17 Sep 2014 17:35:13 +0600 |
parents | b054ea5daf45 |
children | 5abd8fc8f1c6 |
comparison
equal
deleted
inserted
replaced
2494:de8c5c223e9c | 2495:7b076fe64f23 |
---|---|
2106 } | 2106 } |
2107 //----- (0043C91D) -------------------------------------------------------- | 2107 //----- (0043C91D) -------------------------------------------------------- |
2108 int GetItemTextureFilename(char *pOut, signed int item_id, int index, int shoulder) | 2108 int GetItemTextureFilename(char *pOut, signed int item_id, int index, int shoulder) |
2109 { | 2109 { |
2110 int result; // eax@2 | 2110 int result; // eax@2 |
2111 ITEM_EQUIP_TYPE pEquipType; | |
2111 | 2112 |
2112 result = 0; //BUG fn is void | 2113 result = 0; //BUG fn is void |
2114 pEquipType = pItemsTable->pItems[item_id].uEquipType; | |
2113 if ( item_id > 500 ) | 2115 if ( item_id > 500 ) |
2114 { | 2116 { |
2115 switch ( item_id ) | 2117 switch ( item_id ) |
2116 { | 2118 { |
2117 case ITEM_RELIC_HARECS_LEATHER: | 2119 case ITEM_RELIC_HARECS_LEATHER: |
2185 default: | 2187 default: |
2186 return 0; | 2188 return 0; |
2187 } | 2189 } |
2188 } | 2190 } |
2189 | 2191 |
2190 switch (pItemsTable->pItems[item_id].uEquipType) | 2192 switch (pEquipType) |
2191 { | 2193 { |
2192 case EQUIP_ARMOUR: | 2194 case EQUIP_ARMOUR: |
2193 if ( !shoulder ) | 2195 if ( !shoulder ) |
2194 return sprintf(pOut, "item%3.3dv%d", item_id, index); | 2196 return sprintf(pOut, "item%3.3dv%d", item_id, index); |
2195 else if ( shoulder == 1 ) | 2197 else if ( shoulder == 1 ) |