盾牌的耐用度

Revision as of 04:10, 30 May 2020 by Simple (talk | contribs) (Created page with "* <code>damageRatio</code> (攻換防比)是從 GlobalParameter 裡來的("Global" 底下的 "ShieldDamageRatio")。 * <code>attackPower</code> 是被抵擋的攻...")
Other languages:


盾牌的耐用度会随着玩家抵挡怪物的攻击与盾牌滑行逐渐降低。

抵挡攻击

The logic is as follows[1]:

float damageRatio = GlobalParameter::sInstance->globalParam->shieldDamageRatio.value();
int damage = damageRatio * (param->attackPower - guardPower - additionalGuardPower);
if (param->forceOnlyOneDamage)
  minDamage = 1;
else
  minDamage = param->minDmg;
weapon->takeDamage(max(damage, minDamage));
  • damageRatio (攻换防比)是从 GlobalParameter 里来的("Global" 底下的 "ShieldDamageRatio")。
  • attackPower 是被抵挡的攻击的攻击力。
  • guardPower是盾牌的防御力,也是 bgparamlist 来的("WeaponCommon" 底下的 "GuardPower").
  • additionalGuardPower 就是防御力加成加多少(没有加成则是零)。

minDmg appears to be 1 in most cases.

In 1.6.0, ShieldDamageRatio is 0.2, meaning a shield takes a minimum of 1 damage point (in most cases), and 1 damage point for every 5 points of difference between the attack power and the guard power. [2]

Shield surfing

Here is a gist of the logic[3]:

  • Whenever Link is shield surfing, a timer (which is tied to the shield) is incremented.
  • If Link is surfing on a "no shield damage floor", or if the L2 norm of his velocity is lower than 0.03, then the shield takes no damage.
  • Otherwise, every time the timer reaches ShieldRideBaseFrame (as configured in GlobalParameter), the shield takes RideBreakRatio * ShieldRideHitBaseDamage * Damage and the timer is reset.

In 1.6.0:

  • RideBreakRatio is 1.0 for the majority of shields, and 0.2 for the Ancient Shield, which means that the latter takes shield surfing damage at a 20% rate compared to most other shields. Refer to this spreadsheet for more information on shield stats, including the hidden RideBreakRatio.
  • ShieldRideBaseFrame is 120[4] and ShieldRideHitBaseDamage is 1[5]. This means that shield surfing costs RideBreakRatio * 1 durability points every 4 seconds.
  • This damage is also applied when you start surfing.

Since the timer is tied to the shield instance, switching to another shield will reset the timer and doing so lets the player avoid taking any surf damage.


References