Skip to content

Commit 4a63ea3

Browse files
committed
Forced overlay draw
1 parent 25eaacd commit 4a63ea3

File tree

2 files changed

+12
-13
lines changed

2 files changed

+12
-13
lines changed

assets/bundles/bundle.properties

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,10 @@ tu-block-menu.open-painter = Open Terrain Painter
5252

5353
toolmode.pickdata = Pick Data
5454
toolmode.pickdata.description = Copies tile data
55+
toolmode.forceoverlay = Force Overlay
56+
toolmode.forceoverlay.description = Forcibly draw floor as overlay.
5557
toolmode.drawdata = Draw Data
56-
toolmode.drawdata.description = Forcibly override data.
58+
toolmode.drawdata.description = Forcibly overwrite tile data.
5759

5860
tu-painter.cliffs = Flush Cliffs
5961
tu-painter.canyons = Flush Canyons

src/testing/editor/PainterTool.java

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public void touchedLine(int x1, int y1, int x2, int y2){
5454
});
5555
}
5656
},
57-
pencil(true, "replace", "square", "drawteams", "underliquid", "drawdata"){
57+
pencil(true, "replace", "square", "drawteams", "underliquid", "forceoverlay", "drawdata"){
5858
{
5959
edit = true;
6060
draggable = true;
@@ -63,26 +63,23 @@ public void touchedLine(int x1, int y1, int x2, int y2){
6363
@Override
6464
public void touched(int x, int y){
6565
switch(mode){
66-
case -1 -> { //normal mode
66+
case -1 -> //normal mode
6767
painter.drawBlocks(x, y);
68-
}
69-
case 0 -> { //replace mode
68+
case 0 -> //replace mode
7069
painter.drawBlocksReplace(x, y);
71-
}
72-
case 1 -> { //square mode
70+
case 1 -> //square mode
7371
painter.drawBlocks(x, y, true, false, data -> true);
74-
}
75-
case 2 -> { //draw teams
72+
case 2 -> //draw teams
7673
painter.drawCircle(x, y, painter.brushSize, data -> data.setTeam(painter.drawTeam));
77-
}
78-
case 3 -> { //Draw under liquid
74+
case 3 -> { //draw under liquid
7975
if(!(painter.drawBlock instanceof Floor f && f.isLiquid)){
8076
painter.drawBlocks(x, y, false, true, tile -> tile.floor().isLiquid);
8177
}
8278
}
83-
case 4 -> { //draw data
79+
case 4 -> //force overlay
80+
painter.drawBlocks(x, y, false, true, tile -> true);
81+
case 5 -> //draw data
8482
painter.drawData(x, y);
85-
}
8683
}
8784
}
8885
},

0 commit comments

Comments
 (0)