示例#1
0
    public void ReStartLight()
    {
        LightRecycleTime += Time.deltaTime;

        if (LightRecycleTime > 5f)
        {
            animatorPro.SetTrigger(ID_Light);
            LightRecycleTime = 0f;
        }
    }
示例#2
0
    private void Update()
    {
        //이동 애니메이션 재생
        var xx = Input.GetAxisRaw("Horizontal");

        animatorPro.SetParam(ID_Move, Mathf.Abs(xx));

        //공격 애니메이션 재생
        if (Input.GetKeyDown(KeyCode.Space))
        {
            animatorPro.SetTrigger("Attack");
        }

        #region Other - Horizontal Flip

        if (xx != 0.0f)
        {
            transform.localScale = new Vector3(-xx, 1, 1);
        }

        #endregion
    }