Chat message represents a single message send or received from or to the chat
Beispiel #1
0
 public void Add(ChatMessage message)
 {
     messages.Add(message);
 }
Beispiel #2
0
        public void HandleCallback(CallbackMsg msg)
        {
            if(msg.IsType<SteamFriends.FriendMsgCallback>())
            {
                SteamFriends.FriendMsgCallback callback = (SteamFriends.FriendMsgCallback)msg;

                if(callback.EntryType == EChatEntryType.ChatMsg && callback.Sender == friend.SteamId)
                {
                    ChatMessage message = new ChatMessage(friend, callback.Message);
                    Add(message);
                    NotifyDataSetChanged();
                }
            }
        }