void Update() { screenSize.x = Screen.width; screenSize.y = Screen.height; if (this.lastScreenSize != screenSize) { pixelPerfectCamera.refResolutionX = screenSize.x; pixelPerfectCamera.refResolutionY = screenSize.y; pixelPerfectCamera.assetsPPU = (int)(((float)screenSize.y / y) * ratio); this.lastScreenSize = screenSize; } //if (riloo.RewiredInputModule.GetButton(1, RewiredConsts.Action.Game_Attack_1) && // riloo.RewiredInputModule.GetButtonDown(1, RewiredConsts.Action.Game_Attack_2)) if (Input.GetKeyDown(KeyCode.L)) { SceneLoaderScript.LoadScene(2, OnDone, true); } }
private void LoadScene() { EventSystem.current.SetSelectedGameObject(null); SceneLoaderScript.LoadScene(SceneIndex, OnDone); }
private void Start() { Time.timeScale = 0f; SceneLoaderScript.LoadScene(1, OnLoadIsDone); }