Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

schematic size display #188

Merged
merged 2 commits into from
Dec 13, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions core/src/mindustry/input/InputHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
import mindustry.net.Administration.*;
import mindustry.net.*;
import mindustry.type.*;
import mindustry.ui.*;
import mindustry.ui.fragments.*;
import mindustry.world.*;
import mindustry.world.blocks.*;
Expand Down Expand Up @@ -1324,6 +1325,12 @@ protected void drawSelection(int x1, int y1, int x2, int y2, int maxLength, Colo
Draw.color(col2, .3f);
Fill.crect(result.x, result.y, result.x2 - result.x, result.y2 - result.y);
}
Font font = Fonts.outline;
font.setColor(col2);
font.getData().setScale(1 / (4 * Scl.scl(1)));
font.draw((int)(result.x2 - result.x) / 8 + "x" + (int)(result.y2 - result.y) / 8, result.x2, result.y);
font.setColor(Color.white);
font.getData().setScale(1);
}

protected void flushSelectPlans(Seq<BuildPlan> plans){
Expand Down
Loading