Skip to main content
Version: 5.9.6

[deprecated] OnSessionOnlineGuildChannel

public SessionOnlineEventHandler OnSessionOnlineGuildChannel;

Deprecation notice
  • This feature is no longer supported in BACKND versions 5.5.0 or later. The connection is completely destroyed on failure, and OnLeaveGuildChannel handler is called instead.

Argument

ValueTypeDescription
argsSessionOnlineEventArgsWhether reconnecting to the chat server succeeded/failed

SessionOnlineEventArgs

ValueTypeDescription
ErrInfoErrorInfoSuccess/failure information
SessionSessionInfoSessionInfo of the user disconnected from the channel

Description

This is an event that is called when another user is reconnected after being temporarily disconnected from the guild channel.

In order for an event to be called, the message sending/receiving method must be called.

Example

// First way
Backend.Chat.OnSessionOnlineGuildChannel = (SessionOnlineEventArgs args) =>
{
Debug.Log(string.Format("OnSessionOnlineGuildChannel {0}", args.ErrInfo));
// When reentered successfully
if(args.ErrInfo == ErrorInfo.Success)
{
// When you connect
if(!args.Session.IsRemote)
{
Debug.Log("Reconnected to the channel.");
}
// When another user connects
else
{
Debug.log(args.Session.Nickname + " reconnected.");
}
}
else
{
// When an error occurs
Debug.Log("An error occurred during re-entrance : " + args.ErrInfo.Reason);
}
};

// Second way
Backend.Chat.OnSessionOnlineGuildChannel += (args) => {
// Same logic as the first way
}

Argument cases

When reconnection to the chat server is successful ErrInfo.Category: Success ErrInfo.Detail: NetworkOnline ErrInfo.SocketError: Success ErrInfo.Reason: Session Reconnect