Skip to content

Commit e619439

Browse files
committed
changed draw passes
1 parent 2e33356 commit e619439

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/main/java/dev/zwazel/internal/debug/MapVisualiser.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -112,10 +112,7 @@ private void drawHeightMap(Graphics2D g2d, MapDefinition mapDefinition) {
112112
}
113113

114114
private void drawPath(Graphics2D g2d, MapDefinition mapDefinition) {
115-
// First pass: Draw Tank
116-
drawTank(g2d, world);
117-
118-
// Second pass: Draw start and end cells
115+
// First pass: Draw start and end cells
119116
if (!path.isEmpty()) {
120117
Node startNode = path.getFirst();
121118
Node endNode = path.getLast();
@@ -139,6 +136,9 @@ private void drawPath(Graphics2D g2d, MapDefinition mapDefinition) {
139136
);
140137
}
141138

139+
// Second pass: Draw Tank
140+
drawTank(g2d, world);
141+
142142
// Third pass: Draw Path
143143
g2d.setColor(Color.RED);
144144
for (int i = 0; i < path.size() - 1; i++) {

0 commit comments

Comments
 (0)