void CheckSpellsDash() { if (Application.platform == RuntimePlatform.WindowsPlayer || Application.platform == RuntimePlatform.LinuxPlayer || Application.platform == RuntimePlatform.WindowsEditor || Application.platform == RuntimePlatform.LinuxEditor) { if (Input.GetKeyDown(KeyCode.LeftShift) && canDash) { Debug.Log("isDashing"); Dash(); StartCoroutine(PcCooldownDash(dashCooldown)); } } else { if (buttonDash.isPressed()) { Dash(); } } }
/// <summary> /// Checa se algum botão de feitiço foi pressionado /// </summary> void CheckSpellsFireball() { if (Application.platform == RuntimePlatform.WindowsPlayer || Application.platform == RuntimePlatform.LinuxPlayer || Application.platform == RuntimePlatform.WindowsEditor || Application.platform == RuntimePlatform.LinuxEditor) { if (Input.GetMouseButtonUp(0) && canFire) { CmdCastFireball(); StartCoroutine(PcCooldownFireball(fireballCooldown)); } } else { if (buttonFireball.isPressed()) { CmdCastFireball(); } } }