// Copyright Epic Games, Inc. All Rights Reserved. // This file is automatically generated. Changes to this file may be overwritten. namespace Epic.OnlineServices.Lobby { public sealed partial class LobbyInterface : Handle { public LobbyInterface() { } public LobbyInterface(System.IntPtr innerHandle) : base(innerHandle) { } /// /// The most recent version of the API. /// public const int AddnotifyjoinlobbyacceptedApiLatest = 1; /// /// The most recent version of the API. /// public const int AddnotifylobbyinviteacceptedApiLatest = 1; /// /// The most recent version of the API. /// public const int AddnotifylobbyinvitereceivedApiLatest = 1; /// /// The most recent version of the API. /// public const int AddnotifylobbymemberstatusreceivedApiLatest = 1; /// /// The most recent version of the API. /// public const int AddnotifylobbymemberupdatereceivedApiLatest = 1; /// /// The most recent version of the API. /// public const int AddnotifylobbyupdatereceivedApiLatest = 1; /// /// The most recent version of the API. /// public const int AddnotifyrtcroomconnectionchangedApiLatest = 1; /// /// The most recent version of the struct. /// public const int AttributeApiLatest = 1; /// /// The most recent version of the struct. /// public const int AttributedataApiLatest = 1; /// /// The most recent version of the API. /// public const int CopylobbydetailshandleApiLatest = 1; /// /// The most recent version of the API. /// public const int CopylobbydetailshandlebyinviteidApiLatest = 1; /// /// The most recent version of the API. /// public const int CopylobbydetailshandlebyuieventidApiLatest = 1; /// /// The most recent version of the API. /// public const int CreatelobbyApiLatest = 7; /// /// The most recent version of the API. /// public const int CreatelobbysearchApiLatest = 1; /// /// The most recent version of the API. /// public const int DestroylobbyApiLatest = 1; /// /// The most recent version of the API. /// public const int GetinvitecountApiLatest = 1; /// /// The most recent version of the API. /// public const int GetinviteidbyindexApiLatest = 1; /// /// The most recent version of the API. /// public const int GetrtcroomnameApiLatest = 1; /// /// Max length of an invite ID /// public const int InviteidMaxLength = 64; /// /// The most recent version of the API. /// public const int IsrtcroomconnectedApiLatest = 1; /// /// The most recent version of the API. /// public const int JoinlobbyApiLatest = 3; /// /// The most recent version of the API. /// public const int KickmemberApiLatest = 1; /// /// The most recent version of the API. /// public const int LeavelobbyApiLatest = 1; /// /// The most recent version of the structure. /// public const int LocalrtcoptionsApiLatest = 1; /// /// All lobbies are referenced by a unique lobby ID /// public const int MaxLobbies = 16; public const int MaxLobbyMembers = 64; /// /// Maximum number of characters allowed in the lobby id override /// public const int MaxLobbyidoverrideLength = 60; public const int MaxSearchResults = 200; /// /// Minimum number of characters allowed in the lobby id override /// public const int MinLobbyidoverrideLength = 4; /// /// The most recent version of the API. /// public const int PromotememberApiLatest = 1; /// /// The most recent version of the API. /// public const int QueryinvitesApiLatest = 1; /// /// The most recent version of the API. /// public const int RejectinviteApiLatest = 1; /// /// Search for a matching bucket ID (value is string) /// public const string SearchBucketId = "bucket"; /// /// Search for lobbies that contain at least this number of members (value is int) /// public const string SearchMincurrentmembers = "mincurrentmembers"; /// /// Search for a match with min free space (value is int) /// public const string SearchMinslotsavailable = "minslotsavailable"; /// /// The most recent version of the API. /// public const int SendinviteApiLatest = 1; /// /// The most recent version of the API. /// public const int UpdatelobbyApiLatest = 1; /// /// The most recent version of the API. /// public const int UpdatelobbymodificationApiLatest = 1; /// /// Register to receive notifications about lobby join game accepted by local user via the overlay. /// @note must call to remove the notification /// /// Structure containing information about the request. /// Arbitrary data that is passed back to you in the CompletionDelegate. /// A callback that is fired when a notification is received. /// /// handle representing the registered callback /// public ulong AddNotifyJoinLobbyAccepted(AddNotifyJoinLobbyAcceptedOptions options, object clientData, OnJoinLobbyAcceptedCallback notificationFn) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var notificationFnInternal = new OnJoinLobbyAcceptedCallbackInternal(OnJoinLobbyAcceptedCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, notificationFn, notificationFnInternal); var funcResult = Bindings.EOS_Lobby_AddNotifyJoinLobbyAccepted(InnerHandle, optionsAddress, clientDataAddress, notificationFnInternal); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryAssignNotificationIdToCallback(clientDataAddress, funcResult); return funcResult; } /// /// Register to receive notifications about lobby invites accepted by local user via the overlay. /// @note must call RemoveNotifyLobbyInviteAccepted to remove the notification /// /// Structure containing information about the request. /// Arbitrary data that is passed back to you in the CompletionDelegate. /// A callback that is fired when a a notification is received. /// /// handle representing the registered callback /// public ulong AddNotifyLobbyInviteAccepted(AddNotifyLobbyInviteAcceptedOptions options, object clientData, OnLobbyInviteAcceptedCallback notificationFn) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var notificationFnInternal = new OnLobbyInviteAcceptedCallbackInternal(OnLobbyInviteAcceptedCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, notificationFn, notificationFnInternal); var funcResult = Bindings.EOS_Lobby_AddNotifyLobbyInviteAccepted(InnerHandle, optionsAddress, clientDataAddress, notificationFnInternal); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryAssignNotificationIdToCallback(clientDataAddress, funcResult); return funcResult; } /// /// Register to receive notifications about lobby invites sent to local users. /// @note must call RemoveNotifyLobbyInviteReceived to remove the notification /// /// Structure containing information about the request. /// Arbitrary data that is passed back to you in the CompletionDelegate. /// A callback that is fired when a a notification is received. /// /// handle representing the registered callback /// public ulong AddNotifyLobbyInviteReceived(AddNotifyLobbyInviteReceivedOptions options, object clientData, OnLobbyInviteReceivedCallback notificationFn) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var notificationFnInternal = new OnLobbyInviteReceivedCallbackInternal(OnLobbyInviteReceivedCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, notificationFn, notificationFnInternal); var funcResult = Bindings.EOS_Lobby_AddNotifyLobbyInviteReceived(InnerHandle, optionsAddress, clientDataAddress, notificationFnInternal); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryAssignNotificationIdToCallback(clientDataAddress, funcResult); return funcResult; } /// /// Register to receive notifications about the changing status of lobby members. /// @note must call RemoveNotifyLobbyMemberStatusReceived to remove the notification /// /// Structure containing information about the request. /// Arbitrary data that is passed back to you in the CompletionDelegate. /// A callback that is fired when a a notification is received. /// /// handle representing the registered callback /// public ulong AddNotifyLobbyMemberStatusReceived(AddNotifyLobbyMemberStatusReceivedOptions options, object clientData, OnLobbyMemberStatusReceivedCallback notificationFn) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var notificationFnInternal = new OnLobbyMemberStatusReceivedCallbackInternal(OnLobbyMemberStatusReceivedCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, notificationFn, notificationFnInternal); var funcResult = Bindings.EOS_Lobby_AddNotifyLobbyMemberStatusReceived(InnerHandle, optionsAddress, clientDataAddress, notificationFnInternal); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryAssignNotificationIdToCallback(clientDataAddress, funcResult); return funcResult; } /// /// Register to receive notifications when a lobby member updates the attributes associated with themselves inside the lobby. /// @note must call RemoveNotifyLobbyMemberUpdateReceived to remove the notification /// /// Structure containing information about the request. /// Arbitrary data that is passed back to you in the CompletionDelegate. /// A callback that is fired when a a notification is received. /// /// handle representing the registered callback /// public ulong AddNotifyLobbyMemberUpdateReceived(AddNotifyLobbyMemberUpdateReceivedOptions options, object clientData, OnLobbyMemberUpdateReceivedCallback notificationFn) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var notificationFnInternal = new OnLobbyMemberUpdateReceivedCallbackInternal(OnLobbyMemberUpdateReceivedCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, notificationFn, notificationFnInternal); var funcResult = Bindings.EOS_Lobby_AddNotifyLobbyMemberUpdateReceived(InnerHandle, optionsAddress, clientDataAddress, notificationFnInternal); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryAssignNotificationIdToCallback(clientDataAddress, funcResult); return funcResult; } /// /// Register to receive notifications when a lobby owner updates the attributes associated with the lobby. /// @note must call RemoveNotifyLobbyUpdateReceived to remove the notification /// /// Structure containing information about the request. /// Arbitrary data that is passed back to you in the CompletionDelegate. /// A callback that is fired when a a notification is received. /// /// handle representing the registered callback /// public ulong AddNotifyLobbyUpdateReceived(AddNotifyLobbyUpdateReceivedOptions options, object clientData, OnLobbyUpdateReceivedCallback notificationFn) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var notificationFnInternal = new OnLobbyUpdateReceivedCallbackInternal(OnLobbyUpdateReceivedCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, notificationFn, notificationFnInternal); var funcResult = Bindings.EOS_Lobby_AddNotifyLobbyUpdateReceived(InnerHandle, optionsAddress, clientDataAddress, notificationFnInternal); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryAssignNotificationIdToCallback(clientDataAddress, funcResult); return funcResult; } /// /// Register to receive notifications of when the RTC Room for a particular lobby has a connection status change. /// /// The RTC Room connection status is independent of the lobby connection status, however the lobby system will attempt to keep /// them consistent, automatically connecting to the RTC room after joining a lobby which has an associated RTC room and disconnecting /// from the RTC room when a lobby is left or disconnected. /// /// This notification is entirely informational and requires no action in response by the application. If the connected status is offline /// (bIsConnected is false), the connection will automatically attempt to reconnect. The purpose of this notification is to allow /// applications to show the current connection status of the RTC room when the connection is not established. /// /// Unlike , should not be called when the RTC room is disconnected. /// /// This function will only succeed when called on a lobby the local user is currently a member of. /// /// /// Structure containing information about the lobby to receive updates about /// Arbitrary data that is passed back to you in the CompletionDelegate. /// The function to call if the RTC Room's connection status changes /// /// A valid notification ID if the NotificationFn was successfully registered, or if the input was invalid, the lobby did not exist, or the lobby did not have an RTC room. /// public ulong AddNotifyRTCRoomConnectionChanged(AddNotifyRTCRoomConnectionChangedOptions options, object clientData, OnRTCRoomConnectionChangedCallback notificationFn) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var notificationFnInternal = new OnRTCRoomConnectionChangedCallbackInternal(OnRTCRoomConnectionChangedCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, notificationFn, notificationFnInternal); var funcResult = Bindings.EOS_Lobby_AddNotifyRTCRoomConnectionChanged(InnerHandle, optionsAddress, clientDataAddress, notificationFnInternal); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryAssignNotificationIdToCallback(clientDataAddress, funcResult); return funcResult; } /// /// Create a handle to an existing lobby. /// If the call returns an result, the out parameter, OutLobbyDetailsHandle, must be passed to to release the memory associated with it. /// /// Structure containing information about the lobby to retrieve /// The new active lobby handle or null if there was an error /// /// if the lobby handle was created successfully /// if any of the options are incorrect /// if the API version passed in is incorrect /// if the lobby doesn't exist /// public Result CopyLobbyDetailsHandle(CopyLobbyDetailsHandleOptions options, out LobbyDetails outLobbyDetailsHandle) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var outLobbyDetailsHandleAddress = System.IntPtr.Zero; var funcResult = Bindings.EOS_Lobby_CopyLobbyDetailsHandle(InnerHandle, optionsAddress, ref outLobbyDetailsHandleAddress); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryMarshalGet(outLobbyDetailsHandleAddress, out outLobbyDetailsHandle); return funcResult; } /// /// is used to immediately retrieve a handle to the lobby information from after notification of an invite /// If the call returns an result, the out parameter, OutLobbyDetailsHandle, must be passed to to release the memory associated with it. /// /// /// /// Structure containing the input parameters /// out parameter used to receive the lobby handle /// /// if the information is available and passed out in OutLobbyDetailsHandle /// if you pass an invalid invite ID or a null pointer for the out parameter /// if the API version passed in is incorrect /// If the invite ID cannot be found /// public Result CopyLobbyDetailsHandleByInviteId(CopyLobbyDetailsHandleByInviteIdOptions options, out LobbyDetails outLobbyDetailsHandle) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var outLobbyDetailsHandleAddress = System.IntPtr.Zero; var funcResult = Bindings.EOS_Lobby_CopyLobbyDetailsHandleByInviteId(InnerHandle, optionsAddress, ref outLobbyDetailsHandleAddress); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryMarshalGet(outLobbyDetailsHandleAddress, out outLobbyDetailsHandle); return funcResult; } /// /// is used to immediately retrieve a handle to the lobby information from after notification of an join game /// If the call returns an result, the out parameter, OutLobbyDetailsHandle, must be passed to to release the memory associated with it. /// /// /// /// Structure containing the input parameters /// out parameter used to receive the lobby handle /// /// if the information is available and passed out in OutLobbyDetailsHandle /// if you pass an invalid ui event ID /// if the API version passed in is incorrect /// If the invite ID cannot be found /// public Result CopyLobbyDetailsHandleByUiEventId(CopyLobbyDetailsHandleByUiEventIdOptions options, out LobbyDetails outLobbyDetailsHandle) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var outLobbyDetailsHandleAddress = System.IntPtr.Zero; var funcResult = Bindings.EOS_Lobby_CopyLobbyDetailsHandleByUiEventId(InnerHandle, optionsAddress, ref outLobbyDetailsHandleAddress); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryMarshalGet(outLobbyDetailsHandleAddress, out outLobbyDetailsHandle); return funcResult; } /// /// Creates a lobby and adds the user to the lobby membership. There is no data associated with the lobby at the start and can be added vis /// /// If the lobby is successfully created with an RTC Room enabled, the lobby system will automatically join and maintain the connection to the RTC room as long as the /// local user remains in the lobby. Applications can use the to get the name of the RTC Room associated with a lobby, which may be used with /// suite of functions. This can be useful to: register for notifications for talking status; to mute or unmute the local user's audio output; /// to block or unblock room participants; to set local audio device settings; and more. /// /// Required fields for the creation of a lobby such as a user count and its starting advertised state /// Arbitrary data that is passed back to you in the CompletionDelegate /// A callback that is fired when the create operation completes, either successfully or in error /// /// if the creation completes successfully /// if any of the options are incorrect /// if the number of allowed lobbies is exceeded /// public void CreateLobby(CreateLobbyOptions options, object clientData, OnCreateLobbyCallback completionDelegate) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var completionDelegateInternal = new OnCreateLobbyCallbackInternal(OnCreateLobbyCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, completionDelegate, completionDelegateInternal); Bindings.EOS_Lobby_CreateLobby(InnerHandle, optionsAddress, clientDataAddress, completionDelegateInternal); Helper.TryMarshalDispose(ref optionsAddress); } /// /// Create a lobby search handle. This handle may be modified to include various search parameters. /// Searching is possible in three methods, all mutually exclusive /// - set the lobby ID to find a specific lobby /// - set the target user ID to find a specific user /// - set lobby parameters to find an array of lobbies that match the search criteria (not available yet) /// /// Structure containing required parameters such as the maximum number of search results /// The new search handle or null if there was an error creating the search handle /// /// if the search creation completes successfully /// if any of the options are incorrect /// public Result CreateLobbySearch(CreateLobbySearchOptions options, out LobbySearch outLobbySearchHandle) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var outLobbySearchHandleAddress = System.IntPtr.Zero; var funcResult = Bindings.EOS_Lobby_CreateLobbySearch(InnerHandle, optionsAddress, ref outLobbySearchHandleAddress); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryMarshalGet(outLobbySearchHandleAddress, out outLobbySearchHandle); return funcResult; } /// /// Destroy a lobby given a lobby ID /// /// Structure containing information about the lobby to be destroyed /// Arbitrary data that is passed back to you in the CompletionDelegate /// A callback that is fired when the destroy operation completes, either successfully or in error /// /// if the destroy completes successfully /// if any of the options are incorrect /// if the lobby is already marked for destroy /// if the lobby to be destroyed does not exist /// public void DestroyLobby(DestroyLobbyOptions options, object clientData, OnDestroyLobbyCallback completionDelegate) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var completionDelegateInternal = new OnDestroyLobbyCallbackInternal(OnDestroyLobbyCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, completionDelegate, completionDelegateInternal); Bindings.EOS_Lobby_DestroyLobby(InnerHandle, optionsAddress, clientDataAddress, completionDelegateInternal); Helper.TryMarshalDispose(ref optionsAddress); } /// /// Get the number of known invites for a given user /// /// the Options associated with retrieving the current invite count /// /// number of known invites for a given user or 0 if there is an error /// public uint GetInviteCount(GetInviteCountOptions options) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var funcResult = Bindings.EOS_Lobby_GetInviteCount(InnerHandle, optionsAddress); Helper.TryMarshalDispose(ref optionsAddress); return funcResult; } /// /// Retrieve an invite ID from a list of active invites for a given user /// /// /// /// Structure containing the input parameters /// /// if the input is valid and an invite ID was returned /// if any of the options are incorrect /// if the invite doesn't exist /// public Result GetInviteIdByIndex(GetInviteIdByIndexOptions options, out string outBuffer) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); System.IntPtr outBufferAddress = System.IntPtr.Zero; int inOutBufferLength = InviteidMaxLength + 1; Helper.TryMarshalAllocate(ref outBufferAddress, inOutBufferLength); var funcResult = Bindings.EOS_Lobby_GetInviteIdByIndex(InnerHandle, optionsAddress, outBufferAddress, ref inOutBufferLength); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryMarshalGet(outBufferAddress, out outBuffer); Helper.TryMarshalDispose(ref outBufferAddress); return funcResult; } /// /// Get the name of the RTC room associated with a specific lobby a local user belongs to. /// /// suite of functions. RTC Room Names must not be used with /// , , or . Doing so will return or /// if used with those functions. /// /// This function will only succeed when called on a lobby the local user is currently a member of. /// /// Structure containing information about the RTC room name to retrieve /// The buffer to store the null-terminated room name string within /// In: The maximum amount of writable chars in OutBuffer, Out: The minimum amount of chars needed in OutBuffer to store the RTC room name (including the null-terminator) /// /// if a room exists for the specified lobby, there was enough space in OutBuffer, and the name was written successfully /// if the lobby does not exist /// if the lobby exists, but did not have the RTC Room feature enabled when created /// if you pass a null pointer on invalid length for any of the parameters /// The OutBuffer is not large enough to receive the room name. InOutBufferLength contains the required minimum length to perform the operation successfully. /// public Result GetRTCRoomName(GetRTCRoomNameOptions options, out string outBuffer) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); System.IntPtr outBufferAddress = System.IntPtr.Zero; uint inOutBufferLength = 256; Helper.TryMarshalAllocate(ref outBufferAddress, inOutBufferLength); var funcResult = Bindings.EOS_Lobby_GetRTCRoomName(InnerHandle, optionsAddress, outBufferAddress, ref inOutBufferLength); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryMarshalGet(outBufferAddress, out outBuffer); Helper.TryMarshalDispose(ref outBufferAddress); return funcResult; } /// /// Get the current connection status of the RTC Room for a lobby. /// /// The RTC Room connection status is independent of the lobby connection status, however the lobby system will attempt to keep /// them consistent, automatically connecting to the RTC room after joining a lobby which has an associated RTC room and disconnecting /// from the RTC room when a lobby is left or disconnected. /// /// This function will only succeed when called on a lobby the local user is currently a member of. /// /// /// Structure containing information about the lobby to query the RTC Room connection status for /// If the result is , this will be set to true if we are connected, or false if we are not yet connected. /// /// if we are connected to the specified lobby, the input options and parameters were valid and we were able to write to bOutIsConnected successfully. /// if the lobby doesn't exist /// if the lobby exists, but did not have the RTC Room feature enabled when created /// if bOutIsConnected is NULL, or any other parameters are NULL or invalid /// public Result IsRTCRoomConnected(IsRTCRoomConnectedOptions options, out bool bOutIsConnected) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); int bOutIsConnectedInt = 0; var funcResult = Bindings.EOS_Lobby_IsRTCRoomConnected(InnerHandle, optionsAddress, ref bOutIsConnectedInt); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryMarshalGet(bOutIsConnectedInt, out bOutIsConnected); return funcResult; } /// /// Join a lobby, creating a local instance under a given lobby ID. Backend will validate various conditions to make sure it is possible to join the lobby. /// /// If the lobby is successfully join has an RTC Room enabled, the lobby system will automatically join and maintain the connection to the RTC room as long as the /// local user remains in the lobby. Applications can use the to get the name of the RTC Room associated with a lobby, which may be used with /// suite of functions. This can be useful to: register for notifications for talking status; to mute or unmute the local user's audio output; /// to block or unblock room participants; to set local audio device settings; and more. /// /// Structure containing information about the lobby to be joined /// Arbitrary data that is passed back to you in the CompletionDelegate /// A callback that is fired when the join operation completes, either successfully or in error /// /// if the destroy completes successfully /// if any of the options are incorrect /// public void JoinLobby(JoinLobbyOptions options, object clientData, OnJoinLobbyCallback completionDelegate) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var completionDelegateInternal = new OnJoinLobbyCallbackInternal(OnJoinLobbyCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, completionDelegate, completionDelegateInternal); Bindings.EOS_Lobby_JoinLobby(InnerHandle, optionsAddress, clientDataAddress, completionDelegateInternal); Helper.TryMarshalDispose(ref optionsAddress); } /// /// Kick an existing member from the lobby /// /// Structure containing information about the lobby and member to be kicked /// Arbitrary data that is passed back to you in the CompletionDelegate /// A callback that is fired when the kick operation completes, either successfully or in error /// /// if the kick completes successfully /// if any of the options are incorrect /// if the calling user is not the owner of the lobby /// if a lobby of interest does not exist /// public void KickMember(KickMemberOptions options, object clientData, OnKickMemberCallback completionDelegate) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var completionDelegateInternal = new OnKickMemberCallbackInternal(OnKickMemberCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, completionDelegate, completionDelegateInternal); Bindings.EOS_Lobby_KickMember(InnerHandle, optionsAddress, clientDataAddress, completionDelegateInternal); Helper.TryMarshalDispose(ref optionsAddress); } /// /// Leave a lobby given a lobby ID /// /// If the lobby you are leaving had an RTC Room enabled, leaving the lobby will also automatically leave the RTC room. /// /// Structure containing information about the lobby to be left /// Arbitrary data that is passed back to you in the CompletionDelegate /// A callback that is fired when the leave operation completes, either successfully or in error /// /// if the leave completes successfully /// if any of the options are incorrect /// if the lobby is already marked for leave /// if a lobby to be left does not exist /// public void LeaveLobby(LeaveLobbyOptions options, object clientData, OnLeaveLobbyCallback completionDelegate) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var completionDelegateInternal = new OnLeaveLobbyCallbackInternal(OnLeaveLobbyCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, completionDelegate, completionDelegateInternal); Bindings.EOS_Lobby_LeaveLobby(InnerHandle, optionsAddress, clientDataAddress, completionDelegateInternal); Helper.TryMarshalDispose(ref optionsAddress); } /// /// Promote an existing member of the lobby to owner, allowing them to make lobby data modifications /// /// Structure containing information about the lobby and member to be promoted /// Arbitrary data that is passed back to you in the CompletionDelegate /// A callback that is fired when the promotion operation completes, either successfully or in error /// /// if the promote completes successfully /// if any of the options are incorrect /// if the calling user is not the owner of the lobby /// if the lobby of interest does not exist /// public void PromoteMember(PromoteMemberOptions options, object clientData, OnPromoteMemberCallback completionDelegate) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var completionDelegateInternal = new OnPromoteMemberCallbackInternal(OnPromoteMemberCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, completionDelegate, completionDelegateInternal); Bindings.EOS_Lobby_PromoteMember(InnerHandle, optionsAddress, clientDataAddress, completionDelegateInternal); Helper.TryMarshalDispose(ref optionsAddress); } /// /// Retrieve all existing invites for a single user /// /// Structure containing information about the invites to query /// Arbitrary data that is passed back to you in the CompletionDelegate /// A callback that is fired when the query invites operation completes, either successfully or in error public void QueryInvites(QueryInvitesOptions options, object clientData, OnQueryInvitesCallback completionDelegate) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var completionDelegateInternal = new OnQueryInvitesCallbackInternal(OnQueryInvitesCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, completionDelegate, completionDelegateInternal); Bindings.EOS_Lobby_QueryInvites(InnerHandle, optionsAddress, clientDataAddress, completionDelegateInternal); Helper.TryMarshalDispose(ref optionsAddress); } /// /// Reject an invite from another user. /// /// Structure containing information about the invite to reject /// Arbitrary data that is passed back to you in the CompletionDelegate /// A callback that is fired when the reject invite operation completes, either successfully or in error /// /// if the invite rejection completes successfully /// if any of the options are incorrect /// if the invite does not exist /// public void RejectInvite(RejectInviteOptions options, object clientData, OnRejectInviteCallback completionDelegate) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var completionDelegateInternal = new OnRejectInviteCallbackInternal(OnRejectInviteCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, completionDelegate, completionDelegateInternal); Bindings.EOS_Lobby_RejectInvite(InnerHandle, optionsAddress, clientDataAddress, completionDelegateInternal); Helper.TryMarshalDispose(ref optionsAddress); } /// /// Unregister from receiving notifications when a user accepts a lobby invitation via the overlay. /// /// Handle representing the registered callback public void RemoveNotifyJoinLobbyAccepted(ulong inId) { Helper.TryRemoveCallbackByNotificationId(inId); Bindings.EOS_Lobby_RemoveNotifyJoinLobbyAccepted(InnerHandle, inId); } /// /// Unregister from receiving notifications when a user accepts a lobby invitation via the overlay. /// /// Handle representing the registered callback public void RemoveNotifyLobbyInviteAccepted(ulong inId) { Helper.TryRemoveCallbackByNotificationId(inId); Bindings.EOS_Lobby_RemoveNotifyLobbyInviteAccepted(InnerHandle, inId); } /// /// Unregister from receiving notifications when a user receives a lobby invitation. /// /// Handle representing the registered callback public void RemoveNotifyLobbyInviteReceived(ulong inId) { Helper.TryRemoveCallbackByNotificationId(inId); Bindings.EOS_Lobby_RemoveNotifyLobbyInviteReceived(InnerHandle, inId); } /// /// Unregister from receiving notifications when lobby members status change. /// /// Handle representing the registered callback public void RemoveNotifyLobbyMemberStatusReceived(ulong inId) { Helper.TryRemoveCallbackByNotificationId(inId); Bindings.EOS_Lobby_RemoveNotifyLobbyMemberStatusReceived(InnerHandle, inId); } /// /// Unregister from receiving notifications when lobby members change their data. /// /// Handle representing the registered callback public void RemoveNotifyLobbyMemberUpdateReceived(ulong inId) { Helper.TryRemoveCallbackByNotificationId(inId); Bindings.EOS_Lobby_RemoveNotifyLobbyMemberUpdateReceived(InnerHandle, inId); } /// /// Unregister from receiving notifications when a lobby changes its data. /// /// Handle representing the registered callback public void RemoveNotifyLobbyUpdateReceived(ulong inId) { Helper.TryRemoveCallbackByNotificationId(inId); Bindings.EOS_Lobby_RemoveNotifyLobbyUpdateReceived(InnerHandle, inId); } /// /// Unregister from receiving notifications when an RTC Room's connection status changes. /// /// This should be called when the local user is leaving a lobby. /// /// /// Handle representing the registered callback public void RemoveNotifyRTCRoomConnectionChanged(ulong inId) { Helper.TryRemoveCallbackByNotificationId(inId); Bindings.EOS_Lobby_RemoveNotifyRTCRoomConnectionChanged(InnerHandle, inId); } /// /// Send an invite to another user. User must be a member of the lobby or else the call will fail /// /// Structure containing information about the lobby and user to invite /// Arbitrary data that is passed back to you in the CompletionDelegate /// A callback that is fired when the send invite operation completes, either successfully or in error /// /// if the send invite completes successfully /// if any of the options are incorrect /// if the lobby to send the invite from does not exist /// public void SendInvite(SendInviteOptions options, object clientData, OnSendInviteCallback completionDelegate) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var completionDelegateInternal = new OnSendInviteCallbackInternal(OnSendInviteCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, completionDelegate, completionDelegateInternal); Bindings.EOS_Lobby_SendInvite(InnerHandle, optionsAddress, clientDataAddress, completionDelegateInternal); Helper.TryMarshalDispose(ref optionsAddress); } /// /// Update a lobby given a lobby modification handle created by /// /// Structure containing information about the lobby to be updated /// Arbitrary data that is passed back to you in the CompletionDelegate /// A callback that is fired when the update operation completes, either successfully or in error /// /// if the update completes successfully /// if any of the options are incorrect /// if the lobby modification contains modifications that are only allowed by the owner /// if the lobby to update does not exist /// public void UpdateLobby(UpdateLobbyOptions options, object clientData, OnUpdateLobbyCallback completionDelegate) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var completionDelegateInternal = new OnUpdateLobbyCallbackInternal(OnUpdateLobbyCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, completionDelegate, completionDelegateInternal); Bindings.EOS_Lobby_UpdateLobby(InnerHandle, optionsAddress, clientDataAddress, completionDelegateInternal); Helper.TryMarshalDispose(ref optionsAddress); } /// /// Creates a lobby modification handle (). The lobby modification handle is used to modify an existing lobby and can be applied with . /// The must be released by calling once it is no longer needed. /// /// /// /// /// Required fields such as lobby ID /// Pointer to a Lobby Modification Handle only set if successful /// /// if we successfully created the Lobby Modification Handle pointed at in OutLobbyModificationHandle, or an error result if the input data was invalid /// if any of the options are incorrect /// public Result UpdateLobbyModification(UpdateLobbyModificationOptions options, out LobbyModification outLobbyModificationHandle) { var optionsAddress = System.IntPtr.Zero; Helper.TryMarshalSet(ref optionsAddress, options); var outLobbyModificationHandleAddress = System.IntPtr.Zero; var funcResult = Bindings.EOS_Lobby_UpdateLobbyModification(InnerHandle, optionsAddress, ref outLobbyModificationHandleAddress); Helper.TryMarshalDispose(ref optionsAddress); Helper.TryMarshalGet(outLobbyModificationHandleAddress, out outLobbyModificationHandle); return funcResult; } [MonoPInvokeCallback(typeof(OnCreateLobbyCallbackInternal))] internal static void OnCreateLobbyCallbackInternalImplementation(System.IntPtr data) { OnCreateLobbyCallback callback; CreateLobbyCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnDestroyLobbyCallbackInternal))] internal static void OnDestroyLobbyCallbackInternalImplementation(System.IntPtr data) { OnDestroyLobbyCallback callback; DestroyLobbyCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnJoinLobbyAcceptedCallbackInternal))] internal static void OnJoinLobbyAcceptedCallbackInternalImplementation(System.IntPtr data) { OnJoinLobbyAcceptedCallback callback; JoinLobbyAcceptedCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnJoinLobbyCallbackInternal))] internal static void OnJoinLobbyCallbackInternalImplementation(System.IntPtr data) { OnJoinLobbyCallback callback; JoinLobbyCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnKickMemberCallbackInternal))] internal static void OnKickMemberCallbackInternalImplementation(System.IntPtr data) { OnKickMemberCallback callback; KickMemberCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnLeaveLobbyCallbackInternal))] internal static void OnLeaveLobbyCallbackInternalImplementation(System.IntPtr data) { OnLeaveLobbyCallback callback; LeaveLobbyCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnLobbyInviteAcceptedCallbackInternal))] internal static void OnLobbyInviteAcceptedCallbackInternalImplementation(System.IntPtr data) { OnLobbyInviteAcceptedCallback callback; LobbyInviteAcceptedCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnLobbyInviteReceivedCallbackInternal))] internal static void OnLobbyInviteReceivedCallbackInternalImplementation(System.IntPtr data) { OnLobbyInviteReceivedCallback callback; LobbyInviteReceivedCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnLobbyMemberStatusReceivedCallbackInternal))] internal static void OnLobbyMemberStatusReceivedCallbackInternalImplementation(System.IntPtr data) { OnLobbyMemberStatusReceivedCallback callback; LobbyMemberStatusReceivedCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnLobbyMemberUpdateReceivedCallbackInternal))] internal static void OnLobbyMemberUpdateReceivedCallbackInternalImplementation(System.IntPtr data) { OnLobbyMemberUpdateReceivedCallback callback; LobbyMemberUpdateReceivedCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnLobbyUpdateReceivedCallbackInternal))] internal static void OnLobbyUpdateReceivedCallbackInternalImplementation(System.IntPtr data) { OnLobbyUpdateReceivedCallback callback; LobbyUpdateReceivedCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnPromoteMemberCallbackInternal))] internal static void OnPromoteMemberCallbackInternalImplementation(System.IntPtr data) { OnPromoteMemberCallback callback; PromoteMemberCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnQueryInvitesCallbackInternal))] internal static void OnQueryInvitesCallbackInternalImplementation(System.IntPtr data) { OnQueryInvitesCallback callback; QueryInvitesCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnRTCRoomConnectionChangedCallbackInternal))] internal static void OnRTCRoomConnectionChangedCallbackInternalImplementation(System.IntPtr data) { OnRTCRoomConnectionChangedCallback callback; RTCRoomConnectionChangedCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnRejectInviteCallbackInternal))] internal static void OnRejectInviteCallbackInternalImplementation(System.IntPtr data) { OnRejectInviteCallback callback; RejectInviteCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnSendInviteCallbackInternal))] internal static void OnSendInviteCallbackInternalImplementation(System.IntPtr data) { OnSendInviteCallback callback; SendInviteCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } [MonoPInvokeCallback(typeof(OnUpdateLobbyCallbackInternal))] internal static void OnUpdateLobbyCallbackInternalImplementation(System.IntPtr data) { OnUpdateLobbyCallback callback; UpdateLobbyCallbackInfo callbackInfo; if (Helper.TryGetAndRemoveCallback(data, out callback, out callbackInfo)) { callback(callbackInfo); } } } }