示例#1
0
 public static void GenerateShipSpawner()
 {
     if (m_Instance == null)
     {
         m_Instance = new BountyQuestSpawner();
         m_Instance.MoveToWorld(new Point3D(4558, 2347, 0), Map.Trammel);
     }
 }
示例#2
0
 public static void GenerateShipSpawner()
 {
     if (m_Instance == null)
     {
         m_Instance = new BountyQuestSpawner();
         m_Instance.MoveToWorld(new Point3D(4558, 2347, 0), Map.Trammel);
     }
 }
示例#3
0
        public SpawnDefinition(Rectangle2D spawnreg, Point2D[][] waypoints, SpawnZone type, Map map)
        {
            m_SpawnRegion = spawnreg;
            m_Waypoints   = waypoints;
            m_Zone        = type;
            m_Map         = map;

            BountyQuestSpawner.AddZone(this);
        }
示例#4
0
        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);
            int version = reader.ReadInt();

            m_MaxFel    = reader.ReadInt();
            m_MaxTram   = reader.ReadInt();
            m_MaxTokuno = reader.ReadInt();
            m_SpawnTime = reader.ReadTimeSpan();
            m_Active    = reader.ReadBool();

            int count = reader.ReadInt();

            for (int i = 0; i < count; i++)
            {
                SpawnZone zone = (SpawnZone)reader.ReadInt();
                int       c    = reader.ReadInt();
                for (int j = 0; j < c; j++)
                {
                    BaseShipCaptain capt = reader.ReadMobile() as BaseShipCaptain;
                    if (capt != null && !capt.Deleted && capt.Alive)
                    {
                        m_ActiveZones[zone].Add(capt);
                    }
                }
            }

            count = reader.ReadInt();
            for (int i = 0; i < count; i++)
            {
                Mobile mob = reader.ReadMobile();
                int    amt = reader.ReadInt();

                if (mob != null && !mob.Deleted)
                {
                    m_Bounties.Add(mob, amt);
                }
            }

            if (version == 0)
            {
                m_MaxTram   = 1;
                m_MaxFel    = 1;
                m_MaxTokuno = 1;

                RemoveSpawns();
            }

            m_Instance = this;

            if (m_Active)
            {
                m_Timer = Timer.DelayCall(m_SpawnTime, m_SpawnTime, new TimerCallback(OnTick));
            }
        }
示例#5
0
        public BountyQuestSpawner() : base(0xED4)
        {
            Name        = "Pirate/Merchant Spawner";
            Visible     = false;
            Movable     = false;
            m_SpawnTime = TimeSpan.FromMinutes(15);

            m_MaxTram   = 2;
            m_MaxFel    = 2;
            m_MaxTokuno = 1;

            Active     = true;
            m_Instance = this;
        }
示例#6
0
        public BountyQuestSpawner() : base(0xED4)
        {
            if (m_Instance != null && !m_Instance.Deleted)
            {
                Active = false;
                Delete();
            }

            Name        = "Pirate/Merchant Spawner";
            Visible     = false;
            Movable     = false;
            m_SpawnTime = TimeSpan.FromMinutes(15);

            m_MaxTram   = 1;
            m_MaxFel    = 1;
            m_MaxTokuno = 1;

            Active     = true;
            m_Instance = this;
        }
示例#7
0
        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);
            int version = reader.ReadInt();

            m_MaxFel = reader.ReadInt();
            m_MaxTram = reader.ReadInt();
            m_MaxTokuno = reader.ReadInt();
            m_SpawnTime = reader.ReadTimeSpan();
            m_Active = reader.ReadBool();

            int count = reader.ReadInt();
            for (int i = 0; i < count; i++)
            {
                SpawnZone zone = (SpawnZone)reader.ReadInt();
                int c = reader.ReadInt();
                for (int j = 0; j < c; j++)
                {
                    BaseShipCaptain capt = reader.ReadMobile() as BaseShipCaptain;
                    if (capt != null && !capt.Deleted && capt.Alive)
                    {
                        m_ActiveZones[zone].Add(capt);
                    }
                }
            }

            count = reader.ReadInt();
            for (int i = 0; i < count; i++)
            {
                Mobile mob = reader.ReadMobile();
                int amt = reader.ReadInt();

                if (mob != null && !mob.Deleted)
                    m_Bounties.Add(mob, amt);
            }

            m_Instance = this;

            if (m_Active)
                m_Timer = Timer.DelayCall(m_SpawnTime, m_SpawnTime, new TimerCallback(OnTick));
        }
示例#8
0
        public BountyQuestSpawner() : base(0xED4)
        {
            if (m_Instance != null && !m_Instance.Deleted)
            {
                Active = false;
                Delete();
            }

            Name = "Pirate/Merchant Spawner";
            Visible = false;
            Movable = false;
            m_SpawnTime = TimeSpan.FromMinutes(15);

            m_MaxTram = 2;
            m_MaxFel = 2;
            m_MaxTokuno = 1;

            Active = true;
            m_Instance = this;
        }