Пример #1
0
            public FlowChecker(GenericReader reader, FountainEncounter encounter)
            {
                int version = reader.ReadInt();

                _Encounter = encounter;

                _Spigot = reader.ReadItem() as ShadowguardSpigot;
                _Drain  = reader.ReadItem() as ShadowguardDrain;

                int count = reader.ReadInt();

                for (int i = 0; i < count; i++)
                {
                    if (_Checked == null)
                    {
                        _Checked = new List <ShadowguardCanal>();
                    }

                    ShadowguardCanal c = reader.ReadItem() as ShadowguardCanal;

                    if (c != null)
                    {
                        _Checked.Add(c);
                    }
                }
            }
Пример #2
0
        public override void OnDoubleClick(Mobile m)
        {
            FountainEncounter encounter = ShadowguardController.GetEncounter(this.Location, this.Map) as FountainEncounter;

            if (m.InRange(this.Location, 2) && encounter != null && this.ItemID != 17294 && this.ItemID != 17278)
            {
                encounter.UseSpigot(this, m);
            }
        }
Пример #3
0
        public override bool OnBeforeDeath()
        {
            FountainEncounter encounter = ShadowguardController.GetEncounter(this.Location, this.Map) as FountainEncounter;

            if (encounter != null)
            {
                var canal = new ShadowguardCanal();
                canal.MoveToWorld(this.Location, this.Map);
                encounter.AddShadowguardCanal(canal);
            }

            return(base.OnBeforeDeath());
        }
Пример #4
0
            public void EndEncounter()
            {
                if (_Spigot != null)
                {
                    _Spigot.Delete();
                }

                if (_Checked != null)
                {
                    ColUtility.Free(_Checked);
                    _Checked = null;
                }

                _Encounter = null;
            }
Пример #5
0
 public FlowChecker(ShadowguardSpigot start, FountainEncounter encounter)
 {
     _Spigot    = start;
     _Encounter = encounter;
 }