Beispiel #1
0
        public void SendRoomMessage()
        {
            var topic       = StateManager.Instance.Topics[RoomName];
            var chatMessage = new ChatMessageContent {
                Body = _inputField.text
            };

            NakamaManager.Instance.TopicSendMessage(topic, JsonUtility.ToJson(chatMessage));
        }
Beispiel #2
0
        public void SendDirectMessage()
        {
            var user        = StateManager.Instance.Friends[_friendSelectorDropdown.value];
            var topic       = StateManager.Instance.Topics[user.User.Id];
            var chatMessage = new ChatMessageContent {
                Body = _inputField.text
            };

            NakamaManager.Instance.TopicSendMessage(topic, JsonUtility.ToJson(chatMessage));
        }