当前位置: 首页>>代码示例>>C#>>正文


C# GenericReader.ReadInt方法代码示例

本文整理汇总了C#中Server.GenericReader.ReadInt方法的典型用法代码示例。如果您正苦于以下问题:C# GenericReader.ReadInt方法的具体用法?C# GenericReader.ReadInt怎么用?C# GenericReader.ReadInt使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Server.GenericReader的用法示例。


在下文中一共展示了GenericReader.ReadInt方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Deserialize

        public override void Deserialize( GenericReader reader )
        {
            base.Deserialize( reader );

            int version = reader.ReadInt();

            switch ( version )
            {
                case 0:
                    {
                        m_Value = reader.ReadInt();

                        break;
                    }
            }

            if ( LootType != LootType.Cursed )
            {
                LootType = LootType.Cursed;
            }

            if ( Insured )
            {
                Insured = false;
            }
        }
开发者ID:Ravenwolfe,项目名称:xrunuo,代码行数:26,代码来源:StatScroll.cs

示例2: Deserialize

        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);

            int version = reader.ReadInt();

            int entryCount = reader.ReadInt();

            for (int i = 0; i < entryCount; i++)
                m_SystemEntries.Add(new SlayerSystemTracker(reader.ReadString(), reader.ReadInt(), reader.ReadString()));

            if (Owner is Mobile)
            {
                Mobile player = (Mobile)Owner;

                SlayerModule module = player.GetModule(typeof(SlayerModule)) as SlayerModule;

                if (module == null)
                    module = new SlayerModule(player);

                foreach (SlayerSystemTracker entry in m_SystemEntries)
                    module.SetSlayerCount(entry.SystemName, entry.SlayerCount);

                Delete();
            }
        }
开发者ID:kejel,项目名称:ForkUO,代码行数:26,代码来源:SlayerTitleAttachment_v1.0.cs

示例3: Deserialize

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();

			switch ( version )
			{
				case 0:
				{
					m_Boat = reader.ReadItem() as BaseBoat;
					m_Side = (PlankSide) reader.ReadInt();
					m_Locked = reader.ReadBool();
					m_KeyValue = reader.ReadUInt();

					if ( m_Boat == null )
						Delete();

					break;
				}
			}

			if ( IsOpen )
			{
				m_CloseTimer = new CloseTimer( this );
				m_CloseTimer.Start();
			}
		}
开发者ID:jsrn,项目名称:MidnightWatchServer,代码行数:28,代码来源:Plank.cs

示例4: Deserialize

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();

			switch ( version )
			{
				case 1:
				case 0:
				{
					m_MultiID = reader.ReadInt();
					m_Offset = reader.ReadPoint3D();
					m_ShipName = reader.ReadString();

					if ( version == 0 )
						reader.ReadUInt();

					break;
				}
			}

			if ( LootType == LootType.Newbied )
				LootType = LootType.Blessed;

			if ( Weight == 0.0 )
				Weight = 1.0;
		}
开发者ID:jsrn,项目名称:MidnightWatchServer,代码行数:28,代码来源:BaseDockedBoat.cs

示例5: Deserialize

        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);

            int version = reader.ReadInt();
            org_Int = reader.ReadInt();
        }
开发者ID:evildude807,项目名称:kaltar,代码行数:7,代码来源:HeadCold.cs

示例6: ExtendedDeserialize

		public void ExtendedDeserialize( GenericReader reader, int parentVerison )
		{
			int version = reader.ReadInt();

			switch (version)
			{

                                 case 3:
                                 {
					m_PopUpToggle = reader.ReadBool();
                                        goto case 2;
                                 }
                                 case 2:
                                 {
				 	Percent = reader.ReadDouble();
                                 	m_LevelTitle = reader.ReadString();
                                        m_PlayerLevel = reader.ReadInt();
                                        goto case 1;
                                 }

				case 1:
				{
					m_Settings = new MobileSettings(this);
					m_Settings.Deserialize(reader);
					goto case 0;
				}
				case 0:
				{
					m_TravelTickets = reader.ReadInt();
					break;
				}
			}
		}
开发者ID:ITLongwell,项目名称:aedilis2server,代码行数:33,代码来源:AedilisPlayerMobile.cs

示例7: Deserialize

        public void Deserialize( GenericReader reader )
        {
            int version = reader.ReadInt();
            switch( version )
            {
                case 1:
                {
                    m_SpellType = ScriptCompiler.FindTypeByName(reader.ReadString());
                    m_Icon      = reader.ReadInt();
                    m_Location      = reader.ReadPoint3D();
                    m_School    = (School)reader.ReadInt();

                    break;
                }
                case 0:
                {
                    int bad = reader.ReadInt();
                    m_Icon    = reader.ReadInt();
                    m_Location    = reader.ReadPoint3D();

                    m_SpellType = null;
                    m_School  = School.Invalid;
                    break;
                }
            }
        }
