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


C# Packet.ReadSingle方法代码示例

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


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

示例1: HandleGuildPartyStateResponse

 public static void HandleGuildPartyStateResponse(Packet packet)
 {
     packet.ReadSingle("Guild XP multiplier");
     packet.ReadInt32("Int10");
     packet.ReadInt32("Int14");
     packet.ReadBit("Is guild group");
 }
开发者ID:usernel,项目名称:WowPacketParser,代码行数:7,代码来源:GuildHandler.cs

示例2: Handle13516

 public static void Handle13516(Packet packet)
 {
     packet.ReadByte("Unk");
     packet.ReadInt32("Unk");
     packet.ReadSingle("Unk");
     packet.ReadInt32("Unk");
 }
开发者ID:hodobaj,项目名称:StrawberryTools,代码行数:7,代码来源:TestHandler.cs

示例3: HandleCorpseQueryResponse

        public static void HandleCorpseQueryResponse(Packet packet)
        {
            var pos = new Vector3();
            var guid = new byte[8];

            guid[4] = packet.ReadBit();
            guid[2] = packet.ReadBit();
            guid[5] = packet.ReadBit();
            guid[3] = packet.ReadBit();
            guid[1] = packet.ReadBit();
            guid[6] = packet.ReadBit();
            guid[0] = packet.ReadBit();
            packet.ReadBit("Corpse Found");
            guid[7] = packet.ReadBit();

            packet.ReadXORByte(guid, 3);
            packet.ReadXORByte(guid, 1);
            packet.ReadXORByte(guid, 2);
            packet.ReadEntryWithName<Int32>(StoreNameType.Map, "Map ID");
            pos.X = packet.ReadSingle();
            packet.ReadXORByte(guid, 6);
            packet.ReadXORByte(guid, 4);
            packet.ReadXORByte(guid, 5);
            packet.ReadEntryWithName<Int32>(StoreNameType.Map, "Corpse Map ID");
            packet.ReadXORByte(guid, 7);
            pos.Z = packet.ReadSingle();
            packet.ReadXORByte(guid, 0);
            pos.Y = packet.ReadSingle();

            packet.WriteLine("Position: {0}", pos);
            packet.WriteGuid("Corpse Low GUID", guid);
        }
开发者ID:usernel,项目名称:WowPacketParser,代码行数:32,代码来源:CorpseHandler.cs

示例4: HandleAreaTriggerReShape

        public static void HandleAreaTriggerReShape(Packet packet)
        {
            packet.ReadPackedGuid128("TriggerGUID");

            packet.ResetBitReader();
            var hasAreaTriggerSpline = packet.ReadBit("HasAreaTriggerSpline");
            var hasAreaTriggerUnkType = packet.ReadBit("HasAreaTriggerUnkType");

            if (hasAreaTriggerSpline)
                ReadAreaTriggerSpline(packet);

            if (hasAreaTriggerUnkType)
            {
                packet.ResetBitReader();
                var unk1 = packet.ReadBit("AreaTriggerUnk1");
                var hasCenter = packet.ReadBit("HasCenter");
                packet.ReadBit("Unk bit 703 1");
                packet.ReadBit("Unk bit 703 2");

                packet.ReadUInt32("Unk UInt 1");
                packet.ReadInt32("Unk Int 1");
                packet.ReadUInt32("Unk UInt 2");
                packet.ReadSingle("Radius");
                packet.ReadSingle("BlendFromRadius");
                packet.ReadSingle("InitialAngel");
                packet.ReadSingle("ZOffset");

                if (unk1)
                    packet.ReadPackedGuid128("AreaTriggerUnkGUID");

                if (hasCenter)
                    packet.ReadVector3("Center");
            }
        }
开发者ID:TrinityCore,项目名称:WowPacketParser,代码行数:34,代码来源:AreaTriggerHandler.cs

示例5: HandleMailQueryNextTimeResult60x

        public static void HandleMailQueryNextTimeResult60x(Packet packet)
        {
            packet.ReadSingle("NextMailTime");

            var int5 = packet.ReadInt32("NextCount");

            for (int i = 0; i < int5; i++)
            {
                packet.ReadPackedGuid128("SenderGUID", i);

                // PlayerGuidLookupHint
                packet.ResetBitReader();

                var bit4 = packet.ReadBit("HasVirtualRealmAddress", i);
                var bit12 = packet.ReadBit("HasNativeRealmAddress", i);

                if (bit4)
                    packet.ReadInt32("VirtualRealmAddress", i);

                if (bit12)
                    packet.ReadInt32("NativeRealmAddress", i);

                packet.ReadSingle("TimeLeft", i);
                packet.ReadInt32("AltSenderID", i);
                packet.ReadByte("AltSenderType", i);
                packet.ReadInt32("StationeryID", i);
            }
        }
开发者ID:Oboltys,项目名称:WowPacketParser,代码行数:28,代码来源:MailHandler.cs

示例6: HandleCorpseMapPositionQueryResponce

 public static void HandleCorpseMapPositionQueryResponce(Packet packet)
 {
     packet.ReadSingle("Y");
     packet.ReadSingle("X");
     packet.ReadSingle("O");
     packet.ReadSingle("Z");
 }
开发者ID:samaelsacred,项目名称:WowPacketParser,代码行数:7,代码来源:QueryHandler.cs

