using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class ccc : MonoBehaviour {
void Start () {
StartCoroutine( killMe() );
}
void Update () {
Debug.Log("UPDATE");
}
private IEnumerator killMe()
{
yield return new WaitForSeconds(5);
Debug.Log("KILL");
Destroy(gameObject);
}
}