Example #1
0
 public void Serialize(Net.Messages.ServerMessage Message, int Rank)
 {
     Message.AppendInt32(getTreeCount());
     foreach (CatalogueIndex t in cataIndex)
     {
         if (t.IsTree != false && Rank >= t.MinRank)
         {
             Message.AppendBoolean(true);
             Message.AppendInt32(t.Colour);
             Message.AppendInt32(t.Icon);
             Message.AppendInt32(Convert.ToBoolean(t.PageId) ? t.PageId : -1);
             Message.AppendString(t.DisplayName);
             Message.AppendInt32(getSubcatCount(t.ID));
             foreach (CatalogueIndex c in cataIndex)
             {
                 if (c.IsTree != true && c.InCategory == t.ID && Rank >= t.MinRank)
                 {
                     Message.AppendBoolean(true);
                     Message.AppendInt32(c.Colour);
                     Message.AppendInt32(c.Icon);
                     Message.AppendInt32(c.ID);
                     Message.AppendString(c.DisplayName);
                     Message.AppendInt32(0);
                 }
             }
         }
     }
 }
Example #2
0
 public void SendToBuddies(Net.Messages.ServerMessage Message)
 {
     lock (mBuddies)
     {
         foreach (MessengerBuddy buddy in mBuddies)
         {
             AleedaEnvironment.GetHabboHotel().GetClients().GetClientOfHabbo(buddy.ID).GetConnection().SendMessage(Message);
         }
     }
 }