diff options
author | Anubisss <none@none> | 2010-02-18 21:17:19 +0100 |
---|---|---|
committer | Anubisss <none@none> | 2010-02-18 21:17:19 +0100 |
commit | 43a6be4b10da0c5e1e45e97d1130af3b93afaa71 (patch) | |
tree | d267495895e147658a9d90b9b517cc78fd3316e1 | |
parent | cedf706f29fa4fdaccd9d12ee88ac47e6b4a4f16 (diff) |
Fix a crash in generic_vehicleAI_toc5AI.
gdb log:
#3 0x0000000000ce25c9 in Vehicle::GetPassenger (this=0x0, seatId=0 '\0')
#4 0x0000000000f10820 in generic_vehicleAI_toc5AI::UpdateAI (
this=0x7f1c123c3000, uiDiff=118)
--HG--
branch : trunk
-rw-r--r-- | src/scripts/northrend/crusaders_coliseum/trial_of_the_champion/boss_grand_champions.cpp | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/scripts/northrend/crusaders_coliseum/trial_of_the_champion/boss_grand_champions.cpp b/src/scripts/northrend/crusaders_coliseum/trial_of_the_champion/boss_grand_champions.cpp index 9d745c8775a..6fc53263ed1 100644 --- a/src/scripts/northrend/crusaders_coliseum/trial_of_the_champion/boss_grand_champions.cpp +++ b/src/scripts/northrend/crusaders_coliseum/trial_of_the_champion/boss_grand_champions.cpp @@ -261,6 +261,12 @@ struct generic_vehicleAI_toc5AI : public npc_escortAI //dosen't work at all if (uiShieldBreakerTimer <= uiDiff) { + if (!pVehicle) + { + pVehicle = m_creature->GetVehicleKit(); + return; + } + if (Unit* pPassenger = pVehicle->GetPassenger(SEAT_ID_0)) { Map::PlayerList const& players = m_creature->GetMap()->GetPlayers(); |