Skip to content

Commit

Permalink
Correct comments and adjust inside corner tile automap sort order (#87)
Browse files Browse the repository at this point in the history
  • Loading branch information
jaydavid authored Oct 12, 2024
1 parent 8e2df79 commit a8f1cb7
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions src/Murder/Assets/Graphics/TilesetAsset.cs
Original file line number Diff line number Diff line change
Expand Up @@ -98,17 +98,17 @@ public void CalculateAndDrawAutoTile(RenderContext render, int x, int y, bool to

// Top Left Inside Corner
if (topLeft && topRight && botLeft && !botRight)
DrawTile(batch, x, y, 1, 3, alpha, color, blend, -1);
DrawTile(batch, x, y, 1, 3, alpha, color, blend, 1);

// Top Right Inside Corner
if (topLeft && topRight && !botLeft && botRight)
DrawTile(batch, x, y, 2, 3, alpha, color, blend, -1);
DrawTile(batch, x, y, 2, 3, alpha, color, blend, 1);

// Top Left Inside Corner
// Bottom Left Inside Corner
if (topLeft && !topRight && botLeft && botRight)
DrawTile(batch, x, y, 1, 4, alpha, color, blend, 1);

// Top Right Inside Corner
// Bottom Right Inside Corner
if (!topLeft && topRight && botLeft && botRight)
DrawTile(batch, x, y, 2, 4, alpha, color, blend, 1);

Expand Down
8 changes: 4 additions & 4 deletions src/Murder/Services/TileServices.cs
Original file line number Diff line number Diff line change
Expand Up @@ -76,17 +76,17 @@ public static (int tile, int sortAdjust) GetAutoTile(bool topLeft, bool topRight

// Top Left Inside Corner
if (topLeft && topRight && botLeft && !botRight)
return (Calculator.OneD(1, 3, 3), -1);
return (Calculator.OneD(1, 3, 3), 1);

// Top Right Inside Corner
if (topLeft && topRight && !botLeft && botRight)
return (Calculator.OneD(2, 3, 3), -1);
return (Calculator.OneD(2, 3, 3), 1);

// Top Left Inside Corner
// Bottom Left Inside Corner
if (topLeft && !topRight && botLeft && botRight)
return (Calculator.OneD(1, 4, 3), 1);

// Top Right Inside Corner
// Bottom Right Inside Corner
if (!topLeft && topRight && botLeft && botRight)
return (Calculator.OneD(2, 4, 3), 1);

Expand Down

0 comments on commit a8f1cb7

Please sign in to comment.