Beispiel #1
0
        public void HandleMobDeath(BaseCreature mob, ZombieAvatar avatar)
        {
            if (mob is ZombieZEvent)
            {
                _ZombiesLoc1.Remove(mob);
                _ZombiesLoc2.Remove(mob);
                _ZombiesLoc3.Remove(mob);
                _ZombiesLoc4.Remove(mob);
            }
            else if (mob is DaemonZombieEvent)
            {
                Daemons.Remove(mob);
            }
            else if (mob is TreeFellow)
            {
                TreeFellows.Remove(mob);
            }
            else if (mob is ZombieSpider)
            {
                ZombieSpiders.Remove(mob);
            }
            else if (mob is FeyWarrior)
            {
                FeyWarriors.Remove(mob);
            }
            else if (mob is Vitriol)
            {
                FeyWarriors.Remove(mob);
            }
            else if (mob is Bird)
            {
                FeyWarriors.Remove(mob);
            }
            else if (mob is HorrifyingTentacle)
            {
                HorrifyingTentacles.Remove(mob);
            }
            else if (mob is GoreFiendZombieEvent)
            {
                GoreFiends.Remove(mob);
            }

            if (avatar.Owner != null)
            {
                PlayerZombieProfile profile = ZombieEvent.EnsureProfile(avatar.Owner);
                profile.AddKill(mob);
            }
        }
Beispiel #2
0
        public void RespawnEvent()
        {
            foreach (Mobile zombie in _ZombiesLoc1.ToList())
            {
                if (zombie != null)
                {
                    zombie.Delete();
                }
                _ZombiesLoc1.Remove(zombie);
            }
            _ZombiesLoc1.Clear();
            _ZombiesLoc1.TrimExcess();

            foreach (Mobile zombie in _ZombiesLoc2.ToList())
            {
                if (zombie != null)
                {
                    zombie.Delete();
                }
                _ZombiesLoc2.Remove(zombie);
            }
            _ZombiesLoc2.Clear();
            _ZombiesLoc2.TrimExcess();

            foreach (Mobile zombie in _ZombiesLoc3.ToList())
            {
                if (zombie != null)
                {
                    zombie.Delete();
                }
                _ZombiesLoc3.Remove(zombie);
            }
            _ZombiesLoc3.Clear();
            _ZombiesLoc3.TrimExcess();

            foreach (Mobile zombie in _ZombiesLoc4.ToList())
            {
                if (zombie != null)
                {
                    zombie.Delete();
                }
                _ZombiesLoc4.Remove(zombie);
            }
            _ZombiesLoc4.Clear();
            _ZombiesLoc4.TrimExcess();

            foreach (Mobile daemon in Daemons.ToList())
            {
                if (daemon != null)
                {
                    daemon.Delete();
                }
                Daemons.Remove(daemon);
            }
            Daemons.Clear();
            Daemons.TrimExcess();

            foreach (Mobile bird in Birds.ToList())
            {
                if (bird != null)
                {
                    bird.Delete();
                }
                Birds.Remove(bird);
            }
            Birds.Clear();
            Birds.TrimExcess();

            foreach (Mobile dk in GoreFiends.ToList())
            {
                if (dk != null)
                {
                    dk.Delete();
                }
                GoreFiends.Remove(dk);
            }
            GoreFiends.Clear();
            GoreFiends.TrimExcess();

            foreach (Mobile fey in FeyWarriors.ToList())
            {
                if (fey != null)
                {
                    fey.Delete();
                }
                FeyWarriors.Remove(fey);
            }
            FeyWarriors.Clear();
            FeyWarriors.TrimExcess();

            foreach (Mobile tentacle in HorrifyingTentacles.ToList())
            {
                if (tentacle != null)
                {
                    tentacle.Delete();
                }
                HorrifyingTentacles.Remove(tentacle);
            }
            HorrifyingTentacles.Clear();
            HorrifyingTentacles.TrimExcess();

            foreach (Mobile tf in TreeFellows.ToList())
            {
                if (tf != null)
                {
                    tf.Delete();
                }
                TreeFellows.Remove(tf);
            }
            TreeFellows.Clear();
            TreeFellows.TrimExcess();

            foreach (Mobile vitriol in Vitriols.ToList())
            {
                if (vitriol != null)
                {
                    vitriol.Delete();
                }
                Vitriols.Remove(vitriol);
            }
            Vitriols.Clear();
            Vitriols.TrimExcess();

            foreach (Mobile spider in ZombieSpiders.ToList())
            {
                if (spider != null)
                {
                    spider.Delete();
                }
                ZombieSpiders.Remove(spider);
            }

            ZombieSpiders.Clear();
            ZombieSpiders.TrimExcess();

            SpawnZombies();
            SpawnDaemons();
            SpawnBirds();
            SpawnFey();
            SpawnSpider();
            SpawnTentacles();
            SpawnTreeFellow();
            SpawnVitriol();
            SpawnGoreFiends();
        }