示例7: HandleCorpseQueryResponse

        public static void HandleCorpseQueryResponse(Packet packet)
        {
            var pos = new Vector3();
            var guid = new byte[8];

            guid[4] = packet.ReadBit();
            guid[2] = packet.ReadBit();
            guid[5] = packet.ReadBit();
            guid[3] = packet.ReadBit();
            guid[1] = packet.ReadBit();
            guid[6] = packet.ReadBit();
            guid[0] = packet.ReadBit();
            packet.ReadBit("Corpse Found");
            guid[7] = packet.ReadBit();

            packet.ReadXORByte(guid, 3);
            packet.ReadXORByte(guid, 1);
            packet.ReadXORByte(guid, 2);
            packet.ReadInt32<MapId>("Map ID");
            pos.X = packet.ReadSingle();
            packet.ReadXORByte(guid, 6);
            packet.ReadXORByte(guid, 4);
            packet.ReadXORByte(guid, 5);
            packet.ReadInt32<MapId>("Corpse Map ID");
            packet.ReadXORByte(guid, 7);
            pos.Z = packet.ReadSingle();
            packet.ReadXORByte(guid, 0);
            pos.Y = packet.ReadSingle();

            packet.AddValue("Position", pos);
            packet.WriteGuid("Corpse Low GUID", guid);
        }
开发者ID:Oboltys,项目名称:WowPacketParser,代码行数:32,代码来源:CorpseHandler.cs

示例8: HandleSpellHealLog

        public static void HandleSpellHealLog(Packet packet)
        {
            packet.ReadPackedGuid128("TargetGUID");
            packet.ReadPackedGuid128("CasterGUID");

            packet.ReadInt32<SpellId>("SpellID");
            packet.ReadInt32("Health");
            packet.ReadInt32("OverHeal");
            packet.ReadInt32("Absorbed");

            packet.ResetBitReader();

            packet.ReadBit("Crit");
            var hasCritRollMade = packet.ReadBit("HasCritRollMade");
            var hasCritRollNeeded = packet.ReadBit("HasCritRollNeeded");
            var hasLogData = packet.ReadBit("HasLogData");
            var hasSandboxScaling = packet.ReadBit("HasLogData");

            if (hasCritRollMade)
                packet.ReadSingle("CritRollMade");

            if (hasCritRollNeeded)
                packet.ReadSingle("CritRollNeeded");

            if (hasLogData)
                SpellHandler.ReadSpellCastLogData(packet);

            if (hasSandboxScaling)
                ReadSandboxScalingData(packet, "SandboxScalingData");
        }
开发者ID:TrinityCore,项目名称:WowPacketParser,代码行数:30,代码来源:CombatLogHandler.cs

示例9: HandleLoginVerifyWorld

 public static void HandleLoginVerifyWorld(Packet packet)
 {
     packet.ReadUInt32("Map");
     packet.ReadSingle("X");
     packet.ReadSingle("O");
     packet.ReadSingle("Y");
     packet.ReadSingle("Z");
 }
开发者ID:Walkum,项目名称:WowPacketParser_Skyfire,代码行数:8,代码来源:SessionHandler.cs

示例10: HandleAuraCastLog

 public static void HandleAuraCastLog(Packet packet)
 {
     packet.ReadGuid("Caster GUID");
     packet.ReadGuid("Target GUID");
     packet.ReadEntryWithName<UInt32>(StoreNameType.Spell, "Spell ID");
     packet.ReadSingle("Unk 1");
     packet.ReadSingle("Unk 2");
 }
开发者ID:usernel,项目名称:WowPacketParser,代码行数:8,代码来源:SpellHandler.cs

示例11: HandleBindPointUpdate

 public static void HandleBindPointUpdate(Packet packet)
 {
     packet.ReadSingle("Position Z");
     packet.ReadSingle("Position Y");
     packet.ReadEntryWithName<Int32>(StoreNameType.Map, "Map Id");
     packet.ReadEntryWithName<Int32>(StoreNameType.Zone, "Zone Id");
     packet.ReadSingle("Position X");
 }
开发者ID:Resike,项目名称:WowPacketParser,代码行数:8,代码来源:MovementHandler.cs

示例12: HandleAuraCastLog

 public static void HandleAuraCastLog(Packet packet)
 {
     packet.ReadGuid("Caster GUID");
     packet.ReadGuid("Target GUID");
     packet.ReadUInt32<SpellId>("Spell ID");
     packet.ReadSingle("Unk 1");
     packet.ReadSingle("Unk 2");
 }
开发者ID:horn,项目名称:WowPacketParser,代码行数:8,代码来源:SpellHandler.cs

示例13: HandleBindPointUpdate

 public static void HandleBindPointUpdate(Packet packet)
 {
     packet.ReadSingle("Position Z");
     packet.ReadSingle("Position Y");
     packet.ReadInt32<MapId>("Map Id");
     packet.ReadInt32<ZoneId>("Zone Id");
     packet.ReadSingle("Position X");
 }
开发者ID:Oboltys,项目名称:WowPacketParser,代码行数:8,代码来源:MovementHandler.cs

示例14: HandleConquestFormulaConstants

 public static void HandleConquestFormulaConstants(Packet packet)
 {
     // Order guessed
     packet.ReadInt32("PvpMinCPPerWeek");
     packet.ReadInt32("PvpMaxCPPerWeek");
     packet.ReadSingle("PvpCPBaseCoefficient");
     packet.ReadSingle("PvpCPExpCoefficient");
     packet.ReadSingle("PvpCPNumerator");
 }
开发者ID:Oboltys,项目名称:WowPacketParser,代码行数:9,代码来源:CurrencyHandler.cs

示例15: HandleGossipPoi

 public static void HandleGossipPoi(Packet packet)
 {
     var Flags = packet.ReadUInt32("Flags: ");
     var x = packet.ReadSingle("X: ");
     var y = packet.ReadSingle("Y: ");
     var Icon = packet.ReadUInt32("Icon: ");
     var Data = packet.ReadUInt32("Data: ");
     var Text = packet.ReadCString("Text: ");
 }
开发者ID:nelegalno,项目名称:WowPacketParser,代码行数:9,代码来源:NpcHandler.cs


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