本文整理汇总了C#中Messages.PopFixedString方法的典型用法代码示例。如果您正苦于以下问题:C# Messages.PopFixedString方法的具体用法?C# Messages.PopFixedString怎么用?C# Messages.PopFixedString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Messages
的用法示例。
在下文中一共展示了Messages.PopFixedString方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
string Junk = Packet.PopFixedString();
string MachineId = Packet.PopFixedString();
Session.MachineId = MachineId;
}
示例2: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
int junk1 = Packet.PopWiredInt32();
int junk2 = Packet.PopWiredInt32();
uint RoomId = Packet.PopWiredUInt();
string Name = Packet.PopFixedString();
bool junk3 = Packet.PopWiredBoolean();
string Desc = Packet.PopFixedString();
SilverwaveEnvironment.GetGame().GetRoomEvents().AddNewEvent(RoomId, Name, Desc, Session);
Session.SendMessage(new PurchaseOKComposer());
Session.GetHabbo().Credits -= 500;
Session.GetHabbo().UpdateCreditsBalance();
}
示例3: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
uint RoomId = Packet.PopWiredUInt();
string Password = Packet.PopFixedString();
Session.GetMessageHandler().PrepareRoomForUser(RoomId, Password);
}
示例4: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
string Type = Packet.PopFixedString();
string PacketType = "";
int PetId = PetRace.GetPetId(Type, out PacketType);
Session.SendMessage(new SellablePetBreedsComposer(PacketType, PetId, PetRace.GetRacesForRaceId(PetId)));
}
示例5: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
if (SilverwaveEnvironment.GetDBConfig().DBData["gifts_enabled"] != "1")
{
Session.SendNotif("The hotel managers have disabled gifting");
return;
}
int PageId = Packet.PopWiredInt32();
int ItemId = Packet.PopWiredInt32();
string ExtraData = Packet.PopFixedString();
string GiftUser = Packet.PopFixedString();
string GiftMessage = Packet.PopFixedString();
int SpriteId = Packet.PopWiredInt32();
int Lazo = Packet.PopWiredInt32();
int Color = Packet.PopWiredInt32();
bool dnow = Packet.PopWiredBoolean();
SilverwaveEnvironment.GetGame().GetCatalog().HandlePurchase(Session, PageId, ItemId, ExtraData, 1, true, GiftUser, GiftMessage, SpriteId, Lazo, Color, dnow, 0);
}
示例6: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
Silverwave.HabboHotel.Users.Habbo targetHabbo = Session.GetHabbo();
if (targetHabbo == null)
{
return;
}
Session.SendMessage(SilverwaveEnvironment.GetGame().GetNavigator().SerializeNavigator(Session, int.Parse(Packet.PopFixedString())));
}
示例7: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
string CipherPublickey = Packet.PopFixedString();
if (!SilverwaveEnvironment.globalCrypto.InitializeRC4ToSession(Session, CipherPublickey))
{
Session.SendNotif("There was an error logging you in, please try again!");
return;
}
Session.SendMessage(new SecretKeyComposer(SilverwaveEnvironment.globalCrypto.PublicKey.ToString()));
}
示例8: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
if (Session.GetHabbo() == null)
{
Session.tryLogin(Packet.PopFixedString());
if (Session != null)
Session.TimePingedReceived = DateTime.Now;
}
else
{
Session.SendNotif("This user is already logged in.");
}
}
示例9: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
/*if (SilverwaveEnvironment.GetDBConfig().DBData["catalogue_enabled"] != "1")
{
Session.SendNotif("The hotel managers have disabled the catalogue");
return;
}*/
int PageId = Packet.PopWiredInt32();
int ItemId = Packet.PopWiredInt32();
string ExtraData = Packet.PopFixedString();
int Amount = Packet.PopWiredInt32();
SilverwaveEnvironment.GetGame().GetCatalog().HandlePurchase(Session, PageId, ItemId, ExtraData, Amount, false, "", "", 0, 0, 0, false, 0);
}
示例10: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
if (!Session.GetHabbo().InRoom)
{
return;
}
Room Room = Session.GetHabbo().CurrentRoom;
string Params = Packet.PopFixedString();
string ToUser = Params.Split(' ')[0];
string Message = Params.Substring(ToUser.Length + 1);
int Bubble = Packet.PopWiredInt32();
RoomUser User = Room.GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id);
RoomUser User2 = Room.GetRoomUserManager().GetRoomUserByHabbo(ToUser);
Message = LanguageLocale.FilterSwearwords(Message);
if (User == null || User2 == null)
{
return;
}
if (Session.GetHabbo().Rank < 4 && Room.CheckMute(Session))
{
Session.SendNotif("You are unable to whisper as you are muted");
return;
}
bool ContainsBanned = LanguageLocale.CheckForBannedPhrases(Message) && Session.GetHabbo().Rank < 4;
//Room.AddChatlog(Session.GetHabbo().Id, "<Whisper to " + ToUser + ">: " + Message, ContainsBanned);
if (ContainsBanned)
{
Session.GetHabbo().BannedPhraseCount++;
if (Session.GetHabbo().BannedPhraseCount >= Convert.ToInt32(SilverwaveEnvironment.GetDBConfig().DBData["spambans.limit"]))
{
if (!String.IsNullOrWhiteSpace(Message))
{
SilverwaveEnvironment.GetGame().GetBanManager().BanUser(Session, "System", 788922000, "Spamming the following: " + Message, true, false);
return;
}
}
return;
}
int Colour = 0;
int MuteTime;
if (User.IncrementAndCheckFlood(out MuteTime))
{
Session.SendMessage(new FloodControlComposer(MuteTime));
return;
}
SilverwaveEnvironment.GetGame().GetQuestManager().ProgressUserQuest(Session, HabboHotel.Quests.QuestType.SOCIAL_CHAT);
Colour = User.CheckChatColour(Bubble);
User.UnIdle();
User.GetClient().SendMessage(new WhisperComposer(User, Message, 0, Colour));
if (User2 != null && !User2.IsBot && User2.userID != User.userID)
{
if (User2.GetClient().GetHabbo().DisableWhisper)
{
User.GetClient().SendWhisper("This user does not allow whispers");
return;
}
else
{
if (!User2.GetClient().GetHabbo().MutedUsers.Contains(Session.GetHabbo().Id))
{
User2.GetClient().SendMessage(new WhisperComposer(User, Message, 0, Colour));
}
}
}
List<RoomUser> ToNotify = Room.GetRoomUserManager().GetRoomUserByRank(4);
if (ToNotify.Count > 0)
{
foreach (RoomUser user in ToNotify)
{
if (user != null)
{
if (user.HabboId != User2.HabboId && user.HabboId != User.HabboId)
{
if (user.GetClient() != null)
{
user.GetClient().SendMessage(new WhisperComposer(User, LanguageLocale.GetValue("moderation.whisper") + ToUser + ": " + Message, 0, Colour));
}
}
}
}
}
}
示例11: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
string Build = Packet.PopFixedString();
SilverwaveEnvironment.ClientBuild = Build;
}
示例12: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
string PetName = Packet.PopFixedString();
Session.SendMessage(new CheckPetNameComposer(PetName, true));
}
示例13: Parse
public void Parse(HabboHotel.GameClients.GameClient Session, Messages.ClientMessage Packet)
{
if (!Session.GetHabbo().InRoom)
{
return;
}
Room Room = Session.GetHabbo().CurrentRoom;
RoomUser User = Room.GetRoomUserManager().GetRoomUserByHabbo(Session.GetHabbo().Id);
string Message = Packet.PopFixedString();
int Colour = Packet.PopWiredInt32();
int CountUselessSulakeStuff = Packet.PopWiredInt32();
if (User == null)
{
return;
}
if (Session.GetHabbo().Rank < 4 && Room.CheckMute(Session))
{
Session.SendNotif("You are unable to talk as you are muted");
return;
}
if (Message.StartsWith(":"))
{
Colour = User.LastBubble;
}
else
{
User.LastBubble = Colour;
}
if (Message.StartsWith(":") && ChatCommandHandler.Parse(Session, Message))
{
return;
}
bool ContainsBanned = LanguageLocale.CheckForBannedPhrases(Message) && Session.GetHabbo().Rank < 4;
//Room.AddChatlog(Session.GetHabbo().Id, Message, ContainsBanned);
if (ContainsBanned)
{
Session.GetHabbo().BannedPhraseCount++;
if (Session.GetHabbo().BannedPhraseCount >= Convert.ToInt32(SilverwaveEnvironment.GetDBConfig().DBData["spambans.limit"]))
{
if (!String.IsNullOrWhiteSpace(Message))
{
SilverwaveEnvironment.GetGame().GetBanManager().BanUser(Session, "System", 788922000, "Spamming the following: " + Message, true, false);
return;
}
}
return;
}
Message = LanguageLocale.FilterSwearwords(Message);
int MuteTime;
if (User.IncrementAndCheckFlood(out MuteTime))
{
Session.SendMessage(new FloodControlComposer(MuteTime));
return;
}
SilverwaveEnvironment.GetGame().GetQuestManager().ProgressUserQuest(Session, HabboHotel.Quests.QuestType.SOCIAL_CHAT);
User.UnIdle();
//User.OnChat(Colour, Message, false);
User.Chat(Session, Message, false,CountUselessSulakeStuff,Colour);
}