private bool CheckBuildCosts(IEventCard card)
    {
        var costs = card.GetRessourceCosts();

        bool retVal = true;

        if (Wood.currentAmountOfWood < costs.AmountOfWood)
        {
            retVal = false;
        }
        if (Fur.currentAmountOfFur < costs.AmountOfLeather)
        {
            retVal = false;
        }
        if (FoodStorage.GetTotal() < costs.AmountOfFood)
        {
            retVal = false;
        }
        return(retVal);
    }
예제 #2
0
 public PlayEventEffect(IGame game, Sphere resourceSphere, byte numberOfResources, bool isVariableCost, IPlayer player, IEventCard eventCard)
     : base(game, resourceSphere, numberOfResources, isVariableCost, player, eventCard)
 {
     this.eventCard = eventCard;
 }
예제 #3
0
 public PlayEventEffect(IGame game, Sphere resourceSphere, byte numberOfResources, bool isVariableCost, IPlayer player, IEventCard eventCard)
     : base(game, resourceSphere, numberOfResources, isVariableCost, player, eventCard)
 {
     this.eventCard = eventCard;
 }