EOS_RTC_AddNotifyParticipantStatusChanged

EOS API reference page for EOS_RTC_AddNotifyParticipantStatusChanged

4 분 소요

This function is part of the RTC Interface.

Remarks

Register to receive notifications when a participant's status changes (e.g: join or leave the room), or when the participant is added or removed from an applicable block list (e.g: Epic block list and/or current platform's block list). If the returned NotificationId is valid, you must call EOS_RTC_RemoveNotifyParticipantStatusChanged when you no longer wish to have your CompletionDelegate called. If you register to this notification before joining a room, you will receive a notification for every member already in the room when you join said room. This allows you to know who is already in the room when you join. To be used effectively with a Lobby-managed RTC room, this should be registered during the EOS_Lobby_CreateLobby or EOS_Lobby_JoinLobby completion callbacks when the ResultCode is EOS_Success. If this notification is registered after that point, it is possible to miss notifications for already-existing room participants. You can use this notification to detect internal automatic RTC blocks due to block lists. When a participant joins a room and while the system resolves the block list status of said participant, the participant is set to blocked and you'll receive a notification with ParticipantStatus set to EOS_RTCPS_Joined and bParticipantInBlocklist set to true. Once the block list status is resolved, if the player is not in any applicable block list(s), it is then unblocked a new notification is sent with ParticipantStatus set to EOS_RTCPS_Joined and bParticipantInBlocklist set to false.

This notification is also raised when the local user joins the room, but NOT when the local user leaves the room.

Return Value

Notification ID representing the registered callback if successful, an invalid NotificationId if not

See Also

EOS_INVALID_NOTIFICATIONID, EOS_RTC_RemoveNotifyParticipantStatusChanged

Parameters

EOS_RTC_AddNotifyParticipantStatusChanged

Parameter Type And NameUsage Information
EOS_HRTC Handle
const EOS_RTC_AddNotifyParticipantStatusChangedOptions* Options
void* ClientDataArbitrary data that is passed back in the CompletionDelegate
const EOS_RTC_OnParticipantStatusChangedCallback CompletionDelegateThe callback to be fired when a presence change occurs

Callback Function Information

Because this function is asynchronous, it employs a callback of type EOS_RTC_OnParticipantStatusChangedCallback to report the results of its operation.

Callback Parameters

EOS_RTC_OnParticipantStatusChangedCallback

Parameter Type And NameUsage Information
const EOS_RTC_ParticipantStatusChangedCallbackInfo* DataThis struct is passed in with a call to EOS_RTC_AddNotifyParticipantStatusChanged registered event.