private bool LookDeepRight(Row blockageRight, Row rightTwoBlockages) { if (blockageRight == null && this.CanMoveRight(Deity.Ship.X)) { if (rightTwoBlockages != null) { if (!this.IsDangerous(rightTwoBlockages)) { return true; } } else { return true; } } return false; }
private bool IsDangerDeep(Row blockageOne, Row blockageTwo) { if (this.IsDangerous(blockageOne)) { return true; } if (this.IsDangerous(blockageTwo)) { return true; } return false; }
private bool LookDeepLeft(Row blockageLeft, Row leftTwoBlockages) { if (blockageLeft == null && this.CanMoveLeft(Deity.Ship.X)) { if (leftTwoBlockages != null) { if (!this.IsDangerous(leftTwoBlockages)) { return true; } } else { return true; } } return false; }
private bool IsDangerous(Row danger) { if (danger != null && (danger.Type.Equals("Bullet") || (danger.Type.Equals("Missile") && danger.PlayerNumber == 2))) { return true; } return false; }