diff options
| author | Trista <aconstantgoal@abv.bg> | 2012-12-27 01:28:23 +0200 |
|---|---|---|
| committer | Trista <aconstantgoal@abv.bg> | 2012-12-27 01:35:38 +0200 |
| commit | 452e585f7b4b2bc349d7386b0c42cf296f0ab4c2 (patch) | |
| tree | b82146c1756e5899f49e9bb7eb7cf4609ce96f12 /src/server/game/Entities/Unit | |
| parent | fd25bdd4b63adb2b72587dfae48b256a51c638d8 (diff) | |
Core/Vehicles: Fixed seat id for auras with SPELL_AURA_CONTROL_VEHICLE. Also always allow npc passengers to cast spells and remove TRIGGERED_IGNORE_CASTER_MOUNTED_OR_ON_VEHICLE hacks.
* Author: Horn. Please give feedback, I tested a lot stuff, but it will be appreciated.
* One of the fixes allow all creatures to cast when being passangers, researched, this doesn't involve players.
* This basically rewrittes vehicle seat formula calculated, so it fix quite stuff that will not be visible and some eye candies: #3831 and #1984 Heart part ;) (which magically fix a lot more of it and some quests), also Yog-Sarron mechanics
Diffstat (limited to 'src/server/game/Entities/Unit')
| -rw-r--r-- | src/server/game/Entities/Unit/Unit.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 1c2f03ec5b9..62df8c2049c 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -17064,7 +17064,7 @@ bool Unit::HandleSpellClick(Unit* clicker, int8 seatId) } if (IsInMap(caster)) - caster->CastCustomSpell(itr->second.spellId, SpellValueMod(SPELLVALUE_BASE_POINT0+i), seatId+1, target, GetVehicleKit() ? TRIGGERED_IGNORE_CASTER_MOUNTED_OR_ON_VEHICLE : TRIGGERED_NONE, NULL, NULL, origCasterGUID); + caster->CastCustomSpell(itr->second.spellId, SpellValueMod(SPELLVALUE_BASE_POINT0+i), seatId, target, GetVehicleKit() ? TRIGGERED_IGNORE_CASTER_MOUNTED_OR_ON_VEHICLE : TRIGGERED_NONE, NULL, NULL, origCasterGUID); else // This can happen during Player::_LoadAuras { int32 bp0 = seatId; @@ -17094,7 +17094,7 @@ bool Unit::HandleSpellClick(Unit* clicker, int8 seatId) void Unit::EnterVehicle(Unit* base, int8 seatId) { - CastCustomSpell(VEHICLE_SPELL_RIDE_HARDCODED, SPELLVALUE_BASE_POINT0, seatId+1, base, TRIGGERED_IGNORE_CASTER_MOUNTED_OR_ON_VEHICLE); + CastCustomSpell(VEHICLE_SPELL_RIDE_HARDCODED, SPELLVALUE_BASE_POINT0, seatId, base, TRIGGERED_IGNORE_CASTER_MOUNTED_OR_ON_VEHICLE); } void Unit::_EnterVehicle(Vehicle* vehicle, int8 seatId, AuraApplication const* aurApp) |
