Skip to content

Commit fcc4138

Browse files
ShaurenOvahlord
authored andcommitted
Tools/Misc: Document strange array access indexing
1 parent c0634ae commit fcc4138

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/tools/map_extractor/System.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -511,6 +511,7 @@ bool ConvertADT(std::string const& inputPath, std::string const& outputPath, int
511511
// Set map height as grid height
512512
for (int y = 0; y <= ADT_CELL_SIZE; y++)
513513
{
514+
// edge V9s are overlapping between cells (i * ADT_CELL_SIZE is correct, otherwise we would be missing a row/column of V8s between)
514515
int cy = mcnk->iy * ADT_CELL_SIZE + y;
515516
for (int x = 0; x <= ADT_CELL_SIZE; x++)
516517
{
@@ -536,6 +537,7 @@ bool ConvertADT(std::string const& inputPath, std::string const& outputPath, int
536537
// get V9 height map
537538
for (int y = 0; y <= ADT_CELL_SIZE; y++)
538539
{
540+
// edge V9s are overlapping between cells (i * ADT_CELL_SIZE is correct, otherwise we would be missing a row/column of V8s between)
539541
int cy = mcnk->iy * ADT_CELL_SIZE + y;
540542
for (int x = 0; x <= ADT_CELL_SIZE; x++)
541543
{

0 commit comments

Comments
 (0)