Exemplo n.º 1
0
        public static void ResetGenerators(bool startup = false)
        {
            Generators.ForEach(c =>
            {
                c.Activated = false;
                c.Reset();

                if (c.Generator == null || c.Generator.Deleted)
                {
                    c.Generator = new MoonstonePowerGenerator(c);
                    c.Generator.MoveToWorld(new Point3D(c.X, c.Y, c.Z + 5), c.Map);
                }

                c.Generator.CanSpawn = false;

                c.Components.ForEach(comp =>
                {
                    if (!comp.Visible)
                    {
                        comp.Visible = true;
                    }
                });
            });

            if (!startup)
            {
                MorphItems();
            }

            if (Boss != null)
            {
                Boss = null;
            }
        }
Exemplo n.º 2
0
        public static void CheckNetwork()
        {
            bool allactive = true;

            foreach (MoonstonePowerGeneratorAddon c in Generators)
            {
                if (!c.Activated)
                {
                    allactive = false;
                    break;
                }
            }

            if (allactive)
            {
                Boss = new Zipactriotl(true);
                Boss.MoveToWorld(new Point3D(899, 2303, -20), Map.TerMur);

                foreach (MoonstonePowerGeneratorAddon c in Generators.Where(c => c.Generator != null))
                {
                    c.Generator.CanSpawn = true;
                }

                MorphItems();
            }
        }