Exemple #1
0
 public СleanedСellUIController(IAwardWindow awardWindow, IGold gold, ICatsOnCell cats, ICellUIBuilder builder)
 {
     this.awardWindow = awardWindow;
     this.gold        = gold;
     this.cats        = cats;
     this.builder     = builder;
 }
Exemple #2
0
        //private int _gold;

        //private int _leather;

        //public int Leather
        //{
        //    get { return _leather; }
        //    set { _leather = value; }
        //}

        //public int Gold
        //{
        //    get { return _gold; }
        //    set { _gold = value; }
        //}

        //public Monster()
        //{
        //    Gold = this.d6.Roll();
        //    Leather = this.d4.Roll();
        //}

        public Monster()
        {
            if (this is ILeather)
            {
                ILeather L = (ILeather)this; //cast monstre => Leather
                L.Leather = this.d4.Roll();
            }

            if (this is IGold)
            {
                IGold G = (IGold)this; //cast monstre => Gold
                G.Gold = this.d6.Roll();
            }
        }
 public void Add(IGold gold)
 {
     this.gold = gold;
 }