void Update() { if (Input.GetButtonDown("Dash")) { if (pStats.stamina > dashStaminaUse) { pStats.ModStamina(-dashStaminaUse); pFunc.InitDash(); } } if (Input.GetMouseButtonDown(0)) { if (pAttack.canAttack() && (pStats.stamina > attackStaminaUse)) { pAttack.initAttack(); pStats.ModStamina(-attackStaminaUse); pVisuals.attackUpdate(pAttack.attackBox, pAttack); } } if (Input.GetMouseButtonDown(1)) { if (pAttack.canAttack() && !pPSystem.parrying && pPSystem.CanParry()) { if (pStats.stamina > parryStaminaUse) { pPSystem.DoParry(); pStats.ModStamina(-parryStaminaUse); } } } }
void Update() { if (Input.GetButtonDown("Dash")) { if (pStats.stamina > dashStaminaUse) { pStats.ModStamina(-dashStaminaUse); pFunc.InitDash(); } } }