Esempio n. 1
0
        /// <summary>
        /// Ask the player where he wants to build his house
        /// </summary>
        /// <param name="player"></param>
        /// <returns> The land where the player wants to build his house </returns>
        public Land ChooseLandToBuildOn(IPlayer player)
        {
            IList <Land> buildableOwnedLands = player.BuildableOwnedLands;

            if (buildableOwnedLands.Count == 0)
            {
                DisplayMessage("There is no land you can build a house on.");
                return(null);
            }
            else
            {
                return(UserInteraction.GetObjectChoice <Land>("Where do you want to build your house ?", buildableOwnedLands));
            }
        }
Esempio n. 2
0
 public T GetObjectChoice <T>(string message, IList <T> choicesList, IList <string> choicesTitlesList = null)
 {
     return(UserInteraction.GetObjectChoice <T>(message, choicesList, choicesTitlesList));
 }