Esempio n. 1
0
    public void Start()
    {
        if (isTransitionScene)
        {
            return;
        }

        playerObject = GameObject.FindGameObjectWithTag("Player");
        PlayerControl  playerControl  = playerObject.GetComponent <PlayerControl>();
        ScreenFade     screenFade     = GameObject.FindObjectOfType <ScreenFade>();
        CameraRotation cameraRotation = GameObject.FindObjectOfType <CameraRotation>();

        OnOutOfBounds.AddListener(screenFade.StartFadingProcess);
        OnOutOfBounds.AddListener(playerControl.SwitchToResetStart);
        OnOutOfBounds.AddListener(this.SwitchResetStateToLaunch);
        OnOutOfBounds.AddListener(cameraRotation.GetResetStart());
    }