internal FriendMsgCallback(CMsgClientFriendMsgIncoming msg) #endif { this.Sender = msg.steamid_from; this.EntryType = ( EChatEntryType )msg.chat_entry_type; this.FromLimitedAccount = msg.from_limited_account; if (msg.message != null && msg.message.Length > 0) { this.Message = Encoding.UTF8.GetString(msg.message, 0, msg.message.Length - 1); } }
internal FriendMsgEchoCallback(CMsgClientFriendMsgIncoming msg) { this.Recipient = msg.steamid_from; this.EntryType = ( EChatEntryType )msg.chat_entry_type; this.FromLimitedAccount = msg.from_limited_account; if (msg.message != null) { this.Message = Encoding.UTF8.GetString(msg.message); this.Message = this.Message.TrimEnd(new[] { '\0' }); // trim any extra null chars from the end } }
internal FriendMsgCallback(SteamClient client, CMsgClientFriendMsgIncoming msg) : base(client)