private void Awake() { if (instance == null) { instance = this; } }
// Update is called once per frame void Update() { if (trashApplied) { TrashMountain.DestroyTrash(gameObject); Destroy(gameObject); } }
// Use this for initialization void Start() { spawnTime = Time.timeSinceLevelLoad; trashMountain = TrashMountain.GetInstance(); facing = transform.rotation; }