public bool RemoveUpdateStatusListener(GamebaseCallback.DataDelegate <GamebaseResponse.Launching.LaunchingStatus> statusDelegate) { launchingStatusDelegate -= statusDelegate; if (launchingStatusDelegate == null) { launching.RemoveUpdateStatusListener(launchingStatusHandle); GamebaseCallbackHandler.UnregisterCallback(launchingStatusHandle); launchingStatusHandle = 0; } return(true); }
public bool RemoveOnChangedStatusListener(GamebaseCallback.DataDelegate <GamebaseNetworkType> stateDelegate) { networkStateDelegate -= stateDelegate; if (networkStateDelegate == null) { network.RemoveOnChangedStatusListener(); GamebaseCallbackHandler.UnregisterCallback(networkStateHandle); networkStateHandle = 0; } return(true); }
public bool AddOnChangedStatusListener(GamebaseCallback.DataDelegate <GamebaseNetworkType> stateDelegate) { if (networkStateDelegate == null) { networkStateHandle = GamebaseCallbackHandler.RegisterCallback(new GamebaseCallback.DataDelegate <GamebaseNetworkType>(OnChangedStatus)); if (!network.AddOnChangedStatusListener(networkStateHandle)) { GamebaseCallbackHandler.UnregisterCallback(networkStateHandle); return(false); } } networkStateDelegate += stateDelegate; return(true); }
public bool AddUpdateStatusListener(GamebaseCallback.DataDelegate <GamebaseResponse.Launching.LaunchingStatus> statusDelegate) { if (launchingStatusDelegate == null) { launchingStatusHandle = GamebaseCallbackHandler.RegisterCallback(new GamebaseCallback.DataDelegate <GamebaseResponse.Launching.LaunchingStatus>(OnLaunchingStatus)); if (!launching.AddUpdateStatusListener(launchingStatusHandle)) { GamebaseCallbackHandler.UnregisterCallback(launchingStatusHandle); return(false); } } launchingStatusDelegate += statusDelegate; return(true); }