本文整理汇总了C#中FrameWork.PacketOut.WriteHexStringBytes方法的典型用法代码示例。如果您正苦于以下问题:C# PacketOut.WriteHexStringBytes方法的具体用法?C# PacketOut.WriteHexStringBytes怎么用?C# PacketOut.WriteHexStringBytes使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FrameWork.PacketOut
的用法示例。
在下文中一共展示了PacketOut.WriteHexStringBytes方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SendAbilityDone
public void SendAbilityDone(ushort TargetOID)
{
Log.Success("Ability", "Send Done :" + Info.Entry);
Player player = this.Caster.GetPlayer();
PacketOut Out1 = new PacketOut((byte)Opcodes.F_USE_ABILITY);
Out1.WriteUInt16(0);
Out1.WriteUInt16(Info.Entry);
Out1.WriteUInt16(Caster.Oid);
Out1.WriteHexStringBytes("061022730601000001E601000000");
player.DispatchPacket(Out1, true);
PacketOut Out2 = new PacketOut((byte)Opcodes.F_USE_ABILITY);
Out2.WriteUInt16(0);
Out2.WriteUInt16(Info.Entry);
Out2.WriteUInt16(Caster.Oid);
Out2.WriteHexStringBytes("0610227302010000000001000000");
player.DispatchPacket(Out2, true);
PacketOut Out3 = new PacketOut((byte)Opcodes.F_SWITCH_ATTACK_MODE);
Out3.WriteByte(1);
Out3.Fill(0, 3);
player.SendPacket(Out3);
PacketOut Out4 = new PacketOut((byte)Opcodes.F_SET_ABILITY_TIMER);
Out4.WriteUInt16(Info.Entry);
Out4.Fill(0, 10);
player.SendPacket(Out4);
}
示例2: SendSniff
public void SendSniff(string Str)
{
string Result = "";
using (StringReader Reader = new StringReader(Str))
{
string Line;
while ((Line = Reader.ReadLine()) != null)
{
Result+=Line.Substring(1, 48).Replace(" ", string.Empty);
}
}
Result = Result.Remove(0, 4);
byte Opcode = Convert.ToByte(Result.Substring(0, 2), 16);
Result = Result.Remove(0, 2);
PacketOut Out = new PacketOut(Opcode);
Out.WriteHexStringBytes(Result);
Out.WritePacketLength();
SendPacket(Out);
}