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


C# ServerMessage.Append方法代码示例

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


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

示例1: GetGiftWrapping

 public static void GetGiftWrapping(Message Msg, Session Session)
 {
     ServerMessage Packet = new ServerMessage(46);
     Packet.Append<bool>(true);
     Packet.Append<int>(1);
     Packet.Append<int>(10);
     Packet.Append<int>(3144);
     Packet.Append<int>(3145);
     Packet.Append<int>(3146);
     Packet.Append<int>(3147);
     Packet.Append<int>(3148);
     Packet.Append<int>(3149);
     Packet.Append<int>(3150);
     Packet.Append<int>(3151);
     Packet.Append<int>(3152);
     Packet.Append<int>(3153);
     Packet.Append<int>(7);
     Packet.Append<int>(0);
     Packet.Append<int>(1);
     Packet.Append<int>(2);
     Packet.Append<int>(3);
     Packet.Append<int>(4);
     Packet.Append<int>(5);
     Packet.Append<int>(6);
     Packet.Append<int>(11);
     Packet.Append<int>(0);
     Packet.Append<int>(1);
     Packet.Append<int>(2);
     Packet.Append<int>(3);
     Packet.Append<int>(4);
     Packet.Append<int>(5);
     Packet.Append<int>(6);
     Packet.Append<int>(7);
     Packet.Append<int>(8);
     Packet.Append<int>(9);
     Packet.Append<int>(10);
     Packet.Append<int>(7);
     Packet.Append<int>(187);
     Packet.Append<int>(188);
     Packet.Append<int>(189);
     Packet.Append<int>(190);
     Packet.Append<int>(191);
     Packet.Append<int>(192);
     Packet.Append<int>(193);
     Packet.Send(Session);
 }
开发者ID:habb0,项目名称:FerriEmulator,代码行数:46,代码来源:Catalog.cs

示例2: UpdateState

 public ServerMessage UpdateState(int Id, string Status)
 {
     ServerMessage Message = new ServerMessage(Opcodes.OpcodesOut.SendUserStatus);
     Message.Append<int>(1);
     Message.Append<int>(Id);
     Message.Append<int>(CoordX);
     Message.Append<int>(CoordY);
     Message.Append<string>(CoordZ.ToString());
     Message.Append<int>(RotationHead);
     Message.Append<int>(RotationBody);
     Message.Append<string>("/" + Status + "//");
     return Message;
 }
开发者ID:habb0,项目名称:FerriEmulator,代码行数:13,代码来源:RoomUser.cs

示例3: SerializeFirst

        internal void SerializeFirst(ServerMessage Message)
        {
            string Build = "";

            foreach (string s in Lines)
            {
                Build += (s + Convert.ToChar(13));
            }

            Message.Append<string>(Build);
        }
开发者ID:habb0,项目名称:FerriEmulator,代码行数:11,代码来源:RoomModel.cs

示例4: SerializeSecond

        internal void SerializeSecond(ServerMessage Message)
        {
            string Build = "";

            for (int y = 0; y < MapSizeY; y++)
            {
                for (int x = 0; x < MapSizeX; x++)
                {
                    string Square = Lines[y].Substring(x, 1).Trim().ToLower();

                    if (DoorX == x && DoorY == y)
                    {
                        Square = DoorZ.ToString();
                    }

                    Build += Square;
                }

                Build += Convert.ToChar(13);
            }

            string lol = Build.ToString();
            Message.Append<string>(lol);
        }
开发者ID:habb0,项目名称:FerriEmulator,代码行数:24,代码来源:RoomModel.cs

示例5: Serialize

        internal void Serialize(ServerMessage fuseResponse)
        {
            fuseResponse.Append<int>(id);
            fuseResponse.Append<string>(productname);
            fuseResponse.Append<int>(credits);
            fuseResponse.Append<int>(activitypoints);
            fuseResponse.Append<int>(activitypointtype);
            fuseResponse.Append<bool>(true);
            fuseResponse.Append<int>(items.Count());

            for(int i = 0; i < items.Count(); i++)
            {
                furniture furni = Engine.GetHabboHotel.getItemDefinitions.Definitions[uint.Parse(items[i])];

                fuseResponse.Append<string>(furni.type);
                fuseResponse.Append<int>(furni.sprite_id);
                fuseResponse.Append<string>("");
                fuseResponse.Append<int>(int.Parse(amounts[i]));
                fuseResponse.Append<int>(-1);
                fuseResponse.Append<bool>(false);
            }

            fuseResponse.Append<int>(vipneed);
            fuseResponse.Append<bool>((items.Count() < 2));
        }
开发者ID:habb0,项目名称:FerriEmulator,代码行数:25,代码来源:catalogitems.cs

示例6: SendAlert

 public void SendAlert(string message)
 {
     var Response = new ServerMessage(Opcodes.OpcodesOut.SendIlluminaAlert);
     Response.Append<string>(message);
     SendPacket(Response);
 }
开发者ID:habb0,项目名称:FerriEmulator,代码行数:6,代码来源:Session.cs

示例7: Serialize

        internal static void Serialize(ServerMessage Msg, rooms Room)
        {
            Msg.Append<uint>(Room.ID);
            Msg.Append<bool>(false);
            Msg.Append<string>(Room.Caption);
            Msg.Append<bool>(true);
            Msg.Append<int>(Engine.dbManager.ReadInt("SELECT id FROM members WHERE username = '" + Room.Owner + "'"));
            Msg.Append<string>(Room.Owner);
            Msg.Append<int>(Room.State);
            Msg.Append<int>(Room.Users_Now);
            Msg.Append<int>(Room.Users_Max);
            Msg.Append<string>(Room.Description);
            Msg.Append<int>(0);
            Msg.Append<int>(0);
            Msg.Append<int>(Room.Score);
            Msg.Append<int>(Room.Category);
            Msg.Append<int>(Room.GroupID);

            if (Room.GroupID > 0)
            {
                groups group = Engine.GetHabboHotel.getGroups.Groups[Room.GroupID];
                Msg.Append<string>(group.Name);
                Msg.Append<string>(group.Badges);
                Msg.Append<string>("");
            }
            else
            {
                Msg.Append<string>("");
                Msg.Append<string>("");
                Msg.Append<string>("");
            }

            Msg.Append<int>(Room.Tags.Length);
            Msg.Append<string[]>(Room.Tags);
            Msg.Append<int>(0);
            Msg.Append<int>(0);
            Msg.Append<int>(0);
            Msg.Append<bool>(true);
            Msg.Append<bool>(true);
        }
开发者ID:habb0,项目名称:FerriEmulator,代码行数:40,代码来源:FluentRooms.cs


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