comparison Events.cpp @ 1399:91ff22cc755b

Слияние
author Ritor1
date Thu, 18 Jul 2013 09:40:14 +0600
parents b51332ab228f
children 934074e7fcc1
comparison
equal deleted inserted replaced
1398:8557d021a31b 1399:91ff22cc755b
954 pMouse->RemoveHoldingItem(); 954 pMouse->RemoveHoldingItem();
955 ++curr_seq_num; 955 ++curr_seq_num;
956 v4 = v124; 956 v4 = v124;
957 break; 957 break;
958 } 958 }
959 v67 = (int)pPlayers[uActiveCharacter]->pInventoryIndices; 959 v67 = (int)pPlayers[uActiveCharacter]->pInventoryMatrix;
960 for ( v65 = 0; v65 < 126; ++v65 ) 960 for ( v65 = 0; v65 < 126; ++v65 )
961 { 961 {
962 if ( (int)&pPlayers[uActiveCharacter]->pInventoryItems[v67] == pValue ) 962 if ( (int)&pPlayers[uActiveCharacter]->pInventoryItemList[v67] == pValue )
963 { 963 {
964 pPlayers[uActiveCharacter]->RemoveItemAtInventoryIndex(v65); 964 pPlayers[uActiveCharacter]->RemoveItemAtInventoryIndex(v65);
965 ++curr_seq_num; 965 ++curr_seq_num;
966 v4 = v124; 966 v4 = v124;
967 break; 967 break;
970 } 970 }
971 while ( (signed int)v65 < 126 ); 971 while ( (signed int)v65 < 126 );
972 v69 = (int)&pPlayers[uActiveCharacter]->pEquipment; 972 v69 = (int)&pPlayers[uActiveCharacter]->pEquipment;
973 for ( v68 = 0; v68 < 16; ++v68 ) 973 for ( v68 = 0; v68 < 16; ++v68 )
974 { 974 {
975 if ( *(int *)v69 && (int)&pPlayers[uActiveCharacter]->pInventoryItems[v69] == pValue ) 975 if ( *(int *)v69 && (int)&pPlayers[uActiveCharacter]->pInventoryItemList[v69] == pValue )
976 { 976 {
977 *(&pPlayers[uActiveCharacter]->pEquipment.uShield + v68) = 0; 977 *(&pPlayers[uActiveCharacter]->pEquipment.uShield + v68) = 0;
978 ++curr_seq_num; 978 ++curr_seq_num;
979 v4 = v124; 979 v4 = v124;
980 break; 980 break;
981 } 981 }
982 v69 += 4; 982 v69 += 4;
983 } 983 }
984 for (int i = 1; i < 5; i++) 984 for (int i = 1; i < 5; i++)
985 { 985 {
986 v72 = (int)pPlayers[i]->pInventoryIndices; 986 v72 = (int)pPlayers[i]->pInventoryMatrix;
987 for ( int v71 = 0; v71 < 126; ++v71 ) 987 for ( int v71 = 0; v71 < 126; ++v71 )
988 { 988 {
989 if ( (int)&pPlayers[i]->pInventoryItems[v72] == pValue ) 989 if ( (int)&pPlayers[i]->pInventoryItemList[v72] == pValue )
990 { 990 {
991 pPlayers[i]->RemoveItemAtInventoryIndex(v71); 991 pPlayers[i]->RemoveItemAtInventoryIndex(v71);
992 break; 992 break;
993 } 993 }
994 v72 += 4; 994 v72 += 4;
995 } 995 }
996 v73 = 0; 996 v73 = 0;
997 v74 = (int)&pPlayers[i]->pEquipment; 997 v74 = (int)&pPlayers[i]->pEquipment;
998 while ( !*(int *)v74 || (int)&pPlayer->pInventoryItems[v74] != pValue ) 998 while ( !*(int *)v74 || (int)&pPlayer->pInventoryItemList[v74] != pValue )
999 { 999 {
1000 ++v73; 1000 ++v73;
1001 v74 += 4; 1001 v74 += 4;
1002 if ( v73 >= 16 ) 1002 if ( v73 >= 16 )
1003 break; 1003 break;