void OnDestroy() { if (_Instance == this) { // shutdown plugins EtceteraWrapper.Done(); TapJoy.Done(); TwitterWrapper.Done(); #if UNITY_ANDROID && !UNITY_EDITOR MogaGamepad.Done(); MogaGamepad.OnConnectionChange -= OnMogaConnectionChange; MogaGamepad.OnBatteryLowChange = null; #endif GamepadInputManager.DestroyInstance(); CloudUser.authenticationChanged -= OnUserAuthenticationChanged; OnUserAuthenticationChanged(false); //FacebookPlugin.Instance.OnApplicationFocus -= OnApplicationPause; kua ja to nemuzu delat ;) } }