Пример #1
0
 protected void activeClick(CharacterActionChitComponent clickedChit) {
   if (needsToFatigue()) {
     if (clickedChit != null) {
       if (validChit(clickedChit)) {
         int effort = clickedChit.getEffortAsterisks();
         if (clickedChit.isColor()) {
           effort = 1; // color chits only count as one!
         }
         // go ahead
         if ((currentCount - effort) >= -1) { // allowed to dip one into the hole
           if (effort == 0) {
             moveChit(clickedChit, activeChits, woundedChits);
             updateEffort(clickedChit, -1);
           } else {
             moveChit(clickedChit, activeChits, fatiguedChits);
             updateEffort(clickedChit, -effort);
             makeChangeType = TYPE_NA;
             if (currentCount < 0) {
               if (clickedChit.isMove()) {
                 makeChangeType = TYPE_MOVE;
               } else if (clickedChit.isFight() || clickedChit.isFightAlert()) {
                 makeChangeType = TYPE_FIGHT;
               }
             }
           }
         }
       }
     }
   }
 }
Пример #2
0
 protected boolean countsAsMove(CharacterActionChitComponent chit) {
   return chit.isMove() || chit.isFly() || chit.isAnyEffort();
 }