Esempio n. 1
0
        private void set(int index, BuyoType type)
        {
            var buyo     = resolver.Get(type);
            var renderer = buyo.GetComponent <SpriteRenderer>();

            containers[index].sprite = renderer.sprite;
        }
Esempio n. 2
0
        public GameObject Spawn(BuyoType type, Vector3 position, int i)
        {
            position.y += 0.75f * (i - 0.5f);
            var buyo = resolver.Get(type);
            var obj  = instantiator.Instantiate(buyo.gameObject, position, Quaternion.identity);

            obj.GetComponent <Buyo>().Initialize(instantiator, sfxManager);
            return(obj);
        }
Esempio n. 3
0
        //public E black = default(E);

        public E this[BuyoType type] {
            get {
                switch (type)
                {
                case BuyoType.red: return(red);

                case BuyoType.blue: return(blue);

                case BuyoType.green: return(green);

                case BuyoType.yellow: return(yellow);

                case BuyoType.purple: return(purple);
                    //case BuyoType.black: return black;
                }
                throw new ArgumentOutOfRangeException("Invalid type was specified.");
            }
        }
Esempio n. 4
0
        public virtual void Set(BuyoType type1, BuyoType type2)
        {
            var types = new Tuple <BuyoType, BuyoType>(type1, type2);

            frame.Set(types);
        }
Esempio n. 5
0
 public Buyo Get(BuyoType type) => buyos[type];