Esempio n. 1
0
 // Gère l'apparence du token : son placement vis à vis du reste du plateau et l'activation ou non de son halo
 public void manageCharacterDisplay()
 {
     if (associatedCharacter.isTokenOnBoard())
     {
         // Si le personnage peut etre sélectionné ou est en cours de sélection, on affiche son halo
         if ((!gManager.selectionEnCours || associatedCharacter.selected) && gManager.isActivePlayer(associatedCharacter.affiliationJoueur) && associatedCharacter.totalCurrentActionPoints() > 0 && !associatedCharacter.wounded)
         {
             highlightToken(true);
         }
         else
         {
             highlightToken(false);
         }
     }
 }
Esempio n. 2
0
 /////////// implementation details ///////////
 private CharacterBehavior SelectACharacterToOpenRoom(HiddenTileBehaviorIHM tileToDiscover)
 {
     // TODO: choose a character that is neighboor to the room
     foreach (var token in GameObject.FindGameObjectsWithTag("Token"))
     {
         CharacterBehavior character = token.GetComponent <CharacterBehavior>();
         if (character != null && gManager.isActivePlayer(character.affiliationJoueur) && character.isTokenOnBoard())
         {
             return(character);
         }
     }
     Debug.Assert(false, "No valid character found");
     return(null);
 }