internal void AddMessage(ChatMessage message) { listOfMessages.AddFirst(message); if (amountOfMessagesInside == 100) listOfMessages.RemoveLast(); else amountOfMessagesInside++; }
internal static ChatMessage CreateMessage(string message, GameClient user, Room room) { uint userID = user.GetHabbo().Id; string username = user.GetHabbo().Username; uint roomID = room.RoomId; string roomName = room.Name; DateTime timeSpoken = DateTime.Now; ChatMessage chatMessage = new ChatMessage(userID, username, roomID, roomName, message, timeSpoken); return chatMessage; }