aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/game/Unit.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp
index 0b48251dbca..bdb99cef05a 100644
--- a/src/game/Unit.cpp
+++ b/src/game/Unit.cpp
@@ -10219,7 +10219,9 @@ void Unit::UpdateSpeed(UnitMoveType mtype, bool forced)
stack_bonus = GetTotalAuraMultiplier(SPELL_AURA_MOD_VEHICLE_SPEED_ALWAYS);
// for some spells this mod is applied on vehicle owner
- if (Unit * owner = (Vehicle*)this)->GetOwner())
+ uint32 owner_speed_mod = 0;
+
+ if (Unit * owner = ((Vehicle*)this)->GetCharmer())
uint32 owner_speed_mod = owner->GetMaxPositiveAuraModifier(SPELL_AURA_MOD_INCREASE_VEHICLE_FLIGHT_SPEED);
main_speed_mod = main_speed_mod>owner_speed_mod ? main_speed_mod : owner_speed_mod;