using UnityEngine; namespace Passer { /// /// Destroyer of things /// /// public class Destroyer : MonoBehaviour { /// /// Destroy this GameObject /// public void SelfDestroy() { Object.Destroy(this.gameObject); } /// /// Destroy the given GameObject /// /// The GameObject to Destroy public void Destroy(GameObject gameObject) { Object.Destroy(gameObject); } /// /// Exit the application /// public void ApplicationQuit() { #if UNITY_EDITOR UnityEditor.EditorApplication.isPlaying = false; #else Application.Quit(); #endif } } }