public void Set(SetPresenceOptions other) { if (other != null) { m_ApiVersion = PresenceInterface.SetpresenceApiLatest; LocalUserId = other.LocalUserId; PresenceModificationHandle = other.PresenceModificationHandle; } }
/// <summary> /// Sets your new presence with the data applied to a PresenceModificationHandle. The PresenceModificationHandle can be released safely after calling this function. /// <seealso cref="CreatePresenceModification" /> /// <seealso cref="PresenceModification.Release" /> /// </summary> /// <param name="options">Object containing a PresenceModificationHandle and associated user data</param> /// <param name="clientData">Optional pointer to help track this request, that is returned in the completion callback</param> /// <param name="completionDelegate">Pointer to a function that handles receiving the completion information</param> public void SetPresence(SetPresenceOptions options, object clientData, SetPresenceCompleteCallback completionDelegate) { System.IntPtr optionsAddress = new System.IntPtr(); Helper.TryMarshalSet <SetPresenceOptionsInternal, SetPresenceOptions>(ref optionsAddress, options); var clientDataAddress = System.IntPtr.Zero; var completionDelegateInternal = new SetPresenceCompleteCallbackInternal(SetPresenceCompleteCallbackInternalImplementation); Helper.AddCallback(ref clientDataAddress, clientData, completionDelegate, completionDelegateInternal); EOS_Presence_SetPresence(InnerHandle, optionsAddress, clientDataAddress, completionDelegateInternal); Helper.TryMarshalDispose(ref optionsAddress); }