Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Reduce the stun time in battles proportionally to the battle type.

  • Loading branch information...
commit 45ddff8f46441e7e61667089c25920642db7dc8d 1 parent 703f902
Yohann Ferreira authored
Showing with 8 additions and 0 deletions.
  1. +8 −0 src/modes/battle/battle_actors.cpp
View
8 src/modes/battle/battle_actors.cpp
@@ -217,6 +217,14 @@ void BattleActor::RegisterDamage(uint32 amount, BattleTarget* target) {
else // (damage_percent >= 0.50f)
stun_time = 1000;
+ // Make the stun effect disappear faster depending on the battle type,
+ // to not advantage the attacker.
+ BattleMode* BM = BattleMode::CurrentInstance();
+ if (BM->GetBattleType() == BATTLE_TYPE_SEMI_WAIT)
+ stun_time /= 1.5f;
+ else if (BM->GetBattleType() == BATTLE_TYPE_WAIT)
+ stun_time /= 3;
+
_state_timer.StunTimer(stun_time);
// Run a shake effect for the same time.
_shake_timer.Initialize(stun_time);
Please sign in to comment.
Something went wrong with that request. Please try again.