Beispiel #1
0
    protected override void Awake()
    {
        base.Awake();
        //先读取翻译文件
        if (!canContinue)
        {
            return;
        }
        LanguageControl.LoadLanguage();

        Object.DontDestroyOnLoad(this.gameObject);
        RegisterController(Const.E_StartUp, typeof(StartUpCommand));
        SendEvent(Const.E_StartUp);
        SceneManager.sceneLoaded += LevelLoaded;

        SceneArgs e = new SceneArgs();

        e.sceneIndex = SceneManager.GetActiveScene().buildIndex;
        SendEvent(Const.E_EnterScene, e);
    }