Fixed erekir unit requirements
This commit is contained in:
@@ -230,6 +230,20 @@ public class DesktopInput extends InputHandler{
|
||||
brequest.config = null;
|
||||
Draw.reset();
|
||||
}
|
||||
|
||||
if(!valid && state.rules.placeRangeCheck){
|
||||
var blocker = Build.getEnemyOverlap(block, player.team(), cursorX, cursorY);
|
||||
if(blocker != null){
|
||||
Drawf.selected(blocker, blocker.team.color);
|
||||
Tmp.v1.set(cursorX, cursorY).scl(tilesize).add(block.offset, block.offset).sub(blocker).scl(-1f).nor();
|
||||
Drawf.dashLineDst(Pal.remove,
|
||||
cursorX * tilesize + block.offset + Tmp.v1.x * block.size * tilesize/2f,
|
||||
cursorY * tilesize + block.offset + Tmp.v1.y * block.size * tilesize/2f,
|
||||
blocker.x + Tmp.v1.x * -blocker.block.size * tilesize/2f,
|
||||
blocker.y + Tmp.v1.y * -blocker.block.size * tilesize/2f
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user