Code: Select all
if (enemy BC is visible) {
this.avoid = new Point(enemy BC x, enemy BC y);
}
Code: Select all
while (mining) {
Line line = new Line(this.x, this.y, this.angle);
if (AI.avoidRadius > distanceBetweenPointAndLine(line, this.avoid)) {
turnTheFuckAround();
}
}