本文整理汇总了C#中FrameWork.PacketOut.WriteFloat方法的典型用法代码示例。如果您正苦于以下问题:C# PacketOut.WriteFloat方法的具体用法?C# PacketOut.WriteFloat怎么用?C# PacketOut.WriteFloat使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类FrameWork.PacketOut
的用法示例。
在下文中一共展示了PacketOut.WriteFloat方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: HandlePacket
public static void HandlePacket(BaseClient client, PacketIn packet)
{
WorldClient cclient = (WorldClient)client;
UInt32 AcctId = packet.GetUint32R();
Log.Debug("AskWorldEnter", "New client, Account = " + AcctId);
cclient.Account = Program.CharMgr.GetAccount((int)AcctId);
cclient.Character = Program.CharMgr.GetInfoForEnter((int)AcctId);
PacketOut Out = new PacketOut((UInt32)Opcodes.ANS_WORLD_ENTER);
if (cclient.Account == null || cclient.Character == null)
Out.WriteInt32R(1);
else
{
Out.WriteInt32R(0);
Out.WriteInt32R(cclient.Character.Character.Id);
Out.WriteInt32R(cclient.Account.Points); // Points
Out.WriteByte(1);
Out.WriteInt64R(TCPManager.GetTimeStamp());
Out.WriteFloat(5.00f); // fMarketPlaceMinimumBidPct
Out.WriteByte(0); // GroupPublic
Out.WriteByte(0); // GroupInvite
Out.WriteInt32R(Program.FileMgr.GetFileVersion(cclient.Account.Id, 1, false, Program.Config.WorldName, cclient.Character.Character.Name)); // ConfigFileVersion
Out.WriteInt32R(Program.FileMgr.GetFileVersion(cclient.Account.Id, 2, false, Program.Config.WorldName, cclient.Character.Character.Name));
Out.WriteInt32R(Program.FileMgr.GetFileVersion(cclient.Account.Id, 3, false, Program.Config.WorldName, cclient.Character.Character.Name));
Out.WriteInt32R(Program.FileMgr.GetFileVersion(cclient.Account.Id, 4, false, Program.Config.WorldName, cclient.Character.Character.Name));
Out.WriteInt32R(Program.FileMgr.GetFileVersion(cclient.Account.Id, 5, false, Program.Config.WorldName, cclient.Character.Character.Name));
Out.WriteByte(1); // Tutorial Complete
Out.WriteByte(0); // lookInForGroup
}
cclient.SendTCP(Out);
}