UIKit GS2-Chat sample
This sample shows how to create a chat room, subscribe/unsubscribe, reflect received messages in the UI, and send messages.
Folder structure
Sample folder :
(Unity Project)/Assets/Game Server Services/Samples/UIKit/Gs2Chat/
.
Sample scene :
(sample folder)/Scenes/Chat.unity
.
The prefab on which this sample depends is The prefab must be placed in the scene.
- Gs2
- Gs2AccountAutoLogin
- Gs2GatewaySetUserIdAction
GS2-Deploy Sample Template:
(sample folder)/Settings/initialize_chat_template.yaml
.
Create Room
Create a chat room using the Create Room button.
Prefab |
---|
Gs2ChatRoomCreateAction |
Subscribe to subscriptions
Prefab |
---|
Gs2ChatRoomSubscribeAction |
Unsubscribe
Prefab |
---|
Gs2ChatRoomSubscribeAction |
Send message
Prefab |
---|
Gs2ChatMessagePostAction |