コード例 #1
0
ファイル: GuardSpawner.cs プロジェクト: zerodowned/vivre-uo
        public GuardSpawner(Point3D location, TownStone town) : base(0x1f13)
        {
            m_Running      = false;
            Location       = location;
            Map            = town.Map;
            m_SpawnedGuard = null;
            m_Town         = town;
            m_Delay        = TimeSpan.FromSeconds(600.0);
            Visible        = false;
            Movable        = false;
            PomiGuard guard = new PomiGuard(m_Town, this);

            m_SpawnedGuard = guard;
            if (m_Town.GardesPNJ.Count > 0)
            {
                m_RangeHome = ((GuardSpawner)(m_Town.GardesPNJ[0])).RangeHome;
            }
            else
            {
                m_RangeHome = 5;
            }
            guard.Home      = Location;
            guard.RangeHome = 5;
            Name            = guard.Name;
        }
コード例 #2
0
ファイル: GuardSpawner.cs プロジェクト: zerodowned/vivre-uo
            protected override void OnTick()
            {
                PomiGuard guard = new PomiGuard(m_Town, m_spawner);

                m_spawner.SpawnedGuard = guard;
                guard.Home             = m_spawner.Location;
                guard.RangeHome        = 5;
                m_spawner.Name         = guard.Name;
                m_spawner.Running      = false;
            }
コード例 #3
0
ファイル: GuardSpawner.cs プロジェクト: zerodowned/vivre-uo
        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);

            int version = reader.ReadInt();

            m_Delay        = reader.ReadTimeSpan();
            m_Town         = (TownStone)reader.ReadItem();
            m_SpawnedGuard = (PomiGuard)reader.ReadMobile();
            m_RangeHome    = reader.ReadInt();
            m_Running      = reader.ReadBool();
            if (m_Running)
            {
                m_timer = new SpawnTimer(m_Town, this, m_Delay);
                m_timer.Start();
            }
        }
コード例 #4
0
ファイル: GuardSpawner.cs プロジェクト: greeduomacro/vivre-uo
		public GuardSpawner(Point3D location, TownStone town) : base( 0x1f13 )
		{
			m_Running = false;
			Location = location;
			Map = town.Map;
			m_SpawnedGuard = null;
			m_Town = town;
			m_Delay = TimeSpan.FromSeconds( 600.0 );
			Visible = false;
			Movable = false;
			PomiGuard guard = new PomiGuard(m_Town, this);
			m_SpawnedGuard = guard;
			if(m_Town.GardesPNJ.Count > 0 )
				m_RangeHome = ((GuardSpawner)(m_Town.GardesPNJ[0])).RangeHome;
			else
				m_RangeHome = 5;
			guard.Home = Location;
			guard.RangeHome = 5;
			Name = guard.Name;
		}
コード例 #5
0
ファイル: GuardSpawner.cs プロジェクト: greeduomacro/vivre-uo
		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();
			m_Delay = reader.ReadTimeSpan();
			m_Town = (TownStone)reader.ReadItem();
			m_SpawnedGuard = (PomiGuard)reader.ReadMobile();
			m_RangeHome = reader.ReadInt();
			m_Running = reader.ReadBool();
			if(m_Running)
			{
				m_timer =  new SpawnTimer(m_Town, this, m_Delay);
				m_timer.Start();
			}
			
		}
コード例 #6
0
ファイル: GuardSpawner.cs プロジェクト: greeduomacro/vivre-uo
			protected override void OnTick()
			{
				PomiGuard guard = new PomiGuard(m_Town, m_spawner);
				m_spawner.SpawnedGuard = guard;
				guard.Home = m_spawner.Location;
				guard.RangeHome = 5;
				m_spawner.Name = guard.Name;
				m_spawner.Running = false;
			}