# HG changeset patch # User Ritor1 # Date 1362572527 -21600 # Node ID 653724e9c23426a852e01f606bd8cc6ea0490253 # Parent 0193f10fecbf4109bc97838e155cabd4a4a8a2ab m diff -r 0193f10fecbf -r 653724e9c234 Chest.cpp --- a/Chest.cpp Sun Mar 03 18:39:35 2013 +0600 +++ b/Chest.cpp Wed Mar 06 18:22:07 2013 +0600 @@ -581,21 +581,21 @@ uChestArea = pChestWidthsByType[pChests[uChestID].uChestBitmapID] * pChestHeightsByType[pChests[uChestID].uChestBitmapID]; memset(chest_cells_map, 0, 144); //fill cell map at random positions - for (items_counter = 0; items_counter= uChestArea ); //if this pos occupied move to next while ( chest_cells_map[random_chest_pos] ) - { + { ++random_chest_pos; if ( random_chest_pos == uChestArea ) random_chest_pos = 0; - } + } chest_cells_map[random_chest_pos] = items_counter; - } + } items_counter = 0; for (items_counter = 0; items_counterDrawStrip(_this.uNumVertices, &_this, - pBitmaps_LOD->pHardwareTextures[_this.uTileBitmapID]); - return; + pRenderer->DrawStrip(_this.uNumVertices, &_this, pBitmaps_LOD->pHardwareTextures[_this.uTileBitmapID]); + return; }