开发者ID:evildude807,项目名称:kaltar,代码行数:26,代码来源:IconInfo.cs

示例8: Deserialize

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();

			switch ( version )
			{
				case 2:
				{
					m_Level = reader.ReadInt();
					goto case 1;
				}
				case 1:
				{
					m_TargetMap = reader.ReadMap();
					break;
				}
				case 0:
				{
					m_TargetMap = Map.Trammel;
					break;
				}
			}

			if ( version < 2 )
				m_Level = GetRandomLevel();
		}
开发者ID:greeduomacro,项目名称:annox,代码行数:28,代码来源:ParchmentMessage.cs

示例9: Deserialize

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );

			int version = reader.ReadInt();
			m_UsesRemaining = reader.ReadInt();
		}
开发者ID:ITLongwell,项目名称:aedilis2server,代码行数:7,代码来源:CorkScrew.cs

示例10: Deserialize

		public override void Deserialize( GenericReader reader )
		{
			base.Deserialize( reader );
			int version = reader.ReadInt();

			m_StrengthBonus = reader.ReadInt();
		}
开发者ID:greeduomacro,项目名称:vivre-uo,代码行数:7,代码来源:ArcaneFocus.cs

示例11: Deserialize

        public override void Deserialize( GenericReader reader )
        {
            base.Deserialize( reader );

            int version = reader.ReadInt();

            switch ( version )
            {
                case 1:
                    {
                        m_Level = (SecureLevel) reader.ReadInt();
                        goto case 0;
                    }
                case 0:
                    {
                        if ( version < 1 )
                        {
                            m_Level = SecureLevel.Anyone;
                        }

                        m_Facing = (DoorFacing) reader.ReadInt();
                        break;
                    }
            }
        }
开发者ID:Ravenwolfe,项目名称:xrunuo,代码行数:25,代码来源:HouseDoors.cs

示例12: Deserialize

        public override void Deserialize(GenericReader reader)
        {
            base.Deserialize(reader);

            Int32 version = reader.ReadInt();

            Int32 entryCount = reader.ReadInt();

            for (Int32 i = 0; i < entryCount; i++)
                m_TitleEntries[reader.ReadString()] = reader.ReadInt();

            if (Owner is Mobile)
            {
                Mobile player = (Mobile)Owner;

                SlayerModule module = player.GetModule(typeof(SlayerModule)) as SlayerModule;

                if (module == null)
                    module = new SlayerModule(player);

                foreach (String title in m_TitleEntries.Keys)
                    module.SetSlayerCount(title, (Int32)m_TitleEntries[title]);

                Delete();
            }
        }
开发者ID:kejel,项目名称:ForkUO,代码行数:26,代码来源:SlayerTitleAttachment_v2.0.cs

示例13: Deserialize

        public override void Deserialize( GenericReader reader )
        {
            base.Deserialize( reader );

            int version = reader.ReadInt();
            m_portalID = reader.ReadInt();
        }
开发者ID:OurUO,项目名称:ouruo-server,代码行数:7,代码来源:DungeonPortal.cs

示例14: Deserialize

 public override void Deserialize(GenericReader reader)
 {
     base.Deserialize(reader);
     int version = reader.ReadInt();
     m_Track = reader.ReadInt();
     m_Song = (MusicName)reader.ReadInt();
 }
开发者ID:greeduomacro,项目名称:annox,代码行数:7,代码来源:MusicBoxTrack.cs

示例15: Deserialize

        public override void Deserialize( GenericReader reader )
        {
            base.Deserialize( reader );

            int version = reader.ReadInt();

            switch ( version )
            {
                case 1:
                    {
                        int spellId = reader.ReadInt();

                        for ( int i = 0; i < SpellTriggerSpell.Definitions.Length; i++ )
                        {
                            SpellTriggerDef def = SpellTriggerSpell.Definitions[i];

                            if ( def.SpellId == spellId )
                            {
                                m_SpellDef = def;
                                break;
                            }
                        }

                        if ( m_SpellDef == null )
                            Delete();

                        break;
                    }
                case 0:
                    {
                        Delete();
                        break;
                    }
            }
        }
开发者ID:Ravenwolfe,项目名称:xrunuo,代码行数:35,代码来源:SpellTriggerSpell.cs


注:本文中的Server.GenericReader.ReadInt方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。