Exemple #1
0
    // Update is called once per frame
    void Update()
    {
        if (Input.GetKeyDown(KeyCode.E))
        {
            SliceAttack();
        }

        if (sliceTimer <= 0)
        {
            animator.SetBool("Sliceing", false);
            //animator.applyRootMotion = false;
            weaponHandler.EndAttack();
        }
        sliceTimer -= Time.deltaTime;
    }
Exemple #2
0
    // Update is called once per frame
    void Update()
    {
        if (Input.GetKeyDown(KeyCode.E))
        {
            SliceAttack();
        }

        if (sliceTimer <= 0)
        {
            animator.SetBool("Sliceing", false);
            weaponHandler.EndAttack();
        }
        sliceTimer -= Time.deltaTime;
        if (Player.expPoints >= expForNextLvl)
        {
            PlayerLevelUp();
        }
    }