Mercurial > mm7
diff UI/UICharacter.cpp @ 1365:b691c96d8e06
Player::FindFreeInventorySlot and Player::CreateItemInInventory refactoring
author | Grumpy7 |
---|---|
date | Mon, 15 Jul 2013 02:34:52 +0200 |
parents | 61010a655c94 |
children | b51332ab228f |
line wrap: on
line diff
--- a/UI/UICharacter.cpp Mon Jul 15 02:14:39 2013 +0200 +++ b/UI/UICharacter.cpp Mon Jul 15 02:34:52 2013 +0200 @@ -2640,7 +2640,7 @@ unsigned __int16 v5; // ax@7 unsigned int v6; // edi@19 int v7; // esi@27 - unsigned int v8; // eax@29 + int v8; // eax@29 int v9; // edx@32 int v10; // esi@34 int v11; // eax@34 @@ -2655,10 +2655,10 @@ int v20; // esi@60 int v21; // eax@60 unsigned int v22; // eax@61 - unsigned int v23; // eax@62 + int v23; // eax@62 int v24; // esi@65 int v25; // eax@65 - unsigned int v26; // eax@69 + int v26; // eax@69 int v27; // esi@81 int v28; // eax@81 int v29; // esi@84 @@ -2677,7 +2677,7 @@ unsigned int v49; // [sp+34h] [bp-18h]@57 unsigned int v50; // [sp+38h] [bp-14h]@50 int v51; // [sp+3Ch] [bp-10h]@1 - unsigned int v52; // [sp+40h] [bp-Ch]@5 + int v52; // [sp+40h] [bp-Ch]@5 //int v53; // [sp+44h] [bp-8h]@1 //unsigned int v54; // [sp+48h] [bp-4h]@1 @@ -2772,7 +2772,7 @@ if ( !*(int *)v7 ) { v8 = pPlayers[uActiveCharacter]->FindFreeInventorySlot(); - if ( (v8 & 0x80000000u) == 0 ) + if ( v8 >= 0 ) { v9 = v52; pParty->pPickedItem.uBodyAnchor = v52 + 1; @@ -2831,7 +2831,7 @@ else { v52 = pPlayers[uActiveCharacter]->FindFreeInventorySlot(); - if ( (v52 & 0x80000000u) != 0 ) + if ( v52 < 0 ) return; if ( !v51 ) { @@ -2906,7 +2906,7 @@ break; } v23 = pPlayers[uActiveCharacter]->FindFreeInventorySlot(); - if ( (v23 & 0x80000000u) != 0 ) + if ( v23 < 0 ) return; pParty->pPickedItem.uBodyAnchor = 1; v50 = (unsigned int)&pPlayers[uActiveCharacter]->pInventoryItems[v23]; @@ -2929,7 +2929,7 @@ if ( !v1 ) { v26 = pPlayers[uActiveCharacter]->FindFreeInventorySlot(); - if ( (v26 & 0x80000000u) != 0 ) + if ( v26 < 0 ) return; pParty->pPickedItem.uBodyAnchor = 2; v50 = (unsigned int)&pPlayers[uActiveCharacter]->pInventoryItems[v26]; @@ -3000,7 +3000,7 @@ else { v52 = pPlayers[uActiveCharacter]->FindFreeInventorySlot(); - if ( (v52 & 0x80000000u) == 0 ) + if ( v52 >= 0 ) { if ( v2 ) {