This commit is contained in:
Anuken 2024-07-19 19:07:10 -04:00
parent 394ed99616
commit 10e1680d3b
4 changed files with 4 additions and 4 deletions

View File

@ -160,7 +160,7 @@ public class BuilderAI extends AIController{
float minDst = Float.MAX_VALUE;
Player closest = null;
for(var player : Groups.player){
if(player.unit().canBuild() && !player.dead() && player.team() == unit.team){
if(!player.dead() && player.isBuilder() && player.team() == unit.team){
float dst = player.dst2(unit);
if(dst < minDst){
closest = player;

View File

@ -572,7 +572,7 @@ public class DesktopInput extends InputHandler{
player.unit().mineTile = null;
}
if(Core.input.keyTap(Binding.clear_building)){
if(Core.input.keyTap(Binding.clear_building) && !player.dead()){
player.unit().clearBuilding();
}

View File

@ -913,7 +913,7 @@ public class HudFragment{
table.table().update(t -> {
t.left();
Bits applied = player.unit() == null ? null : player.unit().statusBits();
Bits applied = player.dead() ? null : player.unit().statusBits();
if(!statuses.equals(applied)){
t.clear();

View File

@ -26,4 +26,4 @@ org.gradle.caching=true
org.gradle.internal.http.socketTimeout=100000
org.gradle.internal.http.connectionTimeout=100000
android.enableR8.fullMode=false
archash=b857594d11
archash=96cd86d08a