diff UI/UICharacter.cpp @ 2289:60293358b4b3

byte_5111F6 to byte_5111F6_OwnedArtifacts, changed magic numbers to enums in GetItemTextureFilename
author Grumpy7
date Sun, 16 Mar 2014 03:08:26 +0100
parents aff7a7b072b7
children ddb803517a48
line wrap: on
line diff
--- a/UI/UICharacter.cpp	Sun Mar 16 02:59:52 2014 +0100
+++ b/UI/UICharacter.cpp	Sun Mar 16 03:08:26 2014 +0100
@@ -1764,28 +1764,28 @@
       }
     }
   }
-  memset(byte_5111F6.data(), 0, sizeof(byte_5111F6));
+  memset(byte_5111F6_OwnedArtifacts.data(), 0, sizeof(byte_5111F6_OwnedArtifacts));
   for (uint i = 0; i < 4; ++i)
   {
     Player* player = &pParty->pPlayers[i];
 
-    if (player->HasItem(ITEM_ARTIFACT_GOVERNORS_ARMOR, 1))    byte_5111F6[0] = 1;
-    if (player->HasItem(ITEM_ARTIFACT_YORUBA, 1))             byte_5111F6[1] = 1;
-    if (player->HasItem(ITEM_RELIC_HARECS_LEATHER, 1))        byte_5111F6[2] = 1;
-    if (player->HasItem(ITEM_ARTIFACT_LEAGUE_BOOTS, 1))       byte_5111F6[3] = 1;
-    if (player->HasItem(ITEM_RELIC_TALEDONS_HELM, 1))         byte_5111F6[4] = 1;
-    if (player->HasItem(ITEM_RELIC_SCHOLARS_CAP, 1))          byte_5111F6[5] = 1;
-    if (player->HasItem(ITEM_RELIC_PHYNAXIAN_CROWN, 1))       byte_5111F6[6] = 1;
-    if (player->HasItem(ITEM_ARTIFACT_MINDS_EYE, 1))          byte_5111F6[7] = 1;
-    if (player->HasItem(ITEM_RARE_SHADOWS_MASK, 1))           byte_5111F6[8] = 1;
-    if (player->HasItem(ITEM_RILIC_TITANS_BELT, 1))           byte_5111F6[9] = 1;
-    if (player->HasItem(ITEM_ARTIFACT_HEROS_BELT, 1))         byte_5111F6[10] = 1;
-    if (player->HasItem(ITEM_RELIC_TWILIGHT, 1))              byte_5111F6[11] = 1;
-    if (player->HasItem(ITEM_ARTIFACT_CLOAK_OF_THE_SHEEP, 1)) byte_5111F6[12] = 1;
-    if (player->HasItem(ITEM_RARE_SUN_CLOAK, 1))              byte_5111F6[13] = 1;
-    if (player->HasItem(ITEM_RARE_MOON_CLOAK, 1))             byte_5111F6[14] = 1;
-    if (player->HasItem(ITEM_RARE_VAMPIRES_CAPE, 1))          byte_5111F6[15] = 1;
-    if (player->HasItem(ITEM_ELVEN_CHAINMAIL, 1))             byte_5111F6[16] = 1;
+    if (player->HasItem(ITEM_ARTIFACT_GOVERNORS_ARMOR, 1))    byte_5111F6_OwnedArtifacts[0] = 1;
+    if (player->HasItem(ITEM_ARTIFACT_YORUBA, 1))             byte_5111F6_OwnedArtifacts[1] = 1;
+    if (player->HasItem(ITEM_RELIC_HARECS_LEATHER, 1))        byte_5111F6_OwnedArtifacts[2] = 1;
+    if (player->HasItem(ITEM_ARTIFACT_LEAGUE_BOOTS, 1))       byte_5111F6_OwnedArtifacts[3] = 1;
+    if (player->HasItem(ITEM_RELIC_TALEDONS_HELM, 1))         byte_5111F6_OwnedArtifacts[4] = 1;
+    if (player->HasItem(ITEM_RELIC_SCHOLARS_CAP, 1))          byte_5111F6_OwnedArtifacts[5] = 1;
+    if (player->HasItem(ITEM_RELIC_PHYNAXIAN_CROWN, 1))       byte_5111F6_OwnedArtifacts[6] = 1;
+    if (player->HasItem(ITEM_ARTIFACT_MINDS_EYE, 1))          byte_5111F6_OwnedArtifacts[7] = 1;
+    if (player->HasItem(ITEM_RARE_SHADOWS_MASK, 1))           byte_5111F6_OwnedArtifacts[8] = 1;
+    if (player->HasItem(ITEM_RILIC_TITANS_BELT, 1))           byte_5111F6_OwnedArtifacts[9] = 1;
+    if (player->HasItem(ITEM_ARTIFACT_HEROS_BELT, 1))         byte_5111F6_OwnedArtifacts[10] = 1;
+    if (player->HasItem(ITEM_RELIC_TWILIGHT, 1))              byte_5111F6_OwnedArtifacts[11] = 1;
+    if (player->HasItem(ITEM_ARTIFACT_CLOAK_OF_THE_SHEEP, 1)) byte_5111F6_OwnedArtifacts[12] = 1;
+    if (player->HasItem(ITEM_RARE_SUN_CLOAK, 1))              byte_5111F6_OwnedArtifacts[13] = 1;
+    if (player->HasItem(ITEM_RARE_MOON_CLOAK, 1))             byte_5111F6_OwnedArtifacts[14] = 1;
+    if (player->HasItem(ITEM_RARE_VAMPIRES_CAPE, 1))          byte_5111F6_OwnedArtifacts[15] = 1;
+    if (player->HasItem(ITEM_ELVEN_CHAINMAIL, 1))             byte_5111F6_OwnedArtifacts[16] = 1;
   }
 
   for (uint i = 0; i < 2; ++i)