Draw to-be affected blocks when placing projectors (#4818)

This commit is contained in:
Patrick 'Quezler' Mounier 2021-02-28 19:58:06 +01:00 committed by GitHub
parent d025ba63e1
commit 526157a514
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 6 additions and 2 deletions

View File

@ -54,7 +54,9 @@ public class MendProjector extends Block{
@Override
public void drawPlace(int x, int y, int rotation, boolean valid){
Drawf.dashCircle(x * tilesize + offset, y * tilesize + offset, range, Pal.accent);
Drawf.dashCircle(x * tilesize + offset, y * tilesize + offset, range, baseColor);
indexer.eachBlock(player.team(), x * tilesize + offset, y * tilesize + offset, range, other -> true, other -> Drawf.selected(other, Tmp.c1.set(baseColor).a(Mathf.absin(4f, 1f))));
}
public class MendBuild extends Building implements Ranged{

View File

@ -47,7 +47,9 @@ public class OverdriveProjector extends Block{
@Override
public void drawPlace(int x, int y, int rotation, boolean valid){
Drawf.dashCircle(x * tilesize + offset, y * tilesize + offset, range, Pal.accent);
Drawf.dashCircle(x * tilesize + offset, y * tilesize + offset, range, baseColor);
indexer.eachBlock(player.team(), x * tilesize + offset, y * tilesize + offset, range, other -> other.block.canOverdrive, other -> Drawf.selected(other, Tmp.c1.set(baseColor).a(Mathf.absin(4f, 1f))));
}
@Override