Version: 2023.2
public bool didStart ;

描述

Returns a boolean value which represents if Start was called.

using UnityEngine;

public class NewBehaviourScript : MonoBehaviour { void Awake() { // Awake gets called before Start, therefore will print 'false'. Debug.Log(this.didStart); }

void Start() { // Code is within Start, therefore will print 'true', as Start was called. Debug.Log(this.didStart); } }
Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961