# HG changeset patch
# User Ritor1
# Date 1362193150 -21600
# Node ID db4631a484ae0817d951fd896402b66a3828a210
# Parent 55d0794848d1a6102865c28c4506788346340eb2
m
diff -r 55d0794848d1 -r db4631a484ae Chest.cpp
--- a/Chest.cpp Sat Mar 02 00:24:27 2013 +0600
+++ b/Chest.cpp Sat Mar 02 08:59:10 2013 +0600
@@ -89,7 +89,7 @@
//v1 = (char *)&pChests[uChestID].uFlags;
//v34 = v1;
if (!chest->Initialized())
- Chest::_420284(uChestID);
+ Chest::PlacementItems(uChestID);
if ( !uActiveCharacter )
return 0;
@@ -294,8 +294,7 @@
if ( v6 > 0 )
{
v17 = v18 + 32 * v23 / v19;
- v7 = pIcons_LOD->LoadTexture(
- pItemsTable->pItems[*(int *)((char *)&pOtherOverlayList->pOverlays[49].field_4 + 36 * v6 + v3 * 5324)].pIconName,
+ v7 = pIcons_LOD->LoadTexture(pItemsTable->pItems[*(int *)((char *)&pChests[v3].mm7__vector_pItems[v6 - 1].uItemID)].pIconName,
TEXTURE_16BIT_PALETTE);
v8 = (Texture *)(v7 != -1 ? &pIcons_LOD->pTextures[v7] : 0);
v9 = (v7 != -1 ? pIcons_LOD->pTextures[v7].uTextureWidth : 24);
@@ -616,7 +615,7 @@
// 506128: using guessed type int areWeLoadingTexture;
//----- (00420284) --------------------------------------------------------
-char *Chest::_420284(unsigned int uChestID)
+char *Chest::PlacementItems(unsigned int uChestID)
{
int v1; // ebx@1
unsigned int v2; // esi@1
@@ -662,7 +661,7 @@
do
{
v9 = v12->uItemID;
- if ( v9 > 0 )
+ if ( v9 )
{
v6 = 0;
while ( !Chest::CanPlaceItemAt((unsigned __int8)Dst[v6], v9, v10) )
@@ -671,7 +670,7 @@
if ( v6 >= uChestArea )
break;
}
- if(v6
-
@@ -202,6 +201,7 @@
+
@@ -258,7 +258,6 @@
-
@@ -321,6 +320,7 @@
+