Пример #1
0
 public void waitTenTurns() {
   for (int i = 0; i < 10; i++) {
     boolean hostileNPCNear = false;
     for (Char c : currentMap.getChars()) {
       if (c.isNextTo(player) && c.isHostile()) {
         hostileNPCNear = true;
       }
     }
     if (!hostileNPCNear) {
       addEvent(new MiscEvent(100, "", Event.OTHER_EVENT));
       newTurn();
     } else {
       i = 10;
     }
   }
   clearOutput();
   updateVisibleOutput();
 }