goto的用法

using UnityEngine;
using System.Collections;

public class goto1 : MonoBehaviour {
	public bool can = false;
	// Use this for initialization
	void Start () {
		if(can == true){
			goto Exit0;
		}
		Debug.Log("11111");

	Exit0:
		Debug.Log("sadfsd");
	}
	
	// Update is called once per frame
	void Update () {
	
	}
}
原文地址:https://www.cnblogs.com/softimagewht/p/3831439.html