This commit is contained in:
Anuken
2026-09-15 00:39:46 -04:00
parent b76147ec50
commit 0bbc4c6777
2 changed files with 9 additions and 1 deletions
@@ -22,4 +22,11 @@ abstract class TargetDummyComp implements Unitc, Healthc{
td.dummyHit(amount);
}
}
@Override
@Replace
public boolean canLand(){
//dummies should always respect the boost config even when the landing area is obstructed (usually by other dummies)
return true;
}
}
@@ -174,7 +174,8 @@ abstract class UnitComp implements Healthc, Physicsc, Hitboxc, Statusc, Teamc, I
/** @return whether there is solid, un-occupied ground under this unit. */
public boolean canLand(){
return !onSolid() && Units.count(x, y, physicSize(), f -> f != self() && f.isGrounded()) == 0;
float psize = physicSize();
return !onSolid() && !Units.any(x - psize/2f, y - psize/2f, psize, psize, f -> f != self() && f.isGrounded());
}
public boolean inRange(Position other){