Esempio n. 1
0
    public void SummonZombie(string t)
    {
        zombie = factory.CreateZombie(t);

        if (zombie != null)
        {
            int     ranX = Random.Range(minX, maxX);
            Vector3 pos  = new Vector3(ranX, 0, 0);
            Instantiate(zombie, pos, zombie.transform.rotation);
        }
    }
Esempio n. 2
0
 // Start is called before the first frame update
 void Start()
 {
     Timer   = 0;
     Factory = ZombieFactory.Instance;
     Factory.CreateZombie();
 }
Esempio n. 3
0
        public void CreateNewZombie(string type)
        {
            ZombieClass zombie = ZombieFactory.CreateZombie(type, this);

            this.enemies.Add(zombie);
        }