Ejemplo n.º 1
0
 @Override
 public void takeTurn() throws GameActionException {
   super.takeTurn();
   GameObject[] enemiesInArea =
       mRC.senseNearbyGameObjects(Robot.class, ENCAMPMENT_PROTECT_RAD_SQUARED, mEnemy);
   if (enemiesInArea.length > 0) {
     mRadio.writeChannel(RadioChannels.ENCAMPMENT_IN_DANGER, locationToIndex(mRC.getLocation()));
   }
   // nothing is done with ID_OF_HARASSER yet :(
 }
Ejemplo n.º 2
0
 @Override
 public void takeTurn() throws GameActionException {
   super.takeTurn();
   mainHQLogic();
 }
Ejemplo n.º 3
0
 @Override
 public void takeTurn() throws GameActionException {
   super.takeTurn();
   if (mRC.senseNearbyGameObjects(Robot.class, ENCAMPMENT_PROTECT_RAD_SQUARED, mEnemy).length > 0)
     mRadio.writeChannel(RadioChannels.ENCAMPMENT_IN_DANGER, locationToIndex(mRC.getLocation()));
 }