Ejemplo n.º 1
0
    void Start()
    {
        movie = GetComponent <VideoPlayer>();
        movie.Play();
        movie.Pause();
        startPlay = false;

        stageStateMachine = GameObject.Find("StageStateMachine").GetComponent <StageSequenceMachine>();
    }
Ejemplo n.º 2
0
    public StageSequenceState()
    {
        player             = GameObject.FindGameObjectWithTag("Player");
        animator           = player.GetComponent <Animator>();
        stateMachine       = GameObject.Find("StageStateMachine").GetComponent <StageSequenceMachine>();
        playerStateMachine = player.GetComponent <PlayerStateMachine>();

        enterPosition = GameObject.Find("EnterPosition").transform.position;
        startPosition = GameObject.Find("StartPosition").transform.position;
        goalPosition  = GameObject.Find("GoalPosition").transform.position;
        exitPosition  = GameObject.Find("ExitPosition").transform.position;

        //y軸はプレイヤーに合わせる
        enterPosition.y = player.transform.position.y;
        startPosition.y = player.transform.position.y;
        startPosition.y = player.transform.position.y;

        deadTimes = 0;
    }