DestroyDelay 协同法

作者:雨辰 发布于:2017-2-17 14:06 Friday 分类:Unity3D

using UnityEngine;
using System.Collections;

public class Ef_DestroyDelay : MonoBehaviour {
    public float delay = 1F;
	// Use this for initialization
	IEnumerator Start () {
        yield return new WaitForSeconds(delay);
        Destroy(gameObject);
	}

}

标签: Unity3D

发表评论:

雨辰 joyimp|@2011-2017 京ICP备16030765号