aboutsummaryrefslogtreecommitdiff
path: root/src/bindings/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'src/bindings/scripts')
-rw-r--r--src/bindings/scripts/CMakeLists.txt124
-rw-r--r--src/bindings/scripts/Makefile.am445
-rw-r--r--src/bindings/scripts/ScriptMgr.cpp623
-rw-r--r--src/bindings/scripts/ScriptMgr.h16
-rw-r--r--src/bindings/scripts/VC71/71ScriptDev2.vcproj288
-rw-r--r--src/bindings/scripts/VC80/80ScriptDev2.vcproj296
-rw-r--r--src/bindings/scripts/VC90/90ScriptDev2.vcproj529
-rw-r--r--src/bindings/scripts/docs/EventAI.txt185
-rw-r--r--src/bindings/scripts/docs/Text-tables.txt6
-rw-r--r--src/bindings/scripts/include/precompiled.cpp2
-rw-r--r--src/bindings/scripts/include/precompiled.h3
-rw-r--r--src/bindings/scripts/include/sc_creature.cpp111
-rw-r--r--src/bindings/scripts/include/sc_creature.h17
-rw-r--r--src/bindings/scripts/include/sc_gossip.h53
-rw-r--r--src/bindings/scripts/include/sc_instance.h2
-rw-r--r--src/bindings/scripts/scripts/areatrigger/areatrigger_scripts.cpp14
-rw-r--r--src/bindings/scripts/scripts/boss/boss_emeriss.cpp2
-rw-r--r--src/bindings/scripts/scripts/boss/boss_lethon.cpp2
-rw-r--r--src/bindings/scripts/scripts/boss/boss_taerar.cpp2
-rw-r--r--src/bindings/scripts/scripts/boss/boss_ysondre.cpp2
-rw-r--r--src/bindings/scripts/scripts/creature/mob_event_ai.cpp1445
-rw-r--r--src/bindings/scripts/scripts/creature/mob_generic_creature.cpp2
-rw-r--r--src/bindings/scripts/scripts/creature/simple_ai.cpp55
-rw-r--r--src/bindings/scripts/scripts/creature/simple_ai.h14
-rw-r--r--src/bindings/scripts/scripts/custom/npc_acherus_taxi.cpp39
-rw-r--r--src/bindings/scripts/scripts/custom/npc_wyrmresttempel_taxi.cpp116
-rw-r--r--src/bindings/scripts/scripts/examples/example_creature.cpp258
-rw-r--r--src/bindings/scripts/scripts/examples/example_escort.cpp220
-rw-r--r--src/bindings/scripts/scripts/examples/example_gossip_codebox.cpp88
-rw-r--r--src/bindings/scripts/scripts/examples/example_misc.cpp65
-rw-r--r--src/bindings/scripts/scripts/go/go_scripts.cpp68
-rw-r--r--src/bindings/scripts/scripts/guard/guard_ai.cpp18
-rw-r--r--src/bindings/scripts/scripts/guard/guard_ai.h2
-rw-r--r--src/bindings/scripts/scripts/guard/guards.cpp886
-rw-r--r--src/bindings/scripts/scripts/item/item_scripts.cpp4
-rw-r--r--src/bindings/scripts/scripts/npc/npc_escortAI.cpp38
-rw-r--r--src/bindings/scripts/scripts/npc/npc_escortAI.h6
-rw-r--r--src/bindings/scripts/scripts/npc/npc_innkeeper.cpp6
-rw-r--r--src/bindings/scripts/scripts/npc/npc_professions.cpp4
-rw-r--r--src/bindings/scripts/scripts/npc/npcs_special.cpp645
-rw-r--r--src/bindings/scripts/scripts/zone/alterac_mountains/alterac_mountains.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/arathi_highlands/arathi_highlands.cpp24
-rw-r--r--src/bindings/scripts/scripts/zone/ashenvale_forest/ashenvale.cpp58
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/auchenai_crypts/boss_exarch_maladaar.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/auchenai_crypts/boss_shirrak_the_dead_watcher.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/mana_tombs/boss_nexusprince_shaffar.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/mana_tombs/boss_pandemonius.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/boss_darkweaver_syth.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/boss_tailonking_ikiss.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/def_sethekk_halls.h2
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/instance_sethekk_halls.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_ambassador_hellmaw.cpp16
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_blackheart_the_inciter.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_grandmaster_vorpil.cpp16
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_murmur.cpp42
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/def_shadow_labyrinth.h2
-rw-r--r--src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/instance_shadow_labyrinth.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_amanitar.cpp79
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_elder_nadox.cpp117
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_herald_volazj.cpp111
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_jedoga_shadowseeker.cpp109
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_prince_taldaram.cpp109
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/def_ahnkahet.h33
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/instance_ahnkahet.cpp194
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_anubarak.cpp112
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_hadronox.cpp114
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_krikthir_the_gatewatcher.cpp116
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/def_azjol_nerub.h29
-rw-r--r--src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/instance_azjol_nerub.cpp180
-rw-r--r--src/bindings/scripts/scripts/zone/azshara/azshara.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/azshara/boss_azuregos.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/azuremyst_isle/azuremyst_isle.cpp263
-rw-r--r--src/bindings/scripts/scripts/zone/barrens/the_barrens.cpp77
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/.boss_teron_gorefiend.cpp-woains536
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/.instance_black_temple.cpp-s8inyu347
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/black_temple.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/boss_bloodboil.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/boss_illidan.cpp81
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/boss_mother_shahraz.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/boss_reliquary_of_souls.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/boss_shade_of_akama.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/boss_supremus.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/boss_teron_gorefiend.cpp8
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/boss_warlord_najentus.cpp10
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/def_black_temple.h2
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/illidari_council.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/black_temple/instance_black_temple.cpp10
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_depths/blackrock_depths.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_depths/boss_ambassador_flamelash.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_depths/boss_anubshiah.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_depths/boss_emperor_dagran_thaurissan.cpp18
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_depths/boss_general_angerforge.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_depths/boss_gorosh_the_dervish.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_depths/boss_grizzle.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_depths/boss_high_interrogator_gerstahn.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_depths/boss_magmus.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_depths/boss_moira_bronzebeard.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_depths/instance_blackrock_depths.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_drakkisath.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_gyth.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_halycon.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_highlord_omokk.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_mother_smolderweb.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_overlord_wyrmthalak.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_pyroguard_emberseer.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_quartermaster_zigris.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_rend_blackhand.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_shadow_hunter_voshgajin.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_the_beast.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackrock_spire/boss_warmaster_voone.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackwing_lair/boss_broodlord_lashlayer.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackwing_lair/boss_chromaggus.cpp12
-rw-r--r--src/bindings/scripts/scripts/zone/blackwing_lair/boss_ebonroc.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/blackwing_lair/boss_firemaw.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackwing_lair/boss_flamegor.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackwing_lair/boss_nefarian.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackwing_lair/boss_razorgore.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/blackwing_lair/boss_vaelastrasz.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackwing_lair/boss_victor_nefarius.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blackwing_lair/instance_blackwing_lair.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blades_edge_mountains/blades_edge_mountains.cpp279
-rw-r--r--src/bindings/scripts/scripts/zone/blasted_lands/blasted_lands.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/blasted_lands/boss_kruul.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/bloodmyst_isle/bloodmyst_isle.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/borean_tundra/borean_tundra.cpp105
-rw-r--r--src/bindings/scripts/scripts/zone/burning_steppes/burning_steppes.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_epoch.cpp86
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_mal_ganis.cpp123
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_meathook.cpp138
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_salramm.cpp152
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/def_culling_of_stratholme.h4
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/instance_culling_of_stratholme.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_aeonus.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_chrono_lord_deja.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_temporus.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/dark_portal.cpp27
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/def_dark_portal.h2
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/instance_dark_portal.cpp31
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/boss_archimonde.cpp388
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/def_hyjal.h2
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjal.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.cpp17
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.h2
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/instance_hyjal.cpp43
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_captain_skarloc.cpp10
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_epoch_hunter.cpp10
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_leutenant_drake.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/def_old_hillsbrad.h2
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/instance_old_hillsbrad.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/old_hillsbrad.cpp31
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_fathomlord_karathress.cpp14
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_hydross_the_unstable.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lady_vashj.cpp24
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_leotheras_the_blind.cpp44
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lurker_below.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_morogrim_tidewalker.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/def_serpent_shrine.h2
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/instance_serpent_shrine.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_hydromancer_thespia.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_mekgineer_steamrigger.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_warlord_kalithresh.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/def_steam_vault.h2
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/instance_steam_vault.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/underbog/boss_hungarfen.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/coilfang_resevoir/underbog/boss_the_black_stalker.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/darkshore/darkshore.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/deadmines/deadmines.cpp10
-rw-r--r--src/bindings/scripts/scripts/zone/draktharon_keep/boss_dred.cpp56
-rw-r--r--src/bindings/scripts/scripts/zone/draktharon_keep/boss_novos.cpp75
-rw-r--r--src/bindings/scripts/scripts/zone/draktharon_keep/boss_tharon_ja.cpp88
-rw-r--r--src/bindings/scripts/scripts/zone/draktharon_keep/boss_trollgore.cpp75
-rw-r--r--src/bindings/scripts/scripts/zone/draktharon_keep/def_drak_tharon_keep.h4
-rw-r--r--src/bindings/scripts/scripts/zone/draktharon_keep/instance_drak_tharon_keep.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/dun_morogh/dun_morogh.cpp8
-rw-r--r--src/bindings/scripts/scripts/zone/dustwallow_marsh/dustwallow_marsh.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/eastern_plaguelands/eastern_plaguelands.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/elwynn_forest/elwynn_forest.cpp8
-rw-r--r--src/bindings/scripts/scripts/zone/eversong_woods/eversong_woods.cpp54
-rw-r--r--src/bindings/scripts/scripts/zone/felwood/felwood.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/feralas/feralas.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/ghostlands/ghostlands.cpp64
-rw-r--r--src/bindings/scripts/scripts/zone/gruuls_lair/boss_gruul.cpp97
-rw-r--r--src/bindings/scripts/scripts/zone/gruuls_lair/boss_high_king_maulgar.cpp41
-rw-r--r--src/bindings/scripts/scripts/zone/gruuls_lair/def_gruuls_lair.h24
-rw-r--r--src/bindings/scripts/scripts/zone/gruuls_lair/instance_gruuls_lair.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/gundrak/boss_drakkari_colossus.cpp55
-rw-r--r--src/bindings/scripts/scripts/zone/gundrak/boss_eck.cpp65
-rw-r--r--src/bindings/scripts/scripts/zone/gundrak/boss_gal_darah.cpp85
-rw-r--r--src/bindings/scripts/scripts/zone/gundrak/boss_moorabi.cpp88
-rw-r--r--src/bindings/scripts/scripts/zone/gundrak/boss_slad_ran.cpp95
-rw-r--r--src/bindings/scripts/scripts/zone/gundrak/def_gundrak.h4
-rw-r--r--src/bindings/scripts/scripts/zone/gundrak/instance_gundrak.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_broggok.cpp54
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_kelidan_the_breaker.cpp22
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_the_maker.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/hellfire_ramparts/boss_omor_the_unscarred.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/hellfire_ramparts/boss_watchkeeper_gargolmar.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/boss_magtheridon.cpp8
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/def_magtheridons_lair.h2
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/instance_magtheridons_lair.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_nethekurse.cpp77
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_warbringer_omrogg.cpp17
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_warchief_kargath_bladefist.cpp114
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/def_shattered_halls.h2
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/instance_shattered_halls.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_peninsula/boss_doomlord_kazzak.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/hellfire_peninsula/hellfire_peninsula.cpp39
-rw-r--r--src/bindings/scripts/scripts/zone/ironforge/ironforge.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/isle_of_queldanas/isle_of_queldanas.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/boss_curator.cpp114
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/boss_maiden_of_virtue.cpp12
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/boss_midnight.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/boss_moroes.cpp12
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/boss_netherspite.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/boss_nightbane.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/boss_prince_malchezaar.cpp52
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/boss_shade_of_aran.cpp9
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/boss_terestian_illhoof.cpp39
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/bosses_opera.cpp311
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/def_karazhan.h75
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/instance_karazhan.cpp44
-rw-r--r--src/bindings/scripts/scripts/zone/karazhan/karazhan.cpp48
-rw-r--r--src/bindings/scripts/scripts/zone/loch_modan/loch_modan.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/magisters_terrace/boss_felblood_kaelthas.cpp545
-rw-r--r--src/bindings/scripts/scripts/zone/magisters_terrace/boss_priestess_delrissa.cpp369
-rw-r--r--src/bindings/scripts/scripts/zone/magisters_terrace/boss_selin_fireheart.cpp143
-rw-r--r--src/bindings/scripts/scripts/zone/magisters_terrace/boss_vexallus.cpp143
-rw-r--r--src/bindings/scripts/scripts/zone/magisters_terrace/def_magisters_terrace.h13
-rw-r--r--src/bindings/scripts/scripts/zone/magisters_terrace/instance_magisters_terrace.cpp86
-rw-r--r--src/bindings/scripts/scripts/zone/maraudon/boss_celebras_the_cursed.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/maraudon/boss_landslide.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/maraudon/boss_noxxion.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/maraudon/boss_princess_theradras.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/boss_baron_geddon.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/boss_garr.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/boss_gehennas.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/boss_golemagg.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/boss_lucifron.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/boss_magmadar.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/boss_majordomo_executus.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/boss_ragnaros.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/boss_shazzrah.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/boss_sulfuron_harbinger.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/def_molten_core.h2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/instance_molten_core.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/molten_core/molten_core.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/moonglade/moonglade.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/mulgore/mulgore.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/nagrand/nagrand.cpp12
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_anubrekhan.cpp8
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_faerlina.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_four_horsemen.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_gluth.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_gothik.cpp8
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_grobbulus.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_heigan.cpp25
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_kelthuzad.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_loatheb.cpp72
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_maexxna.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_noth.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_patchwerk.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_razuvious.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_sapphiron.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/boss_thaddius.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/naxxramas/instance_naxxramas.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/netherstorm/netherstorm.cpp18
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/boss_malygos.cpp170
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/def_eye_of_eternity.h4
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/instance_eye_of_eternity.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/nexus/boss_anomalus.cpp149
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/nexus/boss_keristrasza.cpp89
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/nexus/boss_magus_telestra.cpp118
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/nexus/boss_ormorok.cpp90
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/nexus/commander_kolurg.cpp57
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/nexus/commander_stoutbeard.cpp63
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/nexus/def_nexus.h35
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/nexus/instance_nexus.cpp158
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/oculus/boss_drakos.cpp82
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/oculus/boss_eregos.cpp104
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/oculus/boss_urom.cpp87
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/oculus/boss_varos.cpp85
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/oculus/def_oculus.h4
-rw-r--r--src/bindings/scripts/scripts/zone/nexus/oculus/instance_oculus.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/obsidian_sanctum/boss_sartharion.cpp300
-rw-r--r--src/bindings/scripts/scripts/zone/obsidian_sanctum/def_obsidian_sanctum.h4
-rw-r--r--src/bindings/scripts/scripts/zone/obsidian_sanctum/instance_obsidian_sanctum.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/onyxias_lair/boss_onyxia.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/orgrimmar/orgrimmar.cpp25
-rw-r--r--src/bindings/scripts/scripts/zone/razorfen_downs/boss_amnennar_the_coldbringer.cpp95
-rw-r--r--src/bindings/scripts/scripts/zone/razorfen_downs/razorfen_downs.cpp85
-rw-r--r--src/bindings/scripts/scripts/zone/razorfen_kraul/razorfen_kraul.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_ayamiss.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_buru.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_kurinnaxx.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_moam.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_ossirian.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_rajaxx.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/instance_ruins_of_ahnqiraj.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/boss_arcanist_doan.cpp150
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/boss_azshir_the_sleepless.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/boss_bloodmage_thalnos.cpp97
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/boss_headless_horseman.cpp12
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/boss_herod.cpp50
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/boss_high_inquisitor_fairbanks.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/boss_houndmaster_loksey.cpp23
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/boss_interrogator_vishas.cpp94
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/boss_mograine_and_whitemane.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/boss_scorn.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/def_scarlet_monastery.h8
-rw-r--r--src/bindings/scripts/scripts/zone/scarlet_monastery/instance_scarlet_monastery.cpp10
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_darkmaster_gandling.cpp39
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_death_knight_darkreaver.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_doctor_theolen_krastinov.cpp8
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_illucia_barov.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_instructor_malicia.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_jandice_barov.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_kormok.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_lord_alexei_barov.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_lorekeeper_polkelt.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_ras_frostwhisper.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_the_ravenian.cpp8
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/boss_vectus.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/def_scholomance.h5
-rw-r--r--src/bindings/scripts/scripts/zone/scholomance/instance_scholomance.cpp92
-rw-r--r--src/bindings/scripts/scripts/zone/searing_gorge/searing_gorge.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/shadowfang_keep/def_shadowfang_keep.h2
-rw-r--r--src/bindings/scripts/scripts/zone/shadowfang_keep/instance_shadowfang_keep.cpp68
-rw-r--r--src/bindings/scripts/scripts/zone/shadowfang_keep/shadowfang_keep.cpp102
-rw-r--r--src/bindings/scripts/scripts/zone/shadowmoon_valley/boss_doomwalker.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/shadowmoon_valley/shadowmoon_valley.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/shattrath/shattrath_city.cpp61
-rw-r--r--src/bindings/scripts/scripts/zone/silithus/silithus.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/silvermoon/silvermoon_city.cpp8
-rw-r--r--src/bindings/scripts/scripts/zone/silverpine_forest/silverpine_forest.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stonetalon_mountains/stonetalon_mountains.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stormwind/stormwind_city.cpp41
-rw-r--r--src/bindings/scripts/scripts/zone/stranglethorn_vale/stranglethorn_vale.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/boss_baron_rivendare.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/boss_baroness_anastari.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/boss_cannon_master_willey.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/boss_dathrohan_balnazzar.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/boss_magistrate_barthilas.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/boss_maleki_the_pallid.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/boss_nerubenkan.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/boss_order_of_silver_hand.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/boss_postmaster_malown.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/boss_ramstein_the_gorger.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/boss_timmy_the_cruel.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/def_stratholme.h2
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/instance_stratholme.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/stratholme/stratholme.cpp77
-rw-r--r--src/bindings/scripts/scripts/zone/sunwell_plateau/boss_brutallus.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/sunwell_plateau/boss_eredar_twins.cpp40
-rw-r--r--src/bindings/scripts/scripts/zone/sunwell_plateau/boss_felmyst.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/sunwell_plateau/boss_kalecgos.cpp12
-rw-r--r--src/bindings/scripts/scripts/zone/sunwell_plateau/def_sunwell_plateau.h2
-rw-r--r--src/bindings/scripts/scripts/zone/sunwell_plateau/instance_sunwell_plateau.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tanaris/tanaris.cpp39
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/arcatraz.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/boss_harbinger_skyriss.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/def_arcatraz.h2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/instance_arcatraz.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_high_botanist_freywinn.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_laj.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_warp_splinter.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_alar.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_astromancer.cpp3
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_kaelthas.cpp34
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_void_reaver.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_eye/def_the_eye.h2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_eye/instance_the_eye.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_eye/the_eye.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_gyrokill.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_ironhand.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_nethermancer_sepethrea.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_pathaleon_the_calculator.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/instance_mechanar.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_bug_trio.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_cthun.cpp30
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_fankriss.cpp14
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_huhuran.cpp8
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_ouro.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_sartura.cpp34
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_skeram.cpp33
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_twinemperors.cpp19
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_viscidus.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/def_temple_of_ahnqiraj.h2
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/instance_temple_of_ahnqiraj.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/mob_anubisath_sentinel.cpp14
-rw-r--r--src/bindings/scripts/scripts/zone/terokkar_forest/terokkar_forest.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/thousand_needles/thousand_needles.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/thunder_bluff/thunder_bluff.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/tirisfal_glades/tirisfal_glades.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/uldaman/boss_ironaya.cpp14
-rw-r--r--src/bindings/scripts/scripts/zone/uldaman/instance_uldaman.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/uldaman/uldaman.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_bjarngrim.cpp94
-rw-r--r--src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_ionar.cpp114
-rw-r--r--src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_loken.cpp86
-rw-r--r--src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_volkhan.cpp128
-rw-r--r--src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/def_halls_of_lightning.h4
-rw-r--r--src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/instance_halls_of_lightning.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_krystallus.cpp73
-rw-r--r--src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_maiden_of_grief.cpp81
-rw-r--r--src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_sjonnir.cpp83
-rw-r--r--src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/def_halls_of_stone.h4
-rw-r--r--src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/instance_halls_of_stone.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/undercity/undercity.cpp8
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_dalronn.cpp97
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_ingvar_the_plunderer.cpp470
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_keleseth.cpp338
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald.cpp96
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald_dalronn.cpp408
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/def_utgarde_keep.h31
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/instance_utgarde_keep.cpp231
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_palehoof.cpp78
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_skadi.cpp89
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_svala.cpp83
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_ymiron.cpp85
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/def_pinnacle.h4
-rw-r--r--src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/instance_pinnacle.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/vault_of_archavon/boss_archavon.cpp93
-rw-r--r--src/bindings/scripts/scripts/zone/vault_of_archavon/def_vault_of_archavon.h4
-rw-r--r--src/bindings/scripts/scripts/zone/vault_of_archavon/instance_vault_of_archavon.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/violet_hold/boss_cyanigosa.cpp82
-rw-r--r--src/bindings/scripts/scripts/zone/violet_hold/boss_erekem.cpp82
-rw-r--r--src/bindings/scripts/scripts/zone/violet_hold/boss_ichoron.cpp81
-rw-r--r--src/bindings/scripts/scripts/zone/violet_hold/boss_lavanthor.cpp52
-rw-r--r--src/bindings/scripts/scripts/zone/violet_hold/boss_moragg.cpp50
-rw-r--r--src/bindings/scripts/scripts/zone/violet_hold/boss_xevozz.cpp82
-rw-r--r--src/bindings/scripts/scripts/zone/violet_hold/boss_zuramat.cpp82
-rw-r--r--src/bindings/scripts/scripts/zone/violet_hold/def_violet_hold.h4
-rw-r--r--src/bindings/scripts/scripts/zone/violet_hold/instance_violet_hold.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/wailing_caverns/instance_wailing_caverns.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/western_plaguelands/western_plaguelands.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/westfall/westfall.cpp59
-rw-r--r--src/bindings/scripts/scripts/zone/winterspring/winterspring.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zangarmarsh/zangarmarsh.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulaman/boss_akilzon.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulaman/boss_halazzi.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulaman/boss_hexlord.cpp3
-rw-r--r--src/bindings/scripts/scripts/zone/zulaman/boss_janalai.cpp10
-rw-r--r--src/bindings/scripts/scripts/zone/zulaman/boss_nalorakk.cpp14
-rw-r--r--src/bindings/scripts/scripts/zone/zulaman/boss_zuljin.cpp12
-rw-r--r--src/bindings/scripts/scripts/zone/zulaman/def_zulaman.h2
-rw-r--r--src/bindings/scripts/scripts/zone/zulaman/instance_zulaman.cpp6
-rw-r--r--src/bindings/scripts/scripts/zone/zulaman/zulaman.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulfarrak/zulfarrak.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_arlokk.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_gahzranka.cpp4
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_grilek.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_hakkar.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_hazzarah.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_jeklik.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_jindo.cpp21
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_mandokir.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_marli.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_renataki.cpp14
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_thekal.cpp24
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_venoxis.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/boss_wushoolay.cpp2
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/def_zulgurub.h2
-rw-r--r--src/bindings/scripts/scripts/zone/zulgurub/instance_zulgurub.cpp2
-rw-r--r--src/bindings/scripts/sql/WotLK/npc_taxi.sql10
-rw-r--r--src/bindings/scripts/sql/WotLK/script_texts_wotlk.sql530
-rw-r--r--src/bindings/scripts/sql/WotLK/wotlk_bosses.sql124
-rw-r--r--src/bindings/scripts/system.cpp4
467 files changed, 16120 insertions, 6430 deletions
diff --git a/src/bindings/scripts/CMakeLists.txt b/src/bindings/scripts/CMakeLists.txt
index dadb2d76985..93fbeaf171a 100644
--- a/src/bindings/scripts/CMakeLists.txt
+++ b/src/bindings/scripts/CMakeLists.txt
@@ -15,20 +15,18 @@ SET(trinityscript_LIB_SRCS
scripts/boss/boss_lethon.cpp
scripts/boss/boss_taerar.cpp
scripts/boss/boss_ysondre.cpp
- scripts/creature/mob_event_ai.cpp
- scripts/creature/mob_event_ai.h
scripts/creature/mob_generic_creature.cpp
scripts/creature/simple_ai.cpp
scripts/creature/simple_ai.h
- scripts/custom/custom_example.cpp
- scripts/custom/custom_gossip_codebox.cpp
- scripts/custom/test.cpp
+ scripts/examples/example_creature.cpp
+ scripts/examples/example_escort.cpp
+ scripts/examples/example_gossip_codebox.cpp
+ scripts/examples/example_misc.cpp
scripts/go/go_scripts.cpp
scripts/guard/guard_ai.cpp
scripts/guard/guard_ai.h
scripts/guard/guards.cpp
scripts/item/item_scripts.cpp
- scripts/item/item_test.cpp
scripts/npc/npc_escortAI.cpp
scripts/npc/npc_escortAI.h
scripts/npc/npc_innkeeper.cpp
@@ -67,19 +65,19 @@ SET(trinityscript_LIB_SRCS
scripts/zone/black_temple/def_black_temple.h
scripts/zone/black_temple/illidari_council.cpp
scripts/zone/black_temple/instance_black_temple.cpp
- scripts/zone/blackrock_depths/blackrock_depths.cpp
- scripts/zone/blackrock_depths/boss_ambassador_flamelash.cpp
- scripts/zone/blackrock_depths/boss_anubshiah.cpp
- scripts/zone/blackrock_depths/boss_emperor_dagran_thaurissan.cpp
- scripts/zone/blackrock_depths/boss_general_angerforge.cpp
+ scripts/zone/blackrock_depths/blackrock_depths.cpp
+ scripts/zone/blackrock_depths/boss_ambassador_flamelash.cpp
+ scripts/zone/blackrock_depths/boss_anubshiah.cpp
+ scripts/zone/blackrock_depths/boss_emperor_dagran_thaurissan.cpp
+ scripts/zone/blackrock_depths/boss_general_angerforge.cpp
scripts/zone/blackrock_depths/boss_gorosh_the_dervish.cpp
- scripts/zone/blackrock_depths/boss_grizzle.cpp
- scripts/zone/blackrock_depths/boss_high_interrogator_gerstahn.cpp
- scripts/zone/blackrock_depths/boss_magmus.cpp
- scripts/zone/blackrock_depths/boss_moira_bronzebeard.cpp
- scripts/zone/blackrock_depths/boss_tomb_of_seven.cpp
- scripts/zone/blackrock_depths/def_blackrock_depths.h
- scripts/zone/blackrock_depths/instance_blackrock_depths.cpp
+ scripts/zone/blackrock_depths/boss_grizzle.cpp
+ scripts/zone/blackrock_depths/boss_high_interrogator_gerstahn.cpp
+ scripts/zone/blackrock_depths/boss_magmus.cpp
+ scripts/zone/blackrock_depths/boss_moira_bronzebeard.cpp
+ scripts/zone/blackrock_depths/boss_tomb_of_seven.cpp
+ scripts/zone/blackrock_depths/def_blackrock_depths.h
+ scripts/zone/blackrock_depths/instance_blackrock_depths.cpp
scripts/zone/blackrock_spire/boss_drakkisath.cpp
scripts/zone/blackrock_spire/boss_gyth.cpp
scripts/zone/blackrock_spire/boss_halycon.cpp
@@ -106,6 +104,7 @@ SET(trinityscript_LIB_SRCS
scripts/zone/blasted_lands/blasted_lands.cpp
scripts/zone/blasted_lands/boss_kruul.cpp
scripts/zone/bloodmyst_isle/bloodmyst_isle.cpp
+ scripts/zone/borean_tundra/borean_tundra.cpp
scripts/zone/burning_steppes/burning_steppes.cpp
scripts/zone/caverns_of_time/dark_portal/def_dark_portal.h
scripts/zone/caverns_of_time/dark_portal/instance_dark_portal.cpp
@@ -227,7 +226,6 @@ SET(trinityscript_LIB_SRCS
scripts/zone/naxxramas/boss_gothik.cpp
scripts/zone/naxxramas/boss_grobbulus.cpp
scripts/zone/naxxramas/boss_heigan.cpp
- scripts/zone/naxxramas/boss_highlord_mograine.cpp
scripts/zone/naxxramas/boss_kelthuzad.cpp
scripts/zone/naxxramas/boss_four_horsemen.cpp
scripts/zone/naxxramas/boss_loatheb.cpp
@@ -242,7 +240,8 @@ SET(trinityscript_LIB_SRCS
scripts/zone/onyxias_lair/boss_onyxia.cpp
scripts/zone/orgrimmar/orgrimmar.cpp
scripts/zone/razorfen_downs/boss_amnennar_the_coldbringer.cpp
- scripts/zone/razorfen_kraul/razorfen_kraul.cpp
+ scripts/zone/razorfen_downs/razorfen_downs.cpp
+ scripts/zone/razorfen_kraul/razorfen_kraul.cpp
scripts/zone/ruins_of_ahnqiraj/boss_ayamiss.cpp
scripts/zone/ruins_of_ahnqiraj/boss_buru.cpp
scripts/zone/ruins_of_ahnqiraj/boss_kurinnaxx.cpp
@@ -385,6 +384,91 @@ SET(trinityscript_LIB_SRCS
scripts/zone/zulgurub/boss_wushoolay.cpp
scripts/zone/zulgurub/def_zulgurub.h
scripts/zone/zulgurub/instance_zulgurub.cpp
+ scripts/zone/utgarde_keep/utgarde_keep/instance_utgarde_keep.cpp
+ scripts/zone/utgarde_keep/utgarde_keep/boss_keleseth.cpp
+ scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald_dalronn.cpp
+ scripts/zone/utgarde_keep/utgarde_keep/boss_ingvar_the_plunderer.cpp
+ scripts/zone/utgarde_keep/utgarde_keep/def_utgarde_keep.h
+ scripts/zone/utgarde_keep/utgarde_pinnacle/instance_pinnacle.cpp
+ scripts/zone/utgarde_keep/utgarde_pinnacle/boss_skadi.cpp
+ scripts/zone/utgarde_keep/utgarde_pinnacle/boss_ymiron.cpp
+ scripts/zone/utgarde_keep/utgarde_pinnacle/boss_palehoof.cpp
+ scripts/zone/utgarde_keep/utgarde_pinnacle/boss_svala.cpp
+ scripts/zone/utgarde_keep/utgarde_pinnacle/def_pinnacle.h
+ scripts/zone/nexus/nexus/instance_nexus.cpp
+ scripts/zone/nexus/nexus/boss_magus_telestra.cpp
+ scripts/zone/nexus/nexus/boss_anomalus.cpp
+ scripts/zone/nexus/nexus/boss_ormorok.cpp
+ scripts/zone/nexus/nexus/boss_keristrasza.cpp
+ scripts/zone/nexus/nexus/commander_stoutbeard.cpp
+ scripts/zone/nexus/nexus/commander_kolurg.cpp
+ scripts/zone/nexus/nexus/def_nexus.h
+ scripts/zone/nexus/oculus/instance_oculus.cpp
+ scripts/zone/nexus/oculus/boss_drakos.cpp
+ scripts/zone/nexus/oculus/boss_urom.cpp
+ scripts/zone/nexus/oculus/boss_varos.cpp
+ scripts/zone/nexus/oculus/boss_eregos.cpp
+ scripts/zone/nexus/oculus/def_oculus.h
+ scripts/zone/azjol_nerub/azjol_nerub/instance_azjol_nerub.cpp
+ scripts/zone/azjol_nerub/azjol_nerub/boss_krikthir_the_gatewatcher.cpp
+ scripts/zone/azjol_nerub/azjol_nerub/boss_hadronox.cpp
+ scripts/zone/azjol_nerub/azjol_nerub/boss_anubarak.cpp
+ scripts/zone/azjol_nerub/azjol_nerub/def_azjol_nerub.h
+ scripts/zone/azjol_nerub/ahnkahet/instance_ahnkahet.cpp
+ scripts/zone/azjol_nerub/ahnkahet/boss_prince_taldaram.cpp
+ scripts/zone/azjol_nerub/ahnkahet/boss_elder_nadox.cpp
+ scripts/zone/azjol_nerub/ahnkahet/boss_jedoga_shadowseeker.cpp
+ scripts/zone/azjol_nerub/ahnkahet/boss_herald_volazj.cpp
+ scripts/zone/azjol_nerub/ahnkahet/boss_amanitar.cpp
+ scripts/zone/azjol_nerub/ahnkahet/def_ahnkahet.h
+ scripts/zone/draktharon_keep/instance_drak_tharon_keep.cpp
+ scripts/zone/draktharon_keep/boss_trollgore.cpp
+ scripts/zone/draktharon_keep/boss_novos.cpp
+ scripts/zone/draktharon_keep/boss_dred.cpp
+ scripts/zone/draktharon_keep/boss_tharon_ja.cpp
+ scripts/zone/draktharon_keep/def_drak_tharon_keep.h
+ scripts/zone/violet_hold/instance_violet_hold.cpp
+ scripts/zone/violet_hold/boss_cyanigosa.cpp
+ scripts/zone/violet_hold/boss_erekem.cpp
+ scripts/zone/violet_hold/boss_ichoron.cpp
+ scripts/zone/violet_hold/boss_lavanthor.cpp
+ scripts/zone/violet_hold/boss_moragg.cpp
+ scripts/zone/violet_hold/boss_xevozz.cpp
+ scripts/zone/violet_hold/boss_zuramat.cpp
+ scripts/zone/violet_hold/def_violet_hold.h
+ scripts/zone/gundrak/instance_gundrak.cpp
+ scripts/zone/gundrak/boss_slad_ran.cpp
+ scripts/zone/gundrak/boss_moorabi.cpp
+ scripts/zone/gundrak/boss_drakkari_colossus.cpp
+ scripts/zone/gundrak/boss_gal_darah.cpp
+ scripts/zone/gundrak/boss_eck.cpp
+ scripts/zone/gundrak/def_gundrak.h
+ scripts/zone/ulduar/halls_of_stone/instance_halls_of_stone.cpp
+ scripts/zone/ulduar/halls_of_stone/boss_maiden_of_grief.cpp
+ scripts/zone/ulduar/halls_of_stone/boss_krystallus.cpp
+ scripts/zone/ulduar/halls_of_stone/boss_sjonnir.cpp
+ scripts/zone/ulduar/halls_of_stone/def_halls_of_stone.h
+ scripts/zone/ulduar/halls_of_lightning/instance_halls_of_lightning.cpp
+ scripts/zone/ulduar/halls_of_lightning/boss_bjarngrim.cpp
+ scripts/zone/ulduar/halls_of_lightning/boss_ionar.cpp
+ scripts/zone/ulduar/halls_of_lightning/boss_volkhan.cpp
+ scripts/zone/ulduar/halls_of_lightning/boss_loken.cpp
+ scripts/zone/ulduar/halls_of_lightning/def_halls_of_lightning.h
+ scripts/zone/caverns_of_time/culling_of_stratholme/instance_culling_of_stratholme.cpp
+ scripts/zone/caverns_of_time/culling_of_stratholme/boss_meathook.cpp
+ scripts/zone/caverns_of_time/culling_of_stratholme/boss_epoch.cpp
+ scripts/zone/caverns_of_time/culling_of_stratholme/boss_mal_ganis.cpp
+ scripts/zone/caverns_of_time/culling_of_stratholme/boss_salramm.cpp
+ scripts/zone/caverns_of_time/culling_of_stratholme/def_culling_of_stratholme.h
+ scripts/zone/nexus/eye_of_eternity/instance_eye_of_eternity.cpp
+ scripts/zone/nexus/eye_of_eternity/boss_malygos.cpp
+ scripts/zone/nexus/eye_of_eternity/def_eye_of_eternity.h
+ scripts/zone/obsidian_sanctum/instance_obsidian_sanctum.cpp
+ scripts/zone/obsidian_sanctum/boss_sartharion.cpp
+ scripts/zone/obsidian_sanctum/def_obsidian_sanctum.h
+ scripts/zone/vault_of_archavon/instance_vault_of_archavon.cpp
+ scripts/zone/vault_of_archavon/boss_archavon.cpp
+ scripts/zone/vault_of_archavon/def_vault_of_archavon.h
system.cpp
)
diff --git a/src/bindings/scripts/Makefile.am b/src/bindings/scripts/Makefile.am
new file mode 100644
index 00000000000..764843f3714
--- /dev/null
+++ b/src/bindings/scripts/Makefile.am
@@ -0,0 +1,445 @@
+# Copyright (C) 2008-2009 Trinity <http://www.trinitycore.org/>
+#
+# Thanks to the original authors: MaNGOS <http://getmangos.com/>
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+
+## Process this file with automake to produce Makefile.in
+
+## Sub-directories to parse
+## SUBDIRS = sql
+
+# build shared library
+lib_LTLIBRARIES = libtrinityscript.la
+
+libtrinityscript_la_CPPFLAGS = \
+$(MYSQL_INCLUDES) \
+$(POSTGRE_INCLUDES) \
+-I$(top_srcdir)/dep/include \
+-I$(top_srcdir)/src/shared \
+-I$(top_srcdir)/src/framework \
+-I$(top_srcdir)/src/game \
+-I$(srcdir)/include \
+$(TRINI_INCLUDES) \
+-D_TRINITY_SCRIPT_CONFIG='"$(sysconfdir)/trinitycore.conf"'
+
+libtrinityscript_la_SOURCES = \
+ScriptMgr.cpp \
+ScriptMgr.h \
+include/precompiled.cpp \
+include/precompiled.h \
+include/sc_creature.cpp \
+include/sc_creature.h \
+include/sc_gossip.h \
+include/sc_instance.h \
+scripts/areatrigger/areatrigger_scripts.cpp \
+scripts/boss/boss_emeriss.cpp \
+scripts/boss/boss_lethon.cpp \
+scripts/boss/boss_taerar.cpp \
+scripts/boss/boss_ysondre.cpp \
+scripts/creature/mob_event_ai.cpp \
+scripts/creature/mob_event_ai.h \
+scripts/creature/mob_generic_creature.cpp \
+scripts/creature/simple_ai.cpp \
+scripts/creature/simple_ai.h \
+scripts/examples/example_creature.cpp \
+scripts/examples/example_escort.cpp \
+scripts/examples/example_gossip_codebox.cpp \
+scripts/examples/example_misc.cpp \
+scripts/go/go_scripts.cpp \
+scripts/guard/guard_ai.cpp \
+scripts/guard/guard_ai.h \
+scripts/guard/guards.cpp \
+scripts/item/item_scripts.cpp \
+scripts/npc/npc_escortAI.cpp \
+scripts/npc/npc_escortAI.h \
+scripts/npc/npc_innkeeper.cpp \
+scripts/npc/npc_professions.cpp \
+scripts/npc/npcs_special.cpp \
+scripts/zone/alterac_mountains/alterac_mountains.cpp \
+scripts/zone/arathi_highlands/arathi_highlands.cpp \
+scripts/zone/ashenvale_forest/ashenvale.cpp\
+scripts/zone/aunchindoun/auchenai_crypts/boss_exarch_maladaar.cpp \
+scripts/zone/aunchindoun/auchenai_crypts/boss_shirrak_the_dead_watcher.cpp \
+scripts/zone/aunchindoun/mana_tombs/boss_nexusprince_shaffar.cpp \
+scripts/zone/aunchindoun/mana_tombs/boss_pandemonius.cpp \
+scripts/zone/aunchindoun/sethekk_halls/boss_darkweaver_syth.cpp \
+scripts/zone/aunchindoun/sethekk_halls/boss_tailonking_ikiss.cpp \
+scripts/zone/aunchindoun/sethekk_halls/def_sethekk_halls.h \
+scripts/zone/aunchindoun/sethekk_halls/instance_sethekk_halls.cpp \
+scripts/zone/aunchindoun/shadow_labyrinth/boss_ambassador_hellmaw.cpp \
+scripts/zone/aunchindoun/shadow_labyrinth/boss_blackheart_the_inciter.cpp \
+scripts/zone/aunchindoun/shadow_labyrinth/boss_grandmaster_vorpil.cpp \
+scripts/zone/aunchindoun/shadow_labyrinth/boss_murmur.cpp \
+scripts/zone/aunchindoun/shadow_labyrinth/def_shadow_labyrinth.h \
+scripts/zone/aunchindoun/shadow_labyrinth/instance_shadow_labyrinth.cpp \
+scripts/zone/azshara/azshara.cpp \
+scripts/zone/azshara/boss_azuregos.cpp \
+scripts/zone/azuremyst_isle/azuremyst_isle.cpp \
+scripts/zone/barrens/the_barrens.cpp \
+scripts/zone/black_temple/black_temple.cpp \
+scripts/zone/black_temple/boss_bloodboil.cpp \
+scripts/zone/black_temple/boss_illidan.cpp \
+scripts/zone/black_temple/boss_mother_shahraz.cpp \
+scripts/zone/black_temple/boss_reliquary_of_souls.cpp \
+scripts/zone/black_temple/boss_shade_of_akama.cpp \
+scripts/zone/black_temple/boss_supremus.cpp \
+scripts/zone/black_temple/boss_teron_gorefiend.cpp \
+scripts/zone/black_temple/boss_warlord_najentus.cpp \
+scripts/zone/black_temple/def_black_temple.h \
+scripts/zone/black_temple/illidari_council.cpp \
+scripts/zone/black_temple/instance_black_temple.cpp \
+scripts/zone/blackrock_depths/blackrock_depths.cpp \
+scripts/zone/blackrock_depths/boss_ambassador_flamelash.cpp \
+scripts/zone/blackrock_depths/boss_anubshiah.cpp \
+scripts/zone/blackrock_depths/boss_emperor_dagran_thaurissan.cpp \
+scripts/zone/blackrock_depths/boss_general_angerforge.cpp \
+scripts/zone/blackrock_depths/boss_gorosh_the_dervish.cpp \
+scripts/zone/blackrock_depths/boss_grizzle.cpp \
+scripts/zone/blackrock_depths/boss_high_interrogator_gerstahn.cpp \
+scripts/zone/blackrock_depths/boss_magmus.cpp \
+scripts/zone/blackrock_depths/boss_moira_bronzebeard.cpp \
+scripts/zone/blackrock_depths/boss_tomb_of_seven.cpp \
+scripts/zone/blackrock_depths/def_blackrock_depths.h \
+scripts/zone/blackrock_depths/instance_blackrock_depths.cpp \
+scripts/zone/blackrock_spire/boss_drakkisath.cpp \
+scripts/zone/blackrock_spire/boss_gyth.cpp \
+scripts/zone/blackrock_spire/boss_halycon.cpp \
+scripts/zone/blackrock_spire/boss_highlord_omokk.cpp \
+scripts/zone/blackrock_spire/boss_mother_smolderweb.cpp \
+scripts/zone/blackrock_spire/boss_overlord_wyrmthalak.cpp \
+scripts/zone/blackrock_spire/boss_pyroguard_emberseer.cpp \
+scripts/zone/blackrock_spire/boss_quartermaster_zigris.cpp \
+scripts/zone/blackrock_spire/boss_rend_blackhand.cpp \
+scripts/zone/blackrock_spire/boss_shadow_hunter_voshgajin.cpp \
+scripts/zone/blackrock_spire/boss_the_beast.cpp \
+scripts/zone/blackrock_spire/boss_warmaster_voone.cpp \
+scripts/zone/blackwing_lair/boss_broodlord_lashlayer.cpp \
+scripts/zone/blackwing_lair/boss_chromaggus.cpp \
+scripts/zone/blackwing_lair/boss_ebonroc.cpp \
+scripts/zone/blackwing_lair/boss_firemaw.cpp \
+scripts/zone/blackwing_lair/boss_flamegor.cpp \
+scripts/zone/blackwing_lair/boss_nefarian.cpp \
+scripts/zone/blackwing_lair/boss_razorgore.cpp \
+scripts/zone/blackwing_lair/boss_vaelastrasz.cpp \
+scripts/zone/blackwing_lair/boss_victor_nefarius.cpp \
+scripts/zone/blackwing_lair/instance_blackwing_lair.cpp \
+scripts/zone/blades_edge_mountains/blades_edge_mountains.cpp \
+scripts/zone/blasted_lands/blasted_lands.cpp \
+scripts/zone/blasted_lands/boss_kruul.cpp \
+scripts/zone/bloodmyst_isle/bloodmyst_isle.cpp \
+scripts/zone/borean_tundra/borean_tundra.cpp \
+scripts/zone/burning_steppes/burning_steppes.cpp \
+scripts/zone/caverns_of_time/dark_portal/boss_aeonus.cpp \
+scripts/zone/caverns_of_time/dark_portal/boss_chrono_lord_deja.cpp \
+scripts/zone/caverns_of_time/dark_portal/boss_temporus.cpp \
+scripts/zone/caverns_of_time/dark_portal/dark_portal.cpp \
+scripts/zone/caverns_of_time/dark_portal/def_dark_portal.h \
+scripts/zone/caverns_of_time/dark_portal/instance_dark_portal.cpp \
+scripts/zone/caverns_of_time/hyjal/boss_archimonde.cpp \
+scripts/zone/caverns_of_time/hyjal/def_hyjal.h \
+scripts/zone/caverns_of_time/hyjal/hyjal.cpp \
+scripts/zone/caverns_of_time/hyjal/hyjalAI.cpp \
+scripts/zone/caverns_of_time/hyjal/hyjalAI.h \
+scripts/zone/caverns_of_time/hyjal/instance_hyjal.cpp \
+scripts/zone/caverns_of_time/old_hillsbrad/boss_captain_skarloc.cpp \
+scripts/zone/caverns_of_time/old_hillsbrad/boss_epoch_hunter.cpp \
+scripts/zone/caverns_of_time/old_hillsbrad/boss_leutenant_drake.cpp \
+scripts/zone/caverns_of_time/old_hillsbrad/def_old_hillsbrad.h \
+scripts/zone/caverns_of_time/old_hillsbrad/instance_old_hillsbrad.cpp \
+scripts/zone/caverns_of_time/old_hillsbrad/old_hillsbrad.cpp \
+scripts/zone/coilfang_resevoir/serpent_shrine/boss_fathomlord_karathress.cpp \
+scripts/zone/coilfang_resevoir/serpent_shrine/boss_hydross_the_unstable.cpp \
+scripts/zone/coilfang_resevoir/serpent_shrine/boss_lurker_below.cpp \
+scripts/zone/coilfang_resevoir/serpent_shrine/boss_lady_vashj.cpp \
+scripts/zone/coilfang_resevoir/serpent_shrine/boss_leotheras_the_blind.cpp \
+scripts/zone/coilfang_resevoir/serpent_shrine/boss_morogrim_tidewalker.cpp \
+scripts/zone/coilfang_resevoir/serpent_shrine/def_serpent_shrine.h \
+scripts/zone/coilfang_resevoir/serpent_shrine/instance_serpent_shrine.cpp \
+scripts/zone/coilfang_resevoir/steam_vault/boss_hydromancer_thespia.cpp \
+scripts/zone/coilfang_resevoir/steam_vault/boss_mekgineer_steamrigger.cpp \
+scripts/zone/coilfang_resevoir/steam_vault/boss_warlord_kalithresh.cpp \
+scripts/zone/coilfang_resevoir/steam_vault/def_steam_vault.h \
+scripts/zone/coilfang_resevoir/steam_vault/instance_steam_vault.cpp \
+scripts/zone/coilfang_resevoir/underbog/boss_hungarfen.cpp \
+scripts/zone/darkshore/darkshore.cpp \
+scripts/zone/deadmines/deadmines.cpp \
+scripts/zone/deadmines/def_deadmines.h \
+scripts/zone/dun_morogh/dun_morogh.cpp \
+scripts/zone/dustwallow_marsh/dustwallow_marsh.cpp \
+scripts/zone/eastern_plaguelands/eastern_plaguelands.cpp \
+scripts/zone/elwynn_forest/elwynn_forest.cpp \
+scripts/zone/eversong_woods/eversong_woods.cpp \
+scripts/zone/felwood/felwood.cpp \
+scripts/zone/feralas/feralas.cpp \
+scripts/zone/ghostlands/ghostlands.cpp \
+scripts/zone/gruuls_lair/boss_gruul.cpp \
+scripts/zone/gruuls_lair/boss_high_king_maulgar.cpp \
+scripts/zone/gruuls_lair/def_gruuls_lair.h \
+scripts/zone/gruuls_lair/instance_gruuls_lair.cpp \
+scripts/zone/hellfire_citadel/blood_furnace/boss_broggok.cpp \
+scripts/zone/hellfire_citadel/blood_furnace/boss_kelidan_the_breaker.cpp \
+scripts/zone/hellfire_citadel/blood_furnace/boss_the_maker.cpp \
+scripts/zone/hellfire_citadel/blood_furnace/instance_blood_furnace.cpp \
+scripts/zone/hellfire_citadel/blood_furnace/def_blood_furnace.h \
+scripts/zone/hellfire_citadel/hellfire_ramparts/boss_omor_the_unscarred.cpp \
+scripts/zone/hellfire_citadel/hellfire_ramparts/boss_watchkeeper_gargolmar.cpp \
+scripts/zone/hellfire_citadel/hellfire_ramparts/boss_vazruden_the_herald.cpp \
+scripts/zone/hellfire_citadel/magtheridons_lair/boss_magtheridon.cpp \
+scripts/zone/hellfire_citadel/magtheridons_lair/def_magtheridons_lair.h \
+scripts/zone/hellfire_citadel/magtheridons_lair/instance_magtheridons_lair.cpp \
+scripts/zone/hellfire_citadel/shattered_halls/boss_nethekurse.cpp \
+scripts/zone/hellfire_citadel/shattered_halls/boss_warbringer_omrogg.cpp \
+scripts/zone/hellfire_citadel/shattered_halls/boss_warchief_kargath_bladefist.cpp \
+scripts/zone/hellfire_citadel/shattered_halls/def_shattered_halls.h \
+scripts/zone/hellfire_citadel/shattered_halls/instance_shattered_halls.cpp \
+scripts/zone/hellfire_peninsula/boss_doomlord_kazzak.cpp \
+scripts/zone/hellfire_peninsula/hellfire_peninsula.cpp \
+scripts/zone/ironforge/ironforge.cpp \
+scripts/zone/isle_of_queldanas/isle_of_queldanas.cpp \
+scripts/zone/karazhan/boss_curator.cpp \
+scripts/zone/karazhan/boss_maiden_of_virtue.cpp \
+scripts/zone/karazhan/boss_midnight.cpp \
+scripts/zone/karazhan/boss_moroes.cpp \
+scripts/zone/karazhan/boss_netherspite.cpp \
+scripts/zone/karazhan/boss_nightbane.cpp \
+scripts/zone/karazhan/boss_prince_malchezaar.cpp \
+scripts/zone/karazhan/boss_shade_of_aran.cpp \
+scripts/zone/karazhan/boss_terestian_illhoof.cpp \
+scripts/zone/karazhan/bosses_opera.cpp \
+scripts/zone/karazhan/def_karazhan.h \
+scripts/zone/karazhan/instance_karazhan.cpp \
+scripts/zone/karazhan/karazhan.cpp \
+scripts/zone/loch_modan/loch_modan.cpp \
+scripts/zone/magisters_terrace/boss_felblood_kaelthas.cpp \
+scripts/zone/magisters_terrace/boss_priestess_delrissa.cpp \
+scripts/zone/magisters_terrace/boss_selin_fireheart.cpp \
+scripts/zone/magisters_terrace/boss_vexallus.cpp \
+scripts/zone/magisters_terrace/def_magisters_terrace.h \
+scripts/zone/magisters_terrace/instance_magisters_terrace.cpp \
+scripts/zone/maraudon/boss_celebras_the_cursed.cpp \
+scripts/zone/maraudon/boss_landslide.cpp \
+scripts/zone/maraudon/boss_noxxion.cpp \
+scripts/zone/maraudon/boss_princess_theradras.cpp \
+scripts/zone/molten_core/boss_baron_geddon.cpp \
+scripts/zone/molten_core/boss_garr.cpp \
+scripts/zone/molten_core/boss_gehennas.cpp \
+scripts/zone/molten_core/boss_golemagg.cpp \
+scripts/zone/molten_core/boss_lucifron.cpp \
+scripts/zone/molten_core/boss_magmadar.cpp \
+scripts/zone/molten_core/boss_majordomo_executus.cpp \
+scripts/zone/molten_core/boss_ragnaros.cpp \
+scripts/zone/molten_core/boss_shazzrah.cpp \
+scripts/zone/molten_core/boss_sulfuron_harbinger.cpp \
+scripts/zone/molten_core/def_molten_core.h \
+scripts/zone/molten_core/instance_molten_core.cpp \
+scripts/zone/molten_core/molten_core.cpp \
+scripts/zone/moonglade/moonglade.cpp \
+scripts/zone/mulgore/mulgore.cpp \
+scripts/zone/nagrand/nagrand.cpp \
+scripts/zone/naxxramas/boss_anubrekhan.cpp \
+scripts/zone/naxxramas/boss_faerlina.cpp \
+scripts/zone/naxxramas/boss_gluth.cpp \
+scripts/zone/naxxramas/boss_gothik.cpp \
+scripts/zone/naxxramas/boss_grobbulus.cpp \
+scripts/zone/naxxramas/boss_heigan.cpp \
+scripts/zone/naxxramas/boss_kelthuzad.cpp \
+scripts/zone/naxxramas/boss_four_horsemen.cpp \
+scripts/zone/naxxramas/boss_loatheb.cpp \
+scripts/zone/naxxramas/boss_maexxna.cpp \
+scripts/zone/naxxramas/boss_noth.cpp \
+scripts/zone/naxxramas/boss_patchwerk.cpp \
+scripts/zone/naxxramas/boss_razuvious.cpp \
+scripts/zone/naxxramas/boss_sapphiron.cpp \
+scripts/zone/naxxramas/boss_thaddius.cpp \
+scripts/zone/naxxramas/instance_naxxramas.cpp \
+scripts/zone/netherstorm/netherstorm.cpp \
+scripts/zone/onyxias_lair/boss_onyxia.cpp \
+scripts/zone/orgrimmar/orgrimmar.cpp \
+scripts/zone/razorfen_downs/boss_amnennar_the_coldbringer.cpp \
+scripts/zone/razorfen_downs/razorfen_downs.cpp \
+scripts/zone/razorfen_kraul/razorfen_kraul.cpp \
+scripts/zone/ruins_of_ahnqiraj/boss_ayamiss.cpp \
+scripts/zone/ruins_of_ahnqiraj/boss_buru.cpp \
+scripts/zone/ruins_of_ahnqiraj/boss_kurinnaxx.cpp \
+scripts/zone/ruins_of_ahnqiraj/boss_moam.cpp \
+scripts/zone/ruins_of_ahnqiraj/boss_ossirian.cpp \
+scripts/zone/ruins_of_ahnqiraj/boss_rajaxx.cpp \
+scripts/zone/ruins_of_ahnqiraj/instance_ruins_of_ahnqiraj.cpp \
+scripts/zone/scarlet_monastery/boss_arcanist_doan.cpp \
+scripts/zone/scarlet_monastery/boss_azshir_the_sleepless.cpp \
+scripts/zone/scarlet_monastery/boss_bloodmage_thalnos.cpp \
+scripts/zone/scarlet_monastery/boss_herod.cpp \
+scripts/zone/scarlet_monastery/boss_high_inquisitor_fairbanks.cpp \
+scripts/zone/scarlet_monastery/boss_houndmaster_loksey.cpp \
+scripts/zone/scarlet_monastery/boss_interrogator_vishas.cpp \
+scripts/zone/scarlet_monastery/boss_scorn.cpp \
+scripts/zone/scarlet_monastery/boss_headless_horseman.cpp \
+scripts/zone/scarlet_monastery/boss_mograine_and_whitemane.cpp \
+scripts/zone/scarlet_monastery/instance_scarlet_monastery.cpp \
+scripts/zone/scarlet_monastery/def_scarlet_monastery.h \
+scripts/zone/scholomance/boss_darkmaster_gandling.cpp \
+scripts/zone/scholomance/boss_death_knight_darkreaver.cpp \
+scripts/zone/scholomance/boss_doctor_theolen_krastinov.cpp \
+scripts/zone/scholomance/boss_illucia_barov.cpp \
+scripts/zone/scholomance/boss_instructor_malicia.cpp \
+scripts/zone/scholomance/boss_jandice_barov.cpp \
+scripts/zone/scholomance/boss_kormok.cpp \
+scripts/zone/scholomance/boss_lord_alexei_barov.cpp \
+scripts/zone/scholomance/boss_lorekeeper_polkelt.cpp \
+scripts/zone/scholomance/boss_ras_frostwhisper.cpp \
+scripts/zone/scholomance/boss_the_ravenian.cpp \
+scripts/zone/scholomance/boss_vectus.cpp \
+scripts/zone/scholomance/def_scholomance.h \
+scripts/zone/scholomance/instance_scholomance.cpp \
+scripts/zone/searing_gorge/searing_gorge.cpp \
+scripts/zone/shadowfang_keep/def_shadowfang_keep.h \
+scripts/zone/shadowfang_keep/instance_shadowfang_keep.cpp \
+scripts/zone/shadowfang_keep/shadowfang_keep.cpp \
+scripts/zone/shadowmoon_valley/boss_doomwalker.cpp \
+scripts/zone/shadowmoon_valley/shadowmoon_valley.cpp \
+scripts/zone/shattrath/shattrath_city.cpp \
+scripts/zone/silithus/silithus.cpp \
+scripts/zone/silvermoon/silvermoon_city.cpp \
+scripts/zone/silverpine_forest/silverpine_forest.cpp \
+scripts/zone/stonetalon_mountains/stonetalon_mountains.cpp \
+scripts/zone/stormwind/stormwind_city.cpp \
+scripts/zone/stranglethorn_vale/stranglethorn_vale.cpp \
+scripts/zone/stratholme/boss_baron_rivendare.cpp \
+scripts/zone/stratholme/boss_baroness_anastari.cpp \
+scripts/zone/stratholme/boss_cannon_master_willey.cpp \
+scripts/zone/stratholme/boss_dathrohan_balnazzar.cpp \
+scripts/zone/stratholme/boss_magistrate_barthilas.cpp \
+scripts/zone/stratholme/boss_maleki_the_pallid.cpp \
+scripts/zone/stratholme/boss_nerubenkan.cpp \
+scripts/zone/stratholme/boss_order_of_silver_hand.cpp \
+scripts/zone/stratholme/boss_postmaster_malown.cpp \
+scripts/zone/stratholme/boss_ramstein_the_gorger.cpp \
+scripts/zone/stratholme/boss_timmy_the_cruel.cpp \
+scripts/zone/stratholme/def_stratholme.h \
+scripts/zone/stratholme/instance_stratholme.cpp \
+scripts/zone/stratholme/stratholme.cpp \
+scripts/zone/sunwell_plateau/boss_eredar_twins.cpp \
+scripts/zone/sunwell_plateau/boss_felmyst.cpp \
+scripts/zone/sunwell_plateau/boss_brutallus.cpp \
+scripts/zone/sunwell_plateau/boss_kalecgos.cpp \
+scripts/zone/sunwell_plateau/def_sunwell_plateau.h \
+scripts/zone/sunwell_plateau/instance_sunwell_plateau.cpp \
+scripts/zone/tanaris/tanaris.cpp \
+scripts/zone/tempest_keep/arcatraz/arcatraz.cpp \
+scripts/zone/tempest_keep/arcatraz/boss_harbinger_skyriss.cpp \
+scripts/zone/tempest_keep/arcatraz/def_arcatraz.h \
+scripts/zone/tempest_keep/arcatraz/instance_arcatraz.cpp \
+scripts/zone/tempest_keep/botanica/boss_high_botanist_freywinn.cpp \
+scripts/zone/tempest_keep/botanica/boss_laj.cpp \
+scripts/zone/tempest_keep/botanica/boss_warp_splinter.cpp \
+scripts/zone/tempest_keep/the_eye/boss_alar.cpp \
+scripts/zone/tempest_keep/the_eye/boss_astromancer.cpp \
+scripts/zone/tempest_keep/the_eye/boss_kaelthas.cpp \
+scripts/zone/tempest_keep/the_eye/boss_void_reaver.cpp \
+scripts/zone/tempest_keep/the_eye/def_the_eye.h \
+scripts/zone/tempest_keep/the_eye/instance_the_eye.cpp \
+scripts/zone/tempest_keep/the_eye/the_eye.cpp \
+scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_gyrokill.cpp \
+scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_ironhand.cpp \
+scripts/zone/tempest_keep/the_mechanar/boss_nethermancer_sepethrea.cpp \
+scripts/zone/tempest_keep/the_mechanar/boss_pathaleon_the_calculator.cpp \
+scripts/zone/tempest_keep/the_mechanar/def_mechanar.h \
+scripts/zone/tempest_keep/the_mechanar/instance_mechanar.cpp \
+scripts/zone/temple_of_ahnqiraj/boss_bug_trio.cpp \
+scripts/zone/temple_of_ahnqiraj/boss_cthun.cpp \
+scripts/zone/temple_of_ahnqiraj/boss_fankriss.cpp \
+scripts/zone/temple_of_ahnqiraj/boss_huhuran.cpp \
+scripts/zone/temple_of_ahnqiraj/boss_ouro.cpp \
+scripts/zone/temple_of_ahnqiraj/boss_sartura.cpp \
+scripts/zone/temple_of_ahnqiraj/boss_skeram.cpp \
+scripts/zone/temple_of_ahnqiraj/boss_twinemperors.cpp \
+scripts/zone/temple_of_ahnqiraj/boss_viscidus.cpp \
+scripts/zone/temple_of_ahnqiraj/def_temple_of_ahnqiraj.h \
+scripts/zone/temple_of_ahnqiraj/instance_temple_of_ahnqiraj.cpp \
+scripts/zone/temple_of_ahnqiraj/mob_anubisath_sentinel.cpp \
+scripts/zone/terokkar_forest/terokkar_forest.cpp \
+scripts/zone/thunder_bluff/thunder_bluff.cpp \
+scripts/zone/tirisfal_glades/tirisfal_glades.cpp \
+scripts/zone/thousand_needles/thousand_needles.cpp \
+scripts/zone/uldaman/boss_archaedas.cpp \
+scripts/zone/uldaman/instance_uldaman.cpp \
+scripts/zone/uldaman/boss_ironaya.cpp \
+scripts/zone/uldaman/uldaman.cpp \
+scripts/zone/undercity/undercity.cpp \
+scripts/zone/ungoro_crater/ungoro_crater.cpp \
+scripts/zone/utgarde_keep/utgarde_keep/instance_utgarde_keep.cpp \
+scripts/zone/utgarde_keep/utgarde_keep/boss_keleseth.cpp \
+scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald_dalronn.cpp \
+scripts/zone/utgarde_keep/utgarde_keep/boss_ingvar_the_plunderer.cpp \
+scripts/zone/wailing_caverns/instance_wailing_caverns.cpp \
+scripts/zone/western_plaguelands/western_plaguelands.cpp \
+scripts/zone/westfall/westfall.cpp \
+scripts/zone/winterspring/winterspring.cpp \
+scripts/zone/zangarmarsh/zangarmarsh.cpp \
+scripts/zone/zulaman/boss_akilzon.cpp \
+scripts/zone/zulaman/boss_halazzi.cpp \
+scripts/zone/zulaman/boss_hexlord.cpp \
+scripts/zone/zulaman/boss_janalai.cpp \
+scripts/zone/zulaman/boss_nalorakk.cpp \
+scripts/zone/zulaman/boss_zuljin.cpp \
+scripts/zone/zulaman/def_zulaman.h \
+scripts/zone/zulaman/instance_zulaman.cpp \
+scripts/zone/zulaman/zulaman.cpp \
+scripts/zone/zulfarrak/zulfarrak.cpp \
+scripts/zone/zulgurub/boss_arlokk.cpp \
+scripts/zone/zulgurub/boss_gahzranka.cpp \
+scripts/zone/zulgurub/boss_grilek.cpp \
+scripts/zone/zulgurub/boss_hakkar.cpp \
+scripts/zone/zulgurub/boss_hazzarah.cpp \
+scripts/zone/zulgurub/boss_jeklik.cpp \
+scripts/zone/zulgurub/boss_jindo.cpp \
+scripts/zone/zulgurub/boss_mandokir.cpp \
+scripts/zone/zulgurub/boss_marli.cpp \
+scripts/zone/zulgurub/boss_renataki.cpp \
+scripts/zone/zulgurub/boss_thekal.cpp \
+scripts/zone/zulgurub/boss_venoxis.cpp \
+scripts/zone/zulgurub/boss_wushoolay.cpp \
+scripts/zone/zulgurub/def_zulgurub.h \
+scripts/zone/zulgurub/instance_zulgurub.cpp \
+system.cpp
+
+## libtool settings
+# API versioning
+# Increase the last number, if you do bug fixes only, no interface change.
+# Increase the middle number when you augmented the interface ( aka add new exported functions ).
+# Increase the first number when you break old interface. ( aka remove/change previously exported functions ).
+libtrinityscript_la_LIBFLAGS = -version-info 0:0:1
+libtrinityscript_la_LIBADD = $(MYSQL_LIBS) $(POSTGRE_LIBS)
+
+## Additional files to install
+## sysconf_DATA =
+
+## EXTRA_DIST =
+
+## Prevend overwrite of the config file, if its already installed
+install-data-hook:
+ @list='$(sysconf_DATA)'; for p in $$list; do \
+ dest=`echo $$p | sed -e s/.dist//`; \
+ if test -f $(DESTDIR)$(sysconfdir)/$$dest; then \
+ echo "$@ will not overwrite existing $(DESTDIR)$(sysconfdir)/$$dest"; \
+ else \
+ echo " $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(sysconfdir)/$$dest"; \
+ $(INSTALL_DATA) $(srcdir)/$$p $(DESTDIR)$(sysconfdir)/$$dest; \
+ fi; \
+ done
+
+
+
diff --git a/src/bindings/scripts/ScriptMgr.cpp b/src/bindings/scripts/ScriptMgr.cpp
index 8ab29f769f0..1de66cdf98d 100644
--- a/src/bindings/scripts/ScriptMgr.cpp
+++ b/src/bindings/scripts/ScriptMgr.cpp
@@ -5,10 +5,9 @@
#include "precompiled.h"
#include "Config/Config.h"
#include "Database/DatabaseEnv.h"
-#include "Database/DBCStores.h"
+#include "DBCStores.h"
#include "ObjectMgr.h"
#include "ProgressBar.h"
-#include "scripts/creature/mob_event_ai.h"
#define _FULLVERSION "TrinityScript"
@@ -16,7 +15,6 @@
# define _TRINITY_SCRIPT_CONFIG "trinitycore.conf"
#endif _TRINITY_SCRIPT_CONFIG
-//*** Global data ***
int num_sc_scripts;
Script *m_scripts[MAX_SCRIPTS];
@@ -32,36 +30,13 @@ struct StringTextData
uint32 Emote;
};
-// Enums used by StringTextData::Type
-enum ChatType
-{
- CHAT_TYPE_SAY = 0,
- CHAT_TYPE_YELL = 1,
- CHAT_TYPE_TEXT_EMOTE = 2,
- CHAT_TYPE_BOSS_EMOTE = 3,
- CHAT_TYPE_WHISPER = 4,
- CHAT_TYPE_BOSS_WHISPER = 5,
-};
-
#define TEXT_SOURCE_RANGE -1000000 //the amount of entries each text source has available
// Text Maps
UNORDERED_MAP<int32, StringTextData> TextMap;
-//*** End Global data ***
-
-//*** EventAI data ***
-//Event AI structure. Used exclusivly by mob_event_ai.cpp (60 bytes each)
-UNORDERED_MAP<uint32, std::vector<EventAI_Event> > EventAI_Event_Map;
-
-//Event AI summon structure. Used exclusivly by mob_event_ai.cpp.
-UNORDERED_MAP<uint32, EventAI_Summon> EventAI_Summon_Map;
-
-//Event AI error prevention structure. Used at runtime to prevent error log spam of same creature id.
-//UNORDERED_MAP<uint32, EventAI_CreatureError> EventAI_CreatureErrorPreventionList;
-
-uint32 EAI_ErrorLevel;
-//*** End EventAI data ***
+// Waypoint map (escorts)
+UNORDERED_MAP<uint32, std::vector<PointMovement> > PointMovementMap;
void FillSpellSummary();
void LoadOverridenSQLData();
@@ -78,13 +53,15 @@ extern void AddSC_boss_taerar();
extern void AddSC_boss_ysondre();
// -- Creature --
-extern void AddSC_mob_event();
extern void AddSC_generic_creature();
// -- Custom --
-extern void AddSC_custom_example();
-extern void AddSC_custom_gossip_codebox();
-extern void AddSC_test();
+
+// -- Examples --
+extern void AddSC_example_creature();
+extern void AddSC_example_escort();
+extern void AddSC_example_gossip_codebox();
+extern void AddSC_example_misc();
// -- GO --
extern void AddSC_go_scripts();
@@ -96,7 +73,6 @@ extern void AddSC_guards();
// -- Item --
extern void AddSC_item_scripts();
-extern void AddSC_item_test();
// -- NPC --
extern void AddSC_npc_professions();
@@ -211,6 +187,9 @@ extern void AddSC_blasted_lands();
//Bloodmyst Isle
extern void AddSC_bloodmyst_isle();
+//Borean Tundra
+extern void AddSC_borean_tundra();
+
//Burning steppes
extern void AddSC_burning_steppes();
@@ -395,14 +374,13 @@ extern void AddSC_boss_anubrekhan();
extern void AddSC_boss_maexxna();
extern void AddSC_boss_patchwerk();
extern void AddSC_boss_razuvious();
-extern void AddSC_boss_highlord_mograine();
extern void AddSC_boss_kelthuzad();
-extern void AddSC_boss_faerlina();
extern void AddSC_boss_loatheb();
extern void AddSC_boss_noth();
extern void AddSC_boss_gluth();
extern void AddSC_boss_sapphiron();
extern void AddSC_boss_four_horsemen();
+extern void AddSC_boss_faerlina();
//Netherstorm
extern void AddSC_netherstorm();
@@ -416,6 +394,7 @@ extern void AddSC_orgrimmar();
//Ragefire Chasm
//Razorfen Downs
extern void AddSC_boss_amnennar_the_coldbringer();
+extern void AddSC_razorfen_downs();
//Razorfen Kraul
extern void AddSC_razorfen_kraul();
@@ -574,6 +553,13 @@ extern void AddSC_undercity();
extern void AddSC_ungoro_crater();
//Upper blackrock spire
+
+//Utgarde Keep
+extern void AddSC_boss_keleseth();
+extern void AddSC_boss_skarvald_dalronn();
+extern void AddSC_boss_ingvar_the_plunderer();
+extern void AddSC_instance_utgarde_keep();
+
//Wailing caverns
//Western plaguelands
@@ -622,17 +608,17 @@ extern void AddSC_zulaman();
void LoadDatabase()
{
//Get db string from file
- char const* dbstring = NULL;
+ std::string dbstring = TScriptConfig.GetStringDefault("WorldDatabaseInfo", "");
- if (!TScriptConfig.GetString("WorldDatabaseInfo", &dbstring) )
+ if (dbstring.empty() )
{
error_log("TSCR: Missing world database info from configuration file. Load database aborted.");
return;
}
//Initialize connection to DB
- if (dbstring && TScriptDB.Initialize(dbstring) )
- outstring_log("TSCR: TrinityScript database: %s",dbstring);
+ if (!dbstring.empty() && TScriptDB.Initialize(dbstring.c_str()) )
+ outstring_log("TSCR: TrinityScript database: %s",dbstring.c_str());
else
{
error_log("TSCR: Unable to connect to Database. Load database aborted.");
@@ -663,11 +649,10 @@ void LoadDatabase()
// Load EventAI Text
outstring_log("TSCR: Loading EventAI Texts...");
- LoadTrinityStrings(TScriptDB,"eventai_texts",-1,1+(TEXT_SOURCE_RANGE));
+ LoadTrinityStrings(TScriptDB,"creature_ai_texts",-1,1+(TEXT_SOURCE_RANGE));
// Gather Additional data from EventAI Texts
- //result = TScriptDB.PQuery("SELECT entry, sound, type, language, emote FROM eventai_texts");
- result = TScriptDB.PQuery("SELECT entry, sound, type, language FROM eventai_texts");
+ result = TScriptDB.PQuery("SELECT entry, sound, type, language, emote FROM creature_ai_texts");
outstring_log("TSCR: Loading EventAI Texts additional data...");
if (result)
@@ -685,31 +670,31 @@ void LoadDatabase()
temp.SoundId = fields[1].GetInt32();
temp.Type = fields[2].GetInt32();
temp.Language = fields[3].GetInt32();
- temp.Emote = 0;//fields[4].GetInt32();
+ temp.Emote = fields[4].GetInt32();
if (i >= 0)
{
- error_db_log("TSCR: Entry %i in table `eventai_texts` is not a negative value.",i);
+ error_db_log("TSCR: Entry %i in table `creature_ai_texts` is not a negative value.",i);
continue;
}
if (i <= TEXT_SOURCE_RANGE)
{
- error_db_log("TSCR: Entry %i in table `eventai_texts` is out of accepted entry range for table.",i);
+ error_db_log("TSCR: Entry %i in table `creature_ai_texts` is out of accepted entry range for table.",i);
continue;
}
if (temp.SoundId)
{
if (!GetSoundEntriesStore()->LookupEntry(temp.SoundId))
- error_db_log("TSCR: Entry %i in table `eventai_texts` has soundId %u but sound does not exist.",i,temp.SoundId);
+ error_db_log("TSCR: Entry %i in table `creature_ai_texts` has soundId %u but sound does not exist.",i,temp.SoundId);
}
if (!GetLanguageDescByID(temp.Language))
- error_db_log("TSCR: Entry %i in table `eventai_texts` using Language %u but Language does not exist.",i,temp.Language);
+ error_db_log("TSCR: Entry %i in table `creature_ai_texts` using Language %u but Language does not exist.",i,temp.Language);
if (temp.Type > CHAT_TYPE_BOSS_WHISPER)
- error_db_log("TSCR: Entry %i in table `eventai_texts` has Type %u but this Chat Type does not exist.",i,temp.Type);
+ error_db_log("TSCR: Entry %i in table `creature_ai_texts` has Type %u but this Chat Type does not exist.",i,temp.Type);
TextMap[i] = temp;
++count;
@@ -724,7 +709,7 @@ void LoadDatabase()
barGoLink bar(1);
bar.step();
outstring_log("");
- outstring_log(">> Loaded 0 additional EventAI Texts data. DB table `eventai_texts` is empty.");
+ outstring_log(">> Loaded 0 additional EventAI Texts data. DB table `creature_ai_texts` is empty.");
}
// Load Script Text
@@ -857,455 +842,66 @@ void LoadDatabase()
outstring_log(">> Loaded 0 additional Custom Texts data. DB table `custom_texts` is empty.");
}
- //Gather additional data for EventAI
- result = TScriptDB.PQuery("SELECT id, position_x, position_y, position_z, orientation, spawntimesecs FROM eventai_summons");
-
- //Drop Existing EventSummon Map
- EventAI_Summon_Map.clear();
+ // Drop Existing Waypoint list
+ PointMovementMap.clear();
+ uint64 uiCreatureCount = 0;
- outstring_log("TSCR: Loading EventAI Summons...");
+ // Load Waypoints
+ result = TScriptDB.PQuery("SELECT COUNT(entry) FROM script_waypoint GROUP BY entry");
if (result)
{
- barGoLink bar(result->GetRowCount());
- uint32 Count = 0;
-
- do
- {
- bar.step();
- Field *fields = result->Fetch();
-
- EventAI_Summon temp;
-
- uint32 i = fields[0].GetUInt32();
- temp.position_x = fields[1].GetFloat();
- temp.position_y = fields[2].GetFloat();
- temp.position_z = fields[3].GetFloat();
- temp.orientation = fields[4].GetFloat();
- temp.SpawnTimeSecs = fields[5].GetUInt32();
-
- //Add to map
- EventAI_Summon_Map[i] = temp;
- ++Count;
- }while (result->NextRow());
-
+ uiCreatureCount = result->GetRowCount();
delete result;
-
- outstring_log("");
- outstring_log(">> Loaded %u EventAI summon definitions", Count);
- }else
- {
- barGoLink bar(1);
- bar.step();
- outstring_log("");
- outstring_log(">> Loaded 0 EventAI Summon definitions. DB table `eventai_summons` is empty.");
}
- //Gather event data
- result = TScriptDB.PQuery("SELECT id, creature_id, event_type, event_inverse_phase_mask, event_chance, event_flags, "
- "event_param1, event_param2, event_param3, event_param4, "
- "action1_type, action1_param1, action1_param2, action1_param3, "
- "action2_type, action2_param1, action2_param2, action2_param3, "
- "action3_type, action3_param1, action3_param2, action3_param3 "
- "FROM eventai_scripts");
+ outstring_log("SD2: Loading Script Waypoints for %u creature(s)...", uiCreatureCount);
- //Drop Existing EventAI List
- EventAI_Event_Map.clear();
+ result = TScriptDB.PQuery("SELECT entry, pointid, location_x, location_y, location_z, waittime FROM script_waypoint ORDER BY pointid");
- outstring_log("TSCR: Loading EventAI scripts...");
if (result)
{
barGoLink bar(result->GetRowCount());
- uint32 Count = 0;
+ uint32 uiNodeCount = 0;
do
{
bar.step();
- Field *fields = result->Fetch();
-
- EventAI_Event temp;
-
- temp.event_id = fields[0].GetUInt32();
- uint32 i = temp.event_id;
- temp.creature_id = fields[1].GetUInt32();
- uint32 creature_id = temp.creature_id;
- temp.event_type = fields[2].GetUInt16();
- temp.event_inverse_phase_mask = fields[3].GetUInt32();
- temp.event_chance = fields[4].GetUInt8();
- temp.event_flags = fields[5].GetUInt8();
- temp.event_param1 = fields[6].GetUInt32();
- temp.event_param2 = fields[7].GetUInt32();
- temp.event_param3 = fields[8].GetUInt32();
- temp.event_param4 = fields[9].GetUInt32();
-
- //Creature does not exist in database
- if (!GetCreatureTemplateStore(temp.creature_id))
- error_db_log("TSCR: Event %u has script for non-existing creature.", i);
-
- //Report any errors in event
- if (temp.event_type >= EVENT_T_END)
- error_db_log("TSCR: Event %u has incorrect event type. Maybe DB requires updated version of SD2.", i);
-
- //No chance of this event occuring
- if (temp.event_chance == 0)
- error_db_log("TSCR: Event %u has 0 percent chance. Event will never trigger!", i);
-
- //Chance above 100, force it to be 100
- if (temp.event_chance > 100)
- {
- error_db_log("TSCR: Creature %u are using event %u with more than 100 percent chance. Adjusting to 100 percent.", temp.creature_id, i);
- temp.event_chance = 100;
- }
-
- //Individual event checks
- switch (temp.event_type)
+ Field* pFields = result->Fetch();
+ PointMovement pTemp;
+
+ pTemp.m_uiCreatureEntry = pFields[0].GetUInt32();
+ uint32 uiCreatureEntry = pTemp.m_uiCreatureEntry;
+ pTemp.m_uiPointId = pFields[1].GetUInt32();
+ pTemp.m_fX = pFields[2].GetFloat();
+ pTemp.m_fY = pFields[3].GetFloat();
+ pTemp.m_fZ = pFields[4].GetFloat();
+ pTemp.m_uiWaitTime = pFields[5].GetUInt32();
+
+ CreatureInfo const* pCInfo = GetCreatureTemplateStore(pTemp.m_uiCreatureEntry);
+ if (!pCInfo)
{
- case EVENT_T_HP:
- case EVENT_T_MANA:
- case EVENT_T_TARGET_HP:
- {
- if (temp.event_param2 > 100)
- error_db_log("TSCR: Creature %u are using percentage event(%u) with param2 (MinPercent) > 100. Event will never trigger! ", temp.creature_id, i);
-
- if (temp.event_param1 <= temp.event_param2)
- error_db_log("TSCR: Creature %u are using percentage event(%u) with param1 <= param2 (MaxPercent <= MinPercent). Event will never trigger! ", temp.creature_id, i);
-
- if (temp.event_flags & EFLAG_REPEATABLE && !temp.event_param3 && !temp.event_param4)
- {
- error_db_log("TSCR: Creature %u has param3 and param4=0 (RepeatMin/RepeatMax) but cannot be repeatable without timers. Removing EFLAG_REPEATABLE for event %u.", temp.creature_id, i);
- temp.event_flags &= ~EFLAG_REPEATABLE;
- }
- }
- break;
-
- case EVENT_T_SPELLHIT:
- {
- if (temp.event_param1)
- {
- SpellEntry const* pSpell = GetSpellStore()->LookupEntry(temp.event_param1);
- if (!pSpell)
- {
- error_db_log("TSCR: Creature %u has non-existant SpellID(%u) defined in event %u.", temp.creature_id, temp.event_param1, i);
- continue;
- }
-
- if (temp.event_param2_s != -1 && temp.event_param2 != pSpell->SchoolMask)
- error_db_log("TSCR: Creature %u has param1(spellId %u) but param2 is not -1 and not equal to spell's school mask. Event %u can never trigger.", temp.creature_id, temp.event_param1, i);
- }
-
- //TODO: fix this system with SPELL_SCHOOL_MASK. Current complicate things, using int32(-1) instead of just 0
- //SPELL_SCHOOL_MASK_NONE = 0 and does not exist, thus it can not ever trigger or be used in SpellHit()
- if (temp.event_param2_s != -1 && temp.event_param2_s > SPELL_SCHOOL_MASK_ALL)
- error_db_log("TSCR: Creature %u is using invalid SpellSchoolMask(%u) defined in event %u.", temp.creature_id, temp.event_param2, i);
-
- if (temp.event_param4 < temp.event_param3)
- error_db_log("TSCR: Creature %u are using repeatable event(%u) with param4 < param3 (RepeatMax < RepeatMin). Event will never repeat.", temp.creature_id, i);
- }
- break;
-
- case EVENT_T_RANGE:
- case EVENT_T_OOC_LOS:
- case EVENT_T_FRIENDLY_HP:
- case EVENT_T_FRIENDLY_IS_CC:
- case EVENT_T_FRIENDLY_MISSING_BUFF:
- {
- if (temp.event_param4 < temp.event_param3)
- error_db_log("TSCR: Creature %u are using repeatable event(%u) with param4 < param3 (RepeatMax < RepeatMin). Event will never repeat.", temp.creature_id, i);
- }
- break;
-
- case EVENT_T_TIMER:
- case EVENT_T_TIMER_OOC:
- {
- if (temp.event_param2 < temp.event_param1)
- error_db_log("TSCR: Creature %u are using timed event(%u) with param2 < param1 (InitialMax < InitialMin). Event will never repeat.", temp.creature_id, i);
-
- if (temp.event_param4 < temp.event_param3)
- error_db_log("TSCR: Creature %u are using repeatable event(%u) with param4 < param3 (RepeatMax < RepeatMin). Event will never repeat.", temp.creature_id, i);
- }
- break;
-
- case EVENT_T_KILL:
- case EVENT_T_TARGET_CASTING:
- {
- if (temp.event_param2 < temp.event_param1)
- error_db_log("TSCR: Creature %u are using event(%u) with param2 < param1 (RepeatMax < RepeatMin). Event will never repeat.", temp.creature_id, i);
- }
- break;
-
- case EVENT_T_AGGRO:
- case EVENT_T_DEATH:
- case EVENT_T_EVADE:
- case EVENT_T_SPAWNED:
- case EVENT_T_REACHED_HOME:
- {
- if (temp.event_flags & EFLAG_REPEATABLE)
- {
- error_db_log("TSCR: Creature %u has EFLAG_REPEATABLE set. Event can never be repeatable. Removing flag for event %u.", temp.creature_id, i);
- temp.event_flags &= ~EFLAG_REPEATABLE;
- }
- }
- break;
- }
-
- for (uint32 j = 0; j < MAX_ACTIONS; j++)
- {
- temp.action[j].type = fields[10+(j*4)].GetUInt16();
- temp.action[j].param1 = fields[11+(j*4)].GetUInt32();
- temp.action[j].param2 = fields[12+(j*4)].GetUInt32();
- temp.action[j].param3 = fields[13+(j*4)].GetUInt32();
-
- //Report any errors in actions
- switch (temp.action[j].type)
- {
- case ACTION_T_TEXT:
- {
- if (temp.action[j].param1_s < 0)
- {
- if (TextMap.find(temp.action[j].param1_s) == TextMap.end())
- error_db_log("TSCR: Event %u Action %u param1 refrences non-existing entry in texts table.", i, j+1);
- }
- if (temp.action[j].param2_s < 0)
- {
- if (TextMap.find(temp.action[j].param2_s) == TextMap.end())
- error_db_log("TSCR: Event %u Action %u param2 refrences non-existing entry in texts table.", i, j+1);
-
- if (!temp.action[j].param1_s)
- error_db_log("TSCR: Event %u Action %u has param2, but param1 is not set. Required for randomized text.", i, j+1);
- }
- if (temp.action[j].param3_s < 0)
- {
- if (TextMap.find(temp.action[j].param3_s) == TextMap.end())
- error_db_log("TSCR: Event %u Action %u param3 refrences non-existing entry in texts table.", i, j+1);
-
- if (!temp.action[j].param1_s || !temp.action[j].param2_s)
- error_db_log("TSCR: Event %u Action %u has param3, but param1 and/or param2 is not set. Required for randomized text.", i, j+1);
- }
- }
- break;
- case ACTION_T_SET_FACTION:
- /*if (temp.action[j].param1 !=0 && !GetFactionStore()->LookupEntry(temp.action[j].param1))
- {
- error_db_log("SD2: Event %u Action %u uses non-existant FactionId %u.", i, j+1, temp.action[j].param1);
- temp.action[j].param1 = 0;
- }*/
- break;
- case ACTION_T_MORPH_TO_ENTRY_OR_MODEL:
- if (temp.action[j].param1 !=0 || temp.action[j].param2 !=0)
- {
- if (temp.action[j].param1 && !GetCreatureTemplateStore(temp.action[j].param1))
- {
- error_db_log("TSCR: Event %u Action %u uses non-existant Creature entry %u.", i, j+1, temp.action[j].param1);
- temp.action[j].param1 = 0;
- }
-
- /*if (temp.action[j].param2 && !GetCreatureDisplayStore()->LookupEntry(temp.action[j].param2))
- {
- error_db_log("TSCR: Event %u Action %u uses non-existant ModelId %u.", i, j+1, temp.action[j].param2);
- temp.action[j].param2 = 0;
- }*/
- }
- break;
- case ACTION_T_SOUND:
- if (!GetSoundEntriesStore()->LookupEntry(temp.action[j].param1))
- error_db_log("TSCR: Event %u Action %u uses non-existant SoundID %u.", i, j+1, temp.action[j].param1);
- break;
-
- /*case ACTION_T_RANDOM_SOUND:
- {
- if(!GetSoundEntriesStore()->LookupEntry(temp.action[j].param1))
- error_db_log("TSCR: Event %u Action %u param1 uses non-existant SoundID %u.", i, j+1, temp.action[j].param1);
- if(!GetSoundEntriesStore()->LookupEntry(temp.action[j].param2))
- error_db_log("TSCR: Event %u Action %u param2 uses non-existant SoundID %u.", i, j+1, temp.action[j].param2);
- if(!GetSoundEntriesStore()->LookupEntry(temp.action[j].param3))
- error_db_log("TSCR: Event %u Action %u param3 uses non-existant SoundID %u.", i, j+1, temp.action[j].param3);
- }
- break;*/
-
- case ACTION_T_CAST:
- {
- const SpellEntry *spell = GetSpellStore()->LookupEntry(temp.action[j].param1);
- if (!spell)
- error_db_log("SD2: Event %u Action %u uses non-existant SpellID %u.", i, j+1, temp.action[j].param1);
- else
- {
- if (spell->RecoveryTime > 0 && temp.event_flags & EFLAG_REPEATABLE)
- {
- //output as debug for now, also because there's no general rule all spells have RecoveryTime
- if (temp.event_param3 < spell->RecoveryTime)
- debug_log("SD2: Event %u Action %u uses SpellID %u but cooldown is longer(%u) than minumum defined in event param3(%u).", i, j+1,temp.action[j].param1, spell->RecoveryTime, temp.event_param3);
- }
- }
-
- if (temp.action[j].param2 >= TARGET_T_END)
- error_db_log("TSCR: Event %u Action %u uses incorrect Target type", i, j+1);
- }
- break;
-
- case ACTION_T_REMOVEAURASFROMSPELL:
- {
- if (!GetSpellStore()->LookupEntry(temp.action[j].param2))
- error_db_log("TSCR: Event %u Action %u uses non-existant SpellID %u.", i, j+1, temp.action[j].param2);
-
- if (temp.action[j].param1 >= TARGET_T_END)
- error_db_log("TSCR: Event %u Action %u uses incorrect Target type", i, j+1);
- }
- break;
- case ACTION_T_QUEST_EVENT:
- {
- if (Quest const* qid = GetQuestTemplateStore(temp.action[j].param1))
- {
- if (!qid->HasFlag(QUEST_TRINITY_FLAGS_EXPLORATION_OR_EVENT))
- error_db_log("SD2: Event %u Action %u. SpecialFlags for quest entry %u does not include |2, Action will not have any effect.", i, j+1, temp.action[j].param1);
- }
- else
- error_db_log("SD2: Event %u Action %u uses non-existant Quest entry %u.", i, j+1, temp.action[j].param1);
-
- if (temp.action[j].param2 >= TARGET_T_END)
- error_db_log("SD2: Event %u Action %u uses incorrect Target type", i, j+1);
- }
- break;
- case ACTION_T_QUEST_EVENT_ALL:
- {
- if (Quest const* qid = GetQuestTemplateStore(temp.action[j].param1))
- {
- if (!qid->HasFlag(QUEST_TRINITY_FLAGS_EXPLORATION_OR_EVENT))
- error_db_log("SD2: Event %u Action %u. SpecialFlags for quest entry %u does not include |2, Action will not have any effect.", i, j+1, temp.action[j].param1);
- }
- else
- error_db_log("SD2: Event %u Action %u uses non-existant Quest entry %u.", i, j+1, temp.action[j].param1);
- }
- break;
- case ACTION_T_CASTCREATUREGO:
- {
- if (!GetCreatureTemplateStore(temp.action[j].param1))
- error_db_log("SD2: Event %u Action %u uses non-existant creature entry %u.", i, j+1, temp.action[j].param1);
-
- if (!GetSpellStore()->LookupEntry(temp.action[j].param2))
- error_db_log("TSCR: Event %u Action %u uses non-existant SpellID %u.", i, j+1, temp.action[j].param2);
-
- if (temp.action[j].param3 >= TARGET_T_END)
- error_db_log("SD2: Event %u Action %u uses incorrect Target type", i, j+1);
- }
- break;
- case ACTION_T_CASTCREATUREGO_ALL:
- {
- if (!GetQuestTemplateStore(temp.action[j].param1))
- error_db_log("SD2: Event %u Action %u uses non-existant Quest entry %u.", i, j+1, temp.action[j].param1);
-
- if (!GetSpellStore()->LookupEntry(temp.action[j].param2))
- error_db_log("SD2: Event %u Action %u uses non-existant SpellID %u.", i, j+1, temp.action[j].param2);
- }
- break;
-
- //2nd param target
- case ACTION_T_SUMMON_ID:
- {
- if (!GetCreatureTemplateStore(temp.action[j].param1))
- error_db_log("SD2: Event %u Action %u uses non-existant creature entry %u.", i, j+1, temp.action[j].param1);
-
- if (EventAI_Summon_Map.find(temp.action[j].param3) == EventAI_Summon_Map.end())
- error_db_log("TSCR: Event %u Action %u summons missing EventAI_Summon %u", i, j+1, temp.action[j].param3);
-
- if (temp.action[j].param2 >= TARGET_T_END)
- error_db_log("TSCR: Event %u Action %u uses incorrect Target type", i, j+1);
- }
- break;
- case ACTION_T_KILLED_MONSTER:
- {
- if (!GetCreatureTemplateStore(temp.action[j].param1))
- error_db_log("SD2: Event %u Action %u uses non-existant creature entry %u.", i, j+1, temp.action[j].param1);
-
- if (temp.action[j].param2 >= TARGET_T_END)
- error_db_log("SD2: Event %u Action %u uses incorrect Target type", i, j+1);
- }
- break;
- case ACTION_T_SUMMON:
- {
- if (!GetCreatureTemplateStore(temp.action[j].param1))
- error_db_log("SD2: Event %u Action %u uses non-existant creature entry %u.", i, j+1, temp.action[j].param1);
-
- if (temp.action[j].param2 >= TARGET_T_END)
- error_db_log("SD2: Event %u Action %u uses incorrect Target type", i, j+1);
- }
- break;
- case ACTION_T_THREAT_SINGLE_PCT:
- case ACTION_T_SET_UNIT_FLAG:
- case ACTION_T_REMOVE_UNIT_FLAG:
- if (temp.action[j].param2 >= TARGET_T_END)
- error_db_log("TSCR: Event %u Action %u uses incorrect Target type", i, j+1);
- break;
-
- //3rd param target
- case ACTION_T_SET_UNIT_FIELD:
- if (temp.action[j].param1 < OBJECT_END || temp.action[j].param1 >= UNIT_END)
- error_db_log("SD2: Event %u Action %u param1 (UNIT_FIELD*). Index out of range for intended use.", i, j+1);
- if (temp.action[j].param3 >= TARGET_T_END)
- error_db_log("TSCR: Event %u Action %u uses incorrect Target type", i, j+1);
- break;
-
- case ACTION_T_SET_PHASE:
- if (temp.action[j].param1 > 31)
- error_db_log("TSCR: Event %u Action %u attempts to set phase > 31. Phase mask cannot be used past phase 31.", i, j+1);
- break;
-
- case ACTION_T_INC_PHASE:
- if (!temp.action[j].param1)
- error_db_log("SD2: Event %u Action %u is incrementing phase by 0. Was this intended?", i, j+1);
- break;
-
- case ACTION_T_SET_INST_DATA:
- {
- if (!(temp.event_flags & EFLAG_NORMAL) && !(temp.event_flags & EFLAG_HEROIC))
- error_db_log("SD2: Event %u Action %u. Cannot set instance data without event flags (normal/heroic).", i, j+1);
-
- if (temp.action[j].param2 > SPECIAL)
- error_db_log("SD2: Event %u Action %u attempts to set instance data above encounter state 4. Custom case?", i, j+1);
- }
- break;
- case ACTION_T_SET_INST_DATA64:
- {
- if (!(temp.event_flags & EFLAG_NORMAL) && !(temp.event_flags & EFLAG_HEROIC))
- error_db_log("SD2: Event %u Action %u. Cannot set instance data without event flags (normal/heroic).", i, j+1);
-
- if (temp.action[j].param2 >= TARGET_T_END)
- error_db_log("SD2: Event %u Action %u uses incorrect Target type", i, j+1);
- }
- break;
- case ACTION_T_UPDATE_TEMPLATE:
- {
- if (!GetCreatureTemplateStore(temp.action[j].param1))
- error_db_log("SD2: Event %u Action %u uses non-existant creature entry %u.", i, j+1, temp.action[j].param1);
- }
- break;
- case ACTION_T_RANDOM_SAY:
- case ACTION_T_RANDOM_YELL:
- case ACTION_T_RANDOM_TEXTEMOTE:
- error_db_log("TSCR: Event %u Action %u currently unused ACTION type. Did you forget to update database?", i, j+1);
- break;
-
- default:
- if (temp.action[j].type >= ACTION_T_END)
- error_db_log("TSCR: Event %u Action %u has incorrect action type. Maybe DB requires updated version of SD2.", i, j+1);
- break;
- }
+ error_db_log("SD2: DB table script_waypoint has waypoint for non-existant creature entry %u", pTemp.m_uiCreatureEntry);
+ continue;
}
- //Add to list
- EventAI_Event_Map[creature_id].push_back(temp);
+ if (!pCInfo->ScriptID)
+ error_db_log("SD2: DB table script_waypoint has waypoint for creature entry %u, but creature does not have ScriptName defined and then useless.", pTemp.m_uiCreatureEntry);
- ++Count;
+ PointMovementMap[uiCreatureEntry].push_back(pTemp);
+ ++uiNodeCount;
} while (result->NextRow());
delete result;
outstring_log("");
- outstring_log(">> Loaded %u EventAI scripts", Count);
- }else
+ outstring_log(">> Loaded %u Script Waypoint nodes.", uiNodeCount);
+ }
+ else
{
barGoLink bar(1);
bar.step();
outstring_log("");
- outstring_log(">> Loaded 0 EventAI scripts. DB table `eventai_scripts` is empty.");
+ outstring_log(">> Loaded 0 Script Waypoints. DB table `script_waypoint` is empty.");
}
//Free database thread and resources
@@ -1325,7 +921,7 @@ void ScriptsFree()
delete []SpellSummary;
// Free resources before library unload
- for(int i=0;i<num_sc_scripts;i++)
+ for(int i=0;i<MAX_SCRIPTS;i++)
delete m_scripts[i];
num_sc_scripts = 0;
@@ -1354,25 +950,6 @@ void ScriptsInit()
}
else outstring_log("TSCR: Using configuration file %s",_TRINITY_SCRIPT_CONFIG);
- EAI_ErrorLevel = TScriptConfig.GetIntDefault("EAIErrorLevel", 1);
-
- switch (EAI_ErrorLevel)
- {
- case 0:
- outstring_log("TSCR: EventAI Error Reporting level set to 0 (Startup Errors only)");
- break;
- case 1:
- outstring_log("TSCR: EventAI Error Reporting level set to 1 (Startup errors and Runtime event errors)");
- break;
- case 2:
- outstring_log("TSCR: EventAI Error Reporting level set to 2 (Startup errors, Runtime event errors, and Creation errors)");
- break;
- default:
- outstring_log("TSCR: Unknown EventAI Error Reporting level. Defaulting to 1 (Startup errors and Runtime event errors)");
- EAI_ErrorLevel = 1;
- break;
- }
-
outstring_log("");
//Load database (must be called after TScriptConfig.SetSource). In case it failed, no need to even try load.
@@ -1400,13 +977,15 @@ void ScriptsInit()
AddSC_boss_ysondre();
// -- Creature --
- AddSC_mob_event();
AddSC_generic_creature();
// -- Custom --
- AddSC_custom_example();
- AddSC_custom_gossip_codebox();
- AddSC_test();
+
+ // -- Examples --
+ AddSC_example_creature();
+ AddSC_example_escort();
+ AddSC_example_gossip_codebox();
+ AddSC_example_misc();
// -- GO --
AddSC_go_scripts();
@@ -1418,7 +997,6 @@ void ScriptsInit()
// -- Item --
AddSC_item_scripts();
- AddSC_item_test();
// -- NPC --
AddSC_npc_professions();
@@ -1532,6 +1110,9 @@ void ScriptsInit()
//Bloodmyst Isle
AddSC_bloodmyst_isle();
+
+ //Borean Tundra
+ AddSC_borean_tundra();
//Burning steppes
AddSC_burning_steppes();
@@ -1713,12 +1294,11 @@ void ScriptsInit()
//Naxxramas
AddSC_boss_anubrekhan();
+ AddSC_boss_faerlina();
AddSC_boss_maexxna();
AddSC_boss_patchwerk();
AddSC_boss_razuvious();
- AddSC_boss_highlord_mograine();
AddSC_boss_kelthuzad();
- AddSC_boss_faerlina();
AddSC_boss_loatheb();
AddSC_boss_noth();
AddSC_boss_gluth();
@@ -1737,6 +1317,7 @@ void ScriptsInit()
//Ragefire Chasm
//Razorfen Downs
AddSC_boss_amnennar_the_coldbringer();
+ AddSC_razorfen_downs();
//Razorfen Kraul
AddSC_razorfen_kraul();
@@ -1895,6 +1476,13 @@ void ScriptsInit()
AddSC_ungoro_crater();
//Upper blackrock spire
+
+ //Utgarde Keep
+ AddSC_boss_keleseth();
+ AddSC_boss_skarvald_dalronn();
+ AddSC_boss_ingvar_the_plunderer();
+ AddSC_instance_utgarde_keep();
+
//Wailing caverns
//Western plaguelands
@@ -2022,6 +1610,9 @@ void DoScriptText(int32 textEntry, WorldObject* pSource, Unit* target)
pSource->MonsterWhisper(textEntry, target->GetGUID(), true);
else error_log("TSCR: DoScriptText entry %i cannot whisper without target unit (TYPEID_PLAYER).", textEntry);
}break;
+ case CHAT_TYPE_ZONE_YELL:
+ pSource->MonsterYellToZone(textEntry, (*i).second.Language, target ? target->GetGUID() : 0);
+ break;
}
}
@@ -2035,8 +1626,12 @@ void Script::RegisterSelf()
{
m_scripts[id] = this;
++num_sc_scripts;
- } else
- debug_log("SD2: RegisterSelf, but script named %s does not have ScriptName assigned in database.",(this)->Name.c_str());
+ }
+ else
+ {
+ debug_log("TSCR: RegisterSelf, but script named %s does not have ScriptName assigned in database.",(this)->Name.c_str());
+ delete this;
+ }
}
//********************************
@@ -2243,12 +1838,34 @@ bool ItemUse( Player *player, Item* _Item, SpellCastTargets const& targets)
}
TRINITY_DLL_EXPORT
-bool ReceiveEmote( Player *player, Creature *_Creature, uint32 emote )
+bool EffectDummyCreature(Unit *caster, uint32 spellId, uint32 effIndex, Creature *crTarget )
{
- Script *tmpscript = m_scripts[_Creature->GetScriptId()];
- if (!tmpscript || !tmpscript->pReceiveEmote) return false;
+ Script *tmpscript = m_scripts[crTarget->GetScriptId()];
+
+ if (!tmpscript || !tmpscript->pEffectDummyCreature) return false;
+
+ return tmpscript->pEffectDummyCreature(caster, spellId,effIndex,crTarget);
+}
+
+TRINITY_DLL_EXPORT
+bool EffectDummyGameObj(Unit *caster, uint32 spellId, uint32 effIndex, GameObject *gameObjTarget )
+{
+ Script *tmpscript = m_scripts[gameObjTarget->GetGOInfo()->ScriptId];
+
+ if (!tmpscript || !tmpscript->pEffectDummyGameObj) return false;
+
+ return tmpscript->pEffectDummyGameObj(caster, spellId,effIndex,gameObjTarget);
+}
+
+
+TRINITY_DLL_EXPORT
+bool EffectDummyItem(Unit *caster, uint32 spellId, uint32 effIndex, Item *itemTarget )
+{
+ Script *tmpscript = m_scripts[itemTarget->GetProto()->ScriptId];
+
+ if (!tmpscript || !tmpscript->pEffectDummyItem) return false;
- return tmpscript->pReceiveEmote(player, _Creature, emote);
+ return tmpscript->pEffectDummyItem(caster, spellId,effIndex,itemTarget);
}
TRINITY_DLL_EXPORT
diff --git a/src/bindings/scripts/ScriptMgr.h b/src/bindings/scripts/ScriptMgr.h
index 87a557779a2..719cf7932e9 100644
--- a/src/bindings/scripts/ScriptMgr.h
+++ b/src/bindings/scripts/ScriptMgr.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2008 Trinity <http://www.trinitycore.org/>
+/* Copyright (C) 2008-2009 Trinity <http://www.trinitycore.org/>
*
* Thanks to the original authors: ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
*
@@ -10,7 +10,7 @@
#include "Common.h"
#include "Platform/CompilerDefs.h"
-#include "Database/DBCStructure.h"
+#include "DBCStructure.h"
class Player;
class Creature;
@@ -32,9 +32,11 @@ struct Script
{
Script() :
pGossipHello(NULL), pQuestAccept(NULL), pGossipSelect(NULL), pGossipSelectWithCode(NULL),
- pQuestSelect(NULL), pQuestComplete(NULL), pNPCDialogStatus(NULL), pGODialogStatus(NULL), pChooseReward(NULL),
- pItemHello(NULL), pGOHello(NULL), pAreaTrigger(NULL), pItemQuestAccept(NULL), pGOQuestAccept(NULL),
- pGOChooseReward(NULL),pReceiveEmote(NULL),pItemUse(NULL), GetAI(NULL), GetInstanceData(NULL)
+ pQuestSelect(NULL), pQuestComplete(NULL), pNPCDialogStatus(NULL), pGODialogStatus(NULL),
+ pChooseReward(NULL), pItemHello(NULL), pGOHello(NULL), pAreaTrigger(NULL), pItemQuestAccept(NULL),
+ pGOQuestAccept(NULL), pGOChooseReward(NULL),pItemUse(NULL),
+ pEffectDummyCreature(NULL), pEffectDummyGameObj(NULL), pEffectDummyItem(NULL),
+ GetAI(NULL), GetInstanceData(NULL)
{}
std::string Name;
@@ -57,8 +59,10 @@ struct Script
bool (*pItemQuestAccept )(Player*, Item *, Quest const* );
bool (*pGOQuestAccept )(Player*, GameObject*, Quest const* );
bool (*pGOChooseReward )(Player*, GameObject*, Quest const*, uint32 );
- bool (*pReceiveEmote )(Player*, Creature*, uint32 );
bool (*pItemUse )(Player*, Item*, SpellCastTargets const& );
+ bool (*pEffectDummyCreature )(Unit*, uint32, uint32, Creature* );
+ bool (*pEffectDummyGameObj )(Unit*, uint32, uint32, GameObject* );
+ bool (*pEffectDummyItem )(Unit*, uint32, uint32, Item* );
CreatureAI* (*GetAI)(Creature*);
InstanceData* (*GetInstanceData)(Map*);
diff --git a/src/bindings/scripts/VC71/71ScriptDev2.vcproj b/src/bindings/scripts/VC71/71ScriptDev2.vcproj
index e92d43e61c2..f241121295a 100644
--- a/src/bindings/scripts/VC71/71ScriptDev2.vcproj
+++ b/src/bindings/scripts/VC71/71ScriptDev2.vcproj
@@ -43,7 +43,7 @@
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..\..\..\..\dep\include\;..\..\..\shared\;..\..\..\framework\;..\..\..\game\;..\include\;..\..\..\..\dep\ACE_wrappers"
- PreprocessorDefinitions="WIN32;_DEBUG;MANGOS_DEBUG;_WINDOWS;_USRDLL;SCRIPT"
+ PreprocessorDefinitions="WIN32;_DEBUG;TRINITY_DEBUG;_WINDOWS;_USRDLL;SCRIPT"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
@@ -51,7 +51,7 @@
PrecompiledHeaderThrough="precompiled.h"
WarningLevel="3"
Detect64BitPortabilityProblems="true"
- DebugInformationFormat="4"
+ DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
@@ -69,7 +69,7 @@
LinkIncremental="2"
AdditionalLibraryDirectories="..\..\..\..\win\VC71\zthread__$(PlatformName)_$(ConfigurationName);..\..\..\..\win\VC71\trinitycore__$(PlatformName)_$(ConfigurationName)"
GenerateDebugInformation="true"
- ProgramDatabaseFile="$(OutDir)/MaNGOSScript.pdb"
+ ProgramDatabaseFile="$(OutDir)/TrinityScript.pdb"
SubSystem="2"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
@@ -231,6 +231,26 @@
</File>
</Filter>
<Filter
+ Name="examples"
+ >
+ <File
+ RelativePath="..\scripts\examples\example_creature.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\examples\example_escort.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\examples\example_gossip_codebox.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\examples\example_misc.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
Name="guard"
>
<File
@@ -281,18 +301,6 @@
<Filter
Name="custom"
>
- <File
- RelativePath="..\scripts\custom\custom_example.cpp"
- >
- </File>
- <File
- RelativePath="..\scripts\custom\custom_gossip_codebox.cpp"
- >
- </File>
- <File
- RelativePath="..\scripts\custom\test.cpp"
- >
- </File>
</Filter>
<Filter
Name="areatrigger"
@@ -317,10 +325,6 @@
RelativePath="..\scripts\item\item_scripts.cpp"
>
</File>
- <File
- RelativePath="..\scripts\item\item_test.cpp"
- >
- </File>
</Filter>
<Filter
Name="zone"
@@ -578,6 +582,190 @@
>
</Filter>
<Filter
+ Name="Borean Tundra"
+ >
+ <File
+ RelativePath="..\scripts\zone\borean_tundra\borean_tundra.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Howling Fjord"
+ >
+ </Filter>
+ <Filter
+ Name="Crystalsong Forest"
+ >
+ </Filter>
+ <Filter
+ Name="Dalaran"
+ >
+ </Filter>
+ <Filter
+ Name="Dragonblight"
+ >
+ </Filter>
+ <Filter
+ Name="Grizzly Hills"
+ >
+ </Filter>
+ <Filter
+ Name="Icecrown"
+ >
+ </Filter>
+ <Filter
+ Name="Sholazar Basin"
+ >
+ </Filter>
+ <Filter
+ Name="The Storm Peaks"
+ >
+ </Filter>
+ <Filter
+ Name="Zul&apos;Drak"
+ >
+ </Filter>
+ <Filter
+ Name="Azjol-Nerub"
+ >
+ <Filter
+ Name="Ahn&apos;kahet"
+ >
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_amanitar.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_elder_nadox.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_herald_volazj.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_jedoga_shadowseeker.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_prince_taldaram.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\def_ahnkahet.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\instance_ahnkahet.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Azjol-Nerub"
+ >
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\boss_anubarak.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\boss_hadronox.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\boss_krikthir_the_gatewatcher.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\def_azjol_nerub.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\instance_azjol_nerub.cpp"
+ >
+ </File>
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Drak&apos;Tharon Keep"
+ >
+ </Filter>
+ <Filter
+ Name="Gundrak"
+ >
+ </Filter>
+ <Filter
+ Name="Nexus"
+ >
+ <Filter
+ Name="Nexus"
+ >
+ </Filter>
+ <Filter
+ Name="Oculus"
+ >
+ </Filter>
+ <Filter
+ Name="Eye of Eternity"
+ >
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Violet Hold"
+ >
+ </Filter>
+ <Filter
+ Name="Ulduar"
+ >
+ <Filter
+ Name="Halls of Stone"
+ >
+ </Filter>
+ <Filter
+ Name="Halls of Lightning"
+ >
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Utgarde Keep"
+ >
+ <Filter
+ Name="Utgarde Keep"
+ >
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_ingvar_the_plunderer.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_keleseth.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_skarvald_dalronn.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\def_utgarde_keep.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\instance_utgarde_keep.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Utgarde Pinnacle"
+ >
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Obsidian Sanctum"
+ >
+ </Filter>
+ <Filter
+ Name="Vault of Archavon"
+ >
+ </Filter>
+ <Filter
Name="Scarlet Monastery"
>
<File
@@ -849,10 +1037,6 @@
>
</File>
<File
- RelativePath="..\scripts\zone\naxxramas\boss_highlord_mograine.cpp"
- >
- </File>
- <File
RelativePath="..\scripts\zone\naxxramas\boss_kelthuzad.cpp"
>
</File>
@@ -908,6 +1092,10 @@
RelativePath="..\scripts\zone\razorfen_downs\boss_amnennar_the_coldbringer.cpp"
>
</File>
+ <File
+ RelativePath="..\scripts\zone\razorfen_downs\razorfen_downs.cpp"
+ >
+ </File>
</Filter>
<Filter
Name="Shadowfang Keep"
@@ -1073,9 +1261,9 @@
Name="Thousand Needles"
>
<File
- RelativePath="..\scripts\zone\thousand_needles\thousand_needles.cpp"
- >
- </File>
+ RelativePath="..\scripts\zone\thousand_needles\thousand_needles.cpp"
+ >
+ </File>
</Filter>
<Filter
Name="Silithus"
@@ -1237,9 +1425,9 @@
Name="Un&apos;Goro Crater"
>
<File
- RelativePath="..\scripts\zone\ungoro_crater\ungoro_crater.cpp"
- >
- </File>
+ RelativePath="..\scripts\zone\ungoro_crater\ungoro_crater.cpp"
+ >
+ </File>
</Filter>
<Filter
Name="Aunchindoun"
@@ -1464,11 +1652,11 @@
>
</File>
<File
- RelativePath="..\scripts\zone\hellfire_citadel\hellfire_ramparts\boss_watchkeeper_gargolmar.cpp"
+ RelativePath="..\scripts\zone\hellfire_citadel\hellfire_ramparts\boss_vazruden_the_herald.cpp"
>
</File>
<File
- RelativePath="..\scripts\zone\hellfire_citadel\hellfire_ramparts\boss_vazruden_the_herald.cpp"
+ RelativePath="..\scripts\zone\hellfire_citadel\hellfire_ramparts\boss_watchkeeper_gargolmar.cpp"
>
</File>
</Filter>
@@ -1934,6 +2122,10 @@
</Filter>
<Filter
+ Name="Culling of Stratholme"
+ >
+ </Filter>
+ <Filter
Name="Old Hillsbrad"
>
<File
@@ -2142,21 +2334,13 @@
>
</File>
<File
- RelativePath="..\scripts\zone\blackrock_depths\def_blackrock_depths.h"
- >
- </File>
- <File
- RelativePath="..\scripts\zone\blackrock_depths\instance_blackrock_depths.cpp"
- >
- </File>
- <File
RelativePath="..\scripts\zone\blackrock_depths\boss_ambassador_flamelash.cpp"
>
- </File>
+ </File>
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_anubshiah.cpp"
>
- </File>
+ </File>
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_emperor_dagran_thaurissan.cpp"
>
@@ -2164,7 +2348,7 @@
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_general_angerforge.cpp"
>
- </File>
+ </File>
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_gorosh_the_dervish.cpp"
>
@@ -2172,7 +2356,7 @@
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_grizzle.cpp"
>
- </File>
+ </File>
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_high_interrogator_gerstahn.cpp"
>
@@ -2184,11 +2368,19 @@
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_moira_bronzebeard.cpp"
>
- </File>
+ </File>
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_tomb_of_seven.cpp"
>
</File>
+ <File
+ RelativePath="..\scripts\zone\blackrock_depths\def_blackrock_depths.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\blackrock_depths\instance_blackrock_depths.cpp"
+ >
+ </File>
</Filter>
<Filter
Name="Loch Modan"
@@ -2249,10 +2441,6 @@
</File>
</Filter>
<File
- RelativePath="..\config.h"
- >
- </File>
- <File
RelativePath="..\ScriptMgr.cpp"
>
</File>
@@ -2261,10 +2449,6 @@
>
</File>
<File
- RelativePath="..\svn_revision.h"
- >
- </File>
- <File
RelativePath="..\system.cpp"
>
</File>
diff --git a/src/bindings/scripts/VC80/80ScriptDev2.vcproj b/src/bindings/scripts/VC80/80ScriptDev2.vcproj
index fcec093ee91..b10552f9f57 100644
--- a/src/bindings/scripts/VC80/80ScriptDev2.vcproj
+++ b/src/bindings/scripts/VC80/80ScriptDev2.vcproj
@@ -47,15 +47,15 @@
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..\..\..\..\dep\include\;..\..\..\shared\;..\..\..\framework\;..\..\..\game\;..\include\;..\..\..\..\dep\ACE_wrappers"
- PreprocessorDefinitions="WIN32;_DEBUG;MANGOS_DEBUG;_WINDOWS;_USRDLL;SCRIPT"
+ PreprocessorDefinitions="WIN32;_DEBUG;TRINITY_DEBUG;_WINDOWS;_USRDLL;SCRIPT"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
UsePrecompiledHeader="2"
PrecompiledHeaderThrough="precompiled.h"
WarningLevel="3"
- Detect64BitPortabilityProblems="true"
- DebugInformationFormat="4"
+ Detect64BitPortabilityProblems="false"
+ DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
@@ -73,7 +73,7 @@
LinkIncremental="2"
AdditionalLibraryDirectories="..\..\..\..\win\VC80\zthread__$(PlatformName)_$(ConfigurationName);..\..\..\..\win\VC80\trinitycore__$(PlatformName)_$(ConfigurationName)"
GenerateDebugInformation="true"
- ProgramDatabaseFile="$(OutDir)/MaNGOSScript.pdb"
+ ProgramDatabaseFile="$(OutDir)/TrinityScript.pdb"
SubSystem="2"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
@@ -215,7 +215,7 @@
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..\..\..\..\dep\include\;..\..\..\shared\;..\..\..\framework\;..\..\..\game\;..\include\;..\..\..\..\dep\ACE_wrappers"
- PreprocessorDefinitions="WIN32;_DEBUG;MANGOS_DEBUG;_WINDOWS;_USRDLL;SCRIPT"
+ PreprocessorDefinitions="WIN32;_DEBUG;TRINITY_DEBUG;_WINDOWS;_USRDLL;SCRIPT"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
@@ -241,7 +241,7 @@
LinkIncremental="2"
AdditionalLibraryDirectories="..\..\..\..\win\VC80\zthread__$(PlatformName)_$(ConfigurationName);..\..\..\..\win\VC80\trinitycore__$(PlatformName)_$(ConfigurationName)"
GenerateDebugInformation="true"
- ProgramDatabaseFile="$(OutDir)/MaNGOSScript.pdb"
+ ProgramDatabaseFile="$(OutDir)/TrinityScript.pdb"
SubSystem="2"
ImportLibrary="$(OutDir)/TrinityScript.lib"
TargetMachine="17"
@@ -387,23 +387,35 @@
Name="creature"
>
<File
- RelativePath="..\scripts\creature\mob_event_ai.cpp"
+ RelativePath="..\scripts\creature\mob_generic_creature.cpp"
>
</File>
<File
- RelativePath="..\scripts\creature\mob_event_ai.h"
+ RelativePath="..\scripts\creature\simple_ai.cpp"
>
</File>
<File
- RelativePath="..\scripts\creature\mob_generic_creature.cpp"
+ RelativePath="..\scripts\creature\simple_ai.h"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="examples"
+ >
+ <File
+ RelativePath="..\scripts\examples\example_creature.cpp"
>
</File>
<File
- RelativePath="..\scripts\creature\simple_ai.cpp"
+ RelativePath="..\scripts\examples\example_escort.cpp"
>
</File>
<File
- RelativePath="..\scripts\creature\simple_ai.h"
+ RelativePath="..\scripts\examples\example_gossip_codebox.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\examples\example_misc.cpp"
>
</File>
</Filter>
@@ -458,18 +470,6 @@
<Filter
Name="custom"
>
- <File
- RelativePath="..\scripts\custom\custom_example.cpp"
- >
- </File>
- <File
- RelativePath="..\scripts\custom\custom_gossip_codebox.cpp"
- >
- </File>
- <File
- RelativePath="..\scripts\custom\test.cpp"
- >
- </File>
</Filter>
<Filter
Name="areatrigger"
@@ -494,10 +494,6 @@
RelativePath="..\scripts\item\item_scripts.cpp"
>
</File>
- <File
- RelativePath="..\scripts\item\item_test.cpp"
- >
- </File>
</Filter>
<Filter
Name="zone"
@@ -755,6 +751,190 @@
>
</Filter>
<Filter
+ Name="Borean Tundra"
+ >
+ <File
+ RelativePath="..\scripts\zone\borean_tundra\borean_tundra.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Howling Fjord"
+ >
+ </Filter>
+ <Filter
+ Name="Crystalsong Forest"
+ >
+ </Filter>
+ <Filter
+ Name="Dalaran"
+ >
+ </Filter>
+ <Filter
+ Name="Dragonblight"
+ >
+ </Filter>
+ <Filter
+ Name="Grizzly Hills"
+ >
+ </Filter>
+ <Filter
+ Name="Icecrown"
+ >
+ </Filter>
+ <Filter
+ Name="Sholazar Basin"
+ >
+ </Filter>
+ <Filter
+ Name="The Storm Peaks"
+ >
+ </Filter>
+ <Filter
+ Name="Zul&apos;Drak"
+ >
+ </Filter>
+ <Filter
+ Name="Azjol-Nerub"
+ >
+ <Filter
+ Name="Ahn&apos;kahet"
+ >
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_amanitar.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_elder_nadox.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_herald_volazj.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_jedoga_shadowseeker.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_prince_taldaram.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\def_ahnkahet.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\instance_ahnkahet.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Azjol-Nerub"
+ >
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\boss_anubarak.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\boss_hadronox.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\boss_krikthir_the_gatewatcher.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\def_azjol_nerub.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\instance_azjol_nerub.cpp"
+ >
+ </File>
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Drak&apos;Tharon Keep"
+ >
+ </Filter>
+ <Filter
+ Name="Gundrak"
+ >
+ </Filter>
+ <Filter
+ Name="Nexus"
+ >
+ <Filter
+ Name="Nexus"
+ >
+ </Filter>
+ <Filter
+ Name="Oculus"
+ >
+ </Filter>
+ <Filter
+ Name="Eye of Eternity"
+ >
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Violet Hold"
+ >
+ </Filter>
+ <Filter
+ Name="Ulduar"
+ >
+ <Filter
+ Name="Halls of Stone"
+ >
+ </Filter>
+ <Filter
+ Name="Halls of Lightning"
+ >
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Utgarde Keep"
+ >
+ <Filter
+ Name="Utgarde Keep"
+ >
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_ingvar_the_plunderer.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_keleseth.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_skarvald_dalronn.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\def_utgarde_keep.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\instance_utgarde_keep.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Utgarde Pinnacle"
+ >
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Obsidian Sanctum"
+ >
+ </Filter>
+ <Filter
+ Name="Vault of Archavon"
+ >
+ </Filter>
+ <Filter
Name="Scarlet Monastery"
>
<File
@@ -1026,10 +1206,6 @@
>
</File>
<File
- RelativePath="..\scripts\zone\naxxramas\boss_highlord_mograine.cpp"
- >
- </File>
- <File
RelativePath="..\scripts\zone\naxxramas\boss_kelthuzad.cpp"
>
</File>
@@ -1085,6 +1261,10 @@
RelativePath="..\scripts\zone\razorfen_downs\boss_amnennar_the_coldbringer.cpp"
>
</File>
+ <File
+ RelativePath="..\scripts\zone\razorfen_downs\razorfen_downs.cpp"
+ >
+ </File>
</Filter>
<Filter
Name="Shadowfang Keep"
@@ -1250,9 +1430,9 @@
Name="Thousand Needles"
>
<File
- RelativePath="..\scripts\zone\thousand_needles\thousand_needles.cpp"
- >
- </File>
+ RelativePath="..\scripts\zone\thousand_needles\thousand_needles.cpp"
+ >
+ </File>
</Filter>
<Filter
Name="Silithus"
@@ -1414,9 +1594,9 @@
Name="Un&apos;Goro Crater"
>
<File
- RelativePath="..\scripts\zone\ungoro_crater\ungoro_crater.cpp"
- >
- </File>
+ RelativePath="..\scripts\zone\ungoro_crater\ungoro_crater.cpp"
+ >
+ </File>
</Filter>
<Filter
Name="Aunchindoun"
@@ -1641,11 +1821,11 @@
>
</File>
<File
- RelativePath="..\scripts\zone\hellfire_citadel\hellfire_ramparts\boss_watchkeeper_gargolmar.cpp"
+ RelativePath="..\scripts\zone\hellfire_citadel\hellfire_ramparts\boss_vazruden_the_herald.cpp"
>
</File>
<File
- RelativePath="..\scripts\zone\hellfire_citadel\hellfire_ramparts\boss_vazruden_the_herald.cpp"
+ RelativePath="..\scripts\zone\hellfire_citadel\hellfire_ramparts\boss_watchkeeper_gargolmar.cpp"
>
</File>
</Filter>
@@ -2111,6 +2291,10 @@
</Filter>
<Filter
+ Name="Culling of Stratholme"
+ >
+ </Filter>
+ <Filter
Name="Old Hillsbrad"
>
<File
@@ -2319,21 +2503,13 @@
>
</File>
<File
- RelativePath="..\scripts\zone\blackrock_depths\def_blackrock_depths.h"
- >
- </File>
- <File
- RelativePath="..\scripts\zone\blackrock_depths\instance_blackrock_depths.cpp"
- >
- </File>
- <File
RelativePath="..\scripts\zone\blackrock_depths\boss_ambassador_flamelash.cpp"
>
- </File>
+ </File>
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_anubshiah.cpp"
>
- </File>
+ </File>
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_emperor_dagran_thaurissan.cpp"
>
@@ -2341,7 +2517,7 @@
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_general_angerforge.cpp"
>
- </File>
+ </File>
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_gorosh_the_dervish.cpp"
>
@@ -2349,7 +2525,7 @@
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_grizzle.cpp"
>
- </File>
+ </File>
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_high_interrogator_gerstahn.cpp"
>
@@ -2361,11 +2537,19 @@
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_moira_bronzebeard.cpp"
>
- </File>
+ </File>
<File
RelativePath="..\scripts\zone\blackrock_depths\boss_tomb_of_seven.cpp"
>
</File>
+ <File
+ RelativePath="..\scripts\zone\blackrock_depths\def_blackrock_depths.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\blackrock_depths\instance_blackrock_depths.cpp"
+ >
+ </File>
</Filter>
<Filter
Name="Loch Modan"
@@ -2442,10 +2626,6 @@
</File>
</Filter>
<File
- RelativePath="..\config.h"
- >
- </File>
- <File
RelativePath="..\ScriptMgr.cpp"
>
</File>
@@ -2454,10 +2634,6 @@
>
</File>
<File
- RelativePath="..\svn_revision.h"
- >
- </File>
- <File
RelativePath="..\system.cpp"
>
</File>
diff --git a/src/bindings/scripts/VC90/90ScriptDev2.vcproj b/src/bindings/scripts/VC90/90ScriptDev2.vcproj
index 7cf04d191ed..4ae4f14eb33 100644
--- a/src/bindings/scripts/VC90/90ScriptDev2.vcproj
+++ b/src/bindings/scripts/VC90/90ScriptDev2.vcproj
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="windows-1250"?>
<VisualStudioProject
ProjectType="Visual C++"
- Version="9,00"
+ Version="9.00"
Name="TrinityScript"
ProjectGUID="{4295C8A9-79B7-4354-8064-F05FB9CA0C96}"
RootNamespace="ScriptDev2"
@@ -47,7 +47,7 @@
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..\..\..\..\dep\include\;..\..\..\shared\;..\..\..\framework\;..\..\..\game\;..\include\;..\..\..\..\dep\ACE_wrappers"
- PreprocessorDefinitions="WIN32;_DEBUG;MANGOS_DEBUG;_WINDOWS;_USRDLL;SCRIPT"
+ PreprocessorDefinitions="WIN32;_DEBUG;TRINITY_DEBUG;_WINDOWS;_USRDLL;SCRIPT"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
@@ -55,7 +55,7 @@
PrecompiledHeaderThrough="precompiled.h"
WarningLevel="3"
Detect64BitPortabilityProblems="false"
- DebugInformationFormat="4"
+ DebugInformationFormat="3"
/>
<Tool
Name="VCManagedResourceCompilerTool"
@@ -73,7 +73,7 @@
LinkIncremental="2"
AdditionalLibraryDirectories="..\..\..\..\win\VC90\zthread__$(PlatformName)_$(ConfigurationName);..\..\..\..\win\VC90\trinitycore__$(PlatformName)_$(ConfigurationName)"
GenerateDebugInformation="true"
- ProgramDatabaseFile="$(OutDir)/MaNGOSScript.pdb"
+ ProgramDatabaseFile="$(OutDir)/TrinityScript.pdb"
SubSystem="2"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
@@ -216,7 +216,7 @@
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..\..\..\..\dep\include\;..\..\..\shared\;..\..\..\framework\;..\..\..\game\;..\include\;..\..\..\..\dep\ACE_wrappers"
- PreprocessorDefinitions="WIN32;_DEBUG;MANGOS_DEBUG;_WINDOWS;_USRDLL;SCRIPT"
+ PreprocessorDefinitions="WIN32;_DEBUG;TRINITY_DEBUG;_WINDOWS;_USRDLL;SCRIPT"
MinimalRebuild="true"
BasicRuntimeChecks="3"
RuntimeLibrary="3"
@@ -242,7 +242,7 @@
LinkIncremental="2"
AdditionalLibraryDirectories="..\..\..\..\win\VC90\zthread__$(PlatformName)_$(ConfigurationName);..\..\..\..\win\VC90\trinitycore__$(PlatformName)_$(ConfigurationName)"
GenerateDebugInformation="true"
- ProgramDatabaseFile="$(OutDir)/MaNGOSScript.pdb"
+ ProgramDatabaseFile="$(OutDir)/TrinityScript.pdb"
SubSystem="2"
RandomizedBaseAddress="1"
DataExecutionPrevention="0"
@@ -267,6 +267,9 @@
<Tool
Name="VCAppVerifierTool"
/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
</Configuration>
<Configuration
Name="Release|x64"
@@ -348,6 +351,9 @@
<Tool
Name="VCAppVerifierTool"
/>
+ <Tool
+ Name="VCPostBuildEventTool"
+ />
</Configuration>
</Configurations>
<References>
@@ -380,23 +386,35 @@
Name="creature"
>
<File
- RelativePath="..\scripts\creature\mob_event_ai.cpp"
+ RelativePath="..\scripts\creature\mob_generic_creature.cpp"
>
</File>
<File
- RelativePath="..\scripts\creature\mob_event_ai.h"
+ RelativePath="..\scripts\creature\simple_ai.cpp"
>
</File>
<File
- RelativePath="..\scripts\creature\mob_generic_creature.cpp"
+ RelativePath="..\scripts\creature\simple_ai.h"
>
</File>
+ </Filter>
+ <Filter
+ Name="examples"
+ >
<File
- RelativePath="..\scripts\creature\simple_ai.cpp"
+ RelativePath="..\scripts\examples\example_creature.cpp"
>
</File>
<File
- RelativePath="..\scripts\creature\simple_ai.h"
+ RelativePath="..\scripts\examples\example_escort.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\examples\example_gossip_codebox.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\examples\example_misc.cpp"
>
</File>
</Filter>
@@ -452,15 +470,11 @@
Name="custom"
>
<File
- RelativePath="..\scripts\custom\custom_example.cpp"
- >
- </File>
- <File
- RelativePath="..\scripts\custom\custom_gossip_codebox.cpp"
+ RelativePath="..\scripts\custom\npc_acherus_taxi.cpp"
>
</File>
<File
- RelativePath="..\scripts\custom\test.cpp"
+ RelativePath="..\scripts\custom\npc_wyrmresttempel_taxi.cpp"
>
</File>
</Filter>
@@ -487,10 +501,6 @@
RelativePath="..\scripts\item\item_scripts.cpp"
>
</File>
- <File
- RelativePath="..\scripts\item\item_test.cpp"
- >
- </File>
</Filter>
<Filter
Name="zone"
@@ -748,6 +758,438 @@
>
</Filter>
<Filter
+ Name="Borean Tundra"
+ >
+ <File
+ RelativePath="..\scripts\zone\borean_tundra\borean_tundra.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Howling Fjord"
+ >
+ </Filter>
+ <Filter
+ Name="Crystalsong Forest"
+ >
+ </Filter>
+ <Filter
+ Name="Dalaran"
+ >
+ </Filter>
+ <Filter
+ Name="Dragonblight"
+ >
+ </Filter>
+ <Filter
+ Name="Grizzly Hills"
+ >
+ </Filter>
+ <Filter
+ Name="Icecrown"
+ >
+ </Filter>
+ <Filter
+ Name="Sholazar Basin"
+ >
+ </Filter>
+ <Filter
+ Name="The Storm Peaks"
+ >
+ </Filter>
+ <Filter
+ Name="Zul&apos;Drak"
+ >
+ </Filter>
+ <Filter
+ Name="Azjol-Nerub"
+ >
+ <Filter
+ Name="Ahn&apos;kahet"
+ >
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_amanitar.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_elder_nadox.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_herald_volazj.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_jedoga_shadowseeker.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\boss_prince_taldaram.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\def_ahnkahet.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\ahnkahet\instance_ahnkahet.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Azjol-Nerub"
+ >
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\boss_anubarak.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\boss_hadronox.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\boss_krikthir_the_gatewatcher.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\def_azjol_nerub.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\azjol_nerub\azjol_nerub\instance_azjol_nerub.cpp"
+ >
+ </File>
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Drak&apos;Tharon Keep"
+ >
+ <File
+ RelativePath="..\scripts\zone\draktharon_keep\boss_dred.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\draktharon_keep\boss_novos.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\draktharon_keep\boss_tharon_ja.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\draktharon_keep\boss_trollgore.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\draktharon_keep\def_drak_tharon_keep.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\draktharon_keep\instance_drak_tharon_keep.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Gundrak"
+ >
+ <File
+ RelativePath="..\scripts\zone\gundrak\boss_drakkari_colossus.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\gundrak\boss_eck.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\gundrak\boss_gal_darah.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\gundrak\boss_moorabi.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\gundrak\boss_slad_ran.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\gundrak\def_gundrak.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\gundrak\instance_gundrak.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Nexus"
+ >
+ <Filter
+ Name="Nexus"
+ >
+ <File
+ RelativePath="..\scripts\zone\nexus\nexus\boss_anomalus.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\nexus\boss_keristrasza.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\nexus\boss_magus_telestra.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\nexus\boss_ormorok.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\nexus\commander_kolurg.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\nexus\commander_stoutbeard.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\nexus\def_nexus.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\nexus\instance_nexus.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Oculus"
+ >
+ <File
+ RelativePath="..\scripts\zone\nexus\oculus\boss_drakos.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\oculus\boss_eregos.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\oculus\boss_urom.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\oculus\boss_varos.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\oculus\def_oculus.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\oculus\instance_oculus.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Eye of Eternity"
+ >
+ <File
+ RelativePath="..\scripts\zone\nexus\eye_of_eternity\boss_malygos.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\eye_of_eternity\def_eye_of_eternity.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\nexus\eye_of_eternity\instance_eye_of_eternity.cpp"
+ >
+ </File>
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Violet Hold"
+ >
+ <File
+ RelativePath="..\scripts\zone\violet_hold\boss_cyanigosa.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\violet_hold\boss_erekem.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\violet_hold\boss_ichoron.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\violet_hold\boss_lavanthor.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\violet_hold\boss_moragg.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\violet_hold\boss_xevozz.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\violet_hold\boss_zuramat.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\violet_hold\def_violet_hold.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\violet_hold\instance_violet_hold.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Ulduar"
+ >
+ <Filter
+ Name="Halls of Stone"
+ >
+ <File
+ RelativePath="..\scripts\zone\ulduar\halls_of_stone\boss_krystallus.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\ulduar\halls_of_stone\boss_maiden_of_grief.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\ulduar\halls_of_stone\boss_sjonnir.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\ulduar\halls_of_stone\def_halls_of_stone.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\ulduar\halls_of_stone\instance_halls_of_stone.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Halls of Lightning"
+ >
+ <File
+ RelativePath="..\scripts\zone\ulduar\halls_of_lightning\boss_bjarngrim.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\ulduar\halls_of_lightning\boss_ionar.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\ulduar\halls_of_lightning\boss_loken.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\ulduar\halls_of_lightning\boss_volkhan.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\ulduar\halls_of_lightning\def_halls_of_lightning.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\ulduar\halls_of_lightning\instance_halls_of_lightning.cpp"
+ >
+ </File>
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Utgarde Keep"
+ >
+ <Filter
+ Name="Utgarde Keep"
+ >
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_ingvar_the_plunderer.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_keleseth.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\boss_skarvald_dalronn.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\def_utgarde_keep.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_keep\instance_utgarde_keep.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Utgarde Pinnacle"
+ >
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_pinnacle\boss_palehoof.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_pinnacle\boss_skadi.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_pinnacle\boss_svala.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_pinnacle\boss_ymiron.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_pinnacle\def_pinnacle.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\utgarde_keep\utgarde_pinnacle\instance_pinnacle.cpp"
+ >
+ </File>
+ </Filter>
+ </Filter>
+ <Filter
+ Name="Obsidian Sanctum"
+ >
+ <File
+ RelativePath="..\scripts\zone\obsidian_sanctum\boss_sartharion.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\obsidian_sanctum\def_obsidian_sanctum.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\obsidian_sanctum\instance_obsidian_sanctum.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
+ Name="Vault of Archavon"
+ >
+ <File
+ RelativePath="..\scripts\zone\vault_of_archavon\boss_archavon.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\vault_of_archavon\def_vault_of_archavon.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\vault_of_archavon\instance_vault_of_archavon.cpp"
+ >
+ </File>
+ </Filter>
+ <Filter
Name="Scarlet Monastery"
>
<File
@@ -1019,10 +1461,6 @@
>
</File>
<File
- RelativePath="..\scripts\zone\naxxramas\boss_highlord_mograine.cpp"
- >
- </File>
- <File
RelativePath="..\scripts\zone\naxxramas\boss_kelthuzad.cpp"
>
</File>
@@ -1078,6 +1516,10 @@
RelativePath="..\scripts\zone\razorfen_downs\boss_amnennar_the_coldbringer.cpp"
>
</File>
+ <File
+ RelativePath="..\scripts\zone\razorfen_downs\razorfen_downs.cpp"
+ >
+ </File>
</Filter>
<Filter
Name="Shadowfang Keep"
@@ -2102,7 +2544,34 @@
>
</File>
</Filter>
-
+ <Filter
+ Name="Culling of Stratholme"
+ >
+ <File
+ RelativePath="..\scripts\zone\caverns_of_time\culling_of_stratholme\boss_epoch.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\caverns_of_time\culling_of_stratholme\boss_mal_ganis.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\caverns_of_time\culling_of_stratholme\boss_meathook.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\caverns_of_time\culling_of_stratholme\boss_salramm.cpp"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\caverns_of_time\culling_of_stratholme\def_culling_of_stratholme.h"
+ >
+ </File>
+ <File
+ RelativePath="..\scripts\zone\caverns_of_time\culling_of_stratholme\instance_culling_of_stratholme.cpp"
+ >
+ </File>
+ </Filter>
<Filter
Name="Old Hillsbrad"
>
@@ -2435,10 +2904,6 @@
</File>
</Filter>
<File
- RelativePath="..\config.h"
- >
- </File>
- <File
RelativePath="..\ScriptMgr.cpp"
>
</File>
@@ -2447,10 +2912,6 @@
>
</File>
<File
- RelativePath="..\svn_revision.h"
- >
- </File>
- <File
RelativePath="..\system.cpp"
>
</File>
diff --git a/src/bindings/scripts/docs/EventAI.txt b/src/bindings/scripts/docs/EventAI.txt
index 37064b63e8b..3dac5c271e8 100644
--- a/src/bindings/scripts/docs/EventAI.txt
+++ b/src/bindings/scripts/docs/EventAI.txt
@@ -42,7 +42,7 @@ action3_param3
All params are signed 32 bit values (+/- 2147483647). If param specifies time then time is in milliseconds. If param specifies percentage then percentages are value/100 (ex: if param = 500 then that means 500%, -50 = -50%)
-*Phase mask is a bit mask of which phases this event should not trigger in. Example: Phase mask value of 12 (1100) would mean that this event would trigger 0, 1 and all other phases except for 2 and 3 (0 counts as the first phase).
+*Phase mask is a bit mask of which phases this event should not trigger in. Example: Phase mask value of 12 (1100) would mean that this event would trigger 0, 1 and all other phases except for 2 and 3 (0 counts as the first phase).
=========================================
Event Types
@@ -56,22 +56,24 @@ Events will not repeat until the creature exits combat unless EFLAG_REPEATABLE i
-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
0 EVENT_T_TIMER InitialMin, InitialMax, RepeatMin, RepeatMax Expires first between (Param1) and (Param2) and then between every (Param3) and (Param4). but only in combat.
1 EVENT_T_TIMER_OOC InitialMin, InitialMax, RepeatMin, RepeatMax Expires first between (Param1) and (Param2) and then between every (Param3) and (Param4). but only out of combat.
-2 EVENT_T_HP HPMax%, HPMin%, RepeatMin, RepeatMax Expires when HP is between (Param1) and (Param2). Will repeat every (Param3) and (Param4).
-3 EVENT_T_MANA ManaMax%,ManaMin% RepeatMin, RepeatMax Expires once Mana% is between (Param1) and (Param2). Will repeat every (Param3) and (Param4).
-4 EVENT_T_AGGRO NONE Expires upon initial aggro (does not repeat).
+2 EVENT_T_HP HPMax%, HPMin%, RepeatMin, RepeatMax Expires when HP is between (Param1) and (Param2). Will repeat every (Param3) and (Param4).
+3 EVENT_T_MANA ManaMax%,ManaMin% RepeatMin, RepeatMax Expires once Mana% is between (Param1) and (Param2). Will repeat every (Param3) and (Param4).
+4 EVENT_T_AGGRO NONE Expires upon initial aggro (does not repeat).
5 EVENT_T_KILL RepeatMin, RepeatMax Expires upon killing a player. Will repeat between every (Param1) and (Param2).
-6 EVENT_T_DEATH NONE Expires upon Death of the Creature.
+6 EVENT_T_DEATH NONE Expires upon Death of the Creature.
7 EVENT_T_EVADE NONE Expires upon creature EnterEvadeMode().
8 EVENT_T_SPELLHIT SpellID, School, RepeatMin, RepeatMax Expires upon Spell hit. If (param1) is set will only expire on that spell. If (param2) will only expire on spells of that school (-1 for all). Will repeat every (Param3) and (Param4) .
9 EVENT_T_RANGE MinDist, MaxDist, RepeatMin, RepeatMax Expires when the highest threat target distance is greater than (Param1) and less than (Param2). Will repeat every (Param3) and (Param4) .
-10 EVENT_T_OOC_LOS NoHostile, NoFriendly, RepeatMin, RepeatMax Expires when a Player moves within visible distance to creature. Does not expire for Hostile Players if (Param1) is not 0. Does not expire for Friendly Players if (Param2) is not 0. Will repeat every (Param3) and (Param4) . Does not expire for creatures or pet or when the creature is in combat.
+10 EVENT_T_OOC_LOS Hostile-or-Not, MaxAllowedRange, RepeatMin, RepeatMax Expires when a Unit moves within distance(MaxAllowedRange) to creature. If Param1=0 it will expire if Unit are Hostile. If Param1=1 it will only expire if Unit are not Hostile(generally determined by faction). Will repeat every (Param3) and (Param4). Does not expire when the creature is in combat.
11 EVENT_T_SPAWNED NONE Expires at initial spawn and at creature respawn (useful for setting ranged movement type)
-12 EVENT_T_TARGET_HP HPMax%, HPMin%, RepeatMin, RepeatMax Expires when Current Target's HP is between (Param1) and (Param2). Will repeat every (Param3) and (Param4) .
+12 EVENT_T_TARGET_HP HPMax%, HPMin%, RepeatMin, RepeatMax Expires when Current Target's HP is between (Param1) and (Param2). Will repeat every (Param3) and (Param4) .
13 EVENT_T_TARGET_CASTING RepeatMin, RepeatatMax Expires when the current target is casting a spell. Will repeat every (Param1) and (Param2) .
14 EVENT_T_FRIENDLY_HP HPDeficit, Radius, RepeatMin, RepeatMax Expires when a friendly unit in radius has at least (param1) hp missing. Will repeat every (Param3) and (Param4) .
15 EVENT_T_FRIENDLY_IS_CC DispelType, Radius, RepeatMin, RepeatMax Expires when a friendly unit is Crowd controlled within the given radius (param2). Will repeat every (Param3) and (Param4) .
16 EVENT_T_MISSING_BUFF SpellId, Radius, RepeatMin, RepeatMax Expires when a friendly unit is missing aura's given by spell (param1) within radius (param2). Will repeat every (Param3) and (Param4) .
-17 EVENT_T_SUMMONED_UNIT CreatureId, RepeatMin, RepeatMax Expires after creature with entry = (param1) is spawned or for all spawns if param1 = 0. Will repeat every (Param2) and (Param3) .
+17 EVENT_T_SUMMONED_UNIT CreatureId, RepeatMin, RepeatMax Expires after creature with entry = (param1) is spawned or for all spawns if param1 = 0. Will repeat every (Param2) and (Param3).
+18 EVENT_T_TARGET_MANA ManaMax%, ManaMin%, RepeatMin, RepeatMax
+21 EVENT_T_REACHED_HOME NONE Expires when creature reach it's home(spawn) location after Evade.
=========================================
Action Types
@@ -83,8 +85,8 @@ Params are always read from Param1, then Param2, then Param3.
(# Internal Name Param usage Discription)
0 ACTION_T_NONE No Action Does Nothing
1 ACTION_T_TEXT -TextId1, -TextId2, -TextId3 Displays the -TextId as defined. In case -TextId2 and optionally -TextId3, the output will be randomized. Type text are defined in the text table itself(say, yell, whisper, etc) along with other options for the text. All values are required to be negative.
-2 ACTION_T_YELL UNUSED
-3 ACTION_T_TEXTEMOTE UNUSED
+2 ACTION_T_SET_FACTION FactionId Change faction for creature. If param1==0, creature will revert to default faction.
+3 ACTION_T_MORPH_TO_ENTRY_OR_MODEL CreatureEntry, ModelId Set model from creature_template.entry(param1) OR set explicit modelId(param2). If param1 AND param2 both 0, demorph and revert to default model for creature.
4 ACTION_T_SOUND SoundId Plays Sound
5 ACTION_T_EMOTE EmoteId Does emote
6 ACTION_T_RANDOM_SAY UNUSED
@@ -93,7 +95,7 @@ Params are always read from Param1, then Param2, then Param3.
9 ACTION_T_RANDOM_SOUND SoundId1, SoundId2, SoundId3 Plays random sound between 3 params*
10 ACTION_T_RANDOM_EMOTE EmoteId1, EmoteId2, EmoteId3 Emotes random emote between 3 params
11 ACTION_T_CAST SpellId, Target, CastFlags Casts spell (param1) on target type (param2). Uses Cast Flags (specified below target types)
-12 ACTION_T_SUMMON CreatureID, Target, Duration Summons creature (param1) to attack target (param2) for (param3) duration. Spawns on top of current creature.
+12 ACTION_T_SUMMON CreatureID, Target, Duration Summons creature (param1) to attack target (param2) for (param3) duration. Spawns on top of current creature.
13 ACTION_T_THREAT_SINGLE_PCT Threat%, Target Modifies threat by (param1) on target type (param2)
14 ACTION_T_THREAT_ALL_PCT Threat% Modifies threat by (param1) on all targets (using -100% on all will result in full aggro dump)
15 ACTION_T_QUEST_EVENT QuestID, Target Calls AreaExploredOrEventHappens with (param1) for target type (Param2)
@@ -113,7 +115,7 @@ Params are always read from Param1, then Param2, then Param3.
29 ACTION_T_RANGED_MOVEMENT Distance, Angle Changes the movement generator type to a ranged type. Note: Default melee type can still be done with this. Specify 0 angle and 0 distance.
30 ACTION_T_RANDOM_PHASE PhaseId1, PhaseId2, PhaseId3 Sets the phase to the id between 3 params*
31 ACTION_T_RANDOM_PHASE_RANGE PhaseMin, PhaseMax Sets the phase to a random id (Phase = PhaseMin + rnd % PhaseMin-PhaseMax). PhaseMax must be greater than PhaseMin.
-32 ACTION_T_SUMMON CreatureID, Target, SummonID Summons creature (param1) to attack target (param2) at location specified by EventAI_Summons (param3).
+32 ACTION_T_SUMMON CreatureID, Target, SummonID Summons creature (param1) to attack target (param2) at location specified by EventAI_Summons (param3).
33 ACTION_T_KILLED_MONSTER CreatureID, Target Calls KilledMonster (param1) for target of type (param2)
34 ACTION_T_SET_INST_DATA Field, Data Calls ScriptedInstance::SetData with field (param1) and data (param2)
35 ACTION_T_SET_INST_DATA64 Field, Target Calls ScriptedInstance::SetData64 with field (param1) and data (param2) target's GUID.
@@ -135,7 +137,7 @@ BOTH - This event can trigger both in and out of combat.
Events that do not have lables on them are events that are directly involved with the in and out of combat state.
------------------
-0 = EVENT_T_TIMER:
+0 = EVENT_T_TIMER:
------------------
Parameter 1: InitialMin - Minumum Time used to calculate Random Initial Expire
Parameter 2: InitialMax - Maximum Time used to calculate Random Initial Expire
@@ -153,7 +155,7 @@ Parameter 2: InitialMax - Maximum Time used to calculate Random Initial Expire
Parameter 3: RepeatMin - Minimum Time used to calculate Random Repeat Expire
Parameter 4: RepeatMax - Maximum Time used to calculate Random Repeat Expire
-OUT OF COMBAT ONLY! - Expires first between (Param1) and (Param2) and then between every (Param3) and (Param4) from then on.
+OUT OF COMBAT ONLY! - Expires first between (Param1) and (Param2) and then between every (Param3) and (Param4) from then on.
This is commonly used for events that occur and repeat outside of combat.
---------------
@@ -164,7 +166,7 @@ Parameter 2: HPMin% - Minimum HP% That this Event will Expire
Parameter 3: RepeatMin - Minimum Time used to calculate Random Repeat Expire
Parameter 4: RepeatMax - Maximum Time used to calculate Random Repeat Expire
-BOTH - Expires when HP is between (Param1) and (Param2). Will repeat every (Param3) and (Param4).
+BOTH - Expires when HP is between (Param1) and (Param2). Will repeat every (Param3) and (Param4).
This is commonly used for events that trigger at a specific HP% (Such as Heal/Enrage Spells or NPC's that Flee).
-----------------
@@ -175,7 +177,7 @@ Parameter 2: ManaMin% - Minimum Mana% That this Event will Expire
Parameter 3: RepeatMin - Minimum Time used to calculate Random Repeat Expire
Parameter 4: RepeatMax - Maximum Time used to calculate Random Repeat Expire
-BOTH - Expires once Mana% is between (Param1) and (Param2). Will repeat every (Param3) and (Param4).
+BOTH - Expires once Mana% is between (Param1) and (Param2). Will repeat every (Param3) and (Param4).
This is commonly used for events where an NPC low on Mana will do something (Such as stop casting spells and switch to melee).
------------------
@@ -189,7 +191,7 @@ This Event Expires upon initial aggro (does not repeat).
Parameter 1: RepeatMin - Minimum Time used to calculate Random Repeat Expire
Parameter 2: RepeatMax - Maximum Time used to calculate Random Repeat Expire
-COMBAT ONLY! - Expires upon killing a player. Will repeat every (Param1) and (Param2).
+COMBAT ONLY! - Expires upon killing a player. Will repeat every (Param1) and (Param2).
This Event Expires upon killing a player. It is commonly used for NPC's who yell or do something after killing a player.
------------------
@@ -201,7 +203,7 @@ This is commonly used for NPC's who have a yell on death or cast some kind if su
------------------
7 = EVENT_T_EVADE:
------------------
-This Event Expires upon the creature EnterEvadeMode().
+This Event Expires upon the creature EnterEvadeMode().
This is commonly used for NPC's who use phases, allows you to reset their phase to 0 upon evade to prevent possible strange behavior.
---------------------
@@ -224,7 +226,7 @@ Parameter 3: RepeatMin - Minimum Time used to calculate Random Repeat Expire
Parameter 4: RepeatMax - Maximum Time used to calculate Random Repeat Expire
COMBAT ONLY! - Expires when the highest threat target distance is greater than (Param1) and less than (Param2). Will repeat every (Param3) and (Param4).
-This Event is commonly used for NPC's who have Ranged Combat and will Throw/Shoot between a certian distance.
+This Event is commonly used for NPC's who have Ranged Combat and will Throw/Shoot between a certian distance.
---------------------
10 = EVENT_T_OOC_LOS:
@@ -234,7 +236,7 @@ Parameter 2: NoFriendly - This Value is to Prevent this Action from Expiring Whe
Parameter 3: RepeatMin - Minimum Time used to calculate Random Repeat Expire
Parameter 4: RepeatMax - Maximum Time used to calculate Random Repeat Expire
-OUT OF COMBAT ONLY! - Expires when a Player moves within visible distance to the NPC. Does not expire for Hostile Players if (Param1) is not 0. Does not expire for Friendly Players if (Param2) is not 0. Will repeat every (Param3) and (Param4). Does not expire for creatures or pets when they are in combat.
+OUT OF COMBAT ONLY! - Expires when a Player moves within visible distance to the NPC. Does not expire for Hostile Players if (Param1) is not 0. Does not expire for Friendly Players if (Param2) is not 0. Will repeat every (Param3) and (Param4). Does not expire for creatures or pets when they are in combat.
This Event is commonly used for NPC's who Do Something or Say Something when you walk past them Out of Combat.
---------------------
@@ -251,7 +253,7 @@ Parameter 2: HPMin% - Minimum HP% That this Event will Expire
Parameter 3: RepeatMin - Minimum Time used to calculate Random Repeat Expire
Parameter 4: RepeatMax - Maximum Time used to calculate Random Repeat Expire
-COMBAT ONLY! - Expires when Current NPC's Target's HP is between (Param1) and (Param2). Will repeat every (Param3) and (Param4).
+COMBAT ONLY! - Expires when Current NPC's Target's HP is between (Param1) and (Param2). Will repeat every (Param3) and (Param4).
This Event is commonly used for NPC's who have a special ability (Like Execute) that only casts when a Player HP is low.
----------------------------
@@ -260,7 +262,7 @@ This Event is commonly used for NPC's who have a special ability (Like Execute)
Parameter 1: RepeatMin - Minimum Time used to calculate Random Repeat Expire
Parameter 2: RepeatMax - Maximum Time used to calculate Random Repeat Expire
-COMBAT ONLY! - Expires when the current target is casting a spell. Will repeat every (Param1) and (Param2).
+COMBAT ONLY! - Expires when the current target is casting a spell. Will repeat every (Param1) and (Param2).
This event is commonly used for NPC's who will cast a counter spell when their target starts to cast a spell.
-------------------------
@@ -282,7 +284,7 @@ Parameter 2: Radius - This is the Range in Yards the NPC will scan for nearby Fr
Parameter 3: RepeatMin - Minimum Time used to calculate Random Repeat Expire
Parameter 4: RepeatMax - Maximum Time used to calculate Random Repeat Expire
-COMBAT ONLY! - Expires when a friendly unit is Crowd controlled within the given radius (param2). Will repeat every (Param3) and (Param4).
+COMBAT ONLY! - Expires when a friendly unit is Crowd controlled within the given radius (param2). Will repeat every (Param3) and (Param4).
This is commonly used for NPC's who can come to the resule of other Friendly NPC's if being Crowd Controlled
--------------------------
@@ -303,9 +305,15 @@ Parameter 1: CreatureId - The CreatureID that the NPC is watching to spawn to tr
Parameter 2: RepeatMin - Minimum Time used to calculate Random Repeat Expire
Parameter 3: RepeatMax - Maximum Time used to calculate Random Repeat Expire
-BOTH - Expires after creature with entry(Param1) is spawned or for all spawns if param1 = 0. Will repeat every (Param2) and (Param3) .
+BOTH - Expires after creature with entry(Param1) is spawned or for all spawns if param1 = 0. Will repeat every (Param2) and (Param3) .
This is commonly used for NPC's who will do something special once another NPC is summoned. Usually used is Complex Scripts or Special Events.
+---------------------------
+21 = EVENT_T_REACHED_HOME:
+---------------------------
+Expires only when creature has returned to it's home location after Evade. Out of combat event.
+Most commonly used to cast spells that can not be casted in EVENT_T_EVADE and other effects that does not fit in while still running back to spawn/home location.
+
=========================================
Action Types
@@ -322,15 +330,20 @@ Parameter 1: The entry of the text that the NPC should use from eventai_texts ta
Parameter 2: Optional. TextId can be defined in addition. The same apply to this as explained above, however eventAI will randomize between the two.
Parameter 3: Optional, if Parameter 2 exist. In this case, eventAI will randomize between three.
+See Text-tables.txt for documentation of eventai_texts-table.
+
------------------
-2 = ACTION_T_YELL:
+2 = ACTION_T_SET_FACTION:
------------------
-UNUSED Can be reused to create new action type
+Parameter 1: FactionId from Faction.dbc OR 0. Changes faction for creature. If 0, creature will revert to it's default faction if previously changed.
-----------------------
-3 = ACTION_T_TEXTEMOTE:
+3 = ACTION_T_MORPH_TO_ENTRY_OR_MODEL:
-----------------------
-UNUSED Can be reused to create new action type
+Parameter 1: Creature entry from creature_template. Action will then change to the model this creature are using.
+Parameter 2: If parameter 1 is 0, then this modelId will be used (in case parameter 1 exist, parameter 2 will not be used)
+
+If both parameter 1 and 2 is 0, the creature will DeMorph, and use it's default model.
-------------------
4 = ACTION_T_SOUND:
@@ -368,16 +381,16 @@ UNUSED Can be reused to create new action type
--------------------------
Parameter 1: The Sound ID to be played as Random Choice #1.
Parameter 2: The Sound ID to be played as Random Choice #2.
-Parameter 3: The Sound ID to be played as Random Choice #3.
+Parameter 3: The Sound ID to be played as Random Choice #3.
-Similar to the ACTION_T_SOUND action, it will choose at random a sound to play.
+Similar to the ACTION_T_SOUND action, it will choose at random a sound to play.
---------------------------
10 = ACTION_T_RANDOM_EMOTE:
---------------------------
Parameter 1: The Emote ID to be played as Random Choice #1.
Parameter 2: The Emote ID to be played as Random Choice #2.
-Parameter 3: The Emote ID to be played as Random Choice #3.
+Parameter 3: The Emote ID to be played as Random Choice #3.
Similar to the ACTION_T_EMOTE action, it will choose at random an Emote to Visually Perform.
@@ -388,26 +401,26 @@ Parameter 1: SpellId - The Spell ID to use for the NPC to cast. The value used i
Parameter 2: Target - The Target Type defining who the creature should cast the spell at. The value in this field needs to be a valid Target Type as specified in the reference tables below.
Parameter 3: CastFlags - See Table Below for Cast Flag Bitmask Values. If you are unsure what to set this value at leave it at 0.
-The creature will cast a spell specified by a spell ID on a target specified by the target type.
+The creature will cast a spell specified by a spell ID on a target specified by the target type.
This is commonly used for NPC's who cast spells.
---------------------
12 = ACTION_T_SUMMON:
---------------------
Parameter 1: CreatureID - The Creature Template ID to be Summoned. The value here needs to be a valid Creature Template ID.
-Parameter 2: Target - The Target Type defining who the Summoned creature will attack once spawned. The value in this field needs to be a valid Target Type as specified in the reference tables below.
-Parameter 3: Duration - The duration until the summoned creature should be unsummoned AFTER Combat ends. The value in this field is in milliseconds or 0.
+Parameter 2: Target - The Target Type defining who the Summoned creature will attack once spawned. The value in this field needs to be a valid Target Type as specified in the reference tables below.
+Parameter 3: Duration - The duration until the summoned creature should be unsummoned AFTER Combat ends. The value in this field is in milliseconds or 0.
-The NPC will Summon another creature at the same spot as itself that will attack the specified target.
+The NPC will Summon another creature at the same spot as itself that will attack the specified target.
NOTE: Almost all Creature Summons have proper Summon Spells that should be used when possible. This Action is a powerful last resort option only to be used if nothing else works.
NOTE: Using Target Type 0 will cause the Summoned creature to not attack anyone.
-NOTE: If Duration is set at 0, then the summoned creature will not despawn until it has died.
+NOTE: If Duration is set at 0, then the summoned creature will not despawn until it has died.
This is used as a manual way to force an NPC to Summon.
--------------------------------
13 = ACTION_T_THREAT_SINGLE_PCT:
--------------------------------
Parameter 1: Threat% - Threat percent that should be modified. The value in this field can range from -100 to +100. If it is negative, threat will be taken away and if positive, threat will be added.
-Parameter 2: Target - The Target Type defining on whom the threat change should occur. The value in this field needs to be a valid target type as specified in the reference tables below.
+Parameter 2: Target - The Target Type defining on whom the threat change should occur. The value in this field needs to be a valid target type as specified in the reference tables below.
This action will modify the threat of a target in the creature's threat list by the specified percent.
This is commonly used to allow an NPC to adjust the Threat to a single player.
@@ -415,7 +428,7 @@ This is commonly used to allow an NPC to adjust the Threat to a single player.
-----------------------------
14 = ACTION_T_THREAT_ALL_PCT:
-----------------------------
-Parameter 1: Threat% - The percent that should be used in modifying everyone's threat in the creature's threat list. The value here can range from -100 to +100.
+Parameter 1: Threat% - The percent that should be used in modifying everyone's threat in the creature's threat list. The value here can range from -100 to +100.
This action will modify the threat for everyone in the creature's threat list by the specified percent.
NOTE: Using -100 will cause the creature to reset everyone's threat to 0 so that everyone has the same amount of threat. It will NOT remove anyone from the threat list.
@@ -425,10 +438,10 @@ This is commonly used to allow an NPC to drop threat for all players to zero.
15 = ACTION_T_QUEST_EVENT:
--------------------------
Parameter 1: QuestID - The Quest Template ID. The value here must be a valid quest template ID. Furthermore, the quest should have SpecialFlags | 2 as it would need to be completed by an external event which is the activation of this action.
-Parameter 2: Target - The Target Type defining whom the quest should be completed for. The value in this field needs to be a valid target type as specified in the reference tables below.
+Parameter 2: Target - The Target Type defining whom the quest should be completed for. The value in this field needs to be a valid target type as specified in the reference tables below.
-This action will satisfy the external completion requirement for the quest for the specified target defined by the target type.
-NOTE: This action can only be used with player targets so it must be ensured that the target type will point to a player.
+This action will satisfy the external completion requirement for the quest for the specified target defined by the target type.
+NOTE: This action can only be used with player targets so it must be ensured that the target type will point to a player.
This is commonly used for Quests where only ONE player will gain credit for the quest.
-----------------------------
@@ -436,9 +449,9 @@ This is commonly used for Quests where only ONE player will gain credit for the
-----------------------------
Parameter 1: CreatureID - The Creature Template ID to be Summoned. The value here needs to be a valid Creature Template ID.
Parameter 2: SpellId - The Spell ID to use to simulate the cast. The value used in this field needs to be a valid Spell ID.
-Parameter 3: Target - The Target Type defining whom the quest credit should be given to. The value in this field needs to be a valid target type as specified in the reference tables below.
+Parameter 3: Target - The Target Type defining whom the quest credit should be given to. The value in this field needs to be a valid target type as specified in the reference tables below.
-This action will call CastedCreatureOrGO() function for the player. It can be used to give quest credit for casting a spell on the creature.
+This action will call CastedCreatureOrGO() function for the player. It can be used to give quest credit for casting a spell on the creature.
This is commonly used for NPC's who have a special requirement to have a Spell cast on them to complete a quest.
-----------------------------
@@ -446,7 +459,7 @@ This is commonly used for NPC's who have a special requirement to have a Spell c
-----------------------------
Parameter 1: Field_Number - The index of the Field Number to be changed. Use (http://wiki.udbforums.org/index.php/Character_data) for a list of indeces and what they control. Creatures only contain the OBJECT_FIELD_* and UNIT_FIELD_* fields. They do not contain the PLAYER_FIELD_* fields.
Parameter 2: Value - The new value to be put in the field.
-Parameter 3: Target - The Target Type defining for whom the unit field should be changed. The value in this field needs to be a valid target type as specified in the reference tables below.
+Parameter 3: Target - The Target Type defining for whom the unit field should be changed. The value in this field needs to be a valid target type as specified in the reference tables below.
When activated, this action can change the target's unit field values. More information on the field value indeces can be found at (http://wiki.udbforums.org/index.php/Character_data)
@@ -454,31 +467,31 @@ When activated, this action can change the target's unit field values. More info
18 = ACTION_T_SET_UNIT_FLAG:
----------------------------
Parameter 1: Flags - The flag(s) to be set. Multiple flags can be set by using bitwise-OR on them (adding them together).
-Parameter 2: Target - The Target Type defining for whom the flags should be changed. The value in this field needs to be a valid Target Type as specified in the reference tables below.
+Parameter 2: Target - The Target Type defining for whom the flags should be changed. The value in this field needs to be a valid Target Type as specified in the reference tables below.
-When activated, this action changes the target's flags by adding (turning on) more flags. For example, this action can make the creature unattackable/unselectable if the right flags are used.
+When activated, this action changes the target's flags by adding (turning on) more flags. For example, this action can make the creature unattackable/unselectable if the right flags are used.
-------------------------------
19 = ACTION_T_REMOVE_UNIT_FLAG:
-------------------------------
Parameter 1: Flags - The flag(s) to be removed. Multiple flags can be set by using bitwise-OR on them (adding them together).
-Parameter 2: Target - The target type defining for whom the flags should be changed. The value in this field needs to be a valid Target Type as specified in the reference tables below.
+Parameter 2: Target - The target type defining for whom the flags should be changed. The value in this field needs to be a valid Target Type as specified in the reference tables below.
-When activated, this action changes the target's flags by removing (turning off) flags. For example, this action can make the creature normal after it was unattackable/unselectable if the right flags are used.
+When activated, this action changes the target's flags by removing (turning off) flags. For example, this action can make the creature normal after it was unattackable/unselectable if the right flags are used.
--------------------------
20 = ACTION_T_AUTO_ATTACK:
--------------------------
-Parameter 1: AllowAutoAttack - If zero, then the creature will stop its melee attacks. If non-zero, then the creature will either continue its melee attacks (the action would then have no effect) or it will start its melee attacks on the target with the top threat if its melee attacks were previously stopped.
+Parameter 1: AllowAutoAttack - If zero, then the creature will stop its melee attacks. If non-zero, then the creature will either continue its melee attacks (the action would then have no effect) or it will start its melee attacks on the target with the top threat if its melee attacks were previously stopped.
-This action controls whether or not the creature should stop or start the auto melee attack.
+This action controls whether or not the creature should stop or start the auto melee attack.
NOTE: The ACID Dev Team has conformed to using either 0 or 1 for the Param values (0 = Stop Melee, 1 = Start Melee).
This is commonly used in combination with EVENT_T_RANGE and ACTION_T_COMBAT_MOVEMENT for Ranged Combat for Mages and Spell Casters.
------------------------------
21 = ACTION_T_COMBAT_MOVEMENT:
------------------------------
-Parameter 1: If zero, then the creature will stop moving towards its victim (if its victim gets out of melee range) and will be stationary. If non-zero, then the creature will either continue to follow its victim (the action would have no effect) or it will start to follow the target with the top threat if its movement was disabled before.
+Parameter 1: If zero, then the creature will stop moving towards its victim (if its victim gets out of melee range) and will be stationary. If non-zero, then the creature will either continue to follow its victim (the action would have no effect) or it will start to follow the target with the top threat if its movement was disabled before.
This action controls whether or not the creature will always move towards its target.
NOTE: The ACID Dev Team has conformed to using either 0 or 1 for the Param values. (0 = Stop Movement, 1 = Start Movement)
@@ -487,7 +500,7 @@ This is commonly used with EVENT_T_RANGE and ACTION_T_AUTO_ATTACK for NPC's who
------------------------
22 = ACTION_T_SET_PHASE:
------------------------
-Parameter 1: The new phase to set the creature in. This number must be an integer between 0 and 31. Numbers outside of that range will result in an error.
+Parameter 1: The new phase to set the creature in. This number must be an integer between 0 and 31. Numbers outside of that range will result in an error.
When activated, this action sets the creature's event to the specified value.
NOTE: The creature's current Phase is NOT reset at creature evade. You must manually set the phase back to 0 at EVENT_T_RESET.
@@ -497,20 +510,20 @@ This is commonly used for complex scripts with several phases and you need to sw
------------------------
23 = ACTION_T_INC_PHASE:
------------------------
-Parameter 1: Value - The number of phases to increase or decrease. Use negative values to decrease the current phase.
+Parameter 1: Value - The number of phases to increase or decrease. Use negative values to decrease the current phase.
-When activated, this action will increase (or decrease) the current creature's phase.
-NOTE: After increasing or decreasing the phase by this action, the current phase must NOT be lower than 0 or exceed 31.
+When activated, this action will increase (or decrease) the current creature's phase.
+NOTE: After increasing or decreasing the phase by this action, the current phase must NOT be lower than 0 or exceed 31.
This can be used instead of ACTION_T_SET_PHASE to change phases in scripts. Just a user friendly option for changing phases.
--------------------
24 = ACTION_T_EVADE:
--------------------
-When activated, the creature will immediately exit out of combat, clear its threat list, and move back to its spawn point. Basically, this action will reset the whole encounter.
+When activated, the creature will immediately exit out of combat, clear its threat list, and move back to its spawn point. Basically, this action will reset the whole encounter.
NOTE: All Param Values Are 0 for this Action.
-------------------
-25 = ACTION_T_FLEE:
+25 = ACTION_T_FLEE:
-------------------
When activated, the creature will try to flee from combat. Currently this is done by it casting a fear-like spell on itself called "Run Away". A Better Flee system is in Development but will take time before it is implimented.
NOTE: All Param Values Are 0 for this Action.
@@ -518,47 +531,47 @@ NOTE: All Param Values Are 0 for this Action.
------------------------------
26 = ACTION_T_QUEST_EVENT_ALL:
------------------------------
-Parameter 1: QuestId - The quest ID to finish for everyone.
+Parameter 1: QuestId - The quest ID to finish for everyone.
-This action does the same thing as the ACTION_T_QUEST_EVENT does but it does it for all players in the creature's threat list.
-NOTE: If a player is not in the NPC's threat list for whatever reason, he/she won't get the quest completed.
+This action does the same thing as the ACTION_T_QUEST_EVENT does but it does it for all players in the creature's threat list.
+NOTE: If a player is not in the NPC's threat list for whatever reason, he/she won't get the quest completed.
---------------------------------
27 = ACTION_T_CASTCREATUREGO_ALL:
---------------------------------
Parameter 1: QuestId - The quest template ID.
-Parameter 2: SpellId - The spell ID used to simulate the cast.
+Parameter 2: SpellId - The spell ID used to simulate the cast.
-This action does the same thing as the ACTION_T_CASTCREATUREGO does but it does it for all players in the creature's threat list.
-NOTE: If a player is not in its threat list for whatever reason, he/she won't receive the cast emulation.
+This action does the same thing as the ACTION_T_CASTCREATUREGO does but it does it for all players in the creature's threat list.
+NOTE: If a player is not in its threat list for whatever reason, he/she won't receive the cast emulation.
-----------------------------------
28 = ACTION_T_REMOVEAURASFROMSPELL:
-----------------------------------
Parameter 1: Target - The target type defining for whom the unit field should be changed. The value in this field needs to be a valid target type as specified in the reference tables below.
-Parameter 2: SpellId - The spell ID whose auras will be removed.
+Parameter 2: SpellId - The spell ID whose auras will be removed.
-This action will remove all auras from a specific spell from the target.
+This action will remove all auras from a specific spell from the target.
This is commonly used for NPC's who have an OOC Aura that is removed at combat start or a similar idea (Like Stealth or Shape Shift)
------------------------------
29 = ACTION_T_RANGED_MOVEMENT:
------------------------------
Parameter 1: Distance - The distance the mob should keep between it and its target.
-Parameter 2: Angle - The angle the mob should use.
+Parameter 2: Angle - The angle the mob should use.
-This action changes the movement type generator to ranged type using the specified values for angle and distance.
-NOTE: Specifying zero angle and distance will make it just melee instead.
-This is commonly used for NPC's who always attack at range and you can specify the distance they will maintain from the target.
+This action changes the movement type generator to ranged type using the specified values for angle and distance.
+NOTE: Specifying zero angle and distance will make it just melee instead.
+This is commonly used for NPC's who always attack at range and you can specify the distance they will maintain from the target.
---------------------------
30 = ACTION_T_RANDOM_PHASE:
---------------------------
Parameter 1: PhaseId1 - A possible random phase choice.
Parameter 2: PhaseId2 - A possible random phase choice.
-Parameter 3: PhaseId3 - A possible random phase choice.
+Parameter 3: PhaseId3 - A possible random phase choice.
-Randomly sets the phase to one from the three parameter choices.
+Randomly sets the phase to one from the three parameter choices.
NOTE: Use -1 to specify that if this param is picked to do nothing. Random is constant between actions within an event. So if you have a random Yell and a random Sound they will match up (ex: param2 with param2)
NOTE 2: PLEASE NOTE THAT EACH OF THE PARAM VALUES ARE ACTUAL PHASE NUMBERS NOT THE INVERSE PHASE MASK VALUE.
This is commonly used for Spellcasting NPC's who on Aggro may select at random a school of spells to use for the fight. Use this if you have up to 3 phases used, otherwise use Action 31 for more then 3 phases.
@@ -567,9 +580,9 @@ This is commonly used for Spellcasting NPC's who on Aggro may select at random a
31 = ACTION_T_RANDOM_PHASE_RANGE:
---------------------------------
Parameter 1: PhaseMin - The minimum of the phase range.
-Parameter 2: PhaseMax - The maximum of the phase range. The number here must be greater than PhaseMin.
+Parameter 2: PhaseMax - The maximum of the phase range. The number here must be greater than PhaseMin.
-Randomly sets the phase between a range of phases controlled by the parameters. Sets the phase to a random id (Phase = PhaseMin + rnd % PhaseMin-PhaseMax).
+Randomly sets the phase between a range of phases controlled by the parameters. Sets the phase to a random id (Phase = PhaseMin + rnd % PhaseMin-PhaseMax).
NOTE: PhaseMax must be greater than PhaseMin.
NOTE 2: PLEASE NOTE THAT EACH OF THE PARAM VALUES ARE ACTUAL PHASE NUMBERS NOT THE INVERSE PHASE MASK VALUE.
This is commonly used for Spellcasting NPC's who on Aggro may select at random a school of spells to use for the fight. Use this if you have MORE then 3 phases used, otherwise use Action 30.
@@ -579,9 +592,9 @@ This is commonly used for Spellcasting NPC's who on Aggro may select at random a
---------------------
Parameter 1: CreatureID - The creature template ID to be summoned. The value here needs to be a valid creature template ID.
Parameter 2: Target - The target type defining who the summoned creature will attack. The value in this field needs to be a valid target type as specified in the reference tables below. NOTE: Using target type 0 will cause the summoned creature to not attack anyone.
-Parameter 3: SummonID - The summon ID from the eventai_summons table controlling the position (and spawntime) where the summoned mob should be spawned at.
+Parameter 3: SummonID - The summon ID from the eventai_summons table controlling the position (and spawntime) where the summoned mob should be spawned at.
-Summons creature (param1) to attack target (param2) at location specified by EventAI_Summons (param3).
+Summons creature (param1) to attack target (param2) at location specified by EventAI_Summons (param3).
NOTE: Param3 Value is the ID Value used for the entry used in EventAI_Summons for this action. You MUST have an EventAI_Summons entry to use this action.
This is commonly used for NPC's who need to Summon a creature at a specific location. (Normally used for complex events)
@@ -589,9 +602,9 @@ This is commonly used for NPC's who need to Summon a creature at a specific loca
33 = ACTION_T_KILLED_MONSTER:
-----------------------------
Parameter 1: CreatureID - The creature template ID. The value here must be a valid creature template ID.
-Parameter 2: Target - The target type defining whom the quest kill count should be given to. The value in this field needs to be a valid target type as specified in the reference tables below.
+Parameter 2: Target - The target type defining whom the quest kill count should be given to. The value in this field needs to be a valid target type as specified in the reference tables below.
-When activated, this action will call KilledMonster() function for the player. It can be used to give creature credit for killing a creature. In general if the quest is set to be accompished on different creatures (e.g. "Credit" templates).
+When activated, this action will call KilledMonster() function for the player. It can be used to give creature credit for killing a creature. In general if the quest is set to be accompished on different creatures (e.g. "Credit" templates).
NOTE: It can be ANY creature including certain quest specific triggers
This is commonly used for giving the player Quest Credits for NPC kills (Many NPC's may use the same CreatureID for the Kill Credit)
@@ -601,7 +614,7 @@ This is commonly used for giving the player Quest Credits for NPC kills (Many NP
Parameter 1: Field - The field to change in the instance script. Again, this field needs to be a valid field that has been already defined in the instance's script.
Parameter 2: Data - The value to put at that field index.
-Sets data for the instance. Note that this will only work when the creature is inside an instantiable zone that has a valid script (ScriptedInstance) assigned.
+Sets data for the instance. Note that this will only work when the creature is inside an instantiable zone that has a valid script (ScriptedInstance) assigned.
NOTE: Param1 Value is located in "def_<instance name>.h" SD2 File and Param2 value is generally found in the "sc_instance.h" file in SD2
This is commonly used to link an ACID script with a SD2 C++ Script. You make make things happen like opening doors on specific events that happen. ACID Just triggers the C++ Script to function.
@@ -609,30 +622,30 @@ This is commonly used to link an ACID script with a SD2 C++ Script. You make mak
35 = ACTION_T_SET_INST_DATA64:
------------------------------
Parameter 1: Field - The field to change in the instance script. Again, this field needs to be a valid field that has been already defined in the instance's script.
-Parameter 2: Target - The target type to use to get the GUID that will be stored at the field index. The value in this field needs to be a valid target type as specified in the reference tables below.
+Parameter 2: Target - The target type to use to get the GUID that will be stored at the field index. The value in this field needs to be a valid target type as specified in the reference tables below.
-Sets GUID (64 bits) data for the instance based on the target. Note that this will only work when the creature is inside an instantiable zone that has a valid script (ScriptedInstance) assigned.
+Sets GUID (64 bits) data for the instance based on the target. Note that this will only work when the creature is inside an instantiable zone that has a valid script (ScriptedInstance) assigned.
Calls ScriptedInstance::SetData64 with field (param1) and data (param2) target's GUID.
------------------------------
36 = ACTION_T_UPDATE_TEMPLATE:
------------------------------
Parameter 1: TemplateId - The creature template ID. The value here must be a valid creature template ID.
-Parameter 2: Team - Use model_id from team : Alliance(0) or Horde (1).
+Parameter 2: Team - Use model_id from team : Alliance(0) or Horde (1).
-This function temporarily changes creature entry to new entry, display is changed, loot is changed, but AI is not changed. At respawn creature will be reverted to original entry.
+This function temporarily changes creature entry to new entry, display is changed, loot is changed, but AI is not changed. At respawn creature will be reverted to original entry.
Changes the creature to a new creature template of (param1) with team = Alliance if (param2) = false or Horde if (param2) = true
------------------
37 = ACTION_T_DIE:
------------------
Kills the creature
-This is commonly used if you need to Instakill the creature for one reason or another.
+This is commonly used if you need to Instakill the creature for one reason or another.
--------------------------------
38 = ACTION_T_ZONE_COMBAT_PULSE:
--------------------------------
-Places all players within the instance into combat with the creature. Only works in combat and only works inside of instances.
+Places all players within the instance into combat with the creature. Only works in combat and only works inside of instances.
=========================================
@@ -666,7 +679,7 @@ Another example: the number "5" (101 in Binary, selecting first and third option
4 16 CAST_FORCE_TARGET_SELF Forces the target to cast this spell on itself
5 32 CAST_AURA_NOT_PRESENT Only casts the spell on the target if the target does not have the aura from that spell on itself already.
-NOTE: You can add the numbers in the decimal column to combine flags.
+NOTE: You can add the numbers in the decimal column to combine flags.
For example if you wanted to use CAST_NO_MELEE_IF_OOM(8) and CAST_TRIGGERED(2) you would simply use 10 in the cast flags field (8 + 2 = 10).
=========================================
@@ -684,4 +697,4 @@ Below is the list of current Event Flags that EventAI can handle. Event flags ar
6 64
7 128 EFLAG_DEBUG_ONLY Prevents events from occuring on Release builds of ScriptDev2. Useful for testing new features.
-NOTE: You can add the numbers in the decimal column to combine flags.
+NOTE: You can add the numbers in the decimal column to combine flags. \ No newline at end of file
diff --git a/src/bindings/scripts/docs/Text-tables.txt b/src/bindings/scripts/docs/Text-tables.txt
index 6db1ce9d852..2a539a72874 100644
--- a/src/bindings/scripts/docs/Text-tables.txt
+++ b/src/bindings/scripts/docs/Text-tables.txt
@@ -52,8 +52,8 @@ Below is the list of current Text types that texts tables can handle. These were
-----------------------------------------------------------
0 CHAT_TYPE_SAY This type sets the text to be displayed as a Say (Speech Bubble).
1 CHAT_TYPE_YELL This type sets the text to be displayed as a Yell (Red Speech Bubble) and usually has a matching Sound ID.
-2 CHAT_TYPE_TEXT_EMOTE This type sets the text to be displayed as a text emote in orange in the chat log.
-3 CHAT_TYPE_BOSS_EMOTE This type sets the text to be displayed as a text emote in orange in the chat log (Used only for specific Bosses).
+2 CHAT_TYPE_TEXT_EMOTE This type sets the text to be displayed as a text emote in orange in the chat log.
+3 CHAT_TYPE_BOSS_EMOTE This type sets the text to be displayed as a text emote in orange in the chat log (Used only for specific Bosses).
4 CHAT_TYPE_WHISPER This type sets the text to be displayed as a whisper to the player in the chat log.
5 CHAT_TYPE_BOSS_WHISPER This type sets the text to be displayed as a whisper to the player in the chat log (Used only for specific Bosses).
@@ -65,7 +65,7 @@ Below is the list of current Language types that are allowed.
This is the Race Language that the text is native to (So it will display properly)
# Internal Name Description
------------------------------------------------------------
+-----------------------------------------------------------
0 UNIVERSAL Text in this language is understood by ALL Races.
1 ORCISH Text in this language is understood ONLY by Horde Races.
2 DARNASSIAN Text in this language is understood ONLY by the Night Elf Race.
diff --git a/src/bindings/scripts/include/precompiled.cpp b/src/bindings/scripts/include/precompiled.cpp
index 9753d023374..75bfae9e1c4 100644
--- a/src/bindings/scripts/include/precompiled.cpp
+++ b/src/bindings/scripts/include/precompiled.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/include/precompiled.h b/src/bindings/scripts/include/precompiled.h
index cd6d68f9f31..2c36cc924e0 100644
--- a/src/bindings/scripts/include/precompiled.h
+++ b/src/bindings/scripts/include/precompiled.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
@@ -12,6 +12,7 @@
#include "GridNotifiersImpl.h"
#include "Unit.h"
#include "GameObject.h"
+#include "TemporarySummon.h"
#include "sc_creature.h"
#include "sc_gossip.h"
#include "sc_instance.h"
diff --git a/src/bindings/scripts/include/sc_creature.cpp b/src/bindings/scripts/include/sc_creature.cpp
index f04f757d43e..fcd44d94842 100644
--- a/src/bindings/scripts/include/sc_creature.cpp
+++ b/src/bindings/scripts/include/sc_creature.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2008 Trinity <http://www.trinitycore.org/>
+/* Copyright (C) 2008-2009 Trinity <http://www.trinitycore.org/>
*
* Thanks to the original authors: ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
*
@@ -108,9 +108,9 @@ void ScriptedAI::AttackStart(Unit* who)
void ScriptedAI::UpdateAI(const uint32 diff)
{
//Check if we have a current target
- if (m_creature->isAlive() && UpdateVictim())
+ if (UpdateVictim())
{
- if (m_creature->isAttackReady() )
+ if (m_creature->isAttackReady())
{
//If we are within range melee the target
if (m_creature->IsWithinMeleeRange(m_creature->getVictim()))
@@ -206,23 +206,23 @@ void ScriptedAI::DoSay(const char* text, uint32 language, Unit* target, bool Say
{
if (target)
{
- m_creature->Say(text, language, target->GetGUID());
+ m_creature->MonsterSay(text, language, target->GetGUID());
if(SayEmote)
m_creature->HandleEmoteCommand(EMOTE_ONESHOT_TALK);
}
- else m_creature->Say(text, language, 0);
+ else m_creature->MonsterSay(text, language, 0);
}
void ScriptedAI::DoYell(const char* text, uint32 language, Unit* target)
{
- if (target) m_creature->Yell(text, language, target->GetGUID());
- else m_creature->Yell(text, language, 0);
+ if (target) m_creature->MonsterYell(text, language, target->GetGUID());
+ else m_creature->MonsterYell(text, language, 0);
}
void ScriptedAI::DoTextEmote(const char* text, Unit* target, bool IsBossEmote)
{
- if (target) m_creature->TextEmote(text, target->GetGUID(), IsBossEmote);
- else m_creature->TextEmote(text, 0, IsBossEmote);
+ if (target) m_creature->MonsterTextEmote(text, target->GetGUID(), IsBossEmote);
+ else m_creature->MonsterTextEmote(text, 0, IsBossEmote);
}
void ScriptedAI::DoWhisper(const char* text, Unit* reciever, bool IsBossWhisper)
@@ -230,24 +230,21 @@ void ScriptedAI::DoWhisper(const char* text, Unit* reciever, bool IsBossWhisper)
if (!reciever || reciever->GetTypeId() != TYPEID_PLAYER)
return;
- m_creature->Whisper(text, reciever->GetGUID(), IsBossWhisper);
+ m_creature->MonsterWhisper(text, reciever->GetGUID(), IsBossWhisper);
}
-void ScriptedAI::DoPlaySoundToSet(Unit* unit, uint32 sound)
+void ScriptedAI::DoPlaySoundToSet(Unit* pSource, uint32 uiSoundId)
{
- if (!unit)
+ if (!pSource)
return;
- if (!GetSoundEntriesStore()->LookupEntry(sound))
+ if (!GetSoundEntriesStore()->LookupEntry(uiSoundId))
{
- error_log("SD2: Invalid soundId %u used in DoPlaySoundToSet (by unit TypeId %u, guid %u)", sound, unit->GetTypeId(), unit->GetGUID());
+ error_log("SD2: Invalid soundId %u used in DoPlaySoundToSet (by unit TypeId %u, guid %u)", uiSoundId, pSource->GetTypeId(), pSource->GetGUID());
return;
}
- WorldPacket data(4);
- data.SetOpcode(SMSG_PLAY_SOUND);
- data << uint32(sound);
- unit->SendMessageToSet(&data,false);
+ pSource->PlayDirectSound(uiSoundId);
}
Creature* ScriptedAI::DoSpawnCreature(uint32 id, float x, float y, float z, float angle, uint32 type, uint32 despawntime)
@@ -437,11 +434,9 @@ SpellEntry const* ScriptedAI::SelectSpell(Unit* Target, int32 School, int32 Mech
return false;
//Using the extended script system we first create a list of viable spells
- SpellEntry const* Spell[4];
- Spell[0] = 0;
- Spell[1] = 0;
- Spell[2] = 0;
- Spell[3] = 0;
+ SpellEntry const* Spell[CREATURE_MAX_SPELLS];
+ for (uint8 i=0;i<CREATURE_MAX_SPELLS;i++)
+ Spell[i] = 0;
uint32 SpellCount = 0;
@@ -449,7 +444,7 @@ SpellEntry const* ScriptedAI::SelectSpell(Unit* Target, int32 School, int32 Mech
SpellRangeEntry const* TempRange;
//Check if each spell is viable(set it to null if not)
- for (uint32 i = 0; i < 4; i++)
+ for (uint32 i = 0; i < CREATURE_MAX_SPELLS; i++)
{
TempSpell = GetSpellStore()->LookupEntry(m_creature->m_spells[i]);
@@ -493,13 +488,13 @@ SpellEntry const* ScriptedAI::SelectSpell(Unit* Target, int32 School, int32 Mech
continue;
//Check if the spell meets our range requirements
- if (RangeMin && TempRange->maxRange < RangeMin)
+ if (RangeMin && m_creature->GetSpellMinRangeForTarget(Target, TempRange) < RangeMin)
continue;
- if (RangeMax && TempRange->maxRange > RangeMax)
+ if (RangeMax && m_creature->GetSpellMaxRangeForTarget(Target, TempRange) > RangeMax)
continue;
//Check if our target is in range
- if (m_creature->IsWithinDistInMap(Target, TempRange->minRange) || !m_creature->IsWithinDistInMap(Target, TempRange->maxRange))
+ if (m_creature->IsWithinDistInMap(Target, m_creature->GetSpellMinRangeForTarget(Target, TempRange)) || !m_creature->IsWithinDistInMap(Target, m_creature->GetSpellMaxRangeForTarget(Target, TempRange)))
continue;
//All good so lets add it to the spell list
@@ -521,11 +516,11 @@ bool ScriptedAI::CanCast(Unit* Target, SpellEntry const *Spell, bool Triggered)
return false;
//Silenced so we can't cast
- if (!Triggered && m_creature->HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_SILENCED))
+ if (!Triggered && me->HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_SILENCED))
return false;
//Check for power
- if (!Triggered && m_creature->GetPower((Powers)Spell->powerType) < Spell->manaCost)
+ if (!Triggered && me->GetPower((Powers)Spell->powerType) < Spell->manaCost)
return false;
SpellRangeEntry const *TempRange = NULL;
@@ -537,20 +532,21 @@ bool ScriptedAI::CanCast(Unit* Target, SpellEntry const *Spell, bool Triggered)
return false;
//Unit is out of range of this spell
- if (m_creature->GetDistance(Target) > TempRange->maxRange || m_creature->GetDistance(Target) < TempRange->minRange)
+ if (me->GetDistance(Target) > me->GetSpellMaxRangeForTarget(Target, TempRange)
+ || me->GetDistance(Target) < me->GetSpellMinRangeForTarget(Target, TempRange))
return false;
return true;
}
-float GetSpellMaxRange(uint32 id)
+float GetSpellMaxRangeForHostile(uint32 id)
{
SpellEntry const *spellInfo = GetSpellStore()->LookupEntry(id);
if(!spellInfo) return 0;
SpellRangeEntry const *range = GetSpellRangeStore()->LookupEntry(spellInfo->rangeIndex);
if(!range) return 0;
- return range->maxRange;
+ return range->maxRangeHostile;
}
void FillSpellSummary()
@@ -583,7 +579,7 @@ void FillSpellSummary()
//Spell targets AoE at enemy
if ( TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_ENEMY_IN_AREA ||
TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_ENEMY_IN_AREA_INSTANT ||
- TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_AROUND_CASTER ||
+ TempSpell->EffectImplicitTargetA[j] == TARGET_DEST_CASTER ||
TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_ENEMY_IN_AREA_CHANNELED )
SpellSummary[i].Targets |= 1 << (SELECT_TARGET_AOE_ENEMY-1);
@@ -592,7 +588,7 @@ void FillSpellSummary()
TempSpell->EffectImplicitTargetA[j] == TARGET_CURRENT_ENEMY_COORDINATES ||
TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_ENEMY_IN_AREA ||
TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_ENEMY_IN_AREA_INSTANT ||
- TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_AROUND_CASTER ||
+ TempSpell->EffectImplicitTargetA[j] == TARGET_DEST_CASTER ||
TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_ENEMY_IN_AREA_CHANNELED )
SpellSummary[i].Targets |= 1 << (SELECT_TARGET_ANY_ENEMY-1);
@@ -605,7 +601,7 @@ void FillSpellSummary()
//Spell targets aoe friends
if ( TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_PARTY_AROUND_CASTER ||
TempSpell->EffectImplicitTargetA[j] == TARGET_AREAEFFECT_PARTY ||
- TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_AROUND_CASTER)
+ TempSpell->EffectImplicitTargetA[j] == TARGET_DEST_CASTER)
SpellSummary[i].Targets |= 1 << (SELECT_TARGET_AOE_FRIEND-1);
//Spell targets any friend(or self)
@@ -614,7 +610,7 @@ void FillSpellSummary()
TempSpell->EffectImplicitTargetA[j] == TARGET_SINGLE_PARTY ||
TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_PARTY_AROUND_CASTER ||
TempSpell->EffectImplicitTargetA[j] == TARGET_AREAEFFECT_PARTY ||
- TempSpell->EffectImplicitTargetA[j] == TARGET_ALL_AROUND_CASTER)
+ TempSpell->EffectImplicitTargetA[j] == TARGET_DEST_CASTER)
SpellSummary[i].Targets |= 1 << (SELECT_TARGET_ANY_FRIEND-1);
//Make sure that this spell includes a damage effect
@@ -638,39 +634,6 @@ void FillSpellSummary()
}
}
-void ScriptedAI::DoZoneInCombat(Unit* pUnit)
-{
- if (!pUnit)
- pUnit = m_creature;
-
- Map *map = pUnit->GetMap();
-
- if (!map->IsDungeon()) //use IsDungeon instead of Instanceable, in case battlegrounds will be instantiated
- {
- error_log("SD2: DoZoneInCombat call for map that isn't an instance (pUnit entry = %d)", pUnit->GetTypeId() == TYPEID_UNIT ? ((Creature*)pUnit)->GetEntry() : 0);
- return;
- }
-
- if (!pUnit->CanHaveThreatList() || pUnit->getThreatManager().isThreatListEmpty())
- {
- error_log("SD2: DoZoneInCombat called for creature that either cannot have threat list or has empty threat list (pUnit entry = %d)", pUnit->GetTypeId() == TYPEID_UNIT ? ((Creature*)pUnit)->GetEntry() : 0);
-
- return;
- }
-
- Map::PlayerList const &PlayerList = map->GetPlayers();
- for(Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
- {
- if (Player* i_pl = i->getSource())
- if (i_pl->isAlive())
- {
- pUnit->SetInCombatWith(i_pl);
- i_pl->SetInCombatWith(pUnit);
- pUnit->AddThreat(i_pl, 0.0f);
- }
- }
-}
-
void ScriptedAI::DoResetThreat()
{
if (!m_creature->CanHaveThreatList() || m_creature->getThreatManager().isThreatListEmpty())
@@ -741,7 +704,7 @@ Unit* FindCreature(uint32 entry, float range, Unit* Finder)
return NULL;
Creature* target = NULL;
Trinity::AllCreaturesOfEntryInRange check(Finder, entry, range);
- Trinity::CreatureSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(target, check);
+ Trinity::CreatureSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(Finder, target, check);
Finder->VisitNearbyObject(range, searcher);
return target;
}
@@ -752,7 +715,7 @@ GameObject* FindGameObject(uint32 entry, float range, Unit* Finder)
return NULL;
GameObject* target = NULL;
Trinity::AllGameObjectsWithEntryInGrid go_check(entry);
- Trinity::GameObjectSearcher<Trinity::AllGameObjectsWithEntryInGrid> searcher(target, go_check);
+ Trinity::GameObjectSearcher<Trinity::AllGameObjectsWithEntryInGrid> searcher(Finder, target, go_check);
Finder->VisitNearbyGridObject(range, searcher);
return target;
}
@@ -761,7 +724,7 @@ Unit* ScriptedAI::DoSelectLowestHpFriendly(float range, uint32 MinHPDiff)
{
Unit* pUnit = NULL;
Trinity::MostHPMissingInRange u_check(m_creature, range, MinHPDiff);
- Trinity::UnitLastSearcher<Trinity::MostHPMissingInRange> searcher(pUnit, u_check);
+ Trinity::UnitLastSearcher<Trinity::MostHPMissingInRange> searcher(m_creature, pUnit, u_check);
m_creature->VisitNearbyObject(range, searcher);
return pUnit;
}
@@ -770,7 +733,7 @@ std::list<Creature*> ScriptedAI::DoFindFriendlyCC(float range)
{
std::list<Creature*> pList;
Trinity::FriendlyCCedInRange u_check(m_creature, range);
- Trinity::CreatureListSearcher<Trinity::FriendlyCCedInRange> searcher(pList, u_check);
+ Trinity::CreatureListSearcher<Trinity::FriendlyCCedInRange> searcher(m_creature, pList, u_check);
m_creature->VisitNearbyObject(range, searcher);
return pList;
}
@@ -779,7 +742,7 @@ std::list<Creature*> ScriptedAI::DoFindFriendlyMissingBuff(float range, uint32 s
{
std::list<Creature*> pList;
Trinity::FriendlyMissingBuffInRange u_check(m_creature, range, spellid);
- Trinity::CreatureListSearcher<Trinity::FriendlyMissingBuffInRange> searcher(pList, u_check);
+ Trinity::CreatureListSearcher<Trinity::FriendlyMissingBuffInRange> searcher(m_creature, pList, u_check);
m_creature->VisitNearbyObject(range, searcher);
return pList;
}
diff --git a/src/bindings/scripts/include/sc_creature.h b/src/bindings/scripts/include/sc_creature.h
index 40a331b7d6b..03194e9a3a9 100644
--- a/src/bindings/scripts/include/sc_creature.h
+++ b/src/bindings/scripts/include/sc_creature.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2008 Trinity <http://www.trinitycore.org/>
+/* Copyright (C) 2008-2009 Trinity <http://www.trinitycore.org/>
*
* Thanks to the original authors: ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
*
@@ -11,7 +11,7 @@
#include "CreatureAI.h"
#include "Creature.h"
-float GetSpellMaxRange(uint32 id);
+float GetSpellMaxRangeForHostile(uint32 id);
class SummonList : std::list<uint64>
{
@@ -31,6 +31,16 @@ Unit* FindCreature(uint32 entry, float range, Unit* Finder);
//Get a single gameobject of given entry
GameObject* FindGameObject(uint32 entry, float range, Unit* Finder);
+struct PointMovement
+{
+ uint32 m_uiCreatureEntry;
+ uint32 m_uiPointId;
+ float m_fX;
+ float m_fY;
+ float m_fZ;
+ uint32 m_uiWaitTime;
+};
+
struct TRINITY_DLL_DECL ScriptedAI : public CreatureAI
{
ScriptedAI(Creature* creature) : CreatureAI(creature), m_creature(creature), InCombat(false), IsFleeing(false) {}
@@ -138,9 +148,6 @@ struct TRINITY_DLL_DECL ScriptedAI : public CreatureAI
//Plays a sound to all nearby players
void DoPlaySoundToSet(Unit* unit, uint32 sound);
- //Places the entire map into combat with creature
- void DoZoneInCombat(Unit* pUnit = 0);
-
//Drops all threat to 0%. Does not remove players from the threat list
void DoResetThreat();
diff --git a/src/bindings/scripts/include/sc_gossip.h b/src/bindings/scripts/include/sc_gossip.h
index 74bc93694af..9665a7e1123 100644
--- a/src/bindings/scripts/include/sc_gossip.h
+++ b/src/bindings/scripts/include/sc_gossip.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2008 Trinity <http://www.trinitycore.org/>
+/* Copyright (C) 2008-2009 Trinity <http://www.trinitycore.org/>
*
* Thanks to the original authors: ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
*
@@ -16,29 +16,38 @@
#define GOSSIP_TEXT_BROWSE_GOODS "I'd like to browse your goods."
#define GOSSIP_TEXT_TRAIN "Train me!"
-#define GOSSIP_TEXT_BANK "The Bank"
-#define GOSSIP_TEXT_WINDRIDER "Wind rider master"
-#define GOSSIP_TEXT_GRYPHON "Gryphon Master"
-#define GOSSIP_TEXT_BATHANDLER "Bat Handler"
-#define GOSSIP_TEXT_HIPPOGRYPH "Hippogryph Master"
-#define GOSSIP_TEXT_FLIGHTMASTER "Flight Master"
-#define GOSSIP_TEXT_AUCTIONHOUSE "Auction House"
-#define GOSSIP_TEXT_GUILDMASTER "Guild Master"
-#define GOSSIP_TEXT_INN "The Inn"
-#define GOSSIP_TEXT_MAILBOX "Mailbox"
-#define GOSSIP_TEXT_STABLEMASTER "Stable Master"
-#define GOSSIP_TEXT_WEAPONMASTER "Weapons Trainer"
-#define GOSSIP_TEXT_BATTLEMASTER "Battlemaster"
-#define GOSSIP_TEXT_CLASSTRAINER "Class Trainer"
-#define GOSSIP_TEXT_PROFTRAINER "Profession Trainer"
-#define GOSSIP_TEXT_OFFICERS "The officers` lounge"
+#define GOSSIP_TEXT_BANK "The bank"
+#define GOSSIP_TEXT_IRONFORGE_BANK "The bank of Ironforge"
+#define GOSSIP_TEXT_STORMWIND_BANK "The bank of Stormwind"
+#define GOSSIP_TEXT_WINDRIDER "The wind rider master"
+#define GOSSIP_TEXT_GRYPHON "The gryphon master"
+#define GOSSIP_TEXT_BATHANDLER "The bat handler"
+#define GOSSIP_TEXT_HIPPOGRYPH "The hippogryph master"
+#define GOSSIP_TEXT_ZEPPLINMASTER "The zeppelin master"
+#define GOSSIP_TEXT_DEEPRUNTRAM "The Deeprun Tram"
+#define GOSSIP_TEXT_FERRY "The Rut'theran Ferry"
+#define GOSSIP_TEXT_FLIGHTMASTER "The flight master"
+#define GOSSIP_TEXT_AUCTIONHOUSE "The auction house"
+#define GOSSIP_TEXT_GUILDMASTER "The guild master"
+#define GOSSIP_TEXT_INN "The inn"
+#define GOSSIP_TEXT_MAILBOX "The mailbox"
+#define GOSSIP_TEXT_STABLEMASTER "The stable master"
+#define GOSSIP_TEXT_WEAPONMASTER "The weapon master"
+#define GOSSIP_TEXT_OFFICERS "The officers' lounge"
+#define GOSSIP_TEXT_BATTLEMASTER "The battlemaster"
+#define GOSSIP_TEXT_BARBER "Barber"
+#define GOSSIP_TEXT_CLASSTRAINER "A class trainer"
+#define GOSSIP_TEXT_PROFTRAINER "A profession trainer"
+#define GOSSIP_TEXT_LEXICON "Lexicon of Power"
#define GOSSIP_TEXT_ALTERACVALLEY "Alterac Valley"
#define GOSSIP_TEXT_ARATHIBASIN "Arathi Basin"
#define GOSSIP_TEXT_WARSONGULCH "Warsong Gulch"
#define GOSSIP_TEXT_ARENA "Arena"
#define GOSSIP_TEXT_EYEOFTHESTORM "Eye of The Storm"
+#define GOSSIP_TEXT_STRANDOFANCIENT "Strand of the Ancients"
+#define GOSSIP_TEXT_DEATH_KNIGHT "Death Knight"
#define GOSSIP_TEXT_DRUID "Druid"
#define GOSSIP_TEXT_HUNTER "Hunter"
#define GOSSIP_TEXT_PRIEST "Priest"
@@ -57,18 +66,12 @@
#define GOSSIP_TEXT_FIRSTAID "First Aid"
#define GOSSIP_TEXT_HERBALISM "Herbalism"
#define GOSSIP_TEXT_LEATHERWORKING "Leatherworking"
-#define GOSSIP_TEXT_POISONS "Poisons"
#define GOSSIP_TEXT_TAILORING "Tailoring"
#define GOSSIP_TEXT_MINING "Mining"
#define GOSSIP_TEXT_FISHING "Fishing"
#define GOSSIP_TEXT_SKINNING "Skinning"
#define GOSSIP_TEXT_JEWELCRAFTING "Jewelcrafting"
-
-#define GOSSIP_TEXT_IRONFORGE_BANK "Bank of Ironforge"
-#define GOSSIP_TEXT_STORMWIND_BANK "Bank of Stormwind"
-#define GOSSIP_TEXT_DEEPRUNTRAM "Deeprun Tram"
-#define GOSSIP_TEXT_ZEPPLINMASTER "Zeppelin master"
-#define GOSSIP_TEXT_FERRY "Rut'theran Ferry"
+#define GOSSIP_TEXT_INSCRIPTION "Inscription"
// Skill defines
@@ -86,6 +89,7 @@
#define TRADESKILL_FISHING 12
#define TRADESKILL_SKINNING 13
#define TRADESKILL_JEWLCRAFTING 14
+#define TRADESKILL_INSCRIPTION 15
#define TRADESKILL_LEVEL_NONE 0
#define TRADESKILL_LEVEL_APPRENTICE 1
@@ -93,6 +97,7 @@
#define TRADESKILL_LEVEL_EXPERT 3
#define TRADESKILL_LEVEL_ARTISAN 4
#define TRADESKILL_LEVEL_MASTER 5
+#define TRADESKILL_LEVEL_GRAND_MASTER 6
// Gossip defines
diff --git a/src/bindings/scripts/include/sc_instance.h b/src/bindings/scripts/include/sc_instance.h
index 75a25490419..2f1cd3a16a6 100644
--- a/src/bindings/scripts/include/sc_instance.h
+++ b/src/bindings/scripts/include/sc_instance.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/areatrigger/areatrigger_scripts.cpp b/src/bindings/scripts/scripts/areatrigger/areatrigger_scripts.cpp
index 6767a8fe88b..1c1b7312cb3 100644
--- a/src/bindings/scripts/scripts/areatrigger/areatrigger_scripts.cpp
+++ b/src/bindings/scripts/scripts/areatrigger/areatrigger_scripts.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,7 +23,6 @@ EndScriptData */
/* ContentData
at_legion_teleporter 4560 Teleporter TO Invasion Point: Cataclysm
-at_test script test only
EndContentData */
#include "precompiled.h"
@@ -56,12 +55,6 @@ bool AreaTrigger_at_legion_teleporter(Player *player, AreaTriggerEntry *at)
return false;
}
-bool ATtest(Player *player, AreaTriggerEntry *at)
-{
- player->Say("Hi!",LANG_UNIVERSAL);
- return true;
-}
-
void AddSC_areatrigger_scripts()
{
Script *newscript;
@@ -70,10 +63,5 @@ void AddSC_areatrigger_scripts()
newscript->Name = "at_legion_teleporter";
newscript->pAreaTrigger = &AreaTrigger_at_legion_teleporter;
newscript->RegisterSelf();
-
- newscript = new Script;
- newscript->Name="at_test";
- newscript->pAreaTrigger = &ATtest;
- newscript->RegisterSelf();
}
diff --git a/src/bindings/scripts/scripts/boss/boss_emeriss.cpp b/src/bindings/scripts/scripts/boss/boss_emeriss.cpp
index eecd2595a68..08b374c443e 100644
--- a/src/bindings/scripts/scripts/boss/boss_emeriss.cpp
+++ b/src/bindings/scripts/scripts/boss/boss_emeriss.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/boss/boss_lethon.cpp b/src/bindings/scripts/scripts/boss/boss_lethon.cpp
index 721009ac68c..e387891efed 100644
--- a/src/bindings/scripts/scripts/boss/boss_lethon.cpp
+++ b/src/bindings/scripts/scripts/boss/boss_lethon.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/boss/boss_taerar.cpp b/src/bindings/scripts/scripts/boss/boss_taerar.cpp
index 57184aa4b98..0d046456523 100644
--- a/src/bindings/scripts/scripts/boss/boss_taerar.cpp
+++ b/src/bindings/scripts/scripts/boss/boss_taerar.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/boss/boss_ysondre.cpp b/src/bindings/scripts/scripts/boss/boss_ysondre.cpp
index fca9bc4b15b..0cfbc37b374 100644
--- a/src/bindings/scripts/scripts/boss/boss_ysondre.cpp
+++ b/src/bindings/scripts/scripts/boss/boss_ysondre.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/creature/mob_event_ai.cpp b/src/bindings/scripts/scripts/creature/mob_event_ai.cpp
deleted file mode 100644
index b1af88b948f..00000000000
--- a/src/bindings/scripts/scripts/creature/mob_event_ai.cpp
+++ /dev/null
@@ -1,1445 +0,0 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License as published by
- * the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
- */
-
-/* ScriptData
-SDName: Mob_Event_AI
-SD%Complete: 90
-SDComment: Database Event AI
-SDCategory: Creatures
-EndScriptData */
-
-#include "precompiled.h"
-#include "mob_event_ai.h"
-#include "ObjectMgr.h"
-
-#define EVENT_UPDATE_TIME 500
-#define SPELL_RUN_AWAY 8225
-
-struct EventHolder
-{
- EventHolder(EventAI_Event p) : Event(p), Time(0), Enabled(true){}
-
- EventAI_Event Event;
- uint32 Time;
- bool Enabled;
-};
-
-struct TRINITY_DLL_DECL Mob_EventAI : public ScriptedAI
-{
- Mob_EventAI(Creature *c, std::list<EventHolder> pEventList) : ScriptedAI(c)
- {
- EventList = pEventList;
- Phase = 0;
- CombatMovementEnabled = true;
- MeleeEnabled = true;
- AttackDistance = 0;
- AttackAngle = 0.0f;
-
- //Handle Spawned Events
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- switch ((*i).Event.event_type)
- {
- case EVENT_T_SPAWNED:
- ProcessEvent(*i);
- break;
- }
- }
- }
-
- ~Mob_EventAI()
- {
- EventList.clear();
- }
-
- //Variables used by EventAI for handling events
- std::list<EventHolder> EventList; //Holder for events (stores enabled, time, and eventid)
- uint32 EventUpdateTime; //Time between event updates
- uint32 EventDiff; //Time between the last event call
-
- //Variables used by Events themselves
- uint8 Phase; //Current phase, max 32 phases
- bool CombatMovementEnabled; //If we allow targeted movment gen (movement twoards top threat)
- bool MeleeEnabled; //If we allow melee auto attack
- uint32 AttackDistance; //Distance to attack from
- float AttackAngle; //Angle of attack
- uint32 TimetoFleeLeft; //For fleeing
-
- bool ProcessEvent(EventHolder& pHolder, Unit* pActionInvoker = NULL)
- {
- if (!pHolder.Enabled || pHolder.Time)
- return false;
-
- //Check the inverse phase mask (event doesn't trigger if current phase bit is set in mask)
- if (pHolder.Event.event_inverse_phase_mask & (1 << Phase))
- return false;
-
- //Store random here so that all random actions match up
- uint32 rnd = rand();
-
- //Return if chance for event is not met
- if (pHolder.Event.event_chance <= rnd % 100)
- return false;
-
- union
- {
- uint32 param1;
- int32 param1_s;
- };
-
- union
- {
- uint32 param2;
- int32 param2_s;
- };
-
- union
- {
- uint32 param3;
- int32 param3_s;
- };
-
- union
- {
- uint32 param4;
- int32 param4_s;
- };
-
- param1 = pHolder.Event.event_param1;
- param2 = pHolder.Event.event_param2;
- param3 = pHolder.Event.event_param3;
- param4 = pHolder.Event.event_param4;
-
- //Check event conditions based on the event type, also reset events
- switch (pHolder.Event.event_type)
- {
- case EVENT_T_TIMER:
- {
- if (!InCombat)
- return false;
-
- //Repeat Timers
- if (param3 == param4)
- {
- pHolder.Time = param3;
-
- }else if (param4 > param3)
- pHolder.Time = urand(param3, param4);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_TIMER_OOC:
- {
- if (InCombat)
- return false;
-
- //Repeat Timers
- if (param3 == param4)
- {
- pHolder.Time = param3;
-
- }else if (param4 > param3)
- pHolder.Time = urand(param3, param4);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_HP:
- {
- if (!InCombat || !m_creature->GetMaxHealth())
- return false;
-
- uint32 perc = (m_creature->GetHealth()*100) / m_creature->GetMaxHealth();
-
- if (perc > param1 || perc < param2)
- return false;
-
- //Repeat Timers
- if (param3 == param4)
- {
- pHolder.Time = param3;
-
- }else if (param4 > param3)
- pHolder.Time = urand(param3, param4);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_MANA:
- {
- if (!InCombat || !m_creature->GetMaxPower(POWER_MANA))
- return false;
-
- uint32 perc = (m_creature->GetPower(POWER_MANA)*100) / m_creature->GetMaxPower(POWER_MANA);
-
- if (perc > param1 || perc < param2)
- return false;
-
- //Repeat Timers
- if (param3 == param4)
- {
- pHolder.Time = param3;
-
- }else if (param4 > param3)
- pHolder.Time = urand(param3, param4);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_AGGRO:
- {
- }
- break;
- case EVENT_T_KILL:
- {
- //Repeat Timers
- if (param1 == param2)
- {
- pHolder.Time = param1;
-
- }else if (param2 > param1)
- pHolder.Time = urand(param1, param2);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- case EVENT_T_DEATH:
- {
- }
- break;
- case EVENT_T_EVADE:
- {
- }
- break;
- case EVENT_T_SPELLHIT:
- {
- //Spell hit is special case, param1 and param2 handled within EventAI::SpellHit
-
- //Repeat Timers
- if (param3 == param4)
- {
- pHolder.Time = param3;
-
- }else if (param4 > param3)
- pHolder.Time = urand(param3, param4);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_RANGE:
- {
- //Repeat Timers
- if (param3 == param4)
- {
- pHolder.Time = param3;
-
- }else if (param4 > param3)
- pHolder.Time = urand(param3, param4);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_OOC_LOS:
- {
- //Repeat Timers
- if (param3 == param4)
- {
- pHolder.Time = param3;
-
- }else if (param4 > param3)
- pHolder.Time = urand(param3, param4);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_SPAWNED:
- {
- }
- break;
- case EVENT_T_TARGET_HP:
- {
- if (!InCombat || !m_creature->getVictim() || !m_creature->getVictim()->GetMaxHealth())
- return false;
-
- uint32 perc = (m_creature->getVictim()->GetHealth()*100) / m_creature->getVictim()->GetMaxHealth();
-
- if (perc > param1 || perc < param2)
- return false;
-
- //Repeat Timers
- if (param3 == param4)
- {
- pHolder.Time = param3;
-
- }else if (param4 > param3)
- pHolder.Time = urand(param3, param4);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_TARGET_CASTING:
- {
- if (!InCombat || !m_creature->getVictim() || !m_creature->getVictim()->IsNonMeleeSpellCasted(false, false, true))
- return false;
-
- //Repeat Timers
- if (param1 == param2)
- {
- pHolder.Time = param1;
-
- }else if (param2 > param1)
- pHolder.Time = urand(param1, param2);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_FRIENDLY_HP:
- {
- if (!InCombat)
- return false;
-
- Unit* pUnit = DoSelectLowestHpFriendly(param2, param1);
-
- if (!pUnit)
- return false;
-
- pActionInvoker = pUnit;
-
- //Repeat Timers
- if (param3 == param4)
- {
- pHolder.Time = param3;
-
- }else if (param4 > param3)
- pHolder.Time = urand(param3, param4);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_FRIENDLY_IS_CC:
- {
- if (!InCombat)
- return false;
-
- std::list<Creature*> pList = DoFindFriendlyCC(param2);
-
- //List is empty
- if (pList.empty())
- return false;
-
- //We don't really care about the whole list, just return first available
- pActionInvoker = *(pList.begin());
-
- //Repeat Timers
- if (param3 == param4)
- {
- pHolder.Time = param3;
-
- }else if (param4 > param3)
- pHolder.Time = urand(param3, param4);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_FRIENDLY_MISSING_BUFF:
- {
- std::list<Creature*> pList = DoFindFriendlyMissingBuff(param2, param1);
-
- //List is empty
- if (pList.empty())
- return false;
-
- //We don't really care about the whole list, just return first available
- pActionInvoker = *(pList.begin());
-
- //Repeat Timers
- if (param3 == param4)
- {
- pHolder.Time = param3;
-
- }else if (param4 > param3)
- pHolder.Time = urand(param3, param4);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_SUMMONED_UNIT:
- {
- //Prevent event from occuring on no unit or non creatures
- if (!pActionInvoker || pActionInvoker->GetTypeId()!=TYPEID_UNIT)
- return false;
-
- //Creature id doesn't match up
- if (param1 && ((Creature*)pActionInvoker)->GetEntry() != param1)
- return false;
-
- //Repeat Timers
- if (param2 == param3)
- {
- pHolder.Time = param2;
-
- }else if (param3 > param2)
- pHolder.Time = urand(param2, param3);
- else
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has RandomMax < RandomMin. Event repeating disabled.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- pHolder.Enabled = false;
- }
- }
- break;
- case EVENT_T_REACHED_HOME:
- {
- }
- break;
- default:
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u has invalid Event Type(%u), missing from ProcessEvent() Switch.", m_creature->GetEntry(), pHolder.Event.event_id, pHolder.Event.event_type);
- break;
- }
-
- //Disable non-repeatable events
- if (!(pHolder.Event.event_flags & EFLAG_REPEATABLE))
- pHolder.Enabled = false;
-
- //Process actions
- for (uint32 j = 0; j < MAX_ACTIONS; j++)
- ProcessAction(pHolder.Event.action[j].type, pHolder.Event.action[j].param1, pHolder.Event.action[j].param2, pHolder.Event.action[j].param3, rnd, pHolder.Event.event_id, pActionInvoker);
-
- return true;
- }
-
- inline uint32 GetRandActionParam(uint32 rnd, uint32 param1, uint32 param2, uint32 param3)
- {
- switch (rnd % 3)
- {
- case 0:
- return param1;
- break;
- case 1:
- return param2;
- break;
- case 2:
- return param3;
- break;
- }
- return 0;
- }
-
- inline Unit* GetTargetByType(uint32 Target, Unit* pActionInvoker)
- {
- switch (Target)
- {
- case TARGET_T_SELF:
- return m_creature;
- break;
- case TARGET_T_HOSTILE:
- return m_creature->getVictim();
- break;
- case TARGET_T_HOSTILE_SECOND_AGGRO:
- return SelectUnit(SELECT_TARGET_TOPAGGRO,1);
- break;
- case TARGET_T_HOSTILE_LAST_AGGRO:
- return SelectUnit(SELECT_TARGET_BOTTOMAGGRO,0);
- break;
- case TARGET_T_HOSTILE_RANDOM:
- return SelectUnit(SELECT_TARGET_RANDOM,0);
- break;
- case TARGET_T_HOSTILE_RANDOM_NOT_TOP:
- return SelectUnit(SELECT_TARGET_RANDOM,1);
- break;
- case TARGET_T_ACTION_INVOKER:
- return pActionInvoker;
- break;
- default:
- return NULL;
- break;
- };
- }
-
- void ProcessAction(uint16 type, uint32 param1, uint32 param2, uint32 param3, uint32 rnd, uint32 EventId, Unit* pActionInvoker)
- {
- switch (type)
- {
- case ACTION_T_TEXT:
- {
- if (!param1)
- return;
-
- uint32 temp = 0;
-
- if (param2 && param3)
- {
- switch( rand()%3 )
- {
- case 0: temp = param1; break;
- case 2: temp = param2; break;
- case 3: temp = param3; break;
- }
- }else if ( param2 && urand(0,1) )
- {
- temp = param2;
- }else
- {
- temp = param1;
- }
-
- if (temp)
- {
- Unit* target = NULL;
- Unit* owner = NULL;
-
- if (pActionInvoker)
- {
- if (pActionInvoker->GetTypeId() == TYPEID_PLAYER)
- target = pActionInvoker;
- else if (owner = pActionInvoker->GetOwner())
- {
- if (owner->GetTypeId() == TYPEID_PLAYER)
- target = owner;
- }
- }
- else if (target = m_creature->getVictim())
- {
- if (target->GetTypeId() != TYPEID_PLAYER)
- {
- if (owner = target->GetOwner())
- {
- if (owner->GetTypeId() == TYPEID_PLAYER)
- target = owner;
- }
- }
- }
-
- DoScriptText(temp, m_creature, target);
- }
- }
- break;
- case ACTION_T_SET_FACTION:
- {
- if (param1)
- m_creature->setFaction(param1);
- else
- {
- if (CreatureInfo const* ci = GetCreatureTemplateStore(m_creature->GetEntry()))
- {
- //if no id provided, assume reset and then use default
- if (m_creature->getFaction() != ci->faction_A)
- m_creature->setFaction(ci->faction_A);
- }
- }
- }
- break;
- case ACTION_T_MORPH_TO_ENTRY_OR_MODEL:
- {
- if (param1 || param2)
- {
- //set model based on entry from creature_template
- if (param1)
- {
- if (CreatureInfo const* ci = GetCreatureTemplateStore(param1))
- {
- //use default display
- if (ci->Modelid_A1)
- m_creature->SetDisplayId(ci->Modelid_A1);
- }
- }
- //if no param1, then use value from param2 (modelId)
- else
- m_creature->SetDisplayId(param2);
- }
- else
- m_creature->DeMorph();
- }
- break;
- case ACTION_T_SOUND:
- DoPlaySoundToSet(m_creature, param1);
- break;
- case ACTION_T_EMOTE:
- m_creature->HandleEmoteCommand(param1);
- break;
- case ACTION_T_RANDOM_SOUND:
- {
- uint32 temp = GetRandActionParam(rnd, param1, param2, param3);
-
- if (temp != 0xffffffff)
- DoPlaySoundToSet(m_creature, temp);
- }
- break;
- case ACTION_T_RANDOM_EMOTE:
- {
- uint32 temp = GetRandActionParam(rnd, param1, param2, param3);
-
- if (temp != 0xffffffff)
- m_creature->HandleEmoteCommand(temp);
- }
- break;
- case ACTION_T_CAST:
- {
- Unit* target = GetTargetByType(param2, pActionInvoker);
- Unit* caster = m_creature;
-
- if (!target)
- return;
-
- //Cast is always triggered if target is forced to cast on self
- if (param3 & CAST_FORCE_TARGET_SELF)
- {
- param3 |= CAST_TRIGGERED;
- caster = target;
- }
-
- //Allowed to cast only if not casting (unless we interrupt ourself) or if spell is triggered
- bool canCast = !(caster->IsNonMeleeSpellCasted(false) && (param3 & CAST_TRIGGERED | CAST_INTURRUPT_PREVIOUS));
-
- // If cast flag CAST_AURA_NOT_PRESENT is active, check if target already has aura on them
- if(param3 & CAST_AURA_NOT_PRESENT)
- {
- for(uint8 i = 0; i < 3; ++i)
- if(target->HasAura(param1, i))
- return;
- }
-
- if (canCast)
- {
- const SpellEntry* tSpell = GetSpellStore()->LookupEntry(param1);
-
- //Verify that spell exists
- if (tSpell)
- {
- //Check if cannot cast spell
- if (!(param3 & (CAST_FORCE_TARGET_SELF | CAST_FORCE_CAST)) &&
- !CanCast(target, tSpell, (param3 & CAST_TRIGGERED)))
- {
- //Melee current victim if flag not set
- if (!(param3 & CAST_NO_MELEE_IF_OOM))
- {
- AttackDistance = 0;
- AttackAngle = 0;
-
- m_creature->GetMotionMaster()->MoveChase(m_creature->getVictim(), AttackDistance, AttackAngle);
- }
-
- }else
- {
- //Interrupt any previous spell
- if (caster->IsNonMeleeSpellCasted(false) && param3 & CAST_INTURRUPT_PREVIOUS)
- caster->InterruptNonMeleeSpells(false);
-
- caster->CastSpell(target, param1, (param3 & CAST_TRIGGERED));
- }
-
- }else if (EAI_ErrorLevel > 0)
- error_db_log("SD2: EventAI event %d creature %d attempt to cast spell that doesn't exist %d", EventId, m_creature->GetEntry(), param1);
- }
- }
- break;
- case ACTION_T_SUMMON:
- {
- Unit* target = GetTargetByType(param2, pActionInvoker);
-
- Creature* pCreature = NULL;
-
- if (param3)
- pCreature = DoSpawnCreature(param1, 0, 0, 0, 0, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, param3);
- else pCreature = pCreature = DoSpawnCreature(param1, 0, 0, 0, 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 0);
-
- if (!pCreature)
- {
- if (EAI_ErrorLevel > 0)
- error_db_log( "SD2: EventAI failed to spawn creature %u. Spawn event %d is on creature %d", param1, EventId, m_creature->GetEntry());
- }
- else if (param2 != TARGET_T_SELF && target)
- pCreature->AI()->AttackStart(target);
- }
- break;
- case ACTION_T_THREAT_SINGLE_PCT:
- {
- Unit* target = GetTargetByType(param2, pActionInvoker);
-
- if (target)
- DoModifyThreatPercent(target, param1);
- }
- break;
- case ACTION_T_THREAT_ALL_PCT:
- {
- Unit* Temp = NULL;
-
- std::list<HostilReference*>::iterator i = m_creature->getThreatManager().getThreatList().begin();
- for (; i != m_creature->getThreatManager().getThreatList().end(); ++i)
- {
- Temp = Unit::GetUnit((*m_creature),(*i)->getUnitGuid());
- if (Temp)
- DoModifyThreatPercent(Temp, param1);
- }
- }
- break;
- case ACTION_T_QUEST_EVENT:
- {
- Unit* target = GetTargetByType(param2, pActionInvoker);
-
- if (target && target->GetTypeId() == TYPEID_PLAYER)
- ((Player*)target)->AreaExploredOrEventHappens(param1);
- }
- break;
- case ACTION_T_CASTCREATUREGO:
- {
- Unit* target = GetTargetByType(param3, pActionInvoker);
-
- if (target && target->GetTypeId() == TYPEID_PLAYER)
- ((Player*)target)->CastedCreatureOrGO(param1, m_creature->GetGUID(), param2);
- }
- break;
- case ACTION_T_SET_UNIT_FIELD:
- {
- Unit* target = GetTargetByType(param3, pActionInvoker);
-
- if (param1 < OBJECT_END || param1 >= UNIT_END)
- return;
-
- if (target)
- target->SetUInt32Value(param1, param2);
- }
- break;
- case ACTION_T_SET_UNIT_FLAG:
- {
- Unit* target = GetTargetByType(param2, pActionInvoker);
-
- if (target)
- target->SetFlag(UNIT_FIELD_FLAGS, param1);
- }
- break;
- case ACTION_T_REMOVE_UNIT_FLAG:
- {
- Unit* target = GetTargetByType(param2, pActionInvoker);
-
- if (target)
- target->RemoveFlag(UNIT_FIELD_FLAGS, param1);
- }
- break;
- case ACTION_T_AUTO_ATTACK:
- {
- if (param1)
- MeleeEnabled = true;
- else MeleeEnabled = false;
- }
- break;
- case ACTION_T_COMBAT_MOVEMENT:
- {
- CombatMovementEnabled = param1;
-
- //Allow movement (create new targeted movement gen if none exist already)
- if (CombatMovementEnabled)
- {
- m_creature->GetMotionMaster()->MoveChase(m_creature->getVictim(), AttackDistance, AttackAngle);
- }
- else
- {
- m_creature->GetMotionMaster()->MoveIdle();
- }
- }
- break;
- case ACTION_T_SET_PHASE:
- {
- Phase = param1;
- }
- break;
- case ACTION_T_INC_PHASE:
- {
- Phase += param1;
-
- if (Phase > 31)
- if (EAI_ErrorLevel > 0)
- error_db_log( "SD2: Event %d incremented Phase above 31. Phase mask cannot be used with phases past 31. CreatureEntry = %d", EventId, m_creature->GetEntry());
- }
- break;
- case ACTION_T_EVADE:
- {
- EnterEvadeMode();
- }
- break;
- case ACTION_T_FLEE:
- {
- if(m_creature->HasAuraType(SPELL_AURA_PREVENTS_FLEEING))
- break;
- TimetoFleeLeft = 8000;
- m_creature->DoFleeToGetAssistance();
- IsFleeing = true;
- }
- break;
- case ACTION_T_QUEST_EVENT_ALL:
- {
- Unit* Temp = NULL;
- if( pActionInvoker && pActionInvoker->GetTypeId() == TYPEID_PLAYER )
- {
- Temp = Unit::GetUnit((*m_creature),pActionInvoker->GetGUID());
- if( Temp )
- ((Player*)Temp)->GroupEventHappens(param1,m_creature);
- }
- }
- break;
- case ACTION_T_CASTCREATUREGO_ALL:
- {
- Unit* Temp = NULL;
-
- std::list<HostilReference*>::iterator i = m_creature->getThreatManager().getThreatList().begin();
- for (; i != m_creature->getThreatManager().getThreatList().end(); ++i)
- {
- Temp = Unit::GetUnit((*m_creature),(*i)->getUnitGuid());
- if (Temp && Temp->GetTypeId() == TYPEID_PLAYER)
- ((Player*)Temp)->CastedCreatureOrGO(param1, m_creature->GetGUID(), param2);
- }
- }
- break;
- case ACTION_T_REMOVEAURASFROMSPELL:
- {
- Unit* target = GetTargetByType(param1, pActionInvoker);
-
- if (target)
- target->RemoveAurasDueToSpell(param2);
- }
- break;
- case ACTION_T_RANGED_MOVEMENT:
- {
- AttackDistance = param1;
- AttackAngle = ((float)param2/180)*M_PI;
-
- if (CombatMovementEnabled)
- {
- m_creature->GetMotionMaster()->MoveChase(m_creature->getVictim(), AttackDistance, AttackAngle);
- }
- }
- break;
- case ACTION_T_RANDOM_PHASE:
- {
- uint32 temp = GetRandActionParam(rnd, param1, param2, param3);
-
- Phase = temp;
- }
- break;
- case ACTION_T_RANDOM_PHASE_RANGE:
- {
- if (param2 > param1)
- {
- Phase = param1 + (rnd % (param2 - param1));
- }
- else if (EAI_ErrorLevel > 0)
- error_db_log( "SD2: ACTION_T_RANDOM_PHASE_RANGE cannot have Param2 <= Param1. Divide by Zero. Event = %d. CreatureEntry = %d", EventId, m_creature->GetEntry());
- }
- break;
- case ACTION_T_SUMMON_ID:
- {
- Unit* target = GetTargetByType(param2, pActionInvoker);
-
- //Duration
- Creature* pCreature = NULL;
-
- UNORDERED_MAP<uint32, EventAI_Summon>::iterator i = EventAI_Summon_Map.find(param3);
-
- if (i == EventAI_Summon_Map.end())
- {
- if (EAI_ErrorLevel > 0)
- error_db_log( "SD2: EventAI failed to spawn creature %u. Summon map index %u does not exist. EventID %d. CreatureID %d", param1, param3, EventId, m_creature->GetEntry());
- return;
- }
-
- if ((*i).second.SpawnTimeSecs)
- pCreature = m_creature->SummonCreature(param1, (*i).second.position_x, (*i).second.position_y, (*i).second.position_z, (*i).second.orientation, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, (*i).second.SpawnTimeSecs);
- else pCreature = m_creature->SummonCreature(param1, (*i).second.position_x, (*i).second.position_y, (*i).second.position_z, (*i).second.orientation, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 0);
-
- if (!pCreature)
- {
- if (EAI_ErrorLevel > 0)
- error_db_log( "SD2: EventAI failed to spawn creature %u. EventId %d.Creature %d", param1, EventId, m_creature->GetEntry());
- }
- else if (param2 != TARGET_T_SELF && target)
- pCreature->AI()->AttackStart(target);
- }
- break;
- case ACTION_T_KILLED_MONSTER:
- {
- Unit* target = GetTargetByType(param2, pActionInvoker);
-
- if (target && target->GetTypeId() == TYPEID_PLAYER)
- ((Player*)target)->KilledMonster(param1, m_creature->GetGUID());
- }
- break;
- case ACTION_T_SET_INST_DATA:
- {
- ScriptedInstance* pInst = (ScriptedInstance*)m_creature->GetInstanceData();
- if (!pInst)
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Event %d attempt to set instance data without instance script. Creature %d", EventId, m_creature->GetEntry());
- return;
- }
-
- pInst->SetData(param1, param2);
- }
- break;
- case ACTION_T_SET_INST_DATA64:
- {
- Unit* target = GetTargetByType(param2, pActionInvoker);
-
- if (!target)
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Event %d attempt to set instance data64 but Target == NULL. Creature %d", EventId, m_creature->GetEntry());
- return;
- }
-
- ScriptedInstance* pInst = (ScriptedInstance*)m_creature->GetInstanceData();
-
- if (!pInst)
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Event %d attempt to set instance data64 without instance script. Creature %d", EventId, m_creature->GetEntry());
- return;
- }
-
- pInst->SetData64(param1, target->GetGUID());
- }
- break;
- case ACTION_T_UPDATE_TEMPLATE:
- {
- if (m_creature->GetEntry() == param1)
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Event %d ACTION_T_UPDATE_TEMPLATE call with param1 == current entry. Creature %d", EventId, m_creature->GetEntry());
- return;
- }
-
- m_creature->UpdateEntry(param1, param2 ? HORDE : ALLIANCE);
- }
- break;
- case ACTION_T_DIE:
- {
- if (m_creature->isDead())
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Event %d ACTION_T_DIE on dead creature. Creature %d", EventId, m_creature->GetEntry());
- return;
- }
- m_creature->DealDamage(m_creature, m_creature->GetMaxHealth(),NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
- }
- break;
- case ACTION_T_ZONE_COMBAT_PULSE:
- {
- if (!m_creature->isInCombat() || !m_creature->GetMap()->IsDungeon())
- {
- if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Event %d ACTION_T_ZONE_COMBAT_PULSE on creature out of combat or in non-dungeon map. Creature %d", EventId, m_creature->GetEntry());
- return;
- }
-
- DoZoneInCombat();
- }
- break;
- case ACTION_T_SUMMON_GO:
- {
- GameObject* pObject = NULL;
-
- float x,y,z;
- m_creature->GetPosition(x,y,z);
- pObject = m_creature->SummonGameObject(param1, x, y, z, 0, 0, 0, 0, 0, param2);
- if (!pObject)
- {
- if (EAI_ErrorLevel > 0)
- error_db_log( "SD2: EventAI failed to spawn object %u. Spawn event %d is on creature %d", param1, EventId, m_creature->GetEntry());
- }
- }
- break;
-
- // TRINITY ONLY
- case ACTION_T_SET_ACTIVE:
- m_creature->setActive(param1 ? true : false);
- break;
- case ACTION_T_SET_AGGRESSIVE:
- m_creature->SetReactState(ReactStates(param1));
- break;
- case ACTION_T_ATTACK_START_PULSE:
- AttackStart(m_creature->SelectNearestTarget((float)param1));
- break;
- }
- }
-
- void JustRespawned()
- {
- InCombat = false;
- IsFleeing = false;
- Reset();
-
- //Handle Spawned Events
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- switch ((*i).Event.event_type)
- {
- case EVENT_T_SPAWNED:
- ProcessEvent(*i);
- break;
- }
- }
- }
-
- void Reset()
- {
- EventUpdateTime = EVENT_UPDATE_TIME;
- EventDiff = 0;
-
- //Reset all events to enabled
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- switch ((*i).Event.event_type)
- {
- //Reset all out of combat timers
- case EVENT_T_TIMER_OOC:
- {
- if ((*i).Event.event_param2 == (*i).Event.event_param1)
- {
- (*i).Time = (*i).Event.event_param1;
- (*i).Enabled = true;
- }else if ((*i).Event.event_param2 > (*i).Event.event_param1)
- {
- (*i).Time = urand((*i).Event.event_param1, (*i).Event.event_param2);
- (*i).Enabled = true;
- }else if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has InitialMax < InitialMin. Event disabled.", m_creature->GetEntry(), (*i).Event.event_id, (*i).Event.event_type);
- }
- break;
- //default:
- //TODO: enable below code line / verify this is correct to enable events previously disabled (ex. aggro yell), instead of enable this in void Aggro()
- //(*i).Enabled = true;
- //(*i).Time = 0;
- //break;
- }
- }
- }
-
- //when creature reach home after EnterEvadeMode
- void JustReachedHome()
- {
- m_creature->LoadCreaturesAddon();
-
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- if ((*i).Event.event_type == EVENT_T_REACHED_HOME)
- ProcessEvent(*i);
- }
-
- Reset();
- }
-
- void EnterEvadeMode()
- {
- ScriptedAI::EnterEvadeMode();
-
- IsFleeing = false;
-
- //Handle Evade events
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- if ((*i).Event.event_type == EVENT_T_EVADE)
- ProcessEvent(*i);
- }
- }
-
- void JustDied(Unit* killer)
- {
- InCombat = false;
- IsFleeing = false;
- Reset();
-
- //Handle Evade events
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- switch ((*i).Event.event_type)
- {
- //Evade
- case EVENT_T_DEATH:
- ProcessEvent(*i, killer);
- break;
- }
- }
- }
-
- void KilledUnit(Unit* victim)
- {
- if (victim->GetTypeId() != TYPEID_PLAYER)
- return;
-
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- switch ((*i).Event.event_type)
- {
- //Kill
- case EVENT_T_KILL:
- ProcessEvent(*i, victim);
- break;
- }
- }
-
- }
-
- void JustSummoned(Creature* pUnit)
- {
- if (!pUnit)
- return;
-
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- switch ((*i).Event.event_type)
- {
- //Summoned
- case EVENT_T_SUMMONED_UNIT:
- ProcessEvent(*i, pUnit);
- break;
- }
- }
- }
-
- void Aggro(Unit *who)
- {
- //Check for on combat start events
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- switch ((*i).Event.event_type)
- {
- case EVENT_T_AGGRO:
- (*i).Enabled = true;
- ProcessEvent(*i, who);
- break;
- //Reset all in combat timers
- case EVENT_T_TIMER:
- if ((*i).Event.event_param2 == (*i).Event.event_param1)
- {
- (*i).Time = (*i).Event.event_param1;
- (*i).Enabled = true;
- }else if ((*i).Event.event_param2 > (*i).Event.event_param1)
- {
- (*i).Time = urand((*i).Event.event_param1, (*i).Event.event_param2);
- (*i).Enabled = true;
- }else if (EAI_ErrorLevel > 0)
- error_db_log("SD2: Creature %u using Event %u (Type = %u) has InitialMax < InitialMin. Event disabled.", m_creature->GetEntry(), (*i).Event.event_id, (*i).Event.event_type);
- break;
- //All normal events need to be re-enabled and their time set to 0
- default:
- (*i).Enabled = true;
- (*i).Time = 0;
- break;
- }
- }
-
- EventUpdateTime = EVENT_UPDATE_TIME;
- EventDiff = 0;
- }
-
- void AttackStart(Unit *who)
- {
- if (!who)
- return;
-
- if (m_creature->Attack(who, MeleeEnabled))
- {
- //Begin melee attack if we are within range
-
- if (!InCombat)
- {
- InCombat = true;
- Aggro(who);
- }
-
- if (CombatMovementEnabled)
- {
- m_creature->GetMotionMaster()->MoveChase(who, AttackDistance, AttackAngle);
- }
- else
- {
- m_creature->GetMotionMaster()->MoveIdle();
- }
- }
- }
-
- void MoveInLineOfSight(Unit *who)
- {
- if (!who || InCombat)
- return;
-
- //Check for OOC LOS Event
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- switch ((*i).Event.event_type)
- {
- case EVENT_T_OOC_LOS:
- {
- if ((*i).Event.event_param1 && m_creature->IsHostileTo(who))
- break;
-
- if ((*i).Event.event_param2 && !m_creature->IsHostileTo(who))
- break;
-
- ProcessEvent(*i, who);
- }
- break;
- }
- }
-
- // do we need this?
- //if (m_creature->isCivilian() && m_creature->IsNeutralToAll())
- // return;
-
- if(m_creature->canStartAttack(who))
- AttackStart(who);
- }
-
- void SpellHit(Unit* pUnit, const SpellEntry* pSpell)
- {
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- switch ((*i).Event.event_type)
- {
- //Spell hit
- case EVENT_T_SPELLHIT:
- {
- //If spell id matches (or no spell id) & if spell school matches (or no spell school)
- if (!(*i).Event.event_param1 || pSpell->Id == (*i).Event.event_param1)
- if ((*i).Event.event_param2_s == -1 || pSpell->SchoolMask == (*i).Event.event_param2)
- ProcessEvent(*i, pUnit);
- }
- break;
- }
- }
- }
-
- void UpdateAI(const uint32 diff)
- {
- //Check if we are in combat (also updates calls threat update code)
- bool Combat = InCombat ? UpdateVictim() : false;
-
- //Must return if creature isn't alive. Normally select hostil target and get victim prevent this
- if (!m_creature->isAlive())
- return;
-
- if (IsFleeing)
- {
- if(TimetoFleeLeft < diff)
- {
- m_creature->SetControlled(false, UNIT_STAT_FLEEING);
- m_creature->SetNoCallAssistance(false);
- m_creature->CallAssistance();
- if(m_creature->getVictim())
- m_creature->GetMotionMaster()->MoveChase(m_creature->getVictim());
- IsFleeing = false;
- }
- else
- TimetoFleeLeft -= diff;
-
- return;
- }
-
- //Events are only updated once every EVENT_UPDATE_TIME ms to prevent lag with large amount of events
- if (EventUpdateTime < diff)
- {
- EventDiff += diff;
-
- //Check for range based events
- //if (m_creature->GetDistance(m_creature->getVictim()) >
- if (Combat)
- {
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- switch ((*i).Event.event_type)
- {
- case EVENT_T_RANGE:
- // in some cases this is called twice and victim may not exist in the second time
- if(m_creature->getVictim())
- {
- float dist = m_creature->GetDistance(m_creature->getVictim());
- if (dist > (*i).Event.event_param1 && dist < (*i).Event.event_param2)
- ProcessEvent(*i);
- }
- break;
- }
- }
- }
-
- //Check for time based events
- for (std::list<EventHolder>::iterator i = EventList.begin(); i != EventList.end(); ++i)
- {
- //Decrement Timers
- if ((*i).Time)
- {
- if ((*i).Time > EventDiff)
- {
- //Do not decrement timers if event cannot trigger in this phase
- if (!((*i).Event.event_inverse_phase_mask & (1 << Phase)))
- (*i).Time -= EventDiff;
-
- //Skip processing of events that have time remaining
- continue;
- }
- else (*i).Time = 0;
- }
-
- //Events that are updated every EVENT_UPDATE_TIME
- switch ((*i).Event.event_type)
- {
- case EVENT_T_TIMER_OOC:
- ProcessEvent(*i);
- break;
- case EVENT_T_TIMER:
- case EVENT_T_MANA:
- case EVENT_T_HP:
- case EVENT_T_TARGET_HP:
- case EVENT_T_TARGET_CASTING:
- case EVENT_T_FRIENDLY_HP:
- if (Combat)
- ProcessEvent(*i);
- break;
- case EVENT_T_RANGE:
- if (Combat)
- {
- if (m_creature->IsWithinDistInMap(m_creature->getVictim(),(float)(*i).Event.event_param2))
- {
- if (m_creature->GetDistance(m_creature->getVictim()) >= (float)(*i).Event.event_param1)
- ProcessEvent(*i);
- }
- }
- break;
- }
- }
-
- EventDiff = 0;
- EventUpdateTime = EVENT_UPDATE_TIME;
- }
- else
- {
- EventDiff += diff;
- EventUpdateTime -= diff;
- }
-
- //Melee Auto-Attack
- if (Combat && MeleeEnabled)
- DoMeleeAttackIfReady();
-
- }
-};
-
-CreatureAI* GetAI_Mob_EventAI(Creature *pCreature)
-{
- //Select events by creature id
- std::list<EventHolder> EventList;
-
- //Find creature id in the Event map
- UNORDERED_MAP<uint32, std::vector<EventAI_Event> >::iterator CreatureEvents = EventAI_Event_Map.find(pCreature->GetEntry());
-
- if (CreatureEvents != EventAI_Event_Map.end())
- {
- std::vector<EventAI_Event>::iterator i;
-
- for (i = (*CreatureEvents).second.begin(); i != (*CreatureEvents).second.end(); ++i)
- {
- //Debug check
-#ifndef _DEBUG
- if ((*i).event_flags & EFLAG_DEBUG_ONLY)
- continue;
-#endif
- if( pCreature->GetMap()->IsDungeon() )
- {
- if ((pCreature->GetMap()->IsHeroic() && (*i).event_flags & EFLAG_HEROIC) || (!pCreature->GetMap()->IsHeroic() && (*i).event_flags & EFLAG_NORMAL))
- EventList.push_back(EventHolder(*i));
- continue;
- }
-
- EventList.push_back(EventHolder(*i));
- }
-
- //EventMap had events but they were not added because they must be for instance
- if (EventList.empty())
- {
- if (EAI_ErrorLevel > 1)
- error_db_log("SD2: CreatureId has events but no events added to list because of instance flags.", pCreature->GetEntry());
- }
- }
- else
- {
- if (EAI_ErrorLevel > 1)
- error_db_log("SD2: EventMap for Creature %u is empty but creature is using Mob_EventAI.", pCreature->GetEntry());
- }
-
- return new Mob_EventAI (pCreature, EventList);
-}
-
-void AddSC_mob_event()
-{
- Script *newscript;
- newscript = new Script;
- newscript->Name = "mob_eventai";
- newscript->GetAI = &GetAI_Mob_EventAI;
- newscript->RegisterSelf();
-}
-
diff --git a/src/bindings/scripts/scripts/creature/mob_generic_creature.cpp b/src/bindings/scripts/scripts/creature/mob_generic_creature.cpp
index d3395327aa7..a912e6af17f 100644
--- a/src/bindings/scripts/scripts/creature/mob_generic_creature.cpp
+++ b/src/bindings/scripts/scripts/creature/mob_generic_creature.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/creature/simple_ai.cpp b/src/bindings/scripts/scripts/creature/simple_ai.cpp
index 96583c4ee39..5dd299e0a14 100644
--- a/src/bindings/scripts/scripts/creature/simple_ai.cpp
+++ b/src/bindings/scripts/scripts/creature/simple_ai.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -27,34 +27,25 @@ EndScriptData */
SimpleAI::SimpleAI(Creature *c) : ScriptedAI(c)
{
//Clear all data
- Aggro_Text[0] = NULL;
- Aggro_Text[1] = NULL;
- Aggro_Text[2] = NULL;
- Aggro_Say[0] = false;
- Aggro_Say[1] = false;
- Aggro_Say[2] = false;
+ Aggro_TextId[0] = 0;
+ Aggro_TextId[1] = 0;
+ Aggro_TextId[2] = 0;
Aggro_Sound[0] = 0;
Aggro_Sound[1] = 0;
Aggro_Sound[2] = 0;
- Death_Text[0] = NULL;
- Death_Text[1] = NULL;
- Death_Text[2] = NULL;
- Death_Say[0] = false;
- Death_Say[1] = false;
- Death_Say[2] = false;
+ Death_TextId[0] = 0;
+ Death_TextId[1] = 0;
+ Death_TextId[2] = 0;
Death_Sound[0] = 0;
Death_Sound[1] = 0;
Death_Sound[2] = 0;
Death_Spell = 0;
Death_Target_Type = 0;
- Kill_Text[0] = NULL;
- Kill_Text[1] = NULL;
- Kill_Text[2] = NULL;
- Kill_Say[0] = false;
- Kill_Say[1] = false;
- Kill_Say[2] = false;
+ Kill_TextId[0] = 0;
+ Kill_TextId[1] = 0;
+ Kill_TextId[2] = 0;
Kill_Sound[0] = 0;
Kill_Sound[1] = 0;
Kill_Sound[2] = 0;
@@ -106,11 +97,9 @@ void SimpleAI::Aggro(Unit *who)
uint32 random_text = rand()%3;
- //Random yell
- if (Aggro_Text[random_text])
- if (Aggro_Say[random_text])
- DoSay(Aggro_Text[random_text], LANG_UNIVERSAL, who);
- else DoYell(Aggro_Text[random_text], LANG_UNIVERSAL, who);
+ //Random text
+ if (Aggro_TextId[random_text])
+ DoScriptText(Aggro_TextId[random_text], m_creature, who);
//Random sound
if (Aggro_Sound[random_text])
@@ -122,10 +111,8 @@ void SimpleAI::KilledUnit(Unit *victim)
uint32 random_text = rand()%3;
//Random yell
- if (Kill_Text[random_text])
- if (Kill_Say[random_text])
- DoSay(Kill_Text[random_text], LANG_UNIVERSAL, victim);
- else DoYell(Kill_Text[random_text], LANG_UNIVERSAL, victim);
+ if (Kill_TextId[random_text])
+ DoScriptText(Kill_TextId[random_text], m_creature, victim);
//Random sound
if (Kill_Sound[random_text])
@@ -172,10 +159,8 @@ void SimpleAI::DamageTaken(Unit *killer, uint32 &damage)
uint32 random_text = rand()%3;
//Random yell
- if (Death_Text[random_text])
- if (Death_Say[random_text])
- DoSay(Death_Text[random_text], LANG_UNIVERSAL, killer);
- else DoYell(Death_Text[random_text], LANG_UNIVERSAL, killer);
+ if (Death_TextId[random_text])
+ DoScriptText(Death_TextId[random_text], m_creature, killer);
//Random sound
if (Death_Sound[random_text])
@@ -269,10 +254,8 @@ void SimpleAI::UpdateAI(const uint32 diff)
uint32 random_text = rand()%3;
//Random yell
- if (Spell[i].Text[random_text])
- if (Spell[i].Say[random_text])
- DoSay(Spell[i].Text[random_text], LANG_UNIVERSAL, target);
- else DoYell(Spell[i].Text[random_text], LANG_UNIVERSAL, target);
+ if (Spell[i].TextId[random_text])
+ DoScriptText(Spell[i].TextId[random_text], m_creature, target);
//Random sound
if (Spell[i].Text_Sound[random_text])
diff --git a/src/bindings/scripts/scripts/creature/simple_ai.h b/src/bindings/scripts/scripts/creature/simple_ai.h
index 8745d78ad41..44cadef1f33 100644
--- a/src/bindings/scripts/scripts/creature/simple_ai.h
+++ b/src/bindings/scripts/scripts/creature/simple_ai.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
@@ -35,18 +35,15 @@ struct TRINITY_DLL_DECL SimpleAI : public ScriptedAI
public:
- char* Aggro_Text[3];
- bool Aggro_Say[3];
+ int32 Aggro_TextId[3];
uint32 Aggro_Sound[3];
- char* Death_Text[3];
- bool Death_Say[3];
+ int32 Death_TextId[3];
uint32 Death_Sound[3];
uint32 Death_Spell;
uint32 Death_Target_Type;
- char* Kill_Text[3];
- bool Kill_Say[3];
+ int32 Kill_TextId[3];
uint32 Kill_Sound[3];
uint32 Kill_Spell;
uint32 Kill_Target_Type;
@@ -62,8 +59,7 @@ public:
bool Enabled; //Spell enabled or disabled (default: false)
//3 texts to many?
- char* Text[3];
- bool Say[3];
+ int32 TextId[3];
uint32 Text_Sound[3];
}Spell[10];
diff --git a/src/bindings/scripts/scripts/custom/npc_acherus_taxi.cpp b/src/bindings/scripts/scripts/custom/npc_acherus_taxi.cpp
new file mode 100644
index 00000000000..3e58efa345b
--- /dev/null
+++ b/src/bindings/scripts/scripts/custom/npc_acherus_taxi.cpp
@@ -0,0 +1,39 @@
+#include "precompiled.h"
+#include "WorldPacket.h"
+
+#define GOSSIP_FLIGHT "I need a ride"
+
+bool GossipHello_npc_acherus_taxi(Player *player, Creature *_Creature)
+{
+player->SetTaxiCheater(true);
+
+player->ADD_GOSSIP_ITEM(0, GOSSIP_FLIGHT, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
+ player->SEND_GOSSIP_MENU(9978,_Creature->GetGUID());
+ return true;
+}
+
+bool GossipSelect_npc_acherus_taxi(Player *player, Creature *_Creature, uint32 sender, uint32 action )
+{
+ if (action == GOSSIP_ACTION_INFO_DEF + 1)
+ {
+ if (player->GetPositionZ() >=316)
+ {
+ player->GetSession()->SendDoFlight(24446, 1053);
+ }else{
+ player->GetSession()->SendDoFlight(24446, 1054);
+ }
+
+ }
+ return true;
+}
+
+void AddSC_npc_acherus_taxi()
+{
+ Script *newscript;
+
+newscript = new Script;
+newscript->Name="npc_acherus_taxi";
+newscript->pGossipHello = &GossipHello_npc_acherus_taxi;
+newscript->pGossipSelect = &GossipSelect_npc_acherus_taxi;
+newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/custom/npc_wyrmresttempel_taxi.cpp b/src/bindings/scripts/scripts/custom/npc_wyrmresttempel_taxi.cpp
new file mode 100644
index 00000000000..2e9ab3f412d
--- /dev/null
+++ b/src/bindings/scripts/scripts/custom/npc_wyrmresttempel_taxi.cpp
@@ -0,0 +1,116 @@
+#include "precompiled.h"
+#include "WorldPacket.h"
+
+#define GOSSIP_UP "My Lord, I must go to the upper floor of the temple."
+#define GOSSIP_DOWN "I would like to take a flight to the ground, Lord Afrasastrasz."
+#define GOSSIP_MIDDLE "Can you spare a drake to travel to Lord Afrasastrasz, in the middle of the temple?"
+#define GOSSIP_TOP "Please, Let me take one of these dragons to the top floor of the temple."
+#define GOSSIP_BOTTOM "Yes, Please. I would like to return to the ground floor of the temple."
+#define GOSSIP_ONEDOWN "I would like to see Lord Afrasastrasz, in the middle of the temple."
+
+bool GossipHello_npc_wyrmresttempel_middle_taxi(Player *player, Creature *_Creature)
+{
+player->SetTaxiCheater(true);
+
+player->ADD_GOSSIP_ITEM(0, GOSSIP_UP, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
+player->ADD_GOSSIP_ITEM(0, GOSSIP_DOWN, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
+ player->SEND_GOSSIP_MENU(12887,_Creature->GetGUID());
+
+ return true;
+}
+
+bool GossipSelect_npc_wyrmresttempel_middle_taxi(Player *player, Creature *_Creature, uint32 sender, uint32 action )
+{
+ if (action == GOSSIP_ACTION_INFO_DEF + 1)
+ {
+ player->GetSession()->SendDoFlight(6376, 881);
+ }
+
+
+ if (action == GOSSIP_ACTION_INFO_DEF + 2)
+ {
+ player->GetSession()->SendDoFlight(6376, 882);
+
+ }
+return true;
+}
+
+bool GossipHello_npc_wyrmresttempel_bottom_taxi(Player *player, Creature *_Creature)
+{
+player->SetTaxiCheater(true);
+
+player->ADD_GOSSIP_ITEM(0, GOSSIP_TOP, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 4);
+player->ADD_GOSSIP_ITEM(0, GOSSIP_MIDDLE, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3);
+ player->SEND_GOSSIP_MENU(12713,_Creature->GetGUID());
+
+ return true;
+}
+
+
+
+bool GossipSelect_npc_wyrmresttempel_bottom_taxi(Player *player, Creature *_Creature, uint32 sender, uint32 action )
+{
+ if (action == GOSSIP_ACTION_INFO_DEF + 4)
+ {
+ player->GetSession()->SendDoFlight(6376, 878);
+ }
+
+
+ if (action == GOSSIP_ACTION_INFO_DEF + 3)
+ {
+ player->GetSession()->SendDoFlight(6376, 883);
+
+ }
+return true;
+}
+
+bool GossipHello_npc_wyrmresttempel_top_taxi(Player *player, Creature *_Creature)
+{
+player->SetTaxiCheater(true);
+
+player->ADD_GOSSIP_ITEM(0, GOSSIP_BOTTOM, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 5);
+player->ADD_GOSSIP_ITEM(0, GOSSIP_ONEDOWN, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 6);
+ player->SEND_GOSSIP_MENU(12714,_Creature->GetGUID());
+
+ return true;
+}
+
+bool GossipSelect_npc_wyrmresttempel_top_taxi(Player *player, Creature *_Creature, uint32 sender, uint32 action )
+{
+ if (action == GOSSIP_ACTION_INFO_DEF + 5)
+ {
+ player->GetSession()->SendDoFlight(6376, 879);
+ }
+
+ if (action == GOSSIP_ACTION_INFO_DEF + 6)
+
+ {
+ player->GetSession()->SendDoFlight(6376, 880);
+
+ }
+return true;
+}
+
+void AddSC_npc_wyrmresttempel_taxi()
+{
+ Script *newscript;
+
+newscript = new Script;
+newscript->Name="npc_wyrmresttempelmiddle_taxi";
+newscript->pGossipHello = &GossipHello_npc_wyrmresttempel_middle_taxi;
+newscript->pGossipSelect = &GossipSelect_npc_wyrmresttempel_middle_taxi;
+newscript->RegisterSelf();
+
+newscript = new Script;
+newscript->Name="npc_wyrmresttempelbottom_taxi";
+newscript->pGossipHello = &GossipHello_npc_wyrmresttempel_bottom_taxi;
+newscript->pGossipSelect = &GossipSelect_npc_wyrmresttempel_bottom_taxi;
+newscript->RegisterSelf();
+
+newscript = new Script;
+newscript->Name="npc_wyrmresttempeltop_taxi";
+newscript->pGossipHello = &GossipHello_npc_wyrmresttempel_top_taxi;
+newscript->pGossipSelect = &GossipSelect_npc_wyrmresttempel_top_taxi;
+newscript->RegisterSelf();
+
+}
diff --git a/src/bindings/scripts/scripts/examples/example_creature.cpp b/src/bindings/scripts/scripts/examples/example_creature.cpp
new file mode 100644
index 00000000000..140e477441d
--- /dev/null
+++ b/src/bindings/scripts/scripts/examples/example_creature.cpp
@@ -0,0 +1,258 @@
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Example_Creature
+SD%Complete: 100
+SDComment: Short custom scripting example
+SDCategory: Script Examples
+EndScriptData */
+
+#include "precompiled.h"
+
+// **** This script is designed as an example for others to build on ****
+// **** Please modify whatever you'd like to as this script is only for developement ****
+
+// **** Script Info ****
+// This script is written in a way that it can be used for both friendly and hostile monsters
+// Its primary purpose is to show just how much you can really do with scripts
+// I recommend trying it out on both an agressive NPC and on friendly npc
+
+// **** Quick Info ****
+// Functions with Handled Function marked above them are functions that are called automatically by the core
+// Functions that are marked Custom Function are functions I've created to simplify code
+
+//List of text id's. The text is stored in database, also in a localized version
+//(if translation not exist for the textId, default english text will be used)
+//Not required to define in this way, but simplify if changes are needed.
+#define SAY_AGGRO -1999900
+#define SAY_RANDOM_0 -1999901
+#define SAY_RANDOM_1 -1999902
+#define SAY_RANDOM_2 -1999903
+#define SAY_RANDOM_3 -1999904
+#define SAY_RANDOM_4 -1999905
+#define SAY_BESERK -1999906
+#define SAY_PHASE -1999907
+#define SAY_DANCE -1999908
+#define SAY_SALUTE -1999909
+
+//List of gossip item texts. Items will appear in the gossip window.
+#define GOSSIP_ITEM "I'm looking for a fight"
+
+//List of spells. Not required to define them in this way, but will make it easier to maintain in case spellId change
+#define SPELL_BUFF 25661
+#define SPELL_ONE 12555
+#define SPELL_ONE_ALT 24099
+#define SPELL_TWO 10017
+#define SPELL_THREE 26027
+#define SPELL_ENRAGE 23537
+#define SPELL_BESERK 32309
+
+struct TRINITY_DLL_DECL example_creatureAI : public ScriptedAI
+{
+ //*** HANDLED FUNCTION ***
+ //This is the constructor, called only once when the creature is first created
+ example_creatureAI(Creature *c) : ScriptedAI(c) {Reset();}
+
+ //*** CUSTOM VARIABLES ****
+ //These variables are for use only by this individual script.
+ //Nothing else will ever call them but us.
+
+ uint32 Say_Timer; //Timer for random chat
+ uint32 Rebuff_Timer; //Timer for rebuffing
+ uint32 Spell_1_Timer; //Timer for spell 1 when in combat
+ uint32 Spell_2_Timer; //Timer for spell 1 when in combat
+ uint32 Spell_3_Timer; //Timer for spell 1 when in combat
+ uint32 Beserk_Timer; //Timer until we go into Beserk (enraged) mode
+ uint32 Phase; //The current battle phase we are in
+ uint32 Phase_Timer; //Timer until phase transition
+
+ //*** HANDLED FUNCTION ***
+ //This is called whenever the core decides we need to evade
+ void Reset()
+ {
+ Phase = 1; //Start in phase 1
+ Phase_Timer = 60000; //60 seconds
+ Spell_1_Timer = 5000; //5 seconds
+ Spell_2_Timer = 37000; //37 seconds
+ Spell_3_Timer = 19000; //19 seconds
+ Beserk_Timer = 120000; //2 minutes
+ }
+
+ //*** HANDLED FUNCTION ***
+ //Attack Start is called whenever someone hits us.
+ void Aggro(Unit *who)
+ {
+ //Say some stuff
+ DoScriptText(SAY_AGGRO, m_creature, who);
+ }
+
+ //*** HANDLED FUNCTION ***
+ //Update AI is called Every single map update (roughly once every 100ms if a player is within the grid)
+ void UpdateAI(const uint32 diff)
+ {
+ //Out of combat timers
+ if (!m_creature->getVictim())
+ {
+ //Random Say timer
+ if (Say_Timer < diff)
+ {
+ //Random switch between 5 outcomes
+ switch (rand()%5)
+ {
+ case 0: DoScriptText(SAY_RANDOM_0, m_creature); break;
+ case 1: DoScriptText(SAY_RANDOM_1, m_creature); break;
+ case 2: DoScriptText(SAY_RANDOM_2, m_creature); break;
+ case 3: DoScriptText(SAY_RANDOM_3, m_creature); break;
+ case 4: DoScriptText(SAY_RANDOM_4, m_creature); break;
+ }
+
+ Say_Timer = 45000; //Say something agian in 45 seconds
+ }else Say_Timer -= diff;
+
+ //Rebuff timer
+ if (Rebuff_Timer < diff)
+ {
+ DoCast(m_creature,SPELL_BUFF);
+ Rebuff_Timer = 900000; //Rebuff agian in 15 minutes
+ }else Rebuff_Timer -= diff;
+ }
+
+ //Return since we have no target
+ if (!UpdateVictim())
+ return;
+
+ //Spell 1 timer
+ if (Spell_1_Timer < diff)
+ {
+ //Cast spell one on our current target.
+ if (rand()%50 > 10)
+ DoCast(m_creature->getVictim(),SPELL_ONE_ALT);
+ else if (m_creature->GetDistance(m_creature->getVictim()) < 25)
+ DoCast(m_creature->getVictim(),SPELL_ONE);
+
+ Spell_1_Timer = 5000;
+ }else Spell_1_Timer -= diff;
+
+ //Spell 2 timer
+ if (Spell_2_Timer < diff)
+ {
+ //Cast spell one on our current target.
+ DoCast(m_creature->getVictim(),SPELL_TWO);
+
+ Spell_2_Timer = 37000;
+ }else Spell_2_Timer -= diff;
+
+ //Spell 3 timer
+ if (Phase > 1)
+ if (Spell_3_Timer < diff)
+ {
+ //Cast spell one on our current target.
+ DoCast(m_creature->getVictim(),SPELL_THREE);
+
+ Spell_3_Timer = 19000;
+ }else Spell_3_Timer -= diff;
+
+ //Beserk timer
+ if (Phase > 1)
+ if (Beserk_Timer < diff)
+ {
+ //Say our line then cast uber death spell
+ DoScriptText(SAY_BESERK, m_creature, m_creature->getVictim());
+ DoCast(m_creature->getVictim(),SPELL_BESERK);
+
+ //Cast our beserk spell agian in 12 seconds if we didn't kill everyone
+ Beserk_Timer = 12000;
+ }else Beserk_Timer -= diff;
+
+ //Phase timer
+ if (Phase == 1)
+ if (Phase_Timer < diff)
+ {
+ //Go to next phase
+ Phase++;
+ DoScriptText(SAY_PHASE, m_creature);
+ DoCast(m_creature,SPELL_ENRAGE);
+ }else Phase_Timer -= diff;
+
+ DoMeleeAttackIfReady();
+ }
+
+ //Our Recive emote function
+ void ReceiveEmote(Player *player, uint32 emote)
+ {
+ m_creature->HandleEmoteCommand(emote);
+
+ if (emote == TEXTEMOTE_DANCE)
+ DoScriptText(SAY_DANCE, m_creature);
+
+ if (emote == TEXTEMOTE_SALUTE)
+ DoScriptText(SAY_SALUTE, m_creature);
+ }
+};
+
+//This is the GetAI method used by all scripts that involve AI
+//It is called every time a new creature using this script is created
+CreatureAI* GetAI_example_creature(Creature *_Creature)
+{
+ return new example_creatureAI (_Creature);
+}
+
+//This function is called when the player clicks an option on the gossip menu
+void SendDefaultMenu_example_creature(Player *player, Creature *_Creature, uint32 action)
+{
+ if (action == GOSSIP_ACTION_INFO_DEF + 1) //Fight time
+ {
+ //Set our faction to hostile twoards all
+ _Creature->setFaction(24);
+ _Creature->Attack(player, true);
+ player->PlayerTalkClass->CloseGossip();
+ }
+}
+
+//This function is called when the player clicks an option on the gossip menu
+bool GossipSelect_example_creature(Player *player, Creature *_Creature, uint32 sender, uint32 action )
+{
+ if (sender == GOSSIP_SENDER_MAIN)
+ SendDefaultMenu_example_creature(player, _Creature, action);
+
+ return true;
+}
+
+//This function is called when the player opens the gossip menu
+bool GossipHello_example_creature(Player *player, Creature *_Creature)
+{
+ player->ADD_GOSSIP_ITEM( 0, GOSSIP_ITEM , GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
+ player->PlayerTalkClass->SendGossipMenu(907,_Creature->GetGUID());
+
+ return true;
+}
+
+//This is the actual function called only once durring InitScripts()
+//It must define all handled functions that are to be run in this script
+//For example if you want this Script to handle Emotes you must include
+//newscript->ReciveEmote = My_Emote_Function;
+void AddSC_example_creature()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name = "example_creature";
+ newscript->GetAI = &GetAI_example_creature;
+ newscript->pGossipHello = &GossipHello_example_creature;
+ newscript->pGossipSelect = &GossipSelect_example_creature;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/examples/example_escort.cpp b/src/bindings/scripts/scripts/examples/example_escort.cpp
new file mode 100644
index 00000000000..1cc5356a9ac
--- /dev/null
+++ b/src/bindings/scripts/scripts/examples/example_escort.cpp
@@ -0,0 +1,220 @@
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Example_Escort
+SD%Complete: 100
+SDComment: Script used for testing escortAI
+SDCategory: Script Examples
+EndScriptData */
+
+#include "precompiled.h"
+#include "../npc/npc_escortAI.h"
+
+#define SAY_AGGRO1 -1999910
+#define SAY_AGGRO2 -1999911
+#define SAY_WP_1 -1999912
+#define SAY_WP_2 -1999913
+#define SAY_WP_3 -1999914
+#define SAY_WP_4 -1999915
+#define SAY_DEATH_1 -1999916
+#define SAY_DEATH_2 -1999917
+#define SAY_DEATH_3 -1999918
+#define SAY_SPELL -1999919
+#define SAY_RAND_1 -1999920
+#define SAY_RAND_2 -1999921
+
+#define GOSSIP_ITEM_1 "Click to Test Escort(Attack, Defend, Run)"
+#define GOSSIP_ITEM_2 "Click to Test Escort(NoAttack, NoDefend, Walk)"
+#define GOSSIP_ITEM_3 "Click to Test Escort(NoAttack, Defend, Walk)"
+
+struct TRINITY_DLL_DECL example_escortAI : public npc_escortAI
+{
+ public:
+
+ // CreatureAI functions
+ example_escortAI(Creature *c) : npc_escortAI(c) {Reset();}
+
+ uint32 DeathCoilTimer;
+ uint32 ChatTimer;
+
+ // Pure Virtual Functions
+ void WaypointReached(uint32 i)
+ {
+ switch (i)
+ {
+ case 1:
+ DoScriptText(SAY_WP_1, m_creature);
+ break;
+
+ case 3:
+ {
+ DoScriptText(SAY_WP_2, m_creature);
+ Creature* temp = m_creature->SummonCreature(21878, m_creature->GetPositionX()+5, m_creature->GetPositionY()+7, m_creature->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 3000);
+ if(temp)
+ temp->AI()->AttackStart(m_creature);
+ }
+ break;
+
+ case 4:
+ {
+ Unit* temp = Unit::GetUnit(*m_creature, PlayerGUID);
+ if (temp)
+ {
+ //temp is the target of the text
+ DoScriptText(SAY_WP_3, m_creature, temp);
+ //temp is the source of the text
+ DoScriptText(SAY_WP_4, temp);
+ }
+ }
+ break;
+ }
+ }
+
+ void Aggro(Unit* who)
+ {
+ if (IsBeingEscorted)
+ {
+ if (Unit* temp = Unit::GetUnit(*m_creature, PlayerGUID))
+ DoScriptText(SAY_AGGRO1, m_creature, temp);
+ }
+ else DoScriptText(SAY_AGGRO2, m_creature);
+ }
+
+ void Reset()
+ {
+ DeathCoilTimer = 4000;
+ ChatTimer = 4000;
+ }
+
+ void JustDied(Unit* killer)
+ {
+ if (IsBeingEscorted)
+ {
+ Unit *pTemp = Unit::GetUnit(*m_creature,PlayerGUID);
+ //killer = m_creature when player got to far from creature
+ if (killer == m_creature)
+ {
+ //This is actually a whisper. You control the text type in database
+ if (pTemp)
+ DoScriptText(SAY_DEATH_1, m_creature, pTemp);
+ }
+ else if (pTemp) DoScriptText(SAY_DEATH_2, m_creature, pTemp);
+ }
+ else DoScriptText(SAY_DEATH_3, m_creature);
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ //Must update npc_escortAI
+ npc_escortAI::UpdateAI(diff);
+
+ //Combat check
+ if (InCombat && m_creature->getVictim())
+ {
+ if (DeathCoilTimer < diff)
+ {
+ DoScriptText(SAY_SPELL, m_creature);
+ m_creature->CastSpell(m_creature->getVictim(), 33130, false);
+
+ DeathCoilTimer = 4000;
+ }else DeathCoilTimer -= diff;
+ }else
+ {
+ //Out of combat but being escorted
+ if (IsBeingEscorted)
+ if (ChatTimer < diff)
+ {
+ if (m_creature->HasAura(3593))
+ {
+ DoScriptText(SAY_RAND_1, m_creature);
+ m_creature->CastSpell(m_creature, 11540, false);
+ }else
+ {
+ DoScriptText(SAY_RAND_2, m_creature);
+ m_creature->CastSpell(m_creature, 3593, false);
+ }
+
+ ChatTimer = 12000;
+ }else ChatTimer -= diff;
+ }
+ }
+};
+
+CreatureAI* GetAI_example_escort(Creature *_Creature)
+{
+ example_escortAI* testAI = new example_escortAI(_Creature);
+
+ testAI->AddWaypoint(0, 1231, -4419, 23);
+ testAI->AddWaypoint(1, 1198, -4440, 23, 0);
+ testAI->AddWaypoint(2, 1208, -4392, 23);
+ testAI->AddWaypoint(3, 1231, -4419, 23, 5000);
+ testAI->AddWaypoint(4, 1208, -4392, 23, 5000);
+
+ return (CreatureAI*)testAI;
+}
+
+bool GossipHello_example_escort(Player *player, Creature *_Creature)
+{
+ player->TalkedToCreature(_Creature->GetEntry(),_Creature->GetGUID());
+ _Creature->prepareGossipMenu(player,0);
+
+ player->ADD_GOSSIP_ITEM(0, GOSSIP_ITEM_1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
+ player->ADD_GOSSIP_ITEM(0, GOSSIP_ITEM_2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2);
+ player->ADD_GOSSIP_ITEM(0, GOSSIP_ITEM_3, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+3);
+
+ _Creature->sendPreparedGossip( player );
+ return true;
+}
+
+bool GossipSelect_example_escort(Player *player, Creature *_Creature, uint32 sender, uint32 action )
+{
+ if (action == GOSSIP_ACTION_INFO_DEF+1)
+ {
+ player->CLOSE_GOSSIP_MENU();
+ ((npc_escortAI*)(_Creature->AI()))->Start(true, true, true, player->GetGUID());
+
+ return true; // prevent mangos core handling
+ }
+
+ if (action == GOSSIP_ACTION_INFO_DEF+2)
+ {
+ player->CLOSE_GOSSIP_MENU();
+ ((npc_escortAI*)(_Creature->AI()))->Start(false, false, false, player->GetGUID());
+
+ return true; // prevent mangos core handling
+ }
+
+ if (action == GOSSIP_ACTION_INFO_DEF+3)
+ {
+ player->CLOSE_GOSSIP_MENU();
+ ((npc_escortAI*)(_Creature->AI()))->Start(false, true, false, player->GetGUID());
+
+ return true; // prevent mangos core handling
+ }
+ return false;
+}
+
+void AddSC_example_escort()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "example_escort";
+ newscript->GetAI = &GetAI_example_escort;
+ newscript->pGossipHello = &GossipHello_example_escort;
+ newscript->pGossipSelect = &GossipSelect_example_escort;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/examples/example_gossip_codebox.cpp b/src/bindings/scripts/scripts/examples/example_gossip_codebox.cpp
new file mode 100644
index 00000000000..5d05197fd7a
--- /dev/null
+++ b/src/bindings/scripts/scripts/examples/example_gossip_codebox.cpp
@@ -0,0 +1,88 @@
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Example_Gossip_Codebox
+SD%Complete: 100
+SDComment: Show a codebox in gossip option
+SDCategory: Script Examples
+EndScriptData */
+
+#include "precompiled.h"
+#include <cstring>
+
+#define SAY_NOT_INTERESTED -1999922
+#define SAY_WRONG -1999923
+#define SAY_CORRECT -1999924
+
+#define GOSSIP_ITEM_1 "A quiz: what's your name?"
+#define GOSSIP_ITEM_2 "I'm not interested"
+
+//This function is called when the player opens the gossip menubool
+bool GossipHello_example_gossip_codebox(Player *player, Creature *_Creature)
+{
+ player->ADD_GOSSIP_ITEM_EXTENDED(0, GOSSIP_ITEM_1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1, "", 0, true);
+ player->ADD_GOSSIP_ITEM(0, GOSSIP_ITEM_2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2);
+
+ player->PlayerTalkClass->SendGossipMenu(907,_Creature->GetGUID());
+ return true;
+}
+
+//This function is called when the player clicks an option on the gossip menubool
+bool GossipSelect_example_gossip_codebox(Player *player, Creature *_Creature, uint32 sender, uint32 action )
+{
+ if(action == GOSSIP_ACTION_INFO_DEF+2)
+ {
+ DoScriptText(SAY_NOT_INTERESTED, _Creature);
+ player->CLOSE_GOSSIP_MENU();
+ }
+ return true;
+}
+
+bool GossipSelectWithCode_example_gossip_codebox( Player *player, Creature *_Creature, uint32 sender, uint32 action, const char* sCode )
+{
+ if(sender == GOSSIP_SENDER_MAIN)
+ {
+ if(action == GOSSIP_ACTION_INFO_DEF+1)
+ {
+ if(std::strcmp(sCode, player->GetName())!=0)
+ {
+ DoScriptText(SAY_WRONG, _Creature);
+ _Creature->CastSpell(player, 12826, true);
+ }
+ else
+ {
+ DoScriptText(SAY_CORRECT, _Creature);
+ _Creature->CastSpell(player, 26990, true);
+ }
+ player->CLOSE_GOSSIP_MENU();
+ return true;
+ }
+ }
+ return false;
+}
+
+void AddSC_example_gossip_codebox()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name = "example_gossip_codebox";
+ newscript->pGossipHello = &GossipHello_example_gossip_codebox;
+ newscript->pGossipSelect = &GossipSelect_example_gossip_codebox;
+ newscript->pGossipSelectWithCode = &GossipSelectWithCode_example_gossip_codebox;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/examples/example_misc.cpp b/src/bindings/scripts/scripts/examples/example_misc.cpp
new file mode 100644
index 00000000000..63136c6bc5d
--- /dev/null
+++ b/src/bindings/scripts/scripts/examples/example_misc.cpp
@@ -0,0 +1,65 @@
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Example_Misc
+SD%Complete: 100
+SDComment: Item, Areatrigger and other small code examples
+SDCategory: Script Examples
+EndScriptData */
+
+#include "precompiled.h"
+
+#define SAY_HI -1999925
+
+bool AT_example_areatrigger(Player *player, AreaTriggerEntry *at)
+{
+ DoScriptText(SAY_HI, player);
+ return true;
+}
+
+extern void LoadDatabase();
+bool ItemUse_example_item(Player *player, Item* _Item, SpellCastTargets const& targets)
+{
+ LoadDatabase();
+ return true;
+}
+
+bool GOHello_example_go_teleporter(Player *player, GameObject* _GO)
+{
+ player->TeleportTo(0, 1807.07f,336.105f,70.3975f,0.0f);
+ return false;
+}
+
+void AddSC_example_misc()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name = "example_areatrigger";
+ newscript->pAreaTrigger = &AT_example_areatrigger;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name = "example_item";
+ newscript->pItemUse = &ItemUse_example_item;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name = "example_go_teleporter";
+ newscript->pGOHello = &GOHello_example_go_teleporter;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/go/go_scripts.cpp b/src/bindings/scripts/scripts/go/go_scripts.cpp
index 9aacd2487e9..5613ccdd9b7 100644
--- a/src/bindings/scripts/scripts/go/go_scripts.cpp
+++ b/src/bindings/scripts/scripts/go/go_scripts.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -22,6 +22,7 @@ SDCategory: Game Objects
EndScriptData */
/* ContentData
+go_cat_figurine (the "trap" version of GO, two different exist)
go_northern_crystal_pylon
go_eastern_crystal_pylon
go_western_crystal_pylon
@@ -30,12 +31,26 @@ go_field_repair_bot_74A
go_orb_of_command
go_tablet_of_madness
go_tablet_of_the_seven
-go_teleporter
EndContentData */
#include "precompiled.h"
/*######
+## go_cat_figurine
+######*/
+
+enum
+{
+ SPELL_SUMMON_GHOST_SABER = 5968,
+};
+
+bool GOHello_go_cat_figurine(Player *player, GameObject* _GO)
+{
+ player->CastSpell(player,SPELL_SUMMON_GHOST_SABER,true);
+ return false;
+}
+
+/*######
## go_crystal_pylons (3x)
######*/
@@ -108,6 +123,26 @@ bool GOHello_go_field_repair_bot_74A(Player *player, GameObject* _GO)
}
/*######
+## go_gilded_brazier
+######*/
+
+enum
+{
+ NPC_STILLBLADE = 17716,
+};
+
+bool GOHello_go_gilded_brazier(Player* pPlayer, GameObject* pGO)
+{
+ if (pGO->GetGoType() == GAMEOBJECT_TYPE_GOOBER)
+ {
+ if (Creature* pCreature = pPlayer->SummonCreature(NPC_STILLBLADE, 8087.632, -7542.740, 151.568, 0.122, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5000))
+ pCreature->AI()->AttackStart(pPlayer);
+ }
+
+ return true;
+}
+
+/*######
## go_orb_of_command
######*/
@@ -148,16 +183,6 @@ bool GOHello_go_tablet_of_the_seven(Player *player, GameObject* _GO)
return true;
}
-/*######
-## go_teleporter
-######*/
-
-bool GOHello_go_teleporter(Player *player, GameObject* _GO)
-{
- player->TeleportTo(0, 1807.07f,336.105f,70.3975f,0.0f);
- return false;
-}
-
/*#####
## go_jump_a_tron
######*/
@@ -173,7 +198,7 @@ bool GOHello_go_jump_a_tron(Player *player, GameObject* _GO)
/*######
## go_ethereum_prison
######*/
-
+
float ethereum_NPC[2][7] =
{
{20785,20790,20789,20784,20786,20783,20788}, // hostile npc
@@ -184,7 +209,7 @@ bool GOHello_go_ethereum_prison(Player *player, GameObject* _GO)
{
_GO->SetGoState(0);
switch(rand()%2){
- case 0:
+ case 0:
_GO->SummonCreature(ethereum_NPC[0][rand()%6],_GO->GetPositionX(),_GO->GetPositionY(),_GO->GetPositionZ()+0.3, 0,TEMPSUMMON_CORPSE_TIMED_DESPAWN,10000);
break;
case 1:
@@ -213,6 +238,11 @@ void AddSC_go_scripts()
Script *newscript;
newscript = new Script;
+ newscript->Name = "go_cat_figurine";
+ newscript->pGOHello = &GOHello_go_cat_figurine;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
newscript->Name="go_northern_crystal_pylon";
newscript->pGOHello = &GOHello_go_northern_crystal_pylon;
newscript->RegisterSelf();
@@ -238,6 +268,11 @@ void AddSC_go_scripts()
newscript->RegisterSelf();
newscript = new Script;
+ newscript->Name = "go_gilded_brazier";
+ newscript->pGOHello = &GOHello_go_gilded_brazier;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
newscript->Name="go_orb_of_command";
newscript->pGOHello = &GOHello_go_orb_of_command;
newscript->RegisterSelf();
@@ -253,11 +288,6 @@ void AddSC_go_scripts()
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="go_teleporter";
- newscript->pGOHello = &GOHello_go_teleporter;
- newscript->RegisterSelf();
-
- newscript = new Script;
newscript->Name="go_jump_a_tron";
newscript->pGOHello = &GOHello_go_jump_a_tron;
newscript->RegisterSelf();
diff --git a/src/bindings/scripts/scripts/guard/guard_ai.cpp b/src/bindings/scripts/scripts/guard/guard_ai.cpp
index f28820eb7ee..b635ae74b2d 100644
--- a/src/bindings/scripts/scripts/guard/guard_ai.cpp
+++ b/src/bindings/scripts/scripts/guard/guard_ai.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -28,6 +28,10 @@ EndScriptData */
#define GENERIC_CREATURE_COOLDOWN 5000
+#define SAY_GUARD_SIL_AGGRO1 -1070001
+#define SAY_GUARD_SIL_AGGRO2 -1070002
+#define SAY_GUARD_SIL_AGGRO3 -1070003
+
void guardAI::Reset()
{
GlobalCooldown = 0;
@@ -40,15 +44,9 @@ void guardAI::Aggro(Unit *who)
{
switch(rand()%3)
{
- case 0:
- DoSay("Taste blade, mongrel!", LANG_UNIVERSAL,NULL);
- break;
- case 1:
- DoSay("Please tell me that you didn't just do what I think you just did. Please tell me that I'm not going to have to hurt you...", LANG_UNIVERSAL,NULL);
- break;
- case 2:
- DoSay("As if we don't have enough problems, you go and create more!", LANG_UNIVERSAL,NULL);
- break;
+ case 0: DoScriptText(SAY_GUARD_SIL_AGGRO1, m_creature, who); break;
+ case 1: DoScriptText(SAY_GUARD_SIL_AGGRO1, m_creature, who); break;
+ case 2: DoScriptText(SAY_GUARD_SIL_AGGRO1, m_creature, who); break;
}
}
diff --git a/src/bindings/scripts/scripts/guard/guard_ai.h b/src/bindings/scripts/scripts/guard/guard_ai.h
index 7952040b5e2..d7cd6cd6318 100644
--- a/src/bindings/scripts/scripts/guard/guard_ai.h
+++ b/src/bindings/scripts/scripts/guard/guard_ai.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/guard/guards.cpp b/src/bindings/scripts/scripts/guard/guards.cpp
index ff6ec258b22..2a7f171a4a4 100644
--- a/src/bindings/scripts/scripts/guard/guards.cpp
+++ b/src/bindings/scripts/scripts/guard/guards.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -115,23 +115,23 @@ void SendDefaultMenu_guard_azuremyst(Player *player, Creature *_Creature, uint32
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Bank
- player->SEND_POI(-3918.95, -11544.7, 6, 6, 0, "Bank");
+ player->SEND_POI(-3918.95, -11544.7, 7, 6, 0, "Bank");
player->SEND_GOSSIP_MENU(10067,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Hippogryph Master
- player->SEND_POI(-4057.15, -11788.6, 6, 6, 0, "Stephanos");
+ player->SEND_POI(-4057.15, -11788.6, 7, 6, 0, "Stephanos");
player->SEND_GOSSIP_MENU(10071,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Guild master
- player->SEND_POI(-4092.43, -11626.6, 6, 6, 0, "Funaam");
+ player->SEND_POI(-4092.43, -11626.6, 7, 6, 0, "Funaam");
player->SEND_GOSSIP_MENU(10073,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Inn
- player->SEND_POI(-4129.43, -12469, 6, 6, 0, "Caregiver Chellan");
+ player->SEND_POI(-4129.43, -12469, 7, 6, 0, "Caregiver Chellan");
player->SEND_GOSSIP_MENU(10074,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Stable Master
- player->SEND_POI(-4146.42, -12492.7, 6, 6, 0, "Esbina");
+ player->SEND_POI(-4146.42, -12492.7, 7, 6, 0, "Esbina");
player->SEND_GOSSIP_MENU(10075,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Class trainer
@@ -168,31 +168,31 @@ void SendClassTrainerMenu_guard_azuremyst(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Druid
- player->SEND_POI(-4274.81, -11495.3, 6, 6, 0, "Shalannius");
+ player->SEND_POI(-4274.81, -11495.3, 7, 6, 0, "Shalannius");
player->SEND_GOSSIP_MENU(10077,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Hunter
- player->SEND_POI(-4203.65, -12526.5, 6, 6, 0, "Acteon");
+ player->SEND_POI(-4203.65, -12526.5, 7, 6, 0, "Acteon");
player->SEND_GOSSIP_MENU(10078,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Mage
- player->SEND_POI(-4149.62, -12530.1, 6, 6, 0, "Semid");
+ player->SEND_POI(-4149.62, -12530.1, 7, 6, 0, "Semid");
player->SEND_GOSSIP_MENU(10081,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Paladin
- player->SEND_POI(-4138.98, -12468.5, 6, 6, 0, "Tullas");
+ player->SEND_POI(-4138.98, -12468.5, 7, 6, 0, "Tullas");
player->SEND_GOSSIP_MENU(10083,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Priest
- player->SEND_POI(-4131.66, -12478.6, 6, 6, 0, "Guvan");
+ player->SEND_POI(-4131.66, -12478.6, 7, 6, 0, "Guvan");
player->SEND_GOSSIP_MENU(10084,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Shaman
- player->SEND_POI(-4162.33, -12456.1, 6, 6, 0, "Tuluun");
+ player->SEND_POI(-4162.33, -12456.1, 7, 6, 0, "Tuluun");
player->SEND_GOSSIP_MENU(10085,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Warrior
- player->SEND_POI(-4165.05, -12536.4, 6, 6, 0, "Ruada");
+ player->SEND_POI(-4165.05, -12536.4, 7, 6, 0, "Ruada");
player->SEND_GOSSIP_MENU(10086,_Creature->GetGUID());
break;
}
@@ -203,54 +203,54 @@ void SendProfTrainerMenu_guard_azuremyst(Player *player, Creature *_Creature, ui
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(-4191.15, -12470, 6, 6, 0, "Daedal");
+ player->SEND_POI(-4191.15, -12470, 7, 6, 0, "Daedal");
player->SEND_GOSSIP_MENU(10088,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(-4726.29, -12387, 6, 6, 0, "Blacksmith Calypso");
+ player->SEND_POI(-4726.29, -12387, 7, 6, 0, "Blacksmith Calypso");
player->SEND_GOSSIP_MENU(10089,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(-4710.87, -12400.6, 6, 6, 0, "'Cookie' McWeaksauce");
+ player->SEND_POI(-4710.87, -12400.6, 7, 6, 0, "'Cookie' McWeaksauce");
player->SEND_GOSSIP_MENU(10090,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(-3882.85, -11496.7, 6, 6, 0, "Nahogg");
+ player->SEND_POI(-3882.85, -11496.7, 7, 6, 0, "Nahogg");
player->SEND_GOSSIP_MENU(10091,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Engineering
- player->SEND_POI(-4157.57, -12470.2, 6, 6, 0, "Artificer Daelo");
+ player->SEND_POI(-4157.57, -12470.2, 7, 6, 0, "Artificer Daelo");
player->SEND_GOSSIP_MENU(10092,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //First Aid
- player->SEND_POI(-4199.11, -12469.9, 6, 6, 0, "Anchorite Fateema");
+ player->SEND_POI(-4199.11, -12469.9, 7, 6, 0, "Anchorite Fateema");
player->SEND_GOSSIP_MENU(10093,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Fishing
- player->SEND_POI(-4266.38, -12985.1, 6, 6, 0, "Diktynna");
+ player->SEND_POI(-4266.38, -12985.1, 7, 6, 0, "Diktynna");
player->SEND_GOSSIP_MENU(10094,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Herbalism
player->SEND_GOSSIP_MENU(10095,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Jewelcrafting
- player->SEND_POI(-3781.55, -11541.8, 6, 6, 0, "Farii");
+ player->SEND_POI(-3781.55, -11541.8, 7, 6, 0, "Farii");
player->SEND_GOSSIP_MENU(10096,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Leatherworking
- player->SEND_POI(-3442.68, -12322.2, 6, 6, 0, "Moordo");
+ player->SEND_POI(-3442.68, -12322.2, 7, 6, 0, "Moordo");
player->SEND_GOSSIP_MENU(10098,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Mining
- player->SEND_POI(-4179.89, -12493.1, 6, 6, 0, "Dulvi");
+ player->SEND_POI(-4179.89, -12493.1, 7, 6, 0, "Dulvi");
player->SEND_GOSSIP_MENU(10097,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 12: //Skinning
- player->SEND_POI(-3431.17, -12316.5, 6, 6, 0, "Gurf");
+ player->SEND_POI(-3431.17, -12316.5, 7, 6, 0, "Gurf");
player->SEND_GOSSIP_MENU(10098,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 13: //Tailoring
- player->SEND_POI(-4711.54, -12386.7, 6, 6, 0, "Erin Kelly");
+ player->SEND_POI(-4711.54, -12386.7, 7, 6, 0, "Erin Kelly");
player->SEND_GOSSIP_MENU(10099,_Creature->GetGUID());
break;
}
@@ -302,35 +302,35 @@ void SendDefaultMenu_guard_bluffwatcher(Player *player, Creature *_Creature, uin
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Bank
- player->SEND_POI(-1257.8, 24.14, 6, 6, 0, "Thunder Bluff Bank");
+ player->SEND_POI(-1257.8, 24.14, 7, 6, 0, "Thunder Bluff Bank");
player->SEND_GOSSIP_MENU(1292,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Wind master
- player->SEND_POI(-1196.43, 28.26, 6, 6, 0, "Wind Rider Roost");
+ player->SEND_POI(-1196.43, 28.26, 7, 6, 0, "Wind Rider Roost");
player->SEND_GOSSIP_MENU(1293,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Guild master
- player->SEND_POI(-1296.5, 127.57, 6, 6, 0, "Thunder Bluff Civic Information");
+ player->SEND_POI(-1296.5, 127.57, 7, 6, 0, "Thunder Bluff Civic Information");
player->SEND_GOSSIP_MENU(1291,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Inn
- player->SEND_POI(-1296, 39.7, 6, 6, 0, "Thunder Bluff Inn");
+ player->SEND_POI(-1296, 39.7, 7, 6, 0, "Thunder Bluff Inn");
player->SEND_GOSSIP_MENU(3153,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Mailbox
- player->SEND_POI(-1263.59, 44.36, 6, 6, 0, "Thunder Bluff Mailbox");
+ player->SEND_POI(-1263.59, 44.36, 7, 6, 0, "Thunder Bluff Mailbox");
player->SEND_GOSSIP_MENU(3154,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Auction House
- player->SEND_POI(1381.77, -4371.16, 6, 6, 0, GOSSIP_TEXT_AUCTIONHOUSE);
+ player->SEND_POI(1381.77, -4371.16, 7, 6, 0, GOSSIP_TEXT_AUCTIONHOUSE);
player->SEND_GOSSIP_MENU(3155,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Weapon master
- player->SEND_POI(-1282.31, 89.56, 6, 6, 0, "Ansekhwa");
+ player->SEND_POI(-1282.31, 89.56, 7, 6, 0, "Ansekhwa");
player->SEND_GOSSIP_MENU(4520,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Stable master
- player->SEND_POI(-1270.19, 48.84, 6, 6, 0, "Bulrug");
+ player->SEND_POI(-1270.19, 48.84, 7, 6, 0, "Bulrug");
player->SEND_GOSSIP_MENU(5977,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //battlemaster
@@ -370,15 +370,15 @@ void SendBattleMasterMenu_guard_bluffwatcher(Player *player, Creature *_Creature
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //AV
- player->SEND_POI(-1387.82, -97.55, 6, 6, 0, "Taim Ragetotem");
+ player->SEND_POI(-1387.82, -97.55, 7, 6, 0, "Taim Ragetotem");
player->SEND_GOSSIP_MENU(7522,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //AB
- player->SEND_POI(-997, 214.12, 6, 6, 0, "Martin Lindsey");
+ player->SEND_POI(-997, 214.12, 7, 6, 0, "Martin Lindsey");
player->SEND_GOSSIP_MENU(7648,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //WSG
- player->SEND_POI(-1384.94, -75.91, 6, 6, 0, "Kergul Bloodaxe");
+ player->SEND_POI(-1384.94, -75.91, 7, 6, 0, "Kergul Bloodaxe");
player->SEND_GOSSIP_MENU(7523,_Creature->GetGUID());
break;
}
@@ -389,27 +389,27 @@ void SendClassTrainerMenu_guard_bluffwatcher(Player *player, Creature *_Creature
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Druid
- player->SEND_POI(-1054.47, -285, 6, 6, 0, "Hall of Elders");
+ player->SEND_POI(-1054.47, -285, 7, 6, 0, "Hall of Elders");
player->SEND_GOSSIP_MENU(1294,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Hunter
- player->SEND_POI(-1416.32, -114.28, 6, 6, 0, "Hunter's Hall");
+ player->SEND_POI(-1416.32, -114.28, 7, 6, 0, "Hunter's Hall");
player->SEND_GOSSIP_MENU(1295,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Mage
- player->SEND_POI(-1061.2, 195.5, 6, 6, 0, "Pools of Vision");
+ player->SEND_POI(-1061.2, 195.5, 7, 6, 0, "Pools of Vision");
player->SEND_GOSSIP_MENU(1296,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Priest
- player->SEND_POI(-1061.2, 195.5, 6, 6, 0, "Pools of Vision");
+ player->SEND_POI(-1061.2, 195.5, 7, 6, 0, "Pools of Vision");
player->SEND_GOSSIP_MENU(1297,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Shaman
- player->SEND_POI(-989.54, 278.25, 6, 6, 0, "Hall of Spirits");
+ player->SEND_POI(-989.54, 278.25, 7, 6, 0, "Hall of Spirits");
player->SEND_GOSSIP_MENU(1298,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Warrior
- player->SEND_POI(-1416.32, -114.28, 6, 6, 0, "Hunter's Hall");
+ player->SEND_POI(-1416.32, -114.28, 7, 6, 0, "Hunter's Hall");
player->SEND_GOSSIP_MENU(1299,_Creature->GetGUID());
break;
}
@@ -420,47 +420,47 @@ void SendProfTrainerMenu_guard_bluffwatcher(Player *player, Creature *_Creature,
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(-1085.56, 27.29, 6, 6, 0, "Bena's Alchemy");
+ player->SEND_POI(-1085.56, 27.29, 7, 6, 0, "Bena's Alchemy");
player->SEND_GOSSIP_MENU(1332,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(-1239.75, 104.88, 6, 6, 0, "Karn's Smithy");
+ player->SEND_POI(-1239.75, 104.88, 7, 6, 0, "Karn's Smithy");
player->SEND_GOSSIP_MENU(1333,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(-1214.5, -21.23, 6, 6, 0, "Aska's Kitchen");
+ player->SEND_POI(-1214.5, -21.23, 7, 6, 0, "Aska's Kitchen");
player->SEND_GOSSIP_MENU(1334,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(-1112.65, 48.26, 6, 6, 0, "Dawnstrider Enchanters");
+ player->SEND_POI(-1112.65, 48.26, 7, 6, 0, "Dawnstrider Enchanters");
player->SEND_GOSSIP_MENU(1335,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //First Aid
- player->SEND_POI(-996.58, 200.5, 6, 6, 0, "Spiritual Healing");
+ player->SEND_POI(-996.58, 200.5, 7, 6, 0, "Spiritual Healing");
player->SEND_GOSSIP_MENU(1336,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Fishing
- player->SEND_POI(-1169.35, -68.87, 6, 6, 0, "Mountaintop Bait & Tackle");
+ player->SEND_POI(-1169.35, -68.87, 7, 6, 0, "Mountaintop Bait & Tackle");
player->SEND_GOSSIP_MENU(1337,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Herbalism
- player->SEND_POI(-1137.7, -1.51, 6, 6, 0, "Holistic Herbalism");
+ player->SEND_POI(-1137.7, -1.51, 7, 6, 0, "Holistic Herbalism");
player->SEND_GOSSIP_MENU(1338,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Leatherworking
- player->SEND_POI(-1156.22, 66.86, 6, 6, 0, "Thunder Bluff Armorers");
+ player->SEND_POI(-1156.22, 66.86, 7, 6, 0, "Thunder Bluff Armorers");
player->SEND_GOSSIP_MENU(1339,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Mining
- player->SEND_POI(-1249.17, 155, 6, 6, 0, "Stonehoof Geology");
+ player->SEND_POI(-1249.17, 155, 7, 6, 0, "Stonehoof Geology");
player->SEND_GOSSIP_MENU(1340,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Skinning
- player->SEND_POI(-1148.56, 51.18, 6, 6, 0, "Mooranta");
+ player->SEND_POI(-1148.56, 51.18, 7, 6, 0, "Mooranta");
player->SEND_GOSSIP_MENU(1343,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Tailoring
- player->SEND_POI(-1156.22, 66.86, 6, 6, 0, "Thunder Bluff Armorers");
+ player->SEND_POI(-1156.22, 66.86, 7, 6, 0, "Thunder Bluff Armorers");
player->SEND_GOSSIP_MENU(1341,_Creature->GetGUID());
break;
}
@@ -525,35 +525,35 @@ void SendDefaultMenu_guard_darnassus(Player *player, Creature *_Creature, uint32
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Auction house
- player->SEND_POI(9861.23, 2334.55, 6, 6, 0, "Darnassus Auction House");
+ player->SEND_POI(9861.23, 2334.55, 7, 6, 0, "Darnassus Auction House");
player->SEND_GOSSIP_MENU(3833, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Bank
- player->SEND_POI(9938.45, 2512.35, 6, 6, 0, "Darnassus Bank");
+ player->SEND_POI(9938.45, 2512.35, 7, 6, 0, "Darnassus Bank");
player->SEND_GOSSIP_MENU(3017, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Wind master
- player->SEND_POI(9945.65, 2618.94, 6, 6, 0, "Rut'theran Village");
+ player->SEND_POI(9945.65, 2618.94, 7, 6, 0, "Rut'theran Village");
player->SEND_GOSSIP_MENU(3018, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Guild master
- player->SEND_POI(10076.40, 2199.59, 6, 6, 0, "Darnassus Guild Master");
+ player->SEND_POI(10076.40, 2199.59, 7, 6, 0, "Darnassus Guild Master");
player->SEND_GOSSIP_MENU(3019, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Inn
- player->SEND_POI(10133.29, 2222.52, 6, 6, 0, "Darnassus Inn");
+ player->SEND_POI(10133.29, 2222.52, 7, 6, 0, "Darnassus Inn");
player->SEND_GOSSIP_MENU(3020, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Mailbox
- player->SEND_POI(9942.17, 2495.48, 6, 6, 0, "Darnassus Mailbox");
+ player->SEND_POI(9942.17, 2495.48, 7, 6, 0, "Darnassus Mailbox");
player->SEND_GOSSIP_MENU(3021, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Stable master
- player->SEND_POI(10167.20, 2522.66, 6, 6, 0, "Alassin");
+ player->SEND_POI(10167.20, 2522.66, 7, 6, 0, "Alassin");
player->SEND_GOSSIP_MENU(5980, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Weapon trainer
- player->SEND_POI(9907.11, 2329.70, 6, 6, 0, "Ilyenia Moonfire");
+ player->SEND_POI(9907.11, 2329.70, 7, 6, 0, "Ilyenia Moonfire");
player->SEND_GOSSIP_MENU(4517, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Battlemaster
@@ -590,15 +590,15 @@ void SendBattleMasterMenu_guard_darnassus(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //AV
- player->SEND_POI(9923.61, 2327.43, 6, 6, 0, "Brogun Stoneshield");
+ player->SEND_POI(9923.61, 2327.43, 7, 6, 0, "Brogun Stoneshield");
player->SEND_GOSSIP_MENU(7518, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //AB
- player->SEND_POI(9977.37, 2324.39, 6, 6, 0, "Keras Wolfheart");
+ player->SEND_POI(9977.37, 2324.39, 7, 6, 0, "Keras Wolfheart");
player->SEND_GOSSIP_MENU(7651, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //WSG
- player->SEND_POI(9979.84, 2315.79, 6, 6, 0, "Aethalas");
+ player->SEND_POI(9979.84, 2315.79, 7, 6, 0, "Aethalas");
player->SEND_GOSSIP_MENU(7482, _Creature->GetGUID());
break;
}
@@ -609,23 +609,23 @@ void SendClassTrainerMenu_guard_darnassus(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Druid
- player->SEND_POI(10186, 2570.46, 6, 6, 0, "Darnassus Druid Trainer");
+ player->SEND_POI(10186, 2570.46, 7, 6, 0, "Darnassus Druid Trainer");
player->SEND_GOSSIP_MENU(3024, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Hunter
- player->SEND_POI(10177.29, 2511.10, 6, 6, 0, "Darnassus Hunter Trainer");
+ player->SEND_POI(10177.29, 2511.10, 7, 6, 0, "Darnassus Hunter Trainer");
player->SEND_GOSSIP_MENU(3023, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Priest
- player->SEND_POI(9659.12, 2524.88, 6, 6, 0, "Temple of the Moon");
+ player->SEND_POI(9659.12, 2524.88, 7, 6, 0, "Temple of the Moon");
player->SEND_GOSSIP_MENU(3025, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Rogue
- player->SEND_POI(10122, 2599.12, 6, 6, 0, "Darnassus Rogue Trainer");
+ player->SEND_POI(10122, 2599.12, 7, 6, 0, "Darnassus Rogue Trainer");
player->SEND_GOSSIP_MENU(3026, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Warrior
- player->SEND_POI(9951.91, 2280.38, 6, 6, 0, "Warrior's Terrace");
+ player->SEND_POI(9951.91, 2280.38, 7, 6, 0, "Warrior's Terrace");
player->SEND_GOSSIP_MENU(3033, _Creature->GetGUID());
break;
}
@@ -636,39 +636,39 @@ void SendProfTrainerMenu_guard_darnassus(Player *player, Creature *_Creature, ui
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(10075.90, 2356.76, 6, 6, 0, "Darnassus Alchemy Trainer");
+ player->SEND_POI(10075.90, 2356.76, 7, 6, 0, "Darnassus Alchemy Trainer");
player->SEND_GOSSIP_MENU(3035, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Cooking
- player->SEND_POI(10088.59, 2419.21, 6, 6, 0, "Darnassus Cooking Trainer");
+ player->SEND_POI(10088.59, 2419.21, 7, 6, 0, "Darnassus Cooking Trainer");
player->SEND_GOSSIP_MENU(3036, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Enchanting
- player->SEND_POI(10146.09, 2313.42, 6, 6, 0, "Darnassus Enchanting Trainer");
+ player->SEND_POI(10146.09, 2313.42, 7, 6, 0, "Darnassus Enchanting Trainer");
player->SEND_GOSSIP_MENU(3337, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //First Aid
- player->SEND_POI(10150.09, 2390.43, 6, 6, 0, "Darnassus First Aid Trainer");
+ player->SEND_POI(10150.09, 2390.43, 7, 6, 0, "Darnassus First Aid Trainer");
player->SEND_GOSSIP_MENU(3037, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Fishing
- player->SEND_POI(9836.20, 2432.17, 6, 6, 0, "Darnassus Fishing Trainer");
+ player->SEND_POI(9836.20, 2432.17, 7, 6, 0, "Darnassus Fishing Trainer");
player->SEND_GOSSIP_MENU(3038, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Herbalism
- player->SEND_POI(9757.17, 2430.16, 6, 6, 0, "Darnassus Herbalism Trainer");
+ player->SEND_POI(9757.17, 2430.16, 7, 6, 0, "Darnassus Herbalism Trainer");
player->SEND_GOSSIP_MENU(3039, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Leatherworking
- player->SEND_POI(10086.59, 2255.77, 6, 6, 0, "Darnassus Leatherworking Trainer");
+ player->SEND_POI(10086.59, 2255.77, 7, 6, 0, "Darnassus Leatherworking Trainer");
player->SEND_GOSSIP_MENU(3040, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Skinning
- player->SEND_POI(10081.40, 2257.18, 6, 6, 0, "Darnassus Skinning Trainer");
+ player->SEND_POI(10081.40, 2257.18, 7, 6, 0, "Darnassus Skinning Trainer");
player->SEND_GOSSIP_MENU(3042, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Tailoring
- player->SEND_POI(10079.70, 2268.19, 6, 6, 0, "Darnassus Tailor");
+ player->SEND_POI(10079.70, 2268.19, 7, 6, 0, "Darnassus Tailor");
player->SEND_GOSSIP_MENU(3044, _Creature->GetGUID());
break;
}
@@ -727,11 +727,11 @@ void SendDefaultMenu_guard_dunmorogh(Player *player, Creature *_Creature, uint32
player->SEND_GOSSIP_MENU(4290,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Inn
- player->SEND_POI(-5582.66, -525.89, 6, 6, 0, "Thunderbrew Distillery");
+ player->SEND_POI(-5582.66, -525.89, 7, 6, 0, "Thunderbrew Distillery");
player->SEND_GOSSIP_MENU(4291,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Stable Master
- player->SEND_POI(-5604, -509.58, 6, 6, 0, "Shelby Stoneflint");
+ player->SEND_POI(-5604, -509.58, 7, 6, 0, "Shelby Stoneflint");
player->SEND_GOSSIP_MENU(5985,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Class trainer
@@ -767,31 +767,31 @@ void SendClassTrainerMenu_guard_dunmorogh(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Hunter
- player->SEND_POI(-5618.29, -454.25, 6, 6, 0, "Grif Wildheart");
+ player->SEND_POI(-5618.29, -454.25, 7, 6, 0, "Grif Wildheart");
player->SEND_GOSSIP_MENU(4293,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Mage
- player->SEND_POI(-5585.6, -539.99, 6, 6, 0, "Magis Sparkmantle");
+ player->SEND_POI(-5585.6, -539.99, 7, 6, 0, "Magis Sparkmantle");
player->SEND_GOSSIP_MENU(4294,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Paladin
- player->SEND_POI(-5585.6, -539.99, 6, 6, 0, "Azar Stronghammer");
+ player->SEND_POI(-5585.6, -539.99, 7, 6, 0, "Azar Stronghammer");
player->SEND_GOSSIP_MENU(4295,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Priest
- player->SEND_POI(-5591.74, -525.61, 6, 6, 0, "Maxan Anvol");
+ player->SEND_POI(-5591.74, -525.61, 7, 6, 0, "Maxan Anvol");
player->SEND_GOSSIP_MENU(4296,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Rogue
- player->SEND_POI(-5602.75, -542.4, 6, 6, 0, "Hogral Bakkan");
+ player->SEND_POI(-5602.75, -542.4, 7, 6, 0, "Hogral Bakkan");
player->SEND_GOSSIP_MENU(4297,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Warlock
- player->SEND_POI(-5641.97, -523.76, 6, 6, 0, "Gimrizz Shadowcog");
+ player->SEND_POI(-5641.97, -523.76, 7, 6, 0, "Gimrizz Shadowcog");
player->SEND_GOSSIP_MENU(4298,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Warrior
- player->SEND_POI(-5604.79, -529.38, 6, 6, 0, "Granis Swiftaxe");
+ player->SEND_POI(-5604.79, -529.38, 7, 6, 0, "Granis Swiftaxe");
player->SEND_GOSSIP_MENU(4299,_Creature->GetGUID());
break;
}
@@ -805,26 +805,26 @@ void SendProfTrainerMenu_guard_dunmorogh(Player *player, Creature *_Creature, ui
player->SEND_GOSSIP_MENU(4301,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(-5584.72, -428.41, 6, 6, 0, "Tognus Flintfire");
+ player->SEND_POI(-5584.72, -428.41, 7, 6, 0, "Tognus Flintfire");
player->SEND_GOSSIP_MENU(4302,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(-5596.85, -541.43, 6, 6, 0, "Gremlock Pilsnor");
+ player->SEND_POI(-5596.85, -541.43, 7, 6, 0, "Gremlock Pilsnor");
player->SEND_GOSSIP_MENU(4303,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
player->SEND_GOSSIP_MENU(4304,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Engineering
- player->SEND_POI(-5531, -666.53, 6, 6, 0, "Bronk Guzzlegear");
+ player->SEND_POI(-5531, -666.53, 7, 6, 0, "Bronk Guzzlegear");
player->SEND_GOSSIP_MENU(4305,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //First Aid
- player->SEND_POI(-5603.67, -523.57, 6, 6, 0, "Thamner Pol");
+ player->SEND_POI(-5603.67, -523.57, 7, 6, 0, "Thamner Pol");
player->SEND_GOSSIP_MENU(4306,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Fishing
- player->SEND_POI(-5199.9, 58.58, 6, 6, 0, "Paxton Ganter");
+ player->SEND_POI(-5199.9, 58.58, 7, 6, 0, "Paxton Ganter");
player->SEND_GOSSIP_MENU(4307,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Herbalism
@@ -834,7 +834,7 @@ void SendProfTrainerMenu_guard_dunmorogh(Player *player, Creature *_Creature, ui
player->SEND_GOSSIP_MENU(4310,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Mining
- player->SEND_POI(-5531, -666.53, 6, 6, 0, "Yarr Hamerstone");
+ player->SEND_POI(-5531, -666.53, 7, 6, 0, "Yarr Hamerstone");
player->SEND_GOSSIP_MENU(4311,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Skinning
@@ -893,11 +893,11 @@ void SendDefaultMenu_guard_durotar(Player *player, Creature *_Creature, uint32 a
player->SEND_GOSSIP_MENU(4033,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Inn
- player->SEND_POI(338.7, -4688.87, 6, 6, 0, "Razor Hill Inn");
+ player->SEND_POI(338.7, -4688.87, 7, 6, 0, "Razor Hill Inn");
player->SEND_GOSSIP_MENU(4034,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Stable master
- player->SEND_POI(330.31, -4710.66, 6, 6, 0, "Shoja'my");
+ player->SEND_POI(330.31, -4710.66, 7, 6, 0, "Shoja'my");
player->SEND_GOSSIP_MENU(5973,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Class trainer
@@ -933,31 +933,31 @@ void SendClassTrainerMenu_guard_durotar(Player *player, Creature *_Creature, uin
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Hunter
- player->SEND_POI(276, -4706.72, 6, 6, 0, "Thotar");
+ player->SEND_POI(276, -4706.72, 7, 6, 0, "Thotar");
player->SEND_GOSSIP_MENU(4013,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Mage
- player->SEND_POI(-839.33, -4935.6, 6, 6, 0, "Un'Thuwa");
+ player->SEND_POI(-839.33, -4935.6, 7, 6, 0, "Un'Thuwa");
player->SEND_GOSSIP_MENU(4014,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Priest
- player->SEND_POI(296.22, -4828.1, 6, 6, 0, "Tai'jin");
+ player->SEND_POI(296.22, -4828.1, 7, 6, 0, "Tai'jin");
player->SEND_GOSSIP_MENU(4015,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Rogue
- player->SEND_POI(265.76, -4709, 6, 6, 0, "Kaplak");
+ player->SEND_POI(265.76, -4709, 7, 6, 0, "Kaplak");
player->SEND_GOSSIP_MENU(4016,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Shaman
- player->SEND_POI(307.79, -4836.97, 6, 6, 0, "Swart");
+ player->SEND_POI(307.79, -4836.97, 7, 6, 0, "Swart");
player->SEND_GOSSIP_MENU(4017,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Warlock
- player->SEND_POI(355.88, -4836.45, 6, 6, 0, "Dhugru Gorelust");
+ player->SEND_POI(355.88, -4836.45, 7, 6, 0, "Dhugru Gorelust");
player->SEND_GOSSIP_MENU(4018,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Warrior
- player->SEND_POI(312.3, -4824.66, 6, 6, 0, "Tarshaw Jaggedscar");
+ player->SEND_POI(312.3, -4824.66, 7, 6, 0, "Tarshaw Jaggedscar");
player->SEND_GOSSIP_MENU(4019,_Creature->GetGUID());
break;
}
@@ -968,11 +968,11 @@ void SendProfTrainerMenu_guard_durotar(Player *player, Creature *_Creature, uint
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(-800.25, -4894.33, 6, 6, 0, "Miao'zan");
+ player->SEND_POI(-800.25, -4894.33, 7, 6, 0, "Miao'zan");
player->SEND_GOSSIP_MENU(4020,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(373.24, -4716.45, 6, 6, 0, "Dwukk");
+ player->SEND_POI(373.24, -4716.45, 7, 6, 0, "Dwukk");
player->SEND_GOSSIP_MENU(4021,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
@@ -982,26 +982,26 @@ void SendProfTrainerMenu_guard_durotar(Player *player, Creature *_Creature, uint
player->SEND_GOSSIP_MENU(4023,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Engineering
- player->SEND_POI(368.95, -4723.95, 6, 6, 0, "Mukdrak");
+ player->SEND_POI(368.95, -4723.95, 7, 6, 0, "Mukdrak");
player->SEND_GOSSIP_MENU(4024,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //First Aid
- player->SEND_POI(327.17, -4825.62, 6, 6, 0, "Rawrk");
+ player->SEND_POI(327.17, -4825.62, 7, 6, 0, "Rawrk");
player->SEND_GOSSIP_MENU(4025,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Fishing
- player->SEND_POI(-1065.48, -4777.43, 6, 6, 0, "Lau'Tiki");
+ player->SEND_POI(-1065.48, -4777.43, 7, 6, 0, "Lau'Tiki");
player->SEND_GOSSIP_MENU(4026,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Herbalism
- player->SEND_POI(-836.25, -4896.89, 6, 6, 0, "Mishiki");
+ player->SEND_POI(-836.25, -4896.89, 7, 6, 0, "Mishiki");
player->SEND_GOSSIP_MENU(4027,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Leatherworking
player->SEND_GOSSIP_MENU(4028,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Mining
- player->SEND_POI(366.94, -4705, 6, 6, 0, "Krunn");
+ player->SEND_POI(366.94, -4705, 7, 6, 0, "Krunn");
player->SEND_GOSSIP_MENU(4029,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Skinning
@@ -1064,11 +1064,11 @@ void SendDefaultMenu_guard_elwynnforest(Player *player, Creature *_Creature, uin
player->SEND_GOSSIP_MENU(4262,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Inn
- player->SEND_POI(-9459.34, 42.08, 6, 6, 0, "Lion's Pride Inn");
+ player->SEND_POI(-9459.34, 42.08, 7, 6, 0, "Lion's Pride Inn");
player->SEND_GOSSIP_MENU(4263,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Stable Master
- player->SEND_POI(-9466.62, 45.87, 6, 6, 0, "Erma");
+ player->SEND_POI(-9466.62, 45.87, 7, 6, 0, "Erma");
player->SEND_GOSSIP_MENU(5983,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Class trainer
@@ -1111,27 +1111,27 @@ void SendClassTrainerMenu_guard_elwynnforest(Player *player, Creature *_Creature
player->SEND_GOSSIP_MENU(4266,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Mage
- player->SEND_POI(-9471.12, 33.44, 6, 6, 0, "Zaldimar Wefhellt");
+ player->SEND_POI(-9471.12, 33.44, 7, 6, 0, "Zaldimar Wefhellt");
player->SEND_GOSSIP_MENU(4268,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Paladin
- player->SEND_POI(-9469, 108.05, 6, 6, 0, "Brother Wilhelm");
+ player->SEND_POI(-9469, 108.05, 7, 6, 0, "Brother Wilhelm");
player->SEND_GOSSIP_MENU(4269,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Priest
- player->SEND_POI(-9461.07, 32.6, 6, 6, 0, "Priestess Josetta");
+ player->SEND_POI(-9461.07, 32.6, 7, 6, 0, "Priestess Josetta");
player->SEND_GOSSIP_MENU(4267,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Rogue
- player->SEND_POI(-9465.13, 13.29, 6, 6, 0, "Keryn Sylvius");
+ player->SEND_POI(-9465.13, 13.29, 7, 6, 0, "Keryn Sylvius");
player->SEND_GOSSIP_MENU(4270,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Warlock
- player->SEND_POI(-9473.21, -4.08, 6, 6, 0, "Maximillian Crowe");
+ player->SEND_POI(-9473.21, -4.08, 7, 6, 0, "Maximillian Crowe");
player->SEND_GOSSIP_MENU(4272,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Warrior
- player->SEND_POI(-9461.82, 109.50, 6, 6, 0, "Lyria Du Lac");
+ player->SEND_POI(-9461.82, 109.50, 7, 6, 0, "Lyria Du Lac");
player->SEND_GOSSIP_MENU(4271,_Creature->GetGUID());
break;
}
@@ -1142,15 +1142,15 @@ void SendProfTrainerMenu_guard_elwynnforest(Player *player, Creature *_Creature,
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(-9057.04, 153.63, 6, 6, 0, "Alchemist Mallory");
+ player->SEND_POI(-9057.04, 153.63, 7, 6, 0, "Alchemist Mallory");
player->SEND_GOSSIP_MENU(4274,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(-9456.58, 87.90, 6, 6, 0, "Smith Argus");
+ player->SEND_POI(-9456.58, 87.90, 7, 6, 0, "Smith Argus");
player->SEND_GOSSIP_MENU(4275,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(-9467.54, -3.16, 6, 6, 0, "Tomas");
+ player->SEND_POI(-9467.54, -3.16, 7, 6, 0, "Tomas");
player->SEND_GOSSIP_MENU(4276,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
@@ -1160,30 +1160,30 @@ void SendProfTrainerMenu_guard_elwynnforest(Player *player, Creature *_Creature,
player->SEND_GOSSIP_MENU(4278,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //First Aid
- player->SEND_POI(-9456.82, 30.49, 6, 6, 0, "Michelle Belle");
+ player->SEND_POI(-9456.82, 30.49, 7, 6, 0, "Michelle Belle");
player->SEND_GOSSIP_MENU(4279,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Fishing
- player->SEND_POI(-9386.54, -118.73, 6, 6, 0, "Lee Brown");
+ player->SEND_POI(-9386.54, -118.73, 7, 6, 0, "Lee Brown");
player->SEND_GOSSIP_MENU(4280,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Herbalism
- player->SEND_POI(-9060.70, 149.23, 6, 6, 0, "Herbalist Pomeroy");
+ player->SEND_POI(-9060.70, 149.23, 7, 6, 0, "Herbalist Pomeroy");
player->SEND_GOSSIP_MENU(4281,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Leatherworking
- player->SEND_POI(-9376.12, -75.23, 6, 6, 0, "Adele Fielder");
+ player->SEND_POI(-9376.12, -75.23, 7, 6, 0, "Adele Fielder");
player->SEND_GOSSIP_MENU(4282,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Mining
player->SEND_GOSSIP_MENU(4283,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Skinning
- player->SEND_POI(-9536.91, -1212.76, 6, 6, 0, "Helene Peltskinner");
+ player->SEND_POI(-9536.91, -1212.76, 7, 6, 0, "Helene Peltskinner");
player->SEND_GOSSIP_MENU(4284,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 12: //Tailoring
- player->SEND_POI(-9376.12, -75.23, 6, 6, 0, "Eldrin");
+ player->SEND_POI(-9376.12, -75.23, 7, 6, 0, "Eldrin");
player->SEND_GOSSIP_MENU(4285,_Creature->GetGUID());
break;
}
@@ -1230,18 +1230,18 @@ void SendDefaultMenu_guard_eversong(Player *player, Creature *_Creature, uint32
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Bat Handler
- player->SEND_POI(9371.93, -7164.80, 6, 6, 0, "Skymistress Gloaming");
+ player->SEND_POI(9371.93, -7164.80, 7, 6, 0, "Skymistress Gloaming");
player->SEND_GOSSIP_MENU(10181,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Guild master
player->SEND_GOSSIP_MENU(10182,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Inn
- player->SEND_POI(9483.74, -6844.58, 6, 6, 0, "Delaniel's inn");
+ player->SEND_POI(9483.74, -6844.58, 7, 6, 0, "Delaniel's inn");
player->SEND_GOSSIP_MENU(10183,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Stable Master
- player->SEND_POI(9489.62, -6829.93, 6, 6, 0, "Anathos");
+ player->SEND_POI(9489.62, -6829.93, 7, 6, 0, "Anathos");
player->SEND_GOSSIP_MENU(10184,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Class trainer
@@ -1280,27 +1280,27 @@ void SendClassTrainerMenu_guard_eversong(Player *player, Creature *_Creature, ui
player->SEND_GOSSIP_MENU(10185,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Hunter
- player->SEND_POI(9527.44, -6865.25, 6, 6, 0, "Hannovia");
+ player->SEND_POI(9527.44, -6865.25, 7, 6, 0, "Hannovia");
player->SEND_GOSSIP_MENU(10186,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Mage
- player->SEND_POI(9464.24, -6855.52, 6, 6, 0, "Garridel");
+ player->SEND_POI(9464.24, -6855.52, 7, 6, 0, "Garridel");
player->SEND_GOSSIP_MENU(10187,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Paladin
- player->SEND_POI(9517.61, -6871.04, 6, 6, 0, "Noellene");
+ player->SEND_POI(9517.61, -6871.04, 7, 6, 0, "Noellene");
player->SEND_GOSSIP_MENU(10189,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Priest
- player->SEND_POI(9467.39, -6845.72, 6, 6, 0, "Ponaris");
+ player->SEND_POI(9467.39, -6845.72, 7, 6, 0, "Ponaris");
player->SEND_GOSSIP_MENU(10190,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Rogue
- player->SEND_POI(9533.67, -6877.39, 6, 6, 0, "Tannaria");
+ player->SEND_POI(9533.67, -6877.39, 7, 6, 0, "Tannaria");
player->SEND_GOSSIP_MENU(10191,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Warlock
- player->SEND_POI(9468.99, -6865.60, 6, 6, 0, "Celoenus");
+ player->SEND_POI(9468.99, -6865.60, 7, 6, 0, "Celoenus");
player->SEND_GOSSIP_MENU(10192,_Creature->GetGUID());
break;
}
@@ -1311,48 +1311,48 @@ void SendProfTrainerMenu_guard_eversong(Player *player, Creature *_Creature, uin
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(8659.90, -6368.12, 6, 6, 0, "Arcanist Sheynathren");
+ player->SEND_POI(8659.90, -6368.12, 7, 6, 0, "Arcanist Sheynathren");
player->SEND_GOSSIP_MENU(10193,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(8984.21, -7419.21, 6, 6, 0, "Arathel Sunforge");
+ player->SEND_POI(8984.21, -7419.21, 7, 6, 0, "Arathel Sunforge");
player->SEND_GOSSIP_MENU(10194,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(9494.04, -6881.51, 6, 6, 0, "Quarelestra");
+ player->SEND_POI(9494.04, -6881.51, 7, 6, 0, "Quarelestra");
player->SEND_GOSSIP_MENU(10195,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Engineering
player->SEND_GOSSIP_MENU(10197,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //First Aid
- player->SEND_POI(9479.46, -6879.16, 6, 6, 0, "Kanaria");
+ player->SEND_POI(9479.46, -6879.16, 7, 6, 0, "Kanaria");
player->SEND_GOSSIP_MENU(10198,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Fishing
player->SEND_GOSSIP_MENU(10199,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Herbalism
- player->SEND_POI(8678.92, -6329.09, 6, 6, 0, "Botanist Tyniarrel");
+ player->SEND_POI(8678.92, -6329.09, 7, 6, 0, "Botanist Tyniarrel");
player->SEND_GOSSIP_MENU(10200,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Jewelcrafting
- player->SEND_POI(9484.32, -6874.98, 6, 6, 0, "Aleinia");
+ player->SEND_POI(9484.32, -6874.98, 7, 6, 0, "Aleinia");
player->SEND_GOSSIP_MENU(10203,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Leatherworking
- player->SEND_POI(9362.04, -7130.33, 6, 6, 0, "Sathein");
+ player->SEND_POI(9362.04, -7130.33, 7, 6, 0, "Sathein");
player->SEND_GOSSIP_MENU(10204,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Mining
player->SEND_GOSSIP_MENU(10205,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Skinning
- player->SEND_POI(9362.04, -7130.33, 6, 6, 0, "Mathreyn");
+ player->SEND_POI(9362.04, -7130.33, 7, 6, 0, "Mathreyn");
player->SEND_GOSSIP_MENU(10206,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 12: //Tailoring
- player->SEND_POI(8680.36, -6327.51, 6, 6, 0, "Sempstress Ambershine");
+ player->SEND_POI(8680.36, -6327.51, 7, 6, 0, "Sempstress Ambershine");
player->SEND_GOSSIP_MENU(10207,_Creature->GetGUID());
break;
}
@@ -1404,35 +1404,35 @@ void SendDefaultMenu_guard_exodar(Player *player, Creature *_Creature, uint32 ac
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Auction house
- player->SEND_POI(-4023.6, -11739.3, 6, 6, 0, "Exodar Auction House");
+ player->SEND_POI(-4023.6, -11739.3, 7, 6, 0, "Exodar Auction House");
player->SEND_GOSSIP_MENU(9528, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Bank
- player->SEND_POI(-3923.89, -11544.5, 6, 6, 0, "Exodar Bank");
+ player->SEND_POI(-3923.89, -11544.5, 7, 6, 0, "Exodar Bank");
player->SEND_GOSSIP_MENU(9529, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Guild master
- player->SEND_POI(-4092.57, -11626.5, 6, 6, 0, "Exodar Guild Master");
+ player->SEND_POI(-4092.57, -11626.5, 7, 6, 0, "Exodar Guild Master");
player->SEND_GOSSIP_MENU(9539, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Hippogryph master
- player->SEND_POI(-4060.46, -11787.1, 6, 6, 0, "Exodar Hippogryph Master");
+ player->SEND_POI(-4060.46, -11787.1, 7, 6, 0, "Exodar Hippogryph Master");
player->SEND_GOSSIP_MENU(9530, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Inn
- player->SEND_POI(-3741.87, -11695.1, 6, 6, 0, "Exodar Inn");
+ player->SEND_POI(-3741.87, -11695.1, 7, 6, 0, "Exodar Inn");
player->SEND_GOSSIP_MENU(9545, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Mailbox
- player->SEND_POI(-3972.5, -11696.0, 6, 6, 0, "Mailbox");
+ player->SEND_POI(-3972.5, -11696.0, 7, 6, 0, "Mailbox");
player->SEND_GOSSIP_MENU(10254, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Stable master
- player->SEND_POI(-3786.5, -11702.5, 6, 6, 0, "Stable Master Arthaid");
+ player->SEND_POI(-3786.5, -11702.5, 7, 6, 0, "Stable Master Arthaid");
player->SEND_GOSSIP_MENU(9558, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Weapon trainer
- player->SEND_POI(-4215.68, -11628.9, 6, 6, 0, "Weapon Master Handiir");
+ player->SEND_POI(-4215.68, -11628.9, 7, 6, 0, "Weapon Master Handiir");
player->SEND_GOSSIP_MENU(9565, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Battlemaster
@@ -1477,23 +1477,23 @@ void SendBattleMasterMenu_guard_exodar(Player *player, Creature *_Creature, uint
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //AV
- player->SEND_POI(-3978.1, -11357, 6, 6, 0, "Alterac Valley Battlemaster");
+ player->SEND_POI(-3978.1, -11357, 7, 6, 0, "Alterac Valley Battlemaster");
player->SEND_GOSSIP_MENU(9531, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //AB
- player->SEND_POI(-3998.9, -11345.2, 6, 6, 0, "Arathi Basin Battlemaster");
+ player->SEND_POI(-3998.9, -11345.2, 7, 6, 0, "Arathi Basin Battlemaster");
player->SEND_GOSSIP_MENU(9531, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //A
- player->SEND_POI(-3759.27, -11695.63, 6, 6, 0, "Miglik Blotstrom");
+ player->SEND_POI(-3759.27, -11695.63, 7, 6, 0, "Miglik Blotstrom");
player->SEND_GOSSIP_MENU(10223, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //EOS
- player->SEND_POI(-3978.1, -11357, 6, 6, 0, "Eye Of The Storm Battlemaster");
+ player->SEND_POI(-3978.1, -11357, 7, 6, 0, "Eye Of The Storm Battlemaster");
player->SEND_GOSSIP_MENU(9531, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //WSG
- player->SEND_POI(-3977.5, -11381.2, 6, 6, 0, "Warsong Gulch Battlemaster");
+ player->SEND_POI(-3977.5, -11381.2, 7, 6, 0, "Warsong Gulch Battlemaster");
player->SEND_GOSSIP_MENU(9531, _Creature->GetGUID());
break;
}
@@ -1504,31 +1504,31 @@ void SendClassTrainerMenu_guard_exodar(Player *player, Creature *_Creature, uint
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Druid
- player->SEND_POI(-4276.0, -11495, 6, 6, 0, "Exodar Druid Trainer");
+ player->SEND_POI(-4276.0, -11495, 7, 6, 0, "Exodar Druid Trainer");
player->SEND_GOSSIP_MENU(9534, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Hunter
- player->SEND_POI(-4210.6, -11575.2, 6, 6, 0, "Exodar Hunter Trainer");
+ player->SEND_POI(-4210.6, -11575.2, 7, 6, 0, "Exodar Hunter Trainer");
player->SEND_GOSSIP_MENU(9544, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Mage
- player->SEND_POI(-4057.32, -11556.5, 6, 6, 0, "Exodar Mage Trainer");
+ player->SEND_POI(-4057.32, -11556.5, 7, 6, 0, "Exodar Mage Trainer");
player->SEND_GOSSIP_MENU(9550, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Paladin
- player->SEND_POI(-4191.2, -11470.4, 6, 6, 0, "Exodar Paladin Trainer");
+ player->SEND_POI(-4191.2, -11470.4, 7, 6, 0, "Exodar Paladin Trainer");
player->SEND_GOSSIP_MENU(9553, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Priest
- player->SEND_POI(-3969.63, -11482.8, 6, 6, 0, "Exodar Priest Trainer");
+ player->SEND_POI(-3969.63, -11482.8, 7, 6, 0, "Exodar Priest Trainer");
player->SEND_GOSSIP_MENU(9554, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Shaman
- player->SEND_POI(-3805.5, -11380.7, 6, 6, 0, "Exodar Shaman Trainer");
+ player->SEND_POI(-3805.5, -11380.7, 7, 6, 0, "Exodar Shaman Trainer");
player->SEND_GOSSIP_MENU(9556, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Warrior
- player->SEND_POI(-4189.43, -11653.7, 6, 6, 0, "Exodar Warrior Trainer");
+ player->SEND_POI(-4189.43, -11653.7, 7, 6, 0, "Exodar Warrior Trainer");
player->SEND_GOSSIP_MENU(9562, _Creature->GetGUID());
break;
}
@@ -1539,55 +1539,55 @@ void SendProfTrainerMenu_guard_exodar(Player *player, Creature *_Creature, uint3
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(-4040.6, -11364.5, 6, 6, 0, "Exodar Alchemy Trainer");
+ player->SEND_POI(-4040.6, -11364.5, 7, 6, 0, "Exodar Alchemy Trainer");
player->SEND_GOSSIP_MENU(9527, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(-4229.5, -11706, 6, 6, 0, "Exodar Blacksmithing Trainer");
+ player->SEND_POI(-4229.5, -11706, 7, 6, 0, "Exodar Blacksmithing Trainer");
player->SEND_GOSSIP_MENU(9532, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(-3798.3, -11651.7, 6, 6, 0, "Exodar Cooking Trainer");
+ player->SEND_POI(-3798.3, -11651.7, 7, 6, 0, "Exodar Cooking Trainer");
player->SEND_GOSSIP_MENU(9551, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(-3889.3, -11495, 6, 6, 0, "Exodar Enchanting Trainer");
+ player->SEND_POI(-3889.3, -11495, 7, 6, 0, "Exodar Enchanting Trainer");
player->SEND_GOSSIP_MENU(9535, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Engineering
- player->SEND_POI(-4257.68, -11640.3, 6, 6, 0, "Exodar Engineering Trainer");
+ player->SEND_POI(-4257.68, -11640.3, 7, 6, 0, "Exodar Engineering Trainer");
player->SEND_GOSSIP_MENU(9536, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //First Aid
- player->SEND_POI(-3769.5, -11479.6, 6, 6, 0, "Exodar First Aid Trainer");
+ player->SEND_POI(-3769.5, -11479.6, 7, 6, 0, "Exodar First Aid Trainer");
player->SEND_GOSSIP_MENU(9537, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Fishing
- player->SEND_POI(-3725.5, -11385.2, 6, 6, 0, "Exodar Fishing Trainer");
+ player->SEND_POI(-3725.5, -11385.2, 7, 6, 0, "Exodar Fishing Trainer");
player->SEND_GOSSIP_MENU(9538, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Jewelcrafting
- player->SEND_POI(-3783, -11546, 6, 6, 0, "Exodar Jewelcrafting Trainer");
+ player->SEND_POI(-3783, -11546, 7, 6, 0, "Exodar Jewelcrafting Trainer");
player->SEND_GOSSIP_MENU(9547, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Herbalism
- player->SEND_POI(-4040.6, -11364.5, 6, 6, 0, "Exodar Herbalist Trainer");
+ player->SEND_POI(-4040.6, -11364.5, 7, 6, 0, "Exodar Herbalist Trainer");
player->SEND_GOSSIP_MENU(9543, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Leatherworking
- player->SEND_POI(-4140.6, -11776.7, 6, 6, 0, "Exodar Leatherworking Trainer");
+ player->SEND_POI(-4140.6, -11776.7, 7, 6, 0, "Exodar Leatherworking Trainer");
player->SEND_GOSSIP_MENU(9549, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Mining
- player->SEND_POI(-4228, -11697, 6, 6, 0, "Exodar Mining Trainer");
+ player->SEND_POI(-4228, -11697, 7, 6, 0, "Exodar Mining Trainer");
player->SEND_GOSSIP_MENU(9552, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 12: //Skinning
- player->SEND_POI(-4134.97, -11760.5, 6, 6, 0, "Exodar Skinning Trainer");
+ player->SEND_POI(-4134.97, -11760.5, 7, 6, 0, "Exodar Skinning Trainer");
player->SEND_GOSSIP_MENU(9557, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 13: //Tailoring
- player->SEND_POI(-4092.5, -11744.5, 6, 6, 0, "Exodar Tailor Trainer");
+ player->SEND_POI(-4092.5, -11744.5, 7, 6, 0, "Exodar Tailor Trainer");
player->SEND_GOSSIP_MENU(9559, _Creature->GetGUID());
break;
}
@@ -1641,39 +1641,39 @@ void SendDefaultMenu_guard_ironforge(Player *player, Creature *_Creature, uint32
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Auction House
- player->SEND_POI(-4957.39, -911.6, 6, 6, 0, "Ironforge Auction House");
+ player->SEND_POI(-4957.39, -911.6, 7, 6, 0, "Ironforge Auction House");
player->SEND_GOSSIP_MENU(3014, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Bank
- player->SEND_POI(-4891.91, -991.47, 6, 6, 0, "The Vault");
+ player->SEND_POI(-4891.91, -991.47, 7, 6, 0, "The Vault");
player->SEND_GOSSIP_MENU(2761, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Tram
- player->SEND_POI(-4835.27, -1294.69, 6, 6, 0, "Deeprun Tram");
+ player->SEND_POI(-4835.27, -1294.69, 7, 6, 0, "Deeprun Tram");
player->SEND_GOSSIP_MENU(3814, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Gryphon Master
- player->SEND_POI(-4821.52, -1152.3, 6, 6, 0, "Ironforge Gryphon Master");
+ player->SEND_POI(-4821.52, -1152.3, 7, 6, 0, "Ironforge Gryphon Master");
player->SEND_GOSSIP_MENU(2762, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Guild Master
- player->SEND_POI(-5021, -996.45, 6, 6, 0, "Ironforge Visitor's Center");
+ player->SEND_POI(-5021, -996.45, 7, 6, 0, "Ironforge Visitor's Center");
player->SEND_GOSSIP_MENU(2764, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Inn
- player->SEND_POI(-4850.47, -872.57, 6, 6, 0, "Stonefire Tavern");
+ player->SEND_POI(-4850.47, -872.57, 7, 6, 0, "Stonefire Tavern");
player->SEND_GOSSIP_MENU(2768, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Mailbox
- player->SEND_POI(-4845.7, -880.55, 6, 6, 0, "Ironforge Mailbox");
+ player->SEND_POI(-4845.7, -880.55, 7, 6, 0, "Ironforge Mailbox");
player->SEND_GOSSIP_MENU(2769, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Stable Master
- player->SEND_POI(-5010.2, -1262, 6, 6, 0, "Ulbrek Firehand");
+ player->SEND_POI(-5010.2, -1262, 7, 6, 0, "Ulbrek Firehand");
player->SEND_GOSSIP_MENU(5986, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Weapons Trainer
- player->SEND_POI(-5040, -1201.88, 6, 6, 0, "Bixi and Buliwyf");
+ player->SEND_POI(-5040, -1201.88, 7, 6, 0, "Bixi and Buliwyf");
player->SEND_GOSSIP_MENU(4518, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Battlemaster
@@ -1716,15 +1716,15 @@ void SendBattleMasterMenu_guard_ironforge(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //AV
- player->SEND_POI(-5047.87, -1263.77, 6, 6, 0, "Glordrum Steelbeard");
+ player->SEND_POI(-5047.87, -1263.77, 7, 6, 0, "Glordrum Steelbeard");
player->SEND_GOSSIP_MENU(7483, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //AB
- player->SEND_POI(-5038.37, -1266.39, 6, 6, 0, "Donal Osgood");
+ player->SEND_POI(-5038.37, -1266.39, 7, 6, 0, "Donal Osgood");
player->SEND_GOSSIP_MENU(7649, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //WSG
- player->SEND_POI(-5037.24, -1274.82, 6, 6, 0, "Lylandris");
+ player->SEND_POI(-5037.24, -1274.82, 7, 6, 0, "Lylandris");
player->SEND_GOSSIP_MENU(7528, _Creature->GetGUID());
break;
}
@@ -1735,35 +1735,35 @@ void SendClassTrainerMenu_guard_ironforge(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Hunter
- player->SEND_POI(-5023, -1253.68, 6, 6, 0, "Hall of Arms");
+ player->SEND_POI(-5023, -1253.68, 7, 6, 0, "Hall of Arms");
player->SEND_GOSSIP_MENU(2770, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Mage
- player->SEND_POI(-4627, -926.45, 6, 6, 0, "Hall of Mysteries");
+ player->SEND_POI(-4627, -926.45, 7, 6, 0, "Hall of Mysteries");
player->SEND_GOSSIP_MENU(2771, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Paladin
- player->SEND_POI(-4627.02, -926.45, 6, 6, 0, "Hall of Mysteries");
+ player->SEND_POI(-4627.02, -926.45, 7, 6, 0, "Hall of Mysteries");
player->SEND_GOSSIP_MENU(2773, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Priest
- player->SEND_POI(-4627, -926.45, 6, 6, 0, "Hall of Mysteries");
+ player->SEND_POI(-4627, -926.45, 7, 6, 0, "Hall of Mysteries");
player->SEND_GOSSIP_MENU(2772, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Rogue
- player->SEND_POI(-4647.83, -1124, 6, 6, 0, "Ironforge Rogue Trainer");
+ player->SEND_POI(-4647.83, -1124, 7, 6, 0, "Ironforge Rogue Trainer");
player->SEND_GOSSIP_MENU(2774, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Warlock
- player->SEND_POI(-4605, -1110.45, 6, 6, 0, "Ironforge Warlock Trainer");
+ player->SEND_POI(-4605, -1110.45, 7, 6, 0, "Ironforge Warlock Trainer");
player->SEND_GOSSIP_MENU(2775, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Warrior
- player->SEND_POI(-5023.08, -1253.68, 6, 6, 0, "Hall of Arms");
+ player->SEND_POI(-5023.08, -1253.68, 7, 6, 0, "Hall of Arms");
player->SEND_GOSSIP_MENU(2776, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Shaman
- player->SEND_POI(-4732, -1147, 6, 6, 0, "Ironforge Shaman Trainer");
+ player->SEND_POI(-4732, -1147, 7, 6, 0, "Ironforge Shaman Trainer");
//incorrect id
player->SEND_GOSSIP_MENU(2766, _Creature->GetGUID());
break;
@@ -1775,51 +1775,51 @@ void SendProfTrainerMenu_guard_ironforge(Player *player, Creature *_Creature, ui
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(-4858.5, -1241.83, 6, 6, 0, "Berryfizz's Potions and Mixed Drinks");
+ player->SEND_POI(-4858.5, -1241.83, 7, 6, 0, "Berryfizz's Potions and Mixed Drinks");
player->SEND_GOSSIP_MENU(2794, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(-4796.97, -1110.17, 6, 6, 0, "The Great Forge");
+ player->SEND_POI(-4796.97, -1110.17, 7, 6, 0, "The Great Forge");
player->SEND_GOSSIP_MENU(2795, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(-4767.83, -1184.59, 6, 6, 0, "The Bronze Kettle");
+ player->SEND_POI(-4767.83, -1184.59, 7, 6, 0, "The Bronze Kettle");
player->SEND_GOSSIP_MENU(2796, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(-4803.72, -1196.53, 6, 6, 0, "Thistlefuzz Arcanery");
+ player->SEND_POI(-4803.72, -1196.53, 7, 6, 0, "Thistlefuzz Arcanery");
player->SEND_GOSSIP_MENU(2797, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Engineering
- player->SEND_POI(-4799.56, -1250.23, 6, 6, 0, "Springspindle's Gadgets");
+ player->SEND_POI(-4799.56, -1250.23, 7, 6, 0, "Springspindle's Gadgets");
player->SEND_GOSSIP_MENU(2798, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //First Aid
- player->SEND_POI(-4881.6, -1153.13, 6, 6, 0, "Ironforge Physician");
+ player->SEND_POI(-4881.6, -1153.13, 7, 6, 0, "Ironforge Physician");
player->SEND_GOSSIP_MENU(2799, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Fishing
- player->SEND_POI(-4597.91, -1091.93, 6, 6, 0, "Traveling Fisherman");
+ player->SEND_POI(-4597.91, -1091.93, 7, 6, 0, "Traveling Fisherman");
player->SEND_GOSSIP_MENU(2800, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Herbalism
- player->SEND_POI(-4876.9, -1151.92, 6, 6, 0, "Ironforge Physician");
+ player->SEND_POI(-4876.9, -1151.92, 7, 6, 0, "Ironforge Physician");
player->SEND_GOSSIP_MENU(2801, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Leatherworking
- player->SEND_POI(-4745, -1027.57, 6, 6, 0, "Finespindle's Leather Goods");
+ player->SEND_POI(-4745, -1027.57, 7, 6, 0, "Finespindle's Leather Goods");
player->SEND_GOSSIP_MENU(2802, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Minning
- player->SEND_POI(-4705.06, -1116.43, 6, 6, 0, "Deepmountain Mining Guild");
+ player->SEND_POI(-4705.06, -1116.43, 7, 6, 0, "Deepmountain Mining Guild");
player->SEND_GOSSIP_MENU(2804, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Skinning
- player->SEND_POI(-4745, -1027.57, 6, 6, 0, "Finespindle's Leather Goods");
+ player->SEND_POI(-4745, -1027.57, 7, 6, 0, "Finespindle's Leather Goods");
player->SEND_GOSSIP_MENU(2805, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 12: //Tailoring
- player->SEND_POI(-4719.60, -1056.96, 6, 6, 0, "Stonebrow's Clothier");
+ player->SEND_POI(-4719.60, -1056.96, 7, 6, 0, "Stonebrow's Clothier");
player->SEND_GOSSIP_MENU(2807, _Creature->GetGUID());
break;
}
@@ -1873,11 +1873,11 @@ void SendDefaultMenu_guard_mulgore(Player *player, Creature *_Creature, uint32 a
player->SEND_GOSSIP_MENU(4052,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Inn
- player->SEND_POI(-2361.38, -349.19, 6, 6, 0, "Bloodhoof Village Inn");
+ player->SEND_POI(-2361.38, -349.19, 7, 6, 0, "Bloodhoof Village Inn");
player->SEND_GOSSIP_MENU(4053,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Stable master
- player->SEND_POI(-2338.86, -357.56, 6, 6, 0, "Seikwa");
+ player->SEND_POI(-2338.86, -357.56, 7, 6, 0, "Seikwa");
player->SEND_GOSSIP_MENU(5976,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Class trainer
@@ -1909,19 +1909,19 @@ void SendClassTrainerMenu_guard_mulgore(Player *player, Creature *_Creature, uin
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Druid
- player->SEND_POI(-2312.15, -443.69, 6, 6, 0, "Gennia Runetotem");
+ player->SEND_POI(-2312.15, -443.69, 7, 6, 0, "Gennia Runetotem");
player->SEND_GOSSIP_MENU(4054,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Hunter
- player->SEND_POI(-2178.14, -406.14, 6, 6, 0, "Yaw Sharpmane");
+ player->SEND_POI(-2178.14, -406.14, 7, 6, 0, "Yaw Sharpmane");
player->SEND_GOSSIP_MENU(4055,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Shaman
- player->SEND_POI(-2301.5, -439.87, 6, 6, 0, "Narm Skychaser");
+ player->SEND_POI(-2301.5, -439.87, 7, 6, 0, "Narm Skychaser");
player->SEND_GOSSIP_MENU(4056,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Warrior
- player->SEND_POI(-2345.43, -494.11, 6, 6, 0, "Krang Stonehoof");
+ player->SEND_POI(-2345.43, -494.11, 7, 6, 0, "Krang Stonehoof");
player->SEND_GOSSIP_MENU(4057,_Creature->GetGUID());
break;
}
@@ -1938,32 +1938,32 @@ void SendProfTrainerMenu_guard_mulgore(Player *player, Creature *_Creature, uint
player->SEND_GOSSIP_MENU(4059,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(-2263.34, -287.91, 6, 6, 0, "Pyall Silentstride");
+ player->SEND_POI(-2263.34, -287.91, 7, 6, 0, "Pyall Silentstride");
player->SEND_GOSSIP_MENU(4060,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
player->SEND_GOSSIP_MENU(4061,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //First Aid
- player->SEND_POI(-2353.52, -355.82, 6, 6, 0, "Vira Younghoof");
+ player->SEND_POI(-2353.52, -355.82, 7, 6, 0, "Vira Younghoof");
player->SEND_GOSSIP_MENU(4062,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Fishing
- player->SEND_POI(-2349.21, -241.37, 6, 6, 0, "Uthan Stillwater");
+ player->SEND_POI(-2349.21, -241.37, 7, 6, 0, "Uthan Stillwater");
player->SEND_GOSSIP_MENU(4063,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Herbalism
player->SEND_GOSSIP_MENU(4064,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Leatherworking
- player->SEND_POI(-2257.12, -288.63, 6, 6, 0, "Chaw Stronghide");
+ player->SEND_POI(-2257.12, -288.63, 7, 6, 0, "Chaw Stronghide");
player->SEND_GOSSIP_MENU(4065,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Mining
player->SEND_GOSSIP_MENU(4066,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Skinning
- player->SEND_POI(-2252.94, -291.32, 6, 6, 0, "Yonn Deepcut");
+ player->SEND_POI(-2252.94, -291.32, 7, 6, 0, "Yonn Deepcut");
player->SEND_GOSSIP_MENU(4067,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Tailoring
@@ -2021,43 +2021,43 @@ void SendDefaultMenu_guard_orgrimmar(Player *player, Creature *_Creature, uint32
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Bank
- player->SEND_POI(1631.51, -4375.33, 6, 6, 0, "Bank of Orgrimmar");
+ player->SEND_POI(1631.51, -4375.33, 7, 6, 0, "Bank of Orgrimmar");
player->SEND_GOSSIP_MENU(2554,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //wind rider
- player->SEND_POI(1676.6, -4332.72, 6, 6, 0, "The Sky Tower");
+ player->SEND_POI(1676.6, -4332.72, 7, 6, 0, "The Sky Tower");
player->SEND_GOSSIP_MENU(2555,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //guild master
- player->SEND_POI(1576.93, -4294.75, 6, 6, 0, "Horde Embassy");
+ player->SEND_POI(1576.93, -4294.75, 7, 6, 0, "Horde Embassy");
player->SEND_GOSSIP_MENU(2556,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Inn
- player->SEND_POI(1644.51, -4447.27, 6, 6, 0, "Orgrimmar Inn");
+ player->SEND_POI(1644.51, -4447.27, 7, 6, 0, "Orgrimmar Inn");
player->SEND_GOSSIP_MENU(2557,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //mailbox
- player->SEND_POI(1622.53, -4388.79, 6, 6, 0, "Orgrimmar Mailbox");
+ player->SEND_POI(1622.53, -4388.79, 7, 6, 0, "Orgrimmar Mailbox");
player->SEND_GOSSIP_MENU(2558,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //auction house
- player->SEND_POI(1679.21, -4450.1, 6, 6, 0, "Orgrimmar Auction House");
+ player->SEND_POI(1679.21, -4450.1, 7, 6, 0, "Orgrimmar Auction House");
player->SEND_GOSSIP_MENU(3075,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //zeppelin
- player->SEND_POI(1337.36, -4632.7, 6, 6, 0, "Orgrimmar Zeppelin Tower");
+ player->SEND_POI(1337.36, -4632.7, 7, 6, 0, "Orgrimmar Zeppelin Tower");
player->SEND_GOSSIP_MENU(3173,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //weapon master
- player->SEND_POI(2092.56, -4823.95, 6, 6, 0, "Sayoc & Hanashi");
+ player->SEND_POI(2092.56, -4823.95, 7, 6, 0, "Sayoc & Hanashi");
player->SEND_GOSSIP_MENU(4519,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //stable master
- player->SEND_POI(2133.12, -4663.93, 6, 6, 0, "Xon'cha");
+ player->SEND_POI(2133.12, -4663.93, 7, 6, 0, "Xon'cha");
player->SEND_GOSSIP_MENU(5974,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //officers lounge
- player->SEND_POI(1633.56, -4249.37, 6, 6, 0, "Hall of Legends");
+ player->SEND_POI(1633.56, -4249.37, 7, 6, 0, "Hall of Legends");
player->SEND_GOSSIP_MENU(7046,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //battlemaster
@@ -2100,15 +2100,15 @@ void SendBattleMasterMenu_guard_orgrimmar(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //AV
- player->SEND_POI(1983.92, -4794.2, 6, 6, 0, "Hall of the Brave");
+ player->SEND_POI(1983.92, -4794.2, 7, 6, 0, "Hall of the Brave");
player->SEND_GOSSIP_MENU(7484,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //AB
- player->SEND_POI(1983.92, -4794.2, 6, 6, 0, "Hall of the Brave");
+ player->SEND_POI(1983.92, -4794.2, 7, 6, 0, "Hall of the Brave");
player->SEND_GOSSIP_MENU(7644,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //WSG
- player->SEND_POI(1983.92, -4794.2, 6, 6, 0, "Hall of the Brave");
+ player->SEND_POI(1983.92, -4794.2, 7, 6, 0, "Hall of the Brave");
player->SEND_GOSSIP_MENU(7520,_Creature->GetGUID());
break;
}
@@ -2119,35 +2119,35 @@ void SendClassTrainerMenu_guard_orgrimmar(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Hunter
- player->SEND_POI(2114.84, -4625.31, 6, 6, 0, "Orgrimmar Hunter's Hall");
+ player->SEND_POI(2114.84, -4625.31, 7, 6, 0, "Orgrimmar Hunter's Hall");
player->SEND_GOSSIP_MENU(2559,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Mage
- player->SEND_POI(1451.26, -4223.33, 6, 6, 0, "Darkbriar Lodge");
+ player->SEND_POI(1451.26, -4223.33, 7, 6, 0, "Darkbriar Lodge");
player->SEND_GOSSIP_MENU(2560,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Priest
- player->SEND_POI(1442.21, -4183.24, 6, 6, 0, "Spirit Lodge");
+ player->SEND_POI(1442.21, -4183.24, 7, 6, 0, "Spirit Lodge");
player->SEND_GOSSIP_MENU(2561,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Shaman
- player->SEND_POI(1925.34, -4181.89, 6, 6, 0, "Thrall's Fortress");
+ player->SEND_POI(1925.34, -4181.89, 7, 6, 0, "Thrall's Fortress");
player->SEND_GOSSIP_MENU(2562,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Rogue
- player->SEND_POI(1773.39, -4278.97, 6, 6, 0, "Shadowswift Brotherhood");
+ player->SEND_POI(1773.39, -4278.97, 7, 6, 0, "Shadowswift Brotherhood");
player->SEND_GOSSIP_MENU(2563,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Warlock
- player->SEND_POI(1849.57, -4359.68, 6, 6, 0, "Darkfire Enclave");
+ player->SEND_POI(1849.57, -4359.68, 7, 6, 0, "Darkfire Enclave");
player->SEND_GOSSIP_MENU(2564,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Warrior
- player->SEND_POI(1983.92, -4794.2, 6, 6, 0, "Hall of the Brave");
+ player->SEND_POI(1983.92, -4794.2, 7, 6, 0, "Hall of the Brave");
player->SEND_GOSSIP_MENU(2565,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Paladin
- player->SEND_POI(1906.65, -4134.26, 6, 6, 0, "Valley of Wisdom");
+ player->SEND_POI(1906.65, -4134.26, 7, 6, 0, "Valley of Wisdom");
player->SEND_GOSSIP_MENU(10843,_Creature->GetGUID());
break;
}
@@ -2158,51 +2158,51 @@ void SendProfTrainerMenu_guard_orgrimmar(Player *player, Creature *_Creature, ui
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(1955.17, -4475.79, 6, 6, 0, "Yelmak's Alchemy and Potions");
+ player->SEND_POI(1955.17, -4475.79, 7, 6, 0, "Yelmak's Alchemy and Potions");
player->SEND_GOSSIP_MENU(2497,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(2054.34, -4831.85, 6, 6, 0, "The Burning Anvil");
+ player->SEND_POI(2054.34, -4831.85, 7, 6, 0, "The Burning Anvil");
player->SEND_GOSSIP_MENU(2499,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(1780.96, -4481.31, 6, 6, 0, "Borstan's Firepit");
+ player->SEND_POI(1780.96, -4481.31, 7, 6, 0, "Borstan's Firepit");
player->SEND_GOSSIP_MENU(2500,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(1917.5, -4434.95, 6, 6, 0, "Godan's Runeworks");
+ player->SEND_POI(1917.5, -4434.95, 7, 6, 0, "Godan's Runeworks");
player->SEND_GOSSIP_MENU(2501,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Engineering
- player->SEND_POI(2038.45, -4744.75, 6, 6, 0, "Nogg's Machine Shop");
+ player->SEND_POI(2038.45, -4744.75, 7, 6, 0, "Nogg's Machine Shop");
player->SEND_GOSSIP_MENU(2653,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //First Aid
- player->SEND_POI(1485.21, -4160.91, 6, 6, 0, "Survival of the Fittest");
+ player->SEND_POI(1485.21, -4160.91, 7, 6, 0, "Survival of the Fittest");
player->SEND_GOSSIP_MENU(2502,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Fishing
- player->SEND_POI(1994.15, -4655.7, 6, 6, 0, "Lumak's Fishing");
+ player->SEND_POI(1994.15, -4655.7, 7, 6, 0, "Lumak's Fishing");
player->SEND_GOSSIP_MENU(2503,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Herbalism
- player->SEND_POI(1898.61, -4454.93, 6, 6, 0, "Jandi's Arboretum");
+ player->SEND_POI(1898.61, -4454.93, 7, 6, 0, "Jandi's Arboretum");
player->SEND_GOSSIP_MENU(2504,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Leatherworking
- player->SEND_POI(1852.82, -4562.31, 6, 6, 0, "Kodohide Leatherworkers");
+ player->SEND_POI(1852.82, -4562.31, 7, 6, 0, "Kodohide Leatherworkers");
player->SEND_GOSSIP_MENU(2513,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Mining
- player->SEND_POI(2029.79, -4704, 6, 6, 0, "Red Canyon Mining");
+ player->SEND_POI(2029.79, -4704, 7, 6, 0, "Red Canyon Mining");
player->SEND_GOSSIP_MENU(2515,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Skinning
- player->SEND_POI(1852.82, -4562.31, 6, 6, 0, "Kodohide Leatherworkers");
+ player->SEND_POI(1852.82, -4562.31, 7, 6, 0, "Kodohide Leatherworkers");
player->SEND_GOSSIP_MENU(2516,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 12: //Tailoring
- player->SEND_POI(1802.66, -4560.66, 6, 6, 0, "Magar's Cloth Goods");
+ player->SEND_POI(1802.66, -4560.66, 7, 6, 0, "Magar's Cloth Goods");
player->SEND_GOSSIP_MENU(2518,_Creature->GetGUID());
break;
}
@@ -2263,7 +2263,7 @@ void SendDefaultMenu_guard_shattrath(Player *player, Creature *_Creature, uint32
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Tavern
- player->SEND_POI(-1759.5, 5165, 6, 6, 0, "Worlds End Tavern");
+ player->SEND_POI(-1759.5, 5165, 7, 6, 0, "Worlds End Tavern");
player->SEND_GOSSIP_MENU(10394, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Bank
@@ -2277,7 +2277,7 @@ void SendDefaultMenu_guard_shattrath(Player *player, Creature *_Creature, uint32
player->SEND_GOSSIP_MENU(10382, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Flight master
- player->SEND_POI(-1832, 5299, 6, 6, 0, "Flight Master");
+ player->SEND_POI(-1832, 5299, 7, 6, 0, "Flight Master");
player->SEND_GOSSIP_MENU(10385, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Mailbox
@@ -2310,11 +2310,11 @@ void SendDefaultMenu_guard_shattrath(Player *player, Creature *_Creature, uint32
player->SEND_GOSSIP_MENU(10391, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Mana Loom
- player->SEND_POI(-2070, 5265.5, 6, 6, 0, "Mana Loom");
+ player->SEND_POI(-2070, 5265.5, 7, 6, 0, "Mana Loom");
player->SEND_GOSSIP_MENU(10503, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Alchemy Lab
- player->SEND_POI(-1648.5, 5540, 6, 6, 0, "Alchemy Lab");
+ player->SEND_POI(-1648.5, 5540, 7, 6, 0, "Alchemy Lab");
player->SEND_GOSSIP_MENU(10321, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Gem Merchant
@@ -2329,12 +2329,12 @@ void SendBankMenu_guard_shattrath(Player *player, Creature *_Creature, uint32 ac
{
if (action == GOSSIP_ACTION_INFO_DEF + 1)
{
- player->SEND_POI(-1730.5, 5496, 6, 6, 0, "Aldor Bank");
+ player->SEND_POI(-1730.5, 5496, 7, 6, 0, "Aldor Bank");
player->SEND_GOSSIP_MENU(10380, _Creature->GetGUID());
}
if (action == GOSSIP_ACTION_INFO_DEF + 2)
{
- player->SEND_POI(-1997.7, 5363, 6, 6, 0, "Scyers Bank");
+ player->SEND_POI(-1997.7, 5363, 7, 6, 0, "Scyers Bank");
player->SEND_GOSSIP_MENU(10381, _Creature->GetGUID());
}
}
@@ -2343,12 +2343,12 @@ void SendInnMenu_guard_shattrath(Player *player, Creature *_Creature, uint32 act
{
if (action == GOSSIP_ACTION_INFO_DEF + 1)
{
- player->SEND_POI(-1895, 5767, 6, 6, 0, "Aldor Inn");
+ player->SEND_POI(-1895, 5767, 7, 6, 0, "Aldor Inn");
player->SEND_GOSSIP_MENU(10383, _Creature->GetGUID());
}
if (action == GOSSIP_ACTION_INFO_DEF + 2)
{
- player->SEND_POI(-2178, 5405, 6, 6, 0, "Scyers Inn");
+ player->SEND_POI(-2178, 5405, 7, 6, 0, "Scyers Inn");
player->SEND_GOSSIP_MENU(10384, _Creature->GetGUID());
}
}
@@ -2358,19 +2358,19 @@ void SendMailboxMenu_guard_shattrath(Player *player, Creature *_Creature, uint32
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1:
- player->SEND_POI(-1730.5, 5496, 6, 6, 0, "Aldor Bank");
+ player->SEND_POI(-1730.5, 5496, 7, 6, 0, "Aldor Bank");
player->SEND_GOSSIP_MENU(10380, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2:
- player->SEND_POI(-1895, 5767, 6, 6, 0, "Aldor Inn");
+ player->SEND_POI(-1895, 5767, 7, 6, 0, "Aldor Inn");
player->SEND_GOSSIP_MENU(10383, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3:
- player->SEND_POI(-1997.7, 5363, 6, 6, 0, "Scyers Bank");
+ player->SEND_POI(-1997.7, 5363, 7, 6, 0, "Scyers Bank");
player->SEND_GOSSIP_MENU(10381, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4:
- player->SEND_POI(-2178, 5405, 6, 6, 0, "Scyers Inn");
+ player->SEND_POI(-2178, 5405, 7, 6, 0, "Scyers Inn");
player->SEND_GOSSIP_MENU(10384, _Creature->GetGUID());
break;
}
@@ -2380,12 +2380,12 @@ void SendStableMasterMenu_guard_shattrath(Player *player, Creature *_Creature, u
{
if (action == GOSSIP_ACTION_INFO_DEF + 1)
{
- player->SEND_POI(-1888.5, 5761, 6, 6, 0, "Aldor Stable");
+ player->SEND_POI(-1888.5, 5761, 7, 6, 0, "Aldor Stable");
player->SEND_GOSSIP_MENU(10321, _Creature->GetGUID());
}
if (action == GOSSIP_ACTION_INFO_DEF + 2)
{
- player->SEND_POI(-2170, 5404, 6, 6, 0, "Scyers Stable");
+ player->SEND_POI(-2170, 5404, 7, 6, 0, "Scyers Stable");
player->SEND_GOSSIP_MENU(10321, _Creature->GetGUID());
}
}
@@ -2395,15 +2395,15 @@ void SendBattleMasterMenu_guard_shattrath(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1:
- player->SEND_POI(-1774, 5251, 6, 6, 0, "Alliance Battlemasters");
+ player->SEND_POI(-1774, 5251, 7, 6, 0, "Alliance Battlemasters");
player->SEND_GOSSIP_MENU(10389, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2:
- player->SEND_POI(-1963, 5263, 6, 6, 0, "Horde Battlemasters");
+ player->SEND_POI(-1963, 5263, 7, 6, 0, "Horde Battlemasters");
player->SEND_GOSSIP_MENU(10390, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3:
- player->SEND_POI(-1960, 5175, 6, 6, 0, "Arena Battlemasters");
+ player->SEND_POI(-1960, 5175, 7, 6, 0, "Arena Battlemasters");
player->SEND_GOSSIP_MENU(12510, _Creature->GetGUID());
break;
}
@@ -2414,35 +2414,35 @@ void SendProfTrainerMenu_guard_shattrath(Player *player, Creature *_Creature, ui
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(-1648.5, 5534, 6, 6, 0, "Lorokeem");
+ player->SEND_POI(-1648.5, 5534, 7, 6, 0, "Lorokeem");
player->SEND_GOSSIP_MENU(10392, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(-1847, 5222, 6, 6, 0, "Kradu Grimblade and Zula Slagfury");
+ player->SEND_POI(-1847, 5222, 7, 6, 0, "Kradu Grimblade and Zula Slagfury");
player->SEND_GOSSIP_MENU(10400, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(-2067.4, 5316.5, 6, 6, 0, "Jack Trapper");
+ player->SEND_POI(-2067.4, 5316.5, 7, 6, 0, "Jack Trapper");
player->SEND_GOSSIP_MENU(10393, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(-2263.5, 5563.5, 6, 6, 0, "High Enchanter Bardolan");
+ player->SEND_POI(-2263.5, 5563.5, 7, 6, 0, "High Enchanter Bardolan");
player->SEND_GOSSIP_MENU(10395, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //First Aid
- player->SEND_POI(-1591, 5265.5, 6, 6, 0, "Mildred Fletcher");
+ player->SEND_POI(-1591, 5265.5, 7, 6, 0, "Mildred Fletcher");
player->SEND_GOSSIP_MENU(10396, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Jewelcrafting
- player->SEND_POI(-1654, 5667.5, 6, 6, 0, "Hamanar");
+ player->SEND_POI(-1654, 5667.5, 7, 6, 0, "Hamanar");
player->SEND_GOSSIP_MENU(10397, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Leatherworking
- player->SEND_POI(-2060.5, 5256.5, 6, 6, 0, "Darmari");
+ player->SEND_POI(-2060.5, 5256.5, 7, 6, 0, "Darmari");
player->SEND_GOSSIP_MENU(10399, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Skinning
- player->SEND_POI(-2048, 5300, 6, 6, 0, "Seymour");
+ player->SEND_POI(-2048, 5300, 7, 6, 0, "Seymour");
player->SEND_GOSSIP_MENU(10398, _Creature->GetGUID());
break;
}
@@ -2452,12 +2452,12 @@ void SendGemMerchantMenu_guard_shattrath(Player *player, Creature *_Creature, ui
{
if (action == GOSSIP_ACTION_INFO_DEF + 1)
{
- player->SEND_POI(-1645, 5669.5, 6, 6, 0, "Aldor Gem Merchant");
+ player->SEND_POI(-1645, 5669.5, 7, 6, 0, "Aldor Gem Merchant");
player->SEND_GOSSIP_MENU(10698, _Creature->GetGUID());
}
if (action == GOSSIP_ACTION_INFO_DEF + 2)
{
- player->SEND_POI(-2193, 5424.5, 6, 6, 0, "Scyers Gem Merchant");
+ player->SEND_POI(-2193, 5424.5, 7, 6, 0, "Scyers Gem Merchant");
player->SEND_GOSSIP_MENU(10699, _Creature->GetGUID());
}
}
@@ -2573,28 +2573,28 @@ void SendDefaultMenu_guard_shattrath_aldor(Player *player, Creature *_Creature,
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Tavern
- player->SEND_POI(-1759.5, 5165, 6, 6, 0, "Worlds End Tavern");
+ player->SEND_POI(-1759.5, 5165, 7, 6, 0, "Worlds End Tavern");
player->SEND_GOSSIP_MENU(10394, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Bank
- player->SEND_POI(-1730.5, 5496, 6, 6, 0, "Aldor Bank");
+ player->SEND_POI(-1730.5, 5496, 7, 6, 0, "Aldor Bank");
player->SEND_GOSSIP_MENU(10380, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Inn
- player->SEND_POI(-1895, 5767, 6, 6, 0, "Aldor Inn");
+ player->SEND_POI(-1895, 5767, 7, 6, 0, "Aldor Inn");
player->SEND_GOSSIP_MENU(10525, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Flight master
- player->SEND_POI(-1832, 5299, 6, 6, 0, "Shattrath Flight Master");
+ player->SEND_POI(-1832, 5299, 7, 6, 0, "Shattrath Flight Master");
player->SEND_GOSSIP_MENU(10402, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Mailbox
- player->SEND_POI(0, 0, 6, 6, 0, "Aldor Mailbox");
+ player->SEND_POI(0, 0, 7, 6, 0, "Aldor Mailbox");
//unknown
player->SEND_GOSSIP_MENU(10524, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Stable master
- player->SEND_POI(-1888.5, 5761, 6, 6, 0, "Aldor Stable Master");
+ player->SEND_POI(-1888.5, 5761, 7, 6, 0, "Aldor Stable Master");
player->SEND_GOSSIP_MENU(10527, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Battlemaster
@@ -2615,15 +2615,15 @@ void SendDefaultMenu_guard_shattrath_aldor(Player *player, Creature *_Creature,
player->SEND_GOSSIP_MENU(10391, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Mana Loom
- player->SEND_POI(-2070, 5265.5, 6, 6, 0, "Mana Loom");
+ player->SEND_POI(-2070, 5265.5, 7, 6, 0, "Mana Loom");
player->SEND_GOSSIP_MENU(10522, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Alchemy Lab
- player->SEND_POI(-1648.5, 5540, 6, 6, 0, "Alchemy Lab");
+ player->SEND_POI(-1648.5, 5540, 7, 6, 0, "Alchemy Lab");
player->SEND_GOSSIP_MENU(10696, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Gem Merchant
- player->SEND_POI(-1645, 5669.5, 6, 6, 0, "Aldor Gem Merchant");
+ player->SEND_POI(-1645, 5669.5, 7, 6, 0, "Aldor Gem Merchant");
player->SEND_GOSSIP_MENU(10411, _Creature->GetGUID());
break;
}
@@ -2634,35 +2634,35 @@ void SendProfTrainerMenu_guard_shattrath_aldor(Player *player, Creature *_Creatu
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(-1648.5, 5534, 6, 6, 0, "Lorokeem");
+ player->SEND_POI(-1648.5, 5534, 7, 6, 0, "Lorokeem");
player->SEND_GOSSIP_MENU(10392, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(-1847, 5222, 6, 6, 0, "Kradu Grimblade and Zula Slagfury");
+ player->SEND_POI(-1847, 5222, 7, 6, 0, "Kradu Grimblade and Zula Slagfury");
player->SEND_GOSSIP_MENU(10400, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(-2067.4, 5316.5, 6, 6, 0, "Jack Trapper");
+ player->SEND_POI(-2067.4, 5316.5, 7, 6, 0, "Jack Trapper");
player->SEND_GOSSIP_MENU(10393, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(-2263.5, 5563.5, 6, 6, 0, "High Enchanter Bardolan");
+ player->SEND_POI(-2263.5, 5563.5, 7, 6, 0, "High Enchanter Bardolan");
player->SEND_GOSSIP_MENU(10528, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //First Aid
- player->SEND_POI(-1591, 5265.5, 6, 6, 0, "Mildred Fletcher");
+ player->SEND_POI(-1591, 5265.5, 7, 6, 0, "Mildred Fletcher");
player->SEND_GOSSIP_MENU(10396, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Jewelcrafting
- player->SEND_POI(-1654, 5667.5, 6, 6, 0, "Hamanar");
+ player->SEND_POI(-1654, 5667.5, 7, 6, 0, "Hamanar");
player->SEND_GOSSIP_MENU(10529, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Leatherworking
- player->SEND_POI(-2060.5, 5256.5, 6, 6, 0, "Darmari");
+ player->SEND_POI(-2060.5, 5256.5, 7, 6, 0, "Darmari");
player->SEND_GOSSIP_MENU(10399, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Skinning
- player->SEND_POI(-2048, 5300, 6, 6, 0, "Seymour");
+ player->SEND_POI(-2048, 5300, 7, 6, 0, "Seymour");
player->SEND_GOSSIP_MENU(10419, _Creature->GetGUID());
break;
}
@@ -2769,27 +2769,27 @@ void SendDefaultMenu_guard_shattrath_scryer(Player *player, Creature *_Creature,
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Tavern
- player->SEND_POI(-1759.5, 5165, 6, 6, 0, "Worlds End Tavern");
+ player->SEND_POI(-1759.5, 5165, 7, 6, 0, "Worlds End Tavern");
player->SEND_GOSSIP_MENU(10431, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Bank
- player->SEND_POI(-1996.6, 5363.7, 6, 6, 0, "Scryer Bank");
+ player->SEND_POI(-1996.6, 5363.7, 7, 6, 0, "Scryer Bank");
player->SEND_GOSSIP_MENU(10432, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Inn
- player->SEND_POI(-2176.6, 5405.8, 6, 6, 0, "Scryer Inn");
+ player->SEND_POI(-2176.6, 5405.8, 7, 6, 0, "Scryer Inn");
player->SEND_GOSSIP_MENU(10433, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Flight master
- player->SEND_POI(-1832, 5299, 6, 6, 0, "Shattrath Flight Master");
+ player->SEND_POI(-1832, 5299, 7, 6, 0, "Shattrath Flight Master");
player->SEND_GOSSIP_MENU(10435, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Mailbox
- player->SEND_POI(-2174.3, 5411.4, 6, 6, 0, "Scryer Mailbox");
+ player->SEND_POI(-2174.3, 5411.4, 7, 6, 0, "Scryer Mailbox");
player->SEND_GOSSIP_MENU(10436, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Stable master
- player->SEND_POI(-2169.9, 5405.1, 6, 6, 0, "Scryer Stable Master");
+ player->SEND_POI(-2169.9, 5405.1, 7, 6, 0, "Scryer Stable Master");
player->SEND_GOSSIP_MENU(10437, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Battlemaster
@@ -2810,15 +2810,15 @@ void SendDefaultMenu_guard_shattrath_scryer(Player *player, Creature *_Creature,
player->SEND_GOSSIP_MENU(10504, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Mana Loom
- player->SEND_POI(-2070, 5265.5, 6, 6, 0, "Mana Loom");
+ player->SEND_POI(-2070, 5265.5, 7, 6, 0, "Mana Loom");
player->SEND_GOSSIP_MENU(10522, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Alchemy Lab
- player->SEND_POI(-1648.5, 5540, 6, 6, 0, "Alchemy Lab");
+ player->SEND_POI(-1648.5, 5540, 7, 6, 0, "Alchemy Lab");
player->SEND_GOSSIP_MENU(10701, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Gem Merchant
- player->SEND_POI(-1645, 5669.5, 6, 6, 0, "Scryer Gem Merchant");
+ player->SEND_POI(-1645, 5669.5, 7, 6, 0, "Scryer Gem Merchant");
player->SEND_GOSSIP_MENU(10702, _Creature->GetGUID());
break;
}
@@ -2829,35 +2829,35 @@ void SendProfTrainerMenu_guard_shattrath_scryer(Player *player, Creature *_Creat
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(-1648.5, 5534, 6, 6, 0, "Lorokeem");
+ player->SEND_POI(-1648.5, 5534, 7, 6, 0, "Lorokeem");
player->SEND_GOSSIP_MENU(10516, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(-1847, 5222, 6, 6, 0, "Kradu Grimblade and Zula Slagfury");
+ player->SEND_POI(-1847, 5222, 7, 6, 0, "Kradu Grimblade and Zula Slagfury");
player->SEND_GOSSIP_MENU(10517, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(-2067.4, 5316.5, 6, 6, 0, "Jack Trapper");
+ player->SEND_POI(-2067.4, 5316.5, 7, 6, 0, "Jack Trapper");
player->SEND_GOSSIP_MENU(10518, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(-2263.5, 5563.5, 6, 6, 0, "High Enchanter Bardolan");
+ player->SEND_POI(-2263.5, 5563.5, 7, 6, 0, "High Enchanter Bardolan");
player->SEND_GOSSIP_MENU(10519, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //First Aid
- player->SEND_POI(-1591, 5265.5, 6, 6, 0, "Mildred Fletcher");
+ player->SEND_POI(-1591, 5265.5, 7, 6, 0, "Mildred Fletcher");
player->SEND_GOSSIP_MENU(10520, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Jewelcrafting
- player->SEND_POI(-1654, 5667.5, 6, 6, 0, "Hamanar");
+ player->SEND_POI(-1654, 5667.5, 7, 6, 0, "Hamanar");
player->SEND_GOSSIP_MENU(10521, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Leatherworking
- player->SEND_POI(-2060.5, 5256.5, 6, 6, 0, "Darmari");
+ player->SEND_POI(-2060.5, 5256.5, 7, 6, 0, "Darmari");
player->SEND_GOSSIP_MENU(10523, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Skinning
- player->SEND_POI(-2048, 5300, 6, 6, 0, "Seymour");
+ player->SEND_POI(-2048, 5300, 7, 6, 0, "Seymour");
player->SEND_GOSSIP_MENU(10523, _Creature->GetGUID());
break;
}
@@ -2914,11 +2914,11 @@ void SendDefaultMenu_guard_silvermoon(Player *player, Creature *_Creature, uint3
player->SEND_GOSSIP_MENU(9317, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Bank
- player->SEND_POI(9808.4, -7488.16, 6, 6, 0, "Silvermoon Bank");
+ player->SEND_POI(9808.4, -7488.16, 7, 6, 0, "Silvermoon Bank");
player->SEND_GOSSIP_MENU(9322, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Guild master
- player->SEND_POI(9474.97, -7345.21, 6, 6, 0, "Tandrine");
+ player->SEND_POI(9474.97, -7345.21, 7, 6, 0, "Tandrine");
player->SEND_GOSSIP_MENU(9324, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Inn
@@ -2927,19 +2927,19 @@ void SendDefaultMenu_guard_silvermoon(Player *player, Creature *_Creature, uint3
player->SEND_GOSSIP_MENU(9602, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Mailbox
- player->SEND_POI(9658.33, -7492.17, 6, 6, 0, "Silvermoon Mailbox");
+ player->SEND_POI(9658.33, -7492.17, 7, 6, 0, "Silvermoon Mailbox");
player->SEND_GOSSIP_MENU(9326, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Stable master
- player->SEND_POI(9904.95, -7404.31, 6, 6, 0, "Shalenn");
+ player->SEND_POI(9904.95, -7404.31, 7, 6, 0, "Shalenn");
player->SEND_GOSSIP_MENU(9327, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Weapon trainer
- player->SEND_POI(9841.17, -7505.13, 6, 6, 0, "Ileda");
+ player->SEND_POI(9841.17, -7505.13, 7, 6, 0, "Ileda");
player->SEND_GOSSIP_MENU(9328, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Wind master
- player->SEND_POI(9378.45, -7163.94, 6, 6, 0, "Silvermoon Wind Master");
+ player->SEND_POI(9378.45, -7163.94, 7, 6, 0, "Silvermoon Wind Master");
player->SEND_GOSSIP_MENU(10181, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Battlemaster
@@ -2983,12 +2983,12 @@ void SendAuctionhouseMenu_guard_silvermoon(Player *player, Creature *_Creature,
{
if (action == GOSSIP_ACTION_INFO_DEF + 1)
{
- player->SEND_POI(9644.47, -7140.22, 6, 6, 0, "Western Auction House");
+ player->SEND_POI(9644.47, -7140.22, 7, 6, 0, "Western Auction House");
player->SEND_GOSSIP_MENU(9318, _Creature->GetGUID());
}
if (action == GOSSIP_ACTION_INFO_DEF + 2)
{
- player->SEND_POI(9683.27, -7521.22, 6, 6, 0, "Royal Exchange Auction House");
+ player->SEND_POI(9683.27, -7521.22, 7, 6, 0, "Royal Exchange Auction House");
player->SEND_GOSSIP_MENU(9319, _Creature->GetGUID());
}
}
@@ -2997,12 +2997,12 @@ void SendInnMenu_guard_silvermoon(Player *player, Creature *_Creature, uint32 ac
{
if (action == GOSSIP_ACTION_INFO_DEF + 1)
{
- player->SEND_POI(9677.7, -7368, 6, 6, 0, "Silvermoon City Inn");
+ player->SEND_POI(9677.7, -7368, 7, 6, 0, "Silvermoon City Inn");
player->SEND_GOSSIP_MENU(9325, _Creature->GetGUID());
}
if (action == GOSSIP_ACTION_INFO_DEF + 2)
{
- player->SEND_POI(9561.1, -7517.5, 6, 6, 0, "Wayfarer's Rest tavern");
+ player->SEND_POI(9561.1, -7517.5, 7, 6, 0, "Wayfarer's Rest tavern");
player->SEND_GOSSIP_MENU(9603, _Creature->GetGUID());
}
}
@@ -3012,23 +3012,23 @@ void SendBattleMasterMenu_guard_silvermoon(Player *player, Creature *_Creature,
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //AV
- player->SEND_POI(9850.49, -7572.26, 6, 6, 0, "Gurak");
+ player->SEND_POI(9850.49, -7572.26, 7, 6, 0, "Gurak");
player->SEND_GOSSIP_MENU(9329, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //AB
- player->SEND_POI(9857.18, -7564.36, 6, 6, 0, "Karen Wentworth");
+ player->SEND_POI(9857.18, -7564.36, 7, 6, 0, "Karen Wentworth");
player->SEND_GOSSIP_MENU(9329, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //A
- player->SEND_POI(9850.6, -7559.25, 6, 6, 0, "Bipp Glizzitor");
+ player->SEND_POI(9850.6, -7559.25, 7, 6, 0, "Bipp Glizzitor");
player->SEND_GOSSIP_MENU(9329, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //EOS
- player->SEND_POI(9857.18, -7564.36, 6, 6, 0, "Karen Wentworth");
+ player->SEND_POI(9857.18, -7564.36, 7, 6, 0, "Karen Wentworth");
player->SEND_GOSSIP_MENU(9329, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //WSG
- player->SEND_POI(9845.45, -7562.58, 6, 6, 0, "Krukk");
+ player->SEND_POI(9845.45, -7562.58, 7, 6, 0, "Krukk");
player->SEND_GOSSIP_MENU(9329, _Creature->GetGUID());
break;
}
@@ -3039,31 +3039,31 @@ void SendClassTrainerMenu_guard_silvermoon(Player *player, Creature *_Creature,
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Druid
- player->SEND_POI(9700.55, -7262.57, 6, 6, 0, "Harene Plainwalker");
+ player->SEND_POI(9700.55, -7262.57, 7, 6, 0, "Harene Plainwalker");
player->SEND_GOSSIP_MENU(9330, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Hunter
- player->SEND_POI(9927.48, -7426.14, 6, 6, 0, "Zandine");
+ player->SEND_POI(9927.48, -7426.14, 7, 6, 0, "Zandine");
player->SEND_GOSSIP_MENU(9332, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Mage
- player->SEND_POI(9995.07, -7118.17, 6, 6, 0, "Quithas");
+ player->SEND_POI(9995.07, -7118.17, 7, 6, 0, "Quithas");
player->SEND_GOSSIP_MENU(9333, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Paladin
- player->SEND_POI(9850.22, -7516.93, 6, 6, 0, "Champion Bachi");
+ player->SEND_POI(9850.22, -7516.93, 7, 6, 0, "Champion Bachi");
player->SEND_GOSSIP_MENU(9334, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Priest
- player->SEND_POI(9926.79, -7066.66, 6, 6, 0, "Belestra");
+ player->SEND_POI(9926.79, -7066.66, 7, 6, 0, "Belestra");
player->SEND_GOSSIP_MENU(9335, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Rogue
- player->SEND_POI(9739.88, -7374.33, 6, 6, 0, "Zelanis");
+ player->SEND_POI(9739.88, -7374.33, 7, 6, 0, "Zelanis");
player->SEND_GOSSIP_MENU(9336, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Warlock
- player->SEND_POI(9787.57, -7284.63, 6, 6, 0, "Alamma");
+ player->SEND_POI(9787.57, -7284.63, 7, 6, 0, "Alamma");
player->SEND_GOSSIP_MENU(9337, _Creature->GetGUID());
break;
}
@@ -3074,55 +3074,55 @@ void SendProfTrainerMenu_guard_silvermoon(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(9998.09, -7214.36, 6, 6, 0, "Silvermoon Alchemy Trainer");
+ player->SEND_POI(9998.09, -7214.36, 7, 6, 0, "Silvermoon Alchemy Trainer");
player->SEND_GOSSIP_MENU(9316, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(9841.43, -7361.53, 6, 6, 0, "Silvermoon Blacksmithing Trainer");
+ player->SEND_POI(9841.43, -7361.53, 7, 6, 0, "Silvermoon Blacksmithing Trainer");
player->SEND_GOSSIP_MENU(9340, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(9577.26, -7243.6, 6, 6, 0, "Silvermoon Cooking Trainer");
+ player->SEND_POI(9577.26, -7243.6, 7, 6, 0, "Silvermoon Cooking Trainer");
player->SEND_GOSSIP_MENU(9316, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(9962.57, -7246.18, 6, 6, 0, "Silvermoon Enchanting Trainer");
+ player->SEND_POI(9962.57, -7246.18, 7, 6, 0, "Silvermoon Enchanting Trainer");
player->SEND_GOSSIP_MENU(9341, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Engineering
- player->SEND_POI(9820.18, -7329.56, 6, 6, 0, "Silvermoon Engineering Trainer");
+ player->SEND_POI(9820.18, -7329.56, 7, 6, 0, "Silvermoon Engineering Trainer");
player->SEND_GOSSIP_MENU(9316, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //First Aid
- player->SEND_POI(9579.8, -7343.71, 6, 6, 0, "Silvermoon First Aid Trainer");
+ player->SEND_POI(9579.8, -7343.71, 7, 6, 0, "Silvermoon First Aid Trainer");
player->SEND_GOSSIP_MENU(9316, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Fishing
- player->SEND_POI(9602.73, -7328.3, 6, 6, 0, "Silvermoon Fishing Trainer");
+ player->SEND_POI(9602.73, -7328.3, 7, 6, 0, "Silvermoon Fishing Trainer");
player->SEND_GOSSIP_MENU(9316, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Jewelcrafting
- player->SEND_POI(9553.54, -7506.43, 6, 6, 0, "Silvermoon Jewelcrafting Trainer");
+ player->SEND_POI(9553.54, -7506.43, 7, 6, 0, "Silvermoon Jewelcrafting Trainer");
player->SEND_GOSSIP_MENU(9346, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Herbalism
- player->SEND_POI(10004.4, -7216.86, 6, 6, 0, "Silvermoon Herbalism Trainer");
+ player->SEND_POI(10004.4, -7216.86, 7, 6, 0, "Silvermoon Herbalism Trainer");
player->SEND_GOSSIP_MENU(9316, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Leatherworking
- player->SEND_POI(9503.72, -7430.16, 6, 6, 0, "Silvermoon Leatherworking Trainer");
+ player->SEND_POI(9503.72, -7430.16, 7, 6, 0, "Silvermoon Leatherworking Trainer");
player->SEND_GOSSIP_MENU(9347, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Mining
- player->SEND_POI(9805.1, -7355.56, 6, 6, 0, "Silvermoon Mining Trainer");
+ player->SEND_POI(9805.1, -7355.56, 7, 6, 0, "Silvermoon Mining Trainer");
player->SEND_GOSSIP_MENU(9348, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 12: //Skinning
- player->SEND_POI(9513.37, -7429.4, 6, 6, 0, "Silvermoon Skinning Trainer");
+ player->SEND_POI(9513.37, -7429.4, 7, 6, 0, "Silvermoon Skinning Trainer");
player->SEND_GOSSIP_MENU(9316, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 13: //Tailoring
- player->SEND_POI(9750.55, -7095.28, 6, 6, 0, "Silvermoon Tailor");
+ player->SEND_POI(9750.55, -7095.28, 7, 6, 0, "Silvermoon Tailor");
player->SEND_GOSSIP_MENU(9350, _Creature->GetGUID());
break;
}
@@ -3179,43 +3179,43 @@ void SendDefaultMenu_guard_stormwind(Player *player, Creature *_Creature, uint32
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Auction House
- player->SEND_POI(-8811.46, 667.46, 6, 6, 0, "Stormwind Auction House");
+ player->SEND_POI(-8811.46, 667.46, 7, 6, 0, "Stormwind Auction House");
player->SEND_GOSSIP_MENU(3834,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Bank
- player->SEND_POI(-8916.87, 622.87, 6, 6, 0, "Stormwind Bank");
+ player->SEND_POI(-8916.87, 622.87, 7, 6, 0, "Stormwind Bank");
player->SEND_GOSSIP_MENU(764,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Deeprun tram
- player->SEND_POI(-8378.88, 554.23, 6, 6, 0, "The Deeprun Tram");
+ player->SEND_POI(-8378.88, 554.23, 7, 6, 0, "The Deeprun Tram");
player->SEND_GOSSIP_MENU(3813,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Inn
- player->SEND_POI(-8869.0, 675.4, 6, 6, 0, "The Gilded Rose");
+ player->SEND_POI(-8869.0, 675.4, 7, 6, 0, "The Gilded Rose");
player->SEND_GOSSIP_MENU(3860,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Gryphon Master
- player->SEND_POI(-8837.0, 493.5, 6, 6, 0, "Stormwind Gryphon Master");
+ player->SEND_POI(-8837.0, 493.5, 7, 6, 0, "Stormwind Gryphon Master");
player->SEND_GOSSIP_MENU(879,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Guild Master
- player->SEND_POI(-8894.0, 611.2, 6, 6, 0, "Stormwind Vistor`s Center");
+ player->SEND_POI(-8894.0, 611.2, 7, 6, 0, "Stormwind Vistor`s Center");
player->SEND_GOSSIP_MENU(882,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Mailbox
- player->SEND_POI(-8876.48, 649.18, 6, 6, 0, "Stormwind Mailbox");
+ player->SEND_POI(-8876.48, 649.18, 7, 6, 0, "Stormwind Mailbox");
player->SEND_GOSSIP_MENU(3861,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Stable Master
- player->SEND_POI(-8433.0, 554.7, 6, 6, 0, "Jenova Stoneshield");
+ player->SEND_POI(-8433.0, 554.7, 7, 6, 0, "Jenova Stoneshield");
player->SEND_GOSSIP_MENU(5984,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Weapon Trainer
- player->SEND_POI(-8797.0, 612.8, 6, 6, 0, "Woo Ping");
+ player->SEND_POI(-8797.0, 612.8, 7, 6, 0, "Woo Ping");
player->SEND_GOSSIP_MENU(4516,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Officers Lounge
- player->SEND_POI(-8759.92, 399.69, 6, 6, 0, "Champions` Hall");
+ player->SEND_POI(-8759.92, 399.69, 7, 6, 0, "Champions` Hall");
player->SEND_GOSSIP_MENU(7047,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Battlemasters
@@ -3259,15 +3259,15 @@ void SendBattleMasterMenu_guard_stormwind(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //AV
- player->SEND_POI(-8443.88, 335.99, 6, 6, 0, "Thelman Slatefist");
+ player->SEND_POI(-8443.88, 335.99, 7, 6, 0, "Thelman Slatefist");
player->SEND_GOSSIP_MENU(7500, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //AB
- player->SEND_POI(-8443.88, 335.99, 6, 6, 0, "Lady Hoteshem");
+ player->SEND_POI(-8443.88, 335.99, 7, 6, 0, "Lady Hoteshem");
player->SEND_GOSSIP_MENU(7650, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //WSG
- player->SEND_POI(-8443.88, 335.99, 6, 6, 0, "Elfarran");
+ player->SEND_POI(-8443.88, 335.99, 7, 6, 0, "Elfarran");
player->SEND_GOSSIP_MENU(7501, _Creature->GetGUID());
break;
}
@@ -3278,39 +3278,39 @@ void SendClassTrainerMenu_guard_stormwind(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Mage
- player->SEND_POI(-9012.0, 867.6, 6, 6, 0, "Wizard`s Sanctum");
+ player->SEND_POI(-9012.0, 867.6, 7, 6, 0, "Wizard`s Sanctum");
player->SEND_GOSSIP_MENU(899,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Rogue
- player->SEND_POI(-8753.0, 367.8, 6, 6, 0, "Stormwind - Rogue House");
+ player->SEND_POI(-8753.0, 367.8, 7, 6, 0, "Stormwind - Rogue House");
player->SEND_GOSSIP_MENU(900,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Warrior
- player->SEND_POI(-8690.11, 324.85, 6, 6, 0, "Command Center");
+ player->SEND_POI(-8690.11, 324.85, 7, 6, 0, "Command Center");
player->SEND_GOSSIP_MENU(901,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Druid
- player->SEND_POI(-8751.0, 1124.5, 6, 6, 0, "The Park");
+ player->SEND_POI(-8751.0, 1124.5, 7, 6, 0, "The Park");
player->SEND_GOSSIP_MENU(902,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Priest
- player->SEND_POI(-8512.0, 862.4, 6, 6, 0, "Catedral Of Light");
+ player->SEND_POI(-8512.0, 862.4, 7, 6, 0, "Catedral Of Light");
player->SEND_GOSSIP_MENU(903,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Paladin
- player->SEND_POI(-8577.0, 881.7, 6, 6, 0, "Catedral Of Light");
+ player->SEND_POI(-8577.0, 881.7, 7, 6, 0, "Catedral Of Light");
player->SEND_GOSSIP_MENU(904,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Hunter
- player->SEND_POI(-8413.0, 541.5, 6, 6, 0, "Hunter Lodge");
+ player->SEND_POI(-8413.0, 541.5, 7, 6, 0, "Hunter Lodge");
player->SEND_GOSSIP_MENU(905,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Warlock
- player->SEND_POI(-8948.91, 998.35, 6, 6, 0, "The Slaughtered Lamb");
+ player->SEND_POI(-8948.91, 998.35, 7, 6, 0, "The Slaughtered Lamb");
player->SEND_GOSSIP_MENU(906,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Shaman
- player->SEND_POI(-9033, 550, 6, 6, 0, "Valley Of Heroes");
+ player->SEND_POI(-9033, 550, 7, 6, 0, "Valley Of Heroes");
//incorrect id
player->SEND_GOSSIP_MENU(2593,_Creature->GetGUID());
break;
@@ -3322,51 +3322,51 @@ void SendProfTrainerMenu_guard_stormwind(Player *player, Creature *_Creature, ui
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(-8988.0, 759.60, 6, 6, 0, "Alchemy Needs");
+ player->SEND_POI(-8988.0, 759.60, 7, 6, 0, "Alchemy Needs");
player->SEND_GOSSIP_MENU(919,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(-8424.0, 616.9, 6, 6, 0, "Therum Deepforge");
+ player->SEND_POI(-8424.0, 616.9, 7, 6, 0, "Therum Deepforge");
player->SEND_GOSSIP_MENU(920,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(-8611.0, 364.6, 6, 6, 0, "Pig and Whistle Tavern");
+ player->SEND_POI(-8611.0, 364.6, 7, 6, 0, "Pig and Whistle Tavern");
player->SEND_GOSSIP_MENU(921,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(-8858.0, 803.7, 6, 6, 0, "Lucan Cordell");
+ player->SEND_POI(-8858.0, 803.7, 7, 6, 0, "Lucan Cordell");
player->SEND_GOSSIP_MENU(941,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Engineering
- player->SEND_POI(-8347.0, 644.1, 6, 6, 0, "Lilliam Sparkspindle");
+ player->SEND_POI(-8347.0, 644.1, 7, 6, 0, "Lilliam Sparkspindle");
player->SEND_GOSSIP_MENU(922,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //First Aid
- player->SEND_POI(-8513.0, 801.8, 6, 6, 0, "Shaina Fuller");
+ player->SEND_POI(-8513.0, 801.8, 7, 6, 0, "Shaina Fuller");
player->SEND_GOSSIP_MENU(923,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Fishing
- player->SEND_POI(-8803.0, 767.5, 6, 6, 0, "Arnold Leland");
+ player->SEND_POI(-8803.0, 767.5, 7, 6, 0, "Arnold Leland");
player->SEND_GOSSIP_MENU(940,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Herbalism
- player->SEND_POI(-8967.0, 779.5, 6, 6, 0, "Alchemy Needs");
+ player->SEND_POI(-8967.0, 779.5, 7, 6, 0, "Alchemy Needs");
player->SEND_GOSSIP_MENU(924,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Leatherworking
- player->SEND_POI(-8726.0, 477.4, 6, 6, 0, "The Protective Hide");
+ player->SEND_POI(-8726.0, 477.4, 7, 6, 0, "The Protective Hide");
player->SEND_GOSSIP_MENU(925,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Mining
- player->SEND_POI(-8434.0, 692.8, 6, 6, 0, "Gelman Stonehand");
+ player->SEND_POI(-8434.0, 692.8, 7, 6, 0, "Gelman Stonehand");
player->SEND_GOSSIP_MENU(927,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Skinning
- player->SEND_POI(-8716.0, 469.4, 6, 6, 0, "The Protective Hide");
+ player->SEND_POI(-8716.0, 469.4, 7, 6, 0, "The Protective Hide");
player->SEND_GOSSIP_MENU(928,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 12: //Tailoring
- player->SEND_POI(-8938.0, 800.7, 6, 6, 0, "Duncan`s Textiles");
+ player->SEND_POI(-8938.0, 800.7, 7, 6, 0, "Duncan`s Textiles");
player->SEND_GOSSIP_MENU(929,_Creature->GetGUID());
break;
}
@@ -3431,11 +3431,11 @@ void SendDefaultMenu_guard_teldrassil(Player *player, Creature *_Creature, uint3
player->SEND_GOSSIP_MENU(4319,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Inn
- player->SEND_POI(9821.49, 960.13, 6, 6, 0, "Dolanaar Inn");
+ player->SEND_POI(9821.49, 960.13, 7, 6, 0, "Dolanaar Inn");
player->SEND_GOSSIP_MENU(4320,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //stable master
- player->SEND_POI(9808.37, 931.1, 6, 6, 0, "Seriadne");
+ player->SEND_POI(9808.37, 931.1, 7, 6, 0, "Seriadne");
player->SEND_GOSSIP_MENU(5982,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //class trainer
@@ -3466,23 +3466,23 @@ void SendClassTrainerMenu_guard_teldrassil(Player *player, Creature *_Creature,
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Druid
- player->SEND_POI(9741.58, 963.7, 6, 6, 0, "Kal");
+ player->SEND_POI(9741.58, 963.7, 7, 6, 0, "Kal");
player->SEND_GOSSIP_MENU(4323,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Hunter
- player->SEND_POI(9815.12, 926.28, 6, 6, 0, "Dazalar");
+ player->SEND_POI(9815.12, 926.28, 7, 6, 0, "Dazalar");
player->SEND_GOSSIP_MENU(4324,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Priest
- player->SEND_POI(9906.16, 986.63, 6, 6, 0, "Laurna Morninglight");
+ player->SEND_POI(9906.16, 986.63, 7, 6, 0, "Laurna Morninglight");
player->SEND_GOSSIP_MENU(4325,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Rogue
- player->SEND_POI(9789, 942.86, 6, 6, 0, "Jannok Breezesong");
+ player->SEND_POI(9789, 942.86, 7, 6, 0, "Jannok Breezesong");
player->SEND_GOSSIP_MENU(4326,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Warrior
- player->SEND_POI(9821.96, 950.61, 6, 6, 0, "Kyra Windblade");
+ player->SEND_POI(9821.96, 950.61, 7, 6, 0, "Kyra Windblade");
player->SEND_GOSSIP_MENU(4327,_Creature->GetGUID());
break;
}
@@ -3493,34 +3493,34 @@ void SendProfTrainerMenu_guard_teldrassil(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(9767.59, 878.81, 6, 6, 0, "Cyndra Kindwhisper");
+ player->SEND_POI(9767.59, 878.81, 7, 6, 0, "Cyndra Kindwhisper");
player->SEND_GOSSIP_MENU(4329,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Cooking
- player->SEND_POI(9751.19, 906.13, 6, 6, 0, "Zarrin");
+ player->SEND_POI(9751.19, 906.13, 7, 6, 0, "Zarrin");
player->SEND_GOSSIP_MENU(4330,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Enchanting
- player->SEND_POI(10677.59, 1946.56, 6, 6, 0, "Alanna Raveneye");
+ player->SEND_POI(10677.59, 1946.56, 7, 6, 0, "Alanna Raveneye");
player->SEND_GOSSIP_MENU(4331,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //First Aid
- player->SEND_POI(9903.12, 999, 6, 6, 0, "Byancie");
+ player->SEND_POI(9903.12, 999, 7, 6, 0, "Byancie");
player->SEND_GOSSIP_MENU(4332,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Fishing
player->SEND_GOSSIP_MENU(4333,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Herbalism
- player->SEND_POI(9773.78, 875.88, 6, 6, 0, "Malorne Bladeleaf");
+ player->SEND_POI(9773.78, 875.88, 7, 6, 0, "Malorne Bladeleaf");
player->SEND_GOSSIP_MENU(4334,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Leatherworking
- player->SEND_POI(10152.59, 1681.46, 6, 6, 0, "Nadyia Maneweaver");
+ player->SEND_POI(10152.59, 1681.46, 7, 6, 0, "Nadyia Maneweaver");
player->SEND_GOSSIP_MENU(4335,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Skinning
- player->SEND_POI(10135.59, 1673.18, 6, 6, 0, "Radnaal Maneweaver");
+ player->SEND_POI(10135.59, 1673.18, 7, 6, 0, "Radnaal Maneweaver");
player->SEND_GOSSIP_MENU(4336,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Tailoring
@@ -3576,11 +3576,11 @@ void SendDefaultMenu_guard_tirisfal(Player *player, Creature *_Creature, uint32
player->SEND_GOSSIP_MENU(4075,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Inn
- player->SEND_POI(2246.68, 241.89, 6, 6, 0, "Gallows` End Tavern");
+ player->SEND_POI(2246.68, 241.89, 7, 6, 0, "Gallows` End Tavern");
player->SEND_GOSSIP_MENU(4076,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Stable Master
- player->SEND_POI(2267.66, 319.32, 6, 6, 0, "Morganus");
+ player->SEND_POI(2267.66, 319.32, 7, 6, 0, "Morganus");
player->SEND_GOSSIP_MENU(5978,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Class trainer
@@ -3614,23 +3614,23 @@ void SendClassTrainerMenu_guard_tirisfal(Player *player, Creature *_Creature, ui
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Mage
- player->SEND_POI(2259.18, 240.93, 6, 6, 0, "Cain Firesong");
+ player->SEND_POI(2259.18, 240.93, 7, 6, 0, "Cain Firesong");
player->SEND_GOSSIP_MENU(4077,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Priest
- player->SEND_POI(2259.18, 240.93, 6, 6, 0, "Dark Cleric Beryl");
+ player->SEND_POI(2259.18, 240.93, 7, 6, 0, "Dark Cleric Beryl");
player->SEND_GOSSIP_MENU(4078,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Rogue
- player->SEND_POI(2259.18, 240.93, 6, 6, 0, "Marion Call");
+ player->SEND_POI(2259.18, 240.93, 7, 6, 0, "Marion Call");
player->SEND_GOSSIP_MENU(4079,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Warlock
- player->SEND_POI(2259.18, 240.93, 6, 6, 0, "Rupert Boch");
+ player->SEND_POI(2259.18, 240.93, 7, 6, 0, "Rupert Boch");
player->SEND_GOSSIP_MENU(4080,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Warrior
- player->SEND_POI(2256.48, 240.32, 6, 6, 0, "Austil de Mon");
+ player->SEND_POI(2256.48, 240.32, 7, 6, 0, "Austil de Mon");
player->SEND_GOSSIP_MENU(4081,_Creature->GetGUID());
break;
}
@@ -3641,7 +3641,7 @@ void SendProfTrainerMenu_guard_tirisfal(Player *player, Creature *_Creature, uin
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(2263.25, 344.23, 6, 6, 0, "Carolai Anise");
+ player->SEND_POI(2263.25, 344.23, 7, 6, 0, "Carolai Anise");
player->SEND_GOSSIP_MENU(4082,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
@@ -3651,37 +3651,37 @@ void SendProfTrainerMenu_guard_tirisfal(Player *player, Creature *_Creature, uin
player->SEND_GOSSIP_MENU(4084,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(2250.35, 249.12, 6, 6, 0, "Vance Undergloom");
+ player->SEND_POI(2250.35, 249.12, 7, 6, 0, "Vance Undergloom");
player->SEND_GOSSIP_MENU(4085,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Engineering
player->SEND_GOSSIP_MENU(4086,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //First Aid
- player->SEND_POI(2246.68, 241.89, 6, 6, 0, "Nurse Neela");
+ player->SEND_POI(2246.68, 241.89, 7, 6, 0, "Nurse Neela");
player->SEND_GOSSIP_MENU(4087,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Fishing
- player->SEND_POI(2292.37, -10.72, 6, 6, 0, "Clyde Kellen");
+ player->SEND_POI(2292.37, -10.72, 7, 6, 0, "Clyde Kellen");
player->SEND_GOSSIP_MENU(4088,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Herbalism
- player->SEND_POI(2268.21, 331.69, 6, 6, 0, "Faruza");
+ player->SEND_POI(2268.21, 331.69, 7, 6, 0, "Faruza");
player->SEND_GOSSIP_MENU(4089,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Leatherworking
- player->SEND_POI(2027, 78.72, 6, 6, 0, "Shelene Rhobart");
+ player->SEND_POI(2027, 78.72, 7, 6, 0, "Shelene Rhobart");
player->SEND_GOSSIP_MENU(4090,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Mining
player->SEND_GOSSIP_MENU(4091,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Skinning
- player->SEND_POI(2027, 78.72, 6, 6, 0, "Rand Rhobart");
+ player->SEND_POI(2027, 78.72, 7, 6, 0, "Rand Rhobart");
player->SEND_GOSSIP_MENU(4092,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 12: //Tailoring
- player->SEND_POI(2160.45, 659.93, 6, 6, 0, "Bowen Brisboise");
+ player->SEND_POI(2160.45, 659.93, 7, 6, 0, "Bowen Brisboise");
player->SEND_GOSSIP_MENU(4093,_Creature->GetGUID());
break;
}
@@ -3734,39 +3734,39 @@ void SendDefaultMenu_guard_undercity(Player *player, Creature *_Creature, uint32
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Bank
- player->SEND_POI(1595.64, 232.45, 6, 6, 0, "Undercity Bank");
+ player->SEND_POI(1595.64, 232.45, 7, 6, 0, "Undercity Bank");
player->SEND_GOSSIP_MENU(3514,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Bat handler
- player->SEND_POI(1565.9, 271.43, 6, 6, 0, "Undercity Bat Handler");
+ player->SEND_POI(1565.9, 271.43, 7, 6, 0, "Undercity Bat Handler");
player->SEND_GOSSIP_MENU(3515,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Guild master
- player->SEND_POI(1594.17, 205.57, 6, 6, 0, "Undercity Guild Master");
+ player->SEND_POI(1594.17, 205.57, 7, 6, 0, "Undercity Guild Master");
player->SEND_GOSSIP_MENU(3516,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Inn
- player->SEND_POI(1639.43, 220.99, 6, 6, 0, "Undercity Inn");
+ player->SEND_POI(1639.43, 220.99, 7, 6, 0, "Undercity Inn");
player->SEND_GOSSIP_MENU(3517,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Mailbox
- player->SEND_POI(1632.68, 219.4, 6, 6, 0, "Undercity Mailbox");
+ player->SEND_POI(1632.68, 219.4, 7, 6, 0, "Undercity Mailbox");
player->SEND_GOSSIP_MENU(3518,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //Auction House
- player->SEND_POI(1647.9, 258.49, 6, 6, 0, "Undercity Auction House");
+ player->SEND_POI(1647.9, 258.49, 7, 6, 0, "Undercity Auction House");
player->SEND_GOSSIP_MENU(3519,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Zeppelin
- player->SEND_POI(2059, 274.86, 6, 6, 0, "Undercity Zeppelin");
+ player->SEND_POI(2059, 274.86, 7, 6, 0, "Undercity Zeppelin");
player->SEND_GOSSIP_MENU(3520,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Weapon Master
- player->SEND_POI(1670.31, 324.66, 6, 6, 0, "Archibald");
+ player->SEND_POI(1670.31, 324.66, 7, 6, 0, "Archibald");
player->SEND_GOSSIP_MENU(4521,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Stable master
- player->SEND_POI(1634.18, 226.76, 6, 6, 0, "Anya Maulray");
+ player->SEND_POI(1634.18, 226.76, 7, 6, 0, "Anya Maulray");
player->SEND_GOSSIP_MENU(5979,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Battlemaster
@@ -3806,15 +3806,15 @@ void SendBattleMasterMenu_guard_undercity(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //AV
- player->SEND_POI(1329, 333.92, 6, 6, 0, "Grizzle Halfmane");
+ player->SEND_POI(1329, 333.92, 7, 6, 0, "Grizzle Halfmane");
player->SEND_GOSSIP_MENU(7525,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //AB
- player->SEND_POI(1283.3, 287.16, 6, 6, 0, "Sir Malory Wheeler");
+ player->SEND_POI(1283.3, 287.16, 7, 6, 0, "Sir Malory Wheeler");
player->SEND_GOSSIP_MENU(7646,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //WSG
- player->SEND_POI(1265, 351.18, 6, 6, 0, "Kurden Bloodclaw");
+ player->SEND_POI(1265, 351.18, 7, 6, 0, "Kurden Bloodclaw");
player->SEND_GOSSIP_MENU(7526,_Creature->GetGUID());
break;
}
@@ -3825,23 +3825,23 @@ void SendClassTrainerMenu_guard_undercity(Player *player, Creature *_Creature, u
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Mage
- player->SEND_POI(1781, 53, 6, 6, 0, "Undercity Mage Trainers");
+ player->SEND_POI(1781, 53, 7, 6, 0, "Undercity Mage Trainers");
player->SEND_GOSSIP_MENU(3513,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Priest
- player->SEND_POI(1758.33, 401.5, 6, 6, 0, "Undercity Priest Trainers");
+ player->SEND_POI(1758.33, 401.5, 7, 6, 0, "Undercity Priest Trainers");
player->SEND_GOSSIP_MENU(3521,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Rogue
- player->SEND_POI(1418.56, 65, 6, 6, 0, "Undercity Rogue Trainers");
+ player->SEND_POI(1418.56, 65, 7, 6, 0, "Undercity Rogue Trainers");
player->SEND_GOSSIP_MENU(3524,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Warlock
- player->SEND_POI(1780.92, 53.16, 6, 6, 0, "Undercity Warlock Trainers");
+ player->SEND_POI(1780.92, 53.16, 7, 6, 0, "Undercity Warlock Trainers");
player->SEND_GOSSIP_MENU(3526,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Warrior
- player->SEND_POI(1775.59, 418.19, 6, 6, 0, "Undercity Warrior Trainers");
+ player->SEND_POI(1775.59, 418.19, 7, 6, 0, "Undercity Warrior Trainers");
player->SEND_GOSSIP_MENU(3527,_Creature->GetGUID());
break;
}
@@ -3852,51 +3852,51 @@ void SendProfTrainerMenu_guard_undercity(Player *player, Creature *_Creature, ui
switch (action)
{
case GOSSIP_ACTION_INFO_DEF + 1: //Alchemy
- player->SEND_POI(1419.82, 417.19, 6, 6, 0, "The Apothecarium");
+ player->SEND_POI(1419.82, 417.19, 7, 6, 0, "The Apothecarium");
player->SEND_GOSSIP_MENU(3528,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 2: //Blacksmithing
- player->SEND_POI(1696, 285, 6, 6, 0, "Undercity Blacksmithing Trainer");
+ player->SEND_POI(1696, 285, 7, 6, 0, "Undercity Blacksmithing Trainer");
player->SEND_GOSSIP_MENU(3529,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 3: //Cooking
- player->SEND_POI(1596.34, 274.68, 6, 6, 0, "Undercity Cooking Trainer");
+ player->SEND_POI(1596.34, 274.68, 7, 6, 0, "Undercity Cooking Trainer");
player->SEND_GOSSIP_MENU(3530,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 4: //Enchanting
- player->SEND_POI(1488.54, 280.19, 6, 6, 0, "Undercity Enchanting Trainer");
+ player->SEND_POI(1488.54, 280.19, 7, 6, 0, "Undercity Enchanting Trainer");
player->SEND_GOSSIP_MENU(3531,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 5: //Engineering
- player->SEND_POI(1408.58, 143.43, 6, 6, 0, "Undercity Engineering Trainer");
+ player->SEND_POI(1408.58, 143.43, 7, 6, 0, "Undercity Engineering Trainer");
player->SEND_GOSSIP_MENU(3532,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 6: //First Aid
- player->SEND_POI(1519.65, 167.19, 6, 6, 0, "Undercity First Aid Trainer");
+ player->SEND_POI(1519.65, 167.19, 7, 6, 0, "Undercity First Aid Trainer");
player->SEND_GOSSIP_MENU(3533,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 7: //Fishing
- player->SEND_POI(1679.9, 89, 6, 6, 0, "Undercity Fishing Trainer");
+ player->SEND_POI(1679.9, 89, 7, 6, 0, "Undercity Fishing Trainer");
player->SEND_GOSSIP_MENU(3534,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 8: //Herbalism
- player->SEND_POI(1558, 349.36, 6, 6, 0, "Undercity Herbalism Trainer");
+ player->SEND_POI(1558, 349.36, 7, 6, 0, "Undercity Herbalism Trainer");
player->SEND_GOSSIP_MENU(3535,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 9: //Leatherworking
- player->SEND_POI(1498.76, 196.43, 6, 6, 0, "Undercity Leatherworking Trainer");
+ player->SEND_POI(1498.76, 196.43, 7, 6, 0, "Undercity Leatherworking Trainer");
player->SEND_GOSSIP_MENU(3536,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 10: //Mining
- player->SEND_POI(1642.88, 335.58, 6, 6, 0, "Undercity Mining Trainer");
+ player->SEND_POI(1642.88, 335.58, 7, 6, 0, "Undercity Mining Trainer");
player->SEND_GOSSIP_MENU(3537,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 11: //Skinning
- player->SEND_POI(1498.6, 196.46, 6, 6, 0, "Undercity Skinning Trainer");
+ player->SEND_POI(1498.6, 196.46, 7, 6, 0, "Undercity Skinning Trainer");
player->SEND_GOSSIP_MENU(3538,_Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF + 12: //Tailoring
- player->SEND_POI(1689.55, 193, 6, 6, 0, "Undercity Tailoring Trainer");
+ player->SEND_POI(1689.55, 193, 7, 6, 0, "Undercity Tailoring Trainer");
player->SEND_GOSSIP_MENU(3539,_Creature->GetGUID());
break;
}
@@ -4010,7 +4010,7 @@ void AddSC_guards()
newscript->Name="guard_orgrimmar";
newscript->pGossipHello = &GossipHello_guard_orgrimmar;
newscript->pGossipSelect = &GossipSelect_guard_orgrimmar;
- newscript->pReceiveEmote = &ReceiveEmote_guard_orgrimmar;
+ //newscript->pReceiveEmote = &ReceiveEmote_guard_orgrimmar;
newscript->GetAI = &GetAI_guard_orgrimmar;
newscript->RegisterSelf();
@@ -4046,7 +4046,7 @@ void AddSC_guards()
newscript->Name="guard_stormwind";
newscript->pGossipHello = &GossipHello_guard_stormwind;
newscript->pGossipSelect = &GossipSelect_guard_stormwind;
- newscript->pReceiveEmote = &ReceiveEmote_guard_stormwind;
+ //newscript->pReceiveEmote = &ReceiveEmote_guard_stormwind;
newscript->GetAI = &GetAI_guard_stormwind;
newscript->RegisterSelf();
diff --git a/src/bindings/scripts/scripts/item/item_scripts.cpp b/src/bindings/scripts/scripts/item/item_scripts.cpp
index a2e02069e15..0d09d7a67ed 100644
--- a/src/bindings/scripts/scripts/item/item_scripts.cpp
+++ b/src/bindings/scripts/scripts/item/item_scripts.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -223,7 +223,7 @@ bool ItemUse_item_flying_machine(Player *player, Item* _Item, SpellCastTargets c
bool ItemUse_item_gor_dreks_ointment(Player *player, Item* _Item, SpellCastTargets const& targets)
{
if( targets.getUnitTarget() && targets.getUnitTarget()->GetTypeId()==TYPEID_UNIT &&
- targets.getUnitTarget()->GetEntry() == 20748 && !targets.getUnitTarget()->HasAura(32578,0) )
+ targets.getUnitTarget()->GetEntry() == 20748 && !targets.getUnitTarget()->HasAura(32578) )
return false;
player->SendEquipError(EQUIP_ERR_CANT_DO_RIGHT_NOW,_Item,NULL);
diff --git a/src/bindings/scripts/scripts/npc/npc_escortAI.cpp b/src/bindings/scripts/scripts/npc/npc_escortAI.cpp
index 9699505f293..1b047c624cd 100644
--- a/src/bindings/scripts/scripts/npc/npc_escortAI.cpp
+++ b/src/bindings/scripts/scripts/npc/npc_escortAI.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
@@ -13,6 +13,7 @@ EndScriptData */
#include "npc_escortAI.h"
#define WP_LAST_POINT -1
+extern std::list<PointMovement> PointMovementList;
bool npc_escortAI::IsVisible(Unit* who) const
{
@@ -115,16 +116,23 @@ void npc_escortAI::UpdateAI(const uint32 diff)
//Correct movement speed
if (Run)
m_creature->RemoveUnitMovementFlag(MOVEMENTFLAG_WALK_MODE);
- else m_creature->AddUnitMovementFlag(MOVEMENTFLAG_WALK_MODE);
+ else
+ m_creature->AddUnitMovementFlag(MOVEMENTFLAG_WALK_MODE);
//Continue with waypoints
if( !IsOnHold )
{
- m_creature->GetMotionMaster()->MovePoint(CurrentWP->id, CurrentWP->x, CurrentWP->y, CurrentWP->z );
- debug_log("SD2: EscortAI Reconnect WP is: %u, %f, %f, %f", CurrentWP->id, CurrentWP->x, CurrentWP->y, CurrentWP->z);
- WaitTimer = 0;
- ReconnectWP = false;
- return;
+ if (CurrentWP != WaypointList.end())
+ {
+ m_creature->GetMotionMaster()->MovePoint(CurrentWP->id, CurrentWP->x, CurrentWP->y, CurrentWP->z );
+ debug_log("TSCR: EscortAI Reconnect WP is: %u, %f, %f, %f", CurrentWP->id, CurrentWP->x, CurrentWP->y, CurrentWP->z);
+
+ WaitTimer = 0;
+ ReconnectWP = false;
+ return;
+ }
+ else
+ debug_log("TSCR: EscortAI Reconnected to end of WP list");
}
}
@@ -271,6 +279,22 @@ void npc_escortAI::AddWaypoint(uint32 id, float x, float y, float z, uint32 Wait
WaypointList.push_back(t);
}
+void npc_escortAI::FillPointMovementListForCreature()
+{
+ UNORDERED_MAP<uint32, std::vector<PointMovement> >::iterator pPointsEntries = PointMovementMap.find(m_creature->GetEntry());
+
+ if (pPointsEntries != PointMovementMap.end())
+ {
+ std::vector<PointMovement>::iterator itr;
+
+ for (itr = pPointsEntries->second.begin(); itr != pPointsEntries->second.end(); ++itr)
+ {
+ Escort_Waypoint pPoint(itr->m_uiPointId,itr->m_fX,itr->m_fY,itr->m_fZ,itr->m_uiWaitTime);
+ WaypointList.push_back(pPoint);
+ }
+ }
+}
+
void npc_escortAI::Start(bool bAttack, bool bDefend, bool bRun, uint64 pGUID)
{
if (InCombat)
diff --git a/src/bindings/scripts/scripts/npc/npc_escortAI.h b/src/bindings/scripts/scripts/npc/npc_escortAI.h
index a2ec7fc50ed..503ff614171 100644
--- a/src/bindings/scripts/scripts/npc/npc_escortAI.h
+++ b/src/bindings/scripts/scripts/npc/npc_escortAI.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
@@ -7,6 +7,8 @@
#define DEFAULT_MAX_PLAYER_DISTANCE 50
+extern UNORDERED_MAP<uint32, std::vector<PointMovement> > PointMovementMap;
+
struct Escort_Waypoint
{
Escort_Waypoint(uint32 _id, float _x, float _y, float _z, uint32 _w)
@@ -58,6 +60,8 @@ struct TRINITY_DLL_DECL npc_escortAI : public ScriptedAI
// EscortAI functions
void AddWaypoint(uint32 id, float x, float y, float z, uint32 WaitTimeMs = 0);
+ void FillPointMovementListForCreature();
+
void Start(bool bAttack, bool bDefend, bool bRun, uint64 pGUID = 0);
void SetMaxPlayerDistance(float newMax) { MaxPlayerDistance = newMax; }
diff --git a/src/bindings/scripts/scripts/npc/npc_innkeeper.cpp b/src/bindings/scripts/scripts/npc/npc_innkeeper.cpp
index f96011266b9..ccd2b69f8bf 100644
--- a/src/bindings/scripts/scripts/npc/npc_innkeeper.cpp
+++ b/src/bindings/scripts/scripts/npc/npc_innkeeper.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -52,7 +52,7 @@ bool GossipHello_npc_innkeeper(Player *player, Creature *_Creature)
if (_Creature->isQuestGiver())
player->PrepareQuestMenu( _Creature->GetGUID() );
- if (isEventActive()&& !player->GetAura(SPELL_TRICK_OR_TREATED,0))
+ if (isEventActive()&& !player->GetAura(SPELL_TRICK_OR_TREATED, player->GetGUID()))
{
char* localizedEntry;
switch (player->GetSession()->GetSessionDbLocaleIndex())
@@ -83,7 +83,7 @@ bool GossipHello_npc_innkeeper(Player *player, Creature *_Creature)
bool GossipSelect_npc_innkeeper(Player *player, Creature *_Creature, uint32 sender, uint32 action )
{
- if (action == GOSSIP_ACTION_INFO_DEF+HALLOWEEN_EVENTID && isEventActive() && !player->GetAura(SPELL_TRICK_OR_TREATED,0))
+ if (action == GOSSIP_ACTION_INFO_DEF+HALLOWEEN_EVENTID && isEventActive() && !player->GetAura(SPELL_TRICK_OR_TREATED, player->GetGUID()))
{
player->CLOSE_GOSSIP_MENU();
player->CastSpell(player, SPELL_TRICK_OR_TREATED, true);
diff --git a/src/bindings/scripts/scripts/npc/npc_professions.cpp b/src/bindings/scripts/scripts/npc/npc_professions.cpp
index a13dc927603..e121e598528 100644
--- a/src/bindings/scripts/scripts/npc/npc_professions.cpp
+++ b/src/bindings/scripts/scripts/npc/npc_professions.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -634,8 +634,6 @@ void SendActionMenu_npc_prof_blacksmith(Player *player, Creature *_Creature, uin
{
//unknown textID (TALK_MUST_UNLEARN_WEAPON)
player->SEND_GOSSIP_MENU(_Creature->GetNpcTextId(), _Creature->GetGUID());
- //Temporary, not offilike
- _Creature->MonsterSay(TALK_MUST_UNLEARN_WEAPON,0,player->GetGUID());
}
else if( EquippedOk(player,S_UNLEARN_WEAPON) )
{
diff --git a/src/bindings/scripts/scripts/npc/npcs_special.cpp b/src/bindings/scripts/scripts/npc/npcs_special.cpp
index eae009edd24..8257fa60596 100644
--- a/src/bindings/scripts/scripts/npc/npcs_special.cpp
+++ b/src/bindings/scripts/scripts/npc/npcs_special.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -17,7 +17,7 @@
/* ScriptData
SDName: Npcs_Special
SD%Complete: 100
-SDComment: To be used for special NPCs that are located globally. Support for quest 3861 (Cluck!), 6622 and 6624 (Triage)
+SDComment: To be used for special NPCs that are located globally.
SDCategory: NPCs
EndScriptData
*/
@@ -26,8 +26,10 @@ EndScriptData
npc_chicken_cluck 100% support for quest 3861 (Cluck!)
npc_dancing_flames 100% midsummer event NPC
npc_guardian 100% guardianAI used to prevent players from accessing off-limits areas. Not in use by SD2
+npc_garments_of_quests 80% NPC's related to all Garments of-quests 5621, 5624, 5625, 5648, 565
npc_injured_patient 100% patients for triage-quests (6622 and 6624)
npc_doctor 100% Gustaf Vanhowzen and Gregory Victor, quest 6622 and 6624 (Triage)
+npc_kingdom_of_dalaran_quests Misc NPC's gossip option related to quests 12791, 12794 and 12796
npc_mount_vendor 100% Regular mount vendors all over the world. Display gossip if player doesn't meet the requirements to buy
npc_rogue_trainer 80% Scripted trainers, so they are able to offer item 17126 for class quest 6681
npc_sayge 100% Darkmoon event fortune teller, buff player based on answers given
@@ -40,10 +42,11 @@ EndContentData */
# npc_chicken_cluck
#########*/
+#define EMOTE_A_HELLO -1070004
+#define EMOTE_H_HELLO -1070005
+#define EMOTE_CLUCK_TEXT2 -1070006
+
#define QUEST_CLUCK 3861
-#define EMOTE_A_HELLO "looks up at you quizzically. Maybe you should inspect it?"
-#define EMOTE_H_HELLO "looks at you unexpectadly."
-#define CLUCK_TEXT2 "starts pecking at the feed."
#define FACTION_FRIENDLY 84
#define FACTION_CHICKEN 31
@@ -76,40 +79,37 @@ struct TRINITY_DLL_DECL npc_chicken_cluckAI : public ScriptedAI
if(UpdateVictim())
DoMeleeAttackIfReady();
}
-};
-
-CreatureAI* GetAI_npc_chicken_cluck(Creature *_Creature)
-{
- return new npc_chicken_cluckAI(_Creature);
-}
-bool ReceiveEmote_npc_chicken_cluck( Player *player, Creature *_Creature, uint32 emote )
-{
- if( emote == TEXTEMOTE_CHICKEN )
+ void ReceiveEmote( Player *player, uint32 emote )
{
- if( player->GetTeam() == ALLIANCE )
+ if( emote == TEXTEMOTE_CHICKEN )
{
- if( rand()%30 == 1 )
+ if( player->GetTeam() == ALLIANCE )
{
- if( player->GetQuestStatus(QUEST_CLUCK) == QUEST_STATUS_NONE )
+ if( rand()%30 == 1 )
{
- _Creature->SetFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_QUESTGIVER);
- _Creature->setFaction(FACTION_FRIENDLY);
- _Creature->MonsterTextEmote(EMOTE_A_HELLO, 0);
+ if( player->GetQuestStatus(QUEST_CLUCK) == QUEST_STATUS_NONE )
+ {
+ m_creature->SetFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_QUESTGIVER);
+ m_creature->setFaction(FACTION_FRIENDLY);
+ DoScriptText(EMOTE_A_HELLO, m_creature);
+ }
}
- }
- } else
- _Creature->MonsterTextEmote(EMOTE_H_HELLO,0);
- }
- if( emote == TEXTEMOTE_CHEER && player->GetTeam() == ALLIANCE )
- if( player->GetQuestStatus(QUEST_CLUCK) == QUEST_STATUS_COMPLETE )
- {
- _Creature->SetFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_QUESTGIVER);
- _Creature->setFaction(FACTION_FRIENDLY);
- _Creature->MonsterTextEmote(CLUCK_TEXT2, 0);
+ } else DoScriptText(EMOTE_H_HELLO,m_creature);
+ }
+ if( emote == TEXTEMOTE_CHEER && player->GetTeam() == ALLIANCE )
+ if( player->GetQuestStatus(QUEST_CLUCK) == QUEST_STATUS_COMPLETE )
+ {
+ m_creature->SetFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_QUESTGIVER);
+ m_creature->setFaction(FACTION_FRIENDLY);
+ DoScriptText(EMOTE_CLUCK_TEXT2, m_creature);
+ }
}
+};
- return true;
+CreatureAI* GetAI_npc_chicken_cluck(Creature *_Creature)
+{
+ return new npc_chicken_cluckAI(_Creature);
}
bool QuestAccept_npc_chicken_cluck(Player *player, Creature *_Creature, const Quest *_Quest )
@@ -172,114 +172,83 @@ struct TRINITY_DLL_DECL npc_dancing_flamesAI : public ScriptedAI
}
void Aggro(Unit* who){}
-};
-CreatureAI* GetAI_npc_dancing_flames(Creature *_Creature)
-{
- return new npc_dancing_flamesAI(_Creature);
-}
-
-bool ReceiveEmote_npc_dancing_flames( Player *player, Creature *flame, uint32 emote )
-{
- if ( ((npc_dancing_flamesAI*)flame->AI())->active &&
- flame->IsWithinLOS(player->GetPositionX(),player->GetPositionY(),player->GetPositionZ()) && flame->IsWithinDistInMap(player,30.0f))
+ void ReceiveEmote( Player *player, uint32 emote )
{
- flame->SetInFront(player);
- ((npc_dancing_flamesAI*)flame->AI())->active = false;
-
- WorldPacket data;
- flame->BuildHeartBeatMsg(&data);
- flame->SendMessageToSet(&data,true);
- switch(emote)
+ if (m_creature->IsWithinLOS(player->GetPositionX(),player->GetPositionY(),player->GetPositionZ()) && m_creature->IsWithinDistInMap(player,30.0f))
{
- case TEXTEMOTE_KISS: flame->HandleEmoteCommand(EMOTE_ONESHOT_SHY); break;
- case TEXTEMOTE_WAVE: flame->HandleEmoteCommand(EMOTE_ONESHOT_WAVE); break;
- case TEXTEMOTE_BOW: flame->HandleEmoteCommand(EMOTE_ONESHOT_BOW); break;
- case TEXTEMOTE_JOKE: flame->HandleEmoteCommand(EMOTE_ONESHOT_LAUGH); break;
- case TEXTEMOTE_DANCE:
+ m_creature->SetInFront(player);
+ active = false;
+
+ WorldPacket data;
+ m_creature->BuildHeartBeatMsg(&data);
+ m_creature->SendMessageToSet(&data,true);
+ switch(emote)
{
- if (!player->HasAura(SPELL_SEDUCTION,0))
- flame->CastSpell(player,SPELL_SEDUCTION,true);
+ case TEXTEMOTE_KISS: m_creature->HandleEmoteCommand(EMOTE_ONESHOT_SHY); break;
+ case TEXTEMOTE_WAVE: m_creature->HandleEmoteCommand(EMOTE_ONESHOT_WAVE); break;
+ case TEXTEMOTE_BOW: m_creature->HandleEmoteCommand(EMOTE_ONESHOT_BOW); break;
+ case TEXTEMOTE_JOKE: m_creature->HandleEmoteCommand(EMOTE_ONESHOT_LAUGH); break;
+ case TEXTEMOTE_DANCE:
+ {
+ if (!player->HasAura(SPELL_SEDUCTION))
+ m_creature->CastSpell(player,SPELL_SEDUCTION,true);
+ }
+ break;
}
- break;
}
}
- return true;
+};
+
+CreatureAI* GetAI_npc_dancing_flames(Creature *_Creature)
+{
+ return new npc_dancing_flamesAI(_Creature);
}
/*######
## Triage quest
######*/
-#define SAY_DOC1 "I'm saved! Thank you, doctor!"
-#define SAY_DOC2 "HOORAY! I AM SAVED!"
-#define SAY_DOC3 "Sweet, sweet embrace... take me..."
+#define SAY_DOC1 -1000201
+#define SAY_DOC2 -1000202
+#define SAY_DOC3 -1000203
+
+#define DOCTOR_ALLIANCE 12939
+#define DOCTOR_HORDE 12920
+#define ALLIANCE_COORDS 7
+#define HORDE_COORDS 6
struct Location
{
float x, y, z, o;
};
-#define DOCTOR_ALLIANCE 12939
-
static Location AllianceCoords[]=
{
- { // Top-far-right bunk as seen from entrance
- -3757.38, -4533.05, 14.16, 3.62
- },
- { // Top-far-left bunk
- -3754.36, -4539.13, 14.16, 5.13
- },
- { // Far-right bunk
- -3749.54, -4540.25, 14.28, 3.34
- },
- { // Right bunk near entrance
- -3742.10, -4536.85, 14.28, 3.64
- },
- { // Far-left bunk
- -3755.89, -4529.07, 14.05, 0.57
- },
- { // Mid-left bunk
- -3749.51, -4527.08, 14.07, 5.26
- },
- { // Left bunk near entrance
- -3746.37, -4525.35, 14.16, 5.22
- },
+ {-3757.38, -4533.05, 14.16, 3.62}, // Top-far-right bunk as seen from entrance
+ {-3754.36, -4539.13, 14.16, 5.13}, // Top-far-left bunk
+ {-3749.54, -4540.25, 14.28, 3.34}, // Far-right bunk
+ {-3742.10, -4536.85, 14.28, 3.64}, // Right bunk near entrance
+ {-3755.89, -4529.07, 14.05, 0.57}, // Far-left bunk
+ {-3749.51, -4527.08, 14.07, 5.26}, // Mid-left bunk
+ {-3746.37, -4525.35, 14.16, 5.22}, // Left bunk near entrance
};
-#define ALLIANCE_COORDS 7
-
//alliance run to where
#define A_RUNTOX -3742.96
#define A_RUNTOY -4531.52
#define A_RUNTOZ 11.91
-#define DOCTOR_HORDE 12920
-
static Location HordeCoords[]=
{
- { // Left, Behind
- -1013.75, -3492.59, 62.62, 4.34
- },
- { // Right, Behind
- -1017.72, -3490.92, 62.62, 4.34
- },
- { // Left, Mid
- -1015.77, -3497.15, 62.82, 4.34
- },
- { // Right, Mid
- -1019.51, -3495.49, 62.82, 4.34
- },
- { // Left, front
- -1017.25, -3500.85, 62.98, 4.34
- },
- { // Right, Front
- -1020.95, -3499.21, 62.98, 4.34
- }
+ {-1013.75, -3492.59, 62.62, 4.34}, // Left, Behind
+ {-1017.72, -3490.92, 62.62, 4.34}, // Right, Behind
+ {-1015.77, -3497.15, 62.82, 4.34}, // Left, Mid
+ {-1019.51, -3495.49, 62.82, 4.34}, // Right, Mid
+ {-1017.25, -3500.85, 62.98, 4.34}, // Left, front
+ {-1020.95, -3499.21, 62.98, 4.34} // Right, Front
};
-#define HORDE_COORDS 6
-
//horde run to where
#define H_RUNTOX -1016.44
#define H_RUNTOY -3508.48
@@ -305,6 +274,8 @@ const uint32 HordeSoldierId[3] =
struct TRINITY_DLL_DECL npc_doctorAI : public ScriptedAI
{
+ npc_doctorAI(Creature *c) : ScriptedAI(c) {}
+
uint64 Playerguid;
uint32 SummonPatient_Timer;
@@ -317,9 +288,17 @@ struct TRINITY_DLL_DECL npc_doctorAI : public ScriptedAI
std::list<uint64> Patients;
std::vector<Location*> Coordinates;
- npc_doctorAI(Creature *c) : ScriptedAI(c) {}
+ void Reset()
+ {
+ Playerguid = 0;
- void Reset(){}
+ SummonPatient_Timer = 10000;
+ SummonPatientCount = 0;
+ PatientDiedCount = 0;
+ PatientSavedCount = 0;
+
+ Event = false;
+ }
void BeginEvent(Player* player);
void PatientDied(Location* Point);
@@ -338,20 +317,21 @@ struct TRINITY_DLL_DECL npc_injured_patientAI : public ScriptedAI
npc_injured_patientAI(Creature *c) : ScriptedAI(c) {}
uint64 Doctorguid;
-
Location* Coord;
void Reset()
{
Doctorguid = 0;
-
Coord = NULL;
- //no select
+
+ //no select
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- //no regen health
+
+ //no regen health
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_IN_COMBAT);
- //to make them lay with face down
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, PLAYER_STATE_DEAD);
+
+ //to make them lay with face down
+ m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, UNIT_STAND_STATE_DEAD);
uint32 mobId = m_creature->GetEntry();
@@ -378,25 +358,34 @@ struct TRINITY_DLL_DECL npc_injured_patientAI : public ScriptedAI
{
if (caster->GetTypeId() == TYPEID_PLAYER && m_creature->isAlive() && spell->Id == 20804)
{
- if( (((Player*)caster)->GetQuestStatus(6624) == QUEST_STATUS_INCOMPLETE) || (((Player*)caster)->GetQuestStatus(6622) == QUEST_STATUS_INCOMPLETE))
+ if((((Player*)caster)->GetQuestStatus(6624) == QUEST_STATUS_INCOMPLETE) || (((Player*)caster)->GetQuestStatus(6622) == QUEST_STATUS_INCOMPLETE))
{
- if(Doctorguid)
+ if (Doctorguid)
{
- Creature* Doctor = (Unit::GetCreature((*m_creature), Doctorguid));
- if(Doctor)
+ if(Creature* Doctor = Unit::GetCreature(*m_creature, Doctorguid))
((npc_doctorAI*)Doctor->AI())->PatientSaved(m_creature, ((Player*)caster), Coord);
}
}
- //make not selectable
+
+ //make not selectable
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- //regen health
+
+ //regen health
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_IN_COMBAT);
- //stand up
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, PLAYER_STATE_NONE);
- DoSay(SAY_DOC1,LANG_UNIVERSAL,NULL);
+
+ //stand up
+ m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, UNIT_STAND_STATE_STAND);
+
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_DOC1,m_creature); break;
+ case 1: DoScriptText(SAY_DOC2,m_creature); break;
+ case 2: DoScriptText(SAY_DOC3,m_creature); break;
+ }
uint32 mobId = m_creature->GetEntry();
m_creature->RemoveUnitMovementFlag(MOVEMENTFLAG_WALK_MODE);
+
switch (mobId)
{
case 12923:
@@ -416,8 +405,9 @@ struct TRINITY_DLL_DECL npc_injured_patientAI : public ScriptedAI
void UpdateAI(const uint32 diff)
{
+ //lower HP on every world tick makes it a useful counter, not officlone though
if (m_creature->isAlive() && m_creature->GetHealth() > 6)
- { //lower HP on every world tick makes it a useful counter, not officlone though
+ {
m_creature->SetHealth(uint32(m_creature->GetHealth()-5) );
}
@@ -428,10 +418,9 @@ struct TRINITY_DLL_DECL npc_injured_patientAI : public ScriptedAI
m_creature->setDeathState(JUST_DIED);
m_creature->SetFlag(UNIT_DYNAMIC_FLAGS, 32);
- if(Doctorguid)
+ if (Doctorguid)
{
- Creature* Doctor = (Unit::GetCreature((*m_creature), Doctorguid));
- if(Doctor)
+ if(Creature* Doctor = Unit::GetCreature((*m_creature), Doctorguid))
((npc_doctorAI*)Doctor->AI())->PatientDied(Coord);
}
}
@@ -462,7 +451,6 @@ void npc_doctorAI::BeginEvent(Player* player)
for(uint8 i = 0; i < ALLIANCE_COORDS; ++i)
Coordinates.push_back(&AllianceCoords[i]);
break;
-
case DOCTOR_HORDE:
for(uint8 i = 0; i < HORDE_COORDS; ++i)
Coordinates.push_back(&HordeCoords[i]);
@@ -470,7 +458,6 @@ void npc_doctorAI::BeginEvent(Player* player)
}
Event = true;
-
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
}
@@ -489,6 +476,7 @@ void npc_doctorAI::PatientDied(Location* Point)
Event = false;
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ Reset();
}
Coordinates.push_back(Point);
@@ -497,31 +485,31 @@ void npc_doctorAI::PatientDied(Location* Point)
void npc_doctorAI::PatientSaved(Creature* soldier, Player* player, Location* Point)
{
- if(player && Playerguid == player->GetGUID())
+ if (player && Playerguid == player->GetGUID())
{
- if((player->GetQuestStatus(6624) == QUEST_STATUS_INCOMPLETE) || (player->GetQuestStatus(6622) == QUEST_STATUS_INCOMPLETE))
+ if ((player->GetQuestStatus(6624) == QUEST_STATUS_INCOMPLETE) || (player->GetQuestStatus(6622) == QUEST_STATUS_INCOMPLETE))
{
PatientSavedCount++;
- if(PatientSavedCount == 15)
+ if (PatientSavedCount == 15)
{
- if(!Patients.empty())
+ if (!Patients.empty())
{
std::list<uint64>::iterator itr;
for(itr = Patients.begin(); itr != Patients.end(); ++itr)
{
- Creature* Patient = (Unit::GetCreature((*m_creature), *itr));
- if( Patient )
+ if(Creature* Patient = Unit::GetCreature((*m_creature), *itr))
Patient->setDeathState(JUST_DIED);
}
}
- if(player->GetQuestStatus(6624) == QUEST_STATUS_INCOMPLETE)
+ if (player->GetQuestStatus(6624) == QUEST_STATUS_INCOMPLETE)
player->AreaExploredOrEventHappens(6624);
- else if(player->GetQuestStatus(6622) == QUEST_STATUS_INCOMPLETE)
+ else if (player->GetQuestStatus(6622) == QUEST_STATUS_INCOMPLETE)
player->AreaExploredOrEventHappens(6622);
Event = false;
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ Reset();
}
Coordinates.push_back(Point);
@@ -531,53 +519,61 @@ void npc_doctorAI::PatientSaved(Creature* soldier, Player* player, Location* Poi
void npc_doctorAI::UpdateAI(const uint32 diff)
{
- if(Event && SummonPatientCount >= 20)
+ if (Event && SummonPatientCount >= 20)
{
Event = false;
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ Reset();
}
- if(Event)
- if(SummonPatient_Timer < diff)
+ if (Event)
{
- Creature* Patient = NULL;
- Location* Point = NULL;
+ if (SummonPatient_Timer < diff)
+ {
+ Creature* Patient = NULL;
+ Location* Point = NULL;
- if(Coordinates.empty())
- return;
+ if (Coordinates.empty())
+ return;
- std::vector<Location*>::iterator itr = Coordinates.begin()+rand()%Coordinates.size();
- uint32 patientEntry = 0;
+ std::vector<Location*>::iterator itr = Coordinates.begin()+rand()%Coordinates.size();
+ uint32 patientEntry = 0;
- switch(m_creature->GetEntry())
- {
- case DOCTOR_ALLIANCE: patientEntry = AllianceSoldierId[rand()%3]; break;
- case DOCTOR_HORDE: patientEntry = HordeSoldierId[rand()%3]; break;
- default:
- error_log("SD2: Invalid entry for Triage doctor. Please check your database");
- return;
- }
+ switch(m_creature->GetEntry())
+ {
+ case DOCTOR_ALLIANCE: patientEntry = AllianceSoldierId[rand()%3]; break;
+ case DOCTOR_HORDE: patientEntry = HordeSoldierId[rand()%3]; break;
+ default:
+ error_log("SD2: Invalid entry for Triage doctor. Please check your database");
+ return;
+ }
- Point = *itr;
+ Point = *itr;
- Patient = m_creature->SummonCreature(patientEntry, Point->x, Point->y, Point->z, Point->o, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5000);
+ Patient = m_creature->SummonCreature(patientEntry, Point->x, Point->y, Point->z, Point->o, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5000);
- if(Patient)
- {
- Patients.push_back(Patient->GetGUID());
- ((npc_injured_patientAI*)Patient->AI())->Doctorguid = m_creature->GetGUID();
- if(Point)
- ((npc_injured_patientAI*)Patient->AI())->Coord = Point;
- Coordinates.erase(itr);
- }
- SummonPatient_Timer = 10000;
- SummonPatientCount++;
- }else SummonPatient_Timer -= diff;
+ if (Patient)
+ {
+ //303, this flag appear to be required for client side item->spell to work (TARGET_SINGLE_FRIEND)
+ Patient->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PVP_ATTACKABLE);
+
+ Patients.push_back(Patient->GetGUID());
+ ((npc_injured_patientAI*)Patient->AI())->Doctorguid = m_creature->GetGUID();
+
+ if (Point)
+ ((npc_injured_patientAI*)Patient->AI())->Coord = Point;
+
+ Coordinates.erase(itr);
+ }
+ SummonPatient_Timer = 10000;
+ SummonPatientCount++;
+ }else SummonPatient_Timer -= diff;
+ }
}
bool QuestAccept_npc_doctor(Player *player, Creature *creature, Quest const *quest )
{
- if((quest->GetQuestId() == 6624) || (quest->GetQuestId() == 6622))
+ if ((quest->GetQuestId() == 6624) || (quest->GetQuestId() == 6622))
((npc_doctorAI*)creature->AI())->BeginEvent(player);
return true;
@@ -589,11 +585,262 @@ CreatureAI* GetAI_npc_doctor(Creature *_Creature)
}
/*######
+## npc_garments_of_quests
+######*/
+
+//TODO: get text for each NPC
+
+enum
+{
+ SPELL_LESSER_HEAL_R2 = 2052,
+ SPELL_FORTITUDE_R1 = 1243,
+
+ QUEST_MOON = 5621,
+ QUEST_LIGHT_1 = 5624,
+ QUEST_LIGHT_2 = 5625,
+ QUEST_SPIRIT = 5648,
+ QUEST_DARKNESS = 5650,
+
+ ENTRY_SHAYA = 12429,
+ ENTRY_ROBERTS = 12423,
+ ENTRY_DOLF = 12427,
+ ENTRY_KORJA = 12430,
+ ENTRY_DG_KEL = 12428,
+
+ SAY_COMMON_HEALED = -1000164,
+ SAY_DG_KEL_THANKS = -1000165,
+ SAY_DG_KEL_GOODBYE = -1000166,
+ SAY_ROBERTS_THANKS = -1000167,
+ SAY_ROBERTS_GOODBYE = -1000168,
+ SAY_KORJA_THANKS = -1000169,
+ SAY_KORJA_GOODBYE = -1000170,
+ SAY_DOLF_THANKS = -1000171,
+ SAY_DOLF_GOODBYE = -1000172,
+ SAY_SHAYA_THANKS = -1000173,
+ SAY_SHAYA_GOODBYE = -1000174,
+};
+
+float fRunTo[5][3]=
+{
+ {9661.724, 869.803, 1270.742}, //shaya
+ {-9543.747, -117.770, 57.893}, //roberts
+ {-5650.226, -473.517, 397.027}, //dolf
+ {189.175, -4747.069, 11.215}, //kor'ja
+ {2471.303, 371.101, 30.919}, //kel
+};
+
+struct TRINITY_DLL_DECL npc_garments_of_questsAI : public ScriptedAI
+{
+ npc_garments_of_questsAI(Creature *c) : ScriptedAI(c) {Reset();}
+
+ uint64 caster;
+
+ bool bIsHealed;
+ bool bCanRun;
+
+ uint32 RunAwayTimer;
+
+ void Reset()
+ {
+ caster = 0;
+
+ bIsHealed = false;
+ bCanRun = false;
+
+ RunAwayTimer = 5000;
+
+ m_creature->SetStandState(UNIT_STAND_STATE_KNEEL);
+ //expect database to have RegenHealth=0
+ m_creature->SetHealth(int(m_creature->GetMaxHealth()*0.7));
+ m_creature->SetVisibility(VISIBILITY_ON);
+ }
+
+ void Aggro(Unit *who) {}
+
+ void SpellHit(Unit* pCaster, const SpellEntry *Spell)
+ {
+ if (Spell->Id == SPELL_LESSER_HEAL_R2 || Spell->Id == SPELL_FORTITUDE_R1)
+ {
+ //not while in combat
+ if (InCombat)
+ return;
+
+ //nothing to be done now
+ if (bIsHealed && bCanRun)
+ return;
+
+ if (pCaster->GetTypeId() == TYPEID_PLAYER)
+ {
+ switch(m_creature->GetEntry())
+ {
+ case ENTRY_SHAYA:
+ if (((Player*)pCaster)->GetQuestStatus(QUEST_MOON) == QUEST_STATUS_INCOMPLETE)
+ {
+ if (bIsHealed && !bCanRun && Spell->Id == SPELL_FORTITUDE_R1)
+ {
+ DoScriptText(SAY_SHAYA_THANKS,m_creature,pCaster);
+ bCanRun = true;
+ }
+ else if (!bIsHealed && Spell->Id == SPELL_LESSER_HEAL_R2)
+ {
+ caster = pCaster->GetGUID();
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
+ DoScriptText(SAY_COMMON_HEALED,m_creature,pCaster);
+ bIsHealed = true;
+ }
+ }
+ break;
+ case ENTRY_ROBERTS:
+ if (((Player*)pCaster)->GetQuestStatus(QUEST_LIGHT_1) == QUEST_STATUS_INCOMPLETE)
+ {
+ if (bIsHealed && !bCanRun && Spell->Id == SPELL_FORTITUDE_R1)
+ {
+ DoScriptText(SAY_ROBERTS_THANKS,m_creature,pCaster);
+ bCanRun = true;
+ }
+ else if (!bIsHealed && Spell->Id == SPELL_LESSER_HEAL_R2)
+ {
+ caster = pCaster->GetGUID();
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
+ DoScriptText(SAY_COMMON_HEALED,m_creature,pCaster);
+ bIsHealed = true;
+ }
+ }
+ break;
+ case ENTRY_DOLF:
+ if (((Player*)pCaster)->GetQuestStatus(QUEST_LIGHT_2) == QUEST_STATUS_INCOMPLETE)
+ {
+ if (bIsHealed && !bCanRun && Spell->Id == SPELL_FORTITUDE_R1)
+ {
+ DoScriptText(SAY_DOLF_THANKS,m_creature,pCaster);
+ bCanRun = true;
+ }
+ else if (!bIsHealed && Spell->Id == SPELL_LESSER_HEAL_R2)
+ {
+ caster = pCaster->GetGUID();
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
+ DoScriptText(SAY_COMMON_HEALED,m_creature,pCaster);
+ bIsHealed = true;
+ }
+ }
+ break;
+ case ENTRY_KORJA:
+ if (((Player*)pCaster)->GetQuestStatus(QUEST_SPIRIT) == QUEST_STATUS_INCOMPLETE)
+ {
+ if (bIsHealed && !bCanRun && Spell->Id == SPELL_FORTITUDE_R1)
+ {
+ DoScriptText(SAY_KORJA_THANKS,m_creature,pCaster);
+ bCanRun = true;
+ }
+ else if (!bIsHealed && Spell->Id == SPELL_LESSER_HEAL_R2)
+ {
+ caster = pCaster->GetGUID();
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
+ DoScriptText(SAY_COMMON_HEALED,m_creature,pCaster);
+ bIsHealed = true;
+ }
+ }
+ break;
+ case ENTRY_DG_KEL:
+ if (((Player*)pCaster)->GetQuestStatus(QUEST_DARKNESS) == QUEST_STATUS_INCOMPLETE)
+ {
+ if (bIsHealed && !bCanRun && Spell->Id == SPELL_FORTITUDE_R1)
+ {
+ DoScriptText(SAY_DG_KEL_THANKS,m_creature,pCaster);
+ bCanRun = true;
+ }
+ else if (!bIsHealed && Spell->Id == SPELL_LESSER_HEAL_R2)
+ {
+ caster = pCaster->GetGUID();
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
+ DoScriptText(SAY_COMMON_HEALED,m_creature,pCaster);
+ bIsHealed = true;
+ }
+ }
+ break;
+ }
+
+ //give quest credit, not expect any special quest objectives
+ if (bCanRun)
+ ((Player*)pCaster)->TalkedToCreature(m_creature->GetEntry(),m_creature->GetGUID());
+ }
+ }
+ }
+
+ void MovementInform(uint32 type, uint32 id)
+ {
+ if (type != POINT_MOTION_TYPE)
+ return;
+
+ //we reached destination, kill ourselves
+ if (id == 0)
+ {
+ m_creature->SetVisibility(VISIBILITY_OFF);
+ m_creature->setDeathState(JUST_DIED);
+ m_creature->SetHealth(0);
+ m_creature->CombatStop();
+ m_creature->DeleteThreatList();
+ m_creature->RemoveCorpse();
+ }
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ if (bCanRun && !InCombat)
+ {
+ if (RunAwayTimer <= diff)
+ {
+ if (Unit *pUnit = Unit::GetUnit(*m_creature,caster))
+ {
+ switch(m_creature->GetEntry())
+ {
+ case ENTRY_SHAYA:
+ DoScriptText(SAY_SHAYA_GOODBYE,m_creature,pUnit);
+ m_creature->GetMotionMaster()->MovePoint(0, fRunTo[0][0], fRunTo[0][1], fRunTo[0][2]);
+ break;
+ case ENTRY_ROBERTS:
+ DoScriptText(SAY_ROBERTS_GOODBYE,m_creature,pUnit);
+ m_creature->GetMotionMaster()->MovePoint(0, fRunTo[1][0], fRunTo[1][1], fRunTo[1][2]);
+ break;
+ case ENTRY_DOLF:
+ DoScriptText(SAY_DOLF_GOODBYE,m_creature,pUnit);
+ m_creature->GetMotionMaster()->MovePoint(0, fRunTo[2][0], fRunTo[2][1], fRunTo[2][2]);
+ break;
+ case ENTRY_KORJA:
+ DoScriptText(SAY_KORJA_GOODBYE,m_creature,pUnit);
+ m_creature->GetMotionMaster()->MovePoint(0, fRunTo[3][0], fRunTo[3][1], fRunTo[3][2]);
+ break;
+ case ENTRY_DG_KEL:
+ DoScriptText(SAY_DG_KEL_GOODBYE,m_creature,pUnit);
+ m_creature->GetMotionMaster()->MovePoint(0, fRunTo[4][0], fRunTo[4][1], fRunTo[4][2]);
+ break;
+ }
+ }
+ else
+ EnterEvadeMode(); //something went wrong
+
+ RunAwayTimer = 30000;
+ }else RunAwayTimer -= diff;
+ }
+
+ //Return since we have no target
+ if (!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+};
+
+CreatureAI* GetAI_npc_garments_of_quests(Creature* pCreature)
+{
+ return new npc_garments_of_questsAI(pCreature);
+}
+
+/*######
## npc_guardian
######*/
#define SPELL_DEATHTOUCH 5
-#define SAY_AGGRO "This area is closed!"
struct TRINITY_DLL_DECL npc_guardianAI : public ScriptedAI
{
@@ -606,7 +853,6 @@ struct TRINITY_DLL_DECL npc_guardianAI : public ScriptedAI
void Aggro(Unit *who)
{
- DoYell(SAY_AGGRO,LANG_UNIVERSAL,NULL);
}
void UpdateAI(const uint32 diff)
@@ -628,6 +874,44 @@ CreatureAI* GetAI_npc_guardian(Creature *_Creature)
}
/*######
+## npc_kingdom_of_dalaran_quests
+######*/
+
+enum
+{
+ SPELL_TELEPORT_DALARAN = 53360,
+ ITEM_KT_SIGNET = 39740,
+ QUEST_MAGICAL_KINGDOM_A = 12794,
+ QUEST_MAGICAL_KINGDOM_H = 12791,
+ QUEST_MAGICAL_KINGDOM_N = 12796
+};
+
+#define GOSSIP_ITEM_TELEPORT_TO "I am ready to be teleported to Dalaran."
+
+bool GossipHello_npc_kingdom_of_dalaran_quests(Player* pPlayer, Creature* pCreature)
+{
+ if (pCreature->isQuestGiver())
+ pPlayer->PrepareQuestMenu(pCreature->GetGUID());
+
+ if (pPlayer->HasItemCount(ITEM_KT_SIGNET,1) && (!pPlayer->GetQuestRewardStatus(QUEST_MAGICAL_KINGDOM_A) ||
+ !pPlayer->GetQuestRewardStatus(QUEST_MAGICAL_KINGDOM_H) || !pPlayer->GetQuestRewardStatus(QUEST_MAGICAL_KINGDOM_N)))
+ pPlayer->ADD_GOSSIP_ITEM(0, GOSSIP_ITEM_TELEPORT_TO, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
+
+ pPlayer->SEND_GOSSIP_MENU(pCreature->GetNpcTextId(), pCreature->GetGUID());
+ return true;
+}
+
+bool GossipSelect_npc_kingdom_of_dalaran_quests(Player* pPlayer, Creature* pCreature, uint32 uiSender, uint32 uiAction)
+{
+ if (uiAction == GOSSIP_ACTION_INFO_DEF+1)
+ {
+ pPlayer->CLOSE_GOSSIP_MENU();
+ pPlayer->CastSpell(pPlayer,SPELL_TELEPORT_DALARAN,false);
+ }
+ return true;
+}
+
+/*######
## npc_mount_vendor
######*/
@@ -964,7 +1248,7 @@ CreatureAI* GetAI_npc_tonk_mine(Creature *_Creature)
bool ReceiveEmote_npc_winter_reveler( Player *player, Creature *_Creature, uint32 emote )
{
//TODO: check auralist.
- if(player->HasAura(26218, 0))
+ if(player->HasAura(26218))
return false;
if( emote == TEXTEMOTE_KISS )
@@ -1136,7 +1420,6 @@ void AddSC_npcs_special()
newscript = new Script;
newscript->Name="npc_chicken_cluck";
newscript->GetAI = &GetAI_npc_chicken_cluck;
- newscript->pReceiveEmote = &ReceiveEmote_npc_chicken_cluck;
newscript->pQuestAccept = &QuestAccept_npc_chicken_cluck;
newscript->pQuestComplete = &QuestComplete_npc_chicken_cluck;
newscript->RegisterSelf();
@@ -1144,7 +1427,6 @@ void AddSC_npcs_special()
newscript = new Script;
newscript->Name="npc_dancing_flames";
newscript->GetAI = &GetAI_npc_dancing_flames;
- newscript->pReceiveEmote = &ReceiveEmote_npc_dancing_flames;
newscript->RegisterSelf();
newscript = new Script;
@@ -1159,11 +1441,22 @@ void AddSC_npcs_special()
newscript->RegisterSelf();
newscript = new Script;
+ newscript->Name = "npc_garments_of_quests";
+ newscript->GetAI = &GetAI_npc_garments_of_quests;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
newscript->Name="npc_guardian";
newscript->GetAI = &GetAI_npc_guardian;
newscript->RegisterSelf();
newscript = new Script;
+ newscript->Name="npc_kingdom_of_dalaran_quests";
+ newscript->pGossipHello = &GossipHello_npc_kingdom_of_dalaran_quests;
+ newscript->pGossipSelect = &GossipSelect_npc_kingdom_of_dalaran_quests;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
newscript->Name="npc_mount_vendor";
newscript->pGossipHello = &GossipHello_npc_mount_vendor;
newscript->pGossipSelect = &GossipSelect_npc_mount_vendor;
@@ -1193,12 +1486,12 @@ void AddSC_npcs_special()
newscript = new Script;
newscript->Name="npc_winter_reveler";
- newscript->pReceiveEmote = &ReceiveEmote_npc_winter_reveler;
+ //newscript->pReceiveEmote = &ReceiveEmote_npc_winter_reveler;
newscript->RegisterSelf();
newscript = new Script;
newscript->Name="npc_brewfest_reveler";
- newscript->pReceiveEmote = &ReceiveEmote_npc_brewfest_reveler;
+ //newscript->pReceiveEmote = &ReceiveEmote_npc_brewfest_reveler;
newscript->RegisterSelf();
newscript = new Script;
diff --git a/src/bindings/scripts/scripts/zone/alterac_mountains/alterac_mountains.cpp b/src/bindings/scripts/scripts/zone/alterac_mountains/alterac_mountains.cpp
index 72dda8dd835..13f8bdd3fbf 100644
--- a/src/bindings/scripts/scripts/zone/alterac_mountains/alterac_mountains.cpp
+++ b/src/bindings/scripts/scripts/zone/alterac_mountains/alterac_mountains.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/arathi_highlands/arathi_highlands.cpp b/src/bindings/scripts/scripts/zone/arathi_highlands/arathi_highlands.cpp
index d83cb9b3281..084e958a92a 100644
--- a/src/bindings/scripts/scripts/zone/arathi_highlands/arathi_highlands.cpp
+++ b/src/bindings/scripts/scripts/zone/arathi_highlands/arathi_highlands.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -127,27 +127,7 @@ CreatureAI* GetAI_npc_professor_phizzlethorpeAI(Creature *_Creature)
{
npc_professor_phizzlethorpeAI* professor_phizzlethorpeAI = new npc_professor_phizzlethorpeAI(_Creature);
- professor_phizzlethorpeAI->AddWaypoint(0, -2066.45, -2085.96, 9.08);
- professor_phizzlethorpeAI->AddWaypoint(1, -2077.99, -2105.33, 13.24);
- professor_phizzlethorpeAI->AddWaypoint(2, -2074.60, -2109.67, 14.24);
- professor_phizzlethorpeAI->AddWaypoint(3, -2076.60, -2117.46, 16.67);
- professor_phizzlethorpeAI->AddWaypoint(4, -2073.51, -2123.46, 18.42, 2000);
- professor_phizzlethorpeAI->AddWaypoint(5, -2073.51, -2123.46, 18.42, 4000);
- professor_phizzlethorpeAI->AddWaypoint(6, -2066.60, -2131.85, 21.56);
- professor_phizzlethorpeAI->AddWaypoint(7, -2053.85, -2143.19, 20.31);
- professor_phizzlethorpeAI->AddWaypoint(8, -2043.49, -2153.73, 20.20, 12000);
- professor_phizzlethorpeAI->AddWaypoint(9, -2043.49, -2153.73, 20.20, 14000);
- professor_phizzlethorpeAI->AddWaypoint(10, -2043.49, -2153.73, 20.20, 10000);
- professor_phizzlethorpeAI->AddWaypoint(11, -2043.49, -2153.73, 20.20, 2000);
- professor_phizzlethorpeAI->AddWaypoint(12, -2053.85, -2143.19, 20.31);
- professor_phizzlethorpeAI->AddWaypoint(13, -2066.60, -2131.85, 21.56);
- professor_phizzlethorpeAI->AddWaypoint(14, -2073.51, -2123.46, 18.42);
- professor_phizzlethorpeAI->AddWaypoint(15, -2076.60, -2117.46, 16.67);
- professor_phizzlethorpeAI->AddWaypoint(16, -2074.60, -2109.67, 14.24);
- professor_phizzlethorpeAI->AddWaypoint(17, -2077.99, -2105.33, 13.24);
- professor_phizzlethorpeAI->AddWaypoint(18, -2066.45, -2085.96, 9.08);
- professor_phizzlethorpeAI->AddWaypoint(19, -2066.41, -2086.21, 8.97, 6000);
- professor_phizzlethorpeAI->AddWaypoint(20, -2066.41, -2086.21, 8.97, 2000);
+ professor_phizzlethorpeAI->FillPointMovementListForCreature();
return (CreatureAI*)professor_phizzlethorpeAI;
}
diff --git a/src/bindings/scripts/scripts/zone/ashenvale_forest/ashenvale.cpp b/src/bindings/scripts/scripts/zone/ashenvale_forest/ashenvale.cpp
index 16de0d2a8c3..fb7b5c30545 100644
--- a/src/bindings/scripts/scripts/zone/ashenvale_forest/ashenvale.cpp
+++ b/src/bindings/scripts/scripts/zone/ashenvale_forest/ashenvale.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -108,6 +108,9 @@ struct TRINITY_DLL_DECL npc_torekAI : public npc_escortAI
void JustDied(Unit* killer)
{
+ if (killer->GetEntry() == m_creature->GetEntry())
+ return;
+
if (PlayerGUID && !Completed)
{
if (Player* player = Unit::GetPlayer(PlayerGUID))
@@ -149,34 +152,12 @@ bool QuestAccept_npc_torek(Player* player, Creature* creature, Quest const* ques
return true;
}
-CreatureAI* GetAI_npc_torek(Creature *_Creature)
+CreatureAI* GetAI_npc_torek(Creature* pCreature)
{
- npc_torekAI* thisAI = new npc_torekAI(_Creature);
-
- thisAI->AddWaypoint(0, 1782.63, -2241.11, 109.73, 5000);
- thisAI->AddWaypoint(1, 1788.88, -2240.17, 111.71);
- thisAI->AddWaypoint(2, 1797.49, -2238.11, 112.31);
- thisAI->AddWaypoint(3, 1803.83, -2232.77, 111.22);
- thisAI->AddWaypoint(4, 1806.65, -2217.83, 107.36);
- thisAI->AddWaypoint(5, 1811.81, -2208.01, 107.45);
- thisAI->AddWaypoint(6, 1820.85, -2190.82, 100.49);
- thisAI->AddWaypoint(7, 1829.60, -2177.49, 96.44);
- thisAI->AddWaypoint(8, 1837.98, -2164.19, 96.71); //prepare
- thisAI->AddWaypoint(9, 1839.99, -2149.29, 96.78);
- thisAI->AddWaypoint(10, 1835.14, -2134.98, 96.80);
- thisAI->AddWaypoint(11, 1823.57, -2118.27, 97.43);
- thisAI->AddWaypoint(12, 1814.99, -2110.35, 98.38);
- thisAI->AddWaypoint(13, 1806.60, -2103.09, 99.19);
- thisAI->AddWaypoint(14, 1798.27, -2095.77, 100.04);
- thisAI->AddWaypoint(15, 1783.59, -2079.92, 100.81);
- thisAI->AddWaypoint(16, 1776.79, -2069.48, 101.77);
- thisAI->AddWaypoint(17, 1776.82, -2054.59, 109.82);
- thisAI->AddWaypoint(18, 1776.88, -2047.56, 109.83);
- thisAI->AddWaypoint(19, 1776.86, -2036.55, 109.83);
- thisAI->AddWaypoint(20, 1776.90, -2024.56, 109.83); //win
- thisAI->AddWaypoint(21, 1776.87, -2028.31, 109.83,60000);//stay
- thisAI->AddWaypoint(22, 1776.90, -2028.30, 109.83);
+ npc_torekAI* thisAI = new npc_torekAI(pCreature);
+ thisAI->FillPointMovementListForCreature();
+
return (CreatureAI*)thisAI;
}
@@ -272,28 +253,7 @@ CreatureAI* GetAI_npc_ruul_snowhoofAI(Creature *_Creature)
{
npc_ruul_snowhoofAI* ruul_snowhoofAI = new npc_ruul_snowhoofAI(_Creature);
- ruul_snowhoofAI->AddWaypoint(0, 3347.250089, -694.700989, 159.925995);
- ruul_snowhoofAI->AddWaypoint(1, 3341.527039, -694.725891, 161.124542, 4000);
- ruul_snowhoofAI->AddWaypoint(2, 3338.351074, -686.088138, 163.444000);
- ruul_snowhoofAI->AddWaypoint(3, 3352.744873, -677.721741, 162.316269);
- ruul_snowhoofAI->AddWaypoint(4, 3370.291016, -669.366943, 160.751358);
- ruul_snowhoofAI->AddWaypoint(5, 3381.479492, -659.449097, 162.545303);
- ruul_snowhoofAI->AddWaypoint(6, 3389.554199, -648.500000, 163.651825);
- ruul_snowhoofAI->AddWaypoint(7, 3396.645020, -641.508911, 164.216019);
- ruul_snowhoofAI->AddWaypoint(8, 3410.498535, -634.299622, 165.773453);
- ruul_snowhoofAI->AddWaypoint(9, 3418.461426, -631.791992, 166.477615);
- ruul_snowhoofAI->AddWaypoint(10, 3429.500000, -631.588745, 166.921265);
- ruul_snowhoofAI->AddWaypoint(11,3434.950195, -629.245483, 168.333969);
- ruul_snowhoofAI->AddWaypoint(12,3438.927979, -618.503235, 171.503143);
- ruul_snowhoofAI->AddWaypoint(13,3444.217529, -609.293640, 173.077972, 1000); // Ambush 1
- ruul_snowhoofAI->AddWaypoint(14,3460.505127, -593.794189, 174.342255);
- ruul_snowhoofAI->AddWaypoint(15,3480.283203, -578.210327, 176.652313);
- ruul_snowhoofAI->AddWaypoint(16,3492.912842, -562.335449, 181.396301);
- ruul_snowhoofAI->AddWaypoint(17,3495.230957, -550.977600, 184.652267);
- ruul_snowhoofAI->AddWaypoint(18,3496.247070, -529.194214, 188.172028);
- ruul_snowhoofAI->AddWaypoint(19,3497.619385, -510.411499, 188.345322, 1000); // Ambush 2
- ruul_snowhoofAI->AddWaypoint(20,3498.498047, -497.787506, 185.806274);
- ruul_snowhoofAI->AddWaypoint(21,3484.218750, -489.717529, 182.389862, 4000); // End
+ ruul_snowhoofAI->FillPointMovementListForCreature();
return (CreatureAI*)ruul_snowhoofAI;
}
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/auchenai_crypts/boss_exarch_maladaar.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/auchenai_crypts/boss_exarch_maladaar.cpp
index e469dc6f618..986413cdf0f 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/auchenai_crypts/boss_exarch_maladaar.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/auchenai_crypts/boss_exarch_maladaar.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -299,7 +299,7 @@ CreatureAI* GetAI_boss_exarch_maladaar(Creature *_Creature)
}
#define SPELL_AV_MORTAL_STRIKE 16856
-#define SPELL_AV_MORTAL_STRIKE 16856
+#define SPELL_AV_SUNDER_ARMOR 16145
struct TRINITY_DLL_DECL mob_avatar_of_martyredAI : public ScriptedAI
{
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/auchenai_crypts/boss_shirrak_the_dead_watcher.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/auchenai_crypts/boss_shirrak_the_dead_watcher.cpp
index 86ae13e29c6..c7323267b2f 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/auchenai_crypts/boss_shirrak_the_dead_watcher.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/auchenai_crypts/boss_shirrak_the_dead_watcher.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/mana_tombs/boss_nexusprince_shaffar.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/mana_tombs/boss_nexusprince_shaffar.cpp
index 325b5aeb8dd..8e2d4cea736 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/mana_tombs/boss_nexusprince_shaffar.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/mana_tombs/boss_nexusprince_shaffar.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -201,7 +201,7 @@ CreatureAI* GetAI_boss_nexusprince_shaffar(Creature *_Creature)
struct TRINITY_DLL_DECL mob_ethereal_beaconAI : public ScriptedAI
{
- mob_ethereal_beaconAI(Creature *c) : ScriptedAI(c)
+ mob_ethereal_beaconAI(Creature *c) : ScriptedAI(c), CanEvade(false)
{
HeroicMode = m_creature->GetMap()->IsHeroic();
CanEvade = false;
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/mana_tombs/boss_pandemonius.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/mana_tombs/boss_pandemonius.cpp
index d366400b97d..d3ca37b445e 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/mana_tombs/boss_pandemonius.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/mana_tombs/boss_pandemonius.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/boss_darkweaver_syth.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/boss_darkweaver_syth.cpp
index dbf41ed777d..758596ca55d 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/boss_darkweaver_syth.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/boss_darkweaver_syth.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/boss_tailonking_ikiss.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/boss_tailonking_ikiss.cpp
index e1d1e98206e..94257e0aa37 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/boss_tailonking_ikiss.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/boss_tailonking_ikiss.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -147,7 +147,7 @@ struct TRINITY_DLL_DECL boss_talon_king_ikissAI : public ScriptedAI
if (ArcaneVolley_Timer < diff)
{
DoCast(m_creature,HeroicMode ? H_SPELL_ARCANE_VOLLEY : SPELL_ARCANE_VOLLEY);
- ArcaneVolley_Timer = 10000+rand()%5000;
+ ArcaneVolley_Timer = 7000+rand()%5000;
}else ArcaneVolley_Timer -= diff;
if (Sheep_Timer < diff)
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/def_sethekk_halls.h b/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/def_sethekk_halls.h
index 52ba2206c21..698571faecc 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/def_sethekk_halls.h
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/def_sethekk_halls.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/instance_sethekk_halls.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/instance_sethekk_halls.cpp
index e22ac68ff02..3d53f7b29e8 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/instance_sethekk_halls.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/sethekk_halls/instance_sethekk_halls.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_ambassador_hellmaw.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_ambassador_hellmaw.cpp
index 5a9b8e8b2a3..6c64a255370 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_ambassador_hellmaw.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_ambassador_hellmaw.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -38,7 +38,7 @@ EndScriptData */
#define SAY_DEATH -1555007
#define SPELL_BANISH 30231
-#define SPELL_CORROSIVE_ACID 23313
+#define SPELL_CORROSIVE_ACID 33551
#define SPELL_FEAR 33547
#define SPELL_ENRAGE 0 //need to find proper spell
@@ -80,7 +80,7 @@ struct TRINITY_DLL_DECL boss_ambassador_hellmawAI : public ScriptedAI
if (pInstance->GetData(TYPE_OVERSEER) == DONE)
{
- if (m_creature->HasAura(SPELL_BANISH,0))
+ if (m_creature->HasAura(SPELL_BANISH))
m_creature->RemoveAurasDueToSpell(SPELL_BANISH);
Intro = true;
}
@@ -89,7 +89,7 @@ struct TRINITY_DLL_DECL boss_ambassador_hellmawAI : public ScriptedAI
void MoveInLineOfSight(Unit *who)
{
- if (m_creature->HasAura(SPELL_BANISH,0))
+ if (m_creature->HasAura(SPELL_BANISH))
return;
ScriptedAI::MoveInLineOfSight(who);
@@ -105,7 +105,7 @@ struct TRINITY_DLL_DECL boss_ambassador_hellmawAI : public ScriptedAI
{
DoScriptText(SAY_INTRO, m_creature);
- if (m_creature->HasAura(SPELL_BANISH,0))
+ if (m_creature->HasAura(SPELL_BANISH))
m_creature->RemoveAurasDueToSpell(SPELL_BANISH);
IsBanished = false;
@@ -168,14 +168,14 @@ struct TRINITY_DLL_DECL boss_ambassador_hellmawAI : public ScriptedAI
if (CorrosiveAcid_Timer < diff)
{
- DoCast(m_creature,SPELL_CORROSIVE_ACID);
- CorrosiveAcid_Timer = 25000;
+ DoCast(m_creature->getVictim(),SPELL_CORROSIVE_ACID);
+ CorrosiveAcid_Timer = 15000 + rand()%10000;
}else CorrosiveAcid_Timer -= diff;
if (Fear_Timer < diff)
{
DoCast(m_creature,SPELL_FEAR);
- Fear_Timer = 35000;
+ Fear_Timer = 20000 + rand()%15000;
}else Fear_Timer -= diff;
/*if (HeroicMode)
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_blackheart_the_inciter.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_blackheart_the_inciter.cpp
index 43b01ba752f..5aa71a80825 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_blackheart_the_inciter.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_blackheart_the_inciter.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -148,14 +148,14 @@ struct TRINITY_DLL_DECL boss_blackheart_the_inciterAI : public ScriptedAI
{
if (Unit *target = SelectUnit(SELECT_TARGET_RANDOM, 0))
DoCast(target, SPELL_CHARGE);
- Charge_Timer = 25000;
+ Charge_Timer = 15000 + rand()%10000;
}else Charge_Timer -= diff;
//Knockback_Timer
if (Knockback_Timer < diff)
{
DoCast(m_creature, SPELL_WAR_STOMP);
- Knockback_Timer = 20000;
+ Knockback_Timer = 18000 + rand()%6000;
}else Knockback_Timer -= diff;
DoMeleeAttackIfReady();
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_grandmaster_vorpil.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_grandmaster_vorpil.cpp
index 32aa9c3e844..c58bae35137 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_grandmaster_vorpil.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_grandmaster_vorpil.cpp
@@ -60,12 +60,6 @@ float VoidPortalCoords[5][3] =
{-261.4533, -297.3298, 17.1}
};
-class EmpoweringShadowsAura: public Aura
-{
- public:
- EmpoweringShadowsAura(SpellEntry *spell, uint32 eff, int32 *bp, Unit *target, Unit *caster) : Aura(spell, eff, bp, target, caster, NULL) {}
-};
-
struct TRINITY_DLL_DECL mob_voidtravelerAI : public ScriptedAI
{
mob_voidtravelerAI(Creature *c) : ScriptedAI(c)
@@ -100,7 +94,7 @@ struct TRINITY_DLL_DECL mob_voidtravelerAI : public ScriptedAI
{
SpellEntry *spell = (SpellEntry *)GetSpellStore()->LookupEntry(HeroicMode?H_SPELL_EMPOWERING_SHADOWS:SPELL_EMPOWERING_SHADOWS);
if( spell )
- Vorpil->AddAura(new EmpoweringShadowsAura(spell, 0, NULL, Vorpil, m_creature));
+ Vorpil->AddAura(new Aura(spell, 1, NULL, Vorpil, m_creature));
Vorpil->SetHealth(Vorpil->GetHealth()+Vorpil->GetMaxHealth()/25);
DoCast(m_creature, SPELL_SHADOW_NOVA, true);
m_creature->DealDamage(m_creature, m_creature->GetMaxHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
@@ -150,7 +144,7 @@ struct TRINITY_DLL_DECL boss_grandmaster_vorpilAI : public ScriptedAI
void Reset()
{
- ShadowBoltVolley_Timer = 15000;
+ ShadowBoltVolley_Timer = 7000 + rand()%7000;
DrawShadows_Timer = 45000;
summonTraveler_Timer = 90000;
banish_Timer = 17000;
@@ -258,7 +252,7 @@ struct TRINITY_DLL_DECL boss_grandmaster_vorpilAI : public ScriptedAI
if (ShadowBoltVolley_Timer < diff)
{
DoCast(m_creature,SPELL_SHADOWBOLT_VOLLEY);
- ShadowBoltVolley_Timer = 15000;
+ ShadowBoltVolley_Timer = 15000 + rand()%15000;;
}else ShadowBoltVolley_Timer -= diff;
if (HeroicMode && banish_Timer < diff)
@@ -277,7 +271,7 @@ struct TRINITY_DLL_DECL boss_grandmaster_vorpilAI : public ScriptedAI
Map::PlayerList const &PlayerList = map->GetPlayers();
for(Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
if (Player* i_pl = i->getSource())
- if (i_pl->isAlive() && !i_pl->HasAura(SPELL_BANISH,0))
+ if (i_pl->isAlive() && !i_pl->HasAura(SPELL_BANISH))
i_pl->TeleportTo(m_creature->GetMapId(), VorpilPosition[0],VorpilPosition[1],VorpilPosition[2], 0, TELE_TO_NOT_LEAVE_COMBAT);
m_creature->Relocate(VorpilPosition[0],VorpilPosition[1],VorpilPosition[2]);
@@ -286,7 +280,7 @@ struct TRINITY_DLL_DECL boss_grandmaster_vorpilAI : public ScriptedAI
DoCast(m_creature,HeroicMode?H_SPELL_RAIN_OF_FIRE:SPELL_RAIN_OF_FIRE);
ShadowBoltVolley_Timer = 6000;
- DrawShadows_Timer = 30000;
+ DrawShadows_Timer = 3000;
}else DrawShadows_Timer -= diff;
if ( summonTraveler_Timer < diff)
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_murmur.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_murmur.cpp
index aae194de9b8..defaaa51a5d 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_murmur.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/boss_murmur.cpp
@@ -52,9 +52,9 @@ struct TRINITY_DLL_DECL boss_murmurAI : public Scripted_NoMovementAI
void Reset()
{
SonicBoom_Timer = 30000;
- MurmursTouch_Timer = 20000;
- Resonance_Timer = 10000;
- MagneticPull_Timer = 20000;
+ MurmursTouch_Timer = 8000 + rand()%12000;
+ Resonance_Timer = 5000;
+ MagneticPull_Timer = 15000 + rand()%15000;
ThunderingStorm_Timer = 15000;
SonicShock_Timer = 10000;
SonicBoom = false;
@@ -64,6 +64,24 @@ struct TRINITY_DLL_DECL boss_murmurAI : public Scripted_NoMovementAI
if (hp) m_creature->SetHealth(hp);
}
+ void SonicBoomEffect()
+ {
+ std::list<HostilReference *> t_list = m_creature->getThreatManager().getThreatList();
+ for( std::list<HostilReference *>::iterator itr = t_list.begin(); itr!= t_list.end(); ++itr )
+ {
+ Unit* target = Unit::GetUnit(*m_creature, (*itr)->getUnitGuid());
+ if (target && target->GetTypeId() == TYPEID_PLAYER)
+ {
+ //Not do anything without aura, spell can be resisted!
+ if (target->HasAura(SPELL_SONIC_BOOM_CAST) && m_creature->IsWithinDistInMap(target, 34.0f))
+ {
+ //This will be wrong calculation. Also, comments suggest it must deal damage
+ target->SetHealth(uint32(target->GetMaxHealth() - target->GetMaxHealth() * 0.8));
+ }
+ }
+ }
+ }
+
void Aggro(Unit *who) { }
// Sonic Boom instant damage (needs core fix instead of this)
@@ -83,12 +101,14 @@ struct TRINITY_DLL_DECL boss_murmurAI : public Scripted_NoMovementAI
if(SonicBoom)
{
DoCast(m_creature, SPELL_SONIC_BOOM_EFFECT, true);
+ SonicBoomEffect();
+
SonicBoom = false;
Resonance_Timer = 1500;
}
if (SonicBoom_Timer < diff)
{
- DoScriptText(EMOTE_SONIC_BOOM, m_creature);
+ DoScriptText(EMOTE_SONIC_BOOM, m_creature);
DoCast(m_creature, SPELL_SONIC_BOOM_CAST);
SonicBoom_Timer = 30000;
SonicBoom = true;
@@ -100,16 +120,18 @@ struct TRINITY_DLL_DECL boss_murmurAI : public Scripted_NoMovementAI
{
if(Unit* target = SelectUnit(SELECT_TARGET_RANDOM,0,80,true))
DoCast(target, SPELL_MURMURS_TOUCH);
- MurmursTouch_Timer = 30000;
+ MurmursTouch_Timer = 25000 + rand()%10000;
}else MurmursTouch_Timer -= diff;
// Resonance
- if (Resonance_Timer < diff)
+ if (!SonicBoom && !(m_creature->IsWithinMeleeRange(m_creature->getVictim())))
{
- if (!m_creature->IsWithinMeleeRange(SelectUnit(SELECT_TARGET_NEAREST,0,20,true)))
+ if (Resonance_Timer < diff)
+ {
DoCast(m_creature, SPELL_RESONANCE);
- Resonance_Timer = 5000;
- }else Resonance_Timer -= diff;
+ Resonance_Timer = 5000;
+ }else Resonance_Timer -= diff;
+ }
// Magnetic Pull
if (MagneticPull_Timer < diff)
@@ -118,7 +140,7 @@ struct TRINITY_DLL_DECL boss_murmurAI : public Scripted_NoMovementAI
if (target->GetTypeId() == TYPEID_PLAYER && target->isAlive())
{
DoCast(target, SPELL_MAGNETIC_PULL);
- MagneticPull_Timer = 20000+rand()%15000;
+ MagneticPull_Timer = 15000+rand()%15000;
return;
}
MagneticPull_Timer = 500;
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/def_shadow_labyrinth.h b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/def_shadow_labyrinth.h
index d03c9270181..a78955368bf 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/def_shadow_labyrinth.h
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/def_shadow_labyrinth.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/instance_shadow_labyrinth.cpp b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/instance_shadow_labyrinth.cpp
index a3966975f95..33a0ec3320f 100644
--- a/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/instance_shadow_labyrinth.cpp
+++ b/src/bindings/scripts/scripts/zone/aunchindoun/shadow_labyrinth/instance_shadow_labyrinth.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -80,7 +80,7 @@ struct TRINITY_DLL_DECL instance_shadow_labyrinth : public ScriptedInstance
void OnCreatureCreate(Creature *creature, uint32 creature_entry)
{
- switch(creature_entry)
+ switch(creature->GetEntry())
{
case 18732:
GrandmasterVorpil = creature->GetGUID();
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_amanitar.cpp b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_amanitar.cpp
new file mode 100644
index 00000000000..9431880921c
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_amanitar.cpp
@@ -0,0 +1,79 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* Script Data Start
+SDName: boss_amanitar
+SDAuthor: LordVanMartin
+SD%Complete: 0
+SDComment: Only appears in heroic mode
+SDCategory: Ahn'kahet
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_amanitar' where entry = '';
+*** SQL END ***/
+
+#include "precompiled.h"
+#include "def_ahnkahet.h"
+
+#define SPELL_BASH 57094
+#define SPELL_ENTANGLING_ROOTS 57095
+#define SPELL_MINI 57055
+#define SPELL_VENOM_BOLT_VOLLEY 57088
+
+struct TRINITY_DLL_DECL boss_amanitarAI : public ScriptedAI
+{
+ boss_amanitarAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+
+ void JustDied(Unit* killer) {}
+
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+ }
+};
+
+CreatureAI* GetAI_boss_amanitar(Creature *_Creature)
+{
+ return new boss_amanitarAI (_Creature);
+}
+
+void AddSC_boss_amanitar()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_amanitar";
+ newscript->GetAI = GetAI_boss_amanitar;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_elder_nadox.cpp b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_elder_nadox.cpp
new file mode 100644
index 00000000000..468aa8e10a7
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_elder_nadox.cpp
@@ -0,0 +1,117 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: boss_elder_nadox
+SDAuthor: LordVanMartin
+SD%Complete: 0
+SDComment:
+SDCategory: Ahn'kahet
+EndScriptData */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_nadox' where entry = '';
+*** SQL END ***/
+
+#include "precompiled.h"
+#include "def_ahnkahet.h"
+
+#define SPELL_BROOD_PLAGUE 56130
+#define H_SPELL_BROOD_PLAGUE 59467
+#define SPELL_BROOD_RAGE 59465 //--> Heroic -- Enrages a Swarmer, increasing size and damage done.
+
+#define MOB_AHNKAHAR_SWARMER 30178
+#define SPELL_SUMMON_SWARMERS 56119//2x 30178
+
+#define MOB_AHNKAHAR_SWARMER 30178
+#define SPELL_SUMMON_SWARM_GUARD 56120//1x 30176
+#define SPELL_DEADLY_POISON 56145// Proc trigger
+#define H_SPELL_DEADLY_POISON 59479// Proc trigger
+#define SPELL_GUARDIAN_AURA 56151
+
+//randomly summons NPC 30178 and 30176 they can cast Sprint (56354)
+
+//Yell
+#define SAY_AGGRO -1619014
+#define SAY_SLAY_1 -1619015
+#define SAY_SLAY_2 -1619016
+#define SAY_SLAY_3 -1619017
+#define SAY_DEATH -1619018
+#define SAY_EGG_SAC_1 -1619019
+#define SAY_EGG_SAC_2 -1619020
+
+struct TRINITY_DLL_DECL boss_nadoxAI : public ScriptedAI
+{
+ boss_nadoxAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 plague,
+ summon;
+
+ void Reset() {}
+
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+
+ void summon_swarmer(){}
+ void summon_guardian(){}
+};
+
+CreatureAI* GetAI_boss_nadox(Creature *_Creature)
+{
+ return new boss_nadoxAI (_Creature);
+}
+
+void AddSC_boss_nadox()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_nadox";
+ newscript->GetAI = GetAI_boss_nadox;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_herald_volazj.cpp b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_herald_volazj.cpp
new file mode 100644
index 00000000000..8e0b1a4744d
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_herald_volazj.cpp
@@ -0,0 +1,111 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: boss_herald_volazj
+SDAuthor: LordVanMartin
+SD%Complete: 0
+SDComment:
+SDCategory: Ahn'kahet
+EndScriptData */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_volazj' where entry = '';
+*** SQL END ***/
+
+#include "precompiled.h"
+#include "def_ahnkahet.h"
+
+//Spells
+#define SPELL_INSANITY 57496 //Dummy
+#define INSANITY_VISUAL 57561
+#define SPELL_MIND_FLAY_N 57941
+#define SPELL_MIND_FLAY_H 59974
+#define SPELL_SHADOW_BOLT_VOLLEY_1 57942
+#define SPELL_SHADOW_BOLT_VOLLEY_2 59975
+#define SPELL_SHIVER_N 57949
+#define SPELL_SHIVER_H 59978
+
+//Yell
+#define SAY_AGGRO -1619030
+#define SAY_SLAY_1 -1619031
+#define SAY_SLAY_2 -1619032
+#define SAY_SLAY_3 -1619033
+#define SAY_DEATH_1 -1619034
+#define SAY_DEATH_2 -1619035
+#define SAY_PHASE -1619036
+
+struct TRINITY_DLL_DECL boss_volazjAI : public ScriptedAI
+{
+ boss_volazjAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 phase;
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ phase =1;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ if(phase == 1)
+ DoScriptText(SAY_DEATH_1, m_creature);
+ else
+ DoScriptText(SAY_DEATH_2, m_creature);
+ }
+
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_volazj(Creature *_Creature)
+{
+ return new boss_volazjAI (_Creature);
+}
+
+void AddSC_boss_volazj()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_volazj";
+ newscript->GetAI = GetAI_boss_volazj;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_jedoga_shadowseeker.cpp b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_jedoga_shadowseeker.cpp
new file mode 100644
index 00000000000..145c017679e
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_jedoga_shadowseeker.cpp
@@ -0,0 +1,109 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: boss_jedoga_shadowseeker
+SDAuthor: LordVanMartin
+SD%Complete: 0
+SDComment:
+SDCategory: Ahn'kahet
+EndScriptData */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_jedoga' where entry = '';
+*** SQL END ***/
+
+#include "precompiled.h"
+#include "def_ahnkahet.h"
+
+#define SPELL_CYCLONE_STRIKE 56855
+#define H_SPELL_CYCLONE_STRIKE 60030//kein unterschied zu 56855 außer das 60030 1,5sec cast ist
+#define SPELL_LIGHTNING_BOLT 56891
+#define H_SPELL_LIGHTNING_BOLT 60032
+#define SPELL_THUNDERSHOCK 56926//AOE works
+#define H_SPELL_THUNDERSHOCK 60029//AOE works
+#define SPELL_GIFT_OF_THE_HERALD 56219//triggert if sucessfull sacreficed
+
+#define SAY_AGGRO -1619000
+#define SAY_C_SACRIFICE_1 -1619001
+#define SAY_C_SACRIFICE_2 -1619002
+#define SAY_SACRIFICE_1 -1619003
+#define SAY_SACRIFICE_2 -1619004
+#define SAY_SLAY_1 -1619005
+#define SAY_SLAY_2 -1619006
+#define SAY_SLAY_3 -1619007
+#define SAY_DEATH -1619008
+#define SAY_PREACHING_1 -1619009
+#define SAY_PREACHING_2 -1619010
+#define SAY_PREACHING_3 -1619011
+#define SAY_PREACHING_4 -1619012
+#define SAY_PREACHING_5 -1619013
+
+struct TRINITY_DLL_DECL boss_jedogaAI : public ScriptedAI
+{
+ boss_jedogaAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_jedoga(Creature *_Creature)
+{
+ return new boss_jedogaAI (_Creature);
+}
+
+void AddSC_boss_jedoga()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_jedoga";
+ newscript->GetAI = GetAI_boss_jedoga;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_prince_taldaram.cpp b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_prince_taldaram.cpp
new file mode 100644
index 00000000000..36e68862f0c
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/boss_prince_taldaram.cpp
@@ -0,0 +1,109 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: boss_prince_taldaram
+SDAuthor: LordVanMartin
+SD%Complete: 0
+SDComment:
+SDCategory: Ahn'kahet
+EndScriptData */
+
+#include "precompiled.h"
+#include "def_ahnkahet.h"
+
+#define SPELL_BLOODTHIRST 55968 //Trigger Spell + add aura
+#define SPELL_CONJURE_FLAME_SPHERE 55931
+
+#define SPELL_FLAME_SPHERE_SUMMON_1 55895// 1x 30106
+#define H_SPELL_FLAME_SPHERE_SUMMON_1 59511// 1x 31686
+#define H_SPELL_FLAME_SPHERE_SUMMON_2 59512// 1x 31687
+#define SPELL_FLAME_SPHERE_SPAWN_EFFEKT 55891
+#define SPELL_FLAME_SPHERE_VISUAL 55928
+#define SPELL_FLAME_SPHERE_PERIODIC 55926
+#define H_SPELL_FLAME_SPHERE_PERIODIC 59508
+#define SPELL_FLAME_SPHERE_DEATH_EFFEKT 55947
+
+#define SPELL_EMBRACE_OF_THE_VAMPYR 55959
+#define H_SPELL_EMBRACE_OF_THE_VAMPYR 59513
+
+#define SPELL_VANISH 55964
+
+//Yell
+#define SAY_AGGRO -1619021
+#define SAY_SLAY_1 -1619022
+#define SAY_SLAY_2 -1619023
+#define SAY_SLAY_3 -1619024
+#define SAY_DEATH -1619025
+#define SAY_FEED_1 -1619026
+#define SAY_FEED_2 -1619027
+#define SAY_VANISH_1 -1619028
+#define SAY_VANISH_2 -1619029
+
+struct TRINITY_DLL_DECL boss_taldaramAI : public ScriptedAI
+{
+ boss_taldaramAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_taldaram(Creature *_Creature)
+{
+ return new boss_taldaramAI (_Creature);
+}
+
+void AddSC_boss_taldaram()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_taldaram";
+ newscript->GetAI = GetAI_boss_taldaram;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/def_ahnkahet.h b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/def_ahnkahet.h
new file mode 100644
index 00000000000..97c0db55d72
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/def_ahnkahet.h
@@ -0,0 +1,33 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#ifndef DEF_AHNKAHET_H
+#define DEF_AHNKAHET_H
+
+#define DATA_ELDER_NADOX 1
+#define DATA_PRINCE_TALDARAM 2
+#define DATA_JEDOGA_SHADOWSEEKER 3
+#define DATA_HERALD_VOLAZJ 4
+#define DATA_AMANITAR 5
+
+#define DATA_ELDER_NADOX_EVENT 6
+#define DATA_PRINCE_TALDARAM_EVENT 7
+#define DATA_JEDOGA_SHADOWSEEKER_EVENT 8
+#define DATA_HERALD_VOLAZJ_EVENT 9
+#define DATA_AMANITAR_EVENT 10
+#endif
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/instance_ahnkahet.cpp b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/instance_ahnkahet.cpp
new file mode 100644
index 00000000000..41cb91f86b7
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/ahnkahet/instance_ahnkahet.cpp
@@ -0,0 +1,194 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Instance_Azjol_Nerub
+SD%Complete: 0
+SDComment:
+SDCategory: Azjol Nerub
+EndScriptData */
+
+#include "precompiled.h"
+#include "def_ahnkahet.h"
+
+#define ENCOUNTERS 5
+
+/* Ahn'kahet encounters:
+0 - Elder Nadox
+1 - Prince Taldaram
+2 - Jedoga Shadowseeker
+3 - Herald Volazj
+4 - Amanitar (Heroic only)
+*/
+
+struct TRINITY_DLL_DECL instance_ahnkahet : public ScriptedInstance
+{
+ instance_ahnkahet(Map *Map) : ScriptedInstance(Map) {Initialize();};
+
+ uint64 Elder_Nadox;
+ uint64 Prince_Taldaram;
+ uint64 Jedoga_Shadowseeker;
+ uint64 Herald_Volazj;
+ uint64 Amanitar;
+
+ uint32 Encounters[ENCOUNTERS];
+
+ void Initialize()
+ {
+ Elder_Nadox =0;
+ Prince_Taldaram =0;
+ Jedoga_Shadowseeker =0;
+ Herald_Volazj =0;
+ Amanitar =0;
+
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ Encounters[i] = NOT_STARTED;
+ }
+
+ bool IsEncounterInProgress() const
+ {
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ if(Encounters[i] == IN_PROGRESS) return true;
+
+ return false;
+ }
+
+
+ void OnCreatureCreate(Creature *creature, uint32 creature_entry)
+ {
+ switch(creature_entry)
+ {
+ case 29309: Elder_Nadox = creature->GetGUID(); break;
+ case 29308: Prince_Taldaram = creature->GetGUID(); break;
+ case 29310: Jedoga_Shadowseeker = creature->GetGUID(); break;
+ case 29311: Herald_Volazj = creature->GetGUID(); break;
+ case 30258: Amanitar = creature->GetGUID(); break;
+ }
+ }
+
+ uint64 GetData64(uint32 identifier)
+ {
+ switch(identifier)
+ {
+ case DATA_ELDER_NADOX: return Elder_Nadox;
+ case DATA_PRINCE_TALDARAM: return Prince_Taldaram;
+ case DATA_JEDOGA_SHADOWSEEKER: return Jedoga_Shadowseeker;
+ case DATA_HERALD_VOLAZJ: return Herald_Volazj;
+ case DATA_AMANITAR: return Amanitar;
+ }
+ return 0;
+ }
+
+ void SetData(uint32 type, uint32 data)
+ {
+ switch(type)
+ {
+ case DATA_ELDER_NADOX_EVENT:
+ Encounters[0] = data;break;
+ case DATA_PRINCE_TALDARAM_EVENT:
+ Encounters[1] = data; break;
+ case DATA_JEDOGA_SHADOWSEEKER_EVENT:
+ Encounters[2] = data; break;
+ case DATA_HERALD_VOLAZJ:
+ Encounters[3] = data; break;
+ case DATA_AMANITAR:
+ Encounters[4] = data; break;
+ }
+
+ if (data == DONE)
+ {
+ SaveToDB();
+ }
+ }
+
+ uint32 GetData(uint32 type)
+ {
+ switch(type)
+ {
+ case DATA_ELDER_NADOX_EVENT: return Encounters[0];
+ case DATA_PRINCE_TALDARAM_EVENT: return Encounters[1];
+ case DATA_JEDOGA_SHADOWSEEKER_EVENT: return Encounters[2];
+ case DATA_HERALD_VOLAZJ: return Encounters[3];
+ case DATA_AMANITAR: return Encounters[4];
+ }
+ return 0;
+ }
+
+ const char* Save()
+ {
+ OUT_SAVE_INST_DATA;
+
+ std::string str_data;
+
+ std::ostringstream saveStream;
+ saveStream << "A K " << Encounters[0] << " " << Encounters[1] << " "
+ << Encounters[2] << Encounters[3] << Encounters[4];
+
+ str_data = saveStream.str();
+
+ OUT_SAVE_INST_DATA_COMPLETE;
+ return str_data.c_str();
+ }
+
+ void Load(const char* in)
+ {
+ if (!in)
+ {
+ OUT_LOAD_INST_DATA_FAIL;
+ return;
+ }
+
+ OUT_LOAD_INST_DATA(in);
+
+ char dataHead1, dataHead2;
+ uint16 data0,data1,data2,data3,data4;
+
+ std::istringstream loadStream(in);
+ loadStream >> dataHead1 >> dataHead2 >> data0 >> data1 >> data2 >> data3 >> data4;
+
+ if( dataHead1 == 'A' && dataHead2 == 'K')
+ {
+ Encounters[0] = data0;
+ Encounters[1] = data1;
+ Encounters[2] = data2;
+ Encounters[3] = data3;
+ Encounters[4] = data4;
+
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ if (Encounters[i] == IN_PROGRESS)
+ Encounters[i] = NOT_STARTED;
+
+ }else OUT_LOAD_INST_DATA_FAIL;
+
+ OUT_LOAD_INST_DATA_COMPLETE;
+ }
+};
+
+InstanceData* GetInstanceData_instance_ahnkahet(Map* map)
+{
+ return new instance_ahnkahet(map);
+}
+
+void AddSC_instance_ahnkahet()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_ahnkahet";
+ newscript->GetInstanceData = &GetInstanceData_instance_ahnkahet;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_anubarak.cpp b/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_anubarak.cpp
new file mode 100644
index 00000000000..c479e17d162
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_anubarak.cpp
@@ -0,0 +1,112 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: boss_anubarak
+SDAuthor: LordVanMartin
+SD%Complete: 0
+SDComment:
+SDCategory: Azjol Nerub
+EndScriptData */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_anub_arak' where entry = '';
+*** SQL END ***/
+
+#include "precompiled.h"
+#include "def_azjol_nerub.h"
+
+//Spells
+#define SPELL_CARRION_BEETLES 53520
+#define SPELL_LOCUST_SWARM 53467
+#define SPELL_IMPALE 53454
+#define SPELL_POUND 53472
+
+//Yell
+#define SAY_INTRO -1601010
+#define SAY_AGGRO -1601000
+#define SAY_SLAY_1 -1601001
+#define SAY_SLAY_2 -1601002
+#define SAY_SLAY_3 -1601003
+#define SAY_LOCUST_1 -1601005
+#define SAY_LOCUST_2 -1601006
+#define SAY_LOCUST_3 -1601007
+#define SAY_SUBMERGE_1 -1601008
+#define SAY_SUBMERGE_2 -1601009
+#define SAY_DEATH -1601004
+
+struct TRINITY_DLL_DECL boss_anub_arakAI : public ScriptedAI
+{
+ boss_anub_arakAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 phase;
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ phase =1;
+
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) <= 33)
+ phase = 2;
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) == 15)
+ phase = 3;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_anub_arak(Creature *_Creature)
+{
+ return new boss_anub_arakAI (_Creature);
+}
+
+void AddSC_boss_anub_arak()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_anub_arak";
+ newscript->GetAI = GetAI_boss_anub_arak;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_hadronox.cpp b/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_hadronox.cpp
new file mode 100644
index 00000000000..e72ccd6436f
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_hadronox.cpp
@@ -0,0 +1,114 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: boss_hadronox
+SD%Complete: 0
+SDComment: Placeholder
+SDCategory: Azjol Nerub
+EndScriptData */
+
+#include "precompiled.h"
+#include "def_azjol_nerub.h"
+
+#define SPELL_WEB_FRONT_DOORS 53177//dummy
+
+#define SPELL_ACID_CLOUD 53400
+#define H_SPELL_ACID_CLOUD 59419
+#define SPELL_LEECH_POISON 53030
+#define H_SPELL_LEECH_POISON 59417
+#define SPELL_LEECH_POISON_DEADTRIGGER 53800//heal 10% heroic und normal
+#define SPELL_PIECE_ARMOR 53418
+#define SPELL_WEB_GRAB 53406
+#define H_SPELL_WEB_GRAB 59420
+
+/* Script Data Start
+SDName: Boss hadronox
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_hadronox' where entry = '';
+*** SQL END ***/
+
+//Spells
+#define SPELL_LEECH_POISON 53030
+#define SPELL_ACID_CLOUD 53400
+#define SPELL_PIERCE_ARMOR 53418 //Source SUN++
+#define SPELL_WEB_GRAB 53406
+
+//Phase 0 => Gauntlet Event described below
+//Phase 1 => Boss Encounter
+
+/*When your group enters the main room (the one after the bridge), you will notice a group of 3 Nerubians.
+When you engage them, 2 more groups like this one spawn behind the first one - it is important to pull the first group back,
+so you don't aggro all 3. Hadronox will be under you, fighting Nerubians.
+
+This is the timed gauntlet - waves of non-elite spiders
+ will spawn from the 3 doors located a little above the main room, and will then head down to fight Hadronox. After clearing the
+ main room, it is recommended to just stay in it, kill the occasional non-elites that will attack you instead of the boss, and wait for
+ Hadronox to make his way to you. When Hadronox enters the main room, she will web the doors, and no more non-elites will spawn.*/
+
+struct TRINITY_DLL_DECL boss_hadronoxAI : public ScriptedAI
+{
+ boss_hadronoxAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 phase;
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ phase =1;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ //when Hadronox kills any enemy (that includes a party member) she will regain 10% of her HP if the target had Leech Poison on
+ }
+};
+
+CreatureAI* GetAI_boss_hadronox(Creature *_Creature)
+{
+ return new boss_hadronoxAI (_Creature);
+}
+
+void AddSC_boss_hadronox()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_hadronox";
+ newscript->GetAI = GetAI_boss_hadronox;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_krikthir_the_gatewatcher.cpp b/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_krikthir_the_gatewatcher.cpp
new file mode 100644
index 00000000000..43ae13d0b9d
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/boss_krikthir_the_gatewatcher.cpp
@@ -0,0 +1,116 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: boss_krikthir_the_gatewatcher
+SDAuthor: LordVanMartin
+SD%Complete: 0
+SDComment: Placeholder
+SDCategory: Azjol Nerub
+EndScriptData */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_krik_thir' where entry = '';
+*** SQL END ***/
+
+#include "precompiled.h"
+#include "def_azjol_nerub.h"
+
+#define SPELL_MIND_FLAY 52586
+#define H_SPELL_MIND_FLAY 59367
+#define SPELL_CURSE_OF_FATIGUE 52592
+#define H_SPELL_CURSE_OF_FATIGUE 59368
+#define SPELL_FRENZY 28747 // maybe 53361
+
+#define MOB_SKITTERING_SWARMER 28735
+#define MOB_SKITTERING_SWARMER_CONTROLLER 32593
+
+#define SPELL_SUMMON_SKITTERING_SWARMER 52438//AOE Effekt 140, maybe 52439
+#define SPELL_SUMMON_SKITTERING_SWARMER 52439//Summon 3x 28735
+
+//Yell
+#define SAY_AGGRO -1601011
+#define SAY_SLAY_1 -1601012
+#define SAY_SLAY_2 -1601013
+#define SAY_SLAY_3 -1601014
+#define SAY_DEATH -1601015
+#define SAY_SEND_GROUP_1 -1601018
+#define SAY_SEND_GROUP_2 -1601019
+#define SAY_SEND_GROUP_3 -1601020
+#define SAY_SWARM_1 -1601016
+#define SAY_SWARM_2 -1601017
+#define SAY_PREFIGHT_1 -1601021
+#define SAY_PREFIGHT_2 -1601022
+#define SAY_PREFIGHT_3 -1601023
+
+struct TRINITY_DLL_DECL boss_krik_thirAI : public ScriptedAI
+{
+ boss_krik_thirAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ if(!UpdateVictim())
+ return;
+
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) >= 10)
+ {
+ //Frenzy
+ }
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_krik_thir(Creature *_Creature)
+{
+ return new boss_krik_thirAI (_Creature);
+}
+
+void AddSC_boss_krik_thir()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_krik_thir";
+ newscript->GetAI = GetAI_boss_krik_thir;
+ newscript->RegisterSelf();
+
+}
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/def_azjol_nerub.h b/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/def_azjol_nerub.h
new file mode 100644
index 00000000000..9e319e8fde0
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/def_azjol_nerub.h
@@ -0,0 +1,29 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#ifndef DEF_AZJOL_NERUB_H
+#define DEF_AZJOL_NERUB_H
+
+#define DATA_KRIKTHIR_THE_GATEWATCHER 1
+#define DATA_HADRONOX 2
+#define DATA_ANUBARAK 3
+
+#define DATA_KRIKTHIR_THE_GATEWATCHER_EVENT 4
+#define DATA_HADRONOX_EVENT 5
+#define DATA_ANUBARAK_EVENT 6
+#endif
diff --git a/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/instance_azjol_nerub.cpp b/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/instance_azjol_nerub.cpp
new file mode 100644
index 00000000000..bd3fccd98d9
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/azjol_nerub/azjol_nerub/instance_azjol_nerub.cpp
@@ -0,0 +1,180 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Instance_Azjol_Nerub
+SD%Complete: 0
+SDComment: Placeholder
+SDCategory: Azjol Nerub
+EndScriptData */
+
+#include "precompiled.h"
+#include "def_azjol_nerub.h"
+
+#define ENCOUNTERS 3
+
+/* Azjol Nerub encounters:
+0 - Krik'thir the Gatewatcher
+1 - Hadronox
+2 - Anub'arak
+*/
+
+struct TRINITY_DLL_DECL instance_azjol_nerub : public ScriptedInstance
+{
+ instance_azjol_nerub(Map *Map) : ScriptedInstance(Map) {Initialize();};
+
+ uint64 Krikthir;
+ uint64 Hadronox;
+ uint64 Anubarak;
+
+ uint32 Encounters[ENCOUNTERS];
+
+ void Initialize()
+ {
+ Krikthir = 0;
+ Hadronox = 0;
+ Anubarak =0;
+
+
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ Encounters[i] = NOT_STARTED;
+ }
+
+ bool IsEncounterInProgress() const
+ {
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ if(Encounters[i] == IN_PROGRESS) return true;
+
+ return false;
+ }
+
+
+ void OnCreatureCreate(Creature *creature, uint32 creature_entry)
+ {
+ switch(creature_entry)
+ {
+ case 28684: Krikthir = creature->GetGUID(); break;
+ case 28921: Hadronox = creature->GetGUID(); break;
+ case 29120: Anubarak = creature->GetGUID(); break;
+
+ }
+ }
+
+ uint64 GetData64(uint32 identifier)
+ {
+ switch(identifier)
+ {
+ case DATA_KRIKTHIR_THE_GATEWATCHER: return Krikthir;
+ case DATA_HADRONOX: return Hadronox;
+ case DATA_ANUBARAK: return Anubarak;
+ }
+
+ return 0;
+ }
+
+ void SetData(uint32 type, uint32 data)
+ {
+ switch(type)
+ {
+ case DATA_KRIKTHIR_THE_GATEWATCHER_EVENT:
+ Encounters[0] = data;break;
+ case DATA_HADRONOX_EVENT:
+ Encounters[1] = data; break;
+ case DATA_ANUBARAK_EVENT:
+ Encounters[2] = data; break;
+ }
+
+ if (data == DONE)
+ {
+ SaveToDB();
+ }
+ }
+
+ uint32 GetData(uint32 type)
+ {
+ switch(type)
+ {
+ case DATA_KRIKTHIR_THE_GATEWATCHER_EVENT: return Encounters[0];
+ case DATA_HADRONOX_EVENT: return Encounters[1];
+ case DATA_ANUBARAK_EVENT: return Encounters[2];
+ }
+
+ return 0;
+ }
+
+ const char* Save()
+ {
+ OUT_SAVE_INST_DATA;
+
+ std::string str_data;
+
+ std::ostringstream saveStream;
+ saveStream << "A N " << Encounters[0] << " " << Encounters[1] << " "
+ << Encounters[2];
+
+ str_data = saveStream.str();
+
+ OUT_SAVE_INST_DATA_COMPLETE;
+ return str_data.c_str();
+ }
+
+ void Load(const char* in)
+ {
+ if (!in)
+ {
+ OUT_LOAD_INST_DATA_FAIL;
+ return;
+ }
+
+ OUT_LOAD_INST_DATA(in);
+
+ char dataHead1, dataHead2;
+ uint16 data0,data1,data2;
+
+ std::istringstream loadStream(in);
+ loadStream >> dataHead1 >> dataHead2 >> data0 >> data1 >> data2;
+
+ if( dataHead1 == 'A' && dataHead2 == 'N')
+ {
+ Encounters[0] = data0;
+ Encounters[1] = data1;
+ Encounters[2] = data2;
+
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ if (Encounters[i] == IN_PROGRESS)
+ Encounters[i] = NOT_STARTED;
+
+ }else OUT_LOAD_INST_DATA_FAIL;
+
+ OUT_LOAD_INST_DATA_COMPLETE;
+ }
+};
+
+InstanceData* GetInstanceData_instance_azjol_nerub(Map* map)
+{
+ return new instance_azjol_nerub(map);
+}
+
+void AddSC_instance_azjol_nerub()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_azjol_nerub";
+ newscript->GetInstanceData = &GetInstanceData_instance_azjol_nerub;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/azshara/azshara.cpp b/src/bindings/scripts/scripts/zone/azshara/azshara.cpp
index a94d3e003b7..d94579361de 100644
--- a/src/bindings/scripts/scripts/zone/azshara/azshara.cpp
+++ b/src/bindings/scripts/scripts/zone/azshara/azshara.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/azshara/boss_azuregos.cpp b/src/bindings/scripts/scripts/zone/azshara/boss_azuregos.cpp
index 97e21ccbe1b..34aa388c4c7 100644
--- a/src/bindings/scripts/scripts/zone/azshara/boss_azuregos.cpp
+++ b/src/bindings/scripts/scripts/zone/azshara/boss_azuregos.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/azuremyst_isle/azuremyst_isle.cpp b/src/bindings/scripts/scripts/zone/azuremyst_isle/azuremyst_isle.cpp
index d87cf571baf..febf52effd1 100644
--- a/src/bindings/scripts/scripts/zone/azuremyst_isle/azuremyst_isle.cpp
+++ b/src/bindings/scripts/scripts/zone/azuremyst_isle/azuremyst_isle.cpp
@@ -1,4 +1,4 @@
- /* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ /* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -39,155 +39,140 @@ EndContentData */
## npc_draenei_survivor
######*/
-#define HEAL1 -1000248
-#define HEAL2 -1000249
-#define HEAL3 -1000250
-#define HEAL4 -1000251
+#define SAY_HEAL1 -1000248
+#define SAY_HEAL2 -1000249
+#define SAY_HEAL3 -1000250
+#define SAY_HEAL4 -1000251
-#define HELP1 -1000252
-#define HELP2 -1000253
-#define HELP3 -1000254
-#define HELP4 -1000255
+#define SAY_HELP1 -1000252
+#define SAY_HELP2 -1000253
+#define SAY_HELP3 -1000254
+#define SAY_HELP4 -1000255
+
+#define SPELL_IRRIDATION 35046
+#define SPELL_STUNNED 28630
struct TRINITY_DLL_DECL npc_draenei_survivorAI : public ScriptedAI
{
npc_draenei_survivorAI(Creature *c) : ScriptedAI(c) {}
- uint32 UnSpawnTimer;
- uint32 ResetlifeTimer;
- uint32 SayingTimer;
- uint32 HealSayTimer;
- bool UnSpawn;
- bool say;
- bool HealSay;
- bool isRun;
- bool isMove;
+ uint64 pCaster;
+
+ uint32 SayThanksTimer;
+ uint32 RunAwayTimer;
+ uint32 SayHelpTimer;
+
+ bool CanSayHelp;
void Reset()
{
- UnSpawnTimer = 2500;
- ResetlifeTimer= 60000;
- SayingTimer = 5000;
- HealSayTimer = 6000;
- say = false;
- isRun = false;
- isMove = false;
- UnSpawn = false;
- HealSay = false;
+ pCaster = 0;
+
+ SayThanksTimer = 0;
+ RunAwayTimer = 0;
+ SayHelpTimer = 10000;
+
+ CanSayHelp = true;
+
+ m_creature->CastSpell(m_creature, SPELL_IRRIDATION, true);
+
+ m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PVP_ATTACKABLE);
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_IN_COMBAT);
- //cast red shining
- m_creature->CastSpell(m_creature, 29152, false, NULL);
- //set creature health
m_creature->SetHealth(int(m_creature->GetMaxHealth()*.1));
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 3);
+ m_creature->SetStandState(UNIT_STAND_STATE_SLEEP);
}
void Aggro(Unit *who) {}
- void MoveInLineOfSight(Unit *who) //MoveInLineOfSight is called if creature could see you, updated all 100 ms
+ void MoveInLineOfSight(Unit *who)
{
- if (!who)
- return;
-
- if(who->GetTypeId() == TYPEID_PLAYER && m_creature->IsFriendlyTo(who) && m_creature->IsWithinDistInMap(who, 15) && say && !isRun)
+ if (CanSayHelp && who->GetTypeId() == TYPEID_PLAYER && m_creature->IsFriendlyTo(who) && m_creature->IsWithinDistInMap(who, 25.0f))
{
- switch (rand()%4) //Random switch between 4 texts
+ //Random switch between 4 texts
+ switch (rand()%4)
{
- case 0:
- DoScriptText(HELP1, m_creature);
- SayingTimer = 15000;
- say = false;
- break;
- case 1:
- DoScriptText(HELP2, m_creature);
- SayingTimer = 15000;
- say = false;
- break;
- case 2:
- DoScriptText(HELP3, m_creature);
- SayingTimer = 15000;
- say = false;
- break;
- case 3:
- DoScriptText(HELP4, m_creature);
- SayingTimer = 15000;
- say = false;
- break;
- }
- }
- else
- {
- isRun = false;
+ case 0: DoScriptText(SAY_HELP1, m_creature, who); break;
+ case 1: DoScriptText(SAY_HELP2, m_creature, who); break;
+ case 2: DoScriptText(SAY_HELP3, m_creature, who); break;
+ case 3: DoScriptText(SAY_HELP4, m_creature, who); break;
+ }
+
+ SayHelpTimer = 20000;
+ CanSayHelp = false;
}
}
- void UpdateAI(const uint32 diff) //Is also called each ms for Creature AI Updates...
+ void SpellHit(Unit *Caster, const SpellEntry *Spell)
{
- if (m_creature->GetHealth() > 50)
+ if (Spell->SpellFamilyFlags[2] & 0x080000000)
{
- if(ResetlifeTimer < diff)
- {
- ResetlifeTimer = 60000;
- m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_IN_COMBAT);
- //set creature health
- m_creature->SetHealth(int(m_creature->GetMaxHealth()*.1));
- // ley down
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,3);
- }
- else ResetlifeTimer -= diff;
- }
+ m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PVP_ATTACKABLE);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
- if(HealSay)
- {
- if (HealSayTimer < diff)
- {
- UnSpawn = true;
- isRun = true;
- isMove = true;
- }else HealSayTimer -= diff;
+ m_creature->CastSpell(m_creature, SPELL_STUNNED, true);
+
+ pCaster = Caster->GetGUID();
+
+ SayThanksTimer = 5000;
}
+ }
- if(UnSpawn)
+ void UpdateAI(const uint32 diff)
+ {
+ if (SayThanksTimer)
{
- if(isMove)
+ if (SayThanksTimer <= diff)
{
+ m_creature->RemoveAurasDueToSpell(SPELL_IRRIDATION);
+
+ if (Player *pPlayer = Unit::GetPlayer(pCaster))
+ {
+ if (pPlayer->GetTypeId() != TYPEID_PLAYER)
+ return;
+
+ switch (rand()%4)
+ {
+ case 0: DoScriptText(SAY_HEAL1, m_creature, pPlayer); break;
+ case 1: DoScriptText(SAY_HEAL2, m_creature, pPlayer); break;
+ case 2: DoScriptText(SAY_HEAL3, m_creature, pPlayer); break;
+ case 3: DoScriptText(SAY_HEAL4, m_creature, pPlayer); break;
+ }
+
+ pPlayer->TalkedToCreature(m_creature->GetEntry(),m_creature->GetGUID());
+ }
+
m_creature->GetMotionMaster()->Clear();
m_creature->GetMotionMaster()->MovePoint(0, -4115.053711f, -13754.831055f, 73.508949f);
- isMove = false;
- }
- if (UnSpawnTimer < diff)
- {
- m_creature->StopMoving();
- EnterEvadeMode();
- //set creature health
- m_creature->SetHealth(int(m_creature->GetMaxHealth()*.1));
+ RunAwayTimer = 10000;
+ SayThanksTimer = 0;
+ }else SayThanksTimer -= diff;
- }else UnSpawnTimer -= diff;
+ return;
}
- if(SayingTimer < diff)
- {
- say = true;
- }else SayingTimer -= diff;
- }
-
- void SpellHit(Unit *Hitter, const SpellEntry *Spellkind)//Called if you cast a spell and do some things if Specified spell is true!
- {
- if (Hitter && Spellkind->Id == 28880)
+ if (RunAwayTimer)
{
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
- m_creature->SetUInt32Value(UNIT_FIELD_FLAGS, UNIT_FLAG_CONFUSED);
- m_creature->HandleEmoteCommand(ANIM_RISE);
- switch (rand()%4) //This switch doesn't work at all, creature say nothing!
+ if (RunAwayTimer <= diff)
{
- case 0: DoScriptText(HEAL1, m_creature, Hitter); break;
- case 1: DoScriptText(HEAL2, m_creature, Hitter); break;
- case 2: DoScriptText(HEAL3, m_creature, Hitter); break;
- case 3: DoScriptText(HEAL4, m_creature, Hitter); break;
- }
- HealSay = true;
+ m_creature->RemoveAllAuras();
+ m_creature->GetMotionMaster()->Clear();
+ m_creature->GetMotionMaster()->MoveIdle();
+ m_creature->setDeathState(JUST_DIED);
+ m_creature->SetHealth(0);
+ m_creature->CombatStop();
+ m_creature->DeleteThreatList();
+ m_creature->RemoveCorpse();
+ }else RunAwayTimer -= diff;
+
+ return;
}
+
+ if (SayHelpTimer < diff)
+ {
+ CanSayHelp = true;
+ SayHelpTimer = 20000;
+ }else SayHelpTimer -= diff;
}
};
CreatureAI* GetAI_npc_draenei_survivor(Creature *_Creature)
@@ -288,8 +273,8 @@ struct TRINITY_DLL_DECL npc_injured_draeneiAI : public ScriptedAI
m_creature->SetHealth(int(m_creature->GetMaxHealth()*.15));
switch (rand()%2)
{
- case 0: m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 1); break;
- case 1: m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 3); break;
+ case 0: m_creature->SetStandState(UNIT_STAND_STATE_SIT); break;
+ case 1: m_creature->SetStandState(UNIT_STAND_STATE_SLEEP); break;
}
}
@@ -322,7 +307,7 @@ CreatureAI* GetAI_npc_injured_draenei(Creature *_Creature)
#define SAY_END2 -1000115
#define EMOTE_HUG -1000116
-#define QUEST_A_CRY_FOR_HELP 9528
+#define QUEST_A_CRY_FOR_SAY_HELP 9528
struct TRINITY_DLL_DECL npc_magwinAI : public npc_escortAI
{
@@ -351,7 +336,7 @@ struct TRINITY_DLL_DECL npc_magwinAI : public npc_escortAI
DoScriptText(EMOTE_HUG, m_creature, player);
DoScriptText(SAY_END2, m_creature, player);
if (player && player->GetTypeId() == TYPEID_PLAYER)
- ((Player*)player)->GroupEventHappens(QUEST_A_CRY_FOR_HELP,m_creature);
+ ((Player*)player)->GroupEventHappens(QUEST_A_CRY_FOR_SAY_HELP,m_creature);
break;
}
}
@@ -373,7 +358,7 @@ struct TRINITY_DLL_DECL npc_magwinAI : public npc_escortAI
{
Player* player = Unit::GetPlayer(PlayerGUID);
if (player)
- ((Player*)player)->FailQuest(QUEST_A_CRY_FOR_HELP);
+ ((Player*)player)->FailQuest(QUEST_A_CRY_FOR_SAY_HELP);
}
}
@@ -385,7 +370,7 @@ struct TRINITY_DLL_DECL npc_magwinAI : public npc_escortAI
bool QuestAccept_npc_magwin(Player* player, Creature* creature, Quest const* quest)
{
- if (quest->GetQuestId() == QUEST_A_CRY_FOR_HELP)
+ if (quest->GetQuestId() == QUEST_A_CRY_FOR_SAY_HELP)
{
creature->setFaction(113);
((npc_escortAI*)(creature->AI()))->Start(true, true, false, player->GetGUID());
@@ -393,41 +378,11 @@ bool QuestAccept_npc_magwin(Player* player, Creature* creature, Quest const* que
return true;
}
-CreatureAI* GetAI_npc_magwinAI(Creature *_Creature)
+CreatureAI* GetAI_npc_magwinAI(Creature* pCreature)
{
- npc_magwinAI* magwinAI = new npc_magwinAI(_Creature);
-
- magwinAI->AddWaypoint(0, -4784.532227, -11051.060547, 3.484263);
- magwinAI->AddWaypoint(1, -4805.509277, -11037.293945, 3.043942);
- magwinAI->AddWaypoint(2, -4827.826172, -11034.398438, 1.741959);
- magwinAI->AddWaypoint(3, -4852.630859, -11033.695313, 2.208656);
- magwinAI->AddWaypoint(4, -4876.791992, -11034.517578, 3.175228);
- magwinAI->AddWaypoint(5, -4895.486816, -11038.306641, 9.390890);
- magwinAI->AddWaypoint(6, -4915.464844, -11048.402344, 12.369793);
- magwinAI->AddWaypoint(7, -4937.288086, -11067.041992, 13.857983);
- magwinAI->AddWaypoint(8, -4966.577637, -11067.507813, 15.754786);
- magwinAI->AddWaypoint(9, -4993.799805, -11056.544922, 19.175295);
- magwinAI->AddWaypoint(10, -5017.836426, -11052.569336, 22.476587);
- magwinAI->AddWaypoint(11, -5039.706543, -11058.459961, 25.831593);
- magwinAI->AddWaypoint(12, -5057.289063, -11045.474609, 26.972496);
- magwinAI->AddWaypoint(13, -5078.828125, -11037.601563, 29.053417);
- magwinAI->AddWaypoint(14, -5104.158691, -11039.195313, 29.440195);
- magwinAI->AddWaypoint(15, -5120.780273, -11039.518555, 30.142139);
- magwinAI->AddWaypoint(16, -5140.833008, -11039.810547, 28.788074);
- magwinAI->AddWaypoint(17, -5161.201660, -11040.050781, 27.879545, 4000);
- magwinAI->AddWaypoint(18, -5171.842285, -11046.803711, 27.183821);
- magwinAI->AddWaypoint(19, -5185.995117, -11056.359375, 20.234867);
- magwinAI->AddWaypoint(20, -5198.485840, -11065.065430, 18.872593);
- magwinAI->AddWaypoint(21, -5214.062500, -11074.653320, 19.215731);
- magwinAI->AddWaypoint(22, -5220.157227, -11088.377930, 19.818476);
- magwinAI->AddWaypoint(23, -5233.652832, -11098.846680, 18.349432);
- magwinAI->AddWaypoint(24, -5250.163086, -11111.653320, 16.438959);
- magwinAI->AddWaypoint(25, -5268.194336, -11125.639648, 12.668313);
- magwinAI->AddWaypoint(26, -5286.270508, -11130.669922, 6.912246);
- magwinAI->AddWaypoint(27, -5317.449707, -11137.392578, 4.963446);
- magwinAI->AddWaypoint(28, -5334.854492, -11154.384766, 6.742664);
- magwinAI->AddWaypoint(29, -5353.874512, -11171.595703, 6.903912, 20000);
- magwinAI->AddWaypoint(30, -5354.240000, -11171.940000, 6.890000);
+ npc_magwinAI* magwinAI = new npc_magwinAI(pCreature);
+
+ magwinAI->FillPointMovementListForCreature();
return (CreatureAI*)magwinAI;
}
@@ -562,7 +517,7 @@ struct TRINITY_DLL_DECL npc_geezleAI : public ScriptedAI
cell.SetNoCreate();
Trinity::AllGameObjectsWithEntryInGrid go_check(GO_NAGA_FLAG);
- Trinity::GameObjectListSearcher<Trinity::AllGameObjectsWithEntryInGrid> go_search(FlagList, go_check);
+ Trinity::GameObjectListSearcher<Trinity::AllGameObjectsWithEntryInGrid> go_search(m_creature, FlagList, go_check);
TypeContainerVisitor
<Trinity::GameObjectListSearcher<Trinity::AllGameObjectsWithEntryInGrid>, GridTypeMapContainer> go_visit(go_search);
CellLock<GridReadGuard> cell_lock(cell, pair);
diff --git a/src/bindings/scripts/scripts/zone/barrens/the_barrens.cpp b/src/bindings/scripts/scripts/zone/barrens/the_barrens.cpp
index 37d0ee089f5..e944d25ad70 100644
--- a/src/bindings/scripts/scripts/zone/barrens/the_barrens.cpp
+++ b/src/bindings/scripts/scripts/zone/barrens/the_barrens.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -89,50 +89,54 @@ bool GossipSelect_npc_sputtervalve(Player *player, Creature *_Creature, uint32 s
## npc_taskmaster_fizzule
######*/
-//#define FACTION_HOSTILE_F 430
-#define FACTION_HOSTILE_F 16
-#define FACTION_FRIENDLY_F 35
-
-#define SPELL_FLARE 10113
-#define SPELL_FOLLY 10137
+enum
+{
+ FACTION_FRIENDLY_F = 35,
+ SPELL_FLARE = 10113,
+ SPELL_FOLLY = 10137,
+};
struct TRINITY_DLL_DECL npc_taskmaster_fizzuleAI : public ScriptedAI
{
- npc_taskmaster_fizzuleAI(Creature* c) : ScriptedAI(c) {}
+ npc_taskmaster_fizzuleAI(Creature* c) : ScriptedAI(c)
+ {
+ factionNorm = c->getFaction();
+ }
+ uint32 factionNorm;
bool IsFriend;
uint32 Reset_Timer;
- uint32 FlareCount;
+ uint8 FlareCount;
void Reset()
{
IsFriend = false;
Reset_Timer = 120000;
FlareCount = 0;
- m_creature->setFaction(FACTION_HOSTILE_F);
- m_creature->RemoveFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_QUESTGIVER);
+ m_creature->setFaction(factionNorm);
}
- //This is a hack. Spellcast will make creature aggro but that is not
- //supposed to happen (Trinity not implemented/not found way to detect this spell kind)
- void DoUglyHack()
+ void DoFriend()
{
m_creature->RemoveAllAuras();
m_creature->DeleteThreatList();
m_creature->CombatStop();
+
+ m_creature->StopMoving();
+ m_creature->GetMotionMaster()->MoveIdle();
+
+ m_creature->setFaction(FACTION_FRIENDLY_F);
+ m_creature->HandleEmoteCommand(EMOTE_ONESHOT_SALUTE);
}
void SpellHit(Unit *caster, const SpellEntry *spell)
{
- if( spell->Id == SPELL_FLARE || spell->Id == SPELL_FOLLY )
+ if (spell->Id == SPELL_FLARE || spell->Id == SPELL_FOLLY)
{
- DoUglyHack();
++FlareCount;
- if( FlareCount >= 2 )
- {
- m_creature->setFaction(FACTION_FRIENDLY_F);
+
+ if (FlareCount >= 2)
IsFriend = true;
- }
}
}
@@ -140,9 +144,9 @@ struct TRINITY_DLL_DECL npc_taskmaster_fizzuleAI : public ScriptedAI
void UpdateAI(const uint32 diff)
{
- if( IsFriend )
+ if (IsFriend)
{
- if( Reset_Timer < diff )
+ if (Reset_Timer < diff)
{
EnterEvadeMode();
} else Reset_Timer -= diff;
@@ -153,24 +157,27 @@ struct TRINITY_DLL_DECL npc_taskmaster_fizzuleAI : public ScriptedAI
DoMeleeAttackIfReady();
}
-};
-CreatureAI* GetAI_npc_taskmaster_fizzule(Creature *_Creature)
-{
- return new npc_taskmaster_fizzuleAI (_Creature);
-}
-bool ReciveEmote_npc_taskmaster_fizzule(Player *player, Creature *_Creature, uint32 emote)
-{
- if( emote == TEXTEMOTE_SALUTE )
+ void ReciveEmote(Player* pPlayer, uint32 emote)
{
- if( ((npc_taskmaster_fizzuleAI*)_Creature->AI())->FlareCount >= 2 )
+ if (emote == TEXTEMOTE_SALUTE)
{
- _Creature->SetFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_QUESTGIVER);
- _Creature->HandleEmoteCommand(EMOTE_ONESHOT_SALUTE);
+ if (FlareCount >= 2)
+ {
+ if (m_creature->getFaction() == FACTION_FRIENDLY_F)
+ return;
+ else
+ DoFriend();
+ }
}
}
- return true;
+};
+
+CreatureAI* GetAI_npc_taskmaster_fizzule(Creature* pCreature)
+{
+ return new npc_taskmaster_fizzuleAI(pCreature);
}
+
/*#####
## npc_twiggy_flathead
#####*/
@@ -357,7 +364,6 @@ struct TRINITY_DLL_DECL npc_twiggy_flatheadAI : public ScriptedAI
//pCreature->GetMotionMaster()->MovePoint(0, -1693, -4343, 4.32);
//pCreature->GetMotionMaster()->MovePoint(1, -1684, -4333, 2.78);
pCreature->GetMotionMaster()->MovePoint(2, -1682, -4329, 2.79);
- //pCreature->HandleEmoteCommand(EMOTE_ONESHOT_ROAR);
pCreature->HandleEmoteCommand(EMOTE_STATE_READYUNARMED);
EventBigWill = true;
Wave_Timer = 1000;
@@ -543,7 +549,6 @@ void AddSC_the_barrens()
newscript = new Script;
newscript->Name="npc_taskmaster_fizzule";
newscript->GetAI = &GetAI_npc_taskmaster_fizzule;
- newscript->pReceiveEmote = &ReciveEmote_npc_taskmaster_fizzule;
newscript->RegisterSelf();
newscript = new Script;
diff --git a/src/bindings/scripts/scripts/zone/black_temple/.boss_teron_gorefiend.cpp-woains b/src/bindings/scripts/scripts/zone/black_temple/.boss_teron_gorefiend.cpp-woains
new file mode 100644
index 00000000000..327b670c6d3
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/black_temple/.boss_teron_gorefiend.cpp-woains
@@ -0,0 +1,536 @@
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Boss_Teron_Gorefiend
+SD%Complete: 60
+SDComment: Requires Mind Control support for Ghosts.
+SDCategory: Black Temple
+EndScriptData */
+
+#include "precompiled.h"
+#include "def_black_temple.h"
+
+ //Speech'n'sound
+#define SAY_INTRO -1564037
+#define SAY_AGGRO -1564038
+#define SAY_SLAY1 -1564039
+#define SAY_SLAY2 -1564040
+#define SAY_SPELL1 -1564041
+#define SAY_SPELL2 -1564042
+#define SAY_SPECIAL1 -1564043
+#define SAY_SPECIAL2 -1564044
+#define SAY_ENRAGE -1564045
+#define SAY_DEATH -1564046
+
+//Spells
+#define SPELL_INCINERATE 40239
+#define SPELL_CRUSHING_SHADOWS 40243
+#define SPELL_SHADOWBOLT 40185
+#define SPELL_PASSIVE_SHADOWFORM 40326
+#define SPELL_SHADOW_OF_DEATH 40251
+#define SPELL_BERSERK 45078
+
+#define SPELL_ATROPHY 40327 // Shadowy Constructs use this when they get within melee range of a player
+
+#define CREATURE_DOOM_BLOSSOM 23123
+#define CREATURE_SHADOWY_CONSTRUCT 23111
+
+struct TRINITY_DLL_DECL mob_doom_blossomAI : public ScriptedAI
+{
+ mob_doom_blossomAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 CheckTeronTimer;
+ uint32 ShadowBoltTimer;
+ uint64 TeronGUID;
+
+ void Reset()
+ {
+ CheckTeronTimer = 5000;
+ ShadowBoltTimer = 12000;
+ TeronGUID = 0;
+ }
+
+ void Aggro(Unit *who) { }
+ void AttackStart(Unit* who) { }
+ void MoveInLineOfSight(Unit* who) { }
+
+ void Despawn()
+ {
+ m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
+ m_creature->RemoveCorpse();
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ if(CheckTeronTimer < diff)
+ {
+ if(TeronGUID)
+ {
+ DoZoneInCombat();
+
+ Creature* Teron = ((Creature*)Unit::GetUnit((*m_creature), TeronGUID));
+ if((Teron) && (!Teron->isAlive() || Teron->IsInEvadeMode()))
+ Despawn();
+ }
+ else
+ Despawn();
+
+ CheckTeronTimer = 5000;
+ }else CheckTeronTimer -= diff;
+
+ if(ShadowBoltTimer < diff && InCombat)
+ {
+ DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_SHADOWBOLT);
+ ShadowBoltTimer = 10000;
+ }else ShadowBoltTimer -= diff;
+ return;
+ }
+
+ void SetTeronGUID(uint64 guid){ TeronGUID = guid; }
+};
+
+//This is used to sort the players by distance for Constructs to see who to cast Atrophy on
+struct TargetDistanceOrder : public std::binary_function<const Unit, const Unit, bool>
+{
+ const Unit* MainTarget;
+ TargetDistanceOrder(const Unit* Target) : MainTarget(Target) {};
+ // functor for operator "<"
+ bool operator()(const Unit* _Left, const Unit* _Right) const
+ {
+ return (MainTarget->GetDistance(_Left) < MainTarget->GetDistance(_Right));
+ }
+};
+
+struct TRINITY_DLL_DECL mob_shadowy_constructAI : public ScriptedAI
+{
+ mob_shadowy_constructAI(Creature* c) : ScriptedAI(c) {}
+
+ uint64 GhostGUID;
+ uint64 TeronGUID;
+
+ uint32 CheckPlayerTimer;
+ uint32 CheckTeronTimer;
+
+ void Reset()
+ {
+ GhostGUID = 0;
+ TeronGUID = 0;
+
+ CheckPlayerTimer = 2000;
+ CheckTeronTimer = 5000;
+ }
+
+ void Aggro(Unit* who) { }
+
+ void MoveInLineOfSight(Unit *who)
+ {
+ if(!who || (!who->isAlive()) || (who->GetGUID() == GhostGUID))
+ return;
+
+ ScriptedAI::MoveInLineOfSight(who);
+ }
+
+/* Comment it out for now. NOTE TO FUTURE DEV: UNCOMMENT THIS OUT ONLY AFTER MIND CONTROL IS IMPLEMENTED
+ void DamageTaken(Unit* done_by, uint32 &damage)
+ {
+ if(done_by->GetGUID() != GhostGUID)
+ damage = 0; // Only the ghost can deal damage.
+ }
+ */
+
+ void CheckPlayers()
+ {
+ std::list<HostilReference*>& m_threatlist = m_creature->getThreatManager().getThreatList();
+ if(m_threatlist.empty())
+ return; // No threat list. Don't continue.
+ std::list<HostilReference*>::iterator itr = m_threatlist.begin();
+ std::list<Unit*> targets;
+ for( ; itr != m_threatlist.end(); ++itr)
+ {
+ Unit* pUnit = Unit::GetUnit((*m_creature), (*itr)->getUnitGuid());
+ if(pUnit && pUnit->isAlive())
+ targets.push_back(pUnit);
+ }
+ targets.sort(TargetDistanceOrder(m_creature));
+ Unit* target = targets.front();
+ if(target && m_creature->IsWithinDistInMap(target, m_creature->GetAttackDistance(target)))
+ {
+ DoCast(target, SPELL_ATROPHY);
+ m_creature->AI()->AttackStart(target);
+ }
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ if(CheckPlayerTimer < diff)
+ {
+ CheckPlayers();
+ CheckPlayerTimer = 3000;
+ }else CheckPlayerTimer -= diff;
+
+ if(CheckTeronTimer < diff)
+ {
+ Creature* Teron = ((Creature*)Unit::GetUnit((*m_creature), TeronGUID));
+ if(!Teron || !Teron->isAlive() || Teron->IsInEvadeMode())
+ m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
+
+ CheckTeronTimer = 5000;
+ }else CheckTeronTimer -= diff;
+ }
+};
+
+struct TRINITY_DLL_DECL boss_teron_gorefiendAI : public ScriptedAI
+{
+ boss_teron_gorefiendAI(Creature *c) : ScriptedAI(c)
+ {
+ pInstance = ((ScriptedInstance*)c->GetInstanceData());
+ }
+
+ ScriptedInstance* pInstance;
+
+ uint32 IncinerateTimer;
+ uint32 SummonDoomBlossomTimer;
+ uint32 EnrageTimer;
+ uint32 CrushingShadowsTimer;
+ uint32 ShadowOfDeathTimer;
+ uint32 SummonShadowsTimer;
+ uint32 RandomYellTimer;
+ uint32 AggroTimer;
+
+ uint64 AggroTargetGUID;
+ uint64 GhostGUID; // Player that gets killed by Shadow of Death and gets turned into a ghost
+
+ bool Intro;
+
+ void Reset()
+ {
+ if(pInstance)
+ pInstance->SetData(DATA_TERONGOREFIENDEVENT, NOT_STARTED);
+
+ IncinerateTimer = 20000 + rand()%11000;
+ SummonDoomBlossomTimer = 12000;
+ EnrageTimer = 600000;
+ CrushingShadowsTimer = 22000;
+ SummonShadowsTimer = 60000;
+ RandomYellTimer = 50000;
+
+ m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ // Start off unattackable so that the intro is done properly
+ m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
+
+ AggroTimer = 20000;
+ AggroTargetGUID = 0;
+ Intro = false;
+ }
+
+ void Aggro(Unit *who) {}
+
+ void MoveInLineOfSight(Unit *who)
+ {
+ if(!who || (!who->isAlive())) return;
+
+ if(who->isTargetableForAttack() && who->isInAccessiblePlaceFor(m_creature) && m_creature->IsHostileTo(who))
+ {
+ float attackRadius = m_creature->GetAttackDistance(who);
+
+ if (m_creature->IsWithinDistInMap(who, attackRadius) && m_creature->GetDistanceZ(who) <= CREATURE_Z_ATTACK_RANGE && m_creature->IsWithinLOSInMap(who))
+ {
+ //if(who->HasStealthAura())
+ // who->RemoveSpellsCausingAura(SPELL_AURA_MOD_STEALTH);
+
+ m_creature->AddThreat(who, 1.0f);
+ }
+
+ if(!InCombat && !Intro && m_creature->IsWithinDistInMap(who, 60.0f) && (who->GetTypeId() == TYPEID_PLAYER))
+ {
+ if(pInstance)
+ pInstance->SetData(DATA_TERONGOREFIENDEVENT, IN_PROGRESS);
+
+ m_creature->GetMotionMaster()->Clear(false);
+ m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ DoScriptText(SAY_INTRO, m_creature);
+ m_creature->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_TALK);
+ AggroTargetGUID = who->GetGUID();
+ Intro = true;
+ }
+ }
+ }
+
+ void KilledUnit(Unit *victim)
+ {
+ switch(rand()%2)
+ {
+ case 0: DoScriptText(SAY_SLAY1, m_creature); break;
+ case 1: DoScriptText(SAY_SLAY2, m_creature); break;
+ }
+ }
+
+ void JustDied(Unit *victim)
+ {
+ if(pInstance)
+ pInstance->SetData(DATA_TERONGOREFIENDEVENT, DONE);
+
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+
+ float CalculateRandomLocation(float Loc, uint32 radius)
+ {
+ float coord = Loc;
+ switch(rand()%2)
+ {
+ case 0:
+ coord += rand()%radius;
+ break;
+ case 1:
+ coord -= rand()%radius;
+ break;
+ }
+ return coord;
+ }
+
+ void SetThreatList(Creature* Blossom)
+ {
+ if(!Blossom) return;
+
+ std::list<HostilReference*>& m_threatlist = m_creature->getThreatManager().getThreatList();
+ std::list<HostilReference*>::iterator i = m_threatlist.begin();
+ for(i = m_threatlist.begin(); i != m_threatlist.end(); i++)
+ {
+ Unit* pUnit = Unit::GetUnit((*m_creature), (*i)->getUnitGuid());
+ if(pUnit && pUnit->isAlive())
+ {
+ float threat = DoGetThreat(pUnit);
+ Blossom->AddThreat(pUnit, threat);
+ }
+ }
+ }
+
+ void MindControlGhost()
+ {
+ /************************************************************************/
+ /** NOTE FOR FUTURE DEVELOPER: PROPERLY IMPLEMENT THE GHOST PORTION *****/
+ /** ONLY AFTER TrinIty FULLY IMPLEMENTS MIND CONTROL ABILITIES *****/
+ /** THE CURRENT CODE IN THIS FUNCTION IS ONLY THE BEGINNING OF *****/
+ /** WHAT IS FULLY NECESSARY FOR GOREFIEND TO BE 100% COMPLETE *****/
+ /************************************************************************/
+
+ Unit* Ghost = NULL;
+ if(GhostGUID)
+ Ghost = Unit::GetUnit((*m_creature), GhostGUID);
+ if(Ghost && Ghost->isAlive() && Ghost->HasAura(SPELL_SHADOW_OF_DEATH, 0))
+ {
+ /*float x,y,z;
+ Ghost->GetPosition(x,y,z);
+ Creature* control = m_creature->SummonCreature(CREATURE_GHOST, x, y, z, 0, TEMPSUMMON_TIMED_DESAWN, 30000);
+ if(control)
+ {
+ ((Player*)Ghost)->Possess(control);
+ Ghost->DealDamage(Ghost, Ghost->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL,
+ false);
+ }*/
+ for(uint8 i = 0; i < 4; ++i)
+ {
+ Creature* Construct = NULL;
+ float X = CalculateRandomLocation(Ghost->GetPositionX(), 10);
+ float Y = CalculateRandomLocation(Ghost->GetPositionY(), 10);
+ Construct = m_creature->SummonCreature(CREATURE_SHADOWY_CONSTRUCT, X, Y, Ghost->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 45000);
+ if(Construct)
+ {
+ Construct->CastSpell(Construct, SPELL_PASSIVE_SHADOWFORM, true);
+ SetThreatList(Construct); // Use same function as Doom Blossom to set Threat List.
+ ((mob_shadowy_constructAI*)Construct->AI())->GhostGUID = GhostGUID;
+ Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 1);
+ if(!target) // someone's trying to solo.
+ target = m_creature->getVictim();
+
+ if(target)
+ Construct->GetMotionMaster()->MoveChase(target);
+ }
+ }
+ }
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ if(Intro)
+ {
+ if(AggroTimer < diff)
+ {
+ m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
+ DoScriptText(SAY_AGGRO, m_creature);
+ m_creature->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_STATE_NONE);
+ Intro = false;
+ if(AggroTargetGUID)
+ {
+ Unit* pUnit = Unit::GetUnit((*m_creature), AggroTargetGUID);
+ if(pUnit)
+ AttackStart(pUnit);
+
+ DoZoneInCombat();
+ }else EnterEvadeMode();
+
+ }else AggroTimer -= diff;
+ }
+
+ if(!UpdateVictim() || Intro)
+ return;
+
+ if(SummonShadowsTimer < diff)
+ {
+ //MindControlGhost();
+
+ for(uint8 i = 0; i < 2; ++i)
+ {
+ Creature* Shadow = NULL;
+ float X = CalculateRandomLocation(m_creature->GetPositionX(), 10);
+ Shadow = m_creature->SummonCreature(CREATURE_SHADOWY_CONSTRUCT, X, m_creature->GetPositionY(), m_creature->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 0);
+ if(Shadow)
+ {
+ Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 1);
+ if(!target)
+ target = m_creature->getVictim();
+
+ if(target)
+ Shadow->AI()->AttackStart(target);
+ }
+ }
+ SummonShadowsTimer = 60000;
+ }else SummonShadowsTimer -= diff;
+
+ if(SummonDoomBlossomTimer < diff)
+ {
+ if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 0))
+ {
+ float X = CalculateRandomLocation(target->GetPositionX(), 20);
+ float Y = CalculateRandomLocation(target->GetPositionY(), 20);
+ float Z = target->GetPositionZ();
+ Z = m_creature->GetMap()->GetVmapHeight(X, Y, Z, true);
+ Creature* DoomBlossom = m_creature->SummonCreature(CREATURE_DOOM_BLOSSOM, X, Y, Z, 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 20000);
+ if(DoomBlossom)
+ {
+ DoomBlossom->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ DoomBlossom->setFaction(m_creature->getFaction());
+ DoomBlossom->AddThreat(target, 1.0f);
+ ((mob_doom_blossomAI*)DoomBlossom->AI())->SetTeronGUID(m_creature->GetGUID());
+ ((mob_doom_blossomAI*)DoomBlossom->AI())->InCombat = true;
+ SetThreatList(DoomBlossom);
+ SummonDoomBlossomTimer = 35000;
+ }
+ }
+ }else SummonDoomBlossomTimer -= diff;
+
+ if(IncinerateTimer < diff)
+ {
+ Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 1);
+ if(!target)
+ target = m_creature->getVictim();
+
+ if(target)
+ {
+ switch(rand()%2)
+ {
+ case 0: DoScriptText(SAY_SPECIAL1, m_creature); break;
+ case 1: DoScriptText(SAY_SPECIAL2, m_creature); break;
+ }
+ DoCast(target, SPELL_INCINERATE);
+ IncinerateTimer = 20000 + rand()%31 * 1000;
+ }
+ }else IncinerateTimer -= diff;
+
+ if(CrushingShadowsTimer < diff)
+ {
+ Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 0);
+ if(target && target->isAlive())
+ DoCast(target, SPELL_CRUSHING_SHADOWS);
+ CrushingShadowsTimer = 10000 + rand()%16 * 1000;
+ }else CrushingShadowsTimer -= diff;
+
+ /*** NOTE FOR FUTURE DEV: UNCOMMENT BELOW ONLY IF MIND CONTROL IS FULLY IMPLEMENTED **/
+ /*if(ShadowOfDeathTimer < diff)
+ {
+ Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 1);
+
+ if(!target)
+ target = m_creature->getVictim();
+
+ if(target && target->isAlive() && target->GetTypeId() == TYPEID_PLAYER)
+ {
+ DoCast(target, SPELL_SHADOW_OF_DEATH);
+ GhostGUID = target->GetGUID();
+ ShadowOfDeathTimer = 30000;
+ SummonShadowsTimer = 53000; // Make it VERY close but slightly less so that we can check if the aura is still on the player
+ }
+ }else ShadowOfDeathTimer -= diff;*/
+
+ if(RandomYellTimer < diff)
+ {
+ switch(rand()%2)
+ {
+ case 0: DoScriptText(SAY_SPELL1, m_creature); break;
+ case 1: DoScriptText(SAY_SPELL2, m_creature); break;
+ }
+ RandomYellTimer = 50000 + rand()%51 * 1000;
+ }else RandomYellTimer -= diff;
+
+ if(!m_creature->HasAura(SPELL_BERSERK, 0))
+ {
+ if(EnrageTimer < diff)
+ {
+ DoCast(m_creature, SPELL_BERSERK);
+ DoScriptText(SAY_ENRAGE, m_creature);
+ }else EnrageTimer -= diff;
+ }
+
+ DoMeleeAttackIfReady();
+ }
+};
+
+CreatureAI* GetAI_mob_doom_blossom(Creature *_Creature)
+{
+ return new mob_doom_blossomAI(_Creature);
+}
+
+CreatureAI* GetAI_mob_shadowy_construct(Creature *_Creature)
+{
+ return new mob_shadowy_constructAI(_Creature);
+}
+
+CreatureAI* GetAI_boss_teron_gorefiend(Creature *_Creature)
+{
+ return new boss_teron_gorefiendAI (_Creature);
+}
+
+void AddSC_boss_teron_gorefiend()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "mob_doom_blossom";
+ newscript->GetAI = &GetAI_mob_doom_blossom;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name = "mob_shadowy_construct";
+ newscript->GetAI = &GetAI_mob_shadowy_construct;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="boss_teron_gorefiend";
+ newscript->GetAI = &GetAI_boss_teron_gorefiend;
+ newscript->RegisterSelf();
+}
+
diff --git a/src/bindings/scripts/scripts/zone/black_temple/.instance_black_temple.cpp-s8inyu b/src/bindings/scripts/scripts/zone/black_temple/.instance_black_temple.cpp-s8inyu
new file mode 100644
index 00000000000..43646746505
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/black_temple/.instance_black_temple.cpp-s8inyu
@@ -0,0 +1,347 @@
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+* This program is free software; you can redistribute it and/or modify
+* it under the terms of the GNU General Public License as published by
+* the Free Software Foundation; either version 2 of the License, or
+* (at your option) any later version.
+*
+* This program is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+* GNU General Public License for more details.
+*
+* You should have received a copy of the GNU General Public License
+* along with this program; if not, write to the Free Software
+* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+*/
+
+/* ScriptData
+SDName: Instance_Black_Temple
+SD%Complete: 100
+SDComment: Instance Data Scripts and functions to acquire mobs and set encounter status for use in various Black Temple Scripts
+SDCategory: Black Temple
+EndScriptData */
+
+#include "precompiled.h"
+#include "def_black_temple.h"
+
+#define ENCOUNTERS 9
+
+/* Black Temple encounters:
+0 - High Warlord Naj'entus event
+1 - Supremus Event
+2 - Shade of Akama Event
+3 - Teron Gorefiend Event
+4 - Gurtogg Bloodboil Event
+5 - Reliquary Of Souls Event
+6 - Mother Shahraz Event
+7 - Illidari Council Event
+8 - Illidan Stormrage Event
+*/
+
+struct TRINITY_DLL_DECL instance_black_temple : public ScriptedInstance
+{
+ instance_black_temple(Map *map) : ScriptedInstance(map) {Initialize();};
+
+ uint32 Encounters[ENCOUNTERS];
+ std::string str_data;
+
+ uint64 Najentus;
+ uint64 Akama; // This is the Akama that starts the Illidan encounter.
+ uint64 Akama_Shade; // This is the Akama that starts the Shade of Akama encounter.
+ uint64 ShadeOfAkama;
+ uint64 Supremus;
+ uint64 LadyMalande;
+ uint64 GathiosTheShatterer;
+ uint64 HighNethermancerZerevor;
+ uint64 VerasDarkshadow;
+ uint64 IllidariCouncil;
+ uint64 BloodElfCouncilVoice;
+ uint64 IllidanStormrage;
+
+ uint64 NajentusGate;
+ uint64 MainTempleDoors;
+ uint64 ShadeOfAkamaDoor;
+ uint64 CommonDoor;//Teron
+ uint64 TeronDoor;
+ uint64 GuurtogDoor;
+ uint64 MotherDoor;
+ uint64 TempleDoor;//Befor mother
+ uint64 CouncilDoor;
+ uint64 SimpleDoor;//council
+ uint64 IllidanGate;
+ uint64 IllidanDoor[2];
+
+ void Initialize()
+ {
+ Najentus = 0;
+ Akama = 0;
+ Akama_Shade = 0;
+ ShadeOfAkama = 0;
+ Supremus = 0;
+ LadyMalande = 0;
+ GathiosTheShatterer = 0;
+ HighNethermancerZerevor = 0;
+ VerasDarkshadow = 0;
+ IllidariCouncil = 0;
+ BloodElfCouncilVoice = 0;
+ IllidanStormrage = 0;
+
+ NajentusGate = 0;
+ MainTempleDoors = 0;
+ ShadeOfAkamaDoor= 0;
+ CommonDoor = 0;//teron
+ TeronDoor = 0;
+ GuurtogDoor = 0;
+ MotherDoor = 0;
+ TempleDoor = 0;
+ SimpleDoor = 0;//Bycouncil
+ CouncilDoor = 0;
+ IllidanGate = 0;
+ IllidanDoor[0] = 0;
+ IllidanDoor[1] = 0;
+
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ Encounters[i] = NOT_STARTED;
+ }
+
+ bool IsEncounterInProgress() const
+ {
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ if(Encounters[i] == IN_PROGRESS) return true;
+
+ return false;
+ }
+
+ Player* GetPlayerInMap()
+ {
+ Map::PlayerList const& players = instance->GetPlayers();
+
+ if (!players.isEmpty())
+ {
+ for(Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr)
+ {
+ if (Player* plr = itr->getSource())
+ return plr;
+ }
+ }
+
+ debug_log("TSCR: Instance Black Temple: GetPlayerInMap, but PlayerList is empty!");
+ return NULL;
+ }
+
+ void OnCreatureCreate(Creature *creature, uint32 creature_entry)
+ {
+ switch(creature->GetEntry())
+ {
+ case 22887: Najentus = creature->GetGUID(); break;
+ case 23089: Akama = creature->GetGUID(); break;
+ case 22990: Akama_Shade = creature->GetGUID(); break;
+ case 22841: ShadeOfAkama = creature->GetGUID(); break;
+ case 22898: Supremus = creature->GetGUID(); break;
+ case 22917: IllidanStormrage = creature->GetGUID(); break;
+ case 22949: GathiosTheShatterer = creature->GetGUID(); break;
+ case 22950: HighNethermancerZerevor = creature->GetGUID(); break;
+ case 22951: LadyMalande = creature->GetGUID(); break;
+ case 22952: VerasDarkshadow = creature->GetGUID(); break;
+ case 23426: IllidariCouncil = creature->GetGUID(); break;
+ case 23499: BloodElfCouncilVoice = creature->GetGUID(); break;
+ }
+ }
+
+ void OnObjectCreate(GameObject* go)
+ {
+ switch(go->GetEntry())
+ {
+ case 185483: NajentusGate = go->GetGUID();// Gate past Naj'entus (at the entrance to Supermoose's courtyards)
+ if(Encounters[0] == DONE)HandleGameObject(NULL,true,go);break;
+ case 185882: MainTempleDoors = go->GetGUID();// Main Temple Doors - right past Supermoose (Supremus)
+ if(Encounters[1] == DONE)HandleGameObject(NULL,true,go);break;
+ case 185478: ShadeOfAkamaDoor = go->GetGUID();break;
+ case 185480: CommonDoor = go->GetGUID();
+ if(Encounters[3] == DONE)HandleGameObject(NULL,true,go);;break;
+ case 186153: TeronDoor = go->GetGUID();
+ if(Encounters[3] == DONE)HandleGameObject(NULL,true,go);;break;
+ case 185892: GuurtogDoor = go->GetGUID();
+ if(Encounters[4] == DONE)HandleGameObject(NULL,true,go);break;
+ case 185479: TempleDoor = go->GetGUID();
+ if(Encounters[5] == DONE)HandleGameObject(NULL,true,go);break;
+ case 185482: MotherDoor = go->GetGUID();
+ if(Encounters[6] == DONE)HandleGameObject(NULL,true,go);break;
+ case 185481: CouncilDoor = go->GetGUID();
+ if(Encounters[7] == DONE)HandleGameObject(NULL,true,go);break;
+ case 186152: SimpleDoor = go->GetGUID();
+ if(Encounters[7] == DONE)HandleGameObject(NULL,true,go);break;
+ case 185905: IllidanGate = go->GetGUID(); break; // Gate leading to Temple Summit
+ case 186261: IllidanDoor[0] = go->GetGUID(); break; // Right door at Temple Summit
+ case 186262: IllidanDoor[1] = go->GetGUID(); break; // Left door at Temple Summit
+ }
+ }
+
+ uint64 GetData64(uint32 identifier)
+ {
+ switch(identifier)
+ {
+ case DATA_HIGHWARLORDNAJENTUS: return Najentus;
+ case DATA_AKAMA: return Akama;
+ case DATA_AKAMA_SHADE: return Akama_Shade;
+ case DATA_SHADEOFAKAMA: return ShadeOfAkama;
+ case DATA_SUPREMUS: return Supremus;
+ case DATA_ILLIDANSTORMRAGE: return IllidanStormrage;
+ case DATA_GATHIOSTHESHATTERER: return GathiosTheShatterer;
+ case DATA_HIGHNETHERMANCERZEREVOR: return HighNethermancerZerevor;
+ case DATA_LADYMALANDE: return LadyMalande;
+ case DATA_VERASDARKSHADOW: return VerasDarkshadow;
+ case DATA_ILLIDARICOUNCIL: return IllidariCouncil;
+ case DATA_GAMEOBJECT_NAJENTUS_GATE: return NajentusGate;
+ case DATA_GAMEOBJECT_ILLIDAN_GATE: return IllidanGate;
+ case DATA_GAMEOBJECT_ILLIDAN_DOOR_R: return IllidanDoor[0];
+ case DATA_GAMEOBJECT_ILLIDAN_DOOR_L: return IllidanDoor[1];
+ case DATA_GAMEOBJECT_SUPREMUS_DOORS: return MainTempleDoors;
+ case DATA_BLOOD_ELF_COUNCIL_VOICE: return BloodElfCouncilVoice;
+ }
+
+ return 0;
+ }
+
+ void SetData(uint32 type, uint32 data)
+ {
+ switch(type)
+ {
+ case DATA_HIGHWARLORDNAJENTUSEVENT:
+ if(data == DONE)
+ {
+ HandleGameObject(NajentusGate, true);
+ }
+ Encounters[0] = data;break;
+ case DATA_SUPREMUSEVENT:
+ if(data == DONE)
+ {
+ HandleGameObject(NajentusGate, true);
+ }
+ Encounters[1] = data; break;
+ case DATA_SHADEOFAKAMAEVENT:
+ if(data == IN_PROGRESS)
+ {
+ HandleGameObject(ShadeOfAkamaDoor, false);
+ }else HandleGameObject(ShadeOfAkamaDoor, true);
+ Encounters[2] = data; break;
+ case DATA_TERONGOREFIENDEVENT:
+ if(data == IN_PROGRESS)
+ {
+ HandleGameObject(TeronDoor, false);
+ HandleGameObject(CommonDoor, false);
+ }else
+ {
+ HandleGameObject(TeronDoor, true);
+ HandleGameObject(CommonDoor, true);
+ }
+ Encounters[3] = data; break;
+ case DATA_GURTOGGBLOODBOILEVENT:
+ if(data == DONE)
+ {
+ HandleGameObject(GuurtogDoor, true);
+ }
+ Encounters[4] = data; break;
+ case DATA_RELIQUARYOFSOULSEVENT:
+ if(data == DONE)
+ {
+ HandleGameObject(TempleDoor, true);
+ }
+ Encounters[5] = data; break;
+ case DATA_MOTHERSHAHRAZEVENT:
+ if(data == DONE)
+ {
+ HandleGameObject(MotherDoor, true);
+ }
+ Encounters[6] = data; break;
+ case DATA_ILLIDARICOUNCILEVENT:
+ if(data == IN_PROGRESS)
+ {
+ HandleGameObject(CouncilDoor, false);
+ HandleGameObject(SimpleDoor, false);
+ }else
+ {
+ HandleGameObject(CouncilDoor, true);
+ HandleGameObject(SimpleDoor, true);
+ }
+ Encounters[7] = data; break;
+ case DATA_ILLIDANSTORMRAGEEVENT: Encounters[8] = data; break;
+ }
+
+ if (data == DONE)
+ {
+ OUT_SAVE_INST_DATA;
+
+ std::ostringstream saveStream;
+ saveStream << Encounters[0] << " " << Encounters[1] << " "
+ << Encounters[2] << " " << Encounters[3] << " " << Encounters[4]
+ << " " << Encounters[5] << " " << Encounters[6] << " " << Encounters[7]
+ << " " << Encounters[8];
+
+ str_data = saveStream.str();
+
+ SaveToDB();
+ OUT_SAVE_INST_DATA_COMPLETE;
+ }
+ }
+
+ uint32 GetData(uint32 type)
+ {
+ switch(type)
+ {
+ case DATA_HIGHWARLORDNAJENTUSEVENT: return Encounters[0];
+ case DATA_SUPREMUSEVENT: return Encounters[1];
+ case DATA_SHADEOFAKAMAEVENT: return Encounters[2];
+ case DATA_TERONGOREFIENDEVENT: return Encounters[3];
+ case DATA_GURTOGGBLOODBOILEVENT: return Encounters[4];
+ case DATA_RELIQUARYOFSOULSEVENT: return Encounters[5];
+ case DATA_MOTHERSHAHRAZEVENT: return Encounters[6];
+ case DATA_ILLIDARICOUNCILEVENT: return Encounters[7];
+ case DATA_ILLIDANSTORMRAGEEVENT: return Encounters[8];
+ }
+
+ return 0;
+ }
+
+ const char* Save()
+ {
+ return str_data.c_str();
+ }
+
+ void Load(const char* in)
+ {
+ if (!in)
+ {
+ OUT_LOAD_INST_DATA_FAIL;
+ return;
+ }
+
+ OUT_LOAD_INST_DATA(in);
+
+ std::istringstream loadStream(in);
+ loadStream >> Encounters[0] >> Encounters[1] >> Encounters[2]
+ >> Encounters[3] >> Encounters[4] >> Encounters[5] >> Encounters[6]
+ >> Encounters[7] >> Encounters[8];
+
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ if (Encounters[i] == IN_PROGRESS)
+ Encounters[i] = NOT_STARTED;
+
+ OUT_LOAD_INST_DATA_COMPLETE;
+ }
+};
+
+InstanceData* GetInstanceData_instance_black_temple(Map* map)
+{
+ return new instance_black_temple(map);
+}
+
+void AddSC_instance_black_temple()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_black_temple";
+ newscript->GetInstanceData = &GetInstanceData_instance_black_temple;
+ newscript->RegisterSelf();
+}
+
diff --git a/src/bindings/scripts/scripts/zone/black_temple/black_temple.cpp b/src/bindings/scripts/scripts/zone/black_temple/black_temple.cpp
index da9b20ef63e..738c58eab2e 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/black_temple.cpp
+++ b/src/bindings/scripts/scripts/zone/black_temple/black_temple.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/black_temple/boss_bloodboil.cpp b/src/bindings/scripts/scripts/zone/black_temple/boss_bloodboil.cpp
index 656496c268f..b181f50f69b 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/boss_bloodboil.cpp
+++ b/src/bindings/scripts/scripts/zone/black_temple/boss_bloodboil.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -215,7 +215,7 @@ struct TRINITY_DLL_DECL boss_gurtogg_bloodboilAI : public ScriptedAI
FelAcidTimer = 25000;
}else FelAcidTimer -= diff;
- if(!m_creature->HasAura(SPELL_BERSERK, 0))
+ if(!m_creature->HasAura(SPELL_BERSERK))
{
if(EnrageTimer < diff)
{
diff --git a/src/bindings/scripts/scripts/zone/black_temple/boss_illidan.cpp b/src/bindings/scripts/scripts/zone/black_temple/boss_illidan.cpp
index 4b0190c1dd5..6d36e208a70 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/boss_illidan.cpp
+++ b/src/bindings/scripts/scripts/zone/black_temple/boss_illidan.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -137,6 +137,9 @@ EndScriptData */
#define FLAME_ENRAGE_DISTANCE 30
#define FLAME_CHARGE_DISTANCE 50
+#define ITEM_ID_MAIN_HAND 32837
+#define ITEM_ID_OFF_HAND 32838
+
/**** Creature Summon and Recognition IDs ****/
enum CreatureEntry
{
@@ -365,6 +368,10 @@ struct TRINITY_DLL_DECL boss_illidan_stormrageAI : public ScriptedAI
{
pInstance = ((ScriptedInstance*)c->GetInstanceData());
m_creature->CastSpell(m_creature, SPELL_DUAL_WIELD, true);
+
+ SpellEntry *TempSpell = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_SHADOWFIEND_PASSIVE);
+ if(TempSpell)
+ TempSpell->EffectApplyAuraName[0] = 4; // proc debuff, and summon infinite fiends
}
ScriptedInstance* pInstance;
@@ -454,7 +461,7 @@ struct TRINITY_DLL_DECL boss_illidan_stormrageAI : public ScriptedAI
{
GameObject* Door = GameObject::GetGameObject((*m_creature), pInstance->GetData64(i));
if(Door)
- Door->SetUInt32Value(GAMEOBJECT_STATE, 0); // Open Doors
+ Door->SetGoState(0); // Open Doors
}
}
@@ -487,10 +494,10 @@ struct TRINITY_DLL_DECL boss_illidan_stormrageAI : public ScriptedAI
{
if(spell->Id == SPELL_GLAIVE_RETURNS) // Re-equip our warblades!
{
- if(!m_creature->GetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY))
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 45479);
+ if(!m_creature->GetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID))
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 45479);
else
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 45481);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 45481);
m_creature->SetByteValue(UNIT_FIELD_BYTES_2, 0, SHEATH_STATE_MELEE );
}
}
@@ -524,7 +531,7 @@ struct TRINITY_DLL_DECL boss_illidan_stormrageAI : public ScriptedAI
if(Conversation[count].emote)
creature->HandleEmoteCommand(Conversation[count].emote); // Make the creature do some animation!
if(Conversation[count].text)
- creature->Yell(Conversation[count].text, LANG_UNIVERSAL, 0); // Have the creature yell out some text
+ creature->MonsterYell(Conversation[count].text, LANG_UNIVERSAL, 0); // Have the creature yell out some text
if(Conversation[count].sound)
DoPlaySoundToSet(creature, Conversation[count].sound); // Play some sound on the creature
}
@@ -567,8 +574,8 @@ struct TRINITY_DLL_DECL boss_illidan_stormrageAI : public ScriptedAI
Timer[EVENT_FLIGHT_SEQUENCE] = 700;
break;
case 4://throw another
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 0);
{
uint8 i=0;
Creature* Glaive = m_creature->SummonCreature(BLADE_OF_AZZINOTH, GlaivePosition[i].x, GlaivePosition[i].y, GlaivePosition[i].z, 0, TEMPSUMMON_CORPSE_DESPAWN, 0);
@@ -653,14 +660,14 @@ struct TRINITY_DLL_DECL boss_illidan_stormrageAI : public ScriptedAI
if(DemonTransformation[TransformCount].equip)
{
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 45479); // Requip warglaives if needed
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 45481);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 45479); // Requip warglaives if needed
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 45481);
m_creature->SetByteValue(UNIT_FIELD_BYTES_2, 0, SHEATH_STATE_MELEE );
}
else
{
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 0); // Unequip warglaives if needed
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+0, 0); // Unequip warglaives if needed
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 0);
}
switch(TransformCount)
@@ -741,7 +748,7 @@ struct TRINITY_DLL_DECL boss_illidan_stormrageAI : public ScriptedAI
if(m_creature->IsNonMeleeSpellCasted(false))
return;
- if(Phase == PHASE_NORMAL || Phase == PHASE_NORMAL_2 || Phase == PHASE_NORMAL_MAIEV && !m_creature->HasAura(SPELL_CAGED, 0))
+ if(Phase == PHASE_NORMAL || Phase == PHASE_NORMAL_2 || Phase == PHASE_NORMAL_MAIEV && !m_creature->HasAura(SPELL_CAGED))
{
switch(Event)
{
@@ -926,7 +933,7 @@ struct TRINITY_DLL_DECL flame_of_azzinothAI : public ScriptedAI
AttackStart(m_creature->getVictim());
}
}
- else if(!m_creature->HasAura(SPELL_AZZINOTH_CHANNEL, 0))
+ else if(!m_creature->HasAura(SPELL_AZZINOTH_CHANNEL))
{
Glaive->CastSpell(m_creature, SPELL_AZZINOTH_CHANNEL, false);
m_creature->RemoveAurasDueToSpell(SPELL_FLAME_ENRAGE);
@@ -998,10 +1005,10 @@ struct TRINITY_DLL_DECL npc_akama_illidanAI : public ScriptedAI
DoorGUID[1] = pInstance->GetData64(DATA_GAMEOBJECT_ILLIDAN_DOOR_L);
if(GETGO(Gate, GateGUID))
- Gate->SetUInt32Value(GAMEOBJECT_STATE, 1);
+ Gate->SetGoState(1);
for(uint8 i = 0; i < 2; i++)
if(GETGO(Door, DoorGUID[i]))
- Door->SetUInt32Value(GAMEOBJECT_STATE, 1);
+ Door->SetGoState(1);
}
else
{
@@ -1071,7 +1078,7 @@ struct TRINITY_DLL_DECL npc_akama_illidanAI : public ScriptedAI
for(uint8 i = 0; i < 2; i++)
if(GETGO(Door, DoorGUID[i]))
- Door->SetUInt32Value(GAMEOBJECT_STATE, 1);
+ Door->SetGoState(1);
if(GETCRE(Illidan, IllidanGUID))
{
@@ -1186,7 +1193,7 @@ struct TRINITY_DLL_DECL npc_akama_illidanAI : public ScriptedAI
if(GETCRE(Illidan, IllidanGUID))
{
((boss_illidan_stormrageAI*)Illidan->AI())->Timer[EVENT_TAUNT] += 30000;
- Illidan->Yell(SAY_AKAMA_MINION, LANG_UNIVERSAL, 0);
+ Illidan->MonsterYell(SAY_AKAMA_MINION, LANG_UNIVERSAL, 0);
DoPlaySoundToSet(Illidan, SOUND_AKAMA_MINION);
}
Timer = 8000;
@@ -1237,7 +1244,7 @@ struct TRINITY_DLL_DECL npc_akama_illidanAI : public ScriptedAI
Spirit[0]->InterruptNonMeleeSpells(true);
Spirit[1]->InterruptNonMeleeSpells(true);
if(GETGO(Gate, GateGUID))
- Gate->SetUInt32Value(GAMEOBJECT_STATE, 0);
+ Gate->SetGoState(0);
Timer = 2000;
break;
case 4:
@@ -1268,7 +1275,7 @@ struct TRINITY_DLL_DECL npc_akama_illidanAI : public ScriptedAI
case 6:
for(uint8 i = 0; i < 2; i++)
if(GETGO(Door, DoorGUID[i]))
- Door->SetUInt32Value(GAMEOBJECT_STATE, 0);
+ Door->SetGoState(0);
break;
case 8:
if(Phase == PHASE_WALK)
@@ -1378,9 +1385,9 @@ struct TRINITY_DLL_DECL boss_maievAI : public ScriptedAI
Timer[EVENT_MAIEV_STEALTH] = 0;
Timer[EVENT_MAIEV_TAUNT] = 22000 + rand()%21 * 1000;
Timer[EVENT_MAIEV_SHADOW_STRIKE] = 30000;
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 44850);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY + 1, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY + 2, 45738);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 44850);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 1, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 2, 45738);
}
void Aggro(Unit *who) {}
@@ -1618,12 +1625,12 @@ struct TRINITY_DLL_DECL cage_trap_triggerAI : public ScriptedAI
{
if(who->GetEntry() == ILLIDAN_STORMRAGE) // Check if who is Illidan
{
- if(!IllidanGUID && m_creature->IsWithinDistInMap(who, 3) && (!who->HasAura(SPELL_CAGED, 0)))
+ if(!IllidanGUID && m_creature->IsWithinDistInMap(who, 3) && (!who->HasAura(SPELL_CAGED)))
{
IllidanGUID = who->GetGUID();
who->CastSpell(who, SPELL_CAGED, true);
DespawnTimer = 5000;
- if(who->HasAura(SPELL_ENRAGE, 0))
+ if(who->HasAura(SPELL_ENRAGE))
who->RemoveAurasDueToSpell(SPELL_ENRAGE); // Dispel his enrage
//if(GameObject* CageTrap = GameObject::GetGameObject(*m_creature, CageTrapGUID))
// CageTrap->SetLootState(GO_JUST_DEACTIVATED);
@@ -1663,7 +1670,7 @@ bool GOHello_cage_trap(Player* plr, GameObject* go)
// Grid search for nearest live creature of entry 23304 within 10 yards
Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck check(*plr, 23304, true, 10);
- Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck> searcher(trigger, check);
+ Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck> searcher(plr, trigger, check);
TypeContainerVisitor<Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck>, GridTypeMapContainer> cSearcher(searcher);
@@ -1671,7 +1678,7 @@ bool GOHello_cage_trap(Player* plr, GameObject* go)
cell_lock->Visit(cell_lock, cSearcher, *(plr->GetMap()));
((cage_trap_triggerAI*)trigger->AI())->Active = true;
- go->SetUInt32Value(GAMEOBJECT_STATE, 0);
+ go->SetGoState(0);
return true;
}
@@ -1701,7 +1708,7 @@ struct TRINITY_DLL_DECL shadow_demonAI : public ScriptedAI
if(m_creature->getVictim()->GetTypeId() != TYPEID_PLAYER) return; // Only cast the below on players.
- if(!m_creature->getVictim()->HasAura(SPELL_PARALYZE, 0))
+ if(!m_creature->getVictim()->HasAura(SPELL_PARALYZE))
{
TargetGUID = m_creature->getVictim()->GetGUID();
m_creature->AddThreat(m_creature->getVictim(), 10000000.0f);
@@ -1743,8 +1750,8 @@ struct TRINITY_DLL_DECL mob_parasitic_shadowfiendAI : public ScriptedAI
{
if( m_creature->isAttackReady() && m_creature->IsWithinMeleeRange(m_creature->getVictim()))
{
- if(!m_creature->getVictim()->HasAura(SPELL_PARASITIC_SHADOWFIEND, 0)
- && !m_creature->getVictim()->HasAura(SPELL_PARASITIC_SHADOWFIEND2, 0))
+ if(!m_creature->getVictim()->HasAura(SPELL_PARASITIC_SHADOWFIEND)
+ && !m_creature->getVictim()->HasAura(SPELL_PARASITIC_SHADOWFIEND2))
{
m_creature->CastSpell(m_creature->getVictim(), SPELL_PARASITIC_SHADOWFIEND2, true, 0, 0, IllidanGUID); //do not stack
}
@@ -1834,8 +1841,8 @@ void boss_illidan_stormrageAI::Reset()
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_ATTACKABLE_2);
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 0);
m_creature->RemoveUnitMovementFlag(MOVEMENTFLAG_LEVITATING + MOVEMENTFLAG_ONTRANSPORT);
m_creature->setActive(false);
Summons.DespawnAll();
@@ -1855,8 +1862,8 @@ void boss_illidan_stormrageAI::JustSummoned(Creature* summon)
return;
}
Unit *target = SelectUnit(SELECT_TARGET_TOPAGGRO, 0, 999, true);
- if(!target || target->HasAura(SPELL_PARASITIC_SHADOWFIEND, 0)
- || target->HasAura(SPELL_PARASITIC_SHADOWFIEND2, 0))
+ if(!target || target->HasAura(SPELL_PARASITIC_SHADOWFIEND)
+ || target->HasAura(SPELL_PARASITIC_SHADOWFIEND2))
target = SelectUnit(SELECT_TARGET_RANDOM, 0, 999, true);
if(target)
summon->AI()->AttackStart(target);
@@ -1892,8 +1899,8 @@ void boss_illidan_stormrageAI::HandleTalkSequence()
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
break;
case 8:
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 45479); // Equip our warglaives!
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 45481);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 45479); // Equip our warglaives!
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 45481);
m_creature->SetByteValue(UNIT_FIELD_BYTES_2, 0, SHEATH_STATE_MELEE );
m_creature->RemoveUnitMovementFlag(MOVEMENTFLAG_WALK_MODE);
break;
@@ -1953,7 +1960,7 @@ void boss_illidan_stormrageAI::HandleTalkSequence()
{
Maiev->CastSpell(Maiev, SPELL_TELEPORT_VISUAL, true);
Maiev->setDeathState(JUST_DIED);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,PLAYER_STATE_DEAD);
+ m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,UNIT_STAND_STATE_DEAD);
}
break;
case 21: // Kill ourself.
diff --git a/src/bindings/scripts/scripts/zone/black_temple/boss_mother_shahraz.cpp b/src/bindings/scripts/scripts/zone/black_temple/boss_mother_shahraz.cpp
index 4b63b092c53..e459e1aa687 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/boss_mother_shahraz.cpp
+++ b/src/bindings/scripts/scripts/zone/black_temple/boss_mother_shahraz.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -276,7 +276,7 @@ struct TRINITY_DLL_DECL boss_shahrazAI : public ScriptedAI
}else SaberTimer -= diff;
//Enrage
- if(!m_creature->HasAura(SPELL_BERSERK, 0))
+ if(!m_creature->HasAura(SPELL_BERSERK))
if(EnrageTimer < diff)
{
DoCast(m_creature, SPELL_BERSERK);
diff --git a/src/bindings/scripts/scripts/zone/black_temple/boss_reliquary_of_souls.cpp b/src/bindings/scripts/scripts/zone/black_temple/boss_reliquary_of_souls.cpp
index 76aa7196300..353a16fe0e7 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/boss_reliquary_of_souls.cpp
+++ b/src/bindings/scripts/scripts/zone/black_temple/boss_reliquary_of_souls.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/black_temple/boss_shade_of_akama.cpp b/src/bindings/scripts/scripts/zone/black_temple/boss_shade_of_akama.cpp
index 21227969cdf..00358be80f3 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/boss_shade_of_akama.cpp
+++ b/src/bindings/scripts/scripts/zone/black_temple/boss_shade_of_akama.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -291,7 +291,7 @@ struct TRINITY_DLL_DECL boss_shade_of_akamaAI : public ScriptedAI
debug_log("SD2: Increasing Death Count for Shade of Akama encounter");
++DeathCount;
- m_creature->RemoveSingleAuraFromStack(SPELL_SHADE_SOUL_CHANNEL_2, 0);
+ m_creature->RemoveAuraFromStack(SPELL_SHADE_SOUL_CHANNEL_2);
if(guid)
{
if(Sorcerers.empty())
@@ -346,7 +346,7 @@ struct TRINITY_DLL_DECL boss_shade_of_akamaAI : public ScriptedAI
std::list<Creature*> ChannelerList;
Trinity::AllCreaturesOfEntryInRange check(m_creature, CREATURE_CHANNELER, 50);
- Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(ChannelerList, check);
+ Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(m_creature, ChannelerList, check);
TypeContainerVisitor<Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange>, GridTypeMapContainer> visitor(searcher);
CellLock<GridReadGuard> cell_lock(cell, pair);
diff --git a/src/bindings/scripts/scripts/zone/black_temple/boss_supremus.cpp b/src/bindings/scripts/scripts/zone/black_temple/boss_supremus.cpp
index 994f3d500ad..0985e7b61e3 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/boss_supremus.cpp
+++ b/src/bindings/scripts/scripts/zone/black_temple/boss_supremus.cpp
@@ -153,7 +153,7 @@ struct TRINITY_DLL_DECL boss_supremusAI : public ScriptedAI
if (!UpdateVictim())
return;
- if(!m_creature->HasAura(SPELL_BERSERK, 0))
+ if(!m_creature->HasAura(SPELL_BERSERK))
{
if(BerserkTimer < diff)
DoCast(m_creature, SPELL_BERSERK);
@@ -276,7 +276,7 @@ struct TRINITY_DLL_DECL npc_volcanoAI : public ScriptedAI
}
else if(Eruption && ((boss_supremusAI*)Supremus->AI())->Phase1)
{
- m_creature->RemoveAura(SPELL_VOLCANIC_ERUPTION, 0);
+ m_creature->RemoveAura(SPELL_VOLCANIC_ERUPTION);
}
CheckTimer = 1500;
}else CheckTimer -= diff;
diff --git a/src/bindings/scripts/scripts/zone/black_temple/boss_teron_gorefiend.cpp b/src/bindings/scripts/scripts/zone/black_temple/boss_teron_gorefiend.cpp
index a1800a4a951..33a0f20a23e 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/boss_teron_gorefiend.cpp
+++ b/src/bindings/scripts/scripts/zone/black_temple/boss_teron_gorefiend.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -90,7 +90,7 @@ struct TRINITY_DLL_DECL mob_doom_blossomAI : public ScriptedAI
Despawn();
CheckTeronTimer = 5000;
- }else CheckTeronTimer -= diff;
+ }else CheckTeronTimer -= diff;
if(ShadowBoltTimer < diff && InCombat)
{
@@ -331,7 +331,7 @@ struct TRINITY_DLL_DECL boss_teron_gorefiendAI : public ScriptedAI
Unit* Ghost = NULL;
if(GhostGUID)
Ghost = Unit::GetUnit((*m_creature), GhostGUID);
- if(Ghost && Ghost->isAlive() && Ghost->HasAura(SPELL_SHADOW_OF_DEATH, 0))
+ if(Ghost && Ghost->isAlive() && Ghost->HasAura(SPELL_SHADOW_OF_DEATH))
{
/*float x,y,z;
Ghost->GetPosition(x,y,z);
@@ -487,7 +487,7 @@ struct TRINITY_DLL_DECL boss_teron_gorefiendAI : public ScriptedAI
RandomYellTimer = 50000 + rand()%51 * 1000;
}else RandomYellTimer -= diff;
- if(!m_creature->HasAura(SPELL_BERSERK, 0))
+ if(!m_creature->HasAura(SPELL_BERSERK))
{
if(EnrageTimer < diff)
{
diff --git a/src/bindings/scripts/scripts/zone/black_temple/boss_warlord_najentus.cpp b/src/bindings/scripts/scripts/zone/black_temple/boss_warlord_najentus.cpp
index 538c94decf2..9233cc53fca 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/boss_warlord_najentus.cpp
+++ b/src/bindings/scripts/scripts/zone/black_temple/boss_warlord_najentus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -95,7 +95,7 @@ struct TRINITY_DLL_DECL boss_najentusAI : public ScriptedAI
void SpellHit(Unit *caster, const SpellEntry *spell)
{
- if(spell->Id == SPELL_HURL_SPINE && m_creature->HasAura(SPELL_TIDAL_SHIELD, 0))
+ if(spell->Id == SPELL_HURL_SPINE && m_creature->HasAura(SPELL_TIDAL_SHIELD))
{
m_creature->RemoveAurasDueToSpell(SPELL_TIDAL_SHIELD);
m_creature->CastSpell(m_creature, SPELL_TIDAL_BURST, true);
@@ -116,7 +116,7 @@ struct TRINITY_DLL_DECL boss_najentusAI : public ScriptedAI
{
if(!SpineTargetGUID) return false;
Unit* target = Unit::GetUnit(*m_creature, SpineTargetGUID);
- if(target && target->HasAura(SPELL_IMPALING_SPINE, 1))
+ if(target && target->HasAura(SPELL_IMPALING_SPINE))
target->RemoveAurasDueToSpell(SPELL_IMPALING_SPINE);
SpineTargetGUID=0;
return true;
@@ -154,7 +154,7 @@ struct TRINITY_DLL_DECL boss_najentusAI : public ScriptedAI
SelectUnitList(target, 3, SELECT_TARGET_RANDOM, 80, true);
for(std::list<Unit*>::iterator i = target.begin(); i != target.end(); ++i)
m_creature->CastSpell(*i, 39835, true);
- NeedleSpineTimer = 20000+rand()%5000;
+ NeedleSpineTimer = 2000+rand()%1000;
}else NeedleSpineTimer -= diff;
if(SpecialYellTimer < diff)
@@ -199,7 +199,7 @@ bool GOHello_go_najentus_spine(Player *player, GameObject* _GO)
{
player->CastSpell(player, SPELL_CREATE_NAJENTUS_SPINE, true);
_GO->SetLootState(GO_NOT_READY);
- _GO->SetRespawnTime(0);
+ _GO->Delete();
}
return true;
}
diff --git a/src/bindings/scripts/scripts/zone/black_temple/def_black_temple.h b/src/bindings/scripts/scripts/zone/black_temple/def_black_temple.h
index 0d5bb184792..4779f92fa4d 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/def_black_temple.h
+++ b/src/bindings/scripts/scripts/zone/black_temple/def_black_temple.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/black_temple/illidari_council.cpp b/src/bindings/scripts/scripts/zone/black_temple/illidari_council.cpp
index bbf1c600f59..3c063ff30c5 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/illidari_council.cpp
+++ b/src/bindings/scripts/scripts/zone/black_temple/illidari_council.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/black_temple/instance_black_temple.cpp b/src/bindings/scripts/scripts/zone/black_temple/instance_black_temple.cpp
index 80a749faa12..43646746505 100644
--- a/src/bindings/scripts/scripts/zone/black_temple/instance_black_temple.cpp
+++ b/src/bindings/scripts/scripts/zone/black_temple/instance_black_temple.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -42,6 +42,9 @@ struct TRINITY_DLL_DECL instance_black_temple : public ScriptedInstance
{
instance_black_temple(Map *map) : ScriptedInstance(map) {Initialize();};
+ uint32 Encounters[ENCOUNTERS];
+ std::string str_data;
+
uint64 Najentus;
uint64 Akama; // This is the Akama that starts the Illidan encounter.
uint64 Akama_Shade; // This is the Akama that starts the Shade of Akama encounter.
@@ -68,9 +71,6 @@ struct TRINITY_DLL_DECL instance_black_temple : public ScriptedInstance
uint64 IllidanGate;
uint64 IllidanDoor[2];
- uint32 Encounters[ENCOUNTERS];
- std::string str_data;
-
void Initialize()
{
Najentus = 0;
@@ -131,7 +131,7 @@ struct TRINITY_DLL_DECL instance_black_temple : public ScriptedInstance
void OnCreatureCreate(Creature *creature, uint32 creature_entry)
{
- switch(creature_entry)
+ switch(creature->GetEntry())
{
case 22887: Najentus = creature->GetGUID(); break;
case 23089: Akama = creature->GetGUID(); break;
diff --git a/src/bindings/scripts/scripts/zone/blackrock_depths/blackrock_depths.cpp b/src/bindings/scripts/scripts/zone/blackrock_depths/blackrock_depths.cpp
index b16add3e46a..fa1b86da5c8 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_depths/blackrock_depths.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_depths/blackrock_depths.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
diff --git a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_ambassador_flamelash.cpp b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_ambassador_flamelash.cpp
index b0c4bafb290..bf698aff507 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_ambassador_flamelash.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_ambassador_flamelash.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_anubshiah.cpp b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_anubshiah.cpp
index ad9330528b9..7cc38998a9e 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_anubshiah.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_anubshiah.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_emperor_dagran_thaurissan.cpp b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_emperor_dagran_thaurissan.cpp
index 978f4d8e9d7..e5b279d65ef 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_emperor_dagran_thaurissan.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_emperor_dagran_thaurissan.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,12 +23,12 @@ EndScriptData */
#include "precompiled.h"
+#define SAY_AGGRO -1230001
+#define SAY_SLAY -1230002
+
#define SPELL_HANDOFTHAURISSAN 17492
#define SPELL_AVATAROFFLAME 15636
-#define SAY_AGGRO "Come to aid the Throne!"
-#define SAY_SLAY "Hail to the king, baby!"
-
struct TRINITY_DLL_DECL boss_draganthaurissanAI : public ScriptedAI
{
boss_draganthaurissanAI(Creature *c) : ScriptedAI(c) {}
@@ -46,12 +46,12 @@ struct TRINITY_DLL_DECL boss_draganthaurissanAI : public ScriptedAI
void Aggro(Unit *who)
{
- DoYell(SAY_AGGRO,LANG_UNIVERSAL,NULL);
+ DoScriptText(SAY_AGGRO, m_creature);
}
void KilledUnit(Unit* victim)
{
- DoYell(SAY_SLAY, LANG_UNIVERSAL, NULL);
+ DoScriptText(SAY_SLAY, m_creature);
}
void UpdateAI(const uint32 diff)
@@ -62,9 +62,8 @@ struct TRINITY_DLL_DECL boss_draganthaurissanAI : public ScriptedAI
if (HandOfThaurissan_Timer < diff)
{
- Unit* target = NULL;
- target = SelectUnit(SELECT_TARGET_RANDOM,0);
- if (target) DoCast(target,SPELL_HANDOFTHAURISSAN);
+ if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM,0))
+ DoCast(target,SPELL_HANDOFTHAURISSAN);
//3 Hands of Thaurissan will be casted
//if (Counter < 3)
@@ -89,6 +88,7 @@ struct TRINITY_DLL_DECL boss_draganthaurissanAI : public ScriptedAI
DoMeleeAttackIfReady();
}
};
+
CreatureAI* GetAI_boss_draganthaurissan(Creature *_Creature)
{
return new boss_draganthaurissanAI (_Creature);
diff --git a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_general_angerforge.cpp b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_general_angerforge.cpp
index 80df7fec20b..c0ea7cac901 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_general_angerforge.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_general_angerforge.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_gorosh_the_dervish.cpp b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_gorosh_the_dervish.cpp
index 25367c6f4dd..3fd45e6eed7 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_gorosh_the_dervish.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_gorosh_the_dervish.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_grizzle.cpp b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_grizzle.cpp
index 389b2bc5b4d..df109c24001 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_grizzle.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_grizzle.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,6 +23,8 @@ EndScriptData */
#include "precompiled.h"
+#define EMOTE_GENERIC_FRENZY_KILL -1000001
+
#define SPELL_GROUNDTREMOR 6524
#define SPELL_FRENZY 28371
@@ -62,7 +64,7 @@ struct TRINITY_DLL_DECL boss_grizzleAI : public ScriptedAI
if (Frenzy_Timer < diff)
{
DoCast(m_creature,SPELL_FRENZY);
- DoTextEmote("goes into a killing frenzy!",NULL);
+ DoScriptText(EMOTE_GENERIC_FRENZY_KILL, m_creature);
Frenzy_Timer = 15000;
}else Frenzy_Timer -= diff;
diff --git a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_high_interrogator_gerstahn.cpp b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_high_interrogator_gerstahn.cpp
index 422f0f25532..5921cc8419a 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_high_interrogator_gerstahn.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_high_interrogator_gerstahn.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_magmus.cpp b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_magmus.cpp
index 25f7f890e3f..c4230b5f557 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_magmus.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_magmus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_moira_bronzebeard.cpp b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_moira_bronzebeard.cpp
index 26c72404355..bc90aeb17cf 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_depths/boss_moira_bronzebeard.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_depths/boss_moira_bronzebeard.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_depths/instance_blackrock_depths.cpp b/src/bindings/scripts/scripts/zone/blackrock_depths/instance_blackrock_depths.cpp
index 2d5615779a7..e056f732158 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_depths/instance_blackrock_depths.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_depths/instance_blackrock_depths.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_drakkisath.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_drakkisath.cpp
index 45e5184e1d3..69ca2482357 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_drakkisath.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_drakkisath.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_gyth.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_gyth.cpp
index 09656309e5c..919643a34e9 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_gyth.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_gyth.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_halycon.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_halycon.cpp
index 61ce2ea2cc4..81e872b1ffa 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_halycon.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_halycon.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_highlord_omokk.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_highlord_omokk.cpp
index 6069bad85ed..79ebd4fa098 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_highlord_omokk.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_highlord_omokk.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_mother_smolderweb.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_mother_smolderweb.cpp
index 7188ae17770..c2df5796f48 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_mother_smolderweb.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_mother_smolderweb.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_overlord_wyrmthalak.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_overlord_wyrmthalak.cpp
index 85113c9a1ab..ecb0a71db82 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_overlord_wyrmthalak.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_overlord_wyrmthalak.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -103,8 +103,10 @@ struct TRINITY_DLL_DECL boss_overlordwyrmthalakAI : public ScriptedAI
target = SelectUnit(SELECT_TARGET_RANDOM,0);
SummonedCreature = m_creature->SummonCreature(9216,ADD_1X,ADD_1Y,ADD_1Z,ADD_1O,TEMPSUMMON_TIMED_DESPAWN,300000);
+ if(SummonedCreature)
((CreatureAI*)SummonedCreature->AI())->AttackStart(target);
SummonedCreature = m_creature->SummonCreature(9268,ADD_2X,ADD_2Y,ADD_2Z,ADD_2O,TEMPSUMMON_TIMED_DESPAWN,300000);
+ if(SummonedCreature)
((CreatureAI*)SummonedCreature->AI())->AttackStart(target);
Summoned = true;
}
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_pyroguard_emberseer.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_pyroguard_emberseer.cpp
index ea320b40b4d..532a719bbe3 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_pyroguard_emberseer.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_pyroguard_emberseer.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_quartermaster_zigris.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_quartermaster_zigris.cpp
index b4b14ac5f89..af158d97de6 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_quartermaster_zigris.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_quartermaster_zigris.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_rend_blackhand.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_rend_blackhand.cpp
index ee41701667b..d43de67fa56 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_rend_blackhand.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_rend_blackhand.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_shadow_hunter_voshgajin.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_shadow_hunter_voshgajin.cpp
index 7a1080226ea..6563aa8a929 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_shadow_hunter_voshgajin.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_shadow_hunter_voshgajin.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_the_beast.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_the_beast.cpp
index 6eead9d4162..c9ba2a77921 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_the_beast.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_the_beast.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_warmaster_voone.cpp b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_warmaster_voone.cpp
index 625bbc0d28a..d701edc6d40 100644
--- a/src/bindings/scripts/scripts/zone/blackrock_spire/boss_warmaster_voone.cpp
+++ b/src/bindings/scripts/scripts/zone/blackrock_spire/boss_warmaster_voone.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_broodlord_lashlayer.cpp b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_broodlord_lashlayer.cpp
index 5c0b2a8d2f2..b59be12f8eb 100644
--- a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_broodlord_lashlayer.cpp
+++ b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_broodlord_lashlayer.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_chromaggus.cpp b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_chromaggus.cpp
index 8e89a3aeed4..4e54fe2ce35 100644
--- a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_chromaggus.cpp
+++ b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_chromaggus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -258,11 +258,11 @@ struct TRINITY_DLL_DECL boss_chromaggusAI : public ScriptedAI
DoCast(pUnit, SpellAfflict, true);
//Chromatic mutation if target is effected by all afflictions
- if (pUnit->HasAura(SPELL_BROODAF_BLUE,0)
- && pUnit->HasAura(SPELL_BROODAF_BLACK,0)
- && pUnit->HasAura(SPELL_BROODAF_RED,0)
- && pUnit->HasAura(SPELL_BROODAF_BRONZE,0)
- && pUnit->HasAura(SPELL_BROODAF_GREEN,0))
+ if (pUnit->HasAura(SPELL_BROODAF_BLUE)
+ && pUnit->HasAura(SPELL_BROODAF_BLACK)
+ && pUnit->HasAura(SPELL_BROODAF_RED)
+ && pUnit->HasAura(SPELL_BROODAF_BRONZE)
+ && pUnit->HasAura(SPELL_BROODAF_GREEN))
{
//target->RemoveAllAuras();
//DoCast(target,SPELL_CHROMATIC_MUT_1);
diff --git a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_ebonroc.cpp b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_ebonroc.cpp
index c30485ac327..54348dd86c4 100644
--- a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_ebonroc.cpp
+++ b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_ebonroc.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -76,7 +76,7 @@ struct TRINITY_DLL_DECL boss_ebonrocAI : public ScriptedAI
ShadowOfEbonroc_Timer = 25000 + rand()%10000;
}else ShadowOfEbonroc_Timer -= diff;
- if (m_creature->getVictim()->HasAura(SPELL_SHADOWOFEBONROC,0))
+ if (m_creature->getVictim()->HasAura(SPELL_SHADOWOFEBONROC))
{
if (Heal_Timer < diff)
{
diff --git a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_firemaw.cpp b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_firemaw.cpp
index 64a01b228f0..dfae4f31662 100644
--- a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_firemaw.cpp
+++ b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_firemaw.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_flamegor.cpp b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_flamegor.cpp
index 49dfdaa896f..def9af062be 100644
--- a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_flamegor.cpp
+++ b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_flamegor.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_nefarian.cpp b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_nefarian.cpp
index d91714c0246..4abe9265828 100644
--- a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_nefarian.cpp
+++ b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_nefarian.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_razorgore.cpp b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_razorgore.cpp
index 1da3fb554df..ff29427664f 100644
--- a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_razorgore.cpp
+++ b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_razorgore.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -104,7 +104,7 @@ struct TRINITY_DLL_DECL boss_razorgoreAI : public ScriptedAI
}else Conflagration_Timer -= diff;
// Aura Check. If the gamer is affected by confliguration we attack a random gamer.
- if (m_creature->getVictim()->HasAura(SPELL_CONFLAGRATION,0))
+ if (m_creature->getVictim()->HasAura(SPELL_CONFLAGRATION))
{
Unit* target = NULL;
target = SelectUnit(SELECT_TARGET_RANDOM,1);
diff --git a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_vaelastrasz.cpp b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_vaelastrasz.cpp
index f0048e7a4fa..c8fecdae893 100644
--- a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_vaelastrasz.cpp
+++ b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_vaelastrasz.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_victor_nefarius.cpp b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_victor_nefarius.cpp
index ea6751605c0..03543bf9874 100644
--- a/src/bindings/scripts/scripts/zone/blackwing_lair/boss_victor_nefarius.cpp
+++ b/src/bindings/scripts/scripts/zone/blackwing_lair/boss_victor_nefarius.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blackwing_lair/instance_blackwing_lair.cpp b/src/bindings/scripts/scripts/zone/blackwing_lair/instance_blackwing_lair.cpp
index ddd9e8b9aa3..97bf717589a 100644
--- a/src/bindings/scripts/scripts/zone/blackwing_lair/instance_blackwing_lair.cpp
+++ b/src/bindings/scripts/scripts/zone/blackwing_lair/instance_blackwing_lair.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blades_edge_mountains/blades_edge_mountains.cpp b/src/bindings/scripts/scripts/zone/blades_edge_mountains/blades_edge_mountains.cpp
index 3617ae8cc14..03c3a57568c 100644
--- a/src/bindings/scripts/scripts/zone/blades_edge_mountains/blades_edge_mountains.cpp
+++ b/src/bindings/scripts/scripts/zone/blades_edge_mountains/blades_edge_mountains.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -17,7 +17,7 @@
/* ScriptData
SDName: Blades_Edge_Mountains
SD%Complete: 90
-SDComment: Quest support: 10503, 10504, 10556, 10609, 10682, 10980. Ogri'la->Skettis Flight. (npc_daranelle needs bit more work before consider complete)
+SDComment: Quest support: 10503, 10504, 10556, 10609, 10682, 10821, 10980. Ogri'la->Skettis Flight. (npc_daranelle needs bit more work before consider complete)
SDCategory: Blade's Edge Mountains
EndScriptData */
@@ -28,10 +28,20 @@ npc_daranelle
npc_overseer_nuaar
npc_saikkal_the_elder
npc_skyguard_handler_irena
+go_legion_obelisk
EndContentData */
#include "precompiled.h"
+//Support for quest: You're Fired! (10821)
+bool obelisk_one, obelisk_two, obelisk_three, obelisk_four, obelisk_five;
+
+#define LEGION_OBELISK_ONE 185193
+#define LEGION_OBELISK_TWO 185195
+#define LEGION_OBELISK_THREE 185196
+#define LEGION_OBELISK_FOUR 185197
+#define LEGION_OBELISK_FIVE 185198
+
/*######
## mobs_bladespire_ogre
######*/
@@ -96,14 +106,9 @@ struct TRINITY_DLL_DECL mobs_nether_drakeAI : public ScriptedAI
void Reset()
{
- NihilSpeech_Timer = 2000;
IsNihil = false;
- if( m_creature->GetEntry() == ENTRY_NIHIL )
- {
- m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
- IsNihil = true;
- }
- NihilSpeech_Phase = 1;
+ NihilSpeech_Timer = 3000;
+ NihilSpeech_Phase = 0;
ArcaneBlast_Timer = 7500;
ManaBurn_Timer = 10000;
@@ -112,138 +117,115 @@ struct TRINITY_DLL_DECL mobs_nether_drakeAI : public ScriptedAI
void Aggro(Unit* who) { }
+ void MoveInLineOfSight(Unit *who)
+ {
+ if (m_creature->HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE))
+ return;
+
+ ScriptedAI::MoveInLineOfSight(who);
+ }
+
+ //in case creature was not summoned (not expected)
+ void MovementInform(uint32 type, uint32 id)
+ {
+ if (type != POINT_MOTION_TYPE)
+ return;
+
+ if (id == 0)
+ {
+ m_creature->setDeathState(JUST_DIED);
+ m_creature->RemoveCorpse();
+ m_creature->SetHealth(0);
+ }
+ }
+
void SpellHit(Unit *caster, const SpellEntry *spell)
{
- if( spell->Id == SPELL_T_PHASE_MODULATOR && caster->GetTypeId() == TYPEID_PLAYER )
+ if (spell->Id == SPELL_T_PHASE_MODULATOR && caster->GetTypeId() == TYPEID_PLAYER)
{
- uint32 cEntry = 0;
+ const uint32 entry_list[4] = {ENTRY_PROTO, ENTRY_ADOLE, ENTRY_MATUR, ENTRY_NIHIL};
+ int cid = rand()%(4-1);
+
+ if (entry_list[cid] == m_creature->GetEntry())
+ ++cid;
- switch( m_creature->GetEntry() )
+ //we are nihil, so say before transform
+ if (m_creature->GetEntry() == ENTRY_NIHIL)
{
- case ENTRY_WHELP:
- switch(rand()%4)
- {
- case 0: cEntry = ENTRY_PROTO; break;
- case 1: cEntry = ENTRY_ADOLE; break;
- case 2: cEntry = ENTRY_MATUR; break;
- case 3: cEntry = ENTRY_NIHIL; break;
- }
- break;
- case ENTRY_PROTO:
- switch(rand()%3)
- {
- case 0: cEntry = ENTRY_ADOLE; break;
- case 1: cEntry = ENTRY_MATUR; break;
- case 2: cEntry = ENTRY_NIHIL; break;
- }
- break;
- case ENTRY_ADOLE:
- switch(rand()%3)
- {
- case 0: cEntry = ENTRY_PROTO; break;
- case 1: cEntry = ENTRY_MATUR; break;
- case 2: cEntry = ENTRY_NIHIL; break;
- }
- break;
- case ENTRY_MATUR:
- switch(rand()%3)
- {
- case 0: cEntry = ENTRY_PROTO; break;
- case 1: cEntry = ENTRY_ADOLE; break;
- case 2: cEntry = ENTRY_NIHIL; break;
- }
- break;
- case ENTRY_NIHIL:
- if( NihilSpeech_Phase )
- {
- DoScriptText(SAY_NIHIL_INTERRUPT, m_creature);
- IsNihil = false;
- switch(rand()%3)
- {
- case 0: cEntry = ENTRY_PROTO; break;
- case 1: cEntry = ENTRY_ADOLE; break;
- case 2: cEntry = ENTRY_MATUR; break;
- }
- }
- break;
+ DoScriptText(SAY_NIHIL_INTERRUPT, m_creature);
+ m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
+ IsNihil = false;
}
- if( cEntry )
+ if (m_creature->UpdateEntry(entry_list[cid]))
{
- m_creature->UpdateEntry(cEntry);
-
- if( cEntry == ENTRY_NIHIL )
+ if (entry_list[cid] == ENTRY_NIHIL)
{
- m_creature->InterruptNonMeleeSpells(true);
- m_creature->RemoveAllAuras();
- m_creature->DeleteThreatList();
- m_creature->CombatStop();
- InCombat = false;
- Reset();
- }
+ EnterEvadeMode();
+ m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
+ IsNihil = true;
+ }else
+ AttackStart(caster);
}
}
}
void UpdateAI(const uint32 diff)
{
- if( IsNihil )
+ if (IsNihil)
{
- if( NihilSpeech_Phase )
+ if (NihilSpeech_Timer <= diff)
{
- if(NihilSpeech_Timer <= diff)
+ switch(NihilSpeech_Phase)
{
- switch( NihilSpeech_Phase )
- {
- case 1:
- DoScriptText(SAY_NIHIL_1, m_creature);
- ++NihilSpeech_Phase;
- break;
- case 2:
- DoScriptText(SAY_NIHIL_2, m_creature);
- ++NihilSpeech_Phase;
- break;
- case 3:
- DoScriptText(SAY_NIHIL_3, m_creature);
- ++NihilSpeech_Phase;
- break;
- case 4:
- DoScriptText(SAY_NIHIL_4, m_creature);
- ++NihilSpeech_Phase;
- break;
- case 5:
- m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- // + MOVEMENTFLAG_LEVITATING
- m_creature->AddUnitMovementFlag(MOVEMENTFLAG_ONTRANSPORT);
- //then take off to random location. creature is initially summoned, so don't bother do anything else.
- m_creature->GetMotionMaster()->MovePoint(0, m_creature->GetPositionX()+100, m_creature->GetPositionY(), m_creature->GetPositionZ()+100);
- NihilSpeech_Phase = 0;
- break;
- }
- NihilSpeech_Timer = 5000;
- }else NihilSpeech_Timer -=diff;
- }
- return; //anything below here is not interesting for Nihil, so skip it
+ case 0:
+ DoScriptText(SAY_NIHIL_1, m_creature);
+ ++NihilSpeech_Phase;
+ break;
+ case 1:
+ DoScriptText(SAY_NIHIL_2, m_creature);
+ ++NihilSpeech_Phase;
+ break;
+ case 2:
+ DoScriptText(SAY_NIHIL_3, m_creature);
+ ++NihilSpeech_Phase;
+ break;
+ case 3:
+ DoScriptText(SAY_NIHIL_4, m_creature);
+ ++NihilSpeech_Phase;
+ break;
+ case 4:
+ m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ //take off to location above
+ m_creature->GetMotionMaster()->MovePoint(0, m_creature->GetPositionX()+50.0f, m_creature->GetPositionY(), m_creature->GetPositionZ()+50.0f);
+ ++NihilSpeech_Phase;
+ break;
+ }
+ NihilSpeech_Timer = 5000;
+ }else NihilSpeech_Timer -=diff;
+
+ //anything below here is not interesting for Nihil, so skip it
+ return;
}
- if( !UpdateVictim() )
+ if (!UpdateVictim() )
return;
- if( IntangiblePresence_Timer <= diff )
+ if (IntangiblePresence_Timer <= diff)
{
DoCast(m_creature->getVictim(),SPELL_INTANGIBLE_PRESENCE);
IntangiblePresence_Timer = 15000+rand()%15000;
}else IntangiblePresence_Timer -= diff;
- if( ManaBurn_Timer <= diff )
+ if (ManaBurn_Timer <= diff)
{
Unit* target = m_creature->getVictim();
- if( target && target->getPowerType() == POWER_MANA )
+ if (target && target->getPowerType() == POWER_MANA)
DoCast(target,SPELL_MANA_BURN);
ManaBurn_Timer = 8000+rand()%8000;
}else ManaBurn_Timer -= diff;
- if( ArcaneBlast_Timer <= diff )
+ if (ArcaneBlast_Timer <= diff)
{
DoCast(m_creature->getVictim(),SPELL_ARCANE_BLAST);
ArcaneBlast_Timer = 2500+rand()%5000;
@@ -252,6 +234,7 @@ struct TRINITY_DLL_DECL mobs_nether_drakeAI : public ScriptedAI
DoMeleeAttackIfReady();
}
};
+
CreatureAI* GetAI_mobs_nether_drake(Creature *_Creature)
{
return new mobs_nether_drakeAI (_Creature);
@@ -261,27 +244,23 @@ CreatureAI* GetAI_mobs_nether_drake(Creature *_Creature)
## npc_daranelle
######*/
-#define SAY_DARANELLE -1000401
+#define SAY_SPELL_INFLUENCE -1000174
struct TRINITY_DLL_DECL npc_daranelleAI : public ScriptedAI
{
npc_daranelleAI(Creature *c) : ScriptedAI(c) {}
- void Reset()
- {
- }
+ void Reset() { }
- void Aggro(Unit* who)
- {
- }
+ void Aggro(Unit* who) { }
void MoveInLineOfSight(Unit *who)
{
if (who->GetTypeId() == TYPEID_PLAYER)
{
- if(who->HasAura(36904,0))
+ if (who->HasAura(36904) && m_creature->IsWithinDistInMap(who, 10.0f))
{
- DoScriptText(SAY_DARANELLE, m_creature, who);
+ DoScriptText(SAY_SPELL_INFLUENCE, m_creature, who);
//TODO: Move the below to updateAI and run if this statement == true
((Player*)who)->KilledMonster(21511, m_creature->GetGUID());
((Player*)who)->RemoveAurasDueToSpell(36904);
@@ -301,12 +280,10 @@ CreatureAI* GetAI_npc_daranelle(Creature *_Creature)
## npc_overseer_nuaar
######*/
-#define GOSSIP_HON "Overseer, I am here to negotiate on behalf of the Cenarion Expedition."
-
bool GossipHello_npc_overseer_nuaar(Player *player, Creature *_Creature)
{
if (player->GetQuestStatus(10682) == QUEST_STATUS_INCOMPLETE)
- player->ADD_GOSSIP_ITEM( 0, GOSSIP_HON, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
+ player->ADD_GOSSIP_ITEM( 0, "Overseer, I am here to negotiate on behalf of the Cenarion Expedition.", GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
player->SEND_GOSSIP_MENU(10532, _Creature->GetGUID());
@@ -327,13 +304,10 @@ bool GossipSelect_npc_overseer_nuaar(Player *player, Creature *_Creature, uint32
## npc_saikkal_the_elder
######*/
-#define GOSSIP_HSTE "Yes... yes, it's me."
-#define GOSSIP_SSTE "Yes elder. Tell me more of the book."
-
bool GossipHello_npc_saikkal_the_elder(Player *player, Creature *_Creature)
{
if (player->GetQuestStatus(10980) == QUEST_STATUS_INCOMPLETE)
- player->ADD_GOSSIP_ITEM( 0, GOSSIP_HSTE, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
+ player->ADD_GOSSIP_ITEM( 0, "Yes... yes, it's me.", GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
player->SEND_GOSSIP_MENU(10794, _Creature->GetGUID());
@@ -345,7 +319,7 @@ bool GossipSelect_npc_saikkal_the_elder(Player *player, Creature *_Creature, uin
switch (action)
{
case GOSSIP_ACTION_INFO_DEF+1:
- player->ADD_GOSSIP_ITEM( 0, GOSSIP_SSTE, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2);
+ player->ADD_GOSSIP_ITEM( 0, "Yes elder. Tell me more of the book.", GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2);
player->SEND_GOSSIP_MENU(10795, _Creature->GetGUID());
break;
case GOSSIP_ACTION_INFO_DEF+2:
@@ -380,18 +354,54 @@ bool GossipSelect_npc_skyguard_handler_irena(Player *player, Creature *_Creature
if (action == GOSSIP_ACTION_INFO_DEF+1)
{
player->CLOSE_GOSSIP_MENU();
-
- std::vector<uint32> nodes;
-
- nodes.resize(2);
- nodes[0] = 172; //from ogri'la
- nodes[1] = 171; //end at skettis
- player->ActivateTaxiPathTo(nodes); //TaxiPath 706
+ player->CastSpell(player,41278,true); //TaxiPath 706
}
return true;
}
/*######
+## go_legion_obelisk
+######*/
+
+bool GOHello_go_legion_obelisk(Player *player, GameObject* _GO)
+{
+ if ( player->GetQuestStatus(10821) == QUEST_STATUS_INCOMPLETE )
+ {
+ switch( _GO->GetEntry() )
+ {
+ case LEGION_OBELISK_ONE:
+ obelisk_one = true;
+ break;
+ case LEGION_OBELISK_TWO:
+ obelisk_two = true;
+ break;
+ case LEGION_OBELISK_THREE:
+ obelisk_three = true;
+ break;
+ case LEGION_OBELISK_FOUR:
+ obelisk_four = true;
+ break;
+ case LEGION_OBELISK_FIVE:
+ obelisk_five = true;
+ break;
+ }
+
+ if ( obelisk_one == true && obelisk_two == true && obelisk_three == true && obelisk_four == true && obelisk_five == true )
+ {
+ _GO->SummonCreature(19963,2943.40f,4778.20f,284.49f,0.94f,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,120000);
+ //reset global var
+ obelisk_one = false;
+ obelisk_two = false;
+ obelisk_three = false;
+ obelisk_four = false;
+ obelisk_five = false;
+ }
+ }
+
+ return true;
+}
+
+/*######
## AddSC
######*/
@@ -425,6 +435,11 @@ void AddSC_blades_edge_mountains()
newscript->pGossipHello = &GossipHello_npc_saikkal_the_elder;
newscript->pGossipSelect = &GossipSelect_npc_saikkal_the_elder;
newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="go_legion_obelisk";
+ newscript->pGOHello = &GOHello_go_legion_obelisk;
+ newscript->RegisterSelf();
newscript = new Script;
newscript->Name="npc_skyguard_handler_irena";
diff --git a/src/bindings/scripts/scripts/zone/blasted_lands/blasted_lands.cpp b/src/bindings/scripts/scripts/zone/blasted_lands/blasted_lands.cpp
index 954792a1044..432633e90fe 100644
--- a/src/bindings/scripts/scripts/zone/blasted_lands/blasted_lands.cpp
+++ b/src/bindings/scripts/scripts/zone/blasted_lands/blasted_lands.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/blasted_lands/boss_kruul.cpp b/src/bindings/scripts/scripts/zone/blasted_lands/boss_kruul.cpp
index f186a58252c..7516930285e 100644
--- a/src/bindings/scripts/scripts/zone/blasted_lands/boss_kruul.cpp
+++ b/src/bindings/scripts/scripts/zone/blasted_lands/boss_kruul.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/bloodmyst_isle/bloodmyst_isle.cpp b/src/bindings/scripts/scripts/zone/bloodmyst_isle/bloodmyst_isle.cpp
index e7ce3b95c42..79d7b19e108 100644
--- a/src/bindings/scripts/scripts/zone/bloodmyst_isle/bloodmyst_isle.cpp
+++ b/src/bindings/scripts/scripts/zone/bloodmyst_isle/bloodmyst_isle.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -81,7 +81,7 @@ CreatureAI* GetAI_mob_webbed_creature(Creature *_Creature)
bool GossipHello_npc_captured_sunhawk_agent(Player *player, Creature *_Creature)
{
- if (player->HasAura(31609,1) && player->GetQuestStatus(9756) == QUEST_STATUS_INCOMPLETE)
+ if (player->HasAura(31609) && player->GetQuestStatus(9756) == QUEST_STATUS_INCOMPLETE)
{
player->ADD_GOSSIP_ITEM( 0, "[PH] ", GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
player->SEND_GOSSIP_MENU(9136, _Creature->GetGUID());
diff --git a/src/bindings/scripts/scripts/zone/borean_tundra/borean_tundra.cpp b/src/bindings/scripts/scripts/zone/borean_tundra/borean_tundra.cpp
new file mode 100644
index 00000000000..c776c1f9271
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/borean_tundra/borean_tundra.cpp
@@ -0,0 +1,105 @@
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Borean_Tundra
+SD%Complete: 100
+SDComment:
+SDCategory: Borean Tundra
+EndScriptData */
+
+/* ContentData
+npc_tiare
+npc_surristrasz
+EndContentData */
+
+#include "precompiled.h"
+
+/*######
+## npc_tiare
+######*/
+
+#define GOSSIP_ITEM_TELEPORT "Teleport me to Amber Ledge, please."
+
+bool GossipHello_npc_tiare(Player *player, Creature *_Creature)
+{
+ player->ADD_GOSSIP_ITEM(0, GOSSIP_ITEM_TELEPORT, GOSSIP_SENDER_MAIN, GOSSIP_OPTION_GOSSIP);
+ player->SEND_GOSSIP_MENU(_Creature->GetNpcTextId(), _Creature->GetGUID());
+ return true;
+}
+
+bool GossipSelect_npc_tiare(Player *player, Creature *_Creature, uint32 sender, uint32 action)
+{
+ if (action == GOSSIP_OPTION_GOSSIP)
+ {
+ player->CLOSE_GOSSIP_MENU();
+ player->CastSpell(player,50135,true);
+ }
+ return true;
+}
+
+/*######
+## npc_surristrasz
+######*/
+
+#define GOSSIP_ITEM_FREE_FLIGHT "I'd like passage to the Transitus Shield."
+#define GOSSIP_ITEM_FLIGHT "May I use a drake to fly elsewhere?"
+
+bool GossipHello_npc_surristrasz(Player *player, Creature *_Creature)
+{
+ if (_Creature->isQuestGiver())
+ player->PrepareQuestMenu(_Creature->GetGUID());
+
+ if (_Creature->isTaxi())
+ {
+ player->ADD_GOSSIP_ITEM(0, GOSSIP_ITEM_FREE_FLIGHT, GOSSIP_SENDER_MAIN, GOSSIP_OPTION_GOSSIP);
+ player->ADD_GOSSIP_ITEM(2, GOSSIP_ITEM_FLIGHT, GOSSIP_SENDER_MAIN, GOSSIP_OPTION_TAXIVENDOR);
+ }
+
+ player->SEND_GOSSIP_MENU(_Creature->GetNpcTextId(), _Creature->GetGUID());
+ return true;
+}
+
+bool GossipSelect_npc_surristrasz(Player *player, Creature *_Creature, uint32 sender, uint32 action)
+{
+ if (action == GOSSIP_OPTION_GOSSIP)
+ {
+ player->CLOSE_GOSSIP_MENU();
+ player->CastSpell(player,46064,true); //TaxiPath 795 (amber to coldarra)
+ }
+ if (action == GOSSIP_OPTION_TAXIVENDOR)
+ {
+ player->GetSession()->SendTaxiMenu(_Creature);
+ }
+ return true;
+}
+
+void AddSC_borean_tundra()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name = "npc_tiare";
+ newscript->pGossipHello = &GossipHello_npc_tiare;
+ newscript->pGossipSelect = &GossipSelect_npc_tiare;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name = "npc_surristrasz";
+ newscript->pGossipHello = &GossipHello_npc_surristrasz;
+ newscript->pGossipSelect = &GossipSelect_npc_surristrasz;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/burning_steppes/burning_steppes.cpp b/src/bindings/scripts/scripts/zone/burning_steppes/burning_steppes.cpp
index 0458e495959..b16b6551c78 100644
--- a/src/bindings/scripts/scripts/zone/burning_steppes/burning_steppes.cpp
+++ b/src/bindings/scripts/scripts/zone/burning_steppes/burning_steppes.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -52,7 +52,7 @@ struct TRINITY_DLL_DECL npc_ragged_johnAI : public ScriptedAI
void MoveInLineOfSight(Unit *who)
{
- if( who->HasAura(16468,0) )
+ if( who->HasAura(16468) )
{
if( who->GetTypeId() == TYPEID_PLAYER && m_creature->IsWithinDistInMap(who, 15) && who->isInAccessiblePlaceFor(m_creature) )
{
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_epoch.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_epoch.cpp
new file mode 100644
index 00000000000..de2ff9b93fd
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_epoch.cpp
@@ -0,0 +1,86 @@
+/* Script Data Start
+SDName: Boss epoch
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_CURSE_OF_EXERTION 52772
+#define SPELL_TIME_WARP 52766 //Time slows down, reducing attack, casting and movement speed by 70% for 6 sec.
+#define SPELL_TIME_STOP 58848 //Stops time in a 50 yard sphere for 2 sec.
+#define SPELL_WOUNDING_STRIKE_N 52771 //Used only on the tank
+#define SPELL_WOUNDING_STRIKE_H 58830
+
+//Say
+#define SAY_INTRO -1595000 //"Prince Arthas Menethil, on this day, a powerful darkness has taken hold of your soul. The death you are destined to visit upon others will this day be your own."
+#define SAY_AGGRO -1595001 //"We'll see about that, young prince."
+#define SAY_TIME_WARP_1 -1595002 //"Tick tock, tick tock..."
+#define SAY_TIME_WARP_2 -1595003 //"Not quick enough!"
+#define SAY_TIME_WARP_3 -1595004 //"Let's get this over with. "
+#define SAY_SLAY_1 -1595005 //"There is no future for you."
+#define SAY_SLAY_2 -1595006 //"This is the hour of our greatest triumph!"
+#define SAY_SLAY_3 -1595007 //"You were destined to fail. "
+#define SAY_DEATH -1595008 //"*gurgles*"
+
+struct TRINITY_DLL_DECL boss_epochAI : public ScriptedAI
+{
+ boss_epochAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0:DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1:DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2:DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_epoch(Creature *_Creature)
+{
+ return new boss_epochAI (_Creature);
+}
+
+void AddSC_boss_epoch()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_epoch";
+ newscript->GetAI = GetAI_boss_epoch;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_mal_ganis.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_mal_ganis.cpp
new file mode 100644
index 00000000000..12cbb5f27a3
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_mal_ganis.cpp
@@ -0,0 +1,123 @@
+/* Script Data Start
+SDName: Boss mal_ganis
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_mal_ganis' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_CARRION_SWARM_N 52720 //A cresting wave of chaotic magic splashes over enemies in front of the caster, dealing 3230 to 3570 Shadow damage and 380 to 420 Shadow damage every 3 sec. for 15 sec.
+#define SPELL_CARRION_SWARM_H 58852
+#define SPELL_MIND_BLAST_N 52722 //Inflicts 4163 to 4837 Shadow damage to an enemy.
+#define SPELL_MIND_BLAST_H 58850
+#define SPELL_SLEEP 52721 //Puts an enemy to sleep for up to 10 sec. Any damage caused will awaken the target.
+#define SPELL_VAMPIRIC_TOUCH 52723 //Heals the caster for half the damage dealt by a melee attack.
+
+//Yell Mal'ganis
+#define SAY_INTRO_1 -1595009
+#define SAY_INTRO_2 -1595010
+#define SAY_OUTRO -1595011
+#define SAY_AGGRO -1595012
+#define SAY_KILL_1 -1595013
+#define SAY_KILL_2 -1595014
+#define SAY_KILL_3 -1595015
+#define SAY_SLAY_1 -1595016
+#define SAY_SLAY_2 -1595017
+#define SAY_SLAY_3 -1595018
+#define SAY_SLAY_4 -1595019
+#define SAY_SLEEP_1 -1595020
+#define SAY_SLEEP_2 -1595021
+#define SAY_30HEALTH -1595022
+#define SAY_15HEALTH -1595023
+#define SAY_ESCAPE_SPEECH_1 -1595024
+#define SAY_ESCAPE_SPEECH_2 -1595025
+
+struct TRINITY_DLL_DECL boss_mal_ganisAI : public ScriptedAI
+{
+ boss_mal_ganisAI(Creature *c) : ScriptedAI(c) {}
+
+ bool yelled,
+ yelled2,
+ yelled3;
+
+ void Reset()
+ {
+ yelled = false;
+ yelled2 = false;
+ yelled3 = false;
+ }
+
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ if(!yelled)
+ {
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 30)
+ {
+ DoScriptText(SAY_30HEALTH, m_creature);
+ yelled = true;
+ }
+ }
+
+ if(!yelled2)
+ {
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 15)
+ {
+ DoScriptText(SAY_15HEALTH, m_creature);
+ yelled2 = true;
+ }
+ }
+
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 1)
+ {
+ //Handle Escape Event
+ }
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%4)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ case 3: DoScriptText(SAY_SLAY_4, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_mal_ganis(Creature *_Creature)
+{
+ return new boss_mal_ganisAI (_Creature);
+}
+
+void AddSC_boss_mal_ganis()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_mal_ganis";
+ newscript->GetAI = GetAI_boss_mal_ganis;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_meathook.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_meathook.cpp
new file mode 100644
index 00000000000..187889cb053
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_meathook.cpp
@@ -0,0 +1,138 @@
+/* Script Data Start
+SDName: Boss meathook
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_meathook' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spell
+#define SPELL_CONSTRICTING_CHAINS_N 52696 //Encases the targets in chains, dealing 1800 Physical damage every 1 sec. and stunning the target for 5 sec.
+#define SPELL_CONSTRICTING_CHAINS_H 58823
+#define SPELL_DISEASE_EXPULSION_N 52666 //Meathook belches out a cloud of disease, dealing 1710 to 1890 Nature damage and interrupting the spell casting of nearby enemy targets for 4 sec.
+#define SPELL_DISEASE_EXPULSION_H 58824
+#define SPELL_FRENZY 58841 //Increases the caster's Physical damage by 10% for 30 sec.
+
+//Yell
+#define SAY_AGGRO -1595026
+#define SAY_SLAY_1 -1595027
+#define SAY_SLAY_2 -1595028
+#define SAY_SLAY_3 -1595029
+#define SAY_SPAWN -1595030
+#define SAY_DEATH -1595031
+
+struct TRINITY_DLL_DECL boss_meathookAI : public ScriptedAI
+{
+ boss_meathookAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 Chain_Timer,
+ Disease_Timer,
+ Frenzy_Timer;
+
+ void Reset()
+ {
+ Chain_Timer = 12000 + rand()%5000; //seen on video 13, 17, 15, 12, 16
+ Disease_Timer = 2000 + rand()%1000; //approx 3s
+ Frenzy_Timer = 20000 + rand()%10000; //made it up
+ }
+
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+
+ void AttackStart(Unit* who) {}
+
+ std::list <Unit*>pList;
+ void MoveInLineOfSight(Unit* who, const uint32 diff)
+ {
+ /*if (m_creature->isHostileTo(who))
+ {
+ pList.append(who);
+ }*/
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ if(Disease_Timer < diff)
+ {
+ DoCast(m_creature->getVictim(), SPELL_DISEASE_EXPULSION_N);
+ Disease_Timer = 1500 + rand()%2500;
+ }else Disease_Timer -= diff;
+
+ if(Frenzy_Timer < diff)
+ {
+ DoCast(m_creature->getVictim(), SPELL_FRENZY);
+ Frenzy_Timer = 20000 + rand()%10000;
+ }else Frenzy_Timer -= diff;
+
+ if(Chain_Timer < diff)
+ {
+
+ /*
+ std::list<HostilReference*>& m_threatlist = m_creature->getThreatManager().getThreatList();
+ std::list<HostilReference*>::iterator itr;
+
+ int st=0;
+ for(itr = m_threatlist.begin(); itr != m_threatlist.end(); ++itr)
+ {
+ //st++;
+ m_creature->getThreatManager().
+ }
+ Unit* targets[st];
+ int st2=0;
+ for(int i=1; i<=st; i++){
+ if(!IsWithinLOSInMap(targets[i])
+ st2++;
+ }
+ Unit* targets_out_of_LOS[st2];*/
+
+ DoCast(SelectUnit(SELECT_TARGET_RANDOM, 1), SPELL_CONSTRICTING_CHAINS_N); //anyone but the tank
+ Chain_Timer = 2000 + rand()%1000;
+ }else Chain_Timer -= diff;
+
+ DoMeleeAttackIfReady();
+ }
+
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_meathook(Creature *_Creature)
+{
+ return new boss_meathookAI (_Creature);
+}
+
+void AddSC_boss_meathook()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_meathook";
+ newscript->GetAI = GetAI_boss_meathook;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_salramm.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_salramm.cpp
new file mode 100644
index 00000000000..7226a1304dc
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/boss_salramm.cpp
@@ -0,0 +1,152 @@
+/* Script Data Start
+SDName: Boss salramm
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_salramm' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_CURSE_OF_TWISTED_FLESH 58845
+#define SPELL_EXPLODE_GHOUL_N 52480
+#define SPELL_EXPLODE_GHOUL_H 58825
+#define SPELL_SHADOW_BOLT_N 57725
+#define SPELL_SHADOW_BOLT_H 58828
+#define SPELL_STEAL_FLESH 52708
+#define SPELL_SUMMON_GHOULS 52451
+
+//Yell
+#define SAY_AGGRO -1595032
+#define SAY_SPAWN -1595033
+#define SAY_SLAY_1 -1595034
+#define SAY_SLAY_2 -1595035
+#define SAY_SLAY_3 -1595036
+#define SAY_DEATH -1595037
+#define SAY_EXPLODE_GHOUL_1 -1595038
+#define SAY_EXPLODE_GHOUL_2 -1595039
+#define SAY_STEAL_FLESH_1 -1595040
+#define SAY_STEAL_FLESH_2 -1595041
+#define SAY_STEAL_FLESH_3 -1595042
+#define SAY_SUMMON_GHOULS_1 -1595043
+#define SAY_SUMMON_GHOULS_2 -1595044
+
+struct TRINITY_DLL_DECL boss_salrammAI : public ScriptedAI
+{
+ boss_salrammAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 Curse_flesh_Timer,
+ Explode_ghoul_Timer,
+ Shadow_bolt_Timer,
+ Steal_flesh_Timer,
+ Summon_ghouls_Timer;
+
+ void Reset()
+ {
+ Curse_flesh_Timer = 30000; //30s DBM
+ Explode_ghoul_Timer = 25000 + rand()%3000; //approx 6 sec after summon ghouls
+ Shadow_bolt_Timer = 8000 + rand()%4000; // approx 10s
+ Steal_flesh_Timer = 12345;
+ Summon_ghouls_Timer = 19000 + rand()%5000; //on a video approx 24s after aggro
+ }
+
+ void Aggro(Unit* who)
+ {DoScriptText(SAY_AGGRO, m_creature);}
+
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ Unit* random_target = SelectUnit(SELECT_TARGET_RANDOM, 0);
+
+ //Curse of twisted flesh timer
+ if (Curse_flesh_Timer < diff)
+ {
+ DoCast(m_creature->getVictim(),SPELL_CURSE_OF_TWISTED_FLESH);
+ Curse_flesh_Timer = 37000;
+ }else Curse_flesh_Timer -= diff;
+
+ //Shadow bolt timer
+ if (Shadow_bolt_Timer < diff)
+ {
+ DoCast(random_target,SPELL_SHADOW_BOLT_N);
+ Shadow_bolt_Timer = 8000 + rand()%4000;
+ }else Shadow_bolt_Timer -= diff;
+
+ //Steal Flesh timer
+ if (Steal_flesh_Timer < diff)
+ {
+ switch(rand()%3)
+ {
+ case 0:
+ DoScriptText(SAY_STEAL_FLESH_1, m_creature);
+ break;
+ case 1:
+ DoScriptText(SAY_STEAL_FLESH_2, m_creature);
+ break;
+ case 2:
+ DoScriptText(SAY_STEAL_FLESH_3, m_creature);
+ break;
+ }
+ DoCast(random_target,SPELL_STEAL_FLESH);
+ Steal_flesh_Timer = 10000;
+ }else Steal_flesh_Timer -= diff;
+
+ //Summon ghouls timer
+ if (Summon_ghouls_Timer < diff)
+ {
+ switch(rand()%2)
+ {
+ case 0:
+ DoScriptText(SAY_SUMMON_GHOULS_1, m_creature);
+ break;
+ case 1:
+ DoScriptText(SAY_SUMMON_GHOULS_2, m_creature);
+ break;
+ }
+ DoCast(random_target,SPELL_SUMMON_GHOULS);
+ Summon_ghouls_Timer = 10000;
+ }else Summon_ghouls_Timer -= diff;
+
+ DoMeleeAttackIfReady();
+ }
+
+ void JustDied(Unit* killer)
+ {DoScriptText(SAY_DEATH, m_creature);}
+
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_salramm(Creature *_Creature)
+{
+ return new boss_salrammAI (_Creature);
+}
+
+void AddSC_boss_salramm()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_salramm";
+ newscript->GetAI = GetAI_boss_salramm;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/def_culling_of_stratholme.h b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/def_culling_of_stratholme.h
new file mode 100644
index 00000000000..849549e8f99
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/def_culling_of_stratholme.h
@@ -0,0 +1,4 @@
+#ifndef DEF_CULLING_OF_STRATHOLME_H
+#define DEF_CULLING_OF_STRATHOLME_H
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/instance_culling_of_stratholme.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/instance_culling_of_stratholme.cpp
new file mode 100644
index 00000000000..936f8365a35
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/culling_of_stratholme/instance_culling_of_stratholme.cpp
@@ -0,0 +1,21 @@
+#include "precompiled.h"
+#include "def_culling_of_stratholme.h"
+
+struct TRINITY_DLL_DECL instance_culling_of_stratholme : public ScriptedInstance
+{
+ instance_culling_of_stratholme(Map *Map) : ScriptedInstance(Map) {Initialize();};
+};
+
+InstanceData* GetInstanceData_instance_culling_of_stratholme(Map* map)
+{
+ return new instance_culling_of_stratholme(map);
+}
+
+void AddSC_instance_culling_of_stratholme()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_culling_of_stratholme";
+ newscript->GetInstanceData = GetInstanceData_instance_culling_of_stratholme;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_aeonus.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_aeonus.cpp
index 7a2e8239cac..abe37b53685 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_aeonus.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_aeonus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_chrono_lord_deja.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_chrono_lord_deja.cpp
index dc8723b7201..d7ffcde4059 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_chrono_lord_deja.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_chrono_lord_deja.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_temporus.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_temporus.cpp
index 1efa7c75a2c..3e0e327bb89 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_temporus.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/boss_temporus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/dark_portal.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/dark_portal.cpp
index cbe3c4273a2..db8db78f723 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/dark_portal.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/dark_portal.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -79,8 +79,8 @@ struct TRINITY_DLL_DECL npc_medivh_bmAI : public ScriptedAI
if (pInstance->GetData(TYPE_MEDIVH) == IN_PROGRESS)
m_creature->CastSpell(m_creature,SPELL_CHANNEL,true);
- else if (m_creature->HasAura(SPELL_CHANNEL,0))
- m_creature->RemoveAura(SPELL_CHANNEL,0);
+ else if (m_creature->HasAura(SPELL_CHANNEL))
+ m_creature->RemoveAura(SPELL_CHANNEL);
m_creature->CastSpell(m_creature,SPELL_PORTAL_RUNE,true);
}
@@ -92,7 +92,7 @@ struct TRINITY_DLL_DECL npc_medivh_bmAI : public ScriptedAI
if (who->GetTypeId() == TYPEID_PLAYER && m_creature->IsWithinDistInMap(who, 10.0f))
{
- if (pInstance->GetData(TYPE_MEDIVH) == IN_PROGRESS)
+ if (pInstance->GetData(TYPE_MEDIVH) == IN_PROGRESS || pInstance->GetData(TYPE_MEDIVH) == DONE)
return;
DoScriptText(SAY_INTRO, m_creature);
@@ -156,13 +156,13 @@ struct TRINITY_DLL_DECL npc_medivh_bmAI : public ScriptedAI
if (SpellCorrupt_Timer)
{
- if (SpellCorrupt_Timer < diff)
+ if (SpellCorrupt_Timer <= diff)
{
pInstance->SetData(TYPE_MEDIVH,SPECIAL);
- if (m_creature->HasAura(SPELL_CORRUPT_AEONUS,0))
+ if (m_creature->HasAura(SPELL_CORRUPT_AEONUS))
SpellCorrupt_Timer = 1000;
- else if (m_creature->HasAura(SPELL_CORRUPT,0))
+ else if (m_creature->HasAura(SPELL_CORRUPT))
SpellCorrupt_Timer = 3000;
else
SpellCorrupt_Timer = 0;
@@ -171,7 +171,7 @@ struct TRINITY_DLL_DECL npc_medivh_bmAI : public ScriptedAI
if (Check_Timer)
{
- if (Check_Timer < diff)
+ if (Check_Timer <= diff)
{
uint32 pct = pInstance->GetData(DATA_SHIELD);
@@ -181,7 +181,6 @@ struct TRINITY_DLL_DECL npc_medivh_bmAI : public ScriptedAI
{
DoScriptText(SAY_WEAK25, m_creature);
Life25 = false;
- Check_Timer = 0;
}
else if (Life50 && pct <= 50)
{
@@ -203,11 +202,16 @@ struct TRINITY_DLL_DECL npc_medivh_bmAI : public ScriptedAI
return;
}
- if (pInstance->GetData(TYPE_MEDIVH) == DONE)
+ if (pInstance->GetData(TYPE_RIFT) == DONE)
{
DoScriptText(SAY_WIN, m_creature);
Check_Timer = 0;
+
+ if (m_creature->HasAura(SPELL_CHANNEL))
+ m_creature->RemoveAura(SPELL_CHANNEL);
+
//TODO: start the post-event here
+ pInstance->SetData(TYPE_MEDIVH,DONE);
}
}else Check_Timer -= diff;
}
@@ -334,7 +338,8 @@ struct TRINITY_DLL_DECL npc_time_riftAI : public ScriptedAI
debug_log("SD2: npc_time_rift: not casting anylonger, i need to die.");
m_creature->setDeathState(JUST_DIED);
- pInstance->SetData(TYPE_RIFT,SPECIAL);
+ if (pInstance->GetData(TYPE_RIFT) == IN_PROGRESS)
+ pInstance->SetData(TYPE_RIFT,SPECIAL);
}
};
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/def_dark_portal.h b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/def_dark_portal.h
index 61018f58118..7bfd8c917d7 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/def_dark_portal.h
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/def_dark_portal.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/instance_dark_portal.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/instance_dark_portal.cpp
index 39445fe727c..697134cd82d 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/instance_dark_portal.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/dark_portal/instance_dark_portal.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -108,7 +108,7 @@ struct TRINITY_DLL_DECL instance_dark_portal : public ScriptedInstance
}
}
- debug_log("SD2: Instance Black Portal: GetPlayerInMap, but PlayerList is empty!");
+ debug_log("TSCR: Instance Black Portal: GetPlayerInMap, but PlayerList is empty!");
return NULL;
}
@@ -123,7 +123,7 @@ struct TRINITY_DLL_DECL instance_dark_portal : public ScriptedInstance
if (Player* player = itr->getSource())
player->SendUpdateWorldState(id,state);
}
- }else debug_log("SD2: Instance Black Portal: UpdateBMWorldState, but PlayerList is empty!");
+ }else debug_log("TSCR: Instance Black Portal: UpdateBMWorldState, but PlayerList is empty!");
}
void InitWorldState(bool Enable = true)
@@ -187,7 +187,7 @@ struct TRINITY_DLL_DECL instance_dark_portal : public ScriptedInstance
if (!player)
{
- debug_log("SD2: Instance Black Portal: SetData (Type: %u Data %u) cannot find any player.", type, data);
+ debug_log("TSCR: Instance Black Portal: SetData (Type: %u Data %u) cannot find any player.", type, data);
return;
}
@@ -216,7 +216,7 @@ struct TRINITY_DLL_DECL instance_dark_portal : public ScriptedInstance
{
if (data == IN_PROGRESS)
{
- debug_log("SD2: Instance Dark Portal: Starting event.");
+ debug_log("TSCR: Instance Dark Portal: Starting event.");
InitWorldState();
Encounter[1] = IN_PROGRESS;
NextPortal_Timer = 15000;
@@ -227,6 +227,7 @@ struct TRINITY_DLL_DECL instance_dark_portal : public ScriptedInstance
//this may be completed further out in the post-event
if (Unit *medivh = Unit::GetUnit(*player,MedivhGUID))
{
+ debug_log("TSCR: Instance Dark Portal: Event completed.");
player->GroupEventHappens(QUEST_OPENING_PORTAL,medivh);
player->GroupEventHappens(QUEST_MASTER_TOUCH,medivh);
}
@@ -282,7 +283,7 @@ struct TRINITY_DLL_DECL instance_dark_portal : public ScriptedInstance
//normalize Z-level if we can, if rift is not at ground level.
z = std::max(instance->GetHeight(x, y, MAX_HEIGHT), instance->GetWaterLevel(x, y));
- debug_log("SD2: Instance Dark Portal: Summoning rift boss entry %u.",entry);
+ debug_log("TSCR: Instance Dark Portal: Summoning rift boss entry %u.",entry);
Unit *Summon = source->SummonCreature(entry,x,y,z,source->GetOrientation(),
TEMPSUMMON_TIMED_OR_DEAD_DESPAWN,600000);
@@ -290,7 +291,7 @@ struct TRINITY_DLL_DECL instance_dark_portal : public ScriptedInstance
if (Summon)
return Summon;
- debug_log("SD2: Instance Dark Portal: what just happened there? No boss, no loot, no fun...");
+ debug_log("TSCR: Instance Dark Portal: what just happened there? No boss, no loot, no fun...");
return NULL;
}
@@ -302,12 +303,11 @@ struct TRINITY_DLL_DECL instance_dark_portal : public ScriptedInstance
if (Unit *medivh = Unit::GetUnit(*player,MedivhGUID))
{
- for(uint8 i = 0; i < 4; i++)
- {
- int tmp = rand()%4;
- if (tmp != CurrentRiftId)
- {
- debug_log("SD2: Instance Dark Portal: Creating Time Rift at locationId %i (old locationId was %u).",tmp,CurrentRiftId);
+ int tmp = rand()%(4-1);
+
+ if (tmp >= CurrentRiftId)
+ tmp++;
+ debug_log("TSCR: Instance Dark Portal: Creating Time Rift at locationId %i (old locationId was %u).",tmp,CurrentRiftId);
CurrentRiftId = tmp;
@@ -334,9 +334,6 @@ struct TRINITY_DLL_DECL instance_dark_portal : public ScriptedInstance
}
}
}
- break;
- }
- }
}
}
@@ -354,7 +351,7 @@ struct TRINITY_DLL_DECL instance_dark_portal : public ScriptedInstance
if (NextPortal_Timer)
{
- if (NextPortal_Timer < diff)
+ if (NextPortal_Timer <= diff)
{
++mRiftPortalCount;
UpdateBMWorldState(WORLD_STATE_BM_RIFT,mRiftPortalCount);
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/boss_archimonde.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/boss_archimonde.cpp
index 4476a47d04c..af842479ed1 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/boss_archimonde.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/boss_archimonde.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -6,12 +6,12 @@
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/* ScriptData
@@ -40,9 +40,9 @@ EndScriptData */
#define SAY_SOUL_CHARGE1 -1534029
#define SAY_SOUL_CHARGE2 -1534030
-#define SPELL_DENOUEMENT_WISP 32124
-#define SPELL_ANCIENT_SPARK 39349
-#define SPELL_PROTECTION_OF_ELUNE 38528
+#define SPELL_DENOUEMENT_WISP 32124
+#define SPELL_ANCIENT_SPARK 39349
+#define SPELL_PROTECTION_OF_ELUNE 38528
#define SPELL_DRAIN_WORLD_TREE 39140
#define SPELL_DRAIN_WORLD_TREE_2 39141
@@ -53,8 +53,7 @@ EndScriptData */
#define SPELL_GRIP_OF_THE_LEGION 31972
#define SPELL_DOOMFIRE_STRIKE 31903 //summons two creatures
#define SPELL_DOOMFIRE_SPAWN 32074
-#define SPELL_DOOMFIRE_VISUAL 42344 // This is actually a Zul'Aman spell, but the proper Doomfire spell sometimes freezes the server if a player stands in it for too long
-#define SPELL_DOOMFIRE_DAMAGE 31944
+#define SPELL_DOOMFIRE 31945
#define SPELL_SOUL_CHARGE_YELLOW 32045
#define SPELL_SOUL_CHARGE_GREEN 32051
#define SPELL_SOUL_CHARGE_RED 32052
@@ -65,7 +64,7 @@ EndScriptData */
#define CREATURE_ARCHIMONDE 17968
#define CREATURE_DOOMFIRE 18095
-#define CREATURE_DOOMFIRE_TARGETING 18104
+#define CREATURE_DOOMFIRE_SPIRIT 18104
#define CREATURE_ANCIENT_WISP 17946
#define CREATURE_CHANNEL_TARGET 22418
@@ -98,20 +97,20 @@ struct mob_ancient_wispAI : public ScriptedAI
void UpdateAI(const uint32 diff)
{
- if(!ArchimondeGUID)
+ if (!ArchimondeGUID)
{
- if(pInstance)
+ if (pInstance)
ArchimondeGUID = pInstance->GetData64(DATA_ARCHIMONDE);
}
- if(CheckTimer < diff)
+ if (CheckTimer < diff)
{
- if(ArchimondeGUID)
+ if (ArchimondeGUID)
{
Unit* Archimonde = Unit::GetUnit((*m_creature), ArchimondeGUID);
- if(Archimonde)
+ if (Archimonde)
{
- if((((Archimonde->GetHealth()*100) / Archimonde->GetMaxHealth()) < 2) || !Archimonde->isAlive())
+ if ((((Archimonde->GetHealth()*100) / Archimonde->GetMaxHealth()) < 2) || !Archimonde->isAlive())
DoCast(m_creature, SPELL_DENOUEMENT_WISP);
else
DoCast(Archimonde, SPELL_ANCIENT_SPARK);
@@ -122,186 +121,65 @@ struct mob_ancient_wispAI : public ScriptedAI
}
};
-/* This script controls the Doomfire mob. Unlike the other Doomfire mob, this one does not stalk players.
- Instead, this doomfire will simply stand in one place after spawning and deal damage to any players that
- are within 3 yards. Another creature called Doomfire Targetting spawns this creature as well as stalks. */
+/* This script is merely a placeholder for the Doomfire that triggers Doomfire spell. It will
+ MoveChase the Doomfire Spirit always, until despawn (AttackStart is called upon it's spawn) */
struct TRINITY_DLL_DECL mob_doomfireAI : public ScriptedAI
{
mob_doomfireAI(Creature* c) : ScriptedAI(c) {}
- uint32 CheckTimer;
- uint32 RefreshTimer;
-
- bool TargetSelected;
-
- uint64 ArchimondeGUID;
- uint64 TargetGUID;
-
- void Reset()
- {
- CheckTimer = 5000;
- RefreshTimer = 0;
-
- TargetSelected = false;
-
- ArchimondeGUID = 0;
- TargetGUID = 0;
- }
-
- void DamageTaken(Unit *done_by, uint32 &damage) { damage = 0; }
+ void Reset() { }
+ void MoveInLineOfSight(Unit* who) { }
void Aggro(Unit* who) { }
-
- void MoveInLineOfSight(Unit* who)
- {
- // Do not do anything if who does not exist, or we are refreshing our timer, or who is Doomfire, Archimonde or Doomfire targetting
- if(!who || who == m_creature || RefreshTimer || who->GetEntry() == CREATURE_ANCIENT_WISP ||
- who->GetEntry() == CREATURE_ARCHIMONDE || who->GetEntry() == CREATURE_DOOMFIRE ||
- who->GetEntry() == CREATURE_DOOMFIRE_TARGETING || !who->isTargetableForAttack())
- return;
-
- if(m_creature->IsWithinDistInMap(who, 3))
- {
- TargetSelected = true;
- TargetGUID = who->GetGUID();
- RefreshTimer = 2000;
- }
- }
-
- void KilledUnit(Unit* victim)
- {
- bool suicide = true;
- if(ArchimondeGUID)
- {
- Creature* Archimonde = (Unit::GetCreature((*m_creature), ArchimondeGUID));
- if(Archimonde && Archimonde->isAlive())
- {
- suicide = false;
- Archimonde->AI()->KilledUnit(victim);
- }
- }
-
- if(suicide)
- m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
- }
-
- void UpdateAI(const uint32 diff)
- {
- if(RefreshTimer < diff)
- RefreshTimer = 0;
- else RefreshTimer -= diff;
-
- if(TargetSelected && TargetGUID)
- {
- Unit* target = Unit::GetUnit((*m_creature), TargetGUID);
- if(target && target->isAlive())
- {
- target->CastSpell(target, SPELL_DOOMFIRE_DAMAGE, true);
- TargetGUID = 0;
- TargetSelected = false;
- }
- }
-
- if(CheckTimer < diff)
- {
- if(ArchimondeGUID)
- {
- Unit* Archimonde = Unit::GetUnit((*m_creature), ArchimondeGUID);
- if(!Archimonde || !Archimonde->isAlive())
- m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
- CheckTimer = 5000;
- }
- else m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
- }else CheckTimer -= diff;
- }
+ void DamageTaken(Unit *done_by, uint32 &damage) { damage = 0; }
};
-/* This is the script for the Doomfire Targetting Mob. This mob simply follows players and/or travels in random directions and spawns the actual Doomfire which does damage to anyone that moves close. */
+/* This is the script for the Doomfire Spirit Mob. This mob simply follow players or
+ travels in random directions if target cannot be found. */
struct TRINITY_DLL_DECL mob_doomfire_targettingAI : public ScriptedAI
{
mob_doomfire_targettingAI(Creature* c) : ScriptedAI(c) {}
+ uint64 TargetGUID;
uint32 ChangeTargetTimer;
- uint32 SummonTimer; // This timer will serve as both a summon timer for the doomfire that does damage as well as to check on Archionde
-
- uint64 ArchimondeGUID;
void Reset()
{
+ TargetGUID = 0;
ChangeTargetTimer = 5000;
- SummonTimer = 1000;
-
- ArchimondeGUID = 0;
}
- void Aggro(Unit* who) {}
-
void MoveInLineOfSight(Unit* who)
{
- // Do not do anything if who does not exist, or who is Doomfire, Archimonde or Doomfire targetting
- if(!who || who == m_creature || who->GetEntry() == CREATURE_ARCHIMONDE
- || who->GetEntry() == CREATURE_DOOMFIRE || who->GetEntry() == CREATURE_DOOMFIRE_TARGETING || !who->isTargetableForAttack())
- return;
-
- m_creature->AddThreat(who, 0.0f);
+ //will update once TargetGUID is 0. In case noone actually moves(not likely) and this is 0
+ //when UpdateAI needs it, it will be forced to select randomPoint
+ if (!TargetGUID && who->GetTypeId() == TYPEID_PLAYER)
+ TargetGUID = who->GetGUID();
}
+ void Aggro(Unit* who) {}
+
void DamageTaken(Unit *done_by, uint32 &damage) { damage = 0; }
void UpdateAI(const uint32 diff)
{
- if(!UpdateVictim())
- return;
-
- if(SummonTimer < diff)
+ if (ChangeTargetTimer < diff)
{
- if(ArchimondeGUID)
+ if (Unit *temp = Unit::GetUnit(*m_creature,TargetGUID))
{
- Unit* Archimonde = Unit::GetUnit((*m_creature), ArchimondeGUID);
- if(Archimonde && Archimonde->isAlive())
- {
- Creature* Doomfire = DoSpawnCreature(CREATURE_DOOMFIRE, 0, 0, 2, 0, TEMPSUMMON_TIMED_DESPAWN, 30000);
- if(Doomfire)
- {
- Doomfire->CastSpell(Doomfire, SPELL_DOOMFIRE_VISUAL, true);
- ((mob_doomfireAI*)Doomfire->AI())->ArchimondeGUID = ArchimondeGUID;
- Doomfire->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- }
- SummonTimer = 500;
- }
- else
- m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
+ m_creature->GetMotionMaster()->MoveFollow(temp,0.0f,0.0f);
+ TargetGUID = 0;
}
else
- m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
- }else SummonTimer -= diff;
-
- if(ChangeTargetTimer < diff)
- {
- Unit* target = NULL;
- switch(rand()%2)
{
- case 0: // stalk player
- target = SelectUnit(SELECT_TARGET_RANDOM, 1);
- if(target && target->isAlive())
- {
- m_creature->AddThreat(target, DoGetThreat(m_creature->getVictim()));
- m_creature->GetMotionMaster()->MoveChase(target);
- }
- break;
-
- case 1: // random location
- float x = 0;
- float y = 0;
- float z = 0;
- m_creature->GetRandomPoint(m_creature->GetPositionX(), m_creature->GetPositionY(), m_creature->GetPositionZ(), 40, x, y, z);
- m_creature->GetMotionMaster()->MovePoint(0, x, y, z);
- break;
+ float x,y,z = 0.0;
+ m_creature->GetRandomPoint(m_creature->GetPositionX(), m_creature->GetPositionY(), m_creature->GetPositionZ(), 40, x, y, z);
+ m_creature->GetMotionMaster()->MovePoint(0, x, y, z);
}
+
ChangeTargetTimer = 5000;
}else ChangeTargetTimer -= diff;
}
-
};
/* Finally, Archimonde's script. His script isn't extremely complex, most are simply spells on timers.
@@ -309,8 +187,8 @@ struct TRINITY_DLL_DECL mob_doomfire_targettingAI : public ScriptedAI
hardest bit to code. Finger of Death is simply a distance check - if no one is in melee range, then
select a random target and cast the spell on them. However, if someone IS in melee range, and this
is NOT the main tank (creature's victim), then we aggro that player and they become the new victim.
- For Doomfire, we summon a mob (Doomfire Targetting) that summons another mob (Doomfire every second)
- Doomfire Targetting 'stalks' players whilst Doomfire damages player that are within range. */
+ For Doomfire, we summon a mob (Doomfire Spirit) for the Doomfire mob to follow. It's spirit will
+ randomly select it's target to follow and then we create the random movement making it unpredictable. */
// This is used to sort by distance in order to see who is the closest target, when checking for Finger of Death
struct TargetDistanceOrder : public std::binary_function<const Unit, const Unit, bool>
@@ -333,6 +211,9 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
ScriptedInstance* pInstance;
+ uint64 DoomfireSpiritGUID;
+ uint64 WorldTreeGUID;
+
uint32 DrainNordrassilTimer;
uint32 FearTimer;
uint32 AirBurstTimer;
@@ -354,10 +235,13 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
void Reset()
{
- if(pInstance)
+ if (pInstance)
pInstance->SetData(DATA_ARCHIMONDEEVENT, NOT_STARTED);
+ DoomfireSpiritGUID = 0;
damageTaken = 0;
+ WorldTreeGUID = 0;
+
DrainNordrassilTimer = 0;
FearTimer = 42000;
AirBurstTimer = 30000;
@@ -384,7 +268,7 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
DoScriptText(SAY_AGGRO, m_creature);
DoZoneInCombat();
- if(pInstance)
+ if (pInstance)
pInstance->SetData(DATA_ARCHIMONDEEVENT, IN_PROGRESS);
}
@@ -392,12 +276,12 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
{
switch(rand()%2)
{
- case 0: DoScriptText(SAY_SLAY1, m_creature); break;
- case 1: DoScriptText(SAY_SLAY2, m_creature); break;
- case 2: DoScriptText(SAY_SLAY3, m_creature); break;
+ case 0: DoScriptText(SAY_SLAY1, m_creature); break;
+ case 1: DoScriptText(SAY_SLAY2, m_creature); break;
+ case 2: DoScriptText(SAY_SLAY3, m_creature); break;
}
- if(victim && (victim->GetTypeId() == TYPEID_PLAYER))
+ if (victim && (victim->GetTypeId() == TYPEID_PLAYER))
GainSoulCharge(((Player*)victim));
}
@@ -431,7 +315,7 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
hyjal_trashAI::JustDied(victim);
DoScriptText(SAY_DEATH, m_creature);
- if(pInstance)
+ if (pInstance)
pInstance->SetData(DATA_ARCHIMONDEEVENT, DONE);
}
@@ -439,11 +323,11 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
{
// First we check if our current victim is in melee range or not.
Unit* victim = m_creature->getVictim();
- if(victim && m_creature->IsWithinDistInMap(victim, m_creature->GetAttackDistance(victim)))
+ if (victim && m_creature->IsWithinDistInMap(victim, m_creature->GetAttackDistance(victim)))
return false;
std::list<HostilReference*>& m_threatlist = m_creature->getThreatManager().getThreatList();
- if(m_threatlist.empty())
+ if (m_threatlist.empty())
return false;
std::list<Unit*> targets;
@@ -451,56 +335,70 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
for( ; itr != m_threatlist.end(); ++itr)
{
Unit* pUnit = Unit::GetUnit((*m_creature), (*itr)->getUnitGuid());
- if(pUnit && pUnit->isAlive())
+ if (pUnit && pUnit->isAlive())
targets.push_back(pUnit);
}
- if(targets.empty())
+ if (targets.empty())
return false;
targets.sort(TargetDistanceOrder(m_creature));
Unit* target = targets.front();
- if(target)
+ if (target)
{
- if(!m_creature->IsWithinDistInMap(target, m_creature->GetAttackDistance(target)))
+ if (!m_creature->IsWithinDistInMap(target, m_creature->GetAttackDistance(target)))
return true; // Cast Finger of Death
else // This target is closest, he is our new tank
- m_creature->AddThreat(target, DoGetThreat(m_creature->getVictim()));
+ m_creature->AddThreat(target, m_creature->getThreatManager().getThreat(m_creature->getVictim()));
}
return false;
}
- void SummonDoomfire(Unit* target)
+ void JustSummoned(Creature *summoned)
{
- Creature* Doomfire = DoSpawnCreature(CREATURE_DOOMFIRE_TARGETING, rand()%30, rand()%30, 0, 0, TEMPSUMMON_TIMED_DESPAWN, 30000);
- if(Doomfire)
+ summoned->setFaction(m_creature->getFaction());
+ summoned->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
+ summoned->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+
+ if (summoned->GetEntry() == CREATURE_DOOMFIRE_SPIRIT)
{
- ((mob_doomfire_targettingAI*)Doomfire->AI())->ArchimondeGUID = m_creature->GetGUID();
- Doomfire->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- // Give Doomfire a taste of everyone in the threatlist = more targets to chase.
- std::list<HostilReference*>::iterator itr;
- for(itr = m_creature->getThreatManager().getThreatList().begin(); itr != m_creature->getThreatManager().getThreatList().end(); ++itr)
- Doomfire->AddThreat(Unit::GetUnit(*m_creature, (*itr)->getUnitGuid()), 1.0f);
- Doomfire->setFaction(m_creature->getFaction());
- DoCast(Doomfire, SPELL_DOOMFIRE_SPAWN);
- Doomfire->CastSpell(Doomfire, SPELL_DOOMFIRE_VISUAL, true);
- if(target)
- Doomfire->AI()->AttackStart(target);
-
- if(rand()%2 == 0)
- DoScriptText(SAY_DOOMFIRE1, m_creature);
- else
- DoScriptText(SAY_DOOMFIRE2, m_creature);
+ DoomfireSpiritGUID = summoned->GetGUID();
}
+
+ if (summoned->GetEntry() == CREATURE_DOOMFIRE)
+ {
+ summoned->CastSpell(summoned,SPELL_DOOMFIRE_SPAWN,false);
+ summoned->CastSpell(summoned,SPELL_DOOMFIRE,true,0,0,m_creature->GetGUID());
+
+ if (Unit *DoomfireSpirit = Unit::GetUnit(*m_creature, DoomfireSpiritGUID))
+ {
+ summoned->GetMotionMaster()->MoveFollow(DoomfireSpirit,0.0f,0.0f);
+ DoomfireSpiritGUID = 0;
+ }
+ }
+ }
+
+ //this is code doing close to what the summoning spell would do (spell 31903)
+ void SummonDoomfire(Unit* target)
+ {
+ m_creature->SummonCreature(CREATURE_DOOMFIRE_SPIRIT,
+ target->GetPositionX()+15.0,target->GetPositionY()+15.0,target->GetPositionZ(),0,
+ TEMPSUMMON_TIMED_DESPAWN, 27000);
+
+ m_creature->SummonCreature(CREATURE_DOOMFIRE,
+ target->GetPositionX()-15.0,target->GetPositionY()-15.0,target->GetPositionZ(),0,
+ TEMPSUMMON_TIMED_DESPAWN, 27000);
}
void UnleashSoulCharge()
{
m_creature->InterruptNonMeleeSpells(false);
+
bool HasCast = false;
uint32 chargeSpell = 0;
uint32 unleashSpell = 0;
+
switch(rand()%3)
{
case 0:
@@ -516,42 +414,48 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
unleashSpell = SPELL_UNLEASH_SOUL_GREEN;
break;
}
- if(m_creature->HasAura(chargeSpell, 0))
+
+ if (m_creature->HasAura(chargeSpell))
{
- m_creature->RemoveSingleAuraFromStack(chargeSpell, 0);
+ m_creature->RemoveAuraFromStack(chargeSpell);
DoCast(m_creature->getVictim(), unleashSpell);
HasCast = true;
SoulChargeCount--;
}
- if(HasCast)
+
+ if (HasCast)
SoulChargeTimer = 2000 + rand()%28000;
}
void UpdateAI(const uint32 diff)
{
- if(!InCombat)
+ if (!InCombat)
{
- if(pInstance)
+ if (pInstance)
{
// Do not let the raid skip straight to Archimonde. Visible and hostile ONLY if Azagalor is finished.
- if((pInstance->GetData(DATA_AZGALOREVENT) < DONE) && ((m_creature->GetVisibility() != VISIBILITY_OFF) || (m_creature->getFaction() != 35)))
+ if ((pInstance->GetData(DATA_AZGALOREVENT) < DONE) && ((m_creature->GetVisibility() != VISIBILITY_OFF) || (m_creature->getFaction() != 35)))
{
m_creature->SetVisibility(VISIBILITY_OFF);
m_creature->setFaction(35);
}
- else if((pInstance->GetData(DATA_AZGALOREVENT) >= DONE) && ((m_creature->GetVisibility() != VISIBILITY_ON) || (m_creature->getFaction() == 35)))
+ else if ((pInstance->GetData(DATA_AZGALOREVENT) >= DONE) && ((m_creature->GetVisibility() != VISIBILITY_ON) || (m_creature->getFaction() == 35)))
{
m_creature->setFaction(1720);
m_creature->SetVisibility(VISIBILITY_ON);
}
}
- if(DrainNordrassilTimer < diff)
+ if (DrainNordrassilTimer < diff)
{
- if(!IsChanneling)
+ if (!IsChanneling)
{
- Creature* Nordrassil = m_creature->SummonCreature(CREATURE_CHANNEL_TARGET, NORDRASSIL_X, NORDRASSIL_Y, NORDRASSIL_Z, 0, TEMPSUMMON_TIMED_DESPAWN, 1200000);
- if(Nordrassil)
+ Creature *temp = m_creature->SummonCreature(CREATURE_CHANNEL_TARGET, NORDRASSIL_X, NORDRASSIL_Y, NORDRASSIL_Z, 0, TEMPSUMMON_TIMED_DESPAWN, 1200000);
+
+ if (temp)
+ WorldTreeGUID = temp->GetGUID();
+
+ if (Unit *Nordrassil = Unit::GetUnit(*m_creature, WorldTreeGUID))
{
Nordrassil->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
Nordrassil->SetUInt32Value(UNIT_FIELD_DISPLAYID, 11686);
@@ -559,26 +463,24 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
IsChanneling = true;
}
}
- Creature* Nordrassil = m_creature->SummonCreature(CREATURE_CHANNEL_TARGET, NORDRASSIL_X, NORDRASSIL_Y, NORDRASSIL_Z, 0, TEMPSUMMON_TIMED_DESPAWN, 5000);
- if(Nordrassil)
+
+ if (Unit *Nordrassil = Unit::GetUnit(*m_creature, WorldTreeGUID))
{
- Nordrassil->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- Nordrassil->SetUInt32Value(UNIT_FIELD_DISPLAYID, 11686);
Nordrassil->CastSpell(m_creature, SPELL_DRAIN_WORLD_TREE_2, true);
DrainNordrassilTimer = 1000;
}
}else DrainNordrassilTimer -= diff;
}
- if(!UpdateVictim())
+ if (!UpdateVictim() )
return;
- if(((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 10) && !BelowTenPercent && !Enraged)
+ if (((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 10) && !BelowTenPercent && !Enraged)
BelowTenPercent = true;
- if(!Enraged)
+ if (!Enraged)
{
- if(EnrageTimer < diff)
+ if (EnrageTimer < diff)
{
if((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) > 10)
{
@@ -589,14 +491,15 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
}
}else EnrageTimer -= diff;
- if(CheckDistanceTimer < diff)
+ if (CheckDistanceTimer < diff)
{
// To simplify the check, we simply summon a creature in the location and then check how far we are from the creature
Creature* Check = m_creature->SummonCreature(CREATURE_CHANNEL_TARGET, NORDRASSIL_X, NORDRASSIL_Y, NORDRASSIL_Z, 0, TEMPSUMMON_TIMED_DESPAWN, 2000);
- if(Check)
+ if (Check)
{
Check->SetVisibility(VISIBILITY_OFF);
- if(m_creature->IsWithinDistInMap(Check, 75))
+
+ if (m_creature->IsWithinDistInMap(Check, 75))
{
m_creature->GetMotionMaster()->Clear(false);
m_creature->GetMotionMaster()->MoveIdle();
@@ -608,22 +511,23 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
}else CheckDistanceTimer -= diff;
}
- if(BelowTenPercent)
+ if (BelowTenPercent)
{
- if(!HasProtected)
+ if (!HasProtected)
{
m_creature->GetMotionMaster()->Clear(false);
m_creature->GetMotionMaster()->MoveIdle();
+
//all members of raid must get this buff
DoCast(m_creature->getVictim(), SPELL_PROTECTION_OF_ELUNE);
HasProtected = true;
Enraged = true;
}
- if(SummonWispTimer < diff)
+ if (SummonWispTimer < diff)
{
Creature* Wisp = DoSpawnCreature(CREATURE_ANCIENT_WISP, rand()%40, rand()%40, 0, 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
- if(Wisp)
+ if (Wisp)
{
Wisp->AI()->AttackStart(m_creature);
((mob_ancient_wispAI*)Wisp->AI())->ArchimondeGUID = m_creature->GetGUID();
@@ -632,13 +536,13 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
++WispCount;
}else SummonWispTimer -= diff;
- if(WispCount >= 30)
+ if (WispCount >= 30)
m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
}
- if(Enraged)
+ if (Enraged)
{
- if(HandOfDeathTimer < diff)
+ if (HandOfDeathTimer < diff)
{
DoCast(m_creature->getVictim(), SPELL_HAND_OF_DEATH);
HandOfDeathTimer = 2000;
@@ -646,46 +550,57 @@ struct TRINITY_DLL_DECL boss_archimondeAI : public hyjal_trashAI
return; // Don't do anything after this point.
}
- if(SoulChargeCount)
+ if (SoulChargeCount)
{
- if(SoulChargeTimer < diff)
+ if (SoulChargeTimer < diff)
UnleashSoulCharge();
else SoulChargeTimer -= diff;
}
- if(GripOfTheLegionTimer < diff)
+ if (GripOfTheLegionTimer < diff)
{
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_GRIP_OF_THE_LEGION);
GripOfTheLegionTimer = 5000 + rand()%20000;
}else GripOfTheLegionTimer -= diff;
- if(AirBurstTimer < diff)
+ if (AirBurstTimer < diff)
{
- if(rand()%2 == 0)
+ if (rand()%2 == 0)
DoScriptText(SAY_AIR_BURST1, m_creature);
else
DoScriptText(SAY_AIR_BURST2, m_creature);
-
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 1), SPELL_AIR_BURST);//not on tank
AirBurstTimer = 25000 + rand()%15000;
}else AirBurstTimer -= diff;
- if(FearTimer < diff)
+ if (FearTimer < diff)
{
DoCast(m_creature->getVictim(), SPELL_FEAR);
FearTimer = 42000;
}else FearTimer -= diff;
- if(DoomfireTimer < diff)
+ if (DoomfireTimer < diff)
{
- SummonDoomfire(SelectUnit(SELECT_TARGET_RANDOM, 1));
- DoomfireTimer = 40000;
+ if (rand()%2 == 0)
+ DoScriptText(SAY_DOOMFIRE1, m_creature);
+ else
+ DoScriptText(SAY_DOOMFIRE2, m_creature);
+
+ Unit *temp = SelectUnit(SELECT_TARGET_RANDOM, 1);
+ if (!temp)
+ temp = m_creature->getVictim();
+
+ //replace with spell cast 31903 once implicitTarget 73 implemented
+ SummonDoomfire(temp);
+
+ //supposedly three doomfire can be up at the same time
+ DoomfireTimer = 20000;
}else DoomfireTimer -= diff;
- if(MeleeRangeCheckTimer < diff)
+ if (MeleeRangeCheckTimer < diff)
{
- if(CanUseFingerOfDeath())
+ if (CanUseFingerOfDeath())
{
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_FINGER_OF_DEATH);
MeleeRangeCheckTimer = 1000;
@@ -723,7 +638,7 @@ void AddSC_boss_archimonde()
{
Script *newscript;
newscript = new Script;
- newscript->Name="boss_archimonde";
+ newscript->Name = "boss_archimonde";
newscript->GetAI = &GetAI_boss_archimonde;
newscript->RegisterSelf();
@@ -742,4 +657,3 @@ void AddSC_boss_archimonde()
newscript->GetAI = &GetAI_mob_ancient_wisp;
newscript->RegisterSelf();
}
-
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/def_hyjal.h b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/def_hyjal.h
index ed02258cd9f..7d81dbe4993 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/def_hyjal.h
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/def_hyjal.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjal.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjal.cpp
index 312aa90a686..faa7f9eaad7 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjal.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjal.cpp
@@ -1,4 +1,4 @@
- /* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ /* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.cpp
index 0467bfce594..57f484f3ac1 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -354,6 +354,7 @@ void hyjalAI::Reset()
// Misc
WaveCount = 0;
+ EnemyCount = 0;
// Set faction properly based on creature entry
switch(m_creature->GetEntry())
@@ -437,7 +438,7 @@ void hyjalAI::EnterEvadeMode()
void hyjalAI::Aggro(Unit *who)
{
if(IsDummy)return;
- for(uint8 i = 0; i < 2; ++i)
+ for(uint8 i = 0; i < 3; ++i)
if(Spell[i].Cooldown)
SpellTimer[i] = Spell[i].Cooldown;
@@ -691,7 +692,7 @@ void hyjalAI::Retreat()
// First get all creatures.
std::list<Creature*> creatures;
Trinity::AllFriendlyCreaturesInGrid creature_check(m_creature);
- Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(creatures, creature_check);
+ Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(m_creature, creatures, creature_check);
TypeContainerVisitor
<Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid>,
GridTypeMapContainer> creature_visitor(creature_searcher);
@@ -1018,7 +1019,7 @@ void hyjalAI::HideNearPos(float x, float y)
// First get all creatures.
std::list<Creature*> creatures;
Trinity::AllFriendlyCreaturesInGrid creature_check(m_creature);
- Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(creatures, creature_check);
+ Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(m_creature, creatures, creature_check);
TypeContainerVisitor
<Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid>,
GridTypeMapContainer> creature_visitor(creature_searcher);
@@ -1046,7 +1047,7 @@ void hyjalAI::RespawnNearPos(float x, float y)
cell.SetNoCreate();
Trinity::RespawnDo u_do;
- Trinity::WorldObjectWorker<Trinity::RespawnDo> worker(u_do);
+ Trinity::WorldObjectWorker<Trinity::RespawnDo> worker(m_creature, u_do);
TypeContainerVisitor<Trinity::WorldObjectWorker<Trinity::RespawnDo>, GridTypeMapContainer > obj_worker(worker);
CellLock<GridReadGuard> cell_lock(cell, p);
cell_lock->Visit(cell_lock, obj_worker, *m_creature->GetMap());
@@ -1055,7 +1056,7 @@ void hyjalAI::WaypointReached(uint32 i)
{
if(i == 1 || (i == 0 && m_creature->GetEntry() == THRALL))
{
- m_creature->Yell("Hurry, we don't have much time",0,0);
+ m_creature->MonsterYell("Hurry, we don't have much time",0,0);
WaitForTeleport = true;
TeleportTimer = 20000;
if(m_creature->GetEntry() == JAINA)
@@ -1080,7 +1081,7 @@ void hyjalAI::WaypointReached(uint32 i)
// First get all creatures.
std::list<Creature*> creatures;
Trinity::AllFriendlyCreaturesInGrid creature_check(m_creature);
- Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(creatures, creature_check);
+ Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(m_creature, creatures, creature_check);
TypeContainerVisitor
<Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid>,
GridTypeMapContainer> creature_visitor(creature_searcher);
@@ -1122,7 +1123,7 @@ void hyjalAI::DoOverrun(uint32 faction, const uint32 diff)
std::list<Creature*> creatures;
Trinity::AllFriendlyCreaturesInGrid creature_check(m_creature);
- Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(creatures, creature_check);
+ Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> creature_searcher(m_creature, creatures, creature_check);
TypeContainerVisitor
<Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid>,
GridTypeMapContainer> creature_visitor(creature_searcher);
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.h b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.h
index 4a2fbd6494e..ba75eaa36f2 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.h
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/hyjalAI.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/instance_hyjal.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/instance_hyjal.cpp
index b4fc3a65222..13844079b84 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/instance_hyjal.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/hyjal/instance_hyjal.cpp
@@ -1,4 +1,4 @@
- /* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ /* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -39,6 +39,9 @@ struct TRINITY_DLL_DECL instance_mount_hyjal : public ScriptedInstance
{
instance_mount_hyjal(Map *map) : ScriptedInstance(map) {Initialize();};
+ uint32 Encounters[ENCOUNTERS];
+ std::string str_data;
+
uint64 RageWinterchill;
uint64 Anetheron;
uint64 Kazrogal;
@@ -51,7 +54,7 @@ struct TRINITY_DLL_DECL instance_mount_hyjal : public ScriptedInstance
uint64 ElfGate;
uint32 Trash;
- uint32 Encounters[ENCOUNTERS];
+
uint32 hordeRetreat;
uint32 allianceRetreat;
@@ -114,13 +117,12 @@ struct TRINITY_DLL_DECL instance_mount_hyjal : public ScriptedInstance
void OpenDoor(uint64 DoorGUID, bool open)
{
- if(GameObject *Door = instance->GetGameObjectInMap(DoorGUID))
- Door->SetUInt32Value(GAMEOBJECT_STATE, open ? 0 : 1);
+ HandleGameObject(DoorGUID, open, NULL);
}
void OnCreatureCreate(Creature *creature, uint32 creature_entry)
{
- switch(creature_entry)
+ switch(creature->GetEntry())
{
case 17767: RageWinterchill = creature->GetGUID(); break;
case 17808: Anetheron = creature->GetGUID(); break;
@@ -229,7 +231,21 @@ struct TRINITY_DLL_DECL instance_mount_hyjal : public ScriptedInstance
debug_log("SD2: Instance Hyjal: Instance data updated for event %u (Data=%u)",type,data);
if(data == DONE)
+ {
+ OUT_SAVE_INST_DATA;
+
+ std::ostringstream saveStream;
+ saveStream << Encounters[0] << " " << Encounters[1] << " " << Encounters[2] << " "
+ << Encounters[3] << " " << Encounters[4]
+ << " " << allianceRetreat << " " << hordeRetreat
+ << " " << RaidDamage;
+
+ str_data = saveStream.str();
+
SaveToDB();
+ OUT_SAVE_INST_DATA_COMPLETE;
+ }
+
}
uint32 GetData(uint32 type)
@@ -265,19 +281,7 @@ struct TRINITY_DLL_DECL instance_mount_hyjal : public ScriptedInstance
const char* Save()
{
- OUT_SAVE_INST_DATA;
- std::ostringstream stream;
- stream << Encounters[0] << " " << Encounters[1] << " " << Encounters[2] << " "
- << Encounters[3] << " " << Encounters[4] << " " << allianceRetreat << " " << hordeRetreat << " " << RaidDamage;
- char* out = new char[stream.str().length() + 1];
- strcpy(out, stream.str().c_str());
- if(out)
- {
- OUT_SAVE_INST_DATA_COMPLETE;
- return out;
- }
-
- return NULL;
+ return str_data.c_str();
}
void Load(const char* in)
@@ -289,8 +293,7 @@ struct TRINITY_DLL_DECL instance_mount_hyjal : public ScriptedInstance
}
OUT_LOAD_INST_DATA(in);
- std::istringstream loadStream;
- loadStream.str(in);
+ std::istringstream loadStream(in);
loadStream >> Encounters[0] >> Encounters[1] >> Encounters[2] >> Encounters[3] >> Encounters[4] >> allianceRetreat >> hordeRetreat >> RaidDamage;
for(uint8 i = 0; i < ENCOUNTERS; ++i)
if(Encounters[i] == IN_PROGRESS) // Do not load an encounter as IN_PROGRESS - reset it instead.
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_captain_skarloc.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_captain_skarloc.cpp
index ab3a61ffe0b..be4c2660b51 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_captain_skarloc.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_captain_skarloc.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -56,9 +56,9 @@ struct TRINITY_DLL_DECL boss_captain_skarlocAI : public ScriptedAI
void Reset()
{
- Holy_Light_Timer = 30000;
+ Holy_Light_Timer = 20000 + rand()%10000;
Cleanse_Timer = 10000;
- HammerOfJustice_Timer = 60000;
+ HammerOfJustice_Timer = 20000 + rand()%15000;
HolyShield_Timer = 240000;
DevotionAura_Timer = 3000;
Consecration_Timer = 8000;
@@ -126,14 +126,14 @@ struct TRINITY_DLL_DECL boss_captain_skarlocAI : public ScriptedAI
if (DevotionAura_Timer < diff)
{
DoCast(m_creature, SPELL_DEVOTION_AURA);
- DevotionAura_Timer = 60000;
+ DevotionAura_Timer = 45000 + rand()%10000;
}else DevotionAura_Timer -= diff;
//Consecration
if (Consecration_Timer < diff)
{
//DoCast(m_creature->getVictim(), SPELL_CONSECRATION);
- Consecration_Timer = 8000;
+ Consecration_Timer = 5000 + rand()%5000;
}else Consecration_Timer -= diff;
DoMeleeAttackIfReady();
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_epoch_hunter.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_epoch_hunter.cpp
index 39d42413c5f..60ef9ae55fe 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_epoch_hunter.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_epoch_hunter.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -56,8 +56,8 @@ struct TRINITY_DLL_DECL boss_epoch_hunterAI : public ScriptedAI
void Reset()
{
- SandBreath_Timer = 25000;
- ImpendingDeath_Timer = 30000;
+ SandBreath_Timer = 8000 + rand()%8000;
+ ImpendingDeath_Timer = 25000 + rand()%5000;
WingBuffet_Timer = 35000;
Mda_Timer = 40000;
}
@@ -108,13 +108,13 @@ struct TRINITY_DLL_DECL boss_epoch_hunterAI : public ScriptedAI
case 1: DoScriptText(SAY_BREATH2, m_creature); break;
}
- SandBreath_Timer = 25000+rand()%5000;
+ SandBreath_Timer = 10000 + rand()%10000;
}else SandBreath_Timer -= diff;
if (ImpendingDeath_Timer < diff)
{
DoCast(m_creature->getVictim(),SPELL_IMPENDING_DEATH);
- ImpendingDeath_Timer = 30000+rand()%5000;
+ ImpendingDeath_Timer = 25000+rand()%5000;
}else ImpendingDeath_Timer -= diff;
if (WingBuffet_Timer < diff)
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_leutenant_drake.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_leutenant_drake.cpp
index 67d0db45872..b36555cd074 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_leutenant_drake.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/boss_leutenant_drake.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -159,7 +159,7 @@ struct TRINITY_DLL_DECL boss_lieutenant_drakeAI : public ScriptedAI
{
DoScriptText(SAY_SHOUT, m_creature);
DoCast(m_creature->getVictim(), SPELL_FRIGHTENING_SHOUT);
- Fear_Timer = 30000+rand()%10000;
+ Fear_Timer = 25000+rand()%10000;
}else Fear_Timer -= diff;
//Mortal Strike
@@ -167,7 +167,7 @@ struct TRINITY_DLL_DECL boss_lieutenant_drakeAI : public ScriptedAI
{
DoScriptText(SAY_MORTAL, m_creature);
DoCast(m_creature->getVictim(), SPELL_MORTAL_STRIKE);
- MortalStrike_Timer = 45000+rand()%5000;
+ MortalStrike_Timer = 20000+rand()%10000;
}else MortalStrike_Timer -= diff;
DoMeleeAttackIfReady();
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/def_old_hillsbrad.h b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/def_old_hillsbrad.h
index 01c0e1334ac..39db5bed06a 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/def_old_hillsbrad.h
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/def_old_hillsbrad.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/instance_old_hillsbrad.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/instance_old_hillsbrad.cpp
index 9ec75c06e0c..8b0a62c4452 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/instance_old_hillsbrad.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/instance_old_hillsbrad.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -98,7 +98,7 @@ struct TRINITY_DLL_DECL instance_old_hillsbrad : public ScriptedInstance
void OnCreatureCreate(Creature *creature, uint32 creature_entry)
{
- switch(creature_entry)
+ switch(creature->GetEntry())
{
case THRALL_ENTRY:
ThrallGUID = creature->GetGUID();
diff --git a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/old_hillsbrad.cpp b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/old_hillsbrad.cpp
index ea85414a27e..6ed4609e3b9 100644
--- a/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/old_hillsbrad.cpp
+++ b/src/bindings/scripts/scripts/zone/caverns_of_time/old_hillsbrad/old_hillsbrad.cpp
@@ -1,4 +1,4 @@
- /* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ /* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -235,12 +235,12 @@ struct TRINITY_DLL_DECL npc_thrall_old_hillsbradAI : public npc_escortAI
case 9:
DoScriptText(SAY_TH_ARMORY, m_creature);
m_creature->AddUnitMovementFlag(MOVEMENTFLAG_WALK_MODE);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, THRALL_WEAPON_MODEL);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, THRALL_WEAPON_INFO);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+1, 781);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, THRALL_SHIELD_MODEL);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+2, THRALL_SHIELD_INFO);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+3, 1038);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, THRALL_WEAPON_MODEL);
+ //m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, THRALL_WEAPON_INFO);
+ //m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+1, 781);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, THRALL_SHIELD_MODEL);
+ //m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+2, THRALL_SHIELD_INFO);
+ //m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+3, 1038);
break;
case 10:
m_creature->SetUInt32Value(UNIT_FIELD_DISPLAYID, THRALL_MODEL_EQUIPPED);
@@ -278,7 +278,6 @@ struct TRINITY_DLL_DECL npc_thrall_old_hillsbradAI : public npc_escortAI
break;
case 31:
DoScriptText(SAY_TH_MOUNTS_UP, m_creature);
- m_creature->HandleEmoteCommand(EMOTE_ONESHOT_TALK);
DoMount();
break;
case 37:
@@ -347,11 +346,9 @@ struct TRINITY_DLL_DECL npc_thrall_old_hillsbradAI : public npc_escortAI
break;
case 96:
DoScriptText(SAY_TH_EPOCH_WONDER, m_creature);
- m_creature->HandleEmoteCommand(EMOTE_ONESHOT_TALK);
break;
case 97:
DoScriptText(SAY_TH_EPOCH_KILL_TARETHA, m_creature);
- m_creature->HandleEmoteCommand(EMOTE_ONESHOT_EXCLAMATION);
m_creature->RemoveUnitMovementFlag(MOVEMENTFLAG_WALK_MODE);
break;
case 98:
@@ -386,11 +383,11 @@ struct TRINITY_DLL_DECL npc_thrall_old_hillsbradAI : public npc_escortAI
//alot will happen here, thrall and taretha talk, erozion appear at spot to explain
m_creature->SummonCreature(EROZION_ENTRY,2646.47,680.416,55.38,4.16,TEMPSUMMON_TIMED_DESPAWN,120000);
}
- break;
+ break;
case 108:
- //last waypoint, just set Thrall invisible, respawn is turned off
+ //last waypoint, just set Thrall invisible, respawn is turned off
m_creature->SetVisibility(VISIBILITY_OFF);
- break;
+ break;
}
}
@@ -406,12 +403,8 @@ struct TRINITY_DLL_DECL npc_thrall_old_hillsbradAI : public npc_escortAI
{
DoUnmount();
HadMount = false;
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+1, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+2, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+3, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 0);
m_creature->SetUInt32Value(UNIT_FIELD_DISPLAYID, THRALL_MODEL_UNEQUIPPED);
}
if( IsBeingEscorted )
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_fathomlord_karathress.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_fathomlord_karathress.cpp
index 134dac56ca0..ac646413cb0 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_fathomlord_karathress.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_fathomlord_karathress.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -331,7 +331,7 @@ struct TRINITY_DLL_DECL boss_fathomguard_sharkkisAI : public ScriptedAI
pet = false;
- Creature *Pet = (Creature*) Unit::GetUnit(*m_creature, SummonedPet);
+ Creature *Pet = Unit::GetCreature(*m_creature, SummonedPet);
if( Pet && Pet->isAlive() )
{
Pet->DealDamage( Pet, Pet->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false );
@@ -348,7 +348,7 @@ struct TRINITY_DLL_DECL boss_fathomguard_sharkkisAI : public ScriptedAI
if (pInstance)
{
Creature *Karathress = NULL;
- Karathress = (Creature*)(Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_KARATHRESS)));
+ Karathress = (Unit::GetCreature((*m_creature), pInstance->GetData64(DATA_KARATHRESS)));
if (Karathress)
((boss_fathomlord_karathressAI*)Karathress->AI())->EventSharkkisDeath();
@@ -407,7 +407,7 @@ struct TRINITY_DLL_DECL boss_fathomguard_sharkkisAI : public ScriptedAI
if(TheBeastWithin_Timer < diff)
{
DoCast(m_creature, SPELL_THE_BEAST_WITHIN);
- Creature *Pet = (Creature*) Unit::GetUnit(*m_creature, SummonedPet);
+ Creature *Pet = Unit::GetCreature(*m_creature, SummonedPet);
if( Pet && Pet->isAlive() )
{
Pet->CastSpell( Pet, SPELL_PET_ENRAGE, true );
@@ -477,7 +477,7 @@ struct TRINITY_DLL_DECL boss_fathomguard_tidalvessAI : public ScriptedAI
if (pInstance)
{
Creature *Karathress = NULL;
- Karathress = (Creature*)(Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_KARATHRESS)));
+ Karathress = (Unit::GetCreature((*m_creature), pInstance->GetData64(DATA_KARATHRESS)));
if (Karathress)
if(!m_creature->isAlive() && Karathress)
@@ -519,7 +519,7 @@ struct TRINITY_DLL_DECL boss_fathomguard_tidalvessAI : public ScriptedAI
return;
}
- if( !m_creature->HasAura(SPELL_WINDFURY_WEAPON, 0) )
+ if( !m_creature->HasAura(SPELL_WINDFURY_WEAPON) )
{
DoCast(m_creature, SPELL_WINDFURY_WEAPON);
}
@@ -592,7 +592,7 @@ struct TRINITY_DLL_DECL boss_fathomguard_caribdisAI : public ScriptedAI
if (pInstance)
{
Creature *Karathress = NULL;
- Karathress = (Creature*)(Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_KARATHRESS)));
+ Karathress = (Unit::GetCreature((*m_creature), pInstance->GetData64(DATA_KARATHRESS)));
if (Karathress)
if(!m_creature->isAlive() && Karathress)
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_hydross_the_unstable.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_hydross_the_unstable.cpp
index e28fc77acd2..14012be1d1f 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_hydross_the_unstable.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_hydross_the_unstable.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lady_vashj.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lady_vashj.cpp
index 1a82ee38900..87bb245c382 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lady_vashj.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lady_vashj.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -370,7 +370,7 @@ struct TRINITY_DLL_DECL boss_lady_vashjAI : public ScriptedAI
Unit *target = NULL;
target = SelectUnit(SELECT_TARGET_RANDOM, 0);
- if(target && !target->HasAura(SPELL_STATIC_CHARGE_TRIGGER, 0))
+ if(target && !target->HasAura(SPELL_STATIC_CHARGE_TRIGGER))
//cast Static Charge every 2 seconds for 20 seconds
DoCast(target, SPELL_STATIC_CHARGE_TRIGGER);
@@ -576,12 +576,7 @@ struct TRINITY_DLL_DECL boss_lady_vashjAI : public ScriptedAI
}
}
};
-class TRINITY_DLL_DECL VashjSurgeAura : public Aura
-{
- public:
- VashjSurgeAura(SpellEntry *spell, uint32 eff, int32 *bp, Unit *target, Unit *caster) : Aura(spell, eff, bp, target, caster, NULL)
- {}
-};
+
//Enchanted Elemental
//If one of them reaches Vashj he will increase her damage done by 5%.
struct TRINITY_DLL_DECL mob_enchanted_elementalAI : public ScriptedAI
@@ -665,13 +660,14 @@ struct TRINITY_DLL_DECL mob_enchanted_elementalAI : public ScriptedAI
SpellEntry *spell = (SpellEntry *)GetSpellStore()->LookupEntry(SPELL_SURGE);
if( spell )
{
- for(uint32 i = 0;i<3;i++)
+ uint8 eff_mask=0;
+ for (int i=0; i<3; i++)
{
if (!spell->Effect[i])
continue;
-
- Vashj->AddAura(new VashjSurgeAura(spell, i, NULL, Vashj, Vashj));
+ eff_mask|=1<<i;
}
+ Vashj->AddAura(new Aura(spell, eff_mask, NULL, Vashj, Vashj));
}
m_creature->DealDamage(m_creature, m_creature->GetMaxHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
}
@@ -711,7 +707,7 @@ struct TRINITY_DLL_DECL mob_tainted_elementalAI : public ScriptedAI
if(pInstance)
{
Creature *Vashj = NULL;
- Vashj = (Creature*)(Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_LADYVASHJ)));
+ Vashj = (Unit::GetCreature((*m_creature), pInstance->GetData64(DATA_LADYVASHJ)));
if(Vashj)
((boss_lady_vashjAI*)Vashj->AI())->EventTaintedElementalDeath();
@@ -923,7 +919,7 @@ struct TRINITY_DLL_DECL mob_shield_generator_channelAI : public ScriptedAI
if(Vashj && Vashj->isAlive())
{
//start visual channel
- if (!Casted || !Vashj->HasAura(SPELL_MAGIC_BARRIER,0))
+ if (!Casted || !Vashj->HasAura(SPELL_MAGIC_BARRIER))
{
m_creature->CastSpell(Vashj,SPELL_MAGIC_BARRIER,true);
Casted = true;
@@ -945,7 +941,7 @@ bool ItemUse_item_tainted_core(Player *player, Item* _Item, SpellCastTargets con
}
Creature *Vashj = NULL;
- Vashj = (Creature*)(Unit::GetUnit((*player), pInstance->GetData64(DATA_LADYVASHJ)));
+ Vashj = (Unit::GetCreature((*player), pInstance->GetData64(DATA_LADYVASHJ)));
if(Vashj && ((boss_lady_vashjAI*)Vashj->AI())->Phase == 2)
{
if(targets.getGOTarget() && targets.getGOTarget()->GetTypeId()==TYPEID_GAMEOBJECT)
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_leotheras_the_blind.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_leotheras_the_blind.cpp
index 6c2588671e6..073649db5ee 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_leotheras_the_blind.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_leotheras_the_blind.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -65,12 +65,6 @@ EndScriptData */
#define SAY_FREE -1548019
#define SAY_DEATH -1548020
-class TRINITY_DLL_DECL InsidiousAura : public Aura {
-public:
- InsidiousAura(SpellEntry *spell, uint32 eff, int32 *bp, Unit *target, Unit *caster) : Aura(spell, eff, bp, target, caster, NULL)
- {}
-};
-
struct TRINITY_DLL_DECL mob_inner_demonAI : public ScriptedAI
{
mob_inner_demonAI(Creature *c) : ScriptedAI(c)
@@ -91,7 +85,7 @@ struct TRINITY_DLL_DECL mob_inner_demonAI : public ScriptedAI
void JustDied(Unit *victim)
{
Unit* pUnit = Unit::GetUnit((*m_creature),victimGUID);
- if (pUnit && pUnit->HasAura(SPELL_INSIDIOUS_WHISPER,0))
+ if (pUnit && pUnit->HasAura(SPELL_INSIDIOUS_WHISPER))
pUnit->RemoveAurasDueToSpell(SPELL_INSIDIOUS_WHISPER);
}
@@ -128,7 +122,7 @@ struct TRINITY_DLL_DECL mob_inner_demonAI : public ScriptedAI
}else Link_Timer -= diff;
- if(!m_creature->HasAura(AURA_DEMONIC_ALIGNMENT, 0))
+ if(!m_creature->HasAura(AURA_DEMONIC_ALIGNMENT))
DoCast(m_creature, AURA_DEMONIC_ALIGNMENT,true);
if(ShadowBolt_Timer < diff)
@@ -194,8 +188,8 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
InnderDemon_Count = 0;
m_creature->SetSpeed( MOVE_RUN, 2.0f, true);
m_creature->SetUInt32Value(UNIT_FIELD_DISPLAYID, MODEL_NIGHTELF);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY , 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID , 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 0);
m_creature->CastSpell(m_creature, SPELL_DUAL_WIELD, true);
m_creature->SetCorpseDelay(1000*60*60);
if(pInstance)
@@ -229,7 +223,7 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
}
void MoveInLineOfSight(Unit *who)
{
- if(m_creature->HasAura(AURA_BANISH, 0))
+ if(m_creature->HasAura(AURA_BANISH))
return;
if( !m_creature->getVictim() && who->isTargetableForAttack() && ( m_creature->IsHostileTo( who )) && who->isInAccessiblePlaceFor(m_creature) )
@@ -267,7 +261,7 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
}
// channelers == 0 remove banish aura
- if(AliveChannelers == 0 && m_creature->HasAura(AURA_BANISH, 0))
+ if(AliveChannelers == 0 && m_creature->HasAura(AURA_BANISH))
{
// removing banish aura
m_creature->RemoveAurasDueToSpell(AURA_BANISH);
@@ -290,7 +284,7 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
StartEvent();
}
}
- else if(AliveChannelers != 0 && !m_creature->HasAura(AURA_BANISH, 0))
+ else if(AliveChannelers != 0 && !m_creature->HasAura(AURA_BANISH))
{
// channelers != 0 apply banish aura
// removing Leotheras banish immune to apply AURA_BANISH
@@ -301,8 +295,8 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
m_creature->SetUInt32Value(UNIT_FIELD_DISPLAYID, MODEL_DEMON);
// and removing weapons
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY , 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID , 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 0);
}
}
@@ -390,7 +384,7 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
void Aggro(Unit *who)
{
- if(m_creature->HasAura(AURA_BANISH, 0))
+ if(m_creature->HasAura(AURA_BANISH))
return;
m_creature->LoadEquipment(m_creature->GetEquipmentId());
@@ -399,7 +393,7 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
void UpdateAI(const uint32 diff)
{
//Return since we have no target
- if (m_creature->HasAura(AURA_BANISH, 0) || !UpdateVictim())
+ if (m_creature->HasAura(AURA_BANISH) || !UpdateVictim())
{
if(BanishTimer<diff)
{
@@ -408,7 +402,7 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
}else BanishTimer -= diff;
return;
}
- if(m_creature->HasAura(SPELL_WHIRLWIND, 0))
+ if(m_creature->HasAura(SPELL_WHIRLWIND))
if(Whirlwind_Timer < diff)
{
Unit *newTarget = SelectUnit(SELECT_TARGET_RANDOM, 0);
@@ -422,7 +416,7 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
}else Whirlwind_Timer -= diff;
// reseting after changing forms and after ending whirlwind
- if(NeedThreatReset && !m_creature->HasAura(SPELL_WHIRLWIND, 0))
+ if(NeedThreatReset && !m_creature->HasAura(SPELL_WHIRLWIND))
{
// when changing forms seting timers (or when ending whirlwind - to avoid adding new variable i use Whirlwind_Timer to countdown 2s while whirlwinding)
if(DemonForm)
@@ -446,7 +440,7 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
if(!DemonForm)
{
//Whirldind Timer
- if(!m_creature->HasAura(SPELL_WHIRLWIND, 0))
+ if(!m_creature->HasAura(SPELL_WHIRLWIND))
{
if(Whirlwind_Timer < diff)
{
@@ -465,8 +459,8 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
m_creature->RemoveAurasDueToSpell(SPELL_WHIRLWIND,0);
m_creature->SetUInt32Value(UNIT_FIELD_DISPLAYID, MODEL_DEMON);
DoScriptText(SAY_SWITCH_TO_DEMON, m_creature);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY , 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID , 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 0);
DemonForm = true;
NeedThreatReset = true;
SwitchToDemon_Timer = 45000;
@@ -513,12 +507,14 @@ struct TRINITY_DLL_DECL boss_leotheras_the_blindAI : public ScriptedAI
((ScriptedAI *)demon->AI())->AttackStart( (*itr) );
((mob_inner_demonAI *)demon->AI())->victimGUID = (*itr)->GetGUID();
+ uint8 eff_mask=0;
for (int i=0; i<3; i++)
{
if (!spell->Effect[i])
continue;
- (*itr)->AddAura(new InsidiousAura(spell, i, NULL, (*itr), (*itr)));
+ eff_mask|=1<<i;
}
+ (*itr)->AddAura(new Aura(spell, eff_mask, NULL, (*itr), (*itr)));
if( InnderDemon_Count > 4 ) InnderDemon_Count = 0;
//Safe storing of creatures
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lurker_below.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lurker_below.cpp
index 02125f5fd38..653799f08f5 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lurker_below.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_lurker_below.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -266,7 +266,7 @@ struct TRINITY_DLL_DECL boss_the_lurker_belowAI : public Scripted_NoMovementAI
for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
{
- if (i->getSource()->isAlive() && i->getSource()->IsInWater() && !i->getSource()->HasAura(SPELL_SCALDINGWATER, 0))
+ if (i->getSource()->isAlive() && i->getSource()->IsInWater() && !i->getSource()->HasAura(SPELL_SCALDINGWATER))
i->getSource()->CastSpell(i->getSource(), SPELL_SCALDINGWATER, true);
else if(!i->getSource()->IsInWater())
i->getSource()->RemoveAurasDueToSpell(SPELL_SCALDINGWATER);
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_morogrim_tidewalker.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_morogrim_tidewalker.cpp
index 7d56bbf6d2a..35f3f5b9b13 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_morogrim_tidewalker.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/boss_morogrim_tidewalker.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/def_serpent_shrine.h b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/def_serpent_shrine.h
index aceabea4b5c..13144bc93c0 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/def_serpent_shrine.h
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/def_serpent_shrine.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/instance_serpent_shrine.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/instance_serpent_shrine.cpp
index 0aceef32714..adf2eda7c39 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/instance_serpent_shrine.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/serpent_shrine/instance_serpent_shrine.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -137,12 +137,12 @@ struct TRINITY_DLL_DECL instance_serpentshrine_cavern : public ScriptedInstance
void OpenDoor(uint64 DoorGUID, bool open)
{
if(GameObject *Door = instance->GetGameObjectInMap(DoorGUID))
- Door->SetUInt32Value(GAMEOBJECT_STATE, open ? 0 : 1);
+ Door->SetGoState(open ? 0 : 1);
}
void OnCreatureCreate(Creature *creature, uint32 creature_entry)
{
- switch(creature_entry)
+ switch(creature->GetEntry())
{
case 21212: LadyVashj = creature->GetGUID(); break;
case 21214: Karathress = creature->GetGUID(); break;
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_hydromancer_thespia.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_hydromancer_thespia.cpp
index cafbf8e3f4f..8ffee603597 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_hydromancer_thespia.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_hydromancer_thespia.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_mekgineer_steamrigger.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_mekgineer_steamrigger.cpp
index 1515b14e3a2..e5b12065298 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_mekgineer_steamrigger.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_mekgineer_steamrigger.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_warlord_kalithresh.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_warlord_kalithresh.cpp
index 7090d678768..ede9a38126f 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_warlord_kalithresh.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/boss_warlord_kalithresh.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -143,7 +143,7 @@ struct TRINITY_DLL_DECL boss_warlord_kalithreshAI : public ScriptedAI
cell.SetNoCreate();
Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck creature_check(*m_creature, entry, true, range);
- Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck> searcher(pCreature, creature_check);
+ Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck> searcher(m_creature, pCreature, creature_check);
TypeContainerVisitor<Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck>, GridTypeMapContainer> creature_searcher(searcher);
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/def_steam_vault.h b/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/def_steam_vault.h
index 09a76d482b7..4b407ac4816 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/def_steam_vault.h
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/def_steam_vault.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/instance_steam_vault.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/instance_steam_vault.cpp
index b76cfedb777..92df1fffbe1 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/instance_steam_vault.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/steam_vault/instance_steam_vault.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/underbog/boss_hungarfen.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/underbog/boss_hungarfen.cpp
index 328bd8ee1ce..99d313d303a 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/underbog/boss_hungarfen.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/underbog/boss_hungarfen.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/coilfang_resevoir/underbog/boss_the_black_stalker.cpp b/src/bindings/scripts/scripts/zone/coilfang_resevoir/underbog/boss_the_black_stalker.cpp
index 5153edb5e62..d7c9791cf51 100644
--- a/src/bindings/scripts/scripts/zone/coilfang_resevoir/underbog/boss_the_black_stalker.cpp
+++ b/src/bindings/scripts/scripts/zone/coilfang_resevoir/underbog/boss_the_black_stalker.cpp
@@ -121,7 +121,7 @@ struct TRINITY_DLL_DECL boss_the_black_stalkerAI : public ScriptedAI
{
if(Unit* target = (Unit*)Unit::GetUnit(*m_creature, LevitatedTarget))
{
- if(!target->HasAura(SPELL_LEVITATE,0))
+ if(!target->HasAura(SPELL_LEVITATE))
{
LevitatedTarget = 0;
return;
@@ -131,7 +131,7 @@ struct TRINITY_DLL_DECL boss_the_black_stalkerAI : public ScriptedAI
target->AddAura(SPELL_SUSPENSION, target);
LevitatedTarget = 0;
}
- else
+ else
{
target->CastSpell(target, SPELL_MAGNETIC_PULL, true);
InAir = true;
diff --git a/src/bindings/scripts/scripts/zone/darkshore/darkshore.cpp b/src/bindings/scripts/scripts/zone/darkshore/darkshore.cpp
index aea0e52e4f7..fcb13e9f479 100644
--- a/src/bindings/scripts/scripts/zone/darkshore/darkshore.cpp
+++ b/src/bindings/scripts/scripts/zone/darkshore/darkshore.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/deadmines/deadmines.cpp b/src/bindings/scripts/scripts/zone/deadmines/deadmines.cpp
index 3f71dc9041b..cafdc5fbc46 100644
--- a/src/bindings/scripts/scripts/zone/deadmines/deadmines.cpp
+++ b/src/bindings/scripts/scripts/zone/deadmines/deadmines.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -69,7 +69,7 @@ struct TRINITY_DLL_DECL instance_deadmines : public ScriptedInstance
CannonBlast_Timer = CANNON_BLAST_TIMER;
// it's a hack - Mr. Smite should do that but his too far away
IronCladDoor->SetName("Mr. Smite");
- IronCladDoor->Yell(SAY_MR_SMITE_ALARM1, LANG_UNIVERSAL, 0);
+ IronCladDoor->MonsterYell(SAY_MR_SMITE_ALARM1, LANG_UNIVERSAL, 0);
DoPlaySound(IronCladDoor, SOUND_MR_SMITE_ALARM1);
State=CANNON_BLAST_INITIATED;
break;
@@ -81,7 +81,7 @@ struct TRINITY_DLL_DECL instance_deadmines : public ScriptedInstance
ShootCannon();
BlastOutDoor();
LeverStucked();
- IronCladDoor->Yell(SAY_MR_SMITE_ALARM2, LANG_UNIVERSAL, 0);
+ IronCladDoor->MonsterYell(SAY_MR_SMITE_ALARM2, LANG_UNIVERSAL, 0);
DoPlaySound(IronCladDoor, SOUND_MR_SMITE_ALARM2);
State = PIRATES_ATTACK;
}else
@@ -120,13 +120,13 @@ struct TRINITY_DLL_DECL instance_deadmines : public ScriptedInstance
void ShootCannon()
{
- DefiasCannon->SetUInt32Value(GAMEOBJECT_STATE, 0);
+ DefiasCannon->SetGoState(0);
DoPlaySound(DefiasCannon, SOUND_CANNONFIRE);
}
void BlastOutDoor()
{
- IronCladDoor->SetUInt32Value(GAMEOBJECT_STATE, 2);
+ IronCladDoor->SetGoState(2);
DoPlaySound(IronCladDoor, SOUND_DESTROYDOOR);
}
diff --git a/src/bindings/scripts/scripts/zone/draktharon_keep/boss_dred.cpp b/src/bindings/scripts/scripts/zone/draktharon_keep/boss_dred.cpp
new file mode 100644
index 00000000000..a1980b7506b
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/draktharon_keep/boss_dred.cpp
@@ -0,0 +1,56 @@
+/* Script Data Start
+SDName: Boss dred
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_BELLOWING_ROAR 44863 // fears the group, can be resisted/dispelled
+#define SPELL_GRIEVOUS_BITE 48920
+#define SPELL_MANGLING_SLASH 48873 //casted on the current tank, adds debuf
+#define SPELL_FEARSOME_ROAR_N 48849
+#define SPELL_FEARSOME_ROAR_H 48849 //Not stacking, debuff
+#define SPELL_PIERCING_SLASH 48878 //debuff -->Armor reduced by 75%
+#define SPELL_RAPTOR_CALL 59416 //dummy
+
+
+struct TRINITY_DLL_DECL boss_dredAI : public ScriptedAI
+{
+ boss_dredAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+CreatureAI* GetAI_boss_dred(Creature *_Creature)
+{
+ return new boss_dredAI (_Creature);
+}
+
+void AddSC_boss_dred()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_dred";
+ newscript->GetAI = GetAI_boss_dred;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/draktharon_keep/boss_novos.cpp b/src/bindings/scripts/scripts/zone/draktharon_keep/boss_novos.cpp
new file mode 100644
index 00000000000..54392bc3b1f
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/draktharon_keep/boss_novos.cpp
@@ -0,0 +1,75 @@
+/* Script Data Start
+SDName: Boss novos
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_novos' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_ARCANE_BLAST_N 49198
+#define SPELL_ARCANE_BLAST_H 59909
+#define SPELL_ARCANE_FIELD 47346
+#define SPELL_BLIZZARD_N 49034
+#define SPELL_BLIZZARD_H 59854
+#define SPELL_FROSTBOLT_N 49037
+#define SPELL_FROSTBOLT_H 59855
+#define SPELL_WRATH_OF_MISERY_N 50089
+#define SPELL_WRATH_OF_MISERY_H 59856
+#define SPELL_SUMMON_MINIONS 59910 //Summons an army of Fetid Troll Corpses to assist the caster.
+
+//Yell
+#define SAY_AGGRO -1600000
+#define SAY_KILL -1600001
+#define SAY_DEATH -1600002
+#define SAY_NECRO_ADD -1600003
+#define SAY_REUBBLE_1 -1600004
+#define SAY_REUBBLE_2 -1600005
+
+struct TRINITY_DLL_DECL boss_novosAI : public ScriptedAI
+{
+ boss_novosAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+ DoScriptText(SAY_KILL, m_creature);
+ }
+};
+
+CreatureAI* GetAI_boss_novos(Creature *_Creature)
+{
+ return new boss_novosAI (_Creature);
+}
+
+void AddSC_boss_novos()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_novos";
+ newscript->GetAI = GetAI_boss_novos;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/draktharon_keep/boss_tharon_ja.cpp b/src/bindings/scripts/scripts/zone/draktharon_keep/boss_tharon_ja.cpp
new file mode 100644
index 00000000000..1454a9de8f5
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/draktharon_keep/boss_tharon_ja.cpp
@@ -0,0 +1,88 @@
+/* Script Data Start
+SDName: Boss tharon_ja
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_tharon_ja' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_COURSE_OF_LIFE 49527
+#define SPELL_DECAY_FLESH 49356 //casted at end of pahase 1, starts phase 2
+#define SPELL_EYE_BEAM_N 49544
+#define SPELL_LIGHTNING_BREATH_N 49537
+#define SPELL_POISON_CLOUD_N 49548
+#define SPELL_RAIN_OF_FIRE_N 49518
+#define SPELL_RETURN_FLESH 53463 //Channeled spell ending phase two and returning to phase 1. This ability will stun the party for 6 seconds.
+#define SPELL_SHADOW_VOLLEY_N 49528
+
+//Spells Heroic
+#define SPELL_COURSE_OF_LIFE_H 59972
+#define SPELL_EYE_BEAM_H 59965
+#define SPELL_LIGHTNING_BREATH_H 59963
+#define SPELL_POISON_CLOUD_H 59969
+#define SPELL_RAIN_OF_FIRE_H 59971
+#define SPELL_SHADOW_VOLLEY_H 59973
+
+//Players skills durring Phase2
+#define PLAYER_PHASE2_SLAYING_STRIKE 50799
+#define PLAYER_PHASE2_TAUNT 49613
+#define PLAYER_PHASE2_BONE_ARMOR 49609
+#define PLAYER_PHASE2_TOUCH_OF_LIFE 49617
+//Phase 1 all abilities except Eye beam
+//Phase 2 turns players to skeletons with new abilities, boss grows skin
+
+//Yell
+#define SAY_AGGRO 1600011
+#define SAY_KILL_1 1600012
+#define SAY_KILL_2 1600013
+#define SAY_FLESH_1 1600014
+#define SAY_FLESH_2 1600015
+#define SAY_SKELETON_1 1600016
+#define SAY_SKELETON_2 1600017
+#define SAY_DEATH 1600018
+
+struct TRINITY_DLL_DECL boss_tharon_jaAI : public ScriptedAI
+{
+ boss_tharon_jaAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH,m_creature);
+ }
+};
+
+CreatureAI* GetAI_boss_tharon_ja(Creature *_Creature)
+{
+ return new boss_tharon_jaAI (_Creature);
+}
+
+void AddSC_boss_tharon_ja()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_tharon_ja";
+ newscript->GetAI = GetAI_boss_tharon_ja;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/draktharon_keep/boss_trollgore.cpp b/src/bindings/scripts/scripts/zone/draktharon_keep/boss_trollgore.cpp
new file mode 100644
index 00000000000..bfc123edb4d
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/draktharon_keep/boss_trollgore.cpp
@@ -0,0 +1,75 @@
+/* Script Data Start
+SDName: Boss trollgore
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_trollgore' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spell
+#define SPELL_INFECTED_WOUND 49637
+#define SPELL_CRUSH 49639
+#define SPELL_CORPSE_EXPLODE_N 49555
+#define SPELL_CONSUME_N 49380
+
+//Spell Heroic
+#define SPELL_CORPSE_EXPLODE_H 59807
+#define SPELL_CONSUME_H 59803
+
+//Yell
+#define SAY_AGGRO -1600006
+#define SAY_KILL -1600007
+#define SAY_CONSUME -1600008
+#define SAY_EXPLODE -1600009
+#define SAY_DEATH -1600010
+
+struct TRINITY_DLL_DECL boss_trollgoreAI : public ScriptedAI
+{
+ boss_trollgoreAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+ DoScriptText(SAY_KILL, m_creature);
+ }
+};
+
+CreatureAI* GetAI_boss_trollgore(Creature *_Creature)
+{
+ return new boss_trollgoreAI (_Creature);
+}
+
+void AddSC_boss_trollgore()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_trollgore";
+ newscript->GetAI = GetAI_boss_trollgore;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/draktharon_keep/def_drak_tharon_keep.h b/src/bindings/scripts/scripts/zone/draktharon_keep/def_drak_tharon_keep.h
new file mode 100644
index 00000000000..321d77a9c27
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/draktharon_keep/def_drak_tharon_keep.h
@@ -0,0 +1,4 @@
+#ifndef DEF_DRAK_THARON_H
+#define DEF_DRAK_THARON_H
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/draktharon_keep/instance_drak_tharon_keep.cpp b/src/bindings/scripts/scripts/zone/draktharon_keep/instance_drak_tharon_keep.cpp
new file mode 100644
index 00000000000..3f3cd32e764
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/draktharon_keep/instance_drak_tharon_keep.cpp
@@ -0,0 +1,21 @@
+#include "precompiled.h"
+#include "def_drak_tharon_keep.h"
+
+struct TRINITY_DLL_DECL instance_drak_tharon : public ScriptedInstance
+{
+ instance_drak_tharon(Map *Map) : ScriptedInstance(Map) {Initialize();};
+};
+
+InstanceData* GetInstanceData_instance_drak_tharon(Map* map)
+{
+ return new instance_drak_tharon(map);
+}
+
+void AddSC_instance_drak_tharon()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_drak_tharon";
+ newscript->GetInstanceData = GetInstanceData_instance_drak_tharon;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/dun_morogh/dun_morogh.cpp b/src/bindings/scripts/scripts/zone/dun_morogh/dun_morogh.cpp
index abba40ffe2a..c9cc4625b97 100644
--- a/src/bindings/scripts/scripts/zone/dun_morogh/dun_morogh.cpp
+++ b/src/bindings/scripts/scripts/zone/dun_morogh/dun_morogh.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -44,7 +44,7 @@ struct TRINITY_DLL_DECL npc_narm_faulkAI : public ScriptedAI
{
lifeTimer = 120000;
m_creature->SetUInt32Value(UNIT_DYNAMIC_FLAGS, 32);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,7); // lay down
+ m_creature->SetStandState(UNIT_STAND_STATE_DEAD);
spellHit = false;
}
@@ -59,7 +59,7 @@ struct TRINITY_DLL_DECL npc_narm_faulkAI : public ScriptedAI
void UpdateAI(const uint32 diff)
{
- if (!m_creature->GetUInt32Value(UNIT_FIELD_BYTES_1))
+ if (m_creature->IsStandState())
{
if(lifeTimer < diff)
m_creature->AI()->EnterEvadeMode();
@@ -73,7 +73,7 @@ struct TRINITY_DLL_DECL npc_narm_faulkAI : public ScriptedAI
if(Spellkind->Id == 8593 && !spellHit)
{
DoCast(m_creature,32343);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,0);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
m_creature->SetUInt32Value(UNIT_DYNAMIC_FLAGS, 0);
//m_creature->RemoveAllAuras();
DoScriptText(SAY_HEAL, m_creature);
diff --git a/src/bindings/scripts/scripts/zone/dustwallow_marsh/dustwallow_marsh.cpp b/src/bindings/scripts/scripts/zone/dustwallow_marsh/dustwallow_marsh.cpp
index 6e3e0fbb6d7..67f68334410 100644
--- a/src/bindings/scripts/scripts/zone/dustwallow_marsh/dustwallow_marsh.cpp
+++ b/src/bindings/scripts/scripts/zone/dustwallow_marsh/dustwallow_marsh.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/eastern_plaguelands/eastern_plaguelands.cpp b/src/bindings/scripts/scripts/zone/eastern_plaguelands/eastern_plaguelands.cpp
index 6d068ec1543..167dd0455af 100644
--- a/src/bindings/scripts/scripts/zone/eastern_plaguelands/eastern_plaguelands.cpp
+++ b/src/bindings/scripts/scripts/zone/eastern_plaguelands/eastern_plaguelands.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -118,7 +118,7 @@ bool GossipHello_npc_tirion_fordring(Player *player, Creature *_Creature)
if (_Creature->isQuestGiver())
player->PrepareQuestMenu( _Creature->GetGUID() );
- if (player->GetQuestStatus(5742) == QUEST_STATUS_INCOMPLETE && player->getStandState() == PLAYER_STATE_SIT )
+ if (player->GetQuestStatus(5742) == QUEST_STATUS_INCOMPLETE && player->getStandState() == UNIT_STAND_STATE_SIT )
player->ADD_GOSSIP_ITEM( 0, "I am ready to hear your tale, Tirion.", GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
player->SEND_GOSSIP_MENU(_Creature->GetNpcTextId(), _Creature->GetGUID());
diff --git a/src/bindings/scripts/scripts/zone/elwynn_forest/elwynn_forest.cpp b/src/bindings/scripts/scripts/zone/elwynn_forest/elwynn_forest.cpp
index 2e07f91984c..d1fa414ea11 100644
--- a/src/bindings/scripts/scripts/zone/elwynn_forest/elwynn_forest.cpp
+++ b/src/bindings/scripts/scripts/zone/elwynn_forest/elwynn_forest.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -44,7 +44,7 @@ struct TRINITY_DLL_DECL npc_henze_faulkAI : public ScriptedAI
{
lifeTimer = 120000;
m_creature->SetUInt32Value(UNIT_DYNAMIC_FLAGS, 32);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,7); // lay down
+ m_creature->SetStandState(UNIT_STAND_STATE_DEAD); // lay down
spellHit = false;
}
@@ -59,7 +59,7 @@ struct TRINITY_DLL_DECL npc_henze_faulkAI : public ScriptedAI
void UpdateAI(const uint32 diff)
{
- if (!m_creature->GetUInt32Value(UNIT_FIELD_BYTES_1))
+ if (m_creature->IsStandState())
{
if(lifeTimer < diff)
m_creature->AI()->EnterEvadeMode();
@@ -73,7 +73,7 @@ struct TRINITY_DLL_DECL npc_henze_faulkAI : public ScriptedAI
if(Spellkind->Id == 8593 && !spellHit)
{
DoCast(m_creature,32343);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,0);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
m_creature->SetUInt32Value(UNIT_DYNAMIC_FLAGS, 0);
//m_creature->RemoveAllAuras();
DoScriptText(SAY_HEAL, m_creature);
diff --git a/src/bindings/scripts/scripts/zone/eversong_woods/eversong_woods.cpp b/src/bindings/scripts/scripts/zone/eversong_woods/eversong_woods.cpp
index 7340ac5c073..e420446abe8 100644
--- a/src/bindings/scripts/scripts/zone/eversong_woods/eversong_woods.cpp
+++ b/src/bindings/scripts/scripts/zone/eversong_woods/eversong_woods.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -17,12 +17,11 @@
/* ScriptData
SDName: Eversong_Woods
SD%Complete: 100
-SDComment: Quest support: 8346, 8483, 8488, 8490
+SDComment: Quest support: 8483, 8488, 8490
SDCategory: Eversong Woods
EndScriptData */
/* ContentData
-mobs_mana_tapped
npc_prospector_anvilward
npc_apprentice_mirveda
npc_infused_crystal
@@ -32,31 +31,6 @@ EndContentData */
#include "../../npc/npc_escortAI.h"
/*######
-## mobs_mana_tapped
-######*/
-
-struct TRINITY_DLL_DECL mobs_mana_tappedAI : public ScriptedAI
-{
- mobs_mana_tappedAI(Creature *c) : ScriptedAI(c) {}
-
- void Reset() { }
-
- void Aggro(Unit *who) { }
-
- void SpellHit(Unit *caster, const SpellEntry *spell)
- {
- if( caster->GetTypeId() == TYPEID_PLAYER)
- if( ((Player*)caster)->GetQuestStatus(8346) == QUEST_STATUS_INCOMPLETE && !((Player*)caster)->GetReqKillOrCastCurrentCount(8346, m_creature->GetEntry()) && spell->Id == 28734)
- ((Player*)caster)->CastedCreatureOrGO(15468, m_creature->GetGUID(), spell->Id);
- return;
- }
-};
-CreatureAI* GetAI_mobs_mana_tapped(Creature *_Creature)
-{
- return new mobs_mana_tappedAI (_Creature);
-}
-
-/*######
## npc_prospector_anvilward
######*/
@@ -107,18 +81,11 @@ struct TRINITY_DLL_DECL npc_prospector_anvilwardAI : public npc_escortAI
}
};
-CreatureAI* GetAI_npc_prospector_anvilward(Creature *_Creature)
+CreatureAI* GetAI_npc_prospector_anvilward(Creature* pCreature)
{
- npc_prospector_anvilwardAI* thisAI = new npc_prospector_anvilwardAI(_Creature);
+ npc_prospector_anvilwardAI* thisAI = new npc_prospector_anvilwardAI(pCreature);
- thisAI->AddWaypoint(0, 9294.78, -6682.51, 22.42);
- thisAI->AddWaypoint(1, 9298.27, -6667.99, 22.42);
- thisAI->AddWaypoint(2, 9309.63, -6658.84, 22.43);
- thisAI->AddWaypoint(3, 9304.43, -6649.31, 26.46);
- thisAI->AddWaypoint(4, 9298.83, -6648.00, 28.61);
- thisAI->AddWaypoint(5, 9291.06, -6653.46, 31.83, 2500);
- thisAI->AddWaypoint(6, 9289.08, -6660.17, 31.85, 5000);
- thisAI->AddWaypoint(7, 9291.06, -6653.46, 31.83);
+ thisAI->FillPointMovementListForCreature();
return (CreatureAI*)thisAI;
}
@@ -229,7 +196,7 @@ struct TRINITY_DLL_DECL npc_secondTrialAI : public ScriptedAI
questPhase = 0;
summonerGuid = 0;
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, PLAYER_STATE_KNEEL);
+ m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, UNIT_STAND_STATE_KNEEL);
m_creature->setFaction(FACTION_FRIENDLY);
spellFlashLight = false;
@@ -268,7 +235,7 @@ struct TRINITY_DLL_DECL npc_secondTrialAI : public ScriptedAI
if ( questPhase == 1 ) {
if ( timer < diff ) {
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, PLAYER_STATE_NONE);
+ m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, UNIT_STAND_STATE_STAND);
m_creature->setFaction(FACTION_HOSTILE);
questPhase = 0;
@@ -539,7 +506,7 @@ bool GOHello_go_second_trial(Player *player, GameObject* _GO)
Creature* event_controller = NULL;
Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck u_check(*_GO, MASTER_KELERUN_BLOODMOURN, true, 30);
- Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck> searcher(event_controller, u_check);
+ Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck> searcher(player, event_controller, u_check);
TypeContainerVisitor<Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck>, GridTypeMapContainer > grid_unit_searcher(searcher);
//cell_lock->Visit(cell_lock, grid_unit_searcher, *MapManager::Instance().GetMap(_GO->GetMap(), _GO));
cell_lock->Visit(cell_lock, grid_unit_searcher, *(_GO->GetMap()));
@@ -754,11 +721,6 @@ void AddSC_eversong_woods()
Script *newscript;
newscript = new Script;
- newscript->Name="mobs_mana_tapped";
- newscript->GetAI = &GetAI_mobs_mana_tapped;
- newscript->RegisterSelf();
-
- newscript = new Script;
newscript->Name= "npc_prospector_anvilward";
newscript->GetAI = &GetAI_npc_prospector_anvilward;
newscript->pGossipHello = &GossipHello_npc_prospector_anvilward;
diff --git a/src/bindings/scripts/scripts/zone/felwood/felwood.cpp b/src/bindings/scripts/scripts/zone/felwood/felwood.cpp
index b7a4bc03c59..4103283be43 100644
--- a/src/bindings/scripts/scripts/zone/felwood/felwood.cpp
+++ b/src/bindings/scripts/scripts/zone/felwood/felwood.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/feralas/feralas.cpp b/src/bindings/scripts/scripts/zone/feralas/feralas.cpp
index f3822bcdb7a..ff30fc3f90c 100644
--- a/src/bindings/scripts/scripts/zone/feralas/feralas.cpp
+++ b/src/bindings/scripts/scripts/zone/feralas/feralas.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/ghostlands/ghostlands.cpp b/src/bindings/scripts/scripts/zone/ghostlands/ghostlands.cpp
index bdd36dba074..00e00b2ac90 100644
--- a/src/bindings/scripts/scripts/zone/ghostlands/ghostlands.cpp
+++ b/src/bindings/scripts/scripts/zone/ghostlands/ghostlands.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -135,17 +135,21 @@ bool GOHello_gilded_brazier(Player *player, GameObject* _GO)
## npc_ranger_lilatha
######*/
-#define SAY_START -1000140
-#define SAY_PROGRESS1 -1000141
-#define SAY_PROGRESS2 -1000142
-#define SAY_PROGRESS3 -1000143
-#define SAY_END1 -1000144
-#define SAY_END2 -1000145
-#define SAY_CAPTAIN_ANSWER -1000146
-
-#define QUEST_ESCAPE_FROM_THE_CATACOMBS 9212
-#define GO_CAGE 181152
-#define NPC_CAPTAIN_HELIOS 16220
+enum
+{
+ SAY_START = -1000140,
+ SAY_PROGRESS1 = -1000141,
+ SAY_PROGRESS2 = -1000142,
+ SAY_PROGRESS3 = -1000143,
+ SAY_END1 = -1000144,
+ SAY_END2 = -1000145,
+ SAY_CAPTAIN_ANSWER = -1000146,
+
+ QUEST_ESCAPE_FROM_THE_CATACOMBS = 9212,
+ GO_CAGE = 181152,
+ NPC_CAPTAIN_HELIOS = 16220,
+ FACTION_SMOON_E = 1603,
+};
struct TRINITY_DLL_DECL npc_ranger_lilathaAI : public npc_escortAI
{
@@ -249,41 +253,7 @@ CreatureAI* GetAI_npc_ranger_lilathaAI(Creature *_Creature)
{
npc_ranger_lilathaAI* ranger_lilathaAI = new npc_ranger_lilathaAI(_Creature);
- ranger_lilathaAI->AddWaypoint(0, 7545.07, -7359.87, 162.354, 4000); // Say0
- ranger_lilathaAI->AddWaypoint(1, 7550.048340, -7362.237793, 162.235657);
- ranger_lilathaAI->AddWaypoint(2, 7566.976074, -7364.315430, 161.738770);
- ranger_lilathaAI->AddWaypoint(3, 7578.830566, -7361.677734, 161.738770);
- ranger_lilathaAI->AddWaypoint(4, 7590.969238, -7359.053711, 162.257660);
- ranger_lilathaAI->AddWaypoint(5, 7598.354004, -7362.815430, 162.256683, 4000); // Say1
- ranger_lilathaAI->AddWaypoint(6, 7605.861328, -7380.424316, 161.937073);
- ranger_lilathaAI->AddWaypoint(7, 7605.295410, -7387.382813, 157.253998);
- ranger_lilathaAI->AddWaypoint(8, 7606.131836, -7393.893555, 156.941925);
- ranger_lilathaAI->AddWaypoint(9, 7615.207520, -7400.187012, 157.142639);
- ranger_lilathaAI->AddWaypoint(10, 7618.956543, -7402.652832, 158.202042);
- ranger_lilathaAI->AddWaypoint(11, 7636.850586, -7401.756836, 162.144791);
- ranger_lilathaAI->AddWaypoint(12, 7637.058105, -7404.944824, 162.206970, 4000);// Say2
- ranger_lilathaAI->AddWaypoint(13, 7636.910645, -7412.585449, 162.366425);
- ranger_lilathaAI->AddWaypoint(14, 7637.607910, -7425.591797, 162.630661);
- ranger_lilathaAI->AddWaypoint(15, 7637.816895, -7459.057129, 163.302704);
- ranger_lilathaAI->AddWaypoint(16, 7638.859863, -7470.902344, 162.517059);
- ranger_lilathaAI->AddWaypoint(17, 7641.395996, -7488.217285, 157.381287);
- ranger_lilathaAI->AddWaypoint(18, 7634.455566, -7505.451660, 154.682159);
- ranger_lilathaAI->AddWaypoint(19, 7631.906738, -7516.948730, 153.597382); // say3
- ranger_lilathaAI->AddWaypoint(20, 7622.231445, -7537.037598, 151.587112);
- ranger_lilathaAI->AddWaypoint(21, 7610.921875, -7550.670410, 149.639374);
- ranger_lilathaAI->AddWaypoint(22, 7598.229004, -7562.551758, 145.953888);
- ranger_lilathaAI->AddWaypoint(23, 7588.509277, -7577.755371, 148.294479);
- ranger_lilathaAI->AddWaypoint(24, 7567.339355, -7608.456055, 146.006485);
- ranger_lilathaAI->AddWaypoint(25, 7562.547852, -7617.417969, 148.097504);
- ranger_lilathaAI->AddWaypoint(26, 7561.508789, -7645.064453, 151.245163);
- ranger_lilathaAI->AddWaypoint(27, 7563.337402, -7654.652344, 151.227158);
- ranger_lilathaAI->AddWaypoint(28, 7565.533691, -7658.296387, 151.248886);
- ranger_lilathaAI->AddWaypoint(29, 7571.155762, -7659.118652, 151.244568);
- ranger_lilathaAI->AddWaypoint(30, 7579.119629, -7662.213867, 151.651505);
- ranger_lilathaAI->AddWaypoint(31, 7603.768066, -7667.000488, 153.997726);
- ranger_lilathaAI->AddWaypoint(32, 7603.768066, -7667.000488, 153.997726, 4000); // Say4 & Set orientation
- ranger_lilathaAI->AddWaypoint(33, 7603.768066, -7667.000488, 153.997726, 8000); // Say5 & Set orientation
- ranger_lilathaAI->AddWaypoint(34, 7603.768066, -7667.000488, 153.997726);
+ ranger_lilathaAI->FillPointMovementListForCreature();
return (CreatureAI*)ranger_lilathaAI;
}
diff --git a/src/bindings/scripts/scripts/zone/gruuls_lair/boss_gruul.cpp b/src/bindings/scripts/scripts/zone/gruuls_lair/boss_gruul.cpp
index a651c117d7a..e4fdbf90656 100644
--- a/src/bindings/scripts/scripts/zone/gruuls_lair/boss_gruul.cpp
+++ b/src/bindings/scripts/scripts/zone/gruuls_lair/boss_gruul.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -6,12 +6,12 @@
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/* ScriptData
@@ -24,7 +24,6 @@ EndScriptData */
#include "precompiled.h"
#include "def_gruuls_lair.h"
-/* Yells & Quotes */
#define SAY_AGGRO -1565010
#define SAY_SLAM1 -1565011
#define SAY_SLAM2 -1565012
@@ -36,17 +35,18 @@ EndScriptData */
#define SAY_DEATH -1565018
#define EMOTE_GROW -1565019
-/* Spells */
-#define SPELL_GROWTH 36300
-#define SPELL_CAVE_IN 36240
-#define SPELL_GROUND_SLAM 33525 // AoE Ground Slam applying Ground Slam to everyone with a script effect (most likely the knock back, we can code it to a set knockback)
-#define SPELL_REVERBERATION 36297 //AoE Silence
-#define SPELL_SHATTER 33654
-#define SPELL_MAGNETIC_PULL 28337
-#define SPELL_KNOCK_BACK 24199 //Knockback spell until correct implementation is made
+#define SPELL_GROWTH 36300
+#define SPELL_CAVE_IN 36240
+#define SPELL_GROUND_SLAM 33525 //AoE Ground Slam applying Ground Slam to everyone with a script effect (most likely the knock back, we can code it to a set knockback)
+#define SPELL_REVERBERATION 36297 //AoE Silence
+#define SPELL_SHATTER 33654
+
#define SPELL_SHATTER_EFFECT 33671
#define SPELL_HURTFUL_STRIKE 33813
#define SPELL_STONED 33652 //Spell is self cast
+#define SPELL_MAGNETIC_PULL 28337
+#define SPELL_KNOCK_BACK 24199 //Knockback spell until correct implementation is made
+
#define SPELL_GRONN_LORDS_GRASP 33572 //Triggered by Ground Slam
struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
@@ -60,6 +60,7 @@ struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
uint32 Growth_Timer;
uint32 CaveIn_Timer;
+ uint32 CaveIn_StaticTimer;
uint32 GroundSlamTimer;
uint32 GroundSlamStage;
uint32 PerformingGroundSlam;
@@ -69,31 +70,26 @@ struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
void Reset()
{
Growth_Timer= 30000;
- CaveIn_Timer= 40000;
+ CaveIn_Timer= 27000;
+ CaveIn_StaticTimer = 30000;
GroundSlamTimer= 35000;
GroundSlamStage= 0;
PerformingGroundSlam= false;
HurtfulStrike_Timer= 8000;
Reverberation_Timer= 60000+45000;
- if(pInstance)
+ if (pInstance)
pInstance->SetData(DATA_GRUULEVENT, NOT_STARTED);
- }
-
- void JustDied(Unit* Killer)
- {
- DoScriptText(SAY_DEATH, m_creature);
- if(pInstance)
- pInstance->SetData(DATA_GRUULEVENT, DONE);
+ m_creature->ApplySpellImmune(0, IMMUNITY_STATE, SPELL_AURA_MOD_TAUNT, true);
+ m_creature->ApplySpellImmune(0, IMMUNITY_EFFECT,SPELL_EFFECT_ATTACK_ME, true);
}
void Aggro(Unit *who)
{
DoScriptText(SAY_AGGRO, m_creature);
- DoZoneInCombat();
- if(pInstance)
+ if (pInstance)
pInstance->SetData(DATA_GRUULEVENT, IN_PROGRESS);
}
@@ -101,9 +97,23 @@ struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
{
switch(rand()%3)
{
- case 0: DoScriptText(SAY_SLAY1, m_creature); break;
- case 1: DoScriptText(SAY_SLAY2, m_creature); break;
- case 2: DoScriptText(SAY_SLAY3, m_creature); break;
+ case 0: DoScriptText(SAY_SLAY1, m_creature); break;
+ case 1: DoScriptText(SAY_SLAY2, m_creature); break;
+ case 2: DoScriptText(SAY_SLAY3, m_creature); break;
+ }
+ }
+
+ void JustDied(Unit* Killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+
+ if(pInstance)
+ {
+ pInstance->SetData(DATA_GRUULEVENT, DONE);
+
+ GameObject* EncounterDoor = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GRUULDOOR));
+ if (EncounterDoor)
+ EncounterDoor->SetGoState(0); // Open the encounter door
}
}
@@ -117,14 +127,14 @@ struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
// Gruul can cast this spell up to 30 times
if (Growth_Timer < diff)
{
- DoCast(m_creature,SPELL_GROWTH);
DoScriptText(EMOTE_GROW, m_creature);
+ DoCast(m_creature,SPELL_GROWTH);
Growth_Timer = 30000;
}else Growth_Timer -= diff;
- if(PerformingGroundSlam)
+ if (PerformingGroundSlam)
{
- if(GroundSlamTimer < diff)
+ if (GroundSlamTimer < diff)
{
switch(GroundSlamStage)
{
@@ -140,7 +150,7 @@ struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
{
Unit *target = Unit::GetUnit(*m_creature, (*itr)->getUnitGuid());
- if(target && target->GetTypeId() == TYPEID_PLAYER)
+ if (target && target->GetTypeId() == TYPEID_PLAYER)
knockback_targets.push_back(target);
}
@@ -150,7 +160,7 @@ struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
Unit *target = *itr;
Unit *target2 = *(knockback_targets.begin() + rand()%knockback_targets.size());
- if(target && target2)
+ if (target && target2)
{
switch(rand()%2)
{
@@ -161,7 +171,7 @@ struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
}
GroundSlamTimer = 7000;
- break;
+ break;
}
case 1:
@@ -181,18 +191,15 @@ struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
}
GroundSlamTimer = 5000;
-
- break;
+ break;
}
case 2:
{
//The dummy shatter spell is cast
DoCast(m_creature, SPELL_SHATTER);
-
GroundSlamTimer = 1000;
-
- break;
+ break;
}
case 3:
@@ -217,20 +224,20 @@ struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
m_creature->GetMotionMaster()->Clear();
Unit *victim = m_creature->getVictim();
- if(victim)
+ if (victim)
{
m_creature->GetMotionMaster()->MoveChase(victim);
m_creature->SetUInt64Value(UNIT_FIELD_TARGET, victim->GetGUID());
}
PerformingGroundSlam = false;
-
GroundSlamTimer =120000;
HurtfulStrike_Timer= 8000;
- if(Reverberation_Timer < 10000) //Give a little time to the players to undo the damage from shatter
+
+ if (Reverberation_Timer < 10000) //Give a little time to the players to undo the damage from shatter
Reverberation_Timer += 10000;
- break;
+ break;
}
}
@@ -259,7 +266,7 @@ struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
if (Reverberation_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_REVERBERATION, true);
- Reverberation_Timer = 30000;
+ Reverberation_Timer = 15000 + rand()%10000;
}else Reverberation_Timer -= diff;
// Cave In
@@ -268,7 +275,11 @@ struct TRINITY_DLL_DECL boss_gruulAI : public ScriptedAI
if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM,0))
DoCast(target,SPELL_CAVE_IN);
- CaveIn_Timer = 20000;
+ if(CaveIn_StaticTimer >= 4000)
+ CaveIn_StaticTimer -= 2000;
+
+ CaveIn_Timer = CaveIn_StaticTimer;
+
}else CaveIn_Timer -= diff;
// Ground Slam, Gronn Lord's Grasp, Stoned, Shatter
diff --git a/src/bindings/scripts/scripts/zone/gruuls_lair/boss_high_king_maulgar.cpp b/src/bindings/scripts/scripts/zone/gruuls_lair/boss_high_king_maulgar.cpp
index 0131d39dc48..5bf36cc1d1e 100644
--- a/src/bindings/scripts/scripts/zone/gruuls_lair/boss_high_king_maulgar.cpp
+++ b/src/bindings/scripts/scripts/zone/gruuls_lair/boss_high_king_maulgar.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -88,11 +88,11 @@ bool CheckAllBossDied(ScriptedInstance* pInstance, Creature* m_creature)
OlmGUID = pInstance->GetData64(DATA_OLMTHESUMMONER);
KroshGUID = pInstance->GetData64(DATA_KROSHFIREHAND);
- Maulgar = ((Creature*)Unit::GetUnit((*m_creature), MaulgarGUID));
- Kiggler = ((Creature*)Unit::GetUnit((*m_creature), KigglerGUID));
- Blindeye = ((Creature*)Unit::GetUnit((*m_creature), BlindeyeGUID));
- Olm = ((Creature*)Unit::GetUnit((*m_creature), OlmGUID));
- Krosh = ((Creature*)Unit::GetUnit((*m_creature), KroshGUID));
+ Maulgar = (Unit::GetCreature((*m_creature), MaulgarGUID));
+ Kiggler = (Unit::GetCreature((*m_creature), KigglerGUID));
+ Blindeye = (Unit::GetCreature((*m_creature), BlindeyeGUID));
+ Olm = (Unit::GetCreature((*m_creature), OlmGUID));
+ Krosh = (Unit::GetCreature((*m_creature), KroshGUID));
if(!Maulgar || !Kiggler || !Blindeye || !Olm || !Krosh)
return false;
@@ -142,7 +142,7 @@ struct TRINITY_DLL_DECL boss_high_king_maulgarAI : public ScriptedAI
{
if(Council[i])
{
- pCreature = (Creature*)(Unit::GetUnit((*m_creature), Council[i]));
+ pCreature = (Unit::GetCreature((*m_creature), Council[i]));
if(pCreature && !pCreature->isAlive())
{
pCreature->Respawn();
@@ -268,8 +268,8 @@ struct TRINITY_DLL_DECL boss_high_king_maulgarAI : public ScriptedAI
DoScriptText(SAY_ENRAGE, m_creature);
m_creature->CastSpell(m_creature, SPELL_DUAL_WIELD, true);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 0);
}
if(Phase2)
@@ -337,7 +337,7 @@ struct TRINITY_DLL_DECL boss_olm_the_summonerAI : public ScriptedAI
if(pInstance)
{
Creature *Maulgar = NULL;
- Maulgar = (Creature*)(Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_MAULGAR)));
+ Maulgar = (Unit::GetCreature((*m_creature), pInstance->GetData64(DATA_MAULGAR)));
if(Maulgar)
((boss_high_king_maulgarAI*)Maulgar->AI())->AddDeath();
@@ -441,7 +441,7 @@ struct TRINITY_DLL_DECL boss_kiggler_the_crazedAI : public ScriptedAI
if(pInstance)
{
Creature *Maulgar = NULL;
- Maulgar = (Creature*)(Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_MAULGAR)));
+ Maulgar = (Unit::GetCreature((*m_creature), pInstance->GetData64(DATA_MAULGAR)));
if(Maulgar)
((boss_high_king_maulgarAI*)Maulgar->AI())->AddDeath();
@@ -482,7 +482,7 @@ struct TRINITY_DLL_DECL boss_kiggler_the_crazedAI : public ScriptedAI
if(target)
DoCast(target, SPELL_GREATER_POLYMORPH);
- GreaterPolymorph_Timer = 20000;
+ GreaterPolymorph_Timer = 15000 + rand()%5000;
}else GreaterPolymorph_Timer -= diff;
//LightningBolt_Timer
@@ -520,13 +520,15 @@ struct TRINITY_DLL_DECL boss_blindeye_the_seerAI : public ScriptedAI
uint32 GreaterPowerWordShield_Timer;
uint32 Heal_Timer;
+ uint32 PrayerofHealing_Timer;
ScriptedInstance* pInstance;
void Reset()
{
GreaterPowerWordShield_Timer = 5000;
- Heal_Timer = 30000;
+ Heal_Timer = 25000 + rand()%15000;
+ PrayerofHealing_Timer = 45000 + rand()%10000;
//reset encounter
if (pInstance)
@@ -547,7 +549,7 @@ struct TRINITY_DLL_DECL boss_blindeye_the_seerAI : public ScriptedAI
if(pInstance)
{
Creature *Maulgar = NULL;
- Maulgar = (Creature*)(Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_MAULGAR)));
+ Maulgar = (Unit::GetCreature((*m_creature), pInstance->GetData64(DATA_MAULGAR)));
if(Maulgar)
((boss_high_king_maulgarAI*)Maulgar->AI())->AddDeath();
@@ -592,9 +594,16 @@ struct TRINITY_DLL_DECL boss_blindeye_the_seerAI : public ScriptedAI
if(Heal_Timer < diff)
{
DoCast(m_creature, SPELL_HEAL);
- Heal_Timer = 60000;
+ Heal_Timer = 15000 + rand()%25000;
}else Heal_Timer -= diff;
+ //PrayerofHealing_Timer
+ if (PrayerofHealing_Timer < diff)
+ {
+ DoCast(m_creature, SPELL_PRAYER_OH);
+ PrayerofHealing_Timer = 35000 + rand()%15000;
+ }else PrayerofHealing_Timer -= diff;
+
DoMeleeAttackIfReady();
}
};
@@ -638,7 +647,7 @@ struct TRINITY_DLL_DECL boss_krosh_firehandAI : public ScriptedAI
if(pInstance)
{
Creature *Maulgar = NULL;
- Maulgar = (Creature*)(Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_MAULGAR)));
+ Maulgar = (Unit::GetCreature((*m_creature), pInstance->GetData64(DATA_MAULGAR)));
if(Maulgar)
((boss_high_king_maulgarAI*)Maulgar->AI())->AddDeath();
diff --git a/src/bindings/scripts/scripts/zone/gruuls_lair/def_gruuls_lair.h b/src/bindings/scripts/scripts/zone/gruuls_lair/def_gruuls_lair.h
index 145e573f02a..7003dcb1e26 100644
--- a/src/bindings/scripts/scripts/zone/gruuls_lair/def_gruuls_lair.h
+++ b/src/bindings/scripts/scripts/zone/gruuls_lair/def_gruuls_lair.h
@@ -1,19 +1,21 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
#ifndef DEF_GRUULS_LAIR_H
#define DEF_GRUULS_LAIR_H
-#define DATA_BLINDEYETHESEER 1
-#define DATA_GRUULEVENT 2
-#define DATA_KIGGLERTHECRAZED 3
-#define DATA_KROSHFIREHAND 4
-#define DATA_MAULGAREVENT 5
-#define DATA_MAULGAREVENT_TANK 6
-#define DATA_OLMTHESUMMONER 7
-#define DATA_MAULGARDOOR 8
-#define DATA_GRUULDOOR 9
-#define DATA_MAULGAR 10
+#define DATA_BLINDEYETHESEER 1
+#define DATA_GRUULEVENT 2
+#define DATA_KIGGLERTHECRAZED 3
+#define DATA_KROSHFIREHAND 4
+#define DATA_MAULGAREVENT 5
+#define DATA_MAULGAREVENT_TANK 6
+#define DATA_OLMTHESUMMONER 7
+#define DATA_MAULGARDOOR 8
+#define DATA_GRUULDOOR 9
+#define DATA_MAULGAR 10
+
+#define ERROR_INST_DATA "TSCR Error: Instance Data not set properly for Gruul's Lair instance (map 565). Encounters will be buggy."
#endif
diff --git a/src/bindings/scripts/scripts/zone/gruuls_lair/instance_gruuls_lair.cpp b/src/bindings/scripts/scripts/zone/gruuls_lair/instance_gruuls_lair.cpp
index 5c026ab1860..34943449b1e 100644
--- a/src/bindings/scripts/scripts/zone/gruuls_lair/instance_gruuls_lair.cpp
+++ b/src/bindings/scripts/scripts/zone/gruuls_lair/instance_gruuls_lair.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -73,7 +73,7 @@ struct TRINITY_DLL_DECL instance_gruuls_lair : public ScriptedInstance
void OnCreatureCreate(Creature *creature, uint32 creature_entry)
{
- switch(creature_entry)
+ switch(creature->GetEntry())
{
case 18835: KigglerTheCrazed = creature->GetGUID(); break;
case 18836: BlindeyeTheSeer = creature->GetGUID(); break;
diff --git a/src/bindings/scripts/scripts/zone/gundrak/boss_drakkari_colossus.cpp b/src/bindings/scripts/scripts/zone/gundrak/boss_drakkari_colossus.cpp
new file mode 100644
index 00000000000..0b2fc89dd97
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/gundrak/boss_drakkari_colossus.cpp
@@ -0,0 +1,55 @@
+/* Script Data Start
+SDName: Boss Drakkari Colossus
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_EMERGE 54850 //to phase2, Colossus unatackable, Elemental emerges
+#define SPELL_EMERGE_2 54851
+#define SPELL_MIGHTY_BLOW 54719
+
+struct TRINITY_DLL_DECL boss_drakkari_colossusAI : public ScriptedAI
+{
+ boss_drakkari_colossusAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 phase;
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ phase =1;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+CreatureAI* GetAI_boss_drakkari_colossus(Creature *_Creature)
+{
+ return new boss_drakkari_colossusAI (_Creature);
+}
+
+void AddSC_boss_drakkari_colossus()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_drakkari_colossus";
+ newscript->GetAI = GetAI_boss_drakkari_colossus;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/gundrak/boss_eck.cpp b/src/bindings/scripts/scripts/zone/gundrak/boss_eck.cpp
new file mode 100644
index 00000000000..9c518bee397
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/gundrak/boss_eck.cpp
@@ -0,0 +1,65 @@
+/* Script Data Start
+SDName: Boss Eck the Ferocious
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment: Only appears in Heroic mode
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+#define SPELL_ECK_BERSERK 55816 //Eck goes berserk, increasing his attack speed by 150% and all damage he deals by 500%.
+#define SPELL_ECK_BITE 55813 //Eck bites down hard, inflicting 150% of his normal damage to an enemy.
+#define SPELL_ECK_SPIT 55814 //Eck spits toxic bile at enemies in a cone in front of him, inflicting 2970 Nature damage and draining 220 mana every 1 sec for 3 sec.
+#define SPELL_ECK_SPRING_1 55815 //Eck leaps at a distant target. --> Drops aggro and charges a random player. Tank can simply taunt him back.
+#define SPELL_ECK_SPRING_2 55837 //Eck leaps at a distant target.
+
+struct TRINITY_DLL_DECL boss_eckAI : public ScriptedAI
+{
+ boss_eckAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 berserk;
+
+ void Reset()
+ {
+ //Source Deadly Boss Mod
+ berserk = 120000; //2min
+ }
+
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ if(berserk < diff)
+ {
+ DoCast(m_creature,SPELL_ECK_BERSERK);
+ berserk = 120000;
+ }else berserk -= diff;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+CreatureAI* GetAI_boss_eck(Creature *_Creature)
+{
+ return new boss_eckAI (_Creature);
+}
+
+void AddSC_boss_eck()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_eck";
+ newscript->GetAI = GetAI_boss_eck;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/gundrak/boss_gal_darah.cpp b/src/bindings/scripts/scripts/zone/gundrak/boss_gal_darah.cpp
new file mode 100644
index 00000000000..71654de9852
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/gundrak/boss_gal_darah.cpp
@@ -0,0 +1,85 @@
+/* Script Data Start
+SDName: Boss gal_darah
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_ENRAGE 55285
+#define SPELL_IMPALING_CHARGE 54956
+#define SPELL_STOMP 55292
+
+#define SPELL_PUNCTURE 55276
+#define SPELL_STAMPEDE 55218
+#define SPELL_WHIRLING_SLASH 55285
+
+//Yells
+#define SAY_AGGRO -1604000
+#define SAY_SLAY_1 -1604001
+#define SAY_SLAY_2 -1604002
+#define SAY_SLAY_3 -1604003
+#define SAY_DEATH -1604004
+#define SAY_SUMMON_RHINO_1 -1604005
+#define SAY_SUMMON_RHINO_2 -1604006
+#define SAY_SUMMON_RHINO_3 -1604007
+#define SAY_TRANSFORM_1 -1604008 //Phase change
+#define SAY_TRANSFORM_2 -1604009
+
+struct TRINITY_DLL_DECL boss_gal_darahAI : public ScriptedAI
+{
+ boss_gal_darahAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_gal_darah(Creature *_Creature)
+{
+ return new boss_gal_darahAI (_Creature);
+}
+
+void AddSC_boss_gal_darah()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_gal_darah";
+ newscript->GetAI = GetAI_boss_gal_darah;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/gundrak/boss_moorabi.cpp b/src/bindings/scripts/scripts/zone/gundrak/boss_moorabi.cpp
new file mode 100644
index 00000000000..49afd7b8126
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/gundrak/boss_moorabi.cpp
@@ -0,0 +1,88 @@
+/* Script Data Start
+SDName: Boss moorabi
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_moorabi' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_DETERMINED_GORE 55102
+#define SPELL_DETERMINED_STAB_2 59444
+#define SPELL_DETERMINED_STAB_3 55104
+
+#define SPELL_GROUND_TREMOR 55142
+#define SPELL_MOJO_FRENZY 55163
+#define SPELL_NUMBING_ROAR_1 55100
+#define SPELL_NUMBING_ROAR_2 55106
+#define SPELL_TRANSFORMATION 55098 //Periodic, The caster transforms into a powerful mammoth, increasing Physical damage done by 25% and granting immunity to Stun effects.
+#define SPELL_QUAKE 55101
+
+//Yell
+#define SAY_AGGRO -1604010
+#define SAY_SLAY_1 -1604011
+#define SAY_SLAY_2 -1604012
+#define SAY_SLAY_3 -1604013
+#define SAY_DEATH -1604014
+#define SAY_TRANSFORM -1604015
+#define SAY_QUAKE -1604016
+
+struct TRINITY_DLL_DECL boss_moorabiAI : public ScriptedAI
+{
+ boss_moorabiAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 phase;
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ phase =1;
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_moorabi(Creature *_Creature)
+{
+ return new boss_moorabiAI (_Creature);
+}
+
+void AddSC_boss_moorabi()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_moorabi";
+ newscript->GetAI = GetAI_boss_moorabi;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/gundrak/boss_slad_ran.cpp b/src/bindings/scripts/scripts/zone/gundrak/boss_slad_ran.cpp
new file mode 100644
index 00000000000..7efd16fc375
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/gundrak/boss_slad_ran.cpp
@@ -0,0 +1,95 @@
+/* Script Data Start
+SDName: Boss slad_ran
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_slad_ran' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_POISON_NOVA 55081
+#define SPELL_POISON_NOVA_2 59842
+//--
+#define SPELL_POWERFUL_BITE 48287
+#define SPELL_POWERFUL_BITE_2 59840
+//--
+#define SPELL_VENOM_BOLT 54970
+#define SPELL_VENOM_BOLT_2 59839
+//At 30% HPStart summoning small serpents
+
+//Yell
+#define SAY_AGGRO -1604017
+#define SAY_SLAY_1 -1604018
+#define SAY_SLAY_2 -1604019
+#define SAY_SLAY_3 -1604020
+#define SAY_DEATH -1604021
+#define SAY_SUMMON_SNAKES -1604022 //npc 29680
+#define SAY_SUMMON_CONSTRICTORS -1604023 //npc 29713, can cast Grip of Slad'ran (spell 55093)
+
+struct TRINITY_DLL_DECL boss_slad_ranAI : public ScriptedAI
+{
+ boss_slad_ranAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 30)
+ {
+ //Summon 3 snakes --> npc 29680
+ DoScriptText(SAY_SUMMON_SNAKES,m_creature);
+ }
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 25)
+ {
+ //Summon 3 constrictors --> npc 29713
+ DoScriptText(SAY_SUMMON_CONSTRICTORS,m_creature);
+ }
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%3)
+ {
+ case 0:DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1:DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2:DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_slad_ran(Creature *_Creature)
+{
+ return new boss_slad_ranAI (_Creature);
+}
+
+void AddSC_boss_slad_ran()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_slad_ran";
+ newscript->GetAI = GetAI_boss_slad_ran;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/gundrak/def_gundrak.h b/src/bindings/scripts/scripts/zone/gundrak/def_gundrak.h
new file mode 100644
index 00000000000..5f015610312
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/gundrak/def_gundrak.h
@@ -0,0 +1,4 @@
+#ifndef DEF_GUNDRAK_H
+#define DEF_GUNDRAK_H
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/gundrak/instance_gundrak.cpp b/src/bindings/scripts/scripts/zone/gundrak/instance_gundrak.cpp
new file mode 100644
index 00000000000..88df9e1b73c
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/gundrak/instance_gundrak.cpp
@@ -0,0 +1,21 @@
+#include "precompiled.h"
+#include "def_gundrak.h"
+
+struct TRINITY_DLL_DECL instance_gundrak : public ScriptedInstance
+{
+ instance_gundrak(Map *Map) : ScriptedInstance(Map) {Initialize();};
+};
+
+InstanceData* GetInstanceData_instance_gundrak(Map* map)
+{
+ return new instance_gundrak(map);
+}
+
+void AddSC_instance_gundrak()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_gundrak";
+ newscript->GetInstanceData = GetInstanceData_instance_gundrak;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_broggok.cpp b/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_broggok.cpp
index 92971bf16cf..1afe49ce30e 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_broggok.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_broggok.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -6,18 +6,18 @@
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/* ScriptData
SDName: Boss_Broggok
-SD%Complete: 100
-SDComment:
+SD%Complete: 70
+SDComment: pre-event not made
SDCategory: Hellfire Citadel, Blood Furnace
EndScriptData */
@@ -51,25 +51,32 @@ struct TRINITY_DLL_DECL boss_broggokAI : public ScriptedAI
DoScriptText(SAY_AGGRO, m_creature);
}
- void UpdateAI(const uint32 diff)
+ void JustSummoned(Creature *summoned)
{
+ summoned->setFaction(16);
+ summoned->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
+ summoned->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ summoned->CastSpell(summoned,SPELL_POISON,false,0,0,m_creature->GetGUID());
+ }
- if (!UpdateVictim())
+ void UpdateAI(const uint32 diff)
+ {
+ if (!UpdateVictim() )
return;
- if(AcidSpray_Timer < diff)
+ if (AcidSpray_Timer < diff)
{
DoCast(m_creature->getVictim(),SPELL_SLIME_SPRAY);
AcidSpray_Timer = 4000+rand()%8000;
}else AcidSpray_Timer -=diff;
- if(PoisonBolt_Timer < diff)
+ if (PoisonBolt_Timer < diff)
{
DoCast(m_creature->getVictim(),SPELL_POISON_BOLT);
PoisonBolt_Timer = 4000+rand()%8000;
}else PoisonBolt_Timer -=diff;
- if(PoisonSpawn_Timer < diff)
+ if (PoisonSpawn_Timer < diff)
{
DoCast(m_creature,SPELL_POISON_CLOUD);
PoisonSpawn_Timer = 20000;
@@ -79,17 +86,36 @@ struct TRINITY_DLL_DECL boss_broggokAI : public ScriptedAI
}
};
-CreatureAI* GetAI_boss_broggokAI(Creature *_Creature)
+struct TRINITY_DLL_DECL mob_broggok_poisoncloudAI : public ScriptedAI
+{
+ mob_broggok_poisoncloudAI(Creature *c) : ScriptedAI(c) {Reset();}
+
+ void Reset() { }
+ void MoveInLineOfSight(Unit *who) { }
+ void AttackStart(Unit *who) { }
+ void Aggro(Unit* who) { }
+};
+
+CreatureAI* GetAI_boss_broggok(Creature *_Creature)
{
return new boss_broggokAI (_Creature);
}
+CreatureAI* GetAI_mob_broggok_poisoncloud(Creature *_Creature)
+{
+ return new mob_broggok_poisoncloudAI (_Creature);
+}
+
void AddSC_boss_broggok()
{
Script *newscript;
newscript = new Script;
- newscript->Name="boss_broggok";
- newscript->GetAI = &GetAI_boss_broggokAI;
+ newscript->Name = "boss_broggok";
+ newscript->GetAI = &GetAI_boss_broggok;
newscript->RegisterSelf();
-}
+ newscript = new Script;
+ newscript->Name = "mob_broggok_poisoncloud";
+ newscript->GetAI = &GetAI_mob_broggok_poisoncloud;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_kelidan_the_breaker.cpp b/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_kelidan_the_breaker.cpp
index 64bd8e04de1..8c118a022ea 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_kelidan_the_breaker.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_kelidan_the_breaker.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -62,12 +62,6 @@ const float ShadowmoonChannelers[5][4]=
{316,-109,-24.6,1.257}
};
-class TRINITY_DLL_DECL BurningNovaAura : public Aura
-{
- public:
- BurningNovaAura(SpellEntry *spell, uint32 eff, Unit *target, Unit *caster) : Aura(spell, eff, NULL, target, caster, NULL){}
-};
-
struct TRINITY_DLL_DECL boss_kelidan_the_breakerAI : public ScriptedAI
{
boss_kelidan_the_breakerAI(Creature *c) : ScriptedAI(c)
@@ -234,12 +228,14 @@ struct TRINITY_DLL_DECL boss_kelidan_the_breakerAI : public ScriptedAI
if(SpellEntry *nova = (SpellEntry*)GetSpellStore()->LookupEntry(SPELL_BURNING_NOVA))
{
- for(uint32 i = 0; i < 3; ++i)
- if(nova->Effect[i] == SPELL_EFFECT_APPLY_AURA)
- {
- Aura *Aur = new BurningNovaAura(nova, i, m_creature, m_creature);
- m_creature->AddAura(Aur);
- }
+ uint8 eff_mask=0;
+ for (int i=0; i<3; i++)
+ {
+ if (!nova->Effect[i])
+ continue;
+ eff_mask|=1<<i;
+ }
+ m_creature->AddAura(new Aura(nova, eff_mask, NULL, m_creature, m_creature));
}
if (HeroicMode)
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_the_maker.cpp b/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_the_maker.cpp
index 65c98d5ef8d..e1ea1e03b2f 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_the_maker.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/blood_furnace/boss_the_maker.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/hellfire_ramparts/boss_omor_the_unscarred.cpp b/src/bindings/scripts/scripts/zone/hellfire_citadel/hellfire_ramparts/boss_omor_the_unscarred.cpp
index 0dce1fe51d9..e6b8593d0c0 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/hellfire_ramparts/boss_omor_the_unscarred.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/hellfire_ramparts/boss_omor_the_unscarred.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/hellfire_ramparts/boss_watchkeeper_gargolmar.cpp b/src/bindings/scripts/scripts/zone/hellfire_citadel/hellfire_ramparts/boss_watchkeeper_gargolmar.cpp
index 042291b330a..e955c537bf6 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/hellfire_ramparts/boss_watchkeeper_gargolmar.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/hellfire_ramparts/boss_watchkeeper_gargolmar.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/boss_magtheridon.cpp b/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/boss_magtheridon.cpp
index 3e001888752..50db6680e94 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/boss_magtheridon.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/boss_magtheridon.cpp
@@ -257,7 +257,7 @@ struct TRINITY_DLL_DECL boss_magtheridonAI : public ScriptedAI
for(CubeMap::iterator i = Cube.begin(); i != Cube.end(); ++i)
{
Unit *clicker = Unit::GetUnit(*m_creature, (*i).second);
- if(!clicker || !clicker->HasAura(SPELL_SHADOW_GRASP, 1))
+ if(!clicker || !clicker->HasAura(SPELL_SHADOW_GRASP))
{
DebuffClicker(clicker);
(*i).second = 0;
@@ -265,12 +265,12 @@ struct TRINITY_DLL_DECL boss_magtheridonAI : public ScriptedAI
}
// if 5 clickers from other cubes apply shadow cage
- if(ClickerNum >= CLICKERS_COUNT && !m_creature->HasAura(SPELL_SHADOW_CAGE, 0))
+ if(ClickerNum >= CLICKERS_COUNT && !m_creature->HasAura(SPELL_SHADOW_CAGE))
{
DoScriptText(SAY_BANISH, m_creature);
m_creature->CastSpell(m_creature, SPELL_SHADOW_CAGE, true);
}
- else if(ClickerNum < CLICKERS_COUNT && m_creature->HasAura(SPELL_SHADOW_CAGE, 0))
+ else if(ClickerNum < CLICKERS_COUNT && m_creature->HasAura(SPELL_SHADOW_CAGE))
m_creature->RemoveAurasDueToSpell(SPELL_SHADOW_CAGE);
if(!ClickerNum) NeedCheckCube = false;
@@ -510,7 +510,7 @@ bool GOHello_go_Manticron_Cube(Player *player, GameObject* _GO)
if(!Magtheridon || !Magtheridon->isAlive()) return true;
// if exhausted or already channeling return
- if(player->HasAura(SPELL_MIND_EXHAUSTION, 0) || player->HasAura(SPELL_SHADOW_GRASP, 1))
+ if(player->HasAura(SPELL_MIND_EXHAUSTION) || player->HasAura(SPELL_SHADOW_GRASP))
return true;
player->InterruptNonMeleeSpells(false);
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/def_magtheridons_lair.h b/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/def_magtheridons_lair.h
index 3c0012ce447..c5469acaea0 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/def_magtheridons_lair.h
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/def_magtheridons_lair.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/instance_magtheridons_lair.cpp b/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/instance_magtheridons_lair.cpp
index ea51e575824..1bdce52aea9 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/instance_magtheridons_lair.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/magtheridons_lair/instance_magtheridons_lair.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -166,7 +166,7 @@ struct TRINITY_DLL_DECL instance_magtheridons_lair : public ScriptedInstance
Creature *Magtheridon = instance->GetCreatureInMap(MagtheridonGUID);
if(Magtheridon && Magtheridon->isAlive())
{
- Magtheridon->TextEmote("'s bonds begin to weaken!", 0);
+ Magtheridon->MonsterTextEmote("'s bonds begin to weaken!", 0);
CageTimer = 120000;
}
if(GameObject *Door = instance->GetGameObjectInMap(DoorGUID))
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_nethekurse.cpp b/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_nethekurse.cpp
index 320c6a0b0a4..a18579ccfa9 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_nethekurse.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_nethekurse.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -183,10 +183,11 @@ struct TRINITY_DLL_DECL boss_grand_warlock_nethekurseAI : public ScriptedAI
void MoveInLineOfSight(Unit *who)
{
- if (!m_creature->getVictim() && who->isTargetableForAttack() && ( m_creature->IsHostileTo( who )) && who->isInAccessiblePlaceFor(m_creature) )
- {
- if (!IntroOnce && m_creature->IsWithinDistInMap(who, 75))
+ if (!IntroOnce && m_creature->IsWithinDistInMap(who, 50.0f))
{
+ if (who->GetTypeId() != TYPEID_PLAYER)
+ return;
+
DoScriptText(SAY_INTRO, m_creature);
IntroOnce = true;
IsIntroEvent = true;
@@ -195,19 +196,10 @@ struct TRINITY_DLL_DECL boss_grand_warlock_nethekurseAI : public ScriptedAI
pInstance->SetData(TYPE_NETHEKURSE,IN_PROGRESS);
}
- if (!m_creature->canFly() && m_creature->GetDistanceZ(who) > CREATURE_Z_ATTACK_RANGE )
- return;
-
if (IsIntroEvent || !IsMainEvent)
return;
- float attackRadius = m_creature->GetAttackDistance(who);
- if (m_creature->IsWithinDistInMap(who, attackRadius) && m_creature->IsWithinLOSInMap(who) )
- {
- //who->RemoveSpellsCausingAura(SPELL_AURA_MOD_STEALTH);
- AttackStart(who);
- }
- }
+ ScriptedAI::MoveInLineOfSight(who);
}
void Aggro(Unit *who)
@@ -222,9 +214,13 @@ struct TRINITY_DLL_DECL boss_grand_warlock_nethekurseAI : public ScriptedAI
void JustSummoned(Creature *summoned)
{
- summoned->setFaction(14);
+ summoned->setFaction(16);
summoned->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
summoned->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+
+ //triggered spell of consumption does not properly show it's SpellVisual, wrong spellid?
+ summoned->CastSpell(summoned,SPELL_TEMPORARY_VISUAL,true);
+ summoned->CastSpell(summoned,SPELL_CONSUMPTION,false,0,0,m_creature->GetGUID());
}
void KilledUnit(Unit* victim)
@@ -340,20 +336,24 @@ struct TRINITY_DLL_DECL mob_fel_orc_convertAI : public ScriptedAI
if (pInstance->GetData64(DATA_NETHEKURSE))
{
Creature *pKurse = Unit::GetCreature(*m_creature,pInstance->GetData64(DATA_NETHEKURSE));
- if (pKurse)
+ if (pKurse && m_creature->GetDistance(pKurse) < 45.0f)
+ {
((boss_grand_warlock_nethekurseAI*)pKurse->AI())->DoYellForPeonAggro();
- }
- if (pInstance->GetData(TYPE_NETHEKURSE) == IN_PROGRESS )
- return;
- else pInstance->SetData(TYPE_NETHEKURSE,IN_PROGRESS);
- }
+ if (pInstance->GetData(TYPE_NETHEKURSE) == IN_PROGRESS )
+ return;
+ else pInstance->SetData(TYPE_NETHEKURSE,IN_PROGRESS);
+ }
+ }
+ }
}
void JustDied(Unit* Killer)
{
if (pInstance)
{
+ if (pInstance->GetData(TYPE_NETHEKURSE) != IN_PROGRESS)
+ return;
if (pInstance->GetData64(DATA_NETHEKURSE))
{
Creature *pKurse = Unit::GetCreature(*m_creature,pInstance->GetData64(DATA_NETHEKURSE));
@@ -383,39 +383,10 @@ struct TRINITY_DLL_DECL mob_lesser_shadow_fissureAI : public ScriptedAI
{
mob_lesser_shadow_fissureAI(Creature *c) : ScriptedAI(c) {}
- bool Start;
- uint32 Stop_Timer;
-
- void Reset()
- {
- Start = false;
- Stop_Timer = 30000;
- }
-
+ void Reset() { }
+ void MoveInLineOfSight(Unit *who) { }
+ void AttackStart(Unit* who) { }
void Aggro(Unit* who) { }
-
- void MoveInLineOfSight(Unit *who) { return; }
-
- void AttackStart(Unit* who) { return; }
-
- void UpdateAI(const uint32 diff)
- {
- if (!Start)
- {
- //triggered spell of consumption does not properly show it's SpellVisual, hack it a bit
- m_creature->CastSpell(m_creature,SPELL_TEMPORARY_VISUAL,true);
- m_creature->CastSpell(m_creature,SPELL_CONSUMPTION,false);
- Start = true;
- }
-
- if (Stop_Timer < diff)
- {
- m_creature->setDeathState(JUST_DIED);
- m_creature->SetHealth(0);
- m_creature->CombatStop();
- m_creature->DeleteThreatList();
- }else Stop_Timer -= diff;
- }
};
CreatureAI* GetAI_boss_grand_warlock_nethekurse(Creature *_Creature)
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_warbringer_omrogg.cpp b/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_warbringer_omrogg.cpp
index c565d6ab08e..b8c6162a809 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_warbringer_omrogg.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_warbringer_omrogg.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -156,8 +156,6 @@ struct TRINITY_DLL_DECL boss_warbringer_omroggAI : public ScriptedAI
void Reset()
{
- m_creature->ApplySpellImmune(0, IMMUNITY_STATE, SPELL_AURA_MOD_TAUNT, true);
- m_creature->ApplySpellImmune(0, IMMUNITY_EFFECT,SPELL_EFFECT_ATTACK_ME, true);
LeftHead = 0;
RightHead = 0;
@@ -175,6 +173,9 @@ struct TRINITY_DLL_DECL boss_warbringer_omroggAI : public ScriptedAI
ThunderClap_Timer = 15000;
ResetThreat_Timer = 30000;
+ m_creature->ApplySpellImmune(0, IMMUNITY_STATE, SPELL_AURA_MOD_TAUNT, true);
+ m_creature->ApplySpellImmune(1, IMMUNITY_EFFECT,SPELL_EFFECT_ATTACK_ME, true);
+
if (pInstance)
pInstance->SetData(TYPE_OMROGG, NOT_STARTED); //End boss can use this later. O'mrogg must be defeated(DONE) or he will come to aid.
}
@@ -202,8 +203,8 @@ struct TRINITY_DLL_DECL boss_warbringer_omroggAI : public ScriptedAI
void Aggro(Unit *who)
{
- DoSpawnCreature(ENTRY_LEFT_HEAD,0,0,0,0,TEMPSUMMON_TIMED_DESPAWN,1800000);
- DoSpawnCreature(ENTRY_RIGHT_HEAD,0,0,0,0,TEMPSUMMON_TIMED_DESPAWN,1800000);
+ DoSpawnCreature(ENTRY_LEFT_HEAD,0,0,0,0,TEMPSUMMON_TIMED_DESPAWN,90000);
+ DoSpawnCreature(ENTRY_RIGHT_HEAD,0,0,0,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,90000);
if (Unit *Left = Unit::GetUnit(*m_creature,LeftHead))
{
@@ -357,19 +358,19 @@ struct TRINITY_DLL_DECL boss_warbringer_omroggAI : public ScriptedAI
DoResetThreat();
m_creature->AddThreat(target, 0.0f);
}
- ResetThreat_Timer = 35000+rand()%10000;
+ ResetThreat_Timer = 25000+rand()%15000;
}else ResetThreat_Timer -= diff;
if (Fear_Timer < diff)
{
DoCast(m_creature,SPELL_FEAR);
- Fear_Timer = 15000+rand()%25000;
+ Fear_Timer = 15000+rand()%20000;
}else Fear_Timer -= diff;
if (ThunderClap_Timer < diff)
{
DoCast(m_creature,SPELL_THUNDERCLAP);
- ThunderClap_Timer = 25000+rand()%15000;
+ ThunderClap_Timer = 15000+rand()%15000;
}else ThunderClap_Timer -= diff;
DoMeleeAttackIfReady();
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_warchief_kargath_bladefist.cpp b/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_warchief_kargath_bladefist.cpp
index 8c4b24421c6..e72c0adc8e9 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_warchief_kargath_bladefist.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/boss_warchief_kargath_bladefist.cpp
@@ -1,6 +1,39 @@
-/* Copyright (C) 2008 - 2009 BroodWyrm */
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Boss_Warchief_Kargath_Bladefist
+SD%Complete: 90
+SDComment:
+SDCategory: Hellfire Citadel, Shattered Halls
+EndScriptData */
+
+/* ContentData
+boss_warchief_kargath_bladefist
+EndContentData */
+
#include "precompiled.h"
+#define SAY_AGGRO1 -1540042
+#define SAY_AGGRO2 -1540043
+#define SAY_AGGRO3 -1540044
+#define SAY_SLAY1 -1540045
+#define SAY_SLAY2 -1540046
+#define SAY_DEATH -1540047
+
#define SPELL_BLADE_DANCE 30739
#define H_SPELL_CHARGE 25821
@@ -11,23 +44,10 @@
#define MOB_SHARPSHOOTER_GUARD 17622
#define MOB_REAVER_GUARD 17623
-float AssassEntrance[3] = {275.136,-84.29,2.3}; // y +-8
-float AssassExit[3] = {184.233,-84.29,2.3}; // y +-8
+float AssassEntrance[3] = {275.136,-84.29,2.3}; // y -8
+float AssassExit[3] = {184.233,-84.29,2.3}; // y -8
float AddsEntrance[3] = {306.036,-84.29,1.93};
-#define SOUND_AGGRO1 10323
-#define SAY_AGGRO1 "Ours is the true Horde! The only Horde!"
-#define SOUND_AGGRO2 10324
-#define SAY_AGGRO2 "I'll carve the meat from your bones!"
-#define SOUND_AGGRO3 10325
-#define SAY_AGGRO3 "I am called Bladefist for a reason, as you will see!"
-#define SOUND_SLAY1 10326
-#define SAY_SLAY1 "For the real Horde!"
-#define SOUND_SLAY2 10327
-#define SAY_SLAY2 "I am the only Warchief!"
-#define SOUND_DEATH 10328
-#define SAY_DEATH "The true Horde... will.. prevail.."
-
struct TRINITY_DLL_DECL boss_warchief_kargath_bladefistAI : public ScriptedAI
{
boss_warchief_kargath_bladefistAI(Creature *c) : ScriptedAI(c)
@@ -67,8 +87,8 @@ struct TRINITY_DLL_DECL boss_warchief_kargath_bladefistAI : public ScriptedAI
Wait_Timer = 0;
Charge_timer = 0;
- Blade_Dance_Timer = 30000;
- Summon_Assistant_Timer = 15000;
+ Blade_Dance_Timer = 45000;
+ Summon_Assistant_Timer = 30000;
Assassins_Timer = 5000;
resetcheck_timer = 5000;
}
@@ -77,18 +97,9 @@ struct TRINITY_DLL_DECL boss_warchief_kargath_bladefistAI : public ScriptedAI
{
switch (rand()%3)
{
- case 0:
- DoPlaySoundToSet(m_creature,SOUND_AGGRO1);
- DoYell(SAY_AGGRO1,LANG_UNIVERSAL,NULL);
- break;
- case 1:
- DoPlaySoundToSet(m_creature,SOUND_AGGRO2);
- DoYell(SAY_AGGRO2,LANG_UNIVERSAL,NULL);
- break;
- case 2:
- DoPlaySoundToSet(m_creature,SOUND_AGGRO3);
- DoYell(SAY_AGGRO3,LANG_UNIVERSAL,NULL);
- break;
+ case 0:DoScriptText(SAY_AGGRO1, m_creature);break;
+ case 1:DoScriptText(SAY_AGGRO2, m_creature);break;
+ case 2:DoScriptText(SAY_AGGRO3, m_creature);break;
}
}
@@ -114,22 +125,15 @@ struct TRINITY_DLL_DECL boss_warchief_kargath_bladefistAI : public ScriptedAI
{
switch(rand()%2)
{
- case 0:
- DoPlaySoundToSet(m_creature, SOUND_SLAY1);
- DoYell(SAY_SLAY1,LANG_UNIVERSAL,NULL);
- break;
- case 1:
- DoPlaySoundToSet(m_creature, SOUND_SLAY2);
- DoYell(SAY_SLAY2,LANG_UNIVERSAL,NULL);
- break;
+ case 0: DoScriptText(SAY_SLAY1, m_creature); break;
+ case 1: DoScriptText(SAY_SLAY2, m_creature); break;
}
}
}
void JustDied(Unit* Killer)
{
- DoPlaySoundToSet(m_creature, SOUND_DEATH);
- DoYell(SAY_DEATH,LANG_UNIVERSAL,NULL);
+ DoScriptText(SAY_DEATH, m_creature);
removeAdds();
}
@@ -180,15 +184,16 @@ struct TRINITY_DLL_DECL boss_warchief_kargath_bladefistAI : public ScriptedAI
}
void SpawnAssassin()
{
- m_creature->SummonCreature(MOB_SHATTERED_ASSASSIN,AssassEntrance[0],AssassEntrance[1]+8, AssassEntrance[2], 0,TEMPSUMMON_CORPSE_TIMED_DESPAWN,10000);
- m_creature->SummonCreature(MOB_SHATTERED_ASSASSIN,AssassEntrance[0],AssassEntrance[1]-8, AssassEntrance[2], 0,TEMPSUMMON_CORPSE_TIMED_DESPAWN,10000);
- m_creature->SummonCreature(MOB_SHATTERED_ASSASSIN,AssassExit[0],AssassExit[1]+8, AssassExit[2], 0,TEMPSUMMON_CORPSE_TIMED_DESPAWN,10000);
- m_creature->SummonCreature(MOB_SHATTERED_ASSASSIN,AssassExit[0],AssassExit[1]-8, AssassExit[2], 0,TEMPSUMMON_CORPSE_TIMED_DESPAWN,10000);
+ m_creature->SummonCreature(MOB_SHATTERED_ASSASSIN,AssassEntrance[0],AssassEntrance[1]+8, AssassEntrance[2], 0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,30000);
+ m_creature->SummonCreature(MOB_SHATTERED_ASSASSIN,AssassEntrance[0],AssassEntrance[1]-8, AssassEntrance[2], 0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,30000);
+ m_creature->SummonCreature(MOB_SHATTERED_ASSASSIN,AssassExit[0],AssassExit[1]+8, AssassExit[2], 0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,30000);
+ m_creature->SummonCreature(MOB_SHATTERED_ASSASSIN,AssassExit[0],AssassExit[1]-8, AssassExit[2], 0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,30000);
}
void UpdateAI(const uint32 diff)
{
- if (!UpdateVictim() )
+ //Return since we have no target
+ if (!UpdateVictim())
return;
if(Assassins_Timer)
@@ -250,30 +255,29 @@ struct TRINITY_DLL_DECL boss_warchief_kargath_bladefistAI : public ScriptedAI
if (Summon_Assistant_Timer < diff)
{
Unit* target = NULL;
- Creature* Summoned;
for(int i = 0; i < summoned; i++)
{
switch(rand()%3)
{
- case 0: Summoned = m_creature->SummonCreature(MOB_HEARTHEN_GUARD,AddsEntrance[0],AddsEntrance[1], AddsEntrance[2], 0,TEMPSUMMON_CORPSE_TIMED_DESPAWN,10000); break;
- case 1: Summoned = m_creature->SummonCreature(MOB_SHARPSHOOTER_GUARD,AddsEntrance[0],AddsEntrance[1], AddsEntrance[2], 0,TEMPSUMMON_CORPSE_TIMED_DESPAWN,10000); break;
- case 2: Summoned = m_creature->SummonCreature(MOB_REAVER_GUARD,AddsEntrance[0],AddsEntrance[1], AddsEntrance[2], 0,TEMPSUMMON_CORPSE_TIMED_DESPAWN,10000); break;
+ case 0: m_creature->SummonCreature(MOB_HEARTHEN_GUARD,AddsEntrance[0],AddsEntrance[1], AddsEntrance[2], 0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,30000); break;
+ case 1: m_creature->SummonCreature(MOB_SHARPSHOOTER_GUARD,AddsEntrance[0],AddsEntrance[1], AddsEntrance[2], 0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,30000); break;
+ case 2: m_creature->SummonCreature(MOB_REAVER_GUARD,AddsEntrance[0],AddsEntrance[1], AddsEntrance[2], 0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,30000); break;
}
}
if(rand()%100 < 20) summoned++;
- Summon_Assistant_Timer = 15000 + (rand()%5000) ;
+ Summon_Assistant_Timer = 25000 + (rand()%10000) ;
}else Summon_Assistant_Timer -= diff;
DoMeleeAttackIfReady();
}
- if(resetcheck_timer < diff)
+ if (resetcheck_timer < diff)
{
uint32 tempx,tempy;
- tempx = m_creature->GetPositionX();
- tempy = m_creature->GetPositionY();
- if ( tempx > 255 || tempx < 205)
+ tempx = uint32(m_creature->GetPositionX());
+ tempy = uint32(m_creature->GetPositionY());
+ if (tempx > 255 || tempx < 205)
{
EnterEvadeMode();
}
@@ -292,7 +296,7 @@ void AddSC_boss_warchief_kargath_bladefist()
Script *newscript;
newscript = new Script;
newscript->Name="boss_warchief_kargath_bladefist";
- newscript->GetAI = &GetAI_boss_warchief_kargath_bladefist;
+ newscript->GetAI = GetAI_boss_warchief_kargath_bladefist;
newscript->RegisterSelf();
}
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/def_shattered_halls.h b/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/def_shattered_halls.h
index cb3a06055cb..cbfa23ec4e0 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/def_shattered_halls.h
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/def_shattered_halls.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/instance_shattered_halls.cpp b/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/instance_shattered_halls.cpp
index aa2817ca994..b606ff0f97e 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/instance_shattered_halls.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_citadel/shattered_halls/instance_shattered_halls.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/hellfire_peninsula/boss_doomlord_kazzak.cpp b/src/bindings/scripts/scripts/zone/hellfire_peninsula/boss_doomlord_kazzak.cpp
index b9e3b9d752f..fbb86e6cabf 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_peninsula/boss_doomlord_kazzak.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_peninsula/boss_doomlord_kazzak.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/hellfire_peninsula/hellfire_peninsula.cpp b/src/bindings/scripts/scripts/zone/hellfire_peninsula/hellfire_peninsula.cpp
index cba3a107af6..2adbc632155 100644
--- a/src/bindings/scripts/scripts/zone/hellfire_peninsula/hellfire_peninsula.cpp
+++ b/src/bindings/scripts/scripts/zone/hellfire_peninsula/hellfire_peninsula.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -293,8 +293,6 @@ struct TRINITY_DLL_DECL npc_wounded_blood_elfAI : public npc_escortAI
break;
case 13:
DoScriptText(SAY_ELF_RESTING, m_creature, player);
- // make the NPC kneel
- m_creature->HandleEmoteCommand(EMOTE_ONESHOT_KNEEL);
break;
case 14:
DoScriptText(SAY_ELF_SUMMON2, m_creature, player);
@@ -349,38 +347,11 @@ struct TRINITY_DLL_DECL npc_wounded_blood_elfAI : public npc_escortAI
}
};
-CreatureAI* GetAI_npc_wounded_blood_elf(Creature *_Creature)
+CreatureAI* GetAI_npc_wounded_blood_elf(Creature* pCreature)
{
- npc_wounded_blood_elfAI* welfAI = new npc_wounded_blood_elfAI(_Creature);
-
- welfAI->AddWaypoint(0, -1137.72, 4272.10, 14.04, 5000);
- welfAI->AddWaypoint(1, -1141.34, 4232.42, 14.63);
- welfAI->AddWaypoint(2, -1133.47, 4220.88, 11.78);
- welfAI->AddWaypoint(3, -1126.18, 4213.26, 13.51);
- welfAI->AddWaypoint(4, -1100.12, 4204.32, 16.41);
- welfAI->AddWaypoint(5, -1063.68, 4197.92, 15.51);
- welfAI->AddWaypoint(6, -1027.28, 4194.36, 15.52);
- welfAI->AddWaypoint(7, -995.68, 4189.59, 19.84);
- welfAI->AddWaypoint(8, -970.90, 4188.60, 24.61);
- welfAI->AddWaypoint(9, -961.93, 4193.34, 26.11, 15000); // Summon 1
- welfAI->AddWaypoint(10, -935.52, 4210.99, 31.98);
- welfAI->AddWaypoint(11, -913.42, 4218.27, 37.29);
- welfAI->AddWaypoint(12, -896.53, 4207.73, 43.23);
- welfAI->AddWaypoint(13, -868.49, 4194.77, 46.75, 30000);// Kneel and Rest Here
- welfAI->AddWaypoint(14, -852.83, 4198.29, 47.28, 15000);// Summon 2
- welfAI->AddWaypoint(15, -819.85, 4200.50, 46.37);
- welfAI->AddWaypoint(16, -791.92, 4201.96, 44.19);
- welfAI->AddWaypoint(17, -774.42, 4202.46, 47.41);
- welfAI->AddWaypoint(18, -762.90, 4202.17, 48.81);
- welfAI->AddWaypoint(19, -728.25, 4195.35, 50.68);
- welfAI->AddWaypoint(20, -713.58, 4192.07, 53.98);
- welfAI->AddWaypoint(21, -703.09, 4189.74, 56.96);
- welfAI->AddWaypoint(22, -693.70, 4185.43, 57.06);
- welfAI->AddWaypoint(23, -686.38, 4159.81, 60.26);
- welfAI->AddWaypoint(24, -679.88, 4147.04, 64.20);
- welfAI->AddWaypoint(25, -656.74, 4147.72, 64.11);
- welfAI->AddWaypoint(26, -652.22, 4137.50, 64.58);
- welfAI->AddWaypoint(27, -649.99, 4136.38, 64.63, 30000);// Award Quest Credit
+ npc_wounded_blood_elfAI* welfAI = new npc_wounded_blood_elfAI(pCreature);
+
+ welfAI->FillPointMovementListForCreature();
return (CreatureAI*)welfAI;
}
diff --git a/src/bindings/scripts/scripts/zone/ironforge/ironforge.cpp b/src/bindings/scripts/scripts/zone/ironforge/ironforge.cpp
index 674bf56bb26..b17a280391a 100644
--- a/src/bindings/scripts/scripts/zone/ironforge/ironforge.cpp
+++ b/src/bindings/scripts/scripts/zone/ironforge/ironforge.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/isle_of_queldanas/isle_of_queldanas.cpp b/src/bindings/scripts/scripts/zone/isle_of_queldanas/isle_of_queldanas.cpp
index 900a5ae3d5b..70a77302823 100644
--- a/src/bindings/scripts/scripts/zone/isle_of_queldanas/isle_of_queldanas.cpp
+++ b/src/bindings/scripts/scripts/zone/isle_of_queldanas/isle_of_queldanas.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -165,7 +165,7 @@ struct TRINITY_DLL_DECL npc_greengill_slaveAI : public ScriptedAI
if(!caster)
return;
- if(caster->GetTypeId() == TYPEID_PLAYER && spell->Id == ORB && !m_creature->HasAura(ENRAGE, 0))
+ if(caster->GetTypeId() == TYPEID_PLAYER && spell->Id == ORB && !m_creature->HasAura(ENRAGE))
{
PlayerGUID = caster->GetGUID();
if(PlayerGUID)
diff --git a/src/bindings/scripts/scripts/zone/karazhan/boss_curator.cpp b/src/bindings/scripts/scripts/zone/karazhan/boss_curator.cpp
index 9c5563e8ac8..c71870b3232 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/boss_curator.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/boss_curator.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -6,18 +6,18 @@
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/* ScriptData
SDName: Boss_Curator
SD%Complete: 100
-SDComment: Evocation may cause client crash (Core related)
+SDComment:
SDCategory: Karazhan
EndScriptData */
@@ -34,10 +34,6 @@ EndScriptData */
//Flare spell info
#define SPELL_ASTRAL_FLARE_PASSIVE 30234 //Visual effect + Flare damage
-#define SPELL_ASTRAL_FLARE_NE 30236
-#define SPELL_ASTRAL_FLARE_NW 30239
-#define SPELL_ASTRAL_FLARE_SE 30240
-#define SPELL_ASTRAL_FLARE_SW 30241
//Curator spell info
#define SPELL_HATEFUL_BOLT 30383
@@ -45,7 +41,7 @@ EndScriptData */
#define SPELL_ENRAGE 30403 //Arcane Infusion: Transforms Curator and adds damage.
#define SPELL_BERSERK 26662
-struct TRINITY_DLL_DECL boss_curatorAI : public ScriptedAI
+struct TRINITY_DLL_DECL boss_curatorAI : public ScriptedAI
{
boss_curatorAI(Creature *c) : ScriptedAI(c) {}
@@ -69,8 +65,8 @@ struct TRINITY_DLL_DECL boss_curatorAI : public ScriptedAI
{
switch(rand()%2)
{
- case 0: DoScriptText(SAY_KILL1, m_creature); break;
- case 1: DoScriptText(SAY_KILL2, m_creature); break;
+ case 0: DoScriptText(SAY_KILL1, m_creature); break;
+ case 1: DoScriptText(SAY_KILL2, m_creature); break;
}
}
@@ -89,18 +85,38 @@ struct TRINITY_DLL_DECL boss_curatorAI : public ScriptedAI
if (!UpdateVictim() )
return;
- if (Evocating && !m_creature->HasAura(SPELL_EVOCATION, 0))
- Evocating = false;
+ //always decrease BerserkTimer
+ if (BerserkTimer < diff)
+ {
+ //if evocate, then break evocate
+ if (Evocating)
+ {
+ if (m_creature->HasAura(SPELL_EVOCATION))
+ m_creature->RemoveAurasDueToSpell(SPELL_EVOCATION);
+
+ Evocating = false;
+ }
+
+ //may not be correct SAY (generic hard enrage)
+ DoScriptText(SAY_ENRAGE, m_creature);
- if (m_creature->GetPower(POWER_MANA) <= 1000 && !Evocating)
+ m_creature->InterruptNonMeleeSpells(true);
+ DoCast(m_creature, SPELL_BERSERK);
+
+ //don't know if he's supposed to do summon/evocate after hard enrage (probably not)
+ Enraged = true;
+ }else BerserkTimer -= diff;
+
+ if (Evocating)
{
- DoScriptText(SAY_EVOCATE, m_creature);
- m_creature->InterruptNonMeleeSpells(false);
- DoCast(m_creature, SPELL_EVOCATION);
- Evocating = true;
+ //not supposed to do anything while evocate
+ if (m_creature->HasAura(SPELL_EVOCATION))
+ return;
+ else
+ Evocating = false;
}
- if (!Enraged && !Evocating)
+ if (!Enraged)
{
if (AddTimer < diff)
{
@@ -113,29 +129,40 @@ struct TRINITY_DLL_DECL boss_curatorAI : public ScriptedAI
{
AstralFlare->CastSpell(AstralFlare, SPELL_ASTRAL_FLARE_PASSIVE, false);
AstralFlare->AI()->AttackStart(target);
+ AstralFlare->ApplySpellImmune(0, IMMUNITY_STATE, SPELL_AURA_MOD_TAUNT, true);
+ AstralFlare->ApplySpellImmune(0, IMMUNITY_EFFECT,SPELL_EFFECT_ATTACK_ME, true);
}
- //Reduce Mana by 10%
- int32 mana = (int32)(0.1f*(m_creature->GetMaxPower(POWER_MANA)));
- m_creature->ModifyPower(POWER_MANA, -mana);
- switch(rand()%4)
+ //Reduce Mana by 10% of max health
+ if (int32 mana = m_creature->GetMaxPower(POWER_MANA))
{
- case 0: DoScriptText(SAY_SUMMON1, m_creature);break;
- case 1: DoScriptText(SAY_SUMMON2, m_creature);break;
+ mana /= 10;
+ m_creature->ModifyPower(POWER_MANA, -mana);
+
+ //if this get's us below 10%, then we evocate (the 10th should be summoned now)
+ if (m_creature->GetPower(POWER_MANA)*100 / m_creature->GetMaxPower(POWER_MANA) < 10)
+ {
+ DoScriptText(SAY_EVOCATE, m_creature);
+ m_creature->InterruptNonMeleeSpells(false);
+ DoCast(m_creature, SPELL_EVOCATION);
+ Evocating = true;
+ //no AddTimer cooldown, this will make first flare appear instantly after evocate end, like expected
+ return;
+ }
+ else
+ {
+ switch(rand()%4)
+ {
+ case 0: DoScriptText(SAY_SUMMON1, m_creature); break;
+ case 1: DoScriptText(SAY_SUMMON2, m_creature); break;
+ }
+ }
}
+
AddTimer = 10000;
}else AddTimer -= diff;
- if (HatefulBoltTimer < diff)
- {
- Unit* target = NULL;
- target = SelectUnit(SELECT_TARGET_TOPAGGRO, 1);
- DoCast(target, SPELL_HATEFUL_BOLT);
-
- HatefulBoltTimer = 15000;
- }else HatefulBoltTimer -= diff;
-
- if (m_creature->GetHealth()*100 / m_creature->GetMaxHealth() < 15)
+ if (m_creature->GetHealth()*100 / m_creature->GetMaxHealth() <= 15)
{
Enraged = true;
DoCast(m_creature, SPELL_ENRAGE);
@@ -143,11 +170,17 @@ struct TRINITY_DLL_DECL boss_curatorAI : public ScriptedAI
}
}
- if (BerserkTimer < diff)
+ if (HatefulBoltTimer < diff)
{
- DoCast(m_creature, SPELL_BERSERK);
- DoScriptText(SAY_ENRAGE, m_creature);
- }else BerserkTimer -= diff;
+ if (Enraged)
+ HatefulBoltTimer = 7000;
+ else
+ HatefulBoltTimer = 15000;
+
+ if (Unit* target = SelectUnit(SELECT_TARGET_TOPAGGRO, 1))
+ DoCast(target, SPELL_HATEFUL_BOLT);
+
+ }else HatefulBoltTimer -= diff;
DoMeleeAttackIfReady();
}
@@ -162,8 +195,7 @@ void AddSC_boss_curator()
{
Script *newscript;
newscript = new Script;
- newscript->Name="boss_curator";
+ newscript->Name = "boss_curator";
newscript->GetAI = &GetAI_boss_curator;
newscript->RegisterSelf();
}
-
diff --git a/src/bindings/scripts/scripts/zone/karazhan/boss_maiden_of_virtue.cpp b/src/bindings/scripts/scripts/zone/karazhan/boss_maiden_of_virtue.cpp
index 230b31c69bb..95e34e85622 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/boss_maiden_of_virtue.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/boss_maiden_of_virtue.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -51,9 +51,9 @@ struct TRINITY_DLL_DECL boss_maiden_of_virtueAI : public ScriptedAI
void Reset()
{
- Repentance_Timer = 30000+(rand()%15000);
+ Repentance_Timer = 25000+(rand()%15000);
Holyfire_Timer = 8000+(rand()%17000);
- Holywrath_Timer = 20000+(rand()%10000);
+ Holywrath_Timer = 15000+(rand()%10000);
Holyground_Timer = 3000;
Enrage_Timer = 600000;
@@ -109,7 +109,7 @@ struct TRINITY_DLL_DECL boss_maiden_of_virtueAI : public ScriptedAI
case 0: DoScriptText(SAY_REPENTANCE1, m_creature);break;
case 1: DoScriptText(SAY_REPENTANCE2, m_creature);break;
}
- Repentance_Timer = 30000 + rand()%15000; //A little randomness on that spell
+ Repentance_Timer = 25000 + rand()%10000; //A little randomness on that spell
}else Repentance_Timer -= diff;
if (Holyfire_Timer < diff)
@@ -117,7 +117,7 @@ struct TRINITY_DLL_DECL boss_maiden_of_virtueAI : public ScriptedAI
if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM,0))
DoCast(target,SPELL_HOLYFIRE);
- Holyfire_Timer = 8000 + rand()%17000; //Anywhere from 8 to 25 seconds, good luck having several of those in a row!
+ Holyfire_Timer = 8000 + rand()%15000; //Anywhere from 8 to 23 seconds, good luck having several of those in a row!
}else Holyfire_Timer -= diff;
if (Holywrath_Timer < diff)
@@ -125,7 +125,7 @@ struct TRINITY_DLL_DECL boss_maiden_of_virtueAI : public ScriptedAI
if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM,0))
DoCast(target,SPELL_HOLYWRATH);
- Holywrath_Timer = 20000+(rand()%10000); //20-30 secs sounds nice
+ Holywrath_Timer = 20000+(rand()%5000); //20-30 secs sounds nice
}else Holywrath_Timer -= diff;
diff --git a/src/bindings/scripts/scripts/zone/karazhan/boss_midnight.cpp b/src/bindings/scripts/scripts/zone/karazhan/boss_midnight.cpp
index 8bb8a5edbcd..e488ea26810 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/boss_midnight.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/boss_midnight.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -185,6 +185,9 @@ struct TRINITY_DLL_DECL boss_attumenAI : public ScriptedAI
void Reset()
{
ResetTimer = 2000;
+
+ m_creature->ApplySpellImmune(0, IMMUNITY_STATE, SPELL_AURA_MOD_TAUNT, true);
+ m_creature->ApplySpellImmune(0, IMMUNITY_EFFECT,SPELL_EFFECT_ATTACK_ME, true);
}
void Aggro(Unit* who) {}
@@ -283,6 +286,7 @@ struct TRINITY_DLL_DECL boss_attumenAI : public ScriptedAI
{
((boss_midnightAI*)(pMidnight->AI()))->Mount(m_creature);
m_creature->SetHealth(pMidnight->GetHealth());
+ DoResetThreat();
}
}
}
diff --git a/src/bindings/scripts/scripts/zone/karazhan/boss_moroes.cpp b/src/bindings/scripts/scripts/zone/karazhan/boss_moroes.cpp
index 0d3f6f010c6..b0457b49359 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/boss_moroes.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/boss_moroes.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -150,7 +150,7 @@ struct TRINITY_DLL_DECL boss_moroesAI : public ScriptedAI
for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
{
- if (i->getSource()->isAlive() && i->getSource()->HasAura(SPELL_GARROTE,0))
+ if (i->getSource()->isAlive() && i->getSource()->HasAura(SPELL_GARROTE))
i->getSource()->RemoveAurasDueToSpell(SPELL_GARROTE);
}
}
@@ -320,6 +320,8 @@ struct TRINITY_DLL_DECL boss_moroesAI : public ScriptedAI
m_creature->setFaction(16);
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
+ m_creature->ApplySpellImmune(0, IMMUNITY_STATE, SPELL_AURA_MOD_TAUNT, true);
+ m_creature->ApplySpellImmune(0, IMMUNITY_EFFECT,SPELL_EFFECT_ATTACK_ME, true);
m_creature->AI()->AttackStart(m_creature->getVictim());
InVanish = false;
}else Wait_Timer -= diff;
@@ -540,7 +542,7 @@ struct TRINITY_DLL_DECL boss_baron_rafe_dreugerAI : public boss_moroes_guestAI
struct TRINITY_DLL_DECL boss_lady_catriona_von_indiAI : public boss_moroes_guestAI
{
//Holy Priest
- boss_lady_catriona_von_indiAI(Creature *c) : boss_moroes_guestAI(c) {}
+ boss_lady_catriona_von_indiAI(Creature *c) : boss_moroes_guestAI(c) {Reset();}
uint32 DispelMagic_Timer;
uint32 GreaterHeal_Timer;
@@ -610,7 +612,7 @@ struct TRINITY_DLL_DECL boss_lady_catriona_von_indiAI : public boss_moroes_guest
struct TRINITY_DLL_DECL boss_lady_keira_berrybuckAI : public boss_moroes_guestAI
{
//Holy Pally
- boss_lady_keira_berrybuckAI(Creature *c) : boss_moroes_guestAI(c) {}
+ boss_lady_keira_berrybuckAI(Creature *c) : boss_moroes_guestAI(c) {Reset();}
uint32 Cleanse_Timer;
uint32 GreaterBless_Timer;
@@ -727,7 +729,7 @@ struct TRINITY_DLL_DECL boss_lord_robin_darisAI : public boss_moroes_guestAI
struct TRINITY_DLL_DECL boss_lord_crispin_ferenceAI : public boss_moroes_guestAI
{
//Arms Warr
- boss_lord_crispin_ferenceAI(Creature *c) : boss_moroes_guestAI(c) {}
+ boss_lord_crispin_ferenceAI(Creature *c) : boss_moroes_guestAI(c) {Reset();}
uint32 Disarm_Timer;
uint32 HeroicStrike_Timer;
diff --git a/src/bindings/scripts/scripts/zone/karazhan/boss_netherspite.cpp b/src/bindings/scripts/scripts/zone/karazhan/boss_netherspite.cpp
index b074dc920c1..6db1b193234 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/boss_netherspite.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/boss_netherspite.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/karazhan/boss_nightbane.cpp b/src/bindings/scripts/scripts/zone/karazhan/boss_nightbane.cpp
index 96f58bd3a3c..fd7e6176433 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/boss_nightbane.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/boss_nightbane.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -134,9 +134,9 @@ struct TRINITY_DLL_DECL boss_nightbaneAI : public ScriptedAI
void HandleTerraceDoors(bool open)
{
if(GameObject *Door = GameObject::GetGameObject((*m_creature),pInstance->GetData64(DATA_MASTERS_TERRACE_DOOR_1)))
- Door->SetUInt32Value(GAMEOBJECT_STATE, open ? 0 : 1);
+ Door->SetGoState(open ? 0 : 1);
if(GameObject *Door = GameObject::GetGameObject((*m_creature),pInstance->GetData64(DATA_MASTERS_TERRACE_DOOR_2)))
- Door->SetUInt32Value(GAMEOBJECT_STATE, open ? 0 : 1);
+ Door->SetGoState(open ? 0 : 1);
}
void Aggro(Unit *who)
diff --git a/src/bindings/scripts/scripts/zone/karazhan/boss_prince_malchezaar.cpp b/src/bindings/scripts/scripts/zone/karazhan/boss_prince_malchezaar.cpp
index 3de8e352ded..54c04f59743 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/boss_prince_malchezaar.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/boss_prince_malchezaar.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -37,7 +37,7 @@ EndScriptData */
#define SAY_SUMMON2 -1532101
#define SAY_DEATH -1532102
-// 19 Coordinates for Infernal spawns
+// 18 Coordinates for Infernal spawns
struct InfernalPoint
{
float x,y;
@@ -64,11 +64,10 @@ static InfernalPoint InfernalPoints[] =
{-10948.8, -2005.1},
{-10984.0, -2019.3},
{-10932.8, -1979.6},
- {-10932.8, -1979.6},
{-10935.7, -1996.0}
};
-#define TOTAL_INFERNAL_POINTS 19
+#define TOTAL_INFERNAL_POINTS 18
//Enfeeble is supposed to reduce hp to 1 and then heal player back to full when it ends
//Along with reducing healing and regen while enfeebled to 0%
@@ -81,9 +80,10 @@ static InfernalPoint InfernalPoints[] =
#define SPELL_SW_PAIN 30854 //Shadow word pain during phase 1 and 3 (different targeting rules though)
#define SPELL_THRASH_PASSIVE 12787 //Extra attack chance during phase 2
#define SPELL_SUNDER_ARMOR 30901 //Sunder armor during phase 2
-#define SPELL_THRASH_AURA 3417 //Passive proc chance for thrash
+#define SPELL_THRASH_AURA 12787 //Passive proc chance for thrash
#define SPELL_EQUIP_AXES 30857 //Visual for axe equiping
-#define SPELL_AMPLIFY_DAMAGE 12738 //Amplifiy during phase 3
+#define SPELL_AMPLIFY_DAMAGE 39095 //Amplifiy during phase 3
+#define SPELL_CLEAVE 30131 //Same as Nightbane.
#define SPELL_HELLFIRE 30859 //Infenals' hellfire aura
#define NETHERSPITE_INFERNAL 17646 //The netherspite infernal creature
#define MALCHEZARS_AXE 17650 //Malchezar's axes (creatures), summoned during phase 3
@@ -168,6 +168,7 @@ struct TRINITY_DLL_DECL boss_malchezaarAI : public ScriptedAI
uint32 SWPainTimer;
uint32 SunderArmorTimer;
uint32 AmplifyDamageTimer;
+ uint32 Cleave_Timer;
uint32 InfernalTimer;
uint32 AxesTargetSwitchTimer;
uint32 InfernalCleanupTimer;
@@ -196,12 +197,14 @@ struct TRINITY_DLL_DECL boss_malchezaarAI : public ScriptedAI
EnfeebleTimer = 30000;
EnfeebleResetTimer = 38000;
- ShadowNovaTimer = 35000;
+ ShadowNovaTimer = 35500;
SWPainTimer = 20000;
- AmplifyDamageTimer = 10000;
+ AmplifyDamageTimer = 5000;
+ Cleave_Timer = 8000;
InfernalTimer = 45000;
InfernalCleanupTimer = 47000;
AxesTargetSwitchTimer = 7500 + rand()%12500;
+ SunderArmorTimer = 5000 + rand()%5000;
phase = 1;
if(pInstance)
@@ -288,11 +291,11 @@ struct TRINITY_DLL_DECL boss_malchezaarAI : public ScriptedAI
void ClearWeapons()
{
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 0);
+ //m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, 0);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+2, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, 0);
+ //m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+2, 0);
//damage
const CreatureInfo *cinfo = m_creature->GetCreatureInfo();
@@ -432,11 +435,11 @@ struct TRINITY_DLL_DECL boss_malchezaarAI : public ScriptedAI
m_creature->CastSpell(m_creature, SPELL_THRASH_AURA, true);
//models
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, AXE_EQUIP_MODEL);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, AXE_EQUIP_INFO);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, AXE_EQUIP_MODEL);
+ //m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, AXE_EQUIP_INFO);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY+1, AXE_EQUIP_MODEL);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+2, AXE_EQUIP_INFO);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID+1, AXE_EQUIP_MODEL);
+ //m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO+2, AXE_EQUIP_INFO);
//damage
const CreatureInfo *cinfo = m_creature->GetCreatureInfo();
@@ -474,8 +477,8 @@ struct TRINITY_DLL_DECL boss_malchezaarAI : public ScriptedAI
Creature *axe = m_creature->SummonCreature(MALCHEZARS_AXE, m_creature->GetPositionX(), m_creature->GetPositionY(), m_creature->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 1000);
if(axe)
{
- axe->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, AXE_EQUIP_MODEL);
- axe->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, AXE_EQUIP_INFO);
+ axe->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, AXE_EQUIP_MODEL);
+ //axe->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, AXE_EQUIP_INFO);
axe->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
axe->setFaction(m_creature->getFaction());
@@ -499,9 +502,16 @@ struct TRINITY_DLL_DECL boss_malchezaarAI : public ScriptedAI
if(SunderArmorTimer < diff)
{
DoCast(m_creature->getVictim(), SPELL_SUNDER_ARMOR);
- SunderArmorTimer = 15000;
+ SunderArmorTimer = 10000 + rand()%8000;
}else SunderArmorTimer -= diff;
+
+ if (Cleave_Timer < diff)
+ {
+ DoCast(m_creature->getVictim(), SPELL_CLEAVE);
+ Cleave_Timer = 6000 + rand()%6000;
+
+ }else Cleave_Timer -= diff;
}
else
{
@@ -543,13 +553,13 @@ struct TRINITY_DLL_DECL boss_malchezaarAI : public ScriptedAI
if(InfernalTimer < diff)
{
SummonInfernal(diff);
- InfernalTimer = phase == 3 ? 15000 : 45000; //15 secs in phase 3, 45 otherwise
+ InfernalTimer = phase == 3 ? 14500 : 44500; //15 secs in phase 3, 45 otherwise
}else InfernalTimer -= diff;
if(ShadowNovaTimer < diff)
{
DoCast(m_creature->getVictim(), SPELL_SHADOWNOVA);
- ShadowNovaTimer = phase == 3 ? 35000 : -1;
+ ShadowNovaTimer = phase == 3 ? 31000 : -1;
}else ShadowNovaTimer -= diff;
if(phase != 2)
diff --git a/src/bindings/scripts/scripts/zone/karazhan/boss_shade_of_aran.cpp b/src/bindings/scripts/scripts/zone/karazhan/boss_shade_of_aran.cpp
index f98d85f9125..98aa93f3b8d 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/boss_shade_of_aran.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/boss_shade_of_aran.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -273,8 +273,7 @@ struct TRINITY_DLL_DECL boss_aranAI : public ScriptedAI
m_creature->CastSpell(m_creature, SPELL_MASS_POLY, true);
m_creature->CastSpell(m_creature, SPELL_CONJURE, false);
m_creature->CastSpell(m_creature, SPELL_DRINK, false);
- //Sitting down
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 1);
+ m_creature->SetStandState(UNIT_STAND_STATE_SIT);
DrinkInturruptTimer = 10000;
}
}
@@ -284,7 +283,7 @@ struct TRINITY_DLL_DECL boss_aranAI : public ScriptedAI
{
Drinking = false;
m_creature->RemoveAurasDueToSpell(SPELL_DRINK);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
m_creature->SetPower(POWER_MANA, m_creature->GetMaxPower(POWER_MANA)-32000);
m_creature->CastSpell(m_creature, SPELL_POTION, false);
}
@@ -295,7 +294,7 @@ struct TRINITY_DLL_DECL boss_aranAI : public ScriptedAI
DrinkInturruptTimer -= diff;
else
{
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
m_creature->CastSpell(m_creature, SPELL_POTION, true);
m_creature->CastSpell(m_creature, SPELL_AOE_PYROBLAST, false);
DrinkInturrupted = true;
diff --git a/src/bindings/scripts/scripts/zone/karazhan/boss_terestian_illhoof.cpp b/src/bindings/scripts/scripts/zone/karazhan/boss_terestian_illhoof.cpp
index 4cbe59aabb5..13dd8feab34 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/boss_terestian_illhoof.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/boss_terestian_illhoof.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -45,11 +45,10 @@ EndScriptData */
#define SPELL_FIENDISH_PORTAL 30171 // Opens portal and summons Fiendish Portal, 2 sec cast
#define SPELL_FIENDISH_PORTAL_1 30179 // Opens portal and summons Fiendish Portal, instant cast
-#define SPELL_FIREBOLT 18086 // Blasts a target for 150 Fire damage.
+#define SPELL_FIREBOLT 30050 // Blasts a target for 150 Fire damage.
#define SPELL_BROKEN_PACT 30065 // All damage taken increased by 25%.
#define SPELL_AMPLIFY_FLAMES 30053 // Increases the Fire damage taken by an enemy by 500 for 25 sec.
-#define SPELL_FIREBOLT 18086 // Blasts a target for 150 Fire damage.
#define CREATURE_DEMONCHAINS 17248
#define CREATURE_FIENDISHIMP 17267
@@ -79,8 +78,7 @@ struct TRINITY_DLL_DECL mob_kilrekAI : public ScriptedAI
void Reset()
{
TerestianGUID = 0;
-
- AmplifyTimer = 0;
+ AmplifyTimer = 2000;
}
void Aggro(Unit *who)
@@ -121,13 +119,10 @@ struct TRINITY_DLL_DECL mob_kilrekAI : public ScriptedAI
m_creature->InterruptNonMeleeSpells(false);
DoCast(m_creature->getVictim(),SPELL_AMPLIFY_FLAMES);
- AmplifyTimer = 20000;
+ AmplifyTimer = 10000 + rand()%10000;
}else AmplifyTimer -= diff;
- //Chain cast
- if (!m_creature->IsNonMeleeSpellCasted(false) && m_creature->IsWithinDistInMap(m_creature->getVictim(), 30))
- DoCast(m_creature->getVictim(),SPELL_FIREBOLT);
- else DoMeleeAttackIfReady();
+ DoMeleeAttackIfReady();
}
};
@@ -161,6 +156,8 @@ struct TRINITY_DLL_DECL boss_terestianAI : public ScriptedAI
{
boss_terestianAI(Creature *c) : ScriptedAI(c)
{
+ for(uint8 i = 0; i < 2; ++i)
+ PortalGUID[i] = 0;
pInstance = ((ScriptedInstance*)c->GetInstanceData());
}
@@ -175,6 +172,7 @@ struct TRINITY_DLL_DECL boss_terestianAI : public ScriptedAI
uint32 SummonTimer;
uint32 BerserkTimer;
+ bool ReSummon;
bool SummonKilrek;
bool SummonedPortals;
bool Berserk;
@@ -201,6 +199,7 @@ struct TRINITY_DLL_DECL boss_terestianAI : public ScriptedAI
SummonedPortals = false;
Berserk = false;
+ ReSummon = false;
if(pInstance)
pInstance->SetData(DATA_TERESTIAN_EVENT, NOT_STARTED);
@@ -212,8 +211,14 @@ struct TRINITY_DLL_DECL boss_terestianAI : public ScriptedAI
if(pInstance)
{
- // Put Kil'rek in combat against our target so players don't skip him
Creature* Kilrek = (Unit::GetCreature(*m_creature, pInstance->GetData64(DATA_KILREK)));
+ // Respawn Kil'rek on aggro if Kil'rek is dead.
+ if (Kilrek && !Kilrek->isAlive())
+ {
+ Kilrek->Respawn();
+ }
+
+ // Put Kil'rek in combat against our target so players don't skip him
if(Kilrek && !Kilrek->getVictim())
Kilrek->AddThreat(who, 1.0f);
@@ -257,18 +262,22 @@ struct TRINITY_DLL_DECL boss_terestianAI : public ScriptedAI
if(CheckKilrekTimer < diff)
{
+
CheckKilrekTimer = 5000;
if(pInstance)
uint64 KilrekGUID = pInstance->GetData64(DATA_KILREK);
else ERROR_INST_DATA(m_creature);
- Creature* Kilrek = (Unit::GetCreature((*m_creature), KilrekGUID));
+ Creature* Kilrek = (Unit::GetCreature(*m_creature, pInstance->GetData64(DATA_KILREK)));
if(SummonKilrek && Kilrek)
{
Kilrek->Respawn();
if(Kilrek->AI())
+ {
Kilrek->AI()->AttackStart(m_creature->getVictim());
+ m_creature->RemoveAurasDueToSpell(SPELL_BROKEN_PACT);
+ }
SummonKilrek = false;
}
@@ -355,7 +364,9 @@ struct TRINITY_DLL_DECL mob_karazhan_impAI : public ScriptedAI
void Reset()
{
- FireboltTimer = 3000;
+ FireboltTimer = 2000;
+
+ m_creature->ApplySpellImmune(0, IMMUNITY_SCHOOL, SPELL_SCHOOL_MASK_FIRE, true);
}
void Aggro(Unit *who) {}
@@ -369,7 +380,7 @@ struct TRINITY_DLL_DECL mob_karazhan_impAI : public ScriptedAI
if(FireboltTimer < diff)
{
DoCast(m_creature->getVictim(), SPELL_FIREBOLT);
- FireboltTimer = 1500;
+ FireboltTimer = 2200;
}else FireboltTimer -= diff;
DoMeleeAttackIfReady();
diff --git a/src/bindings/scripts/scripts/zone/karazhan/bosses_opera.cpp b/src/bindings/scripts/scripts/zone/karazhan/bosses_opera.cpp
index cd404e2ff15..2fa0184bd42 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/bosses_opera.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/bosses_opera.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -91,7 +91,7 @@ void SummonCroneIfReady(ScriptedInstance* pInstance, Creature *_Creature)
pInstance->SetData(DATA_OPERA_OZ_DEATHCOUNT, 0); // Increment DeathCount
if(pInstance->GetData(DATA_OPERA_OZ_DEATHCOUNT) == 4)
{
- Creature* Crone = _Creature->SummonCreature(CREATURE_CRONE, -10891.96, -1755.95, _Creature->GetPositionZ(), 4.64, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 30000);
+ Creature* Crone = _Creature->SummonCreature(CREATURE_CRONE, -10891.96, -1755.95, _Creature->GetPositionZ(), 4.64, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000);
if(Crone)
{
if(_Creature->getVictim())
@@ -117,7 +117,6 @@ struct TRINITY_DLL_DECL boss_dorotheeAI : public ScriptedAI
bool SummonedTito;
bool TitoDied;
- bool InCombat;
void Reset()
{
@@ -129,7 +128,6 @@ struct TRINITY_DLL_DECL boss_dorotheeAI : public ScriptedAI
SummonedTito = false;
TitoDied = false;
- InCombat = false;
}
void Aggro(Unit* who)
@@ -205,13 +203,11 @@ struct TRINITY_DLL_DECL mob_titoAI : public ScriptedAI
mob_titoAI(Creature* c) : ScriptedAI(c) {}
uint64 DorotheeGUID;
-
uint32 YipTimer;
void Reset()
{
DorotheeGUID = 0;
-
YipTimer = 10000;
}
@@ -247,7 +243,7 @@ struct TRINITY_DLL_DECL mob_titoAI : public ScriptedAI
void boss_dorotheeAI::SummonTito()
{
- Creature* Tito = DoSpawnCreature(CREATURE_TITO, 0, 0, 0, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 45000);
+ Creature* Tito = DoSpawnCreature(CREATURE_TITO, 0, 0, 0, 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000);
if(Tito)
{
DoScriptText(SAY_DOROTHEE_SUMMON, m_creature);
@@ -301,8 +297,15 @@ struct TRINITY_DLL_DECL boss_strawmanAI : public ScriptedAI
void SpellHit(Unit* caster, const SpellEntry *Spell)
{
- if((Spell->SchoolMask == SPELL_SCHOOL_MASK_FIRE) && (!(rand()%10)))
+ if ((Spell->SchoolMask == SPELL_SCHOOL_MASK_FIRE) && (!(rand()%10)))
+ {
+ /*
+ if (not direct damage(aoe,dot))
+ return;
+ */
+
DoCast(m_creature, SPELL_BURNING_STRAW, true);
+ }
}
void JustDied(Unit* killer)
@@ -569,9 +572,13 @@ struct TRINITY_DLL_DECL boss_croneAI : public ScriptedAI
if(pInstance)
{
pInstance->SetData(DATA_OPERA_EVENT, DONE);
- GameObject* Door = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GAMEOBJECT_STAGEDOORRIGHT));
- if(Door)
- Door->UseDoorOrButton();
+
+ if (GameObject* lDoor = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GAMEOBJECT_STAGEDOORLEFT)))
+ lDoor->SetGoState(0);
+ if (GameObject* rDoor = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GAMEOBJECT_STAGEDOORRIGHT)))
+ rDoor->SetGoState(0);
+ if (GameObject* pSideEntrance = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GO_SIDE_ENTRANCE_DOOR)))
+ pSideEntrance->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_LOCKED);
}
}
@@ -620,7 +627,7 @@ struct TRINITY_DLL_DECL mob_cycloneAI : public ScriptedAI
void UpdateAI(const uint32 diff)
{
- if(!m_creature->HasAura(SPELL_KNOCKBACK, 0))
+ if(!m_creature->HasAura(SPELL_KNOCKBACK))
DoCast(m_creature, SPELL_KNOCKBACK, true);
if(MoveTimer < diff)
@@ -705,7 +712,7 @@ bool GossipSelect_npc_grandmother(Player* player, Creature* _Creature, uint32 se
_Creature->SetVisibility(VISIBILITY_OFF);
float x,y,z;
_Creature->GetPosition(x,y,z);
- Creature* BigBadWolf = _Creature->SummonCreature(CREATURE_BIG_BAD_WOLF, x, y, z, 0, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 30000);
+ Creature* BigBadWolf = _Creature->SummonCreature(CREATURE_BIG_BAD_WOLF, x, y, z, 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 30000);
if(BigBadWolf)
{
BigBadWolf->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
@@ -760,9 +767,13 @@ struct TRINITY_DLL_DECL boss_bigbadwolfAI : public ScriptedAI
if(pInstance)
{
pInstance->SetData(DATA_OPERA_EVENT, DONE);
- GameObject* Door = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GAMEOBJECT_STAGEDOORRIGHT));
- if(Door)
- Door->UseDoorOrButton();
+
+ if (GameObject* lDoor = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GAMEOBJECT_STAGEDOORLEFT)))
+ lDoor->SetGoState(0);
+ if (GameObject* rDoor = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GAMEOBJECT_STAGEDOORRIGHT)))
+ rDoor->SetGoState(0);
+ if (GameObject* pSideEntrance = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GO_SIDE_ENTRANCE_DOOR)))
+ pSideEntrance->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_LOCKED);
}
}
@@ -795,8 +806,8 @@ struct TRINITY_DLL_DECL boss_bigbadwolfAI : public ScriptedAI
else
{
IsChasing = false;
- Unit* target = Unit::GetUnit((*m_creature), HoodGUID);
- if(target)
+
+ if (Unit* target = Unit::GetUnit((*m_creature), HoodGUID))
{
HoodGUID = 0;
if(DoGetThreat(target))
@@ -868,9 +879,9 @@ CreatureAI* GetAI_boss_bigbadwolf(Creature* _Creature)
#define SPELL_RES_VISUAL 24171
/*** Misc. Information ****/
-#define CREATURE_ROMULO 17533
-#define ROMULO_X -10900
-#define ROMULO_Y -1758
+#define CREATURE_ROMULO 17533
+#define ROMULO_X -10900
+#define ROMULO_Y -1758
enum RAJPhase
{
@@ -881,32 +892,28 @@ enum RAJPhase
void PretendToDie(Creature* _Creature)
{
- _Creature->InterruptNonMeleeSpells(false);
+ _Creature->InterruptNonMeleeSpells(true);
+ _Creature->RemoveAllAuras();
_Creature->SetHealth(0);
- _Creature->ClearComboPointHolders();
- _Creature->RemoveAllAurasOnDeath();
- _Creature->ModifyAuraState(AURA_STATE_HEALTHLESS_20_PERCENT, false);
- _Creature->ModifyAuraState(AURA_STATE_HEALTHLESS_35_PERCENT, false);
_Creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- _Creature->ClearAllReactives();
- _Creature->SetUInt64Value(UNIT_FIELD_TARGET,0);
- _Creature->GetMotionMaster()->Clear();
+ _Creature->GetMotionMaster()->MovementExpired(false);
_Creature->GetMotionMaster()->MoveIdle();
- _Creature->SetUInt32Value(UNIT_FIELD_BYTES_1,PLAYER_STATE_DEAD);
+ _Creature->SetStandState(UNIT_STAND_STATE_DEAD);
};
void Resurrect(Creature* target)
{
target->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
target->SetHealth(target->GetMaxHealth());
- target->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
+ target->SetStandState(UNIT_STAND_STATE_STAND);
target->CastSpell(target, SPELL_RES_VISUAL, true);
if(target->getVictim())
{
- target->SetUInt64Value(UNIT_FIELD_TARGET, target->getVictim()->GetGUID());
target->GetMotionMaster()->MoveChase(target->getVictim());
target->AI()->AttackStart(target->getVictim());
}
+ else
+ target->GetMotionMaster()->Initialize();
};
struct TRINITY_DLL_DECL boss_julianneAI : public ScriptedAI
@@ -920,18 +927,21 @@ struct TRINITY_DLL_DECL boss_julianneAI : public ScriptedAI
ScriptedInstance* pInstance;
+ uint32 EntryYellTimer;
+ uint32 AggroYellTimer;
+
uint64 RomuloGUID;
uint32 Phase;
- uint32 EntryYellTimer;
- uint32 AggroYellTimer;
uint32 BlindingPassionTimer;
uint32 DevotionTimer;
uint32 EternalAffectionTimer;
uint32 PowerfulAttractionTimer;
uint32 SummonRomuloTimer;
uint32 ResurrectTimer;
+ uint32 DrinkPoisonTimer;
+ uint32 ResurrectSelfTimer;
bool IsFakingDeath;
bool SummonedRomulo;
@@ -947,15 +957,18 @@ struct TRINITY_DLL_DECL boss_julianneAI : public ScriptedAI
Romulo->DealDamage(Romulo, Romulo->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
}
- RomuloGUID = 0;
}
+ RomuloGUID = 0;
Phase = PHASE_JULIANNE;
BlindingPassionTimer = 30000;
DevotionTimer = 15000;
EternalAffectionTimer = 25000;
PowerfulAttractionTimer = 5000;
+ SummonRomuloTimer = 10000;
+ DrinkPoisonTimer = 0;
+ ResurrectSelfTimer = 0;
if(IsFakingDeath)
Resurrect(m_creature);
@@ -983,6 +996,15 @@ struct TRINITY_DLL_DECL boss_julianneAI : public ScriptedAI
ScriptedAI::MoveInLineOfSight(who);
}
+ void SpellHit(Unit* caster, const SpellEntry *Spell)
+ {
+ if (Spell->Id == SPELL_DRINK_POISON)
+ {
+ DoScriptText(SAY_JULIANNE_DEATH01, m_creature);
+ DrinkPoisonTimer = 2500;
+ }
+ }
+
void DamageTaken(Unit* done_by, uint32 &damage);
void JustDied(Unit* killer)
@@ -992,9 +1014,13 @@ struct TRINITY_DLL_DECL boss_julianneAI : public ScriptedAI
if(pInstance)
{
pInstance->SetData(DATA_OPERA_EVENT, DONE);
- GameObject* Door = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GAMEOBJECT_STAGEDOORRIGHT));
- if(Door)
- Door->UseDoorOrButton();
+
+ if (GameObject* lDoor = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GAMEOBJECT_STAGEDOORLEFT)))
+ lDoor->SetGoState(0);
+ if (GameObject* rDoor = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GAMEOBJECT_STAGEDOORRIGHT)))
+ rDoor->SetGoState(0);
+ if (GameObject* pSideEntrance = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GO_SIDE_ENTRANCE_DOOR)))
+ pSideEntrance->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_LOCKED);
}
}
@@ -1010,12 +1036,14 @@ struct TRINITY_DLL_DECL boss_romuloAI : public ScriptedAI
{
boss_romuloAI(Creature* c) : ScriptedAI(c)
{
+ pInstance = ((ScriptedInstance*)c->GetInstanceData());
EntryYellTimer = 8000;
AggroYellTimer = 15000;
}
+
+ ScriptedInstance* pInstance;
uint64 JulianneGUID;
-
uint32 Phase;
uint32 EntryYellTimer;
@@ -1026,22 +1054,19 @@ struct TRINITY_DLL_DECL boss_romuloAI : public ScriptedAI
uint32 PoisonThrustTimer;
uint32 ResurrectTimer;
- bool JulianneDead;
bool IsFakingDeath;
+ bool JulianneDead;
void Reset()
{
JulianneGUID = 0;
-
Phase = PHASE_ROMULO;
BackwardLungeTimer = 15000;
DaringTimer = 20000;
DeadlySwatheTimer = 25000;
PoisonThrustTimer = 10000;
-
- if(IsFakingDeath)
- Resurrect(m_creature);
+ ResurrectTimer = 10000;
IsFakingDeath = false;
JulianneDead = false;
@@ -1074,6 +1099,18 @@ struct TRINITY_DLL_DECL boss_romuloAI : public ScriptedAI
void JustDied(Unit* killer)
{
DoScriptText(SAY_ROMULO_DEATH, m_creature);
+
+ if (pInstance)
+ {
+ pInstance->SetData(DATA_OPERA_EVENT, DONE);
+
+ if (GameObject* lDoor = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GAMEOBJECT_STAGEDOORLEFT)))
+ lDoor->SetGoState(0);
+ if (GameObject* rDoor = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GAMEOBJECT_STAGEDOORRIGHT)))
+ rDoor->SetGoState(0);
+ if (GameObject* pSideEntrance = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_GO_SIDE_ENTRANCE_DOOR)))
+ pSideEntrance->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_LOCKED);
+ }
}
void KilledUnit(Unit* victim)
@@ -1086,137 +1123,169 @@ struct TRINITY_DLL_DECL boss_romuloAI : public ScriptedAI
void boss_julianneAI::DamageTaken(Unit* done_by, uint32 &damage)
{
- if(damage < m_creature->GetHealth() || done_by == m_creature || done_by->GetGUID() == RomuloGUID)
+ if (damage < m_creature->GetHealth())
return;
+ //anything below only used if incoming damage will kill
+
if(Phase == PHASE_JULIANNE)
{
- DoScriptText(SAY_JULIANNE_DEATH01, m_creature);
+ damage = 0;
+
+ //this means already drinking, so return
+ if (IsFakingDeath)
+ return;
+
m_creature->InterruptNonMeleeSpells(true);
DoCast(m_creature, SPELL_DRINK_POISON);
- PretendToDie(m_creature);
- Phase = PHASE_ROMULO;
- damage = 0;
+
IsFakingDeath = true;
- SummonRomuloTimer = 10000;
+ //IS THIS USEFULL? Creature* Julianne = (Unit::GetCreature((*m_creature), JulianneGUID));
return;
}
- if(!IsFakingDeath)
+ if (Phase == PHASE_ROMULO)
{
- Creature* Romulo = (Unit::GetCreature((*m_creature), RomuloGUID));
- if(Romulo && Romulo->isAlive() && !((boss_romuloAI*)Romulo->AI())->IsFakingDeath)
- {
- ((boss_romuloAI*)Romulo->AI())->ResurrectTimer = 10000;
- ((boss_romuloAI*)Romulo->AI())->JulianneDead = true;
- }
- else
+ error_log("TSCR: boss_julianneAI: cannot take damage in PHASE_ROMULO, why was i here?");
+ damage = 0;
+ return;
+ }
+
+ if (Phase == PHASE_BOTH)
+ {
+ //if this is true then we have to kill romulo too
+ if (RomuloDead)
{
- m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
- m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- if(Romulo)
+ if (Creature* Romulo = (Unit::GetCreature((*m_creature), RomuloGUID)))
{
- Romulo->DealDamage(Romulo, Romulo->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
Romulo->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ Romulo->GetMotionMaster()->Clear();
+ Romulo->setDeathState(JUST_DIED);
+ Romulo->CombatStop();
+ Romulo->DeleteThreatList();
+ Romulo->SetUInt32Value(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_LOOTABLE);
}
- JustDied(done_by);
+ return;
}
- IsFakingDeath = true;
- PretendToDie(m_creature);
- damage = 0;
+ //if not already returned, then romulo is alive and we can pretend die
+ if (Creature* Romulo = (Unit::GetCreature((*m_creature), RomuloGUID)))
+ {
+ PretendToDie(m_creature);
+ IsFakingDeath = true;
+ ((boss_romuloAI*)Romulo->AI())->ResurrectTimer = 10000;
+ ((boss_romuloAI*)Romulo->AI())->JulianneDead = true;
+ damage = 0;
+ return;
+ }
}
- else
- damage = 0;
+ error_log("TSCR: boss_julianneAI: DamageTaken reach end of code, that should not happen.");
}
void boss_romuloAI::DamageTaken(Unit* done_by, uint32 &damage)
{
- if(damage < m_creature->GetHealth() || done_by == m_creature || done_by->GetGUID() == JulianneGUID)
+ if (damage < m_creature->GetHealth())
return;
- if(!IsFakingDeath)
+ //anything below only used if incoming damage will kill
+
+ if (Phase == PHASE_ROMULO)
{
- IsFakingDeath = true;
+ DoScriptText(SAY_ROMULO_DEATH, m_creature);
PretendToDie(m_creature);
+ IsFakingDeath = true;
+ Phase = PHASE_BOTH;
- if(Phase == PHASE_BOTH)
+ if (Creature* Julianne = (Unit::GetCreature((*m_creature), JulianneGUID)))
{
- Creature* Julianne = (Unit::GetCreature((*m_creature), JulianneGUID));
- if(Julianne && Julianne->isAlive() && !((boss_julianneAI*)Julianne->AI())->IsFakingDeath)
- {
- ((boss_julianneAI*)Julianne->AI())->ResurrectTimer = 10000;
- ((boss_julianneAI*)Julianne->AI())->RomuloDead = true;
- }
- else
- {
- m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
- m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- if(Julianne)
- {
- Julianne->DealDamage(Julianne, Julianne->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
- Julianne->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- }
- JustDied(done_by);
- }
+ ((boss_julianneAI*)Julianne->AI())->RomuloDead = true;
+ ((boss_julianneAI*)Julianne->AI())->ResurrectSelfTimer = 10000;
}
- else
+
+ damage = 0;
+ return;
+ }
+
+ if (Phase == PHASE_BOTH)
+ {
+ if (JulianneDead)
{
- Creature* Julianne = (Unit::GetCreature((*m_creature), JulianneGUID));
- if(Julianne)
+ if (Creature* Julianne = (Unit::GetCreature((*m_creature), JulianneGUID)))
{
- Resurrect(Julianne);
- m_creature->SetHealth(m_creature->GetMaxHealth());
- ((boss_julianneAI*)Julianne->AI())->ResurrectTimer = 4000;
- ((boss_julianneAI*)Julianne->AI())->RomuloDead = true;
- ((boss_julianneAI*)Julianne->AI())->Phase = PHASE_BOTH;
- ((boss_julianneAI*)Julianne->AI())->IsFakingDeath = false;
+ Julianne->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ Julianne->GetMotionMaster()->Clear();
+ Julianne->setDeathState(JUST_DIED);
+ Julianne->CombatStop();
+ Julianne->DeleteThreatList();
+ Julianne->SetUInt32Value(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_LOOTABLE);
}
- Phase = PHASE_BOTH;
+ return;
}
- damage = 0;
+ if (Creature* Julianne = (Unit::GetCreature((*m_creature), JulianneGUID)))
+ {
+ PretendToDie(m_creature);
+ IsFakingDeath = true;
+ ((boss_julianneAI*)Julianne->AI())->ResurrectTimer = 10000;
+ ((boss_julianneAI*)Julianne->AI())->RomuloDead = true;
+ damage = 0;
+ return;
+ }
}
- if(IsFakingDeath) damage = 0;
+ error_log("TSCR: boss_romuloAI: DamageTaken reach end of code, that should not happen.");
}
void boss_julianneAI::UpdateAI(const uint32 diff)
{
if(EntryYellTimer)
{
- if(EntryYellTimer < diff)
+ if (EntryYellTimer <= diff)
{
DoScriptText(SAY_JULIANNE_ENTER, m_creature);
- m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
EntryYellTimer = 0;
}else EntryYellTimer -= diff;
}
if(AggroYellTimer)
{
- if(AggroYellTimer < diff)
+ if (AggroYellTimer <= diff)
{
DoScriptText(SAY_JULIANNE_AGGRO, m_creature);
+ m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
+ m_creature->setFaction(16);
AggroYellTimer = 0;
}else AggroYellTimer -= diff;
}
- if(Phase == PHASE_ROMULO && !SummonedRomulo)
+ if (DrinkPoisonTimer)
+ {
+ //will do this 2secs after spell hit. this is time to display visual as expected
+ if (DrinkPoisonTimer <= diff)
+ {
+ PretendToDie(m_creature);
+ Phase = PHASE_ROMULO;
+ SummonRomuloTimer = 10000;
+ DrinkPoisonTimer = 0;
+ }else DrinkPoisonTimer -= diff;
+ }
+
+ if (Phase == PHASE_ROMULO && !SummonedRomulo)
{
if(SummonRomuloTimer < diff)
{
- Creature* Romulo = m_creature->SummonCreature(CREATURE_ROMULO, ROMULO_X, ROMULO_Y, m_creature->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN, 45000);
+ Creature* Romulo = m_creature->SummonCreature(CREATURE_ROMULO, ROMULO_X, ROMULO_Y, m_creature->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 60000);
if(Romulo)
{
RomuloGUID = Romulo->GetGUID();
((boss_romuloAI*)Romulo->AI())->JulianneGUID = m_creature->GetGUID();
((boss_romuloAI*)Romulo->AI())->Phase = PHASE_ROMULO;
+ Romulo->setFaction(16);
+
if(m_creature->getVictim())
{
- Romulo->AI()->AttackStart(m_creature->getVictim());
- Romulo->AddThreat(m_creature->getVictim(), 50.0f);
+ Romulo->AddThreat(m_creature->getVictim(), 0.0f);
}
DoZoneInCombat(Romulo);
}
@@ -1224,7 +1293,23 @@ void boss_julianneAI::UpdateAI(const uint32 diff)
}else SummonRomuloTimer -= diff;
}
- if(!UpdateVictim() ||IsFakingDeath)
+ if (ResurrectSelfTimer)
+ {
+ if (ResurrectSelfTimer <= diff)
+ {
+ Resurrect(m_creature);
+ Phase = PHASE_BOTH;
+ IsFakingDeath = false;
+
+ if (m_creature->getVictim())
+ AttackStart(m_creature->getVictim());
+
+ ResurrectSelfTimer = 0;
+ ResurrectTimer = 1000;
+ }else ResurrectSelfTimer -= diff;
+ }
+
+ if(!UpdateVictim() || IsFakingDeath)
return;
if(RomuloDead)
@@ -1237,9 +1322,9 @@ void boss_julianneAI::UpdateAI(const uint32 diff)
DoScriptText(SAY_JULIANNE_RESURRECT, m_creature);
Resurrect(Romulo);
((boss_romuloAI*)Romulo->AI())->IsFakingDeath = false;
+ RomuloDead = false;
ResurrectTimer = 10000;
}
- RomuloDead = false;
}else ResurrectTimer -= diff;
}
@@ -1266,10 +1351,8 @@ void boss_julianneAI::UpdateAI(const uint32 diff)
if(rand()%2 == 1 && SummonedRomulo)
{
Creature* Romulo = (Unit::GetCreature((*m_creature), RomuloGUID));
- if(Romulo && Romulo->isAlive() && !((boss_romuloAI*)Romulo->AI())->IsFakingDeath)
+ if (Romulo && Romulo->isAlive() && !RomuloDead)
DoCast(Romulo, SPELL_ETERNAL_AFFECTION);
- else
- return;
}else DoCast(m_creature, SPELL_ETERNAL_AFFECTION);
EternalAffectionTimer = 45000 + rand()%15000;
@@ -1293,9 +1376,9 @@ void boss_romuloAI::UpdateAI(const uint32 diff)
DoScriptText(SAY_ROMULO_RESURRECT, m_creature);
Resurrect(Julianne);
((boss_julianneAI*)Julianne->AI())->IsFakingDeath = false;
+ JulianneDead = false;
ResurrectTimer = 10000;
}
- JulianneDead = false;
}else ResurrectTimer -= diff;
}
diff --git a/src/bindings/scripts/scripts/zone/karazhan/def_karazhan.h b/src/bindings/scripts/scripts/zone/karazhan/def_karazhan.h
index d08911d9c76..47162ec2599 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/def_karazhan.h
+++ b/src/bindings/scripts/scripts/zone/karazhan/def_karazhan.h
@@ -1,44 +1,51 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
+
#ifndef DEF_KARAZHAN_H
#define DEF_KARAZHAN_H
-#define DATA_ATTUMEN_EVENT 1
-#define DATA_MOROES_EVENT 2
-#define DATA_MAIDENOFVIRTUE_EVENT 3
-#define DATA_OPTIONAL_BOSS_EVENT 4
-#define DATA_OPERA_EVENT 5
-#define DATA_CURATOR_EVENT 6
-#define DATA_SHADEOFARAN_EVENT 7
-#define DATA_TERESTIAN_EVENT 8
-#define DATA_NETHERSPITE_EVENT 9
-#define DATA_CHESS_EVENT 10
-#define DATA_MALCHEZZAR_EVENT 11
-#define DATA_NIGHTBANE_EVENT 12
-#define DATA_OPERA_PERFORMANCE 13
-#define DATA_OPERA_OZ_DEATHCOUNT 14
-#define DATA_KILREK 15
-#define DATA_TERESTIAN 16
-#define DATA_MOROES 17
-#define DATA_GAMEOBJECT_CURTAINS 18
-#define DATA_GAMEOBJECT_STAGEDOORLEFT 19
-#define DATA_GAMEOBJECT_STAGEDOORRIGHT 20
-#define DATA_GAMEOBJECT_LIBRARY_DOOR 21
-#define DATA_GAMEOBJECT_MASSIVE_DOOR 22
-#define DATA_GAMEOBJECT_NETHER_DOOR 23
-#define DATA_GAMEOBJECT_GAME_DOOR 24
-#define DATA_GAMEOBJECT_GAME_EXIT_DOOR 25
-#define DATA_IMAGE_OF_MEDIVH 26
-#define DATA_MASTERS_TERRACE_DOOR_1 27
-#define DATA_MASTERS_TERRACE_DOOR_2 28
+enum
+{
+ DATA_ATTUMEN_EVENT = 1,
+ DATA_MOROES_EVENT = 2,
+ DATA_MAIDENOFVIRTUE_EVENT = 3,
+ DATA_OPTIONAL_BOSS_EVENT = 4,
+ DATA_OPERA_EVENT = 5,
+ DATA_CURATOR_EVENT = 6,
+ DATA_SHADEOFARAN_EVENT = 7,
+ DATA_TERESTIAN_EVENT = 8,
+ DATA_NETHERSPITE_EVENT = 9,
+ DATA_CHESS_EVENT = 10,
+ DATA_MALCHEZZAR_EVENT = 11,
+ DATA_NIGHTBANE_EVENT = 12,
+ DATA_OPERA_PERFORMANCE = 13,
+ DATA_OPERA_OZ_DEATHCOUNT = 14,
+ DATA_KILREK = 15,
+ DATA_TERESTIAN = 16,
+ DATA_MOROES = 17,
+ DATA_GAMEOBJECT_CURTAINS = 18,
+ DATA_GAMEOBJECT_STAGEDOORLEFT = 19,
+ DATA_GAMEOBJECT_STAGEDOORRIGHT = 20,
+ DATA_GAMEOBJECT_LIBRARY_DOOR = 21,
+ DATA_GAMEOBJECT_MASSIVE_DOOR = 22,
+ DATA_GAMEOBJECT_NETHER_DOOR = 23,
+ DATA_GAMEOBJECT_GAME_DOOR = 24,
+ DATA_GAMEOBJECT_GAME_EXIT_DOOR = 25,
+ DATA_IMAGE_OF_MEDIVH = 26,
+ DATA_MASTERS_TERRACE_DOOR_1 = 27,
+ DATA_MASTERS_TERRACE_DOOR_2 = 28,
+ DATA_GO_SIDE_ENTRANCE_DOOR = 29
+};
-// Opera Performances
-#define EVENT_OZ 1
-#define EVENT_HOOD 2
-#define EVENT_RAJ 3
+enum OperaEvents
+{
+ EVENT_OZ = 1,
+ EVENT_HOOD = 2,
+ EVENT_RAJ = 3
+};
-#define ERROR_INST_DATA(a) error_log("SD2: Instance Data for Karazhan not set properly. Encounter for Creature Entry %u may not work properly.", a->GetEntry());
+#define ERROR_INST_DATA(a) error_log("TSCR: Instance Data for Karazhan not set properly. Encounter for Creature Entry %u may not work properly.", a->GetEntry());
#endif
diff --git a/src/bindings/scripts/scripts/zone/karazhan/instance_karazhan.cpp b/src/bindings/scripts/scripts/zone/karazhan/instance_karazhan.cpp
index 3952c0da167..e8dccdd62a4 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/instance_karazhan.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/instance_karazhan.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -46,6 +46,7 @@ struct TRINITY_DLL_DECL instance_karazhan : public ScriptedInstance
instance_karazhan(Map* map) : ScriptedInstance(map) {Initialize();}
uint32 Encounters[ENCOUNTERS];
+ std::string str_data;
uint32 OperaEvent;
uint32 OzDeathCount;
@@ -58,6 +59,7 @@ struct TRINITY_DLL_DECL instance_karazhan : public ScriptedInstance
uint64 MoroesGUID;
uint64 LibraryDoor; // Door at Shade of Aran
uint64 MassiveDoor; // Door at Netherspite
+ uint64 SideEntranceDoor; // Side Entrance
uint64 GamesmansDoor; // Door before Chess
uint64 GamesmansExitDoor; // Door after Chess
uint64 NetherspaceDoor; // Door at Malchezaar
@@ -82,6 +84,7 @@ struct TRINITY_DLL_DECL instance_karazhan : public ScriptedInstance
LibraryDoor = 0;
MassiveDoor = 0;
+ SideEntranceDoor = 0;
GamesmansDoor = 0;
GamesmansExitDoor = 0;
NetherspaceDoor = 0;
@@ -145,6 +148,7 @@ struct TRINITY_DLL_DECL instance_karazhan : public ScriptedInstance
case DATA_GAMEOBJECT_CURTAINS: return CurtainGUID;
case DATA_GAMEOBJECT_LIBRARY_DOOR: return LibraryDoor;
case DATA_GAMEOBJECT_MASSIVE_DOOR: return MassiveDoor;
+ case DATA_GO_SIDE_ENTRANCE_DOOR: return SideEntranceDoor;
case DATA_GAMEOBJECT_GAME_DOOR: return GamesmansDoor;
case DATA_GAMEOBJECT_GAME_EXIT_DOOR: return GamesmansExitDoor;
case DATA_GAMEOBJECT_NETHER_DOOR: return NetherspaceDoor;
@@ -183,7 +187,19 @@ struct TRINITY_DLL_DECL instance_karazhan : public ScriptedInstance
}
if(data == DONE)
+ {
+ OUT_SAVE_INST_DATA;
+
+ std::ostringstream saveStream;
+ saveStream << Encounters[0] << " " << Encounters[1] << " " << Encounters[2] << " "
+ << Encounters[3] << " " << Encounters[4] << " " << Encounters[5] << " " << Encounters[6] << " "
+ << Encounters[7] << " " << Encounters[8] << " " << Encounters[9] << " " << Encounters[10];
+
+ str_data = saveStream.str();
+
SaveToDB();
+ OUT_SAVE_INST_DATA_COMPLETE;
+ }
}
void SetData64(uint32 identifier, uint64 data)
@@ -208,6 +224,13 @@ struct TRINITY_DLL_DECL instance_karazhan : public ScriptedInstance
case 185134: NetherspaceDoor = go->GetGUID(); break;
case 184274: MastersTerraceDoor[0] = go->GetGUID(); break;
case 184280: MastersTerraceDoor[1] = go->GetGUID(); break;
+ case 184275:
+ SideEntranceDoor = go->GetGUID();
+ if (GetData(DATA_OPERA_EVENT) != DONE)
+ go->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_LOCKED);
+ else
+ go->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_LOCKED);
+ break;
}
switch(OperaEvent)
@@ -226,20 +249,7 @@ struct TRINITY_DLL_DECL instance_karazhan : public ScriptedInstance
const char* Save()
{
- OUT_SAVE_INST_DATA;
- std::ostringstream stream;
- stream << Encounters[0] << " " << Encounters[1] << " " << Encounters[2] << " " << Encounters[3] << " "
- << Encounters[4] << " " << Encounters[5] << " " << Encounters[6] << " " << Encounters[7] << " "
- << Encounters[8] << " " << Encounters[9] << " " << Encounters[10] << " " << Encounters[11];
- char* out = new char[stream.str().length() + 1];
- strcpy(out, stream.str().c_str());
- if(out)
- {
- OUT_SAVE_INST_DATA_COMPLETE;
- return out;
- }
-
- return NULL;
+ return str_data.c_str();
}
void Load(const char* in)
@@ -251,8 +261,8 @@ struct TRINITY_DLL_DECL instance_karazhan : public ScriptedInstance
}
OUT_LOAD_INST_DATA(in);
- std::istringstream stream(in);
- stream >> Encounters[0] >> Encounters[1] >> Encounters[2] >> Encounters[3]
+ std::istringstream loadStream(in);
+ loadStream >> Encounters[0] >> Encounters[1] >> Encounters[2] >> Encounters[3]
>> Encounters[4] >> Encounters[5] >> Encounters[6] >> Encounters[7]
>> Encounters[8] >> Encounters[9] >> Encounters[10] >> Encounters[11];
for(uint8 i = 0; i < ENCOUNTERS; ++i)
diff --git a/src/bindings/scripts/scripts/zone/karazhan/karazhan.cpp b/src/bindings/scripts/scripts/zone/karazhan/karazhan.cpp
index bdf7eed9f3a..3b550c34e72 100644
--- a/src/bindings/scripts/scripts/zone/karazhan/karazhan.cpp
+++ b/src/bindings/scripts/scripts/zone/karazhan/karazhan.cpp
@@ -1,4 +1,4 @@
- /* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ /* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -46,6 +46,10 @@ EndContentData */
#define SAY_RAJ_INTRO1 "The romantic plays are really tough, but you'll do better this time. You have TALENT. Ready?"
#define RAJ_GOSSIP1 "I've never been more ready."
+#define OZ_GM_GOSSIP1 "[GM] Change event to EVENT_OZ"
+#define OZ_GM_GOSSIP2 "[GM] Change event to EVENT_HOOD"
+#define OZ_GM_GOSSIP3 "[GM] Change event to EVENT_RAJ"
+
struct Dialogue
{
int32 textid;
@@ -181,6 +185,7 @@ struct TRINITY_DLL_DECL npc_barnesAI : public npc_escortAI
}
IsBeingEscorted = false;
PerformanceReady = true;
+ m_creature->SetFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_GOSSIP);
break;
}
}
@@ -377,6 +382,13 @@ bool GossipHello_npc_barnes(Player* player, Creature* _Creature)
{
player->ADD_GOSSIP_ITEM(0, OZ_GOSSIP1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
+ if (player->isGameMaster())
+ {
+ player->ADD_GOSSIP_ITEM(5, OZ_GM_GOSSIP1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3);
+ player->ADD_GOSSIP_ITEM(5, OZ_GM_GOSSIP2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 4);
+ player->ADD_GOSSIP_ITEM(5, OZ_GM_GOSSIP3, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 5);
+ }
+
if(!((npc_barnesAI*)_Creature->AI())->RaidWiped)
player->SEND_GOSSIP_MENU(8970, _Creature->GetGUID());
else
@@ -394,11 +406,25 @@ bool GossipSelect_npc_barnes(Player *player, Creature *_Creature, uint32 sender,
player->ADD_GOSSIP_ITEM(0, OZ_GOSSIP2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2);
player->SEND_GOSSIP_MENU(8971, _Creature->GetGUID());
break;
-
case GOSSIP_ACTION_INFO_DEF+2:
player->CLOSE_GOSSIP_MENU();
((npc_barnesAI*)_Creature->AI())->StartEvent();
break;
+ case GOSSIP_ACTION_INFO_DEF+3:
+ player->CLOSE_GOSSIP_MENU();
+ ((npc_barnesAI*)_Creature->AI())->Event = EVENT_OZ;
+ outstring_log("TSCR: player (GUID %i) manually set Opera event to EVENT_OZ",player->GetGUID());
+ break;
+ case GOSSIP_ACTION_INFO_DEF+4:
+ player->CLOSE_GOSSIP_MENU();
+ ((npc_barnesAI*)_Creature->AI())->Event = EVENT_HOOD;
+ outstring_log("TSCR: player (GUID %i) manually set Opera event to EVENT_HOOD",player->GetGUID());
+ break;
+ case GOSSIP_ACTION_INFO_DEF+5:
+ player->CLOSE_GOSSIP_MENU();
+ ((npc_barnesAI*)_Creature->AI())->Event = EVENT_RAJ;
+ outstring_log("TSCR: player (GUID %i) manually set Opera event to EVENT_RAJ",player->GetGUID());
+ break;
}
return true;
@@ -524,25 +550,25 @@ struct TRINITY_DLL_DECL npc_image_of_medivhAI : public ScriptedAI
{
case 0: return 9999999;
case 1:
- m_creature->Yell(SAY_DIALOG_MEDIVH_1,LANG_UNIVERSAL,NULL);
+ m_creature->MonsterYell(SAY_DIALOG_MEDIVH_1,LANG_UNIVERSAL,NULL);
return 10000;
case 2:
if(arca)
- ((Creature*)arca)->Yell(SAY_DIALOG_ARCANAGOS_2,LANG_UNIVERSAL,NULL);
+ ((Creature*)arca)->MonsterYell(SAY_DIALOG_ARCANAGOS_2,LANG_UNIVERSAL,NULL);
return 20000;
case 3:
- m_creature->Yell(SAY_DIALOG_MEDIVH_3,LANG_UNIVERSAL,NULL);
+ m_creature->MonsterYell(SAY_DIALOG_MEDIVH_3,LANG_UNIVERSAL,NULL);
return 10000;
case 4:
if(arca)
- ((Creature*)arca)->Yell(SAY_DIALOG_ARCANAGOS_4, LANG_UNIVERSAL, NULL);
+ ((Creature*)arca)->MonsterYell(SAY_DIALOG_ARCANAGOS_4, LANG_UNIVERSAL, NULL);
return 20000;
case 5:
- m_creature->Yell(SAY_DIALOG_MEDIVH_5, LANG_UNIVERSAL, NULL);
+ m_creature->MonsterYell(SAY_DIALOG_MEDIVH_5, LANG_UNIVERSAL, NULL);
return 20000;
case 6:
if(arca)
- ((Creature*)arca)->Yell(SAY_DIALOG_ARCANAGOS_6, LANG_UNIVERSAL, NULL);
+ ((Creature*)arca)->MonsterYell(SAY_DIALOG_ARCANAGOS_6, LANG_UNIVERSAL, NULL);
return 10000;
case 7:
FireArcanagosTimer = 500;
@@ -552,7 +578,7 @@ struct TRINITY_DLL_DECL npc_image_of_medivhAI : public ScriptedAI
DoCast(m_creature, SPELL_MANA_SHIELD);
return 10000;
case 9:
- m_creature->TextEmote(EMOTE_DIALOG_MEDIVH_7, 0, false);
+ m_creature->MonsterTextEmote(EMOTE_DIALOG_MEDIVH_7, 0, false);
return 10000;
case 10:
if(arca)
@@ -560,7 +586,7 @@ struct TRINITY_DLL_DECL npc_image_of_medivhAI : public ScriptedAI
return 1000;
case 11:
if(arca)
- ((Creature*)arca)->Yell(SAY_DIALOG_ARCANAGOS_8, LANG_UNIVERSAL, NULL);
+ ((Creature*)arca)->MonsterYell(SAY_DIALOG_ARCANAGOS_8, LANG_UNIVERSAL, NULL);
return 5000;
case 12:
arca->GetMotionMaster()->MovePoint(0, -11010.82,-1761.18, 156.47);
@@ -569,7 +595,7 @@ struct TRINITY_DLL_DECL npc_image_of_medivhAI : public ScriptedAI
arca->SetSpeed(MOVE_FLIGHT, 2.0f);
return 10000;
case 13:
- m_creature->Yell(SAY_DIALOG_MEDIVH_9, LANG_UNIVERSAL, NULL);
+ m_creature->MonsterYell(SAY_DIALOG_MEDIVH_9, LANG_UNIVERSAL, NULL);
return 10000;
case 14:
m_creature->SetVisibility(VISIBILITY_OFF);
diff --git a/src/bindings/scripts/scripts/zone/loch_modan/loch_modan.cpp b/src/bindings/scripts/scripts/zone/loch_modan/loch_modan.cpp
index d79f581d1c8..b838fc97aab 100644
--- a/src/bindings/scripts/scripts/zone/loch_modan/loch_modan.cpp
+++ b/src/bindings/scripts/scripts/zone/loch_modan/loch_modan.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/magisters_terrace/boss_felblood_kaelthas.cpp b/src/bindings/scripts/scripts/zone/magisters_terrace/boss_felblood_kaelthas.cpp
index cbc1013da17..b35b6a98642 100644
--- a/src/bindings/scripts/scripts/zone/magisters_terrace/boss_felblood_kaelthas.cpp
+++ b/src/bindings/scripts/scripts/zone/magisters_terrace/boss_felblood_kaelthas.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -6,18 +6,18 @@
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/* ScriptData
SDName: Boss_Felblood_Kaelthas
SD%Complete: 80
-SDComment: Normal and Heroic Support. Issues: Arcane Spheres do not initially follow targets. TODO: Convert Phoenix to ACID.
+SDComment: Normal and Heroic Support. Issues: Arcane Spheres do not initially follow targets.
SDCategory: Magisters' Terrace
EndScriptData */
@@ -25,7 +25,7 @@ EndScriptData */
#include "def_magisters_terrace.h"
#include "WorldPacket.h"
-#define SAY_AGGRO -1585023 //This yell should be done when the room is cleared. For now, set it as aggro yell.
+#define SAY_AGGRO -1585023 //This yell should be done when the room is cleared. For now, set it as a movelineofsight yell.
#define SAY_PHOENIX -1585024
#define SAY_FLAMESTRIKE -1585025
#define SAY_GRAVITY_LAPSE -1585026
@@ -36,13 +36,12 @@ EndScriptData */
/*** Spells ***/
// Phase 1 spells
-
#define SPELL_FIREBALL_NORMAL 44189 // Deals 2700-3300 damage at current target
#define SPELL_FIREBALL_HEROIC 46164 // 4950-6050
#define SPELL_PHOENIX 44194 // Summons a phoenix (Doesn't work?)
-#define SPELL_PHOENIX_BURN 44198 // A spell Phoenix uses to damage everything around
-#define SPELL_PHOENIX_FIREBALL 44202 // Phoenix casts this in phase 2 and stops moving
+#define SPELL_PHOENIX_BURN 44197 // A spell Phoenix uses to damage everything around
+#define SPELL_REBIRTH_DMG 44196 // DMG if a Phoenix rebirth happen
#define SPELL_FLAMESTRIKE1_NORMAL 44190 // Damage part
#define SPELL_FLAMESTRIKE1_HEROIC 46163 // Heroic damage part
@@ -53,7 +52,6 @@ EndScriptData */
#define SPELL_PYROBLAST 36819 // Heroic only; 45-55k fire damage
// Phase 2 spells
-
#define SPELL_GRAVITY_LAPSE_INITIAL 44224 // Cast at the beginning of every Gravity Lapse
#define SPELL_GRAVITY_LAPSE_CHANNEL 44251 // Channeled; blue beam animation to every enemy in range
#define SPELL_TELEPORT_CENTER 44218 // Should teleport people to the center. Requires DB entry in spell_target_position.
@@ -68,16 +66,14 @@ EndScriptData */
#define CREATURE_ARCANE_SPHERE 24708
/** Locations **/
-float KaelLocations[6][2]=
+float KaelLocations[3][2]=
{
- {148.744659, 181.377426},//center
- {140.823883, 195.403046},//phoenixpos1
- {156.574188, 195.650482},//phoenixpos2
- {149.813, 160.917},//spherepos1
- {167.223, 173.594},//spherepos2
- {130.68, 173.007},//spherepos3
+ {148.744659, 181.377426},
+ {140.823883, 195.403046},
+ {156.574188, 195.650482},
};
-#define LOCATION_Z -16.727455
+
+#define LOCATION_Z -16.727455
struct TRINITY_DLL_DECL boss_felblood_kaelthasAI : public ScriptedAI
{
@@ -106,6 +102,7 @@ struct TRINITY_DLL_DECL boss_felblood_kaelthasAI : public ScriptedAI
bool FirstGravityLapse;
bool Heroic;
+ bool HasTaunted;
uint8 Phase;
// 0 = Not started
@@ -116,7 +113,7 @@ struct TRINITY_DLL_DECL boss_felblood_kaelthasAI : public ScriptedAI
{
// TODO: Timers
FireballTimer = 0;
- PhoenixTimer = 30000;
+ PhoenixTimer = 10000;
FlameStrikeTimer = 25000;
CombatPulseTimer = 0;
@@ -126,55 +123,57 @@ struct TRINITY_DLL_DECL boss_felblood_kaelthasAI : public ScriptedAI
GravityLapsePhase = 0;
FirstGravityLapse = true;
+ HasTaunted = false;
Phase = 0;
- if(pInstance)
- {
- if(m_creature->isDead())
- pInstance->SetData(DATA_KAELTHAS_EVENT, DONE);
- else
- pInstance->SetData(DATA_KAELTHAS_EVENT, NOT_STARTED);
- }
- }
+ if (pInstance)
+ pInstance->SetData(DATA_KAELTHAS_EVENT, 0);
- void KilledUnit(Unit* victim)
- {
- if(victim && (victim->GetTypeId() == TYPEID_PLAYER))
- {
- victim->RemoveAurasDueToSpell(SPELL_GRAVITY_LAPSE_FLY);
- victim->RemoveAurasDueToSpell(SPELL_GRAVITY_LAPSE_DOT);
- WorldPacket data(12);
- data.SetOpcode(SMSG_MOVE_UNSET_CAN_FLY);
- data.append(victim->GetPackGUID());
- data << uint32(0);
- victim->SendMessageToSet(&data, true);
- }
+ GameObject* Door = GameObject::GetGameObject(*m_creature, pInstance->GetData64(DATA_KAEL_DOOR));
+ if (Door)
+ Door->SetGoState(0); // Open the big encounter door. Close it in Aggro and open it only in JustDied(and here)
+ // Small door opened after event are expected to be closed by default
}
+
void JustDied(Unit *killer)
{
- RemoveGravityLapse();
DoScriptText(SAY_DEATH, m_creature);
- if(pInstance)
- pInstance->SetData(DATA_KAELTHAS_EVENT, DONE);
+ GameObject* EncounterDoor = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_KAEL_DOOR));
+ if (EncounterDoor)
+ EncounterDoor->SetGoState(0); // Open the encounter door
}
void DamageTaken(Unit* done_by, uint32 &damage)
{
- if(damage > m_creature->GetHealth())
+ if (damage > m_creature->GetHealth())
RemoveGravityLapse(); // Remove Gravity Lapse so that players fall to ground if they kill him when in air.
}
void Aggro(Unit *who)
{
- DoScriptText(SAY_AGGRO, m_creature);
- if(pInstance)
- pInstance->SetData(DATA_KAELTHAS_EVENT, IN_PROGRESS);
+ if (pInstance)
+ {
+ GameObject* EncounterDoor = GameObject::GetGameObject(*m_creature, pInstance->GetData64(DATA_KAEL_DOOR));
+ if (EncounterDoor)
+ EncounterDoor->SetGoState(1); //Close the encounter door, open it in JustDied/Reset
+ }
+ }
+
+ void MoveInLineOfSight(Unit *who)
+ {
+ if (!HasTaunted && m_creature->IsWithinDistInMap(who, 40.0))
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ HasTaunted = true;
+ }
+
+ ScriptedAI::MoveInLineOfSight(who);
}
void SetThreatList(Creature* SummonedUnit)
{
- if(!SummonedUnit)
+ if (!SummonedUnit)
return;
std::list<HostilReference*>& m_threatlist = m_creature->getThreatManager().getThreatList();
@@ -182,114 +181,86 @@ struct TRINITY_DLL_DECL boss_felblood_kaelthasAI : public ScriptedAI
for(i = m_threatlist.begin(); i != m_threatlist.end(); i++)
{
Unit* pUnit = Unit::GetUnit((*m_creature), (*i)->getUnitGuid());
- if(pUnit && pUnit->isAlive())
+ if (pUnit && pUnit->isAlive())
{
- float threat = DoGetThreat(pUnit);
- SummonedUnit->AddThreat(pUnit, 0.1f);
+ float threat = m_creature->getThreatManager().getThreat(pUnit);
+ SummonedUnit->AddThreat(pUnit, threat);
}
}
}
- void EnterEvadeMode()
- {
- RemoveGravityLapse();
- m_creature->InterruptNonMeleeSpells(true);
- m_creature->RemoveAllAuras();
- m_creature->DeleteThreatList();
- m_creature->CombatStop();
- m_creature->LoadCreaturesAddon();
-
- if( m_creature->isAlive() )
- m_creature->GetMotionMaster()->MoveTargetedHome();
-
- m_creature->SetLootRecipient(NULL);
-
- InCombat = false;
- Reset();
- }
-
void TeleportPlayersToSelf()
{
- float x,y,z;
- m_creature->Relocate(KaelLocations[0][0], KaelLocations[0][1], LOCATION_Z, 0);
- Map *map = m_creature->GetMap();
- Map::PlayerList const &PlayerList = map->GetPlayers();
- Map::PlayerList::const_iterator i;
- for (i = PlayerList.begin(); i != PlayerList.end(); ++i)
+ float x = KaelLocations[0][0];
+ float y = KaelLocations[0][1];
+ m_creature->Relocate(x, y, LOCATION_Z, 0);
+ //m_creature->SendMonsterMove(x, y, LOCATION_Z, 0, 0, 0); // causes some issues...
+ std::list<HostilReference*>::iterator i = m_creature->getThreatManager().getThreatList().begin();
+ for (i = m_creature->getThreatManager().getThreatList().begin(); i!= m_creature->getThreatManager().getThreatList().end();++i)
{
- if (Player* i_pl = i->getSource())
- if(i_pl->isAlive())
- {
- i_pl->CastSpell(i_pl, SPELL_TELEPORT_CENTER, true);
- m_creature->GetNearPoint(m_creature,x,y,z,5,5,0);
- i_pl->TeleportTo(m_creature->GetMapId(),x,y,LOCATION_Z,i_pl->GetOrientation());
- }
+ Unit* pUnit = Unit::GetUnit((*m_creature), (*i)->getUnitGuid());
+ if (pUnit && (pUnit->GetTypeId() == TYPEID_PLAYER))
+ pUnit->CastSpell(pUnit, SPELL_TELEPORT_CENTER, true);
}
DoCast(m_creature, SPELL_TELEPORT_CENTER, true);
}
void CastGravityLapseKnockUp()
{
- Map *map = m_creature->GetMap();
- Map::PlayerList const &PlayerList = map->GetPlayers();
- Map::PlayerList::const_iterator i;
- for (i = PlayerList.begin(); i != PlayerList.end(); ++i)
+ std::list<HostilReference*>::iterator i = m_creature->getThreatManager().getThreatList().begin();
+ for (i = m_creature->getThreatManager().getThreatList().begin(); i!= m_creature->getThreatManager().getThreatList().end();++i)
{
- if (Player* i_pl = i->getSource())
- if(i_pl->isAlive())
+ Unit* pUnit = Unit::GetUnit((*m_creature), (*i)->getUnitGuid());
+ if (pUnit && (pUnit->GetTypeId() == TYPEID_PLAYER))
// Knockback into the air
- i_pl->CastSpell(i_pl, SPELL_GRAVITY_LAPSE_DOT, true, 0, 0, m_creature->GetGUID());
+ pUnit->CastSpell(pUnit, SPELL_GRAVITY_LAPSE_DOT, true, 0, 0, m_creature->GetGUID());
}
}
void CastGravityLapseFly() // Use Fly Packet hack for now as players can't cast "fly" spells unless in map 530. Has to be done a while after they get knocked into the air...
{
- Map *map = m_creature->GetMap();
- Map::PlayerList const &PlayerList = map->GetPlayers();
- Map::PlayerList::const_iterator i;
- for (i = PlayerList.begin(); i != PlayerList.end(); ++i)
+ std::list<HostilReference*>::iterator i = m_creature->getThreatManager().getThreatList().begin();
+ for (i = m_creature->getThreatManager().getThreatList().begin(); i!= m_creature->getThreatManager().getThreatList().end();++i)
{
- if (Player* i_pl = i->getSource())
+ Unit* pUnit = Unit::GetUnit((*m_creature), (*i)->getUnitGuid());
+ if (pUnit && (pUnit->GetTypeId() == TYPEID_PLAYER))
{
- if(i_pl->isAlive())
- {
- // Also needs an exception in spell system.
- i_pl->CastSpell(i_pl, SPELL_GRAVITY_LAPSE_FLY, true, 0, 0, m_creature->GetGUID());
- // Use packet hack
- WorldPacket data(12);
- data.SetOpcode(SMSG_MOVE_SET_CAN_FLY);
- data.append(i_pl->GetPackGUID());
- data << uint32(0);
- i_pl->SendMessageToSet(&data, true);
- i_pl->SetSpeed(MOVE_FLIGHT, 2.0f);
- }
+ // Also needs an exception in spell system.
+ pUnit->CastSpell(pUnit, SPELL_GRAVITY_LAPSE_FLY, true, 0, 0, m_creature->GetGUID());
+ // Use packet hack
+ WorldPacket data(12);
+ data.SetOpcode(SMSG_MOVE_SET_CAN_FLY);
+ data.append(pUnit->GetPackGUID());
+ data << uint32(0);
+ pUnit->SendMessageToSet(&data, true);
}
}
}
void RemoveGravityLapse()
{
- Map *map = m_creature->GetMap();
- Map::PlayerList const &PlayerList = map->GetPlayers();
- Map::PlayerList::const_iterator i;
- for (i = PlayerList.begin(); i != PlayerList.end(); ++i)
+ std::list<HostilReference*>::iterator i = m_creature->getThreatManager().getThreatList().begin();
+ for (i = m_creature->getThreatManager().getThreatList().begin(); i!= m_creature->getThreatManager().getThreatList().end();++i)
{
- if(Player* i_pl = i->getSource())
+ Unit* pUnit = Unit::GetUnit((*m_creature), (*i)->getUnitGuid());
+ if (pUnit && (pUnit->GetTypeId() == TYPEID_PLAYER))
{
- i_pl->RemoveAurasDueToSpell(SPELL_GRAVITY_LAPSE_FLY);
- i_pl->RemoveAurasDueToSpell(SPELL_GRAVITY_LAPSE_DOT);
+ pUnit->RemoveAurasDueToSpell(SPELL_GRAVITY_LAPSE_FLY);
+ pUnit->RemoveAurasDueToSpell(SPELL_GRAVITY_LAPSE_DOT);
+
WorldPacket data(12);
data.SetOpcode(SMSG_MOVE_UNSET_CAN_FLY);
- data.append(i_pl->GetPackGUID());
+ data.append(pUnit->GetPackGUID());
data << uint32(0);
- i_pl->SendMessageToSet(&data, true);
+ pUnit->SendMessageToSet(&data, true);
}
}
}
void UpdateAI(const uint32 diff)
{
- if(!UpdateVictim())
+ //Return since we have no target
+ if (!UpdateVictim())
return;
switch(Phase)
@@ -297,9 +268,9 @@ struct TRINITY_DLL_DECL boss_felblood_kaelthasAI : public ScriptedAI
case 0:
{
// *Heroic mode only:
- if(Heroic)
+ if (Heroic)
{
- if(PyroblastTimer < diff)
+ if (PyroblastTimer < diff)
{
DoCast(m_creature, SPELL_SHOCK_BARRIER, true);
DoCast(m_creature->getVictim(), SPELL_PYROBLAST);
@@ -307,56 +278,47 @@ struct TRINITY_DLL_DECL boss_felblood_kaelthasAI : public ScriptedAI
}else PyroblastTimer -= diff;
}
- if(FireballTimer < diff)
+ if (FireballTimer < diff)
{
DoCast(m_creature->getVictim(), Heroic ? SPELL_FIREBALL_HEROIC : SPELL_FIREBALL_NORMAL);
FireballTimer = 2000 + rand()%4000;
}else FireballTimer -= diff;
- if(PhoenixTimer < diff)
+ if (PhoenixTimer < diff)
{
+
+ Unit* target = NULL;
+ target = SelectUnit(SELECT_TARGET_RANDOM,1);
+
uint32 random = rand()%2 + 1;
float x = KaelLocations[random][0];
float y = KaelLocations[random][1];
- Creature* Phoenix = m_creature->SummonCreature(CREATURE_PHOENIX, x, y, LOCATION_Z, 0, TEMPSUMMON_CORPSE_DESPAWN, 60000);
- if(Phoenix)
+
+ Creature* Phoenix = m_creature->SummonCreature(CREATURE_PHOENIX, x, y, LOCATION_Z, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 60000);
+ if (Phoenix)
{
Phoenix->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE + UNIT_FLAG_NON_ATTACKABLE);
SetThreatList(Phoenix);
- Unit *target = SelectUnit(SELECT_TARGET_RANDOM,1);
- if(target)
- {
- Phoenix->AddThreat(target,1000);
- Phoenix->Attack(target,true);
- Phoenix->GetMotionMaster()->MoveChase(target);
- }
- else
- {
- Phoenix->AddThreat(m_creature->getVictim(),1000);
- Phoenix->Attack(m_creature->getVictim(),true);
- Phoenix->GetMotionMaster()->MoveChase(m_creature->getVictim());
- }
+ Phoenix->AI()->AttackStart(target);
}
DoScriptText(SAY_PHOENIX, m_creature);
- PhoenixTimer = 40000;
+ PhoenixTimer = 60000;
}else PhoenixTimer -= diff;
- if(FlameStrikeTimer < diff)
+ if (FlameStrikeTimer < diff)
{
if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 0))
{
- m_creature->InterruptNonMeleeSpells(false);
DoCast(target, SPELL_FLAMESTRIKE3, true);
DoScriptText(SAY_FLAMESTRIKE, m_creature);
-
- FlameStrikeTimer = 20000 + rand()%5000;
}
+ FlameStrikeTimer = 15000 + rand()%10000;
}else FlameStrikeTimer -= diff;
// Below 50%
- if(m_creature->GetMaxHealth() * 0.5 > m_creature->GetHealth())
+ if (m_creature->GetMaxHealth() * 0.5 > m_creature->GetHealth())
{
m_creature->ApplySpellImmune(0, IMMUNITY_EFFECT, SPELL_EFFECT_INTERRUPT_CAST, true);
m_creature->StopMoving();
@@ -366,34 +328,35 @@ struct TRINITY_DLL_DECL boss_felblood_kaelthasAI : public ScriptedAI
GravityLapsePhase = 0;
Phase = 1;
}
+
DoMeleeAttackIfReady();
}
break;
case 1:
{
- m_creature->StopMoving();
- if(GravityLapseTimer < diff)
+ if (GravityLapseTimer < diff)
{
switch(GravityLapsePhase)
{
case 0:
- if(FirstGravityLapse) // Different yells at 50%, and at every following Gravity Lapse
+ if (FirstGravityLapse) // Different yells at 50%, and at every following Gravity Lapse
{
DoScriptText(SAY_GRAVITY_LAPSE, m_creature);
FirstGravityLapse = false;
- if(pInstance)
+
+ if (pInstance)
{
GameObject* KaelLeft = GameObject::GetGameObject(*m_creature, pInstance->GetData64(DATA_KAEL_STATUE_LEFT));
- if(KaelLeft) KaelLeft->SetGoState(0);
+ if (KaelLeft) KaelLeft->SetGoState(0);
GameObject* KaelRight = GameObject::GetGameObject(*m_creature, pInstance->GetData64(DATA_KAEL_STATUE_RIGHT));
- if(KaelRight) KaelRight->SetGoState(0);
+ if (KaelRight) KaelRight->SetGoState(0);
}
}else
{
DoScriptText(SAY_RECAST_GRAVITY, m_creature);
}
- m_creature->StopMoving();
+
DoCast(m_creature, SPELL_GRAVITY_LAPSE_INITIAL);
GravityLapseTimer = 2000 + diff;// Don't interrupt the visual spell
GravityLapsePhase = 1;
@@ -415,31 +378,23 @@ struct TRINITY_DLL_DECL boss_felblood_kaelthasAI : public ScriptedAI
CastGravityLapseFly();
GravityLapseTimer = 30000;
GravityLapsePhase = 4;
+
+
for(uint8 i = 0; i < 3; ++i)
{
- Creature* Orb = m_creature->SummonCreature(CREATURE_ARCANE_SPHERE,KaelLocations[3+i][0],KaelLocations[3+i][1],LOCATION_Z,0,TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN,30000);
- if(Orb)
+ Unit* target = NULL;
+ target = SelectUnit(SELECT_TARGET_RANDOM,0);
+
+ Creature* Orb = DoSpawnCreature(CREATURE_ARCANE_SPHERE, 5, 5, 0, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 30000);
+ if (Orb && target)
{
- SetThreatList(Orb);
- Unit *target = SelectUnit(SELECT_TARGET_BOTTOMAGGRO,i);
- if(target)
- {
- Orb->AddThreat(target,1000);
- Orb->Attack(target,true);
- Orb->GetMotionMaster()->MoveChase(target);
- }
- else
- {
- Unit *ntarget = SelectUnit(SELECT_TARGET_RANDOM,0);
- if(ntarget)
- {
- Orb->AddThreat(ntarget,1000);
- Orb->Attack(ntarget,true);
- Orb->GetMotionMaster()->MoveChase(ntarget);
- }
- }
+ //SetThreatList(Orb);
+ Orb->AddThreat(target, 1.0f);
+ Orb->AI()->AttackStart(target);
}
+
}
+
DoCast(m_creature, SPELL_GRAVITY_LAPSE_CHANNEL);
break;
@@ -483,7 +438,7 @@ struct TRINITY_DLL_DECL mob_felkael_flamestrikeAI : public ScriptedAI
void MoveInLineOfSight(Unit *who) {}
void UpdateAI(const uint32 diff)
{
- if(FlameStrikeTimer < diff)
+ if (FlameStrikeTimer < diff)
{
DoCast(m_creature, Heroic ? SPELL_FLAMESTRIKE1_HEROIC : SPELL_FLAMESTRIKE1_NORMAL, true);
m_creature->DealDamage(m_creature, m_creature->GetMaxHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
@@ -493,211 +448,187 @@ struct TRINITY_DLL_DECL mob_felkael_flamestrikeAI : public ScriptedAI
struct TRINITY_DLL_DECL mob_felkael_phoenixAI : public ScriptedAI
{
- mob_felkael_phoenixAI(Creature *c) : ScriptedAI(c)
+ mob_felkael_phoenixAI(Creature* c) : ScriptedAI(c)
{
pInstance = ((ScriptedInstance*)c->GetInstanceData());
}
- uint32 BurnTimer;
- uint32 CheckTimer;
- uint8 phase;
+
ScriptedInstance* pInstance;
- bool end;
+ uint32 BurnTimer;
+ uint32 Death_Timer;
+ bool Rebirth;
+ bool FakeDeath;
void Reset()
{
- m_creature->SetSpeed(MOVE_RUN, 0.5f);
- m_creature->SetSpeed(MOVE_WALK, 0.5f);
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE + UNIT_FLAG_NON_ATTACKABLE);
+ m_creature->AddUnitMovementFlag(MOVEMENTFLAG_ONTRANSPORT);
+ m_creature->CastSpell(m_creature,SPELL_PHOENIX_BURN,true);
BurnTimer = 2000;
- CheckTimer = 1000;
- phase = 0;
- end = false;
+ Death_Timer = 2700;
+ Rebirth = false;
+ FakeDeath = false;
}
void Aggro(Unit* who) {}
- void JustDied(Unit* slayer)
+ void DamageTaken(Unit* pKiller, uint32 &damage)
{
- if (end)
+ if (damage < m_creature->GetHealth())
+ return;
+
+ //Prevent glitch if in fake death
+ if (FakeDeath)
+ {
+ damage = 0;
return;
- DoSpawnCreature(CREATURE_PHOENIX_EGG, 0, 0, 0, 0, TEMPSUMMON_CORPSE_DESPAWN, 45000);
+
+ }
+ //Don't really die in all phases of Kael'Thas
+ if (pInstance && pInstance->GetData(DATA_KAELTHAS_EVENT) == 0)
+ {
+ //prevent death
+ damage = 0;
+ FakeDeath = true;
+
+ m_creature->InterruptNonMeleeSpells(false);
+ m_creature->SetHealth(0);
+ m_creature->StopMoving();
+ m_creature->ClearComboPointHolders();
+ m_creature->RemoveAllAurasOnDeath();
+ m_creature->ModifyAuraState(AURA_STATE_HEALTHLESS_20_PERCENT, false);
+ m_creature->ModifyAuraState(AURA_STATE_HEALTHLESS_35_PERCENT, false);
+ m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ m_creature->ClearAllReactives();
+ m_creature->SetUInt64Value(UNIT_FIELD_TARGET,0);
+ m_creature->GetMotionMaster()->Clear();
+ m_creature->GetMotionMaster()->MoveIdle();
+ m_creature->SetStandState(UNIT_STAND_STATE_DEAD);
+
+ }
+
+ }
+
+ void JustDied(Unit* slayer)
+ {
+ DoSpawnCreature(CREATURE_PHOENIX_EGG, 0, 0, 0, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 45000);
}
void UpdateAI(const uint32 diff)
{
- if(CheckTimer < diff)
+
+ //If we are fake death, we cast revbirth and after that we kill the phoenix to spawn the egg.
+ if (FakeDeath)
{
- if (pInstance)
+ if (!Rebirth)
+ {
+ DoCast(m_creature, SPELL_REBIRTH_DMG);
+ Rebirth = true;
+ }
+
+ if (Rebirth)
{
- Creature *boss = (Unit::GetCreature((*m_creature),pInstance->GetData64(DATA_KAEL)));
- if (boss)
+
+ if (Death_Timer < diff)
{
- phase = ((boss_felblood_kaelthasAI*)boss->AI())->Phase;
- if(boss->isDead() || !boss->isInCombat())
- {
- end = true;
- m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_FIRE, NULL, false);//temphack, hellfire is not damaging self
- }
- }
+ DoSpawnCreature(CREATURE_PHOENIX_EGG, 0, 0, 0, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 45000);
+ m_creature->setDeathState(JUST_DIED);
+ m_creature->RemoveCorpse();
+ Rebirth = false;
+ }else Death_Timer -= diff;
}
- CheckTimer = 1000;
- }else CheckTimer -= diff;
+
+
+ }
if (!UpdateVictim())
return;
if (BurnTimer < diff)
{
- if(!phase)
- {
- DoCast(m_creature, SPELL_PHOENIX_BURN);
- m_creature->DealDamage(m_creature, 1500, NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_FIRE, NULL, false);//temphack, hellfire is not damaging self
- }
- else
- {
- m_creature->StopMoving();
- DoCast(m_creature->getVictim(), SPELL_PHOENIX_FIREBALL);
- }
- BurnTimer = 2000;
- }else BurnTimer -= diff;
+ //spell Burn should possible do this, but it doesn't, so do this for now.
+ uint32 dmg = urand(1650,2050);
+ m_creature->DealDamage(m_creature, dmg, 0, DOT, SPELL_SCHOOL_MASK_FIRE, NULL, false);
+ BurnTimer += 2000;
+ } BurnTimer -= diff;
- //DoMeleeAttackIfReady();
+
+ DoMeleeAttackIfReady();
}
};
-struct TRINITY_DLL_DECL mob_felkael_phoenix_eggAI : public Scripted_NoMovementAI
+struct TRINITY_DLL_DECL mob_felkael_phoenix_eggAI : public ScriptedAI
{
- mob_felkael_phoenix_eggAI(Creature *c) : Scripted_NoMovementAI(c)
- {
- pInstance = ((ScriptedInstance*)c->GetInstanceData());
- }
+ mob_felkael_phoenix_eggAI(Creature *c) : ScriptedAI(c) {}
uint32 HatchTimer;
- ScriptedInstance* pInstance;
- void Reset() { HatchTimer = 15000; }
+
+ void Reset()
+ {
+ HatchTimer = 10000;
+
+ }
void Aggro(Unit* who) {}
void MoveInLineOfSight(Unit* who) {}
+
void UpdateAI(const uint32 diff)
{
-
- if(HatchTimer < diff)
+ if (HatchTimer < diff)
{
- Creature *bird = DoSpawnCreature(CREATURE_PHOENIX, 0, 0, 0, 0, TEMPSUMMON_CORPSE_DESPAWN, 60000);
- if (bird)
- {
- Unit *boss = Unit::GetUnit((*m_creature),pInstance->GetData64(DATA_KAEL));
- if (boss && boss->getVictim())
- {
- bird->AddThreat(boss->getVictim(),100);
- bird->Attack(boss->getVictim(),true);
- bird->GetMotionMaster()->MoveChase(boss->getVictim());
- }
- }
+ DoSpawnCreature(CREATURE_PHOENIX, 0, 0, 0, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 60000);
m_creature->DealDamage(m_creature, m_creature->GetMaxHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
}else HatchTimer -= diff;
+
}
};
struct TRINITY_DLL_DECL mob_arcane_sphereAI : public ScriptedAI
{
- mob_arcane_sphereAI(Creature *c) : ScriptedAI(c)
- {
- pInstance = ((ScriptedInstance*)c->GetInstanceData());
- }
+ mob_arcane_sphereAI(Creature *c) : ScriptedAI(c) {Reset();}
+
uint32 DespawnTimer;
uint32 ChangeTargetTimer;
- uint32 CheckTimer;
-
- ScriptedInstance* pInstance;
void Reset()
{
- m_creature->SetUnitMovementFlags(MOVEMENTFLAG_LEVITATING);
DespawnTimer = 30000;
- ChangeTargetTimer = 5000;
- CheckTimer = 1000;
- m_creature->SetSpeed(MOVE_RUN, 0.5f);
- m_creature->SetSpeed(MOVE_WALK, 0.5f);
+ ChangeTargetTimer = 6000 + rand()%6000;
+
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
+ m_creature->AddUnitMovementFlag(MOVEMENTFLAG_ONTRANSPORT);
m_creature->setFaction(14);
DoCast(m_creature, SPELL_ARCANE_SPHERE_PASSIVE, true);
}
+
void Aggro(Unit* who) {}
- void StalkTarget(Unit* target)
- {
- if(!target)
- return;
- m_creature->AddThreat(target,100000);
- m_creature->GetMotionMaster()->MoveChase(target);
- m_creature->Attack(target,true);
- }
void UpdateAI(const uint32 diff)
{
- if(DespawnTimer < diff)
+ if (DespawnTimer < diff)
m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
else DespawnTimer -= diff;
- if(!UpdateVictim())
- ChangeTargetTimer = 0;
+ //Return since we have no target
+ if (!UpdateVictim())
+ return;
- if(ChangeTargetTimer < diff)
+ if (ChangeTargetTimer < diff)
{
- DoResetThreat();
- Unit *ntarget = SelectUnit(SELECT_TARGET_RANDOM,0);
- if (ntarget)
- StalkTarget(ntarget);
- ChangeTargetTimer = 10000;
- }else ChangeTargetTimer -= diff;
- if(CheckTimer < diff)
- {
- if (pInstance)
- {
- Creature *boss = Unit::GetCreature((*m_creature),pInstance->GetData64(DATA_KAEL));
- if(boss)
- {
- if(!((boss_felblood_kaelthasAI*)boss->AI())->Phase || boss->isDead())
- DespawnTimer = 0;
- }else DespawnTimer = 0;
- }
- CheckTimer = 1000;
- }else CheckTimer -= diff;
- }
-};
+ Unit* target = NULL;
+ target = SelectUnit(SELECT_TARGET_RANDOM,0);
+ if (target)
+ m_creature->AddThreat(target, 1.0f);
+ m_creature->TauntApply(target);
+ AttackStart(target);
-bool GOHello_go_kael_orb(Player *player, GameObject* _GO)
-{
- ScriptedInstance* pInst = (ScriptedInstance*)_GO->GetInstanceData();
- if (pInst && player)
- {
- Unit *kael = Unit::GetUnit((*_GO),pInst->GetData64(DATA_KAEL));
- if (kael && kael->isDead())
- player->TeleportTo(530, 12888, -6876, 9, 0.3);
- }
- return true;
-}
-
-bool GOHello_go_movie_orb(Player *player, GameObject* _GO)
-{
- if (player)
- {
- WorldPacket data(SMSG_TRIGGER_CINEMATIC, 4);
- data << (uint32)164;
- player->GetSession()->SendPacket(&data);
-
- if (player->GetQuestStatus(11490) == QUEST_STATUS_INCOMPLETE)
- {
- Unit *qUnit = player->SummonCreature(25042,player->GetPositionX(),player->GetPositionY(),player->GetPositionZ()-10,0,TEMPSUMMON_CORPSE_DESPAWN,0);
- if(qUnit)
- player->DealDamage(qUnit, qUnit->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
- }
+ ChangeTargetTimer = 5000 + rand()%10000;
+ }else ChangeTargetTimer -= diff;
}
- return true;
-}
+};
CreatureAI* GetAI_boss_felblood_kaelthas(Creature* c)
{
@@ -739,28 +670,18 @@ void AddSC_boss_felblood_kaelthas()
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="mob_felkael_phoenix";
+ newscript->Name = "mob_felkael_phoenix";
newscript->GetAI = &GetAI_mob_felkael_phoenix;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="mob_felkael_phoenix_egg";
+ newscript->Name = "mob_felkael_phoenix_egg";
newscript->GetAI = &GetAI_mob_felkael_phoenix_egg;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="mob_felkael_flamestrike";
+ newscript->Name = "mob_felkael_flamestrike";
newscript->GetAI = &GetAI_mob_felkael_flamestrike;
newscript->RegisterSelf();
-
- newscript = new Script;
- newscript->Name="go_kael_orb";
- newscript->pGOHello = &GOHello_go_kael_orb;
- newscript->RegisterSelf();
-
- newscript = new Script;
- newscript->Name="go_movie_orb";
- newscript->pGOHello = &GOHello_go_movie_orb;
- newscript->RegisterSelf();
}
diff --git a/src/bindings/scripts/scripts/zone/magisters_terrace/boss_priestess_delrissa.cpp b/src/bindings/scripts/scripts/zone/magisters_terrace/boss_priestess_delrissa.cpp
index 36ec57a4e25..e6e0caca2e8 100644
--- a/src/bindings/scripts/scripts/zone/magisters_terrace/boss_priestess_delrissa.cpp
+++ b/src/bindings/scripts/scripts/zone/magisters_terrace/boss_priestess_delrissa.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -97,8 +97,6 @@ struct TRINITY_DLL_DECL boss_priestess_delrissaAI : public ScriptedAI
boss_priestess_delrissaAI(Creature* c) : ScriptedAI(c)
{
pInstance = ((ScriptedInstance*)c->GetInstanceData());
- Adds.clear();
- //SummonAdds();
Heroic = c->GetMap()->IsHeroic();
}
@@ -122,7 +120,6 @@ struct TRINITY_DLL_DECL boss_priestess_delrissaAI : public ScriptedAI
void Reset()
{
- m_creature->SetCorpseDelay(60*60*1000);
LackeysKilled = 0;
PlayersKilled = 0;
@@ -135,15 +132,14 @@ struct TRINITY_DLL_DECL boss_priestess_delrissaAI : public ScriptedAI
CombatPulseTimer = 5000;
+ SummonAdds();
CheckAdds();
- if(pInstance)
+ if (pInstance)
{
+ pInstance->SetData(DATA_DELRISSA_EVENT, NOT_STARTED);
pInstance->SetData(DATA_DELRISSA_DEATH_COUNT, 0);
- if (m_creature->isDead())
- pInstance->SetData(DATA_DELRISSA_EVENT, DONE);
- else pInstance->SetData(DATA_DELRISSA_EVENT, NOT_STARTED);
- }else error_log(ERROR_INST_DATA);
+ } else error_log(ERROR_INST_DATA);
}
void Aggro(Unit* who)
@@ -157,8 +153,9 @@ struct TRINITY_DLL_DECL boss_priestess_delrissaAI : public ScriptedAI
void SummonAdds()
{
- /*if (m_creature->isDead())
- return;*/
+ if(!Adds.empty())
+ return;
+
std::vector<uint32> AddList;
for(uint8 i = 0; i < 8; ++i)
AddList.push_back(AddEntry[i]);
@@ -169,7 +166,7 @@ struct TRINITY_DLL_DECL boss_priestess_delrissaAI : public ScriptedAI
for(uint8 i = 0; i < AddList.size(); ++i)
{
Creature* pAdd = m_creature->SummonCreature(AddList[i], LackeyLocations[i][0], LackeyLocations[i][1], POS_Z, ORIENT, TEMPSUMMON_DEAD_DESPAWN, 0);
- if(pAdd)
+ if (pAdd)
{
Add* nAdd = new Add(AddList[i], pAdd->GetGUID());
Adds.push_back(nAdd);
@@ -179,51 +176,45 @@ struct TRINITY_DLL_DECL boss_priestess_delrissaAI : public ScriptedAI
void CheckAdds()
{
- //if (m_creature->isDead())
- // return;
- if(Adds.empty())
- {
- SummonAdds();
+ if (Adds.empty())
return;
- }
- for(uint8 i = 0; i < Adds.size(); ++i)
+
+ uint32 n = 0;
+ for(std::vector<Add*>::iterator i = Adds.begin(); i != Adds.end(); ++i, ++n)
{
- Creature* pAdd = (Unit::GetCreature(*m_creature, Adds[i]->guid));
+ Creature* pAdd = (Unit::GetCreature(*m_creature, (*i)->guid));
if(pAdd && pAdd->isAlive())
{
- pAdd->AI()->EnterEvadeMode();
- pAdd->GetMotionMaster()->MovePoint(0,LackeyLocations[i][0], LackeyLocations[i][1], POS_Z);
+ pAdd->AI()->EnterEvadeMode(); // Force them out of combat and reset if they are in combat.
}
- if(!pAdd || (pAdd && pAdd->isDead()))
+ else
{
+ pAdd = m_creature->SummonCreature((*i)->entry, LackeyLocations[n][0], LackeyLocations[n][1], POS_Z, ORIENT, TEMPSUMMON_DEAD_DESPAWN, 0);
if(pAdd)
- pAdd->RemoveCorpse();//looks stupid if mob is alive but has a dead corpse in front of him :)
- Creature* pAdd = m_creature->SummonCreature(Adds[i]->entry, LackeyLocations[i][0], LackeyLocations[i][1], POS_Z, ORIENT, TEMPSUMMON_DEAD_DESPAWN, 0);
- if(pAdd)
- Adds[i]->guid = pAdd->GetGUID();
+ (*i)->guid = pAdd->GetGUID();
+ else
+ (*i)->guid = 0;
}
}
}
void KilledUnit(Unit* victim)
{
- if(victim->GetTypeId() != TYPEID_PLAYER || m_creature->isDead())
+ if (victim->GetTypeId() != TYPEID_PLAYER)
return;
DoScriptText(PlayerDeath[PlayersKilled].id, m_creature);
- if( PlayersKilled < 4 )
+
+ if (PlayersKilled < 4)
++PlayersKilled;
}
void KilledLackey()
{
- if(m_creature->isDead())//no sense to talk if dead..
- return;
DoScriptText(LackeyDeath[LackeysKilled].id, m_creature);
- if( LackeysKilled < 3 )
- ++LackeysKilled;
- CheckLootable();
+ if (LackeysKilled < 3)
+ ++LackeysKilled;
}
void JustDied(Unit* killer)
@@ -232,21 +223,21 @@ struct TRINITY_DLL_DECL boss_priestess_delrissaAI : public ScriptedAI
CheckLootable();
- if(!pInstance)
+ if (!pInstance)
{
error_log(ERROR_INST_DATA);
return;
}
- pInstance->SetData(DATA_DELRISSA_DEATH_COUNT, 1);
pInstance->SetData(DATA_DELRISSA_EVENT, DONE);
- if(GameObject* Door = GameObject::GetGameObject(*m_creature, pInstance->GetData64(DATA_DELRISSA_DOOR)))
+
+ if (GameObject* Door = GameObject::GetGameObject(*m_creature, pInstance->GetData64(DATA_DELRISSA_DOOR)))
Door->SetGoState(0);
}
void CheckLootable()
{
- if(pInstance && pInstance->GetData(DATA_DELRISSA_DEATH_COUNT) >= 4)
+ if (LackeysKilled > 3)
m_creature->SetFlag(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_LOOTABLE);
else
m_creature->RemoveFlag(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_LOOTABLE);
@@ -254,7 +245,7 @@ struct TRINITY_DLL_DECL boss_priestess_delrissaAI : public ScriptedAI
void UpdateAI(const uint32 diff)
{
- if(!UpdateVictim())
+ if (!UpdateVictim())
return;
if(ResetTimer < diff)
@@ -269,27 +260,27 @@ struct TRINITY_DLL_DECL boss_priestess_delrissaAI : public ScriptedAI
ResetTimer = 5000;
}else ResetTimer -= diff;
- if(HealTimer < diff)
+ if (HealTimer < diff)
{
uint32 health = m_creature->GetHealth();
Unit* target = m_creature;
for(uint8 i = 0; i < Adds.size(); ++i)
- if(Unit* pAdd = Unit::GetUnit(*m_creature, Adds[i]->guid))
- if(pAdd->isAlive() && pAdd->GetHealth() < health)
+ if (Unit* pAdd = Unit::GetUnit(*m_creature, Adds[i]->guid))
+ if (pAdd->isAlive() && pAdd->GetHealth() < health)
target = pAdd;
DoCast(target, SPELL_FLASH_HEAL);
HealTimer = 15000;
}else HealTimer -= diff;
- if(RenewTimer < diff)
+ if (RenewTimer < diff)
{
Unit* target = m_creature;
- if(rand()%2 == 1)
+ if (rand()%2 == 1)
{
std::vector<Add*>::iterator itr = Adds.begin() + rand()%Adds.size();
Unit* pAdd = Unit::GetUnit(*m_creature, (*itr)->guid);
- if(pAdd && pAdd->isAlive())
+ if (pAdd && pAdd->isAlive())
target = pAdd;
}
DoCast(target,Heroic ? SPELL_RENEW_HEROIC : SPELL_RENEW_NORMAL);
@@ -299,44 +290,44 @@ struct TRINITY_DLL_DECL boss_priestess_delrissaAI : public ScriptedAI
if(ShieldTimer < diff)
{
Unit* target = m_creature;
- if(rand()%2 == 1)
+ if (rand()%2 == 1)
{
std::vector<Add*>::iterator itr = Adds.begin() + rand()%Adds.size();
- if(Unit* pAdd = Unit::GetUnit(*m_creature, (*itr)->guid))
- if(!pAdd->HasAura(SPELL_SHIELD, 0) && pAdd->isAlive())
+ if (Unit* pAdd = Unit::GetUnit(*m_creature, (*itr)->guid))
+ if (!pAdd->HasAura(SPELL_SHIELD) && pAdd->isAlive())
target = pAdd;
}
DoCast(target, SPELL_SHIELD);
ShieldTimer = 7500;
}else ShieldTimer -= diff;
- if(DispelTimer < diff)
+ if (DispelTimer < diff)
{
Unit* target = NULL;
bool friendly = false;
- if(rand()%2 == 1)
+ if (rand()%2 == 1)
target = SelectUnit(SELECT_TARGET_RANDOM, 0);
else
{
friendly = true;
- if(rand()%2 == 1)
+ if (rand()%2 == 1)
target = m_creature;
else
{
std::vector<Add*>::iterator itr = Adds.begin() + rand()%Adds.size();
Unit* pAdd = Unit::GetUnit(*m_creature, (*itr)->guid);
- if(pAdd && pAdd->isAlive())
+ if (pAdd && pAdd->isAlive())
target = pAdd;
}
}
- if(target)
+ if (target)
{
DoCast(target, SPELL_DISPEL_MAGIC);
DispelTimer = 12000;
}
}else DispelTimer -= diff;
- if(SWPainTimer < diff)
+ if (SWPainTimer < diff)
{
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0),Heroic ? SPELL_SW_PAIN_HEROIC : SPELL_SW_PAIN_NORMAL);
SWPainTimer = 10000;
@@ -382,12 +373,7 @@ struct TRINITY_DLL_DECL boss_priestess_guestAI : public ScriptedAI
void Reset()
{
UsedPotion = false;
- if(pInstance)
- {
- Creature *boss = (Unit::GetCreature(*m_creature, pInstance->GetData64(DATA_DELRISSA)));
- if (boss && boss->isDead())
- boss->Respawn();
- }
+
ResetThreatTimer = 5000 + rand()%15000; // These guys like to switch targets often, and are not meant to be tanked.
}
@@ -395,46 +381,47 @@ struct TRINITY_DLL_DECL boss_priestess_guestAI : public ScriptedAI
void JustDied(Unit* killer)
{
- if(!pInstance)
+ if (!pInstance)
{
error_log(ERROR_INST_DATA);
return;
}
Creature* Delrissa = (Unit::GetCreature(*m_creature, pInstance->GetData64(DATA_DELRISSA)));
- if(Delrissa)
+ if (Delrissa)
{
+ pInstance->SetData(DATA_DELRISSA_DEATH_COUNT, 1);
+
((boss_priestess_delrissaAI*)Delrissa->AI())->KilledLackey();
- if(!Delrissa->isAlive() && pInstance->GetData(DATA_DELRISSA_DEATH_COUNT) > 3)
- ((boss_priestess_delrissaAI*)Delrissa->AI())->CheckLootable();
- pInstance->SetData(DATA_DELRISSA_DEATH_COUNT, 1);
+ if (!Delrissa->isAlive() && pInstance->GetData(DATA_DELRISSA_DEATH_COUNT) > 3)
+ Delrissa->SetFlag(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_LOOTABLE);
}
}
void KilledUnit(Unit* victim)
{
- if(!pInstance)
+ if (!pInstance)
{
error_log(ERROR_INST_DATA);
return;
}
Creature* Delrissa = (Unit::GetCreature(*m_creature, pInstance->GetData64(DATA_DELRISSA)));
- if(Delrissa)
+ if (Delrissa)
Delrissa->AI()->KilledUnit(victim);
}
void AcquireGUIDs()
{
- if(!pInstance)
+ if (!pInstance)
{
error_log(ERROR_INST_DATA);
return;
}
Creature* Delrissa = (Unit::GetCreature(*m_creature, pInstance->GetData64(DATA_DELRISSA)));
- if(Delrissa)
+ if (Delrissa)
{
Group = ((boss_priestess_delrissaAI*)Delrissa->AI())->Adds;
Add* dAdd = new Add(Delrissa->GetEntry(), Delrissa->GetGUID());
@@ -444,13 +431,13 @@ struct TRINITY_DLL_DECL boss_priestess_guestAI : public ScriptedAI
void UpdateAI(const uint32 diff)
{
- if(((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 25) && !UsedPotion)
+ if (((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 25) && !UsedPotion)
{
DoCast(m_creature, SPELL_HEALING_POTION, true);
UsedPotion = true;
}
- if(ResetThreatTimer < diff)
+ if (ResetThreatTimer < diff)
{
DoResetThreat();
ResetThreatTimer = 5000 + rand()%15000;
@@ -492,12 +479,12 @@ struct TRINITY_DLL_DECL boss_kagani_nightstrikeAI : public boss_priestess_guestA
void UpdateAI(const uint32 diff)
{
- if(!UpdateVictim() )
+ if (!UpdateVictim())
return;
boss_priestess_guestAI::UpdateAI(diff);
- if(Vanish_Timer < diff)
+ if (Vanish_Timer < diff)
{
m_creature->SetVisibility(VISIBILITY_OFF); // ...? Hacklike
DoCast(m_creature, SPELL_VANISH);
@@ -508,35 +495,36 @@ struct TRINITY_DLL_DECL boss_kagani_nightstrikeAI : public boss_priestess_guestA
m_creature->AddThreat(SelectUnit(SELECT_TARGET_RANDOM, 0), 1000.0f);
}else Vanish_Timer -= diff;
- if(InVanish)
- if(Wait_Timer < diff)
+ if (InVanish)
{
- DoCast(m_creature->getVictim(), SPELL_BACKSTAB, true);
- DoCast(m_creature->getVictim(), SPELL_KIDNEY_SHOT, true);
- m_creature->SetVisibility(VISIBILITY_ON); // ...? Hacklike
- InVanish = false;
- }else Wait_Timer -= diff;
+ if (Wait_Timer < diff)
+ {
+ DoCast(m_creature->getVictim(), SPELL_BACKSTAB, true);
+ DoCast(m_creature->getVictim(), SPELL_KIDNEY_SHOT, true);
+ m_creature->SetVisibility(VISIBILITY_ON); // ...? Hacklike
+ InVanish = false;
+ }else Wait_Timer -= diff;
+ }
- if(Gouge_Timer < diff)
+ if (Gouge_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_GOUGE);
- DoModifyThreatPercent(m_creature->getVictim(),-100);
Gouge_Timer = 5500;
}else Gouge_Timer -= diff;
- if(Kick_Timer < diff)
+ if (Kick_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_KICK);
Kick_Timer = 7000;
}else Kick_Timer -= diff;
- if(Eviscerate_Timer < diff)
+ if (Eviscerate_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_EVISCERATE);
Eviscerate_Timer = 4000;
}else Eviscerate_Timer -= diff;
- if(!InVanish)
+ if (!InVanish)
DoMeleeAttackIfReady();
}
};
@@ -568,7 +556,8 @@ struct TRINITY_DLL_DECL boss_kagani_nightstrikeAI : public boss_priestess_guestA
void UpdateAI(const uint32 diff)
{
- if (!UpdateVictim() )
+ //Return since we have no target
+ if (!UpdateVictim())
return;
//Chain cast
@@ -581,9 +570,7 @@ struct TRINITY_DLL_DECL boss_kagani_nightstrikeAI : public boss_priestess_guestA
struct TRINITY_DLL_DECL boss_ellris_duskhallowAI : public boss_priestess_guestAI
{
//Warlock
- boss_ellris_duskhallowAI(Creature *c) : boss_priestess_guestAI(c)
- {
- }
+ boss_ellris_duskhallowAI(Creature *c) : boss_priestess_guestAI(c) {}
bool HasSummonedImp;
@@ -595,7 +582,7 @@ struct TRINITY_DLL_DECL boss_ellris_duskhallowAI : public boss_priestess_guestAI
void Reset()
{
- //HasSummonedImp = false;
+ HasSummonedImp = false;
Immolate_Timer = 6000;
Shadow_Bolt_Timer = 3000;
@@ -613,51 +600,49 @@ struct TRINITY_DLL_DECL boss_ellris_duskhallowAI : public boss_priestess_guestAI
void UpdateAI(const uint32 diff)
{
- if(!HasSummonedImp)
+ if (!HasSummonedImp)
{
//Imp will not despawn unless it's killed, even if owner dies, this is correct way.
DoCast(m_creature,SPELL_SUMMON_IMP);
HasSummonedImp = true;
}
- if(!UpdateVictim() )
+ if (!UpdateVictim())
return;
boss_priestess_guestAI::UpdateAI(diff);
- if(Immolate_Timer < diff)
+ if (Immolate_Timer < diff)
{
DoCast(m_creature->getVictim(),SPELL_IMMOLATE);
Immolate_Timer = 6000;
}else Immolate_Timer -= diff;
- if(Shadow_Bolt_Timer < diff)
+ if (Shadow_Bolt_Timer < diff)
{
DoCast(m_creature->getVictim(),SPELL_SHADOW_BOLT);
Shadow_Bolt_Timer = 5000;
}else Shadow_Bolt_Timer -= diff;
- if(Seed_of_Corruption_Timer < diff)
+ if (Seed_of_Corruption_Timer < diff)
{
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_SEED_OF_CORRUPTION);
Seed_of_Corruption_Timer = 10000;
}else Seed_of_Corruption_Timer -= diff;
- if(Curse_of_Agony_Timer < diff)
+ if (Curse_of_Agony_Timer < diff)
{
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_CURSE_OF_AGONY);
Curse_of_Agony_Timer = 13000;
}else Curse_of_Agony_Timer -= diff;
- if(Fear_Timer < diff)
+ if (Fear_Timer < diff)
{
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_FEAR);
Fear_Timer = 10000;
}else Fear_Timer -= diff;
- if (m_creature->GetDistance(m_creature->getVictim()) <= 10)
- m_creature->StopMoving();
- //DoMeleeAttackIfReady();//should not melee, she's a warlock
+ DoMeleeAttackIfReady();
}
};
@@ -694,18 +679,18 @@ struct TRINITY_DLL_DECL boss_eramas_brightblazeAI : public boss_priestess_guestA
void UpdateAI(const uint32 diff)
{
- if(!UpdateVictim() )
+ if (!UpdateVictim())
return;
boss_priestess_guestAI::UpdateAI(diff);
- if(Knockdown_Timer < diff)
+ if (Knockdown_Timer < diff)
{
DoCast(m_creature->getVictim(),SPELL_KNOCKDOWN);
Knockdown_Timer = 6000;
}else Knockdown_Timer -= diff;
- if(Snap_Kick_Timer < diff)
+ if (Snap_Kick_Timer < diff)
{
DoCast(m_creature->getVictim(),SPELL_SNAP_KICK);
Snap_Kick_Timer = 4500;
@@ -726,7 +711,7 @@ struct TRINITY_DLL_DECL boss_eramas_brightblazeAI : public boss_priestess_guestA
struct TRINITY_DLL_DECL boss_yazzaiAI : public boss_priestess_guestAI
{
//Mage
- boss_yazzaiAI(Creature *c) : boss_priestess_guestAI(c) {}
+ boss_yazzaiAI(Creature *c) : boss_priestess_guestAI(c) {}
bool HasIceBlocked;
@@ -757,82 +742,75 @@ struct TRINITY_DLL_DECL boss_yazzaiAI : public boss_priestess_guestAI
void UpdateAI(const uint32 diff)
{
- if(!UpdateVictim() )
+ if (!UpdateVictim())
return;
boss_priestess_guestAI::UpdateAI(diff);
- if(Polymorph_Timer < diff)
+ if (Polymorph_Timer < diff)
{
if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 0))
{
DoCast(target, SPELL_POLYMORPH);
- DoModifyThreatPercent(target,-100);
Polymorph_Timer = 20000;
}
}else Polymorph_Timer -= diff;
- if(((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 35) && !HasIceBlocked)
+ if (((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 35) && !HasIceBlocked)
{
DoCast(m_creature, SPELL_ICE_BLOCK);
HasIceBlocked = true;
}
- if(Blizzard_Timer < diff)
+ if (Blizzard_Timer < diff)
{
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_BLIZZARD);
Blizzard_Timer = 8000;
}else Blizzard_Timer -= diff;
- if(Ice_Lance_Timer < diff)
+ if (Ice_Lance_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_ICE_LANCE);
Ice_Lance_Timer = 12000;
}else Ice_Lance_Timer -= diff;
- if(Cone_of_Cold_Timer < diff)
+ if (Cone_of_Cold_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_CONE_OF_COLD);
Cone_of_Cold_Timer = 10000;
}else Cone_of_Cold_Timer -= diff;
- if(Frostbolt_Timer < diff)
+ if (Frostbolt_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_FROSTBOLT);
Frostbolt_Timer = 8000;
}else Frostbolt_Timer -= diff;
- if(Blink_Timer < diff)
+ if (Blink_Timer < diff)
{
bool InMeleeRange = false;
std::list<HostilReference*>& t_list = m_creature->getThreatManager().getThreatList();
for(std::list<HostilReference*>::iterator itr = t_list.begin(); itr!= t_list.end(); ++itr)
{
- if(Unit* target = Unit::GetUnit(*m_creature, (*itr)->getUnitGuid()))
+ if (Unit* target = Unit::GetUnit(*m_creature, (*itr)->getUnitGuid()))
+ {
//if in melee range
if (target->IsWithinDistInMap(m_creature, 5))
{
InMeleeRange = true;
break;
}
+ }
}
+
//if anybody is in melee range than escape by blink
- if(InMeleeRange)
- {
- //DoCast(m_creature, SPELL_BLINK); //blink does not work on npcs
- float x,y,z;
- m_creature->GetPosition(x,y,z);
- x = rand()%2 ? x+10+rand()%10 : x-10-rand()%10;
- y = rand()%2 ? y+10+rand()%10 : y-10-rand()%10;
- DoTeleportTo(x, y, z);
- }
+ if (InMeleeRange)
+ DoCast(m_creature, SPELL_BLINK);
+
Blink_Timer = 8000;
}else Blink_Timer -= diff;
- if (m_creature->getVictim() && m_creature->GetDistance(m_creature->getVictim()) <= 10)
- m_creature->StopMoving();
-
- //DoMeleeAttackIfReady(); //mage type, no melee needed
+ DoMeleeAttackIfReady();
}
};
@@ -865,6 +843,7 @@ struct TRINITY_DLL_DECL boss_warlord_salarisAI : public boss_priestess_guestAI
Hamstring_Timer = 4500;
Mortal_Strike_Timer = 8000;
DoCast(m_creature, SPELL_BATTLE_SHOUT);
+
boss_priestess_guestAI::Reset();
}
@@ -875,56 +854,60 @@ struct TRINITY_DLL_DECL boss_warlord_salarisAI : public boss_priestess_guestAI
void UpdateAI(const uint32 diff)
{
- if(!UpdateVictim() )
+ if (!UpdateVictim())
return;
boss_priestess_guestAI::UpdateAI(diff);
- if(Intercept_Stun_Timer < diff)
+ if (Intercept_Stun_Timer < diff)
{
bool InMeleeRange = false;
std::list<HostilReference*>& t_list = m_creature->getThreatManager().getThreatList();
for(std::list<HostilReference*>::iterator itr = t_list.begin(); itr!= t_list.end(); ++itr)
{
- if(Unit* target = Unit::GetUnit(*m_creature, (*itr)->getUnitGuid()))
- //if in melee range
- if (target->IsWithinDistInMap(m_creature, 5))
+ if (Unit* target = Unit::GetUnit(*m_creature, (*itr)->getUnitGuid()))
{
- InMeleeRange = true;
- break;
+ //if in melee range
+ if (target->IsWithinDistInMap(m_creature, 5))
+ {
+ InMeleeRange = true;
+ break;
+ }
}
}
+
//if nobody is in melee range than try to use Intercept
- if(!InMeleeRange)
+ if (!InMeleeRange)
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_INTERCEPT_STUN);
+
Intercept_Stun_Timer = 10000;
}else Intercept_Stun_Timer -= diff;
- if(Disarm_Timer < diff)
+ if (Disarm_Timer < diff)
{
DoCast(m_creature->getVictim(),SPELL_DISARM);
Disarm_Timer = 6000;
}else Disarm_Timer -= diff;
- if(Hamstring_Timer < diff)
+ if (Hamstring_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_HAMSTRING);
Hamstring_Timer = 4500;
}else Hamstring_Timer -= diff;
- if(Mortal_Strike_Timer < diff)
+ if (Mortal_Strike_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_MORTAL_STRIKE);
Mortal_Strike_Timer = 4500;
}else Mortal_Strike_Timer -= diff;
- if(Piercing_Howl_Timer < diff)
+ if (Piercing_Howl_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_PIERCING_HOWL);
Piercing_Howl_Timer = 10000;
}else Piercing_Howl_Timer -= diff;
- if(Frightening_Shout_Timer < diff)
+ if (Frightening_Shout_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_FRIGHTENING_SHOUT);
Frightening_Shout_Timer = 18000;
@@ -973,13 +956,11 @@ struct TRINITY_DLL_DECL boss_garaxxasAI : public boss_priestess_guestAI
uint32 Multi_Shot_Timer;
uint32 Wing_Clip_Timer;
uint32 Freezing_Trap_Timer;
- uint32 StopMoving;
- bool Stopped;
void Reset()
{
//SliverGUID = 0;
- //HasSummonedSliver = false;
+ HasSummonedSliver = false;
Aimed_Shot_Timer = 6000;
Shoot_Timer = 2500;
@@ -987,8 +968,6 @@ struct TRINITY_DLL_DECL boss_garaxxasAI : public boss_priestess_guestAI
Multi_Shot_Timer = 10000;
Wing_Clip_Timer = 4000;
Freezing_Trap_Timer = 15000;
- StopMoving = 2000;
- Stopped = false;
boss_priestess_guestAI::Reset();
}
@@ -1000,10 +979,10 @@ struct TRINITY_DLL_DECL boss_garaxxasAI : public boss_priestess_guestAI
void UpdateAI(const uint32 diff)
{
- if(!HasSummonedSliver)
+ if (!HasSummonedSliver)
{
Creature* Sliver = m_creature->SummonCreature(CREATURE_SLIVER, 0, 0, 0, 0, TEMPSUMMON_CORPSE_DESPAWN, 0);
- if(Sliver)
+ if (Sliver)
{
//((mob_sliverAI*)Sliver->AI())->GaraxxasGUID = m_creature->GetGUID();
//SliverGUID = Sliver->GetGUID();
@@ -1011,64 +990,53 @@ struct TRINITY_DLL_DECL boss_garaxxasAI : public boss_priestess_guestAI
}
}
- if(!UpdateVictim() )
+ if (!UpdateVictim())
return;
boss_priestess_guestAI::UpdateAI(diff);
- if(m_creature->IsWithinDistInMap(m_creature->getVictim(), 5))
+ if (m_creature->IsWithinDistInMap(m_creature->getVictim(), 5.0f))
{
- if(Wing_Clip_Timer < diff)
+ if (Wing_Clip_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_WING_CLIP);
Wing_Clip_Timer = 4000;
}else Wing_Clip_Timer -= diff;
- if(Freezing_Trap_Timer < diff)
+ if (Freezing_Trap_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_FREEZING_TRAP);
- DoModifyThreatPercent(m_creature->getVictim(),-100);
Freezing_Trap_Timer = 30000;
}else Freezing_Trap_Timer -= diff;
- if(!m_creature->getVictim()->hasUnitState(UNIT_STAT_STUNNED | UNIT_STAT_ROOT | UNIT_STAT_CONFUSED | UNIT_STAT_DISTRACTED))
- DoMeleeAttackIfReady();
- }else
+ DoMeleeAttackIfReady();
+ }
+ else
{
- if(Concussive_Shot_Timer < diff)
+ if (Concussive_Shot_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_CONCUSSIVE_SHOT);
Concussive_Shot_Timer = 8000;
}else Concussive_Shot_Timer -= diff;
- if(Multi_Shot_Timer < diff)
+ if (Multi_Shot_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_MULTI_SHOT);
Multi_Shot_Timer = 10000;
}else Multi_Shot_Timer -= diff;
- if(Aimed_Shot_Timer < diff)
+ if (Aimed_Shot_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_AIMED_SHOT);
Aimed_Shot_Timer = 6000;
}else Aimed_Shot_Timer -= diff;
- if(Shoot_Timer < diff)
+ if (Shoot_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_SHOOT);
Shoot_Timer = 2500;
}else Shoot_Timer -= diff;
}
- if(StopMoving < diff)
- {
- if(Stopped)
- Stopped = false;
- else
- Stopped = true;
- StopMoving = 2000+rand()%5000;
- }else StopMoving -= diff;
- if (Stopped)
- m_creature->StopMoving();
}
};
@@ -1118,12 +1086,12 @@ struct TRINITY_DLL_DECL boss_apokoAI : public boss_priestess_guestAI
void UpdateAI(const uint32 diff)
{
- if(!UpdateVictim() )
+ if (!UpdateVictim())
return;
boss_priestess_guestAI::UpdateAI(diff);
- if(Totem_Timer < diff)
+ if (Totem_Timer < diff)
{
switch(rand()%3)
{
@@ -1135,25 +1103,25 @@ struct TRINITY_DLL_DECL boss_apokoAI : public boss_priestess_guestAI
Totem_Timer = Totem_Amount*2000;
}else Totem_Timer -= diff;
- if(War_Stomp_Timer < diff)
+ if (War_Stomp_Timer < diff)
{
DoCast(m_creature, SPELL_WAR_STOMP);
War_Stomp_Timer = 10000;
}else War_Stomp_Timer -= diff;
- if(Purge_Timer < diff)
+ if (Purge_Timer < diff)
{
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_PURGE);
Purge_Timer = 15000;
}else Purge_Timer -= diff;
- if(Frost_Shock_Timer < diff)
+ if (Frost_Shock_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_FROST_SHOCK);
Frost_Shock_Timer = 7000;
}else Frost_Shock_Timer -= diff;
- if(Healing_Wave_Timer < diff)
+ if (Healing_Wave_Timer < diff)
{
// std::vector<Add*>::iterator itr = Group.begin() + rand()%Group.size();
// uint64 guid = (*itr)->guid;
@@ -1205,44 +1173,45 @@ struct TRINITY_DLL_DECL boss_zelfanAI : public boss_priestess_guestAI
void UpdateAI(const uint32 diff)
{
- if(!UpdateVictim() )
+ if (!UpdateVictim())
return;
boss_priestess_guestAI::UpdateAI(diff);
- if(Goblin_Dragon_Gun_Timer < diff)
+ if (Goblin_Dragon_Gun_Timer < diff)
{
- if (m_creature->GetDistance(m_creature->getVictim()) <= 5)
- {
- Goblin_Dragon_Gun_Timer = 10000;
- DoCast(m_creature->getVictim(), SPELL_GOBLIN_DRAGON_GUN);
- }else Goblin_Dragon_Gun_Timer = 2000;
+ DoCast(m_creature->getVictim(), SPELL_GOBLIN_DRAGON_GUN);
+ Goblin_Dragon_Gun_Timer = 10000;
}else Goblin_Dragon_Gun_Timer -= diff;
- if(Rocket_Launch_Timer < diff)
+ if (Rocket_Launch_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_ROCKET_LAUNCH);
Rocket_Launch_Timer = 9000;
}else Rocket_Launch_Timer -= diff;
- if(Fel_Iron_Bomb_Timer < diff)
+ if (Fel_Iron_Bomb_Timer < diff)
{
DoCast(m_creature->getVictim(), SPELL_FEL_IRON_BOMB);
Fel_Iron_Bomb_Timer = 15000;
}else Fel_Iron_Bomb_Timer -= diff;
- if(Recombobulate_Timer < diff)
+ if (Recombobulate_Timer < diff)
{
for(uint8 i = 0; i < Group.size(); ++i)
- if(Unit* pAdd = Unit::GetUnit(*m_creature, Group[i]->guid))
- if(pAdd->IsPolymorphed())
+ {
+ if (Unit* pAdd = Unit::GetUnit(*m_creature, Group[i]->guid))
+ {
+ if (pAdd->IsPolymorphed())
{
DoCast(pAdd, SPELL_RECOMBOBULATE);
break;
}
+ }
+ }
}else Recombobulate_Timer -= diff;
- if(High_Explosive_Sheep_Timer < diff)
+ if (High_Explosive_Sheep_Timer < diff)
{
DoCast(m_creature, SPELL_HIGH_EXPLOSIVE_SHEEP);
High_Explosive_Sheep_Timer = 65000;
@@ -1342,62 +1311,62 @@ void AddSC_boss_priestess_delrissa()
Script *newscript;
newscript = new Script;
- newscript->Name="boss_priestess_delrissa";
+ newscript->Name = "boss_priestess_delrissa";
newscript->GetAI = &GetAI_boss_priestess_delrissa;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="boss_kagani_nightstrike";
+ newscript->Name = "boss_kagani_nightstrike";
newscript->GetAI = &GetAI_boss_kagani_nightstrike;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="boss_ellris_duskhallow";
+ newscript->Name = "boss_ellris_duskhallow";
newscript->GetAI = &GetAI_ellris_duskhallow;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="boss_eramas_brightblaze";
+ newscript->Name = "boss_eramas_brightblaze";
newscript->GetAI = &GetAI_eramas_brightblaze;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="boss_yazzai";
+ newscript->Name = "boss_yazzai";
newscript->GetAI = &GetAI_yazzai;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="boss_warlord_salaris";
+ newscript->Name = "boss_warlord_salaris";
newscript->GetAI = &GetAI_warlord_salaris;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="boss_garaxxas";
+ newscript->Name = "boss_garaxxas";
newscript->GetAI = &GetAI_garaxxas;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="boss_apoko";
+ newscript->Name = "boss_apoko";
newscript->GetAI = &GetAI_apoko;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="boss_zelfan";
+ newscript->Name = "boss_zelfan";
newscript->GetAI = &GetAI_zelfan;
newscript->RegisterSelf();
/*newscript = new Script;
- newscript->Name="mob_high_explosive_sheep";
+ newscript->Name = "mob_high_explosive_sheep";
newscript->GetAI = &GetAI_mob_high_explosive_sheep;
newscript->RegisterSelf();*/
/*newscript = new Script;
- newscript->Name="mob_fizzle";
+ newscript->Name = "mob_fizzle";
newscript->GetAI = &GetAI_mob_fizzle;
newscript->RegisterSelf();*/
/*newscript = new Script;
- newscript->Name="mob_sliver";
+ newscript->Name = "mob_sliver";
newscript->GetAI = &GetAI_mob_sliver;
newscript->RegisterSelf();*/
}
diff --git a/src/bindings/scripts/scripts/zone/magisters_terrace/boss_selin_fireheart.cpp b/src/bindings/scripts/scripts/zone/magisters_terrace/boss_selin_fireheart.cpp
index b056e2329e4..c18128bbe1a 100644
--- a/src/bindings/scripts/scripts/zone/magisters_terrace/boss_selin_fireheart.cpp
+++ b/src/bindings/scripts/scripts/zone/magisters_terrace/boss_selin_fireheart.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -6,12 +6,12 @@
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/* ScriptData
@@ -32,7 +32,7 @@ EndScriptData */
#define SAY_DEATH -1585005
#define EMOTE_CRYSTAL -1585006
-//Crystal efect spells
+//Crystal effect spells
#define SPELL_FEL_CRYSTAL_COSMETIC 44374
#define SPELL_FEL_CRYSTAL_DUMMY 44329
#define SPELL_FEL_CRYSTAL_VISUAL 44355
@@ -56,8 +56,8 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
pInstance = ((ScriptedInstance*)c->GetInstanceData());
Crystals.clear();
- // GUIDs per instance is static, so we only need to load them once.
- if(pInstance)
+ //GUIDs per instance is static, so we only need to load them once.
+ if (pInstance)
{
uint32 size = pInstance->GetData(DATA_FEL_CRYSTAL_SIZE);
for(uint8 i = 0; i < size; ++i)
@@ -71,6 +71,7 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
}
ScriptedInstance* pInstance;
+ bool Heroic;
std::list<uint64> Crystals;
@@ -78,23 +79,23 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
uint32 DrainManaTimer;
uint32 FelExplosionTimer;
uint32 DrainCrystalTimer;
- uint32 CheckTimer;
+ uint32 EmpowerTimer;
bool IsDraining;
bool DrainingCrystal;
- bool Heroic;
+
uint64 CrystalGUID; // This will help us create a pointer to the crystal we are draining. We store GUIDs, never units in case unit is deleted/offline (offline if player of course).
void Reset()
{
- if(pInstance)
+ if (pInstance)
{
//for(uint8 i = 0; i < CRYSTALS_NUMBER; ++i)
for(std::list<uint64>::iterator itr = Crystals.begin(); itr != Crystals.end(); ++itr)
{
//Unit* pUnit = Unit::GetUnit(*m_creature, FelCrystals[i]);
Unit* pUnit = Unit::GetUnit(*m_creature, *itr);
- if(pUnit)
+ if (pUnit)
{
if(!pUnit->isAlive())
((Creature*)pUnit)->Respawn(); // Let MaNGOS handle setting death state, etc.
@@ -103,14 +104,13 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
pUnit->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
}
}
+
GameObject* Door = GameObject::GetGameObject(*m_creature, pInstance->GetData64(DATA_SELIN_ENCOUNTER_DOOR));
- if( Door )
+ if (Door)
Door->SetGoState(0); // Open the big encounter door. Close it in Aggro and open it only in JustDied(and here)
// Small door opened after event are expected to be closed by default
// Set Inst data for encounter
- if (m_creature->isDead())
- pInstance->SetData(DATA_SELIN_EVENT, DONE);
- else pInstance->SetData(DATA_SELIN_EVENT, NOT_STARTED);
+ pInstance->SetData(DATA_SELIN_EVENT, NOT_STARTED);
}else error_log(ERROR_INST_DATA);
DrainLifeTimer = 3000 + rand()%4000;
@@ -118,7 +118,7 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
FelExplosionTimer = 2100;
DrainCrystalTimer = 10000 + rand()%5000;
DrainCrystalTimer = 20000 + rand()%5000;
- CheckTimer = 1000;
+ EmpowerTimer = 10000;
IsDraining = false;
DrainingCrystal = false;
@@ -127,7 +127,7 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
void SelectNearestCrystal()
{
- if(Crystals.empty())
+ if (Crystals.empty())
return;
float ShortestDistance = 0;
@@ -140,9 +140,9 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
pCrystal = NULL;
//pCrystal = Unit::GetUnit(*m_creature, FelCrystals[i]);
pCrystal = Unit::GetUnit(*m_creature, *itr);
- if(pCrystal && pCrystal->isAlive())
+ if (pCrystal && pCrystal->isAlive())
{
- if(!ShortestDistance || (ShortestDistance > m_creature->GetDistance2d(pCrystal)))
+ if (!ShortestDistance || (ShortestDistance > m_creature->GetDistance2d(pCrystal)))
{
ShortestDistance = m_creature->GetDistance2d(pCrystal);
CrystalGUID = pCrystal->GetGUID();
@@ -150,7 +150,7 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
}
}
}
- if( CrystalChosen )
+ if (CrystalChosen)
{
DoScriptText(SAY_ENERGY, m_creature);
DoScriptText(EMOTE_CRYSTAL, m_creature);
@@ -168,7 +168,7 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
void ShatterRemainingCrystals()
{
- if(Crystals.empty())
+ if (Crystals.empty())
return;
//for(uint8 i = 0; i < CRYSTALS_NUMBER; ++i)
@@ -176,20 +176,19 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
{
//Creature* pCrystal = (Unit::GetCreature(*m_creature, FelCrystals[i]));
Creature* pCrystal = (Unit::GetCreature(*m_creature, *itr));
- if( pCrystal && pCrystal->isAlive())
+ if (pCrystal && pCrystal->isAlive())
pCrystal->DealDamage(pCrystal, pCrystal->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
}
}
void Aggro(Unit* who)
{
- m_creature->SetPower(POWER_MANA, 0);
DoScriptText(SAY_AGGRO, m_creature);
- if( pInstance )
+ if (pInstance)
{
GameObject* EncounterDoor = GameObject::GetGameObject(*m_creature, pInstance->GetData64(DATA_SELIN_ENCOUNTER_DOOR));
- if( EncounterDoor )
+ if (EncounterDoor)
EncounterDoor->SetGoState(1); //Close the encounter door, open it in JustDied/Reset
}
}
@@ -198,17 +197,17 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
{
switch(rand()%2)
{
- case 0: DoScriptText(SAY_KILL_1, m_creature); break;
- case 1: DoScriptText(SAY_KILL_2, m_creature); break;
+ case 0: DoScriptText(SAY_KILL_1, m_creature); break;
+ case 1: DoScriptText(SAY_KILL_2, m_creature); break;
}
}
void MovementInform(uint32 type, uint32 id)
{
- if(type == POINT_MOTION_TYPE && id == 1)
+ if (type == POINT_MOTION_TYPE && id == 1)
{
Unit* CrystalChosen = Unit::GetUnit(*m_creature, CrystalGUID);
- if(CrystalChosen && CrystalChosen->isAlive())
+ if (CrystalChosen && CrystalChosen->isAlive())
{
// Make the crystal attackable
// We also remove NON_ATTACKABLE in case the database has it set.
@@ -229,7 +228,7 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
{
DoScriptText(SAY_DEATH, m_creature);
- if(!pInstance)
+ if (!pInstance)
{
error_log(ERROR_INST_DATA);
return;
@@ -238,35 +237,36 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
pInstance->SetData(DATA_SELIN_EVENT, DONE); // Encounter complete!
GameObject* EncounterDoor = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_SELIN_ENCOUNTER_DOOR));
- if( EncounterDoor )
+ if (EncounterDoor)
EncounterDoor->SetGoState(0); // Open the encounter door
GameObject* ContinueDoor = GameObject::GetGameObject(*m_creature, pInstance->GetData64(DATA_SELIN_DOOR));
- if( ContinueDoor )
+ if (ContinueDoor)
ContinueDoor->SetGoState(0); // Open the door leading further in
+ ShatterRemainingCrystals();
}
void UpdateAI(const uint32 diff)
{
- if(!UpdateVictim())
+ if (!UpdateVictim())
return;
- if(!DrainingCrystal)
+ if (!DrainingCrystal)
{
uint32 maxPowerMana = m_creature->GetMaxPower(POWER_MANA);
- if( maxPowerMana && ((m_creature->GetPower(POWER_MANA)*100 / maxPowerMana) < 10) )
+ if (maxPowerMana && ((m_creature->GetPower(POWER_MANA)*100 / maxPowerMana) < 10))
{
- if( DrainLifeTimer < diff )
+ if (DrainLifeTimer < diff)
{
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_DRAIN_LIFE);
DrainLifeTimer = 10000;
}else DrainLifeTimer -= diff;
// Heroic only
- if( Heroic )
+ if (Heroic)
{
- if( DrainManaTimer < diff )
+ if (DrainManaTimer < diff)
{
DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0), SPELL_DRAIN_MANA);
DrainManaTimer = 10000;
@@ -274,9 +274,9 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
}
}
- if( FelExplosionTimer < diff )
+ if (FelExplosionTimer < diff)
{
- if(!m_creature->IsNonMeleeSpellCasted(false))
+ if (!m_creature->IsNonMeleeSpellCasted(false))
{
DoCast(m_creature, SPELL_FEL_EXPLOSION);
FelExplosionTimer = 2000;
@@ -285,48 +285,40 @@ struct TRINITY_DLL_DECL boss_selin_fireheartAI : public ScriptedAI
// If below 10% mana, start recharging
maxPowerMana = m_creature->GetMaxPower(POWER_MANA);
- if( maxPowerMana && ((m_creature->GetPower(POWER_MANA)*100 / maxPowerMana) < 10) )
+ if (maxPowerMana && ((m_creature->GetPower(POWER_MANA)*100 / maxPowerMana) < 10))
{
- if(DrainCrystalTimer < diff)
+ if (DrainCrystalTimer < diff)
{
SelectNearestCrystal();
- if(Heroic) DrainCrystalTimer = 10000 + rand()%5000;
- else DrainCrystalTimer = 20000 + rand()%5000;
+ if (Heroic) DrainCrystalTimer = 10000 + rand()%5000;
+ else DrainCrystalTimer = 20000 + rand()%5000;
}else DrainCrystalTimer -= diff;
}
}else
{
- if( IsDraining )
+ if (IsDraining)
{
- if (CheckTimer < diff)
+ if (EmpowerTimer < diff)
{
+ IsDraining = false;
+ DrainingCrystal = false;
+
+ DoScriptText(SAY_EMPOWERED, m_creature);
+
Unit* CrystalChosen = Unit::GetUnit(*m_creature, CrystalGUID);
- if(CrystalChosen)
- {
- if(CrystalChosen->GetUInt32Value(UNIT_CHANNEL_SPELL) == SPELL_MANA_RAGE)
- {
- m_creature->StopMoving();
- }else{
- IsDraining = false;
- DrainingCrystal = false;
-
- DoScriptText(SAY_EMPOWERED, m_creature);
-
- Unit* CrystalChosen = Unit::GetUnit(*m_creature, CrystalGUID);
- if( CrystalChosen && CrystalChosen->isAlive() )
- // Use Deal Damage to kill it, not setDeathState.
- CrystalChosen->DealDamage(CrystalChosen, CrystalChosen->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
- CrystalGUID = 0;
-
- m_creature->GetMotionMaster()->Clear();
- m_creature->GetMotionMaster()->MoveChase(m_creature->getVictim());
- }
- }
- CheckTimer = 1000;
- }else CheckTimer -= diff;
+ if (CrystalChosen && CrystalChosen->isAlive())
+ // Use Deal Damage to kill it, not setDeathState.
+ CrystalChosen->DealDamage(CrystalChosen, CrystalChosen->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
+
+ CrystalGUID = 0;
+
+ m_creature->GetMotionMaster()->Clear();
+ m_creature->GetMotionMaster()->MoveChase(m_creature->getVictim());
+ }else EmpowerTimer -= diff;
}
}
+
DoMeleeAttackIfReady(); // No need to check if we are draining crystal here, as the spell has a stun.
}
};
@@ -348,19 +340,18 @@ struct TRINITY_DLL_DECL mob_fel_crystalAI : public ScriptedAI
void JustDied(Unit* killer)
{
- m_creature->RemoveAurasDueToSpell(SPELL_MANA_RAGE);
- if(ScriptedInstance* pInstance = ((ScriptedInstance*)m_creature->GetInstanceData()))
+ if (ScriptedInstance* pInstance = ((ScriptedInstance*)m_creature->GetInstanceData()))
{
Creature* Selin = (Unit::GetCreature(*m_creature, pInstance->GetData64(DATA_SELIN)));
- if(Selin && Selin->isAlive())
+ if (Selin && Selin->isAlive())
{
- if(((boss_selin_fireheartAI*)Selin->AI())->CrystalGUID == m_creature->GetGUID())
+ if (((boss_selin_fireheartAI*)Selin->AI())->CrystalGUID == m_creature->GetGUID())
{
// Set this to false if we are the creature that Selin is draining so his AI flows properly
((boss_selin_fireheartAI*)Selin->AI())->DrainingCrystal = false;
((boss_selin_fireheartAI*)Selin->AI())->IsDraining = false;
- Selin->RemoveAurasDueToSpell(SPELL_MANA_RAGE);
- if(Selin->getVictim())
+ ((boss_selin_fireheartAI*)Selin->AI())->EmpowerTimer = 10000;
+ if (Selin->getVictim())
{
Selin->AI()->AttackStart(Selin->getVictim());
Selin->GetMotionMaster()->MoveChase(Selin->getVictim());
@@ -381,12 +372,12 @@ void AddSC_boss_selin_fireheart()
Script *newscript;
newscript = new Script;
- newscript->Name="boss_selin_fireheart";
+ newscript->Name = "boss_selin_fireheart";
newscript->GetAI = &GetAI_boss_selin_fireheart;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="mob_fel_crystal";
+ newscript->Name = "mob_fel_crystal";
newscript->GetAI = &GetAI_mob_fel_crystal;
newscript->RegisterSelf();
}
diff --git a/src/bindings/scripts/scripts/zone/magisters_terrace/boss_vexallus.cpp b/src/bindings/scripts/scripts/zone/magisters_terrace/boss_vexallus.cpp
index 3743423f0e0..5fb43c88306 100644
--- a/src/bindings/scripts/scripts/zone/magisters_terrace/boss_vexallus.cpp
+++ b/src/bindings/scripts/scripts/zone/magisters_terrace/boss_vexallus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -6,12 +6,12 @@
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/* ScriptData
@@ -29,31 +29,36 @@ EndScriptData */
#define SAY_OVERLOAD -1585009
#define SAY_KILL -1585010
#define EMOTE_DISCHARGE_ENERGY -1585011
+
//is this text for real?
-#define SAY_DEATH "What...happen...ed."
+//#define SAY_DEATH "What...happen...ed."
//Pure energy spell info
-#define SPELL_ENERGY_BOLT 44342
+#define SPELL_ENERGY_BOLT 46156
#define SPELL_ENERGY_FEEDBACK 44335
//Vexallus spell info
#define SPELL_CHAIN_LIGHTNING 44318
-#define SPELL_SUMMON_PURE_ENERGY 44322 //not-working, this script summon this creatures without this spell
#define SPELL_OVERLOAD 44353
#define SPELL_ARCANE_SHOCK 44319
-#define ASTRAL_FLARE_VISUAL 30237
+
+#define SPELL_SUMMON_PURE_ENERGY 44322 //mod scale -10
+#define H_SPELL_SUMMON_PURE_ENERGY1 46154 //mod scale -5
+#define H_SPELL_SUMMON_PURE_ENERGY2 46159 //mod scale -5
//Creatures
#define CREATURE_PURE_ENERGY 24745
-struct TRINITY_DLL_DECL boss_vexallusAI : public ScriptedAI
+struct TRINITY_DLL_DECL boss_vexallusAI : public ScriptedAI
{
boss_vexallusAI(Creature *c) : ScriptedAI(c)
{
pInstance = ((ScriptedInstance*)c->GetInstanceData()); Heroic = c->GetMap()->IsHeroic();
+ Heroic = c->GetMap()->IsHeroic();
}
ScriptedInstance* pInstance;
+ bool Heroic;
uint32 ChainLightningTimer;
uint32 ArcaneShockTimer;
@@ -61,7 +66,6 @@ struct TRINITY_DLL_DECL boss_vexallusAI : public ScriptedAI
uint32 SpawnAddInterval;
uint32 AlreadySpawnedAmount;
bool Enraged;
- bool Heroic;
void Reset()
{
@@ -70,15 +74,10 @@ struct TRINITY_DLL_DECL boss_vexallusAI : public ScriptedAI
OverloadTimer = 2200;
SpawnAddInterval = 15;
AlreadySpawnedAmount = 0;
-
Enraged = false;
- if(pInstance)
- {
- if (m_creature->isDead())
- pInstance->SetData(DATA_VEXALLUS_EVENT, DONE);
- else pInstance->SetData(DATA_VEXALLUS_EVENT, NOT_STARTED);
- }
+ if (pInstance)
+ pInstance->SetData(DATA_VEXALLUS_EVENT, NOT_STARTED);
}
void KilledUnit(Unit *victim)
@@ -88,14 +87,11 @@ struct TRINITY_DLL_DECL boss_vexallusAI : public ScriptedAI
void JustDied(Unit *victim)
{
- DoYell(SAY_DEATH, LANG_UNIVERSAL, NULL);
if (pInstance)
{
pInstance->SetData(DATA_VEXALLUS_EVENT, DONE);
- GameObject* Door = NULL;
- Door = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_VEXALLUS_DOOR));
- if(Door)
+ if (GameObject* Door = GameObject::GetGameObject((*m_creature), pInstance->GetData64(DATA_VEXALLUS_DOOR)))
Door->SetGoState(0);
}
}
@@ -103,68 +99,82 @@ struct TRINITY_DLL_DECL boss_vexallusAI : public ScriptedAI
void Aggro(Unit *who)
{
DoScriptText(SAY_AGGRO, m_creature);
+
if (pInstance)
pInstance->SetData(DATA_VEXALLUS_EVENT, IN_PROGRESS);
}
+ void JustSummoned(Creature *summoned)
+ {
+ if (Unit *temp = SelectUnit(SELECT_TARGET_RANDOM, 0))
+ summoned->GetMotionMaster()->MoveFollow(temp,0,0);
+
+ //spells are SUMMON_TYPE_GUARDIAN, so using setOwner should be ok
+ summoned->CastSpell(summoned,SPELL_ENERGY_BOLT,false,0,0,m_creature->GetGUID());
+ }
+
void UpdateAI(const uint32 diff)
{
if (!UpdateVictim() )
return;
- if(m_creature->GetHealth()*100 / m_creature->GetMaxHealth() < 11)
+ if (m_creature->GetHealth()*100 / m_creature->GetMaxHealth() <= 10)
{
Enraged = true;
}
- if(!Enraged)
+ if (!Enraged)
{
//used for check, when Vexallus cast adds 85%, 70%, 55%, 40%, 25%
if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < (100-(SpawnAddInterval*(AlreadySpawnedAmount+1))))
{
DoScriptText(SAY_ENERGY, m_creature);
DoScriptText(EMOTE_DISCHARGE_ENERGY, m_creature);
- Creature* PureEnergyCreature = NULL;
- PureEnergyCreature = DoSpawnCreature(CREATURE_PURE_ENERGY, 10, 0, 0, 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5000);
- Unit* target = NULL;
- target = SelectUnit(SELECT_TARGET_RANDOM, 0);
- if (PureEnergyCreature && target)
- PureEnergyCreature->AI()->AttackStart(target);
-
- if(Heroic) // *Heroic mode only - he summons two instead of one.
+
+ if (Heroic)
{
- PureEnergyCreature = DoSpawnCreature(CREATURE_PURE_ENERGY, -10, 0, 0, 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 5000);
- target = SelectUnit(SELECT_TARGET_RANDOM, 0);
- if (PureEnergyCreature && target)
- PureEnergyCreature->AI()->AttackStart(target);
+ m_creature->CastSpell(m_creature,H_SPELL_SUMMON_PURE_ENERGY1,false);
+ m_creature->CastSpell(m_creature,H_SPELL_SUMMON_PURE_ENERGY2,false);
}
+ else
+ m_creature->CastSpell(m_creature,SPELL_SUMMON_PURE_ENERGY,false);
+
+ //below are workaround summons, remove when summoning spells w/implicitTarget 73 implemented in Mangos
+ DoSpawnCreature(CREATURE_PURE_ENERGY, 0, 0, 0, 0, TEMPSUMMON_CORPSE_DESPAWN, 0);
+
+ if (Heroic)
+ DoSpawnCreature(CREATURE_PURE_ENERGY, 0, 0, 0, 0, TEMPSUMMON_CORPSE_DESPAWN, 0);
++AlreadySpawnedAmount;
- };
+ }
- if(ChainLightningTimer < diff)
+ if (ChainLightningTimer < diff)
{
if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 0))
- DoCast(target, SPELL_CHAIN_LIGHTNING);
+ DoCast(target, SPELL_CHAIN_LIGHTNING);
+
ChainLightningTimer = 10000;
}else ChainLightningTimer -= diff;
- if(ArcaneShockTimer < diff)
+ if (ArcaneShockTimer < diff)
{
- Unit* target = NULL;
- target = SelectUnit(SELECT_TARGET_RANDOM, 0);
- DoCast(target, SPELL_ARCANE_SHOCK);
+ if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 0))
+ DoCast(target, SPELL_ARCANE_SHOCK);
+
ArcaneShockTimer = 8000;
}else ArcaneShockTimer -= diff;
- }else
+ }
+ else
{
- if(OverloadTimer < diff)
+ if (OverloadTimer < diff)
{
if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 0))
- DoCast(target, SPELL_OVERLOAD);
+ DoCast(target, SPELL_OVERLOAD);
+
OverloadTimer = 2200;
}else OverloadTimer -= diff;
}
+
DoMeleeAttackIfReady();
}
};
@@ -174,44 +184,24 @@ CreatureAI* GetAI_boss_vexallus(Creature *_Creature)
return new boss_vexallusAI (_Creature);
};
-struct TRINITY_DLL_DECL mob_pure_energyAI : public ScriptedAI
+struct TRINITY_DLL_DECL mob_pure_energyAI : public ScriptedAI
{
mob_pure_energyAI(Creature *c) : ScriptedAI(c) {}
- uint32 EnergyBoltTimer;
- uint32 VisualTimer;
-
- void Reset()
- {
- EnergyBoltTimer = 1700;
- VisualTimer = 1000;
- m_creature->SetSpeed(MOVE_RUN, 0.5f);
- m_creature->SetSpeed(MOVE_WALK, 0.5f);
- }
+ void Reset() { }
void JustDied(Unit* slayer)
{
- slayer->CastSpell(slayer, SPELL_ENERGY_FEEDBACK, true, 0, 0, m_creature->GetGUID());
- }
-
- void Aggro(Unit *who){}
-
- void UpdateAI(const uint32 diff)
- {
- if(!UpdateVictim())
- return;
-
- if(EnergyBoltTimer < diff)
+ if (Unit *temp = m_creature->GetOwner())
{
- DoCast(m_creature->getVictim(), SPELL_ENERGY_BOLT);
- EnergyBoltTimer = 1700;
- }else EnergyBoltTimer -= diff;
- if(VisualTimer < diff)
- {
- DoCast(m_creature->getVictim(), ASTRAL_FLARE_VISUAL, true);
- VisualTimer = 1000;
- }else VisualTimer -= diff;
+ if (temp && temp->isAlive())
+ slayer->CastSpell(slayer, SPELL_ENERGY_FEEDBACK, true, 0, 0, temp->GetGUID());
+ }
}
+
+ void Aggro(Unit *who) { }
+ void MoveInLineOfSight(Unit *who) { }
+ void AttackStart(Unit *who) { }
};
CreatureAI* GetAI_mob_pure_energy(Creature *_Creature)
@@ -224,13 +214,12 @@ void AddSC_boss_vexallus()
Script *newscript;
newscript = new Script;
- newscript->Name="boss_vexallus";
+ newscript->Name = "boss_vexallus";
newscript->GetAI = &GetAI_boss_vexallus;
newscript->RegisterSelf();
newscript = new Script;
- newscript->Name="mob_pure_energy";
+ newscript->Name = "mob_pure_energy";
newscript->GetAI = &GetAI_mob_pure_energy;
newscript->RegisterSelf();
}
-
diff --git a/src/bindings/scripts/scripts/zone/magisters_terrace/def_magisters_terrace.h b/src/bindings/scripts/scripts/zone/magisters_terrace/def_magisters_terrace.h
index f509a8bc73c..d6419ea409c 100644
--- a/src/bindings/scripts/scripts/zone/magisters_terrace/def_magisters_terrace.h
+++ b/src/bindings/scripts/scripts/zone/magisters_terrace/def_magisters_terrace.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
@@ -20,13 +20,12 @@
#define DATA_DELRISSA_DOOR 11
#define DATA_SELIN_ENCOUNTER_DOOR 12
-#define DATA_KAEL_STATUE_LEFT 13
-#define DATA_KAEL_STATUE_RIGHT 14
+#define DATA_KAEL_DOOR 13
+#define DATA_KAEL_STATUE_LEFT 14
+#define DATA_KAEL_STATUE_RIGHT 15
-#define DATA_DELRISSA_DEATH_COUNT 15
+#define DATA_DELRISSA_DEATH_COUNT 16
-#define DATA_KAEL 16
-
-#define ERROR_INST_DATA "SD2 Error: Instance Data not set properly for Magister's Terrace instance (map 585). Encounters will be buggy."
+#define ERROR_INST_DATA "TSCR Error: Instance Data not set properly for Magister's Terrace instance (map 585). Encounters will be buggy."
#endif
diff --git a/src/bindings/scripts/scripts/zone/magisters_terrace/instance_magisters_terrace.cpp b/src/bindings/scripts/scripts/zone/magisters_terrace/instance_magisters_terrace.cpp
index 5afb79e84d0..7e16b37c353 100644
--- a/src/bindings/scripts/scripts/zone/magisters_terrace/instance_magisters_terrace.cpp
+++ b/src/bindings/scripts/scripts/zone/magisters_terrace/instance_magisters_terrace.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -6,12 +6,12 @@
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
/* ScriptData
@@ -37,29 +37,25 @@ struct TRINITY_DLL_DECL instance_magisters_terrace : public ScriptedInstance
{
instance_magisters_terrace(Map* map) : ScriptedInstance(map) {Initialize();}
- uint32 DoorState[3];//0seline, 1vexallus, 2derlissa
uint32 Encounters[NUMBER_OF_ENCOUNTERS];
uint32 DelrissaDeathCount;
std::list<uint64> FelCrystals;
std::list<uint64>::iterator CrystalItr;
- uint64 KaelGUID;
uint64 SelinGUID;
uint64 DelrissaGUID;
uint64 VexallusDoorGUID;
uint64 SelinDoorGUID;
uint64 SelinEncounterDoorGUID;
uint64 DelrissaDoorGUID;
+ uint64 KaelDoorGUID;
uint64 KaelStatue[2];
bool InitializedItr;
void Initialize()
{
- for(uint8 i = 0; i < 3; i++)
- DoorState[i] = 1;//1 closed, 0 opened
-
for(uint8 i = 0; i < NUMBER_OF_ENCOUNTERS; i++)
Encounters[i] = NOT_STARTED;
@@ -67,13 +63,13 @@ struct TRINITY_DLL_DECL instance_magisters_terrace : public ScriptedInstance
DelrissaDeathCount = 0;
- KaelGUID = 0;
SelinGUID = 0;
DelrissaGUID = 0;
VexallusDoorGUID = 0;
SelinDoorGUID = 0;
SelinEncounterDoorGUID = 0;
DelrissaDoorGUID = 0;
+ KaelDoorGUID = 0;
KaelStatue[0] = 0;
KaelStatue[1] = 0;
@@ -106,30 +102,9 @@ struct TRINITY_DLL_DECL instance_magisters_terrace : public ScriptedInstance
{
switch(identifier)
{
- case DATA_SELIN_EVENT:
- Encounters[0] = data;
- if(data==DONE)
- {
- DoorState[0] = 0;
- SaveToDB();
- }
- break;
- case DATA_VEXALLUS_EVENT:
- Encounters[1] = data;
- if(data==DONE)
- {
- DoorState[1] = 0;
- SaveToDB();
- }
- break;
- case DATA_DELRISSA_EVENT:
- Encounters[2] = data;
- if(data==DONE)
- {
- DoorState[2] = 0;
- SaveToDB();
- }
- break;
+ case DATA_SELIN_EVENT: Encounters[0] = data; break;
+ case DATA_VEXALLUS_EVENT: Encounters[1] = data; break;
+ case DATA_DELRISSA_EVENT: Encounters[2] = data; break;
case DATA_KAELTHAS_EVENT: Encounters[3] = data; break;
case DATA_DELRISSA_DEATH_COUNT:
@@ -138,38 +113,13 @@ struct TRINITY_DLL_DECL instance_magisters_terrace : public ScriptedInstance
}
}
- const char* Save()
- {
- std::ostringstream ss;
- ss << "S " << DoorState[0] << " " << DoorState[1] << " " << DoorState[2];
- char* data = new char[ss.str().length()+1];
- strcpy(data, ss.str().c_str());
- return data;
- }
-
- void Load(const char* load)
- {
- if(!load) return;
- std::istringstream ss(load);
- char dataHead; // S
- uint32 data1, data2, data3;
- ss >> dataHead >> data1 >> data2 >> data3;
- if(dataHead == 'S')
- {
- DoorState[0] = data1;
- DoorState[1] = data2;
- DoorState[2] = data3;
- }else error_log("SD2: Magister's Terrace: corrupted save data.");
- }
-
void OnCreatureCreate(Creature *creature, uint32 entry)
{
- switch(entry)
+ switch(creature->GetEntry())
{
case 24723: SelinGUID = creature->GetGUID(); break;
case 24560: DelrissaGUID = creature->GetGUID(); break;
case 24722: FelCrystals.push_back(creature->GetGUID()); break;
- case 24664: KaelGUID = creature->GetGUID(); break;
}
}
@@ -177,21 +127,13 @@ struct TRINITY_DLL_DECL instance_magisters_terrace : public ScriptedInstance
{
switch(go->GetEntry())
{
- case 187896:
- VexallusDoorGUID = go->GetGUID();
- go->SetGoState(DoorState[1]);
- break;
+ case 187896: VexallusDoorGUID = go->GetGUID(); break;
//SunwellRaid Gate 02
- case 187979:
- SelinDoorGUID = go->GetGUID();
- go->SetGoState(DoorState[0]);
- break;
+ case 187979: SelinDoorGUID = go->GetGUID(); break;
//Assembly Chamber Door
case 188065: SelinEncounterDoorGUID = go->GetGUID(); break;
- case 187770:
- DelrissaDoorGUID = go->GetGUID();
- go->SetGoState(DoorState[2]);
- break;
+ case 187770: DelrissaDoorGUID = go->GetGUID(); break;
+ case 188064: KaelDoorGUID = go->GetGUID(); break;
case 188165: KaelStatue[0] = go->GetGUID(); break;
case 188166: KaelStatue[1] = go->GetGUID(); break;
}
@@ -202,12 +144,12 @@ struct TRINITY_DLL_DECL instance_magisters_terrace : public ScriptedInstance
switch(identifier)
{
case DATA_SELIN: return SelinGUID;
- case DATA_KAEL: return KaelGUID;
case DATA_DELRISSA: return DelrissaGUID;
case DATA_VEXALLUS_DOOR: return VexallusDoorGUID;
case DATA_SELIN_DOOR: return SelinDoorGUID;
case DATA_SELIN_ENCOUNTER_DOOR: return SelinEncounterDoorGUID;
case DATA_DELRISSA_DOOR: return DelrissaDoorGUID;
+ case DATA_KAEL_DOOR: return KaelDoorGUID;
case DATA_KAEL_STATUE_LEFT: return KaelStatue[0];
case DATA_KAEL_STATUE_RIGHT: return KaelStatue[1];
diff --git a/src/bindings/scripts/scripts/zone/maraudon/boss_celebras_the_cursed.cpp b/src/bindings/scripts/scripts/zone/maraudon/boss_celebras_the_cursed.cpp
index 16a6a301681..bb7c183ff02 100644
--- a/src/bindings/scripts/scripts/zone/maraudon/boss_celebras_the_cursed.cpp
+++ b/src/bindings/scripts/scripts/zone/maraudon/boss_celebras_the_cursed.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/maraudon/boss_landslide.cpp b/src/bindings/scripts/scripts/zone/maraudon/boss_landslide.cpp
index ca2253c96b1..960307421d0 100644
--- a/src/bindings/scripts/scripts/zone/maraudon/boss_landslide.cpp
+++ b/src/bindings/scripts/scripts/zone/maraudon/boss_landslide.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/maraudon/boss_noxxion.cpp b/src/bindings/scripts/scripts/zone/maraudon/boss_noxxion.cpp
index e59da4ff650..d748220d3cf 100644
--- a/src/bindings/scripts/scripts/zone/maraudon/boss_noxxion.cpp
+++ b/src/bindings/scripts/scripts/zone/maraudon/boss_noxxion.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/maraudon/boss_princess_theradras.cpp b/src/bindings/scripts/scripts/zone/maraudon/boss_princess_theradras.cpp
index 64b7c2c67f5..4741577a60b 100644
--- a/src/bindings/scripts/scripts/zone/maraudon/boss_princess_theradras.cpp
+++ b/src/bindings/scripts/scripts/zone/maraudon/boss_princess_theradras.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/molten_core/boss_baron_geddon.cpp b/src/bindings/scripts/scripts/zone/molten_core/boss_baron_geddon.cpp
index 5b34758714c..953ed97cfc6 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/boss_baron_geddon.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/boss_baron_geddon.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/molten_core/boss_garr.cpp b/src/bindings/scripts/scripts/zone/molten_core/boss_garr.cpp
index 7f4758b8c79..72d2e871f16 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/boss_garr.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/boss_garr.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/molten_core/boss_gehennas.cpp b/src/bindings/scripts/scripts/zone/molten_core/boss_gehennas.cpp
index fbe09203551..55ed3c6fb38 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/boss_gehennas.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/boss_gehennas.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/molten_core/boss_golemagg.cpp b/src/bindings/scripts/scripts/zone/molten_core/boss_golemagg.cpp
index 8684f10c509..b98c4bec979 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/boss_golemagg.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/boss_golemagg.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/molten_core/boss_lucifron.cpp b/src/bindings/scripts/scripts/zone/molten_core/boss_lucifron.cpp
index 7b948fbf747..b1d12d5a351 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/boss_lucifron.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/boss_lucifron.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/molten_core/boss_magmadar.cpp b/src/bindings/scripts/scripts/zone/molten_core/boss_magmadar.cpp
index 72c3a759dfa..034344845c6 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/boss_magmadar.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/boss_magmadar.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/molten_core/boss_majordomo_executus.cpp b/src/bindings/scripts/scripts/zone/molten_core/boss_majordomo_executus.cpp
index c28867accbd..ccfed05578b 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/boss_majordomo_executus.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/boss_majordomo_executus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/molten_core/boss_ragnaros.cpp b/src/bindings/scripts/scripts/zone/molten_core/boss_ragnaros.cpp
index 7d9a64666cf..fddbbdeb992 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/boss_ragnaros.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/boss_ragnaros.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -225,6 +225,7 @@ struct TRINITY_DLL_DECL boss_ragnarosAI : public Scripted_NoMovementAI
{
target = SelectUnit(SELECT_TARGET_RANDOM,0);
Summoned = m_creature->SummonCreature(12143,target->GetPositionX(), target->GetPositionY(), target->GetPositionZ(),0,TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN,900000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
}
@@ -242,6 +243,7 @@ struct TRINITY_DLL_DECL boss_ragnarosAI : public Scripted_NoMovementAI
{
target = SelectUnit(SELECT_TARGET_RANDOM,0);
Summoned = m_creature->SummonCreature(12143,target->GetPositionX(), target->GetPositionY(), target->GetPositionZ(),0,TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN,900000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
}
diff --git a/src/bindings/scripts/scripts/zone/molten_core/boss_shazzrah.cpp b/src/bindings/scripts/scripts/zone/molten_core/boss_shazzrah.cpp
index d11a49e0cf9..1f515f1e32f 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/boss_shazzrah.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/boss_shazzrah.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/molten_core/boss_sulfuron_harbinger.cpp b/src/bindings/scripts/scripts/zone/molten_core/boss_sulfuron_harbinger.cpp
index 244bc6ece50..3efc6d08bbf 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/boss_sulfuron_harbinger.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/boss_sulfuron_harbinger.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/molten_core/def_molten_core.h b/src/bindings/scripts/scripts/zone/molten_core/def_molten_core.h
index e728c863767..5874d8b9408 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/def_molten_core.h
+++ b/src/bindings/scripts/scripts/zone/molten_core/def_molten_core.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/molten_core/instance_molten_core.cpp b/src/bindings/scripts/scripts/zone/molten_core/instance_molten_core.cpp
index 5c783edfe10..bfaa583e033 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/instance_molten_core.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/instance_molten_core.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/molten_core/molten_core.cpp b/src/bindings/scripts/scripts/zone/molten_core/molten_core.cpp
index 8d9977957d6..d25ddc7631c 100644
--- a/src/bindings/scripts/scripts/zone/molten_core/molten_core.cpp
+++ b/src/bindings/scripts/scripts/zone/molten_core/molten_core.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/moonglade/moonglade.cpp b/src/bindings/scripts/scripts/zone/moonglade/moonglade.cpp
index 027ef125ca7..dfafa193542 100644
--- a/src/bindings/scripts/scripts/zone/moonglade/moonglade.cpp
+++ b/src/bindings/scripts/scripts/zone/moonglade/moonglade.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/mulgore/mulgore.cpp b/src/bindings/scripts/scripts/zone/mulgore/mulgore.cpp
index 74d800a5484..85d5d8a1d53 100644
--- a/src/bindings/scripts/scripts/zone/mulgore/mulgore.cpp
+++ b/src/bindings/scripts/scripts/zone/mulgore/mulgore.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/nagrand/nagrand.cpp b/src/bindings/scripts/scripts/zone/nagrand/nagrand.cpp
index 0266fa8ef43..8b43005b5df 100644
--- a/src/bindings/scripts/scripts/zone/nagrand/nagrand.cpp
+++ b/src/bindings/scripts/scripts/zone/nagrand/nagrand.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -124,7 +124,7 @@ struct TRINITY_DLL_DECL mob_lumpAI : public ScriptedAI
m_creature->DeleteThreatList();
m_creature->CombatStop();
m_creature->setFaction(1080); //friendly
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, PLAYER_STATE_SIT);
+ m_creature->SetStandState(UNIT_STAND_STATE_SIT);
DoScriptText(LUMP_DEFEAT, m_creature);
bReset = true;
@@ -134,11 +134,11 @@ struct TRINITY_DLL_DECL mob_lumpAI : public ScriptedAI
void Aggro(Unit *who)
{
- if (m_creature->HasAura(SPELL_VISUAL_SLEEP,0))
- m_creature->RemoveAura(SPELL_VISUAL_SLEEP,0);
+ if (m_creature->HasAura(SPELL_VISUAL_SLEEP))
+ m_creature->RemoveAura(SPELL_VISUAL_SLEEP);
if (!m_creature->IsStandState())
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, PLAYER_STATE_NONE);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
switch(rand()%2)
{
@@ -226,7 +226,7 @@ struct TRINITY_DLL_DECL mob_sunspring_villagerAI : public ScriptedAI
void Reset()
{
m_creature->SetUInt32Value(UNIT_DYNAMIC_FLAGS, 32);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,7); // lay down
+ m_creature->SetStandState(UNIT_STAND_STATE_DEAD);
}
void Aggro(Unit *who) {}
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_anubrekhan.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_anubrekhan.cpp
index 86d4002718f..815b273d185 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_anubrekhan.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_anubrekhan.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -16,7 +16,7 @@
/* ScriptData
SDName: Boss_Anubrekhan
-SD%Complete: 70
+SD%Complete: 100
SDComment:
SDCategory: Naxxramas
EndScriptData */
@@ -38,7 +38,7 @@ EndScriptData */
#define SPELL_LOCUSTSWARM 28785 //This is a self buff that triggers the dmg debuff
#define H_SPELL_LOCUSTSWARM 54021
-//invalid
+//spellId invalid
#define SPELL_SUMMONGUARD 29508 //Summons 1 crypt guard at targeted location
#define SPELL_SELF_SPAWN_5 29105 //This spawns 5 corpse scarabs ontop of us (most likely the player casts this on death)
@@ -109,7 +109,7 @@ struct TRINITY_DLL_DECL boss_anubrekhanAI : public ScriptedAI
{
//Cast Impale on a random target
//Do NOT cast it when we are afflicted by locust swarm
- if (!m_creature->HasAura(SPELL_LOCUSTSWARM,1))
+ if (!m_creature->HasAura(SPELL_LOCUSTSWARM))
{
if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM,0))
DoCast(target,SPELL_IMPALE);
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_faerlina.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_faerlina.cpp
index c04cab35e58..5fafebadb96 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_faerlina.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_faerlina.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -17,7 +17,7 @@
/* ScriptData
SDName: Boss_Faerlina
SD%Complete: 50
-SDComment: Without Mindcontrol boss cannot be defeated
+SDComment:
SDCategory: Naxxramas
EndScriptData */
@@ -32,6 +32,8 @@ EndScriptData */
#define SAY_SLAY2 -1533015
#define SAY_DEATH -1533016
+//#define SOUND_RANDOM_AGGRO 8955 //soundId containing the 4 aggro sounds, we not using this
+
#define SPELL_POSIONBOLT_VOLLEY 28796
#define H_SPELL_POSIONBOLT_VOLLEY 54098
#define SPELL_ENRAGE 28798
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_four_horsemen.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_four_horsemen.cpp
index 0ae5080d227..a51573d745d 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_four_horsemen.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_four_horsemen.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_gluth.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_gluth.cpp
index 80cbc347fe1..5fb9f017b0a 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_gluth.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_gluth.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_gothik.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_gothik.cpp
index ed2ef9de4e6..0becff399da 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_gothik.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_gothik.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -41,8 +41,10 @@ EndScriptData */
#define SPELL_SHADOW_MARK 27825
//Unrelenting Rider
-#define SPELL_UNHOLY_AURA 28340
-#define SPELL_SHADOWBOLT 19729 //Search thru targets and find those who have the SHADOW_MARK to cast this on
+#define SPELL_UNHOLY_AURA 55606
+#define H_SPELL_UNHOLY_AURA 55608
+#define SPELL_SHADOWBOLT_VOLLEY 27831 //Search thru targets and find those who have the SHADOW_MARK to cast this on
+#define H_SPELL_SHADOWBOLT_VOLLEY 55638
//Spectral Trainee
#define SPELL_ARCANE_EXPLOSION 27989
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_grobbulus.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_grobbulus.cpp
index 88ce581e6dd..e0bf157dc43 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_grobbulus.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_grobbulus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_heigan.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_heigan.cpp
index 78921efff3d..d5f1e594d0c 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_heigan.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_heigan.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -21,20 +21,19 @@ SDComment: Place Holder
SDCategory: Naxxramas
EndScriptData */
-//Lotheb or Heigan?
-//8825 aggro1 - You are mine now!
-//8826 aggro2 - I see you!
-//8827 aggro3 - You...are next!
-//8828 death -
-//8829 slay - close your eyes... sleep
-//8830 taunt1 - The races of the world will perish. It is only a matter of time.
-//8831 taunt2 - I see endless suffering, I see torment, I see rage. I see... everything!
-//8832 taunt3 - Soon... the world will tremble!
-//8833 taunt4 - The end is upon you.
-//8834 taunt5 - Hungry worms will feast on your rotten flesh!
-
#include "precompiled.h"
+#define SAY_AGGRO1 -1533109
+#define SAY_AGGRO2 -1533110
+#define SAY_AGGRO3 -1533111
+#define SAY_SLAY -1533112
+#define SAY_TAUNT1 -1533113
+#define SAY_TAUNT2 -1533114
+#define SAY_TAUNT3 -1533115
+#define SAY_TAUNT4 -1533116
+#define SAY_TAUNT5 -1533117
+#define SAY_DEATH -1533118
+
//Spell used by floor peices to cause damage to players
#define SPELL_ERUPTION 29371
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_kelthuzad.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_kelthuzad.cpp
index 170ced981f7..952fb5504ce 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_kelthuzad.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_kelthuzad.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -257,7 +257,7 @@ struct TRINITY_DLL_DECL boss_kelthuzadAI : public ScriptedAI
Walk_Pos_Z = ADDZ_RIGHT_NEAR;
break;
}
- pUnit->SendMonsterMoveWithSpeed(Walk_Pos_X, Walk_Pos_Y, Walk_Pos_Z,MOVEMENTFLAG_WALK_MODE);
+ pUnit->SendMonsterMoveWithSpeed(Walk_Pos_X, Walk_Pos_Y, Walk_Pos_Z);
}
}
@@ -407,7 +407,7 @@ struct TRINITY_DLL_DECL boss_kelthuzadAI : public ScriptedAI
{
//if we find no one to figth walk to the center
if(!pUnit->isInCombat())
- pUnit->SendMonsterMoveWithSpeed(Walk_Pos_X,Walk_Pos_Y,Walk_Pos_Z,MOVEMENTFLAG_WALK_MODE);
+ pUnit->SendMonsterMoveWithSpeed(Walk_Pos_X,Walk_Pos_Y,Walk_Pos_Z);
//Safe storing of creatures
GuardiansOfIcecrown[GuardiansOfIcecrown_Count] = pUnit->GetGUID();
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_loatheb.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_loatheb.cpp
index d5e382d80e6..aceaba93b1f 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_loatheb.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_loatheb.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,28 +23,6 @@ EndScriptData */
#include "precompiled.h"
-#define SAY_AGGRO1 "You are mine now!"
-#define SAY_AGGRO2 "I see you!"
-#define SAY_AGGRO3 "You...are next!"
-#define SAY_SLAY1 "Close your eyes... sleep!"
-#define SAY_SLAY2 "The races of the world will perish. It is only a matter of time."
-#define SAY_SLAY3 "I see endless suffering, I see torment, I see rage. I see... everything!"
-#define SAY_SLAY4 "Soon... the world will tremble!"
-#define SAY_SLAY5 "The end is upon you."
-#define SAY_SLAY6 "Hungry worms will feast on your rotten flesh!"
-#define SAY_DEATH ""
-
-#define SOUND_AGGRO1 8825
-#define SOUND_AGGRO2 8826
-#define SOUND_AGGRO3 8827
-#define SOUND_SLAY1 8829
-#define SOUND_SLAY2 8830
-#define SOUND_SLAY3 8831
-#define SOUND_SLAY4 8832
-#define SOUND_SLAY5 8833
-#define SOUND_SLAY6 8834
-#define SOUND_DEATH 8828
-
#define SPELL_CORRUPTED_MIND 29198
#define SPELL_POISON_AURA 29865
#define SPELL_INEVITABLE_DOOM 29204
@@ -85,58 +63,10 @@ struct TRINITY_DLL_DECL boss_loathebAI : public ScriptedAI
void Aggro(Unit *who)
{
- switch (rand()%3)
- {
- case 0:
- DoYell(SAY_AGGRO1,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_AGGRO1);
- break;
- case 1:
- DoYell(SAY_AGGRO2,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_AGGRO2);
- break;
- case 2:
- DoYell(SAY_AGGRO3,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_AGGRO3);
- break;
- }
- }
-
- void KilledUnit(Unit* victim)
- {
- switch (rand()%6)
- {
- case 0:
- DoYell(SAY_SLAY1,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_SLAY1);
- break;
- case 1:
- DoYell(SAY_SLAY2,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_SLAY2);
- break;
- case 2:
- DoYell(SAY_SLAY3,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_SLAY3);
- break;
- case 3:
- DoYell(SAY_SLAY4,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_SLAY4);
- break;
- case 4:
- DoYell(SAY_SLAY5,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_SLAY5);
- break;
- case 5:
- DoYell(SAY_SLAY6,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_SLAY6);
- break;
- }
}
void JustDied(Unit* Killer)
{
- DoYell(SAY_DEATH,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_DEATH);
}
void UpdateAI(const uint32 diff)
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_maexxna.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_maexxna.cpp
index 235029f1cb7..6c41ad1b022 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_maexxna.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_maexxna.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -16,8 +16,8 @@
/* ScriptData
SDName: Boss_Maexxna
-SD%Complete: 80
-SDComment:
+SD%Complete: 60
+SDComment: this needs review, and rewrite of the webwrap ability
SDCategory: Naxxramas
EndScriptData */
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_noth.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_noth.cpp
index 59f9d33e245..43be957aa81 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_noth.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_noth.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_patchwerk.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_patchwerk.cpp
index 99d30a7ed06..5359b47bad4 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_patchwerk.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_patchwerk.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -16,8 +16,8 @@
/* ScriptData
SDName: Boss_Patchwerk
-SD%Complete: 100
-SDComment: Some issues with hateful strike inturrupting the melee swing timer. Probably core issue.
+SD%Complete: 80
+SDComment: Some issues with hateful strike inturrupting the melee swing timer.
SDCategory: Naxxramas
EndScriptData */
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_razuvious.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_razuvious.cpp
index 9a8277264e5..9054e89dc26 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_razuvious.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_razuvious.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_sapphiron.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_sapphiron.cpp
index 43396199f5f..c0c2f457f0c 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_sapphiron.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_sapphiron.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/boss_thaddius.cpp b/src/bindings/scripts/scripts/zone/naxxramas/boss_thaddius.cpp
index a8bc620ec17..259c1589791 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/boss_thaddius.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/boss_thaddius.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -17,7 +17,7 @@
/* ScriptData
SDName: Boss_Thaddius
SD%Complete: 0
-SDComment: Merge Feugen & Stalagg with this script
+SDComment: Placeholder. Includes Feugen & Stalagg.
SDCategory: Naxxramas
EndScriptData */
diff --git a/src/bindings/scripts/scripts/zone/naxxramas/instance_naxxramas.cpp b/src/bindings/scripts/scripts/zone/naxxramas/instance_naxxramas.cpp
index e589630c15f..2ed8399f57a 100644
--- a/src/bindings/scripts/scripts/zone/naxxramas/instance_naxxramas.cpp
+++ b/src/bindings/scripts/scripts/zone/naxxramas/instance_naxxramas.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/netherstorm/netherstorm.cpp b/src/bindings/scripts/scripts/zone/netherstorm/netherstorm.cpp
index 05a6c9b6bf8..7704247cf90 100644
--- a/src/bindings/scripts/scripts/zone/netherstorm/netherstorm.cpp
+++ b/src/bindings/scripts/scripts/zone/netherstorm/netherstorm.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -404,7 +404,7 @@ struct TRINITY_DLL_DECL npc_commander_dawnforgeAI : public ScriptedAI
cell.SetNoCreate();
Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck creature_check(*m_creature, entry, true, range);
- Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck> searcher(pCreature, creature_check);
+ Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck> searcher(m_creature, pCreature, creature_check);
TypeContainerVisitor<Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck>, GridTypeMapContainer> creature_searcher(searcher);
@@ -441,8 +441,8 @@ struct TRINITY_DLL_DECL npc_commander_dawnforgeAI : public ScriptedAI
ardonis->SendUpdateToPlayer(player);
//Set them to kneel
- m_creature->SetStandState(PLAYER_STATE_KNEEL);
- ardonis->SetStandState(PLAYER_STATE_KNEEL);
+ m_creature->SetStandState(UNIT_STAND_STATE_KNEEL);
+ ardonis->SetStandState(UNIT_STAND_STATE_KNEEL);
}
//Set them back to each other
@@ -466,8 +466,8 @@ struct TRINITY_DLL_DECL npc_commander_dawnforgeAI : public ScriptedAI
ardonis->SendUpdateToPlayer(player);
//Set state
- m_creature->SetStandState(PLAYER_STATE_NONE);
- ardonis->SetStandState(PLAYER_STATE_NONE);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
+ ardonis->SetStandState(UNIT_STAND_STATE_STAND);
}
}
@@ -639,7 +639,7 @@ Creature* SearchDawnforge(Player *source, uint32 entry, float range)
cell.SetNoCreate();
Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck creature_check(*source, entry, true, range);
- Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck> searcher(pCreature, creature_check);
+ Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck> searcher(source, pCreature, creature_check);
TypeContainerVisitor<Trinity::CreatureLastSearcher<Trinity::NearestCreatureEntryWithLiveStateInObjectRangeCheck>, GridTypeMapContainer> creature_searcher(searcher);
@@ -652,7 +652,7 @@ Creature* SearchDawnforge(Player *source, uint32 entry, float range)
bool AreaTrigger_at_commander_dawnforge(Player *player, AreaTriggerEntry *at)
{
//if player lost aura or not have at all, we should not try start event.
- if (!player->HasAura(SPELL_SUNFURY_DISGUISE,0))
+ if (!player->HasAura(SPELL_SUNFURY_DISGUISE))
return false;
if (player->isAlive() && player->GetQuestStatus(QUEST_INFO_GATHERING) == QUEST_STATUS_INCOMPLETE)
@@ -858,7 +858,7 @@ struct TRINITY_DLL_DECL mob_phase_hunterAI : public ScriptedAI
DoScriptText(EMOTE_WEAK, m_creature);
Weak = true;
}
- if(Weak && !Drained && m_creature->HasAura(34219, 0))
+ if(Weak && !Drained && m_creature->HasAura(34219))
{
Drained = true;
diff --git a/src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/boss_malygos.cpp b/src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/boss_malygos.cpp
new file mode 100644
index 00000000000..25a156b1bc4
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/boss_malygos.cpp
@@ -0,0 +1,170 @@
+/* Script Data Start
+SDName: Boss malygos
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_ARCANE_BREATH_N 56272
+#define SPELL_ARCANE_BREATH_H 60072
+#define SPELL_ARCANE_PULSE 57432
+#define SPELL_ARCANE_STORM_1 57459
+#define SPELL_ARCANE_STORM_2 61693
+#define SPELL_ARCANE_STORM_3 61694
+#define SPELL_STATIC_FIELD 57430
+#define SPELL_SURGE_OF_POWER_1 56505
+#define SPELL_SURGE_OF_POWER_2 57407
+#define SPELL_SURGE_OF_POWER_3 60936
+#define SPELL_VORTEX 56105
+
+//Dragon "mounts" spells in Phase3
+//they use Rugelike energy
+#define SPELL_DMOUNT_FLAME_SPIKE 56091 //maybe not accurate
+#define SPELL_DMOUNT_ENGULF_IN_FLAMES 61621
+#define SPELL_DMOUNT_REVIVIFY 57090
+#define SPELL_DMOUNT_LIFE_BURST 57143
+#define SPELL_DMOUNT_FLAME_SHIELD 57108
+//#define SPELL_DMOUNT_UNKNOWN XYZ //Increases your drake's flight speed by 500%.
+
+
+//Yell
+//-->Other
+#define SAY_ANTI_MAGIC_SHELL -1616000
+#define SAY_BREATH_ATTACK -1616001
+#define SAY_HIGH_DAMAGE_MODE -1616002
+#define SAY_MAGIC_BLAST -1616003
+//--> Generic Spells
+#define SAY_GENERIC_SPELL_1 -1616004
+#define SAY_GENERIC_SPELL_2 -1616005
+#define SAY_GENERIC_SPELL_3 -1616006
+#define SAY_DEATH -1616007
+//--> Prefight
+#define SAY_PREFIGHT_1 -1616008
+#define SAY_PREFIGHT_2 -1616009
+#define SAY_PREFIGHT_3 -1616010
+#define SAY_PREFIGHT_4 -1616011
+#define SAY_PREFIGHT_5 -1616012
+//--> Phase1
+#define SAY_PHASE1_AGGRO -1616013
+#define SAY_PHASE1_END -1616014
+#define SAY_PHASE1_SLAY_1 -1616015
+#define SAY_PHASE1_SLAY_2 -1616016
+#define SAY_PHASE1_SLAY_3 -1616017
+
+//--> Phase2 at 50% HP,
+
+/*Malygos himself is not targetable during this phase, it will end when the adds he spawns are all killed. However, he does continue to play a part in the encounter.
+During this phase he drops anti-magic zones onto the ground the raid MUST stand inside of, it reduces magical damage taken by 50%. They shrink over time, so it's important that your raid moves to each new one he drops.
+Throughout the phase, he will deep breath doing ~4k damage per second, unless you are standing inside of the anti-magic zone.
+The way the fight works during this phase is there are NPCs riding around on disks in the room. There are two types of mobs, Lords and Scions.
+The Lords will move down onto the group, and need to be tanked (They will one-shot a non-tank). After they die, they drop a disk that a raid member can mount onto, which allows them to fly, to attack the Scions that do not come down to the ground.
+It is recommended to let melee take the first disks, then ranged. As those mobs die, they also drop disks, which allows the rest of your dps to get onto them.
+The Scions will continually cast Arcane Blast on random targets on the floor, which is mitigated by the anti-magic zones. While mounted on a disk, you will not take damage.
+After all of the NPCs riding on the disks die, the players on the disks need to dismount as Phase 3 is about to begin.*/
+
+#define SAY_PHASE2_AGGRO -1616018
+#define SAY_PHASE2_END -1616019
+#define SAY_PHASE2_SLAY_1 -1616020
+#define SAY_PHASE2_SLAY_2 -1616021
+#define SAY_PHASE2_SLAY_3 -1616022
+//--> Phase3 Malygos destroys the floor, encounter continues on dragon "mounts"
+#define SAY_PHASE3_INTRO -1616023
+#define SAY_PHASE3_AGGRO -1616024
+#define SAY_PHASE3_SLAY_1 -1616025
+#define SAY_PHASE3_SLAY_2 -1616026
+#define SAY_PHASE3_SLAY_3 -1616027
+#define SAY_PHASE3_BIG_ATTACK -1616028
+
+struct TRINITY_DLL_DECL boss_malygosAI : public ScriptedAI
+{
+ boss_malygosAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 phase,
+ enrage;
+
+ void Reset()
+ {
+ //Source Deadly Boss Mod
+ enrage = 615000; //10 min
+ }
+ void Aggro(Unit* who)
+ {
+ if(phase == 1)
+ DoScriptText(SAY_PHASE1_AGGRO, m_creature);
+ if(phase == 2)
+ DoScriptText(SAY_PHASE1_AGGRO, m_creature);
+ if(phase == 3)
+ DoScriptText(SAY_PHASE1_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ phase =1;
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) <= 50){
+ phase = 2;
+ //spawn adds
+ //set malygos unatackable untill all adds spawned dead
+ //start phase3
+ }
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ if(phase ==1)
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_PHASE1_SLAY_1, m_creature); break;
+ case 1: DoScriptText(SAY_PHASE1_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_PHASE1_SLAY_3, m_creature);break;
+ }
+ if(phase ==2)
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_PHASE2_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_PHASE2_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_PHASE2_SLAY_3, m_creature);break;
+ }
+ if(phase ==3)
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_PHASE3_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_PHASE3_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_PHASE3_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_malygos(Creature *_Creature)
+{
+ return new boss_malygosAI (_Creature);
+}
+
+void AddSC_boss_malygos()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_malygos";
+ newscript->GetAI = GetAI_boss_malygos;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/def_eye_of_eternity.h b/src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/def_eye_of_eternity.h
new file mode 100644
index 00000000000..caa82a92e95
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/def_eye_of_eternity.h
@@ -0,0 +1,4 @@
+#ifndef DEF_EYE_OF_ETERNITY_H
+#define DEF_EYE_OF_ETERNITY_H
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/instance_eye_of_eternity.cpp b/src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/instance_eye_of_eternity.cpp
new file mode 100644
index 00000000000..48d26f2bcd9
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/eye_of_eternity/instance_eye_of_eternity.cpp
@@ -0,0 +1,21 @@
+#include "precompiled.h"
+#include "def_eye_of_eternity.h"
+
+struct TRINITY_DLL_DECL instance_eye_of_eternity : public ScriptedInstance
+{
+ instance_eye_of_eternity(Map *Map) : ScriptedInstance(Map) {Initialize();};
+};
+
+InstanceData* GetInstanceData_instance_eye_of_eternity(Map* map)
+{
+ return new instance_eye_of_eternity(map);
+}
+
+void AddSC_instance_eye_of_eternity()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_eye_of_eternity";
+ newscript->GetInstanceData = GetInstanceData_instance_eye_of_eternity;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/nexus/boss_anomalus.cpp b/src/bindings/scripts/scripts/zone/nexus/nexus/boss_anomalus.cpp
new file mode 100644
index 00000000000..559a9081226
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/nexus/boss_anomalus.cpp
@@ -0,0 +1,149 @@
+/* Script Data Start
+SDName: Boss anomalus
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_SPARK_1 47751
+#define SPELL_SPARK_2 57062
+#define SPELL_RIFT_SHIELD 47748
+#define SPELL_CHARGE_RIFT 47747
+#define SPELL_ARCANE_ATTRACTION 57063
+#define SPELL_CREATE_RIFT 47743 //Dummy ---> summons (npc 26918) "Chaotic Rift", which spawns "Crazed Mana Wraith"s (npc 26746)
+
+#define MOB_CRAZED_MANA_WRAITH 26746
+#define NPC_CHAOTIC_RIFT 26918
+
+//Yell
+#define SAY_AGGRO -1576000
+#define SAY_KILL -1576001
+#define SAY_DEATH -1576002
+#define SAY_RIFT -1576003
+#define SAY_SHIELD -1576004
+
+struct TRINITY_DLL_DECL boss_anomalusAI : public ScriptedAI
+{
+ boss_anomalusAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ //Source DBM
+ if((((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 80) && ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) > 77))
+ || (((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 55) && ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) > 52))
+ || (((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 30) && ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) > 27)))
+ {
+ //Summon rift at a random location
+ }
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ DoScriptText(SAY_KILL, m_creature);
+ }
+};
+
+/*######
+## Crazed Mana Wraiths
+######*/
+#define SPELL_ARCANE_MISSILES 33833
+
+struct TRINITY_DLL_DECL mob_crazed_mana_wraithAI : public ScriptedAI
+{
+ mob_crazed_mana_wraithAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+/*######
+## Chaotic Rift
+######*/
+#define SPELL_CHAOTIC_ENERGY_BURST 47688
+#define SPELL_CHARGED_CHAOTIC_ENERGY_BURST 47737
+
+struct TRINITY_DLL_DECL npc_chaotic_riftAI : public ScriptedAI
+{
+ npc_chaotic_riftAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+CreatureAI* GetAI_npc_chaotic_rift(Creature *_Creature)
+{
+ return new npc_chaotic_riftAI (_Creature);
+}
+
+CreatureAI* GetAI_boss_anomalus(Creature *_Creature)
+{
+ return new boss_anomalusAI (_Creature);
+}
+
+CreatureAI* GetAI_mob_crazed_mana_wraith(Creature *_Creature)
+{
+ return new boss_anomalusAI (_Creature);
+}
+
+void AddSC_boss_anomalus()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_anomalus";
+ newscript->GetAI = GetAI_boss_anomalus;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="mob_crazed_mana_wraith";
+ newscript->GetAI = GetAI_mob_crazed_mana_wraith;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="npc_chaotic_rift";
+ newscript->GetAI = GetAI_npc_chaotic_rift;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/nexus/boss_keristrasza.cpp b/src/bindings/scripts/scripts/zone/nexus/nexus/boss_keristrasza.cpp
new file mode 100644
index 00000000000..7c764c3ec1a
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/nexus/boss_keristrasza.cpp
@@ -0,0 +1,89 @@
+/* Script Data Start
+SDName: Boss keristrasza
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_maiden_of_grief' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_TAIL_SWEEP 50155
+#define SPELL_CRYSTAL_CHAINS 50997
+#define SPELL_ENRAGE 8599
+#define SPELL_CRYSTALFIRE_BREATH_1 48096
+#define SPELL_CRYSTALFIRE_BREATH_2 57091
+#define SPELL_CRYSTALIZE 48179
+#define SPELL_INTENSE_COLD 48095 //stackable debuff
+
+//Yell
+#define SAY_AGGRO -1576005
+#define SAY_SLAY -1576006
+#define SAY_ENRAGE -1576007
+#define SAY_DEATH -1576008
+#define SAY_CRYSTAL_NOVA -1576009
+
+struct TRINITY_DLL_DECL boss_keristraszaAI : public ScriptedAI
+{
+ boss_keristraszaAI(Creature *c) : ScriptedAI(c) {}
+
+ bool enraged;
+
+ void Reset()
+ {
+ enraged = false;
+ }
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) == 10)
+ {
+ if(!enraged)
+ {
+ DoScriptText(SAY_ENRAGE, m_creature);
+ DoCast(m_creature, SPELL_ENRAGE);
+ enraged = true;
+ }
+ }
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ DoScriptText(SAY_SLAY, m_creature);
+ }
+};
+
+CreatureAI* GetAI_boss_keristrasza(Creature *_Creature)
+{
+ return new boss_keristraszaAI (_Creature);
+}
+
+void AddSC_boss_keristrasza()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_keristrasza";
+ newscript->GetAI = GetAI_boss_keristrasza;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/nexus/boss_magus_telestra.cpp b/src/bindings/scripts/scripts/zone/nexus/nexus/boss_magus_telestra.cpp
new file mode 100644
index 00000000000..0d97b530376
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/nexus/boss_magus_telestra.cpp
@@ -0,0 +1,118 @@
+/* Script Data Start
+SDName: Boss magus_telestra
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+#include "def_nexus.h"
+
+
+//Spells
+
+//phase 1
+#define SPELL_ICE_NOVA 47772
+#define SPELL_ICE_NOVA 56935
+#define SPELL_FIREBOMB 47773
+#define SPELL_FIREBOMB 56934
+#define SPELL_GAVITY_WELL 47756
+
+//Phase 2 -->50% HP (3 clones, Frost, Fire, Arcane)
+//Frost Magus (npc 26930)
+#define FROST_MAGUS_VISUAL 47706 //Dummy
+#define SPELL_BLIZZARD_N 47727
+#define SPELL_ICE_BARB_N 47729
+//heroic
+#define SPELL_BLIZZARD_H 56936
+#define SPELL_ICE_BARB_H 56937
+
+//Fire Magus (npc 26928)
+#define FIRE_MAGUS_VISUAL 47705 //Dummy
+#define SPELL_FIRE_BLAST 47721
+#define SPELL_SCORCH 47723
+//heroic
+#define SPELL_FIRE_BLAST_H 56939
+#define SPELL_SCORCH_H 56938
+
+//Arcane Magus (npc 26929)
+#define ARCANE_MAGUS_VISUAL 47704 //Dummy
+#define SPELL_CRITTER 47731
+#define SPELL_TIME_STOP 47736
+
+//Yell
+#define SAY_AGGRO -1576010
+#define SAY_KILL -1576011
+#define SAY_DEATH -1576012
+#define SAY_MERGE -1576013
+#define SAY_SPLIT_1 -1576014
+#define SAY_SPLIT_2 -1576015
+
+
+struct TRINITY_DLL_DECL boss_magus_telestraAI : public ScriptedAI
+{
+ boss_magus_telestraAI(Creature *c) : ScriptedAI(c) {}
+
+ bool splited;
+ uint64 Magus_frost,
+ Magus_fire,
+ Magus_arcane;
+
+ void Reset()
+ {
+ splited = false;
+ }
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ if(!splited)
+ {
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) <= 50)
+ {
+ DoScriptText(SAY_SPLIT_1, m_creature);
+ //HandleSplit
+ splited = true;
+ }
+ }
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ DoScriptText(SAY_KILL, m_creature);
+ }
+};
+
+CreatureAI* GetAI_boss_magus_telestra(Creature *_Creature)
+{
+ return new boss_magus_telestraAI (_Creature);
+}
+
+void AddSC_boss_magus_telestra()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_magus_telestra";
+ newscript->GetAI = GetAI_boss_magus_telestra;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/nexus/boss_ormorok.cpp b/src/bindings/scripts/scripts/zone/nexus/nexus/boss_ormorok.cpp
new file mode 100644
index 00000000000..d4dcbae6616
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/nexus/boss_ormorok.cpp
@@ -0,0 +1,90 @@
+/* Script Data Start
+SDName: Boss ormorok
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_CRYSTAL_SPIKES_1 47958
+#define SPELL_CRYSTAL_SPIKES_2 57082
+#define SPELL_CRYSTAL_SPIKES_3 57083
+#define SPELL_SPELL_REFLECTION 47981
+#define SPELL_TRAMPLE_N 48016
+#define SPELL_TRAMPLE_H 57066
+#define SPELL_FRENZY_N 48017
+#define SPELL_FRENZY_H 57086
+#define SPELL_SUMMON_CRYSTALLINE_TANGLER 61564 //summons npc 32665
+
+//Yell
+#define SAY_AGGRO -1576016
+#define SAY_KILL -1576017
+#define SAY_DEATH -1576018
+#define SAY_REFLECT -1576019
+#define SAY_ICE_SPIKES -1576020
+
+struct TRINITY_DLL_DECL boss_ormorokAI : public ScriptedAI
+{
+ boss_ormorokAI(Creature *c) : ScriptedAI(c) {}
+
+ bool frenzy;
+
+ void Reset()
+ {
+ frenzy = false;
+ }
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) == 25)
+ {
+ if(!frenzy)
+ {
+ DoCast(m_creature, SPELL_FRENZY_N);
+ frenzy = true;
+ }
+ }
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ DoScriptText(SAY_KILL, m_creature);
+ }
+};
+
+CreatureAI* GetAI_boss_ormorok(Creature *_Creature)
+{
+ return new boss_ormorokAI (_Creature);
+}
+
+void AddSC_boss_ormorok()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_ormorok";
+ newscript->GetAI = GetAI_boss_ormorok;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/nexus/commander_kolurg.cpp b/src/bindings/scripts/scripts/zone/nexus/nexus/commander_kolurg.cpp
new file mode 100644
index 00000000000..b8715fb6d7d
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/nexus/commander_kolurg.cpp
@@ -0,0 +1,57 @@
+/* Script Data Start
+SDName: Boss Commander Kolurg
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment: Only Alliance Heroic
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_commander_kolurg' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+#define SPELL_BATTLE_SHOUT 31403
+#define SPELL_CHARGE 60067
+#define SPELL_FRIGHTENING_SHOUT 19134
+#define SPELL_WHIRLWIND_1 38619
+#define SPELL_WHIRLWIND_2 38618
+
+//Yell
+#define SAY_AGGRO 1576024
+#define SAY_KILL 1576025
+#define SAY_DEATH 1576026
+
+struct TRINITY_DLL_DECL boss_commander_kolurgAI : public ScriptedAI
+{
+ boss_commander_kolurgAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+CreatureAI* GetAI_boss_commander_kolurg(Creature *_Creature)
+{
+ return new boss_commander_kolurgAI (_Creature);
+}
+
+void AddSC_boss_commander_kolurg()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_commander_kolurg";
+ newscript->GetAI = GetAI_boss_commander_kolurg;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/nexus/commander_stoutbeard.cpp b/src/bindings/scripts/scripts/zone/nexus/nexus/commander_stoutbeard.cpp
new file mode 100644
index 00000000000..26ef1fc5f97
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/nexus/commander_stoutbeard.cpp
@@ -0,0 +1,63 @@
+/* Script Data Start
+SDName: Boss Commander Stoutbeard
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment: Only Horde Heroic
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_commander_stoutbeard' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+#define SPELL_BATTLE_SHOUT 31403
+#define SPELL_CHARGE 60067
+#define SPELL_FRIGHTENING_SHOUT 19134
+#define SPELL_WHIRLWIND_1 38619
+#define SPELL_WHIRLWIND_2 38618
+
+//Yell
+#define SAY_AGGRO 1576021
+#define SAY_KILL 1576022
+#define SAY_DEATH 1576023
+
+struct TRINITY_DLL_DECL boss_commander_stoutbeardAI : public ScriptedAI
+{
+ boss_commander_stoutbeardAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+};
+
+CreatureAI* GetAI_boss_commander_stoutbeard(Creature *_Creature)
+{
+ return new boss_commander_stoutbeardAI (_Creature);
+}
+
+void AddSC_boss_commander_stoutbeard()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_commander_stoutbeard";
+ newscript->GetAI = GetAI_boss_commander_stoutbeard;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/nexus/def_nexus.h b/src/bindings/scripts/scripts/zone/nexus/nexus/def_nexus.h
new file mode 100644
index 00000000000..d868c72adf6
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/nexus/def_nexus.h
@@ -0,0 +1,35 @@
+#ifndef DEF_NEXUS_H
+#define DEF_NEXUS_H
+
+#define DATA_ANOMALUSDEAD 1
+#define DATA_ANOMALUS_DEATH 2
+#define DATA_ORMOROKDDEAD 3
+#define DATA_ORMOROK_DEATH 4
+
+#define DATA_MAGUSTELESTRADEAD 5
+#define DATA_MAGUSTELESTRA_DEATH 6
+#define DATA_MAGUSTELESTRA_A_DEAD 7
+#define DATA_MAGUSTELESTRA_A_DEATH 8
+#define DATA_MAGUSTELESTRA_F_DEAD 9
+#define DATA_MAGUSTELESTRA_F_DEATH 10
+#define DATA_MAGUSTELESTRA_FI_DEAD 11
+#define DATA_MAGUSTELESTRA_FI_DEATH 12
+
+#define DATA_KERISTRASZADEAD 13
+#define DATA_KERISTRASZA_DEATH 14
+#define DATA_COMMANDER_KOLURGDEAD 15
+#define DATA_COMMANDER_KOLURG_DEATH 16
+#define DATA_COMMANDER_STOUTBEARDDEAD 17
+#define DATA_COMMANDER_STOUTBEARD_DEATH 18
+#define DATA_ANOMALUS 19
+#define DATA_ORMOROK 20
+
+#define DATA_MAGUSTELESTRA 21
+#define DATA_MAGUSTELESTRA_A 22
+#define DATA_MAGUSTELESTRA_F 23
+#define DATA_MAGUSTELESTRA_FI 24
+
+#define DATA_KERISTRASZA 25
+#define DATA_COMMANDER_KOLURG 26
+#define DATA_COMMANDER_STOUTBEARD 27
+#endif
diff --git a/src/bindings/scripts/scripts/zone/nexus/nexus/instance_nexus.cpp b/src/bindings/scripts/scripts/zone/nexus/nexus/instance_nexus.cpp
new file mode 100644
index 00000000000..7f07b372be9
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/nexus/instance_nexus.cpp
@@ -0,0 +1,158 @@
+#include "precompiled.h"
+#include "def_nexus.h"
+
+struct TRINITY_DLL_DECL instance_nexus : public ScriptedInstance
+{
+ instance_nexus(Map *Map) : ScriptedInstance(Map) {Initialize();};
+
+ uint64 Anomalus,
+ Ormorok,
+ Magus_telestra,
+ Magus_frost,
+ Magus_fire,
+ Magus_arcane,
+ keristrasza,
+ Commander_kolurg,
+ Commander_stoutbeard;
+ bool IsBossDied[9];
+
+ void Initialize()
+ {
+ Anomalus = 0;
+ Ormorok = 0;
+ Magus_telestra =0;
+ Magus_frost =0;
+ Magus_fire =0;
+ Magus_arcane =0;
+ keristrasza =0;
+ Commander_kolurg = 0;
+ Commander_stoutbeard = 0;
+ IsBossDied[0] = false;
+ IsBossDied[1] = false;
+ IsBossDied[2] = false;
+ IsBossDied[3] = false;
+ IsBossDied[4] = false;
+ IsBossDied[5] = false;
+ IsBossDied[6] = false;
+ IsBossDied[7] = false;
+ IsBossDied[8] = false;
+ }
+
+ bool IsEncounterInProgress() const
+ {
+ //not active
+ return false;
+ }
+ void OnCreatureCreate(Creature *creature, uint32 creature_entry)
+ {
+ switch(creature->GetEntry())
+ {
+ case 26763: Anomalus = creature->GetGUID(); break;
+ case 26794: Ormorok = creature->GetGUID(); break;
+ case 26731: Magus_telestra = creature->GetGUID(); break;
+ case 26930: Magus_frost = creature->GetGUID(); break;
+ case 26928: Magus_fire = creature->GetGUID(); break;
+ case 26926: Magus_arcane = creature->GetGUID(); break;
+ case 26723: keristrasza = creature->GetGUID(); break;
+ case 26798: Commander_kolurg = creature->GetGUID(); break;
+ case 26796: Commander_stoutbeard = creature->GetGUID(); break;
+ }
+ }
+ uint32 GetData(uint32 type)
+ {
+ switch(type)
+ {
+ case DATA_ANOMALUSDEAD:
+ if(IsBossDied[0])
+ return 1;
+ break;
+ case DATA_ORMOROKDDEAD:
+ if(IsBossDied[1])
+ return 1;
+ break;
+ case DATA_MAGUSTELESTRADEAD:
+ if(IsBossDied[2])
+ return 1;
+ break;
+ case DATA_MAGUSTELESTRA_A_DEAD:
+ if(IsBossDied[3])
+ return 1;
+ break;
+ case DATA_MAGUSTELESTRA_F_DEAD:
+ if(IsBossDied[4])
+ return 1;
+ break;
+ case DATA_MAGUSTELESTRA_FI_DEAD:
+ if(IsBossDied[5])
+ return 1;
+ break;
+ case DATA_KERISTRASZADEAD:
+ if(IsBossDied[6])
+ return 1;
+ break;
+ case DATA_COMMANDER_KOLURGDEAD:
+ if(IsBossDied[7])
+ return 1;
+ break;
+ case DATA_COMMANDER_STOUTBEARDDEAD:
+ if(IsBossDied[8])
+ return 1;
+ break;
+ }
+
+ return 0;
+ }
+
+ uint64 GetData64 (uint32 identifier)
+ {
+ return 0;
+ }
+
+ void SetData(uint32 type, uint32 data)
+ {
+ switch(type)
+ {
+ case DATA_ANOMALUS_DEATH:
+ IsBossDied[0] = true;
+ break;
+ case DATA_ORMOROK_DEATH:
+ IsBossDied[1] = true;
+ break;
+ case DATA_MAGUSTELESTRA_DEATH:
+ IsBossDied[2] = true;
+ break;
+ case DATA_MAGUSTELESTRA_A_DEATH:
+ IsBossDied[3] = true;
+ break;
+ case DATA_MAGUSTELESTRA_F_DEATH:
+ IsBossDied[4] = true;
+ break;
+ case DATA_MAGUSTELESTRA_FI_DEAD:
+ IsBossDied[5] = true;
+ break;
+ case DATA_KERISTRASZA_DEATH:
+ IsBossDied[6] = true;
+ break;
+ case DATA_COMMANDER_KOLURG_DEATH:
+ IsBossDied[7] = true;
+ break;
+ case DATA_COMMANDER_STOUTBEARD_DEATH:
+ IsBossDied[8] = true;
+ break;
+ }
+ }
+};
+
+InstanceData* GetInstanceData_instance_nexus(Map* map)
+{
+ return new instance_nexus(map);
+}
+
+void AddSC_instance_nexus()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_nexus";
+ newscript->GetInstanceData = GetInstanceData_instance_nexus;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/oculus/boss_drakos.cpp b/src/bindings/scripts/scripts/zone/nexus/oculus/boss_drakos.cpp
new file mode 100644
index 00000000000..eca9760262c
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/oculus/boss_drakos.cpp
@@ -0,0 +1,82 @@
+/* Script Data Start
+SDName: Boss drakos
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_MAGIC_PULL 51336
+#define SPELL_THUNDERING_STOMP 50774
+#define SPELL_THUNDERING_STOMP_2 59370
+
+//Yell
+#define SAY_AGGRO -1578000
+#define SAY_KILL_1 -1578001
+#define SAY_KILL_2 -1578002
+#define SAY_KILL_3 -1578003
+#define SAY_DEATH -1578004
+#define SAY_PULL_1 -1578005
+#define SAY_PULL_2 -1578006
+#define SAY_PULL_3 -1578007
+#define SAY_PULL_4 -1578008
+#define SAY_STOMP_1 -1578009
+#define SAY_STOMP_2 -1578010
+#define SAY_STOMP_3 -1578011
+
+struct TRINITY_DLL_DECL boss_drakosAI : public ScriptedAI
+{
+ boss_drakosAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_KILL_1, m_creature);break;
+ case 1: DoScriptText(SAY_KILL_2, m_creature);break;
+ case 2: DoScriptText(SAY_KILL_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_drakos(Creature *_Creature)
+{
+ return new boss_drakosAI (_Creature);
+}
+
+void AddSC_boss_drakos()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_drakos";
+ newscript->GetAI = GetAI_boss_drakos;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/oculus/boss_eregos.cpp b/src/bindings/scripts/scripts/zone/nexus/oculus/boss_eregos.cpp
new file mode 100644
index 00000000000..abfa904beb6
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/oculus/boss_eregos.cpp
@@ -0,0 +1,104 @@
+/* Script Data Start
+SDName: Boss eregos
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment: Encounter is done entirely on drake vehicles
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Types of drake mounts: Ruby(Tank), Amber(DPS), Emerald(Healer)
+//Two Repeating phases
+
+//Spells
+#define SPELL_ARCANE_BARRAGE 50804
+#define SPELL_ARCANE_VOLLEY 51153
+#define SPELL_ENRAGED_ASSAULT 51170
+#define SPELL_PLANAR_ANOMALIES 57959
+#define SPELL_PLANAR_SHIFT 51162
+
+//Heroic
+#define SPELL_ARCANE_BARRAGE_H 59381
+#define SPELL_ARCANE_VOLLEY_H 59382
+
+/*Ruby Drake ,
+(npc 27756) (item 37860)
+(summoned by spell Ruby Essence = 37860 ---> Call Amber Drake == 49462 ---> Summon 27756)
+*/
+#define NPC_RUBY_DRAKE_VEHICLE 27756
+#define SPELL_RIDE_RUBY_DRAKE_QUE 49463 //Apply Aura: Periodic Trigger, Interval: 3 seconds ---> 49464
+#define SPELL_RUBY_DRAKE_SADDLE 49464 //Allows you to ride on the back of an Amber Drake. ---> Dummy
+
+#define SPELL_RUBY_SEARING_WRATH 50232 //(60 yds) - Instant - Breathes a stream of fire at an enemy dragon, dealing 6800 to 9200 Fire damage and then jumping to additional dragons within 30 yards. Each jump increases the damage by 50%. Affects up to 5 total targets
+#define SPELL_RUBY_EVASIVE_AURA 50248 //Instant - Allows the Ruby Drake to generate Evasive Charges when hit by hostile attacks and spells.
+#define SPELL_RUBY_EVASIVE_MANEUVERS 50240 //Instant - 5 sec. cooldown - Allows your drake to dodge all incoming attacks and spells. Requires Evasive Charges to use. Each attack or spell dodged while this ability is active burns one Evasive Charge. Lasts 30 sec. or until all charges are exhausted.
+//you do not have acces to until you kill Mage-Lord Urom
+#define SPELL_RUBY_MARTYR 50253 //Instant - 10 sec. cooldown - Redirect all harmful spells cast at friendly drakes to yourself for 10 sec.
+
+/*Amber Drake,
+(npc 27755) (item 37859)
+(summoned by spell Amber Essence = 37859 ---> Call Amber Drake == 49461 ---> Summon 27755)
+*/
+#define NPC_AMBER_DRAKE_VEHICLE 27755
+#define SPELL_RIDE_AMBER_DRAKE_QUE 49459 //Apply Aura: Periodic Trigger, Interval: 3 seconds ---> 49460
+#define SPELL_AMBER_DRAKE_SADDLE 49460 //Allows you to ride on the back of an Amber Drake. ---> Dummy
+
+#define SPELL_AMBER_SHOCK_LANCE 49840 //(60 yds) - Instant - Deals 4822 to 5602 Arcane damage and detonates all Shock Charges on an enemy dragon. Damage is increased by 6525 for each detonated.
+#define SPELL_AMBER_STOP_TIME //Instant - 1 min cooldown - Halts the passage of time, freezing all enemy dragons in place for 10 sec. This attack applies 5 Shock Charges to each affected target.
+//you do not have access to until you kill the Mage-Lord Urom.
+#define SPELL_AMBER_TEMPORAL_RIFT 49592 //(60 yds) - Channeled - Channels a temporal rift on an enemy dragon for 10 sec. While trapped in the rift, all damage done to the target is increased by 100%. In addition, for every 15,000 damage done to a target affected by Temporal Rift, 1 Shock Charge is generated.
+
+/*Emerald Drake,
+(npc 27692) (item 37815),
+ (summoned by spell Emerald Essence = 37815 ---> Call Emerald Drake == 49345 ---> Summon 27692)
+*/
+#define NPC_EMERALD_DRAKE_VEHICLE 27692
+#define SPELL_RIDE_EMERALD_DRAKE_QUE 49427 //Apply Aura: Periodic Trigger, Interval: 3 seconds ---> 49346
+#define SPELL_EMERALD_DRAKE_SADDLE 49346 //Allows you to ride on the back of an Amber Drake. ---> Dummy
+
+#define SPELL_EMERALD_LEECHING_POISON 50328 //(60 yds) - Instant - Poisons the enemy dragon, leeching 1300 to the caster every 2 sec. for 12 sec. Stacks up to 3 times.
+#define SPELL_EMERALD_TOUCH_THE_NIGHTMARE 50341 //(60 yds) - Instant - Consumes 30% of the caster's max health to inflict 25,000 nature damage to an enemy dragon and reduce the damage it deals by 25% for 30 sec.
+// you do not have access to until you kill the Mage-Lord Urom
+#define SPELL_EMERALD_DREAM_FUNNEL 50344 //(60 yds) - Channeled - Transfers 5% of the caster's max health to a friendly drake every second for 10 seconds as long as the caster channels.
+
+struct TRINITY_DLL_DECL boss_eregosAI : public ScriptedAI
+{
+ boss_eregosAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 phase;
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ phase =1;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+CreatureAI* GetAI_boss_eregos(Creature *_Creature)
+{
+ return new boss_eregosAI (_Creature);
+}
+
+void AddSC_boss_eregos()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_eregos";
+ newscript->GetAI = GetAI_boss_eregos;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/oculus/boss_urom.cpp b/src/bindings/scripts/scripts/zone/nexus/oculus/boss_urom.cpp
new file mode 100644
index 00000000000..f7d35d014dd
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/oculus/boss_urom.cpp
@@ -0,0 +1,87 @@
+/* Script Data Start
+SDName: Boss urom
+SDAuthor: LordVanMartin
+SD%Complete: 1%
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_ARCANE_SHIELD 53813 //Dummy --> Channeled, shields the caster from damage.
+#define SPELL_EMPOWERED_ARCANE_EXPLOSION 51110
+#define SPELL_EMPOWERED_ARCANE_EXPLOSION_2 59377
+#define SPELL_FROSTBOMB 51103 //Urom throws a bomb, hitting its target with the highest aggro which inflict directly 650 frost damage and drops a frost zone on the ground. This zone deals 650 frost damage per second and reduce the movement speed by 35%. Lasts 1 minute.
+#define SPELL_SUMMON_MENAGERIE 50476 //Summons an assortment of creatures and teleports the caster to safety.
+#define SPELL_SUMMON_MENAGERIE_2 50495
+#define SPELL_SUMMON_MENAGERIE_3 50496
+#define SPELL_TELEPORT 51112 //Teleports to the center of Oculus
+#define SPELL_TIME_BOMB 51121 //Deals arcane damage to a random player, and after 6 seconds, deals zone damage to nearby equal to the health missing of the target afflicted by the debuff.
+#define SPELL_TIME_BOMB_2 59376
+
+//Yell
+#define SAY_AGGRO -1578012
+#define SAY_KILL_1 -1578013
+#define SAY_KILL_2 -1578014
+#define SAY_KILL_3 -1578015
+#define SAY_DEATH -1578016
+#define SAY_EXPLOSION_1 -1578017
+#define SAY_EXPLOSION_2 -1578018
+#define SAY_SUMMON_1 -1578019
+#define SAY_SUMMON_2 -1578020
+#define SAY_SUMMON_3 -1578021
+
+struct TRINITY_DLL_DECL boss_uromAI : public ScriptedAI
+{
+ boss_uromAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_KILL_1, m_creature);break;
+ case 1: DoScriptText(SAY_KILL_2, m_creature);break;
+ case 2: DoScriptText(SAY_KILL_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_urom(Creature *_Creature)
+{
+ return new boss_uromAI (_Creature);
+}
+
+void AddSC_boss_urom()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_urom";
+ newscript->GetAI = GetAI_boss_urom;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/oculus/boss_varos.cpp b/src/bindings/scripts/scripts/zone/nexus/oculus/boss_varos.cpp
new file mode 100644
index 00000000000..272196008f2
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/oculus/boss_varos.cpp
@@ -0,0 +1,85 @@
+/* Script Data Start
+SDName: Boss varos
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_ENERGIZE_CORES 50785 //Damage 5938 to 6562, effec2 Triggers 54069, effect3 Triggers 56251
+#define SPELL_ENERGIZE_CORES_TRIGGER_1 54069
+#define SPELL_ENERGIZE_CORES_TRIGGER_2 56251
+#define SPELL_ENERGIZE_CORES_2 59372 //Damage 9025 to 9975, effect2 Triggers 54069, effect 56251
+#define SPELL_CALL_AZURE_RING_CAPTAIN 51002 //Effect Send Event (12229)
+#define SPELL_CALL_AZURE_RING_CAPTAIN_2 51006 //Effect Send Event (10665)
+#define SPELL_CALL_AZURE_RING_CAPTAIN_3 51007 //Effect Send Event (18454)
+#define SPELL_CALL_AZURE_RING_CAPTAIN_4 51008 //Effect Send Event (18455)
+#define SPELL_CALL_AMPLIFY_MAGIC 51054
+#define SPELL_CALL_AMPLIFY_MAGIC_2 59371
+
+//Yell
+#define SAY_AGGRO -1578022
+#define SAY_KILL_1 -1578023
+#define SAY_KILL_2 -1578024
+#define SAY_DEATH -1578025
+#define SAY_STRIKE_1 -1578026
+#define SAY_STRIKE_2 -1578027
+#define SAY_STRIKE_3 -1578028
+#define SAY_SPAWN -1578029
+
+
+struct TRINITY_DLL_DECL boss_varosAI : public ScriptedAI
+{
+ boss_varosAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%2)
+ {
+ case 0: DoScriptText(SAY_KILL_1, m_creature);break;
+ case 1: DoScriptText(SAY_KILL_2, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_varos(Creature *_Creature)
+{
+ return new boss_varosAI (_Creature);
+}
+
+void AddSC_boss_varos()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_varos";
+ newscript->GetAI = GetAI_boss_varos;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/nexus/oculus/def_oculus.h b/src/bindings/scripts/scripts/zone/nexus/oculus/def_oculus.h
new file mode 100644
index 00000000000..0b63a52d866
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/oculus/def_oculus.h
@@ -0,0 +1,4 @@
+#ifndef DEF_OCULUS_H
+#define DEF_OCULUS_H
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/nexus/oculus/instance_oculus.cpp b/src/bindings/scripts/scripts/zone/nexus/oculus/instance_oculus.cpp
new file mode 100644
index 00000000000..ecf6bcfae89
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/nexus/oculus/instance_oculus.cpp
@@ -0,0 +1,21 @@
+#include "precompiled.h"
+#include "def_oculus.h"
+
+struct TRINITY_DLL_DECL instance_oculus : public ScriptedInstance
+{
+ instance_oculus(Map *Map) : ScriptedInstance(Map) {Initialize();};
+};
+
+InstanceData* GetInstanceData_instance_oculus(Map* map)
+{
+ return new instance_oculus(map);
+}
+
+void AddSC_instance_oculus()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_oculus";
+ newscript->GetInstanceData = GetInstanceData_instance_oculus;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/obsidian_sanctum/boss_sartharion.cpp b/src/bindings/scripts/scripts/zone/obsidian_sanctum/boss_sartharion.cpp
new file mode 100644
index 00000000000..73e6157c600
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/obsidian_sanctum/boss_sartharion.cpp
@@ -0,0 +1,300 @@
+/* Script Data Start
+SDName: Boss sartharion
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Sartharion Spells
+#define SPELL_BERSERK 61632 // Increases the caster's attack speed by 150% and all damage it deals by 500% for 5 min.
+#define SPELL_CLEAVE 56909 // Inflicts 35% weapon damage to an enemy and its nearest allies, affecting up to 10 targets.
+#define SPELL_FLAME_BREATH_N 56908 // Inflicts 8750 to 11250 Fire damage to enemies in a cone in front of the caster.
+#define SPELL_FLAME_BREATH_H 58956 // Inflicts 10938 to 14062 Fire damage to enemies in a cone in front of the caster.
+#define SPELL_TAIL_LASH_N 56910 // A sweeping tail strike hits all enemies behind the caster, inflicting 3063 to 3937 damage and stunning them for 2 sec.
+#define SPELL_TAIL_LASH_H 58957 // A sweeping tail strike hits all enemies behind the caster, inflicting 4375 to 5625 damage and stunning them for 2 sec.
+#define SPELL_WILL_OF_SARTHARION 61254 // Sartharion's presence bolsters the resolve of the Twilight Drakes, increasing their total health by 25%. This effect also increases Sartharion's health by 25%.
+#define SPELL_POWER_OF_SARTHARION 61254 //Shadron's presence increases Fire damage taken by all enemies by 100%.
+
+//Sartharion Yell
+#define SAY_SARTHARION_AGGRO -1615016
+#define SAY_SARTHARION_BERSERK -1615017
+#define SAY_SARTHARION_BREATH -1615018
+#define SAY_SARTHARION_CALL_SHADRON -1615019
+#define SAY_SARTHARION_CALL_TENEBRON -1615020
+#define SAY_SARTHARION_CALL_VESPERON -1615021
+#define SAY_SARTHARION_DEATH -1615022
+#define SAY_SARTHARION_SPECIAL_1 -1615023
+#define SAY_SARTHARION_SPECIAL_2 -1615024
+#define SAY_SARTHARION_SPECIAL_3 -1615025
+#define SAY_SARTHARION_SPECIAL_4 -1615026
+#define SAY_SARTHARION_SLAY_1 -1615027
+#define SAY_SARTHARION_SLAY_2 -1615028
+#define SAY_SARTHARION_SLAY_3 -1615029
+
+//Miniboses (Vesperon, Shadron, Tenebron)
+#define SPELL_SHADOW_BREATH_H 59126 //Inflicts 8788 to 10212 Fire damage to enemies in a cone in front of the caster.
+#define SPELL_SHADOW_BREATH_N 57570 //Inflicts 6938 to 8062 Fire damage to enemies in a cone in front of the caster.
+//TAIL LASH the same as Sartharion's
+#define SPELL_SHADOW_FISSURE_H 59127 //Deals 9488 to 13512 Shadow damage to any enemy within the Shadow fissure after 5 sec.
+#define SPELL_SHADOW_FISSURE_N 57579 //Deals 6188 to 8812 Shadow damage to any enemy within the Shadow fissure after 5 sec.
+
+//Vesperon
+#define MINIBOSS_VESPERON 30449 //npc 30449 //In portal is a disciple, when disciple killed remove Power_of_vesperon, portal spawns multiple times
+#define BUFF_POWER_OF_VESPERON 61251 //Vesperon's presence decreases the maximum health of all enemies by 25%.
+
+//Shadron
+#define MINIBOSS_SHADRON 30451 //npc 30451 //In portal is a disciple, when disciple killed remove Power_of_vesperon, portal spawns multiple times
+#define BUFF_POWER_OF_SHADRON 58105 //Shadron's presence increases Fire damage taken by all enemies by 100%.
+
+//Tenebron
+#define MINIBOSS_TENEBRON 30452 //npc 30452 //in the portal spawns 6 eggs, if not killed in time (approx. 20s) they will hatch, whelps can cast 60708
+#define BUFF_POWER_OF_TENEBRON 61248 //Tenebron's presence increases Shadow damage taken by all enemies by 100%.
+
+//Minibosses common spells
+#define SPELL_SHADOW_BREATH_N 57570
+#define SPELL_SHADOW_BREATH_H 59126
+#define SPELL_SHADOW_FISSURE_N 57579
+#define SPELL_SHADOW_FISSURE_H 59127
+#define SPELL_TWILIGHT_REVENGE 60639
+
+//Tenebron, dummy spell
+#define SPELL_HATCH_EGGS 58793
+
+//Whelps
+#define TWILIGHT_WHELP 30890 //npc 30890
+#define SHARTHARION_TWILIGHT_WHELP 31214 //npc 31214
+#define SPELL_FADE_ARMOR 60708 //Reduces the armor of an enemy by 1500 for 15s
+
+/*Summons a portal, which all DPS and one healer should go through and proceed to kill all eggs. After about 20 seconds these eggs will hatch into whelplings with 60k health. Whelplings that hatched should be picked up by a tank and killed.
+Hatch Eggs Tenebron summons a portal in which eggs are spawned. After about 20s the eggs hatches into Whelps (156,396 hp - amount of whelps determined by Normal or Heroic mode) that do Fade Armor. */
+
+struct TRINITY_DLL_DECL boss_sartharionAI : public ScriptedAI
+{
+ boss_sartharionAI(Creature *c) : ScriptedAI(c) {}
+
+ bool berserk;
+
+ void Reset()
+ {
+ berserk = false;
+ }
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_SARTHARION_DEATH,m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ if ((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) <= 10)
+ {
+ if(!berserk){
+ DoCast(m_creature,SPELL_BERSERK);
+ berserk = true;
+ }
+ }
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_SARTHARION_DEATH,m_creature);
+ }
+};
+
+/*######
+## Mob Vesperon
+######*/
+
+//Vesperon Yell
+#define SAY_VESPERON_AGGRO -1615030
+#define SAY_VESPERON_SLAY_1 -1615031
+#define SAY_VESPERON_SLAY_2 -1615032
+#define SAY_VESPERON_DEATH -1615033
+#define SAY_VESPERON_BREATH -1615034
+#define SAY_VESPERON_RESPOND -1615035
+#define SAY_VESPERON_SPECIAL_1 -1615036
+#define SAY_VESPERON_SPECIAL_2 -1615037
+
+struct TRINITY_DLL_DECL mob_vesperonAI : public ScriptedAI
+{
+ mob_vesperonAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_VESPERON_AGGRO,m_creature);
+ }
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_VESPERON_DEATH,m_creature);
+ }
+};
+
+/*######
+## Mob Shadron
+######*/
+
+//Shadron Yell
+#define SAY_SHADRON_AGGRO -1615000
+#define SAY_SHADRON_SLAY_1 -1615001
+#define SAY_SHADRON_SLAY_2 -1615002
+#define SAY_SHADRON_DEATH -1615003
+#define SAY_SHADRON_BREATH -1615004
+#define SAY_SHADRON_RESPOND -1615005
+#define SAY_SHADRON_SPECIAL_1 -1615006
+#define SAY_SHADRON_SPECIAL_2 -1615007
+
+struct TRINITY_DLL_DECL mob_shadronAI : public ScriptedAI
+{
+ mob_shadronAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset(){}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_SHADRON_AGGRO,m_creature);
+ }
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_SHADRON_DEATH,m_creature);
+ }
+};
+/*######
+## Mob Tenebron
+######*/
+
+//Yell
+#define SAY_TENEBRON_AGGRO -1615008
+#define SAY_TENEBRON_SLAY_1 -1615009
+#define SAY_TENEBRON_SLAY_2 -1615010
+#define SAY_TENEBRON_DEATH -1615011
+#define SAY_TENEBRON_BREATH -1615012
+#define SAY_TENEBRON_RESPOND -1615013
+#define SAY_TENEBRON_SPECIAL_1 -1615014
+#define SAY_TENEBRON_SPECIAL_2 -1615015
+
+struct TRINITY_DLL_DECL mob_tenebronAI : public ScriptedAI
+{
+ mob_tenebronAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_TENEBRON_AGGRO,m_creature);
+ }
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_TENEBRON_DEATH,m_creature);
+ }
+};
+
+/*######
+## Mob Whelps
+######*/
+struct TRINITY_DLL_DECL mob_whelpAI : public ScriptedAI
+{
+ mob_whelpAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 Fade_armor_Timer;
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+CreatureAI* GetAI_mob_whelp(Creature *_Creature)
+{
+ return new mob_whelpAI (_Creature);
+}
+
+CreatureAI* GetAI_mob_tenebron(Creature *_Creature)
+{
+ return new mob_tenebronAI (_Creature);
+}
+
+CreatureAI* GetAI_mob_shadron(Creature *_Creature)
+{
+ return new mob_shadronAI (_Creature);
+}
+
+CreatureAI* GetAI_mob_vesperon(Creature *_Creature)
+{
+ return new mob_vesperonAI (_Creature);
+}
+
+CreatureAI* GetAI_boss_sartharion(Creature *_Creature)
+{
+ return new boss_sartharionAI (_Creature);
+}
+
+void AddSC_boss_sartharion()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_sartharion";
+ newscript->GetAI = GetAI_boss_sartharion;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="mob_vesperon";
+ newscript->GetAI = GetAI_mob_vesperon;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="mob_shadron";
+ newscript->GetAI = GetAI_mob_shadron;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="mob_tenebron";
+ newscript->GetAI = GetAI_mob_tenebron;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="mob_whelp";
+ newscript->GetAI = GetAI_mob_whelp;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/obsidian_sanctum/def_obsidian_sanctum.h b/src/bindings/scripts/scripts/zone/obsidian_sanctum/def_obsidian_sanctum.h
new file mode 100644
index 00000000000..59d76502af3
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/obsidian_sanctum/def_obsidian_sanctum.h
@@ -0,0 +1,4 @@
+#ifndef DEF_OBSIDIAN_SANCTUM_H
+#define DEF_OBSIDIAN_SANCTUM_H
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/obsidian_sanctum/instance_obsidian_sanctum.cpp b/src/bindings/scripts/scripts/zone/obsidian_sanctum/instance_obsidian_sanctum.cpp
new file mode 100644
index 00000000000..2e24a1ae415
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/obsidian_sanctum/instance_obsidian_sanctum.cpp
@@ -0,0 +1,21 @@
+#include "precompiled.h"
+#include "def_obsidian_sanctum.h"
+
+struct TRINITY_DLL_DECL instance_obsidian_sanctum : public ScriptedInstance
+{
+ instance_obsidian_sanctum(Map *Map) : ScriptedInstance(Map) {Initialize();};
+};
+
+InstanceData* GetInstanceData_instance_obsidian_sanctum(Map* map)
+{
+ return new instance_obsidian_sanctum(map);
+}
+
+void AddSC_instance_obsidian_sanctum()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_obsidian_sanctum";
+ newscript->GetInstanceData = GetInstanceData_instance_obsidian_sanctum;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/onyxias_lair/boss_onyxia.cpp b/src/bindings/scripts/scripts/zone/onyxias_lair/boss_onyxia.cpp
index eef29518ecd..9e2370af086 100644
--- a/src/bindings/scripts/scripts/zone/onyxias_lair/boss_onyxia.cpp
+++ b/src/bindings/scripts/scripts/zone/onyxias_lair/boss_onyxia.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -125,7 +125,6 @@ struct TRINITY_DLL_DECL boss_onyxiaAI : public ScriptedAI
if(((m_creature->GetHealth()*100 / m_creature->GetMaxHealth()) < 60) && (Phase == 1))
{
Phase = 2;
- m_creature->HandleEmoteCommand(EMOTE_ONESHOT_LIFTOFF);
m_creature->AddUnitMovementFlag(MOVEMENTFLAG_LEVITATING + MOVEMENTFLAG_ONTRANSPORT);
m_creature->SetHover(true);
m_creature->GetMotionMaster()->Clear(false);
@@ -137,7 +136,6 @@ struct TRINITY_DLL_DECL boss_onyxiaAI : public ScriptedAI
{
Phase = 3;
m_creature->RemoveUnitMovementFlag(MOVEMENTFLAG_LEVITATING + MOVEMENTFLAG_ONTRANSPORT);
- m_creature->HandleEmoteCommand(EMOTE_ONESHOT_LAND);
m_creature->SetHover(false);
m_creature->GetMotionMaster()->MovePoint(0, -10.6155, -219.357, -87.7344);
DoStartMovement(m_creature->getVictim());
diff --git a/src/bindings/scripts/scripts/zone/orgrimmar/orgrimmar.cpp b/src/bindings/scripts/scripts/zone/orgrimmar/orgrimmar.cpp
index a53794c2b7a..1c2822b24b1 100644
--- a/src/bindings/scripts/scripts/zone/orgrimmar/orgrimmar.cpp
+++ b/src/bindings/scripts/scripts/zone/orgrimmar/orgrimmar.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -116,7 +116,18 @@ struct TRINITY_DLL_DECL npc_shenthulAI : public ScriptedAI
DoMeleeAttackIfReady();
}
+
+ void ReciveEmote_npc_shenthul(Player *player, uint32 emote)
+ {
+ if( emote == TEXTEMOTE_SALUTE && player->GetQuestStatus(QUEST_2460) == QUEST_STATUS_INCOMPLETE )
+ if(CanEmote)
+ {
+ player->AreaExploredOrEventHappens(QUEST_2460);
+ Reset();
+ }
+ }
};
+
CreatureAI* GetAI_npc_shenthul(Creature *_Creature)
{
return new npc_shenthulAI (_Creature);
@@ -132,17 +143,6 @@ bool QuestAccept_npc_shenthul(Player* player, Creature* creature, Quest const* q
return true;
}
-bool ReciveEmote_npc_shenthul(Player *player, Creature *_Creature, uint32 emote)
-{
- if( emote == TEXTEMOTE_SALUTE && player->GetQuestStatus(QUEST_2460) == QUEST_STATUS_INCOMPLETE )
- if( ((npc_shenthulAI*)_Creature->AI())->CanEmote )
- {
- player->AreaExploredOrEventHappens(QUEST_2460);
- ((npc_shenthulAI*)_Creature->AI())->Reset();
- }
- return true;
-}
-
/*######
## npc_thrall_warchief
######*/
@@ -263,7 +263,6 @@ void AddSC_orgrimmar()
newscript->Name="npc_shenthul";
newscript->GetAI = &GetAI_npc_shenthul;
newscript->pQuestAccept = &QuestAccept_npc_shenthul;
- newscript->pReceiveEmote = &ReciveEmote_npc_shenthul;
newscript->RegisterSelf();
newscript = new Script;
diff --git a/src/bindings/scripts/scripts/zone/razorfen_downs/boss_amnennar_the_coldbringer.cpp b/src/bindings/scripts/scripts/zone/razorfen_downs/boss_amnennar_the_coldbringer.cpp
index d8e1a297872..9c089fddf71 100644
--- a/src/bindings/scripts/scripts/zone/razorfen_downs/boss_amnennar_the_coldbringer.cpp
+++ b/src/bindings/scripts/scripts/zone/razorfen_downs/boss_amnennar_the_coldbringer.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,15 +23,16 @@ EndScriptData */
#include "precompiled.h"
-#define SAY_0 "You'll never leave this place... alive."
-#define SAY_1 "Come, spirits, attend your master."
-#define SAY_SLAY "Too...easy!"
-#define SOUND_AGGRO 5825
-#define SOUND_SLAY 5826
-#define SOUND_SUMMON 5829
+#define SAY_AGGRO -1129000
+#define SAY_SUMMON60 -1129001
+#define SAY_SUMMON30 -1129002
+#define SAY_HP -1129003
+#define SAY_KILL -1129004
-#define SPELL_AMNENNARSWRATH 13009
-#define SPELL_FROSTBOLT 10179
+#define SPELL_AMNENNARSWRATH 13009
+#define SPELL_FROSTBOLT 15530
+#define SPELL_FROST_NOVA 15531
+#define SPELL_FROST_SPECTRES 12642
struct TRINITY_DLL_DECL boss_amnennar_the_coldbringerAI : public ScriptedAI
{
@@ -39,50 +40,29 @@ struct TRINITY_DLL_DECL boss_amnennar_the_coldbringerAI : public ScriptedAI
uint32 AmnenarsWrath_Timer;
uint32 FrostBolt_Timer;
- bool Spectrals;
- int Rand;
- int RandX;
- int RandY;
- Creature* Summoned;
+ uint32 FrostNova_Timer;
+ bool Spectrals60;
+ bool Spectrals30;
+ bool Hp;
void Reset()
{
AmnenarsWrath_Timer = 8000;
FrostBolt_Timer = 1000;
- Spectrals = false;
+ FrostNova_Timer = 10000 + rand()%5000;
+ Spectrals30 = false;
+ Spectrals60 = false;
+ Hp = false;
}
void Aggro(Unit *who)
{
- DoYell(SAY_0,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_AGGRO);
+ DoScriptText(SAY_AGGRO, m_creature);
}
void KilledUnit()
{
- DoYell(SAY_SLAY, LANG_UNIVERSAL, NULL);
- DoPlaySoundToSet(m_creature, SOUND_SLAY);
- }
-
- void SummonSpectrals(Unit* victim)
- {
- Rand = rand()%5;
- switch (rand()%2)
- {
- case 0: RandX = 0 - Rand; break;
- case 1: RandX = 0 + Rand; break;
- }
- Rand = 0;
- Rand = rand()%5;
- switch (rand()%2)
- {
- case 0: RandY = 0 - Rand; break;
- case 1: RandY = 0 + Rand; break;
- }
- Rand = 0;
- Summoned = DoSpawnCreature(8585, RandX, RandY, 0, 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 60000);
- if(Summoned)
- ((CreatureAI*)Summoned->AI())->AttackStart(victim);
+ DoScriptText(SAY_KILL, m_creature);
}
void UpdateAI(const uint32 diff)
@@ -100,25 +80,34 @@ struct TRINITY_DLL_DECL boss_amnennar_the_coldbringerAI : public ScriptedAI
//FrostBolt_Timer
if (FrostBolt_Timer < diff)
{
- Unit* target = NULL;
- target = SelectUnit(SELECT_TARGET_RANDOM,0);
- if (target) DoCast(target,SPELL_FROSTBOLT);
-
+ DoCast(m_creature->getVictim(),SPELL_FROSTBOLT);
FrostBolt_Timer = 8000;
} else FrostBolt_Timer -= diff;
- if ( !Spectrals && m_creature->GetHealth()*100 / m_creature->GetMaxHealth() < 50 )
+ if (FrostNova_Timer < diff)
{
- DoYell(SAY_1, LANG_UNIVERSAL, NULL);
- DoPlaySoundToSet(m_creature, SOUND_SUMMON);
+ DoCast(m_creature,SPELL_FROST_NOVA);
+ FrostNova_Timer = 15000;
+ } else FrostNova_Timer -= diff;
- Unit* target = NULL;
- target = SelectUnit(SELECT_TARGET_RANDOM,0);
+ if (!Spectrals60 && m_creature->GetHealth()*100 / m_creature->GetMaxHealth() < 60)
+ {
+ DoScriptText(SAY_SUMMON60, m_creature);
+ DoCast(m_creature->getVictim(),SPELL_FROST_SPECTRES);
+ Spectrals60 = true;
+ }
- SummonSpectrals(target);
- SummonSpectrals(target);
- SummonSpectrals(target);
- Spectrals = true;
+ if (!Hp && m_creature->GetHealth()*100 / m_creature->GetMaxHealth() < 50)
+ {
+ DoScriptText(SAY_HP, m_creature);
+ Hp = true;
+ }
+
+ if (!Spectrals30 && m_creature->GetHealth()*100 / m_creature->GetMaxHealth() < 30)
+ {
+ DoScriptText(SAY_SUMMON30, m_creature);
+ DoCast(m_creature->getVictim(),SPELL_FROST_SPECTRES);
+ Spectrals30 = true;
}
DoMeleeAttackIfReady();
diff --git a/src/bindings/scripts/scripts/zone/razorfen_downs/razorfen_downs.cpp b/src/bindings/scripts/scripts/zone/razorfen_downs/razorfen_downs.cpp
new file mode 100644
index 00000000000..d5c09e504a8
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/razorfen_downs/razorfen_downs.cpp
@@ -0,0 +1,85 @@
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Razorfen_Downs
+SD%Complete: 100
+SDComment: Support for Henry Stern(2 recipes)
+SDCategory: Razorfen Downs
+EndScriptData */
+
+/* ContentData
+npc_henry_stern
+EndContentData */
+
+#include "precompiled.h"
+
+/*###
+# npc_henry_stern
+####*/
+
+enum
+{
+ SPELL_GOLDTHORN_TEA = 13028,
+ SPELL_TEACHING_GOLDTHORN_TEA = 13029,
+ SPELL_MIGHT_TROLLS_BLOOD_POTION = 3451,
+ SPELL_TEACHING_MIGHTY_TROLLS_BLOOD_POTION = 13030,
+ GOSSIP_TEXT_TEA_ANSWER = 2114,
+ GOSSIP_TEXT_POTION_ANSWER = 2115,
+};
+
+#define GOSSIP_ITEM_TEA "Teach me the cooking recipe"
+#define GOSSIP_ITEM_POTION "Teach me the alchemy recipe"
+
+bool GossipHello_npc_henry_stern (Player* pPlayer, Creature* pCreature)
+{
+ if (pPlayer->GetBaseSkillValue(SKILL_COOKING) >= 175 && !pPlayer->HasSpell(SPELL_GOLDTHORN_TEA))
+ pPlayer->ADD_GOSSIP_ITEM(0, GOSSIP_ITEM_TEA, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1);
+
+ if (pPlayer->GetBaseSkillValue(SKILL_ALCHEMY) >= 180 && !pPlayer->HasSpell(SPELL_MIGHT_TROLLS_BLOOD_POTION))
+ pPlayer->ADD_GOSSIP_ITEM(0, GOSSIP_ITEM_POTION, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2);
+
+ pPlayer->SEND_GOSSIP_MENU(pCreature->GetNpcTextId(), pCreature->GetGUID());
+ return true;
+}
+
+bool GossipSelect_npc_henry_stern (Player* pPlayer, Creature* pCreature, uint32 sender, uint32 action)
+{
+ if (action == GOSSIP_ACTION_INFO_DEF + 1)
+ {
+ pCreature->CastSpell(pPlayer, SPELL_TEACHING_GOLDTHORN_TEA, true);
+ pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXT_TEA_ANSWER, pCreature->GetGUID());
+ }
+
+ if (action == GOSSIP_ACTION_INFO_DEF + 2)
+ {
+ pPlayer->SEND_GOSSIP_MENU(GOSSIP_TEXT_POTION_ANSWER, pCreature->GetGUID());
+ pCreature->CastSpell(pPlayer, SPELL_TEACHING_MIGHTY_TROLLS_BLOOD_POTION, true);
+ }
+
+ return true;
+}
+
+void AddSC_razorfen_downs()
+{
+ Script* newscript;
+
+ newscript = new Script;
+ newscript->Name = "npc_henry_stern";
+ newscript->pGossipHello = &GossipHello_npc_henry_stern;
+ newscript->pGossipSelect = &GossipSelect_npc_henry_stern;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/razorfen_kraul/razorfen_kraul.cpp b/src/bindings/scripts/scripts/zone/razorfen_kraul/razorfen_kraul.cpp
index 39be57325d7..8a65b493c5a 100644
--- a/src/bindings/scripts/scripts/zone/razorfen_kraul/razorfen_kraul.cpp
+++ b/src/bindings/scripts/scripts/zone/razorfen_kraul/razorfen_kraul.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_ayamiss.cpp b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_ayamiss.cpp
index 128ab315334..be15a35f032 100644
--- a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_ayamiss.cpp
+++ b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_ayamiss.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_buru.cpp b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_buru.cpp
index 4297c32492f..58c48540362 100644
--- a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_buru.cpp
+++ b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_buru.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_kurinnaxx.cpp b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_kurinnaxx.cpp
index 9c888e98605..f164009c79b 100644
--- a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_kurinnaxx.cpp
+++ b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_kurinnaxx.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_moam.cpp b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_moam.cpp
index 5830b3a8070..df0e63f8599 100644
--- a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_moam.cpp
+++ b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_moam.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_ossirian.cpp b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_ossirian.cpp
index 1d389830045..5652b706917 100644
--- a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_ossirian.cpp
+++ b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_ossirian.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_rajaxx.cpp b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_rajaxx.cpp
index 0639a02deb6..fb2c92ff59f 100644
--- a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_rajaxx.cpp
+++ b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/boss_rajaxx.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/instance_ruins_of_ahnqiraj.cpp b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/instance_ruins_of_ahnqiraj.cpp
index 27a0621b2be..b94e6f16a80 100644
--- a/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/instance_ruins_of_ahnqiraj.cpp
+++ b/src/bindings/scripts/scripts/zone/ruins_of_ahnqiraj/instance_ruins_of_ahnqiraj.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_arcanist_doan.cpp b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_arcanist_doan.cpp
index 222f927e5a0..533adf732f3 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_arcanist_doan.cpp
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_arcanist_doan.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,55 +23,40 @@ EndScriptData */
#include "precompiled.h"
-#define SPELL_POLYMORPH 12826
-#define SPELL_AOESILENCE 8988
-#define SPELL_ARCANEEXPLOSION3 8438
-#define SPELL_ARCANEEXPLOSION4 8439
-#define SPELL_FIREAOE 9435
-#define SPELL_BLINK 1953
-#define SPELL_FIREBALL 21162
-#define SPELL_MANASHIELD4 10191
-#define SPELL_ARCANEBUBBLE 9438
-
-#define SAY_AGGRO "You will not defile these mysteries!"
-#define SAY_SPECIALAE "Burn in righteous fire!"
-
-#define SOUND_AGGRO 5842
-#define SOUND_SPECIALAE 5843
+enum
+{
+ SAY_AGGRO = -1189019,
+ SAY_SPECIALAE = -1189020,
+
+ SPELL_POLYMORPH = 13323,
+ SPELL_AOESILENCE = 8988,
+ SPELL_ARCANEEXPLOSION = 9433,
+ SPELL_FIREAOE = 9435,
+ SPELL_ARCANEBUBBLE = 9438,
+};
struct TRINITY_DLL_DECL boss_arcanist_doanAI : public ScriptedAI
{
boss_arcanist_doanAI(Creature *c) : ScriptedAI(c) {}
- uint32 FullAOE_Timer;
uint32 Polymorph_Timer;
- uint32 Yell_Timer;
- uint32 ArcaneBubble_Timer;
uint32 AoESilence_Timer;
- uint32 ArcaneExplosion3_Timer;
- uint32 ArcaneExplosion4_Timer;
- uint32 Blink_Timer;
- uint32 Fireball_Timer;
- uint32 ManaShield4_Timer;
+ uint32 ArcaneExplosion_Timer;
+ bool bCanDetonate;
+ bool bShielded;
void Reset()
{
- FullAOE_Timer = 5000;
- Polymorph_Timer = 1;
- Yell_Timer = 2000;
- ArcaneBubble_Timer = 3000;
- AoESilence_Timer = 20000;
- ArcaneExplosion3_Timer = 10000;
- ArcaneExplosion4_Timer = 10000;
- Blink_Timer = 40000;
- Fireball_Timer = 6000;
- ManaShield4_Timer = 70000;
+ Polymorph_Timer = 20000;
+ AoESilence_Timer = 15000;
+ ArcaneExplosion_Timer = 3000;
+ bCanDetonate = false;
+ bShielded = false;
}
void Aggro(Unit *who)
{
- DoYell(SAY_AGGRO,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_AGGRO);
+ DoScriptText(SAY_AGGRO, m_creature);
}
void UpdateAI(const uint32 diff)
@@ -79,79 +64,50 @@ struct TRINITY_DLL_DECL boss_arcanist_doanAI : public ScriptedAI
if (!UpdateVictim())
return;
- //If we are <50% hp cast Arcane Bubble and start casting SPECIAL FIRE AOE
- if (m_creature->GetHealth()*100 / m_creature->GetMaxHealth() <= 50 && !m_creature->IsNonMeleeSpellCasted(false))
+ if (bShielded && bCanDetonate)
{
- if (Polymorph_Timer < diff)
- {
- Unit* target = NULL;
-
- target = SelectUnit(SELECT_TARGET_RANDOM,0);
- if (target)DoCast(target,SPELL_POLYMORPH);
- Polymorph_Timer = 40000;
- }else Polymorph_Timer -= diff;
-
- if (Yell_Timer < diff)
- {
- DoYell(SAY_SPECIALAE,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_SPECIALAE);
- Yell_Timer = 40000;
- }else Yell_Timer -= diff;
-
- if (ArcaneBubble_Timer < diff)
- {
- DoCast(m_creature,SPELL_ARCANEBUBBLE);
- ArcaneBubble_Timer = 40000;
- }else ArcaneBubble_Timer -= diff;
-
- if (FullAOE_Timer < diff)
- {
- DoCast(m_creature->getVictim(),SPELL_FIREAOE);
- FullAOE_Timer = 40000;
- }else FullAOE_Timer -= diff;
+ DoCast(m_creature,SPELL_FIREAOE);
+ bCanDetonate = false;
}
- //AoESilence_Timer
- if (AoESilence_Timer < diff)
- {
- DoCast(m_creature->getVictim(),SPELL_AOESILENCE);
- AoESilence_Timer = 30000;
- }else AoESilence_Timer -= diff;
+ if (m_creature->HasAura(SPELL_ARCANEBUBBLE))
+ return;
- //ArcaneExplosion3_Timer
- if (ArcaneExplosion3_Timer < diff)
+ //If we are <50% hp cast Arcane Bubble
+ if (!bShielded && m_creature->GetHealth()*100 / m_creature->GetMaxHealth() <= 50)
{
- DoCast(m_creature->getVictim(),SPELL_ARCANEEXPLOSION3);
- ArcaneExplosion3_Timer = 8000;
- }else ArcaneExplosion3_Timer -= diff;
+ //wait if we already casting
+ if (m_creature->IsNonMeleeSpellCasted(false))
+ return;
- //ArcaneExplosion4_Timer
- if (ArcaneExplosion4_Timer < diff)
- {
- DoCast(m_creature->getVictim(),SPELL_ARCANEEXPLOSION4);
- ArcaneExplosion4_Timer = 10000;
- }else ArcaneExplosion4_Timer -= diff;
+ DoScriptText(SAY_SPECIALAE, m_creature);
+ DoCast(m_creature,SPELL_ARCANEBUBBLE);
- //Blink_Timer
- if (Blink_Timer < diff)
+ bCanDetonate = true;
+ bShielded = true;
+ }
+
+ if (Polymorph_Timer < diff)
{
- DoCast(m_creature,SPELL_BLINK);
- Blink_Timer = 30000;
- }else Blink_Timer -= diff;
+ if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM,1))
+ DoCast(target,SPELL_POLYMORPH);
+
+ Polymorph_Timer = 20000;
+ }else Polymorph_Timer -= diff;
- //Fireball_Timer
- if (Fireball_Timer < diff)
+ //AoESilence_Timer
+ if (AoESilence_Timer < diff)
{
- DoCast(m_creature->getVictim(),SPELL_FIREBALL);
- Fireball_Timer = 12000;
- }else Fireball_Timer -= diff;
+ DoCast(m_creature->getVictim(),SPELL_AOESILENCE);
+ AoESilence_Timer = 15000 + rand()%5000;
+ }else AoESilence_Timer -= diff;
- //ManaShiled4_Timer
- if (ManaShield4_Timer < diff)
+ //ArcaneExplosion_Timer
+ if (ArcaneExplosion_Timer < diff)
{
- DoCast(m_creature,SPELL_MANASHIELD4);
- ManaShield4_Timer = 70000;
- }else ManaShield4_Timer -= diff;
+ DoCast(m_creature->getVictim(),SPELL_ARCANEEXPLOSION);
+ ArcaneExplosion_Timer = 8000;
+ }else ArcaneExplosion_Timer -= diff;
DoMeleeAttackIfReady();
}
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_azshir_the_sleepless.cpp b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_azshir_the_sleepless.cpp
index e22de9b8fb3..5975d5f7e57 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_azshir_the_sleepless.cpp
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_azshir_the_sleepless.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_bloodmage_thalnos.cpp b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_bloodmage_thalnos.cpp
index f5c094d6127..351a72db2fc 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_bloodmage_thalnos.cpp
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_bloodmage_thalnos.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,45 +23,45 @@ EndScriptData */
#include "precompiled.h"
-#define SPELL_FROSTNOVA2 865
-#define SPELL_FLAMESHOCK3 8053
-#define SPELL_SHADOWBOLT5 1106
-#define SPELL_FLAMESPIKE 8814
-#define SPELL_FIRENOVA 16079
-
-#define SAY_AGGRO "We hunger for vengeance."
-#define SAY_HEALTH "No rest... for the angry dead!"
-#define SAY_DEATH "More... More souls!"
-
-#define SOUND_AGGRO 5844
-#define SOUND_HEALTH 5846
-#define SOUND_DEATH 5845
+enum
+{
+ SAY_AGGRO = -1189016,
+ SAY_HEALTH = -1189017,
+ SAY_KILL = -1189018,
+
+ SPELL_FLAMESHOCK = 8053,
+ SPELL_SHADOWBOLT = 1106,
+ SPELL_FLAMESPIKE = 8814,
+ SPELL_FIRENOVA = 16079,
+};
struct TRINITY_DLL_DECL boss_bloodmage_thalnosAI : public ScriptedAI
{
boss_bloodmage_thalnosAI(Creature *c) : ScriptedAI(c) {}
- uint32 FrostNova2_Timer;
- uint32 FlameShock3_Timer;
- uint32 ShadowBolt5_Timer;
+ bool HpYell;
+ uint32 FlameShock_Timer;
+ uint32 ShadowBolt_Timer;
uint32 FlameSpike_Timer;
uint32 FireNova_Timer;
- uint32 Yell_Timer;
void Reset()
{
- Yell_Timer = 1;
- FrostNova2_Timer = 10000;
- FlameShock3_Timer = 15000;
- ShadowBolt5_Timer = 20000;
- FlameSpike_Timer = 20000;
- FireNova_Timer = 10000;
+ HpYell = false;
+ FlameShock_Timer = 10000;
+ ShadowBolt_Timer = 2000;
+ FlameSpike_Timer = 8000;
+ FireNova_Timer = 40000;
}
void Aggro(Unit *who)
{
- DoYell(SAY_AGGRO,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_AGGRO);
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+
+ void KilledUnit(Unit* Victim)
+ {
+ DoScriptText(SAY_KILL, m_creature);
}
void UpdateAI(const uint32 diff)
@@ -70,38 +70,18 @@ struct TRINITY_DLL_DECL boss_bloodmage_thalnosAI : public ScriptedAI
return;
//If we are <35% hp
- if ( m_creature->GetHealth()*100 / m_creature->GetMaxHealth() <= 35)
+ if (!HpYell && ((m_creature->GetHealth()*100) / m_creature->GetMaxHealth() <= 35))
{
- Yell_Timer -= diff;
-
- if (Yell_Timer < diff)
- {
- DoYell(SAY_HEALTH,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_HEALTH);
- Yell_Timer = 900000;
- }
+ DoScriptText(SAY_HEALTH, m_creature);
+ HpYell = true;
}
- //FrostNova2_Timer
- if (FrostNova2_Timer < diff)
+ //FlameShock_Timer
+ if (FlameShock_Timer < diff)
{
- DoCast(m_creature->getVictim(),SPELL_FROSTNOVA2);
- FrostNova2_Timer = 10000;
- }else FrostNova2_Timer -= diff;
-
- //FlameShock3_Timer
- if (FlameShock3_Timer < diff)
- {
- DoCast(m_creature->getVictim(),SPELL_FLAMESHOCK3);
- FlameShock3_Timer = 15000;
- }else FlameShock3_Timer -= diff;
-
- //ShadowBolt5_Timer
- if (ShadowBolt5_Timer < diff)
- {
- DoCast(m_creature->getVictim(),SPELL_SHADOWBOLT5);
- ShadowBolt5_Timer = 20000;
- }else ShadowBolt5_Timer -= diff;
+ DoCast(m_creature->getVictim(),SPELL_FLAMESHOCK);
+ FlameShock_Timer = 10000 + rand()%5000;
+ }else FlameShock_Timer -= diff;
//FlameSpike_Timer
if (FlameSpike_Timer < diff)
@@ -114,9 +94,16 @@ struct TRINITY_DLL_DECL boss_bloodmage_thalnosAI : public ScriptedAI
if (FireNova_Timer < diff)
{
DoCast(m_creature->getVictim(),SPELL_FIRENOVA);
- FireNova_Timer = 20000;
+ FireNova_Timer = 40000;
}else FireNova_Timer -= diff;
+ //ShadowBolt_Timer
+ if (ShadowBolt_Timer < diff)
+ {
+ DoCast(m_creature->getVictim(),SPELL_SHADOWBOLT);
+ ShadowBolt_Timer = 2000;
+ }else ShadowBolt_Timer -= diff;
+
DoMeleeAttackIfReady();
}
};
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_headless_horseman.cpp b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_headless_horseman.cpp
index 441797ec158..9d1b447e746 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_headless_horseman.cpp
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_headless_horseman.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -176,7 +176,7 @@ struct TRINITY_DLL_DECL mob_wisp_invisAI : public ScriptedAI
if (!who || Creaturetype != 1 || !who->isTargetableForAttack())
return;
- if (m_creature->GetDistance2d(who) < 0.1 && !who->HasAura(SPELL_SQUASH_SOUL,0))
+ if (m_creature->GetDistance2d(who) < 0.1 && !who->HasAura(SPELL_SQUASH_SOUL))
DoCast(who,SPELL_SQUASH_SOUL);
}
@@ -505,7 +505,7 @@ struct TRINITY_DLL_DECL boss_headless_horsemanAI : public ScriptedAI
void SpellHitTarget(Unit* unit, const SpellEntry* spell)
{
if (spell->Id == SPELL_CONFLAGRATION)
- if (unit->HasAura(SPELL_CONFLAGRATION,0))
+ if (unit->HasAura(SPELL_CONFLAGRATION))
SaySound(SAY_CONFLAGRATION,unit);
}
@@ -572,7 +572,7 @@ struct TRINITY_DLL_DECL boss_headless_horsemanAI : public ScriptedAI
DoCast(m_creature,SPELL_BODY_REGEN,true);
m_creature->CastSpell(Head, SPELL_FLYING_HEAD,true);
DoCast(m_creature,SPELL_CONFUSE,false); //test
- done_by->ProcDamageAndSpell(m_creature,PROC_FLAG_KILL_AND_GET_XP,PROC_FLAG_KILLED,PROC_EX_NONE,0);
+ done_by->ProcDamageAndSpell(m_creature,PROC_FLAG_KILL,PROC_FLAG_KILLED,PROC_EX_NONE,0);
whirlwind = 4000 + (rand()%5)*1000;
regen = 0;
}
@@ -734,7 +734,7 @@ struct TRINITY_DLL_DECL mob_pulsing_pumpkinAI : public ScriptedAI
sprouted = false;
DoCast(m_creature,SPELL_PUMPKIN_AURA,true);
DoCast(m_creature,SPELL_SPROUTING);
- m_creature->SetFlag(UNIT_FIELD_FLAGS,UNIT_FLAG_DISABLE_ROTATE);
+ m_creature->SetFlag(UNIT_FIELD_FLAGS,UNIT_FLAG_STUNNED);
}
void Aggro(Unit *who){}
@@ -745,7 +745,7 @@ struct TRINITY_DLL_DECL mob_pulsing_pumpkinAI : public ScriptedAI
{
sprouted = true;
m_creature->RemoveAllAuras();
- m_creature->RemoveFlag(UNIT_FIELD_FLAGS,UNIT_FLAG_DISABLE_ROTATE);
+ m_creature->RemoveFlag(UNIT_FIELD_FLAGS,UNIT_FLAG_STUNNED);
DoCast(m_creature,SPELL_SPROUT_BODY,true);
m_creature->UpdateEntry(PUMPKIN_FIEND);
DoStartMovement(m_creature->getVictim());
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_herod.cpp b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_herod.cpp
index 17f4aee1ae3..956fa26bdac 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_herod.cpp
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_herod.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -105,45 +105,22 @@ struct TRINITY_DLL_DECL boss_herodAI : public ScriptedAI
}
};
-CreatureAI* GetAI_boss_herod(Creature *_Creature)
+CreatureAI* GetAI_boss_herod(Creature* pCreature)
{
- return new boss_herodAI (_Creature);
+ return new boss_herodAI(pCreature);
}
-float Location[12][3]=
-{
- {1945.81, -431.54, 16.36},
- {1946.21, -436.41, 16.36},
- {1950.01, -444.11, 14.63},
- {1956.08, -449.34, 13.12},
- {1966.59, -450.55, 11.27},
- {1976.09, -447.51, 11.27},
- {1983.42, -435.85, 11.27},
- {1978.17, -428.81, 11.27},
- {1973.97, -422.08, 9.04},
- {1963.84, -418.90, 6.17},
- {1961.22, -422.74, 6.17},
- {1964.80, -431.26, 6.17}
-};
-
-uint32 Wait[12][1]=
-{
- {0},{0},{0},{0},{0},{0},{0},{0},{0},{0},{0},{600000}
-};
-
struct TRINITY_DLL_DECL mob_scarlet_traineeAI : public npc_escortAI
{
- mob_scarlet_traineeAI(Creature *c) : npc_escortAI(c) {}
-
- uint32 Start_Timer;
-
- void WaypointReached(uint32 i) { }
-
- void Reset()
+ mob_scarlet_traineeAI(Creature *c) : npc_escortAI(c)
{
- Start_Timer = urand(1500,4500);
+ Start_Timer = urand(1000,6000);
}
+ uint32 Start_Timer;
+
+ void Reset() { }
+ void WaypointReached(uint32 uiPoint) { }
void Aggro(Unit* who) { }
void UpdateAI(const uint32 diff)
@@ -161,14 +138,13 @@ struct TRINITY_DLL_DECL mob_scarlet_traineeAI : public npc_escortAI
}
};
-CreatureAI* GetAI_mob_scarlet_trainee(Creature* _Creature)
+CreatureAI* GetAI_mob_scarlet_trainee(Creature* pCreature)
{
- mob_scarlet_traineeAI* thisAI = new mob_scarlet_traineeAI(_Creature);
+ mob_scarlet_traineeAI* thisAI = new mob_scarlet_traineeAI(pCreature);
- for(uint32 i = 0; i < 12; ++i)
- thisAI->AddWaypoint(i, Location[i][0], Location[i][1], Location[i][2], Wait[i][0]);
+ thisAI->FillPointMovementListForCreature();
- return ((CreatureAI*)thisAI);
+ return (CreatureAI*)thisAI;
}
void AddSC_boss_herod()
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_high_inquisitor_fairbanks.cpp b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_high_inquisitor_fairbanks.cpp
index b1c8bde0566..a188fe9c3f2 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_high_inquisitor_fairbanks.cpp
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_high_inquisitor_fairbanks.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_houndmaster_loksey.cpp b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_houndmaster_loksey.cpp
index 5dde65cb840..7f812310be3 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_houndmaster_loksey.cpp
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_houndmaster_loksey.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,11 +23,10 @@ EndScriptData */
#include "precompiled.h"
-#define SPELL_SUMMONSCARLETHOUND 17164
-#define SPELL_ENRAGE 28747
+#define SAY_AGGRO -1189021
-#define SAY_AGGRO "Release the hounds!"
-#define SOUND_AGGRO 5841
+#define SPELL_SUMMONSCARLETHOUND 17164
+#define SPELL_ENRAGE 6742
struct TRINITY_DLL_DECL boss_houndmaster_lokseyAI : public ScriptedAI
{
@@ -37,15 +36,12 @@ struct TRINITY_DLL_DECL boss_houndmaster_lokseyAI : public ScriptedAI
void Reset()
{
- Enrage_Timer = 6000000;
+ Enrage_Timer = 0;
}
void Aggro(Unit *who)
{
- DoYell(SAY_AGGRO,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_AGGRO);
-
- DoCast(m_creature,SPELL_SUMMONSCARLETHOUND);
+ DoScriptText(SAY_AGGRO, m_creature);
}
void UpdateAI(const uint32 diff)
@@ -53,16 +49,17 @@ struct TRINITY_DLL_DECL boss_houndmaster_lokseyAI : public ScriptedAI
if (!UpdateVictim())
return;
- //If we are <10% hp cast healing spells at self and Mograine
- if ( m_creature->GetHealth()*100 / m_creature->GetMaxHealth() <= 10 && !m_creature->IsNonMeleeSpellCasted(false) && Enrage_Timer < diff)
+ //If we are <25% hp, bloodlust
+ if (m_creature->GetHealth()*100 / m_creature->GetMaxHealth() <= 25 && Enrage_Timer < diff)
{
DoCast(m_creature,SPELL_ENRAGE);
- Enrage_Timer = 900000;
+ Enrage_Timer = 60000;
}else Enrage_Timer -= diff;
DoMeleeAttackIfReady();
}
};
+
CreatureAI* GetAI_boss_houndmaster_loksey(Creature *_Creature)
{
return new boss_houndmaster_lokseyAI (_Creature);
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_interrogator_vishas.cpp b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_interrogator_vishas.cpp
index 1366897eb05..34d5a7fff37 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_interrogator_vishas.cpp
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_interrogator_vishas.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -22,36 +22,55 @@ SDCategory: Scarlet Monastery
EndScriptData */
#include "precompiled.h"
+#include "def_scarlet_monastery.h"
-#define SPELL_POWERWORDSHIELD 6065
-
-#define SAY_AGGRO "Tell me... tell me everything!"
-#define SAY_HEALTH1 "Naughty secrets"
-#define SAY_HEALTH2 "I'll rip the secrets from your flesh!"
-#define SAY_DEATH "Purged by pain!"
+enum
+{
+ SAY_AGGRO = -1189011,
+ SAY_HEALTH1 = -1189012,
+ SAY_HEALTH2 = -1189013,
+ SAY_KILL = -1189014,
+ SAY_TRIGGER_VORREL = -1189015,
-#define SOUND_AGGRO 5847
-#define SOUND_HEALTH1 5849
-#define SOUND_HEALTH2 5850
-#define SOUND_DEATH 5848
+ SPELL_SHADOWWORDPAIN = 2767,
+};
struct TRINITY_DLL_DECL boss_interrogator_vishasAI : public ScriptedAI
{
- boss_interrogator_vishasAI(Creature *c) : ScriptedAI(c) {}
+ boss_interrogator_vishasAI(Creature *c) : ScriptedAI(c)
+ {
+ pInstance = (ScriptedInstance*)m_creature->GetInstanceData();
+ }
+
+ ScriptedInstance* pInstance;
- uint32 Yell_Timer;
- uint32 PowerWordShield_Timer;
+ bool Yell30;
+ bool Yell60;
+ uint32 ShadowWordPain_Timer;
void Reset()
{
- Yell_Timer = 6000000;
- PowerWordShield_Timer = 60000;
+ ShadowWordPain_Timer = 5000;
}
void Aggro(Unit *who)
{
- DoYell(SAY_AGGRO,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_AGGRO);
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+
+ void KilledUnit(Unit* Victim)
+ {
+ DoScriptText(SAY_KILL, m_creature);
+ }
+
+ void JustDied(Unit* Killer)
+ {
+ if (!pInstance)
+ return;
+
+ //Any other actions to do with vorrel? setStandState?
+ if (Unit *vorrel = Unit::GetUnit(*m_creature,pInstance->GetData64(DATA_VORREL)))
+ DoScriptText(SAY_TRIGGER_VORREL, vorrel);
}
void UpdateAI(const uint32 diff)
@@ -60,44 +79,29 @@ struct TRINITY_DLL_DECL boss_interrogator_vishasAI : public ScriptedAI
return;
//If we are low on hp Do sayings
- if ( m_creature->GetHealth()*100 / m_creature->GetMaxHealth() <= 60 && !m_creature->IsNonMeleeSpellCasted(false))
+ if (!Yell60 && ((m_creature->GetHealth()*100) / m_creature->GetMaxHealth() <= 60))
{
- //Yell_Timer
- if (Yell_Timer < diff)
- {
- DoYell(SAY_HEALTH1,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_HEALTH1);
- return;
-
- //60 seconds until we should cast this agian
- Yell_Timer = 60000;
- }else Yell_Timer -= diff;
+ DoScriptText(SAY_HEALTH1, m_creature);
+ Yell60 = true;
}
- if ( m_creature->GetHealth()*100 / m_creature->GetMaxHealth() <= 30 && !m_creature->IsNonMeleeSpellCasted(false))
+ if (!Yell30 && ((m_creature->GetHealth()*100) / m_creature->GetMaxHealth() <= 30))
{
- //Yell_Timer
- if (Yell_Timer < diff)
- {
- DoYell(SAY_HEALTH2,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_HEALTH2);
- return;
-
- //60 seconds until we should cast this agian
- Yell_Timer = 6000000;
- }else Yell_Timer -= diff;
+ DoScriptText(SAY_HEALTH2, m_creature);
+ Yell30 = true;
}
- //PowerWordShield_Timer
- if (PowerWordShield_Timer < diff)
+ //ShadowWordPain_Timer
+ if (ShadowWordPain_Timer < diff)
{
- DoCast(m_creature,SPELL_POWERWORDSHIELD);
- PowerWordShield_Timer = 60000;
- }else PowerWordShield_Timer -= diff;
+ DoCast(m_creature->getVictim(),SPELL_SHADOWWORDPAIN);
+ ShadowWordPain_Timer = 5000 + rand()%10000;;
+ }else ShadowWordPain_Timer -= diff;
DoMeleeAttackIfReady();
}
};
+
CreatureAI* GetAI_boss_interrogator_vishas(Creature *_Creature)
{
return new boss_interrogator_vishasAI (_Creature);
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_mograine_and_whitemane.cpp b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_mograine_and_whitemane.cpp
index 6c2bd8a9be8..bde26d42478 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_mograine_and_whitemane.cpp
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_mograine_and_whitemane.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_scorn.cpp b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_scorn.cpp
index 88cee632568..642c884ebc8 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_scorn.cpp
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/boss_scorn.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/def_scarlet_monastery.h b/src/bindings/scripts/scripts/zone/scarlet_monastery/def_scarlet_monastery.h
index b8ab822129d..2b6399ae3e4 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/def_scarlet_monastery.h
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/def_scarlet_monastery.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
@@ -10,7 +10,9 @@
#define DATA_WHITEMANE 3
#define DATA_DOOR_WHITEMANE 4
-#define DATA_HORSEMAN_EVENT 5
-#define GAMEOBJECT_PUMPKIN_SHRINE 6
+#define DATA_HORSEMAN_EVENT 5
+#define GAMEOBJECT_PUMPKIN_SHRINE 6
+
+#define DATA_VORREL 7
#endif
diff --git a/src/bindings/scripts/scripts/zone/scarlet_monastery/instance_scarlet_monastery.cpp b/src/bindings/scripts/scripts/zone/scarlet_monastery/instance_scarlet_monastery.cpp
index 44152e6b4e0..4a2239f3b36 100644
--- a/src/bindings/scripts/scripts/zone/scarlet_monastery/instance_scarlet_monastery.cpp
+++ b/src/bindings/scripts/scripts/zone/scarlet_monastery/instance_scarlet_monastery.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -43,6 +43,7 @@ struct TRINITY_DLL_DECL instance_scarlet_monastery : public ScriptedInstance
uint64 MograineGUID;
uint64 WhitemaneGUID;
+ uint64 VorrelGUID;
uint64 DoorHighInquisitorGUID;
uint32 Encounter[ENCOUNTERS];
@@ -56,6 +57,7 @@ struct TRINITY_DLL_DECL instance_scarlet_monastery : public ScriptedInstance
MograineGUID = 0;
WhitemaneGUID = 0;
+ VorrelGUID = 0;
DoorHighInquisitorGUID = 0;
for(uint8 i = 0; i < ENCOUNTERS; i++)
@@ -80,6 +82,7 @@ struct TRINITY_DLL_DECL instance_scarlet_monastery : public ScriptedInstance
case ENTRY_PUMPKIN: HorsemanAdds.insert(creature->GetGUID());break;
case 3976: MograineGUID = creature->GetGUID(); break;
case 3977: WhitemaneGUID = creature->GetGUID(); break;
+ case 3981: VorrelGUID = creature->GetGUID(); break;
}
}
@@ -92,7 +95,7 @@ struct TRINITY_DLL_DECL instance_scarlet_monastery : public ScriptedInstance
{
GameObject *Shrine = instance->GetGameObjectInMap(PumpkinShrineGUID);
if(Shrine)
- Shrine->SetUInt32Value(GAMEOBJECT_STATE,1);
+ Shrine->SetGoState(1);
}break;
case DATA_HORSEMAN_EVENT:
if (data == DONE)
@@ -106,7 +109,7 @@ struct TRINITY_DLL_DECL instance_scarlet_monastery : public ScriptedInstance
HorsemanAdds.clear();
GameObject *Shrine = instance->GetGameObjectInMap(PumpkinShrineGUID);
if(Shrine)
- Shrine->SetUInt32Value(GAMEOBJECT_STATE,1);
+ Shrine->SetGoState(1);
}
break;
}
@@ -121,6 +124,7 @@ struct TRINITY_DLL_DECL instance_scarlet_monastery : public ScriptedInstance
//case DATA_HEAD: return HeadGUID;
case DATA_MOGRAINE: return MograineGUID;
case DATA_WHITEMANE: return WhitemaneGUID;
+ case DATA_VORREL: return VorrelGUID;
case DATA_DOOR_WHITEMANE: return DoorHighInquisitorGUID;
}
return 0;
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_darkmaster_gandling.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_darkmaster_gandling.cpp
index a20cd4d8b83..46f216220aa 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_darkmaster_gandling.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_darkmaster_gandling.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -16,12 +16,13 @@
/* ScriptData
SDName: Boss_Darkmaster_Gandling
-SD%Complete: 99
+SD%Complete: 75
SDComment: Doors missing in instance script.
SDCategory: Scholomance
EndScriptData */
#include "precompiled.h"
+#include "def_scholomance.h"
#define SPELL_ARCANEMISSILES 22272
#define SPELL_SHADOWSHIELD 22417 //Not right ID. But 12040 is wrong either.
@@ -49,12 +50,18 @@ EndScriptData */
struct TRINITY_DLL_DECL boss_darkmaster_gandlingAI : public ScriptedAI
{
- boss_darkmaster_gandlingAI(Creature *c) : ScriptedAI(c) {}
+ boss_darkmaster_gandlingAI(Creature *c) : ScriptedAI(c)
+ {
+ pInstance = (ScriptedInstance*)m_creature->GetInstanceData();
+ }
+
+ ScriptedInstance* pInstance;
uint32 ArcaneMissiles_Timer;
uint32 ShadowShield_Timer;
uint32 Curse_Timer;
uint32 Teleport_Timer;
+
Creature *Summoned;
void Reset()
@@ -69,6 +76,12 @@ struct TRINITY_DLL_DECL boss_darkmaster_gandlingAI : public ScriptedAI
{
}
+ void JustDied(Unit *killer)
+ {
+ if (pInstance)
+ pInstance->SetData(TYPE_GANDLING, DONE);
+ }
+
void UpdateAI(const uint32 diff)
{
if (!UpdateVictim())
@@ -113,59 +126,79 @@ struct TRINITY_DLL_DECL boss_darkmaster_gandlingAI : public ScriptedAI
case 0:
DoTeleportPlayer(target, 250.0696,0.3921,84.8408,3.149);
Summoned = m_creature->SummonCreature(16119,254.2325,0.3417,84.8407,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,257.7133,4.0226,84.8407,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,258.6702,-2.60656,84.8407,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
break;
case 1:
DoTeleportPlayer(target, 181.4220,-91.9481,84.8410,1.608);
Summoned = m_creature->SummonCreature(16119,184.0519,-73.5649,84.8407,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,179.5951,-73.7045,84.8407,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,180.6452,-78.2143,84.8407,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,283.2274,-78.1518,84.8407,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
break;
case 2:
DoTeleportPlayer(target, 95.1547,-1.8173,85.2289,0.043);
Summoned = m_creature->SummonCreature(16119,100.9404,-1.8016,85.2289,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,101.3729,0.4882,85.2289,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,101.4596,-4.4740,85.2289,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
break;
case 3:
DoTeleportPlayer(target, 250.0696,0.3921,72.6722,3.149);
Summoned = m_creature->SummonCreature(16119,240.34481,0.7368,72.6722,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,240.3633,-2.9520,72.6722,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,240.6702,3.34949,72.6722,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
break;
case 4:
DoTeleportPlayer(target, 181.4220,-91.9481,70.7734,1.608);
Summoned = m_creature->SummonCreature(16119,184.0519,-73.5649,70.7734,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,179.5951,-73.7045,70.7734,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,180.6452,-78.2143,70.7734,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,283.2274,-78.1518,70.7734,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
break;
case 5:
DoTeleportPlayer(target, 106.1541,-1.8994,75.3663,0.043);
Summoned = m_creature->SummonCreature(16119,115.3945,-1.5555,75.3663,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,257.7133,1.8066,75.3663,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
Summoned = m_creature->SummonCreature(16119,258.6702,-5.1001,75.3663,0,TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT,10000);
+ if (Summoned)
((CreatureAI*)Summoned->AI())->AttackStart(target);
break;
}
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_death_knight_darkreaver.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_death_knight_darkreaver.cpp
index 2e0eb4e09e2..8bb3703fa8b 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_death_knight_darkreaver.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_death_knight_darkreaver.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_doctor_theolen_krastinov.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_doctor_theolen_krastinov.cpp
index 001c67c26b8..96afbfe1971 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_doctor_theolen_krastinov.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_doctor_theolen_krastinov.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -24,6 +24,8 @@ EndScriptData */
#include "precompiled.h"
#include "def_scholomance.h"
+#define EMOTE_GENERIC_FRENZY_KILL -1000001
+
#define SPELL_REND 18106
#define SPELL_CLEAVE 15584
#define SPELL_FRENZY 28371
@@ -50,7 +52,7 @@ struct TRINITY_DLL_DECL boss_theolenkrastinovAI : public ScriptedAI
{
pInstance->SetData(DATA_DOCTORTHEOLENKRASTINOV_DEATH, 0);
- if(pInstance->GetData(DATA_CANSPAWNGANDLING))
+ if (pInstance->GetData(TYPE_GANDLING) == IN_PROGRESS)
m_creature->SummonCreature(1853, 180.73, -9.43856, 75.507, 1.61399, TEMPSUMMON_DEAD_DESPAWN, 0);
}
}
@@ -84,7 +86,7 @@ struct TRINITY_DLL_DECL boss_theolenkrastinovAI : public ScriptedAI
if (Frenzy_Timer < diff)
{
DoCast(m_creature,SPELL_FRENZY);
- DoTextEmote("goes into a killing frenzy!",NULL);
+ DoScriptText(EMOTE_GENERIC_FRENZY_KILL, m_creature);
Frenzy_Timer = 8000;
}else Frenzy_Timer -= diff;
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_illucia_barov.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_illucia_barov.cpp
index 6eb5e1ec249..02f4c9bc5a4 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_illucia_barov.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_illucia_barov.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -53,7 +53,7 @@ struct TRINITY_DLL_DECL boss_illuciabarovAI : public ScriptedAI
{
pInstance->SetData(DATA_LADYILLUCIABAROV_DEATH, 0);
- if(pInstance->GetData(DATA_CANSPAWNGANDLING))
+ if (pInstance->GetData(TYPE_GANDLING) == IN_PROGRESS)
m_creature->SummonCreature(1853, 180.73, -9.43856, 75.507, 1.61399, TEMPSUMMON_DEAD_DESPAWN, 0);
}
}
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_instructor_malicia.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_instructor_malicia.cpp
index 4ba2811dc52..2790e36ddaf 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_instructor_malicia.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_instructor_malicia.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -60,7 +60,7 @@ struct TRINITY_DLL_DECL boss_instructormaliciaAI : public ScriptedAI
{
pInstance->SetData(DATA_INSTRUCTORMALICIA_DEATH, 0);
- if(pInstance->GetData(DATA_CANSPAWNGANDLING))
+ if (pInstance->GetData(TYPE_GANDLING) == IN_PROGRESS)
m_creature->SummonCreature(1853, 180.73, -9.43856, 75.507, 1.61399, TEMPSUMMON_DEAD_DESPAWN, 0);
}
}
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_jandice_barov.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_jandice_barov.cpp
index c6ff12be817..d2890801b5d 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_jandice_barov.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_jandice_barov.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_kormok.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_kormok.cpp
index 355fbd90c9b..8fdda4d2f33 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_kormok.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_kormok.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_lord_alexei_barov.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_lord_alexei_barov.cpp
index 195e5b048b4..ddf3c3b083d 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_lord_alexei_barov.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_lord_alexei_barov.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -49,7 +49,7 @@ struct TRINITY_DLL_DECL boss_lordalexeibarovAI : public ScriptedAI
{
pInstance->SetData(DATA_LORDALEXEIBAROV_DEATH, 0);
- if(pInstance->GetData(DATA_CANSPAWNGANDLING))
+ if (pInstance->GetData(TYPE_GANDLING) == IN_PROGRESS)
m_creature->SummonCreature(1853, 180.73, -9.43856, 75.507, 1.61399, TEMPSUMMON_DEAD_DESPAWN, 0);
}
}
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_lorekeeper_polkelt.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_lorekeeper_polkelt.cpp
index 728ad07e838..040cafc91fc 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_lorekeeper_polkelt.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_lorekeeper_polkelt.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -53,7 +53,7 @@ struct TRINITY_DLL_DECL boss_lorekeeperpolkeltAI : public ScriptedAI
{
pInstance->SetData(DATA_LOREKEEPERPOLKELT_DEATH, 0);
- if(pInstance->GetData(DATA_CANSPAWNGANDLING))
+ if (pInstance->GetData(TYPE_GANDLING) == IN_PROGRESS)
m_creature->SummonCreature(1853, 180.73, -9.43856, 75.507, 1.61399, TEMPSUMMON_DEAD_DESPAWN, 0);
}
}
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_ras_frostwhisper.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_ras_frostwhisper.cpp
index 154da52596a..fbb1e355f1d 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_ras_frostwhisper.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_ras_frostwhisper.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_the_ravenian.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_the_ravenian.cpp
index 95ebafb092a..aea8b476ad2 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_the_ravenian.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_the_ravenian.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -29,8 +29,6 @@ EndScriptData */
#define SPELL_SUNDERINCLEAVE 25174
#define SPELL_KNOCKAWAY 10101
-#define SAY_AGGRO1 "Mine! Mine! Mine! Gizlock is the ruler of this domain! You shall never reveal my presence!"
-
struct TRINITY_DLL_DECL boss_theravenianAI : public ScriptedAI
{
boss_theravenianAI(Creature *c) : ScriptedAI(c) {}
@@ -57,14 +55,13 @@ struct TRINITY_DLL_DECL boss_theravenianAI : public ScriptedAI
{
pInstance->SetData(DATA_THERAVENIAN_DEATH, 0);
- if(pInstance->GetData(DATA_CANSPAWNGANDLING))
+ if (pInstance->GetData(TYPE_GANDLING) == IN_PROGRESS)
m_creature->SummonCreature(1853, 180.73, -9.43856, 75.507, 1.61399, TEMPSUMMON_DEAD_DESPAWN, 0);
}
}
void Aggro(Unit *who)
{
- DoYell(SAY_AGGRO1, LANG_UNIVERSAL, NULL);
}
void UpdateAI(const uint32 diff)
@@ -103,6 +100,7 @@ struct TRINITY_DLL_DECL boss_theravenianAI : public ScriptedAI
DoMeleeAttackIfReady();
}
};
+
CreatureAI* GetAI_boss_theravenian(Creature *_Creature)
{
return new boss_theravenianAI (_Creature);
diff --git a/src/bindings/scripts/scripts/zone/scholomance/boss_vectus.cpp b/src/bindings/scripts/scripts/zone/scholomance/boss_vectus.cpp
index 280e0d194d7..2ade6f7fd4d 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/boss_vectus.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/boss_vectus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,6 +23,8 @@ EndScriptData */
#include "precompiled.h"
+#define EMOTE_GENERIC_FRENZY_KILL -1000001
+
#define SPELL_FIRESHIELD 19626
#define SPELL_BLASTWAVE 13021
#define SPELL_FRENZY 28371
@@ -71,7 +73,7 @@ struct TRINITY_DLL_DECL boss_vectusAI : public ScriptedAI
if (Frenzy_Timer < diff)
{
DoCast(m_creature,SPELL_FRENZY);
- DoTextEmote("goes into a killing frenzy!",NULL);
+ DoScriptText(EMOTE_GENERIC_FRENZY_KILL, m_creature);
Frenzy_Timer = 24000;
}else Frenzy_Timer -= diff;
diff --git a/src/bindings/scripts/scripts/zone/scholomance/def_scholomance.h b/src/bindings/scripts/scripts/zone/scholomance/def_scholomance.h
index 0216a48fc74..83ce26c9687 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/def_scholomance.h
+++ b/src/bindings/scripts/scripts/zone/scholomance/def_scholomance.h
@@ -1,16 +1,17 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
#ifndef DEF_SCHOLOMANCE_H
#define DEF_SCHOLOMANCE_H
-#define DATA_CANSPAWNGANDLING 1
+#define TYPE_GANDLING 1
#define DATA_DOCTORTHEOLENKRASTINOV_DEATH 2
#define DATA_INSTRUCTORMALICIA_DEATH 3
#define DATA_LADYILLUCIABAROV_DEATH 4
#define DATA_LORDALEXEIBAROV_DEATH 5
#define DATA_LOREKEEPERPOLKELT_DEATH 6
#define DATA_THERAVENIAN_DEATH 7
+#define TYPE_KIRTONOS 8
#endif
diff --git a/src/bindings/scripts/scripts/zone/scholomance/instance_scholomance.cpp b/src/bindings/scripts/scripts/zone/scholomance/instance_scholomance.cpp
index 74b90dfdf53..d99546fbcea 100644
--- a/src/bindings/scripts/scripts/zone/scholomance/instance_scholomance.cpp
+++ b/src/bindings/scripts/scripts/zone/scholomance/instance_scholomance.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -24,36 +24,65 @@ EndScriptData */
#include "precompiled.h"
#include "def_scholomance.h"
+#define GO_GATE_KIRTONOS 175570
+#define GO_GATE_GANDLING 177374
+#define GO_GATE_MALICIA 177375
+#define GO_GATE_THEOLEN 177377
+#define GO_GATE_POLKELT 177376
+#define GO_GATE_RAVENIAN 177372
+#define GO_GATE_BAROV 177373
+#define GO_GATE_ILLUCIA 177371
+
+#define ENCOUNTERS 2
+
struct TRINITY_DLL_DECL instance_scholomance : public ScriptedInstance
{
instance_scholomance(Map *map) : ScriptedInstance(map) {Initialize();};
//Lord Alexei Barov, Doctor Theolen Krastinov, The Ravenian, Lorekeeper Polkelt, Instructor Malicia and the Lady Illucia Barov.
bool IsBossDied[6];
+ uint32 Encounter[ENCOUNTERS];
- void Initialize()
- {
- IsBossDied[0] = false;
- IsBossDied[1] = false;
- IsBossDied[2] = false;
- IsBossDied[3] = false;
- IsBossDied[4] = false;
- IsBossDied[5] = false;
- }
+ uint64 GateKirtonosGUID;
+ uint64 GateGandlingGUID;
+ uint64 GateMiliciaGUID;
+ uint64 GateTheolenGUID;
+ uint64 GatePolkeltGUID;
+ uint64 GateRavenianGUID;
+ uint64 GateBarovGUID;
+ uint64 GateIlluciaGUID;
- bool IsEncounterInProgress() const
+ void Initialize()
{
- //not active in scholomance
- return false;
+ GateKirtonosGUID = 0;
+ GateGandlingGUID = 0;
+ GateMiliciaGUID = 0;
+ GateTheolenGUID = 0;
+ GatePolkeltGUID = 0;
+ GateRavenianGUID = 0;
+ GateBarovGUID = 0;
+ GateIlluciaGUID = 0;
+
+ for(uint8 i = 0; i < 6; i++)
+ IsBossDied[i] = false;
+
+ for(uint8 i = 0; i < ENCOUNTERS; i++)
+ Encounter[i] = NOT_STARTED;
}
- uint32 GetData(uint32 type)
+ void OnObjectCreate(GameObject *go)
{
- if(type == DATA_CANSPAWNGANDLING)
- if(IsBossDied[0] && IsBossDied[1] && IsBossDied[2] && IsBossDied[3] && IsBossDied[4] && IsBossDied[5])
- return 1;
-
- return 0;
+ switch(go->GetEntry())
+ {
+ case GO_GATE_KIRTONOS: GateKirtonosGUID = go->GetGUID(); break;
+ case GO_GATE_GANDLING: GateGandlingGUID = go->GetGUID(); break;
+ case GO_GATE_MALICIA: GateMiliciaGUID = go->GetGUID(); break;
+ case GO_GATE_THEOLEN: GateTheolenGUID = go->GetGUID(); break;
+ case GO_GATE_POLKELT: GatePolkeltGUID = go->GetGUID(); break;
+ case GO_GATE_RAVENIAN: GateRavenianGUID = go->GetGUID(); break;
+ case GO_GATE_BAROV: GateBarovGUID = go->GetGUID(); break;
+ case GO_GATE_ILLUCIA: GateIlluciaGUID = go->GetGUID(); break;
+ }
}
void SetData(uint32 type, uint32 data)
@@ -63,28 +92,43 @@ struct TRINITY_DLL_DECL instance_scholomance : public ScriptedInstance
case DATA_LORDALEXEIBAROV_DEATH:
IsBossDied[0] = true;
break;
-
case DATA_DOCTORTHEOLENKRASTINOV_DEATH:
IsBossDied[1] = true;
break;
-
case DATA_THERAVENIAN_DEATH:
IsBossDied[2] = true;
break;
-
case DATA_LOREKEEPERPOLKELT_DEATH:
IsBossDied[3] = true;
break;
-
case DATA_INSTRUCTORMALICIA_DEATH:
IsBossDied[4] = true;
break;
-
case DATA_LADYILLUCIABAROV_DEATH:
IsBossDied[5] = true;
break;
+ case TYPE_GANDLING:
+ Encounter[0] = data;
+ break;
+ case TYPE_KIRTONOS:
+ Encounter[1] = data;
+ break;
}
}
+
+ uint32 GetData(uint32 type)
+ {
+ if (type == TYPE_GANDLING)
+ {
+ if (IsBossDied[0] && IsBossDied[1] && IsBossDied[2] && IsBossDied[3] && IsBossDied[4] && IsBossDied[5])
+ {
+ Encounter[0] = IN_PROGRESS;
+ return IN_PROGRESS;
+ }
+ }
+
+ return 0;
+ }
};
InstanceData* GetInstanceData_instance_scholomance(Map* map)
diff --git a/src/bindings/scripts/scripts/zone/searing_gorge/searing_gorge.cpp b/src/bindings/scripts/scripts/zone/searing_gorge/searing_gorge.cpp
index fff417bcf21..4d55b5d91fd 100644
--- a/src/bindings/scripts/scripts/zone/searing_gorge/searing_gorge.cpp
+++ b/src/bindings/scripts/scripts/zone/searing_gorge/searing_gorge.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/shadowfang_keep/def_shadowfang_keep.h b/src/bindings/scripts/scripts/zone/shadowfang_keep/def_shadowfang_keep.h
index 1612bfd59f0..8383a5c3950 100644
--- a/src/bindings/scripts/scripts/zone/shadowfang_keep/def_shadowfang_keep.h
+++ b/src/bindings/scripts/scripts/zone/shadowfang_keep/def_shadowfang_keep.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/shadowfang_keep/instance_shadowfang_keep.cpp b/src/bindings/scripts/scripts/zone/shadowfang_keep/instance_shadowfang_keep.cpp
index 3e7caef435f..3a788d2e863 100644
--- a/src/bindings/scripts/scripts/zone/shadowfang_keep/instance_shadowfang_keep.cpp
+++ b/src/bindings/scripts/scripts/zone/shadowfang_keep/instance_shadowfang_keep.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -26,6 +26,18 @@ EndScriptData */
#define ENCOUNTERS 4
+enum
+{
+ SAY_BOSS_DIE_AD = -1033007,
+ SAY_BOSS_DIE_AS = -1033008,
+
+ NPC_ASH = 3850,
+ NPC_ADA = 3849,
+
+ GO_COURTYARD_DOOR = 18895, //door to open when talking to NPC's
+ GO_SORCERER_DOOR = 18972, //door to open when Fenrus the Devourer
+ GO_ARUGAL_DOOR = 18971 //door to open when Wolf Master Nandos
+};
struct TRINITY_DLL_DECL instance_shadowfang_keep : public ScriptedInstance
{
instance_shadowfang_keep(Map *map) : ScriptedInstance(map) {Initialize();};
@@ -33,12 +45,18 @@ struct TRINITY_DLL_DECL instance_shadowfang_keep : public ScriptedInstance
uint32 Encounter[ENCOUNTERS];
std::string str_data;
+ uint64 uiAshGUID;
+ uint64 uiAdaGUID;
+
uint64 DoorCourtyardGUID;
uint64 DoorSorcererGUID;
uint64 DoorArugalGUID;
void Initialize()
{
+ uiAshGUID = 0;
+ uiAdaGUID = 0;
+
DoorCourtyardGUID = 0;
DoorSorcererGUID = 0;
DoorArugalGUID = 0;
@@ -63,13 +81,34 @@ struct TRINITY_DLL_DECL instance_shadowfang_keep : public ScriptedInstance
return NULL;
}
+ void OnCreatureCreate(Creature* pCreature, uint32 uiCreature)
+ {
+ switch(pCreature->GetEntry())
+ {
+ case NPC_ASH: uiAshGUID = pCreature->GetGUID(); break;
+ case NPC_ADA: uiAdaGUID = pCreature->GetGUID(); break;
+ }
+ }
+
void OnObjectCreate(GameObject *go)
{
switch(go->GetEntry())
{
- case 18895: DoorCourtyardGUID = go->GetGUID(); break;
- case 18972: DoorSorcererGUID = go->GetGUID(); break;
- case 18971: DoorArugalGUID = go->GetGUID(); break;
+ case GO_COURTYARD_DOOR:
+ DoorCourtyardGUID = go->GetGUID();
+ if (Encounter[0] == DONE)
+ go->SetGoState(0);
+ break;
+ case GO_SORCERER_DOOR:
+ DoorSorcererGUID = go->GetGUID();
+ if (Encounter[2] == DONE)
+ go->SetGoState(0);
+ break;
+ case GO_ARUGAL_DOOR:
+ DoorArugalGUID = go->GetGUID();
+ if (Encounter[3] == DONE)
+ go->SetGoState(0);
+ break;
}
}
@@ -87,6 +126,23 @@ struct TRINITY_DLL_DECL instance_shadowfang_keep : public ScriptedInstance
go->SetGoState(state);
}
+ void DoSpeech()
+ {
+ Player* pPlayer = GetPlayerInMap();
+
+ if (pPlayer)
+ {
+ Unit* pAda = Unit::GetUnit(*pPlayer,uiAdaGUID);
+ Unit* pAsh = Unit::GetUnit(*pPlayer,uiAshGUID);
+
+ if (pAda && pAda->isAlive() && pAsh && pAsh->isAlive())
+ {
+ DoScriptText(SAY_BOSS_DIE_AD,pAda);
+ DoScriptText(SAY_BOSS_DIE_AS,pAsh);
+ }
+ }
+ }
+
void SetData(uint32 type, uint32 data)
{
switch(type)
@@ -97,6 +153,8 @@ struct TRINITY_DLL_DECL instance_shadowfang_keep : public ScriptedInstance
Encounter[0] = data;
break;
case TYPE_RETHILGORE:
+ if (data == DONE)
+ DoSpeech();
Encounter[1] = data;
break;
case TYPE_FENRUS:
@@ -160,8 +218,10 @@ struct TRINITY_DLL_DECL instance_shadowfang_keep : public ScriptedInstance
loadStream >> Encounter[0] >> Encounter[1] >> Encounter[2] >> Encounter[3];
for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ {
if (Encounter[i] == IN_PROGRESS)
Encounter[i] = NOT_STARTED;
+ }
OUT_LOAD_INST_DATA_COMPLETE;
}
diff --git a/src/bindings/scripts/scripts/zone/shadowfang_keep/shadowfang_keep.cpp b/src/bindings/scripts/scripts/zone/shadowfang_keep/shadowfang_keep.cpp
index a4f04f83ffd..f4b49b5f524 100644
--- a/src/bindings/scripts/scripts/zone/shadowfang_keep/shadowfang_keep.cpp
+++ b/src/bindings/scripts/scripts/zone/shadowfang_keep/shadowfang_keep.cpp
@@ -1,4 +1,4 @@
- /* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ /* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -33,7 +33,20 @@ EndContentData */
## npc_shadowfang_prisoner
######*/
-#define SAY_FREE -1033000
+enum
+{
+ SAY_FREE_AS = -1033000,
+ SAY_OPEN_DOOR_AS = -1033001,
+ SAY_POST_DOOR_AS = -1033002,
+ SAY_FREE_AD = -1033003,
+ SAY_OPEN_DOOR_AD = -1033004,
+ SAY_POST1_DOOR_AD = -1033005,
+ SAY_POST2_DOOR_AD = -1033006,
+
+ SPELL_UNLOCK = 6421,
+ NPC_ASH = 3850
+};
+
#define GOSSIP_ITEM_DOOR "Thanks, I'll follow you to the door."
struct TRINITY_DLL_DECL npc_shadowfang_prisonerAI : public npc_escortAI
@@ -41,17 +54,45 @@ struct TRINITY_DLL_DECL npc_shadowfang_prisonerAI : public npc_escortAI
npc_shadowfang_prisonerAI(Creature *c) : npc_escortAI(c)
{
pInstance = ((ScriptedInstance*)c->GetInstanceData());
+ uiNpcEntry = c->GetEntry();
}
ScriptedInstance *pInstance;
+ uint32 uiNpcEntry;
- void WaypointReached(uint32 i)
+ void WaypointReached(uint32 uiPoint)
{
- if( pInstance && i == 6)
+ switch(uiPoint)
{
- m_creature->HandleEmoteCommand(EMOTE_ONESHOT_TALK);
- DoScriptText(SAY_FREE, m_creature);
- pInstance->SetData(TYPE_FREE_NPC, DONE);
+ case 0:
+ if (uiNpcEntry == NPC_ASH)
+ DoScriptText(SAY_FREE_AS, m_creature);
+ else
+ DoScriptText(SAY_FREE_AD, m_creature);
+ break;
+ case 10:
+ if (uiNpcEntry == NPC_ASH)
+ DoScriptText(SAY_OPEN_DOOR_AS, m_creature);
+ else
+ DoScriptText(SAY_OPEN_DOOR_AD, m_creature);
+ break;
+ case 11:
+ if (uiNpcEntry == NPC_ASH)
+ DoCast(m_creature, SPELL_UNLOCK);
+ break;
+ case 12:
+ if (uiNpcEntry == NPC_ASH)
+ DoScriptText(SAY_POST_DOOR_AS, m_creature);
+ else
+ DoScriptText(SAY_POST1_DOOR_AD, m_creature);
+
+ if (pInstance)
+ pInstance->SetData(TYPE_FREE_NPC, DONE);
+ break;
+ case 13:
+ if (uiNpcEntry != NPC_ASH)
+ DoScriptText(SAY_POST2_DOOR_AD, m_creature);
+ break;
}
}
@@ -59,62 +100,43 @@ struct TRINITY_DLL_DECL npc_shadowfang_prisonerAI : public npc_escortAI
void Aggro(Unit* who) {}
};
-CreatureAI* GetAI_npc_shadowfang_prisoner(Creature *_Creature)
+CreatureAI* GetAI_npc_shadowfang_prisoner(Creature* pCreature)
{
- npc_shadowfang_prisonerAI* prisonerAI = new npc_shadowfang_prisonerAI(_Creature);
-
- uint32 eCreature = _Creature->GetEntry();
-
- if( eCreature==3849) //adamant
- prisonerAI->AddWaypoint(0, -254.47, 2117.48, 81.17);
- if( eCreature==3850) //ashcrombe
- prisonerAI->AddWaypoint(0, -252.35, 2126.71, 81.17);
+ npc_shadowfang_prisonerAI* prisonerAI = new npc_shadowfang_prisonerAI(pCreature);
- prisonerAI->AddWaypoint(1, -253.63, 2131.27, 81.28);
- prisonerAI->AddWaypoint(2, -249.66, 2142.45, 87.01);
- prisonerAI->AddWaypoint(3, -248.08, 2143.68, 87.01);
- prisonerAI->AddWaypoint(4, -238.87, 2139.93, 87.01);
- prisonerAI->AddWaypoint(5, -235.47, 2149.18, 90.59);
- prisonerAI->AddWaypoint(6, -239.89, 2156.06, 90.62, 20000);
+ prisonerAI->FillPointMovementListForCreature();
return (CreatureAI*)prisonerAI;
}
-bool GossipHello_npc_shadowfang_prisoner(Player *player, Creature *_Creature)
+bool GossipHello_npc_shadowfang_prisoner(Player* pPlayer, Creature* pCreature)
{
- ScriptedInstance* pInstance = ((ScriptedInstance*)_Creature->GetInstanceData());
+ ScriptedInstance* pInstance = ((ScriptedInstance*)pCreature->GetInstanceData());
- if (!pInstance)
- return false;
-
- if (pInstance->GetData(TYPE_FREE_NPC) != DONE && pInstance->GetData(TYPE_RETHILGORE) == DONE)
- player->ADD_GOSSIP_ITEM( 0, GOSSIP_ITEM_DOOR, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
-
- player->SEND_GOSSIP_MENU(_Creature->GetNpcTextId(), _Creature->GetGUID());
+ if (pInstance && pInstance->GetData(TYPE_FREE_NPC) != DONE && pInstance->GetData(TYPE_RETHILGORE) == DONE)
+ pPlayer->ADD_GOSSIP_ITEM(0, GOSSIP_ITEM_DOOR, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
+
+ pPlayer->SEND_GOSSIP_MENU(pCreature->GetNpcTextId(), pCreature->GetGUID());
return true;
}
-bool GossipSelect_npc_shadowfang_prisoner(Player *player, Creature *_Creature, uint32 sender, uint32 action)
+bool GossipSelect_npc_shadowfang_prisoner(Player* pPlayer, Creature* pCreature, uint32 uiSender, uint32 uiAction)
{
- if (action == GOSSIP_ACTION_INFO_DEF+1)
+ if (uiAction == GOSSIP_ACTION_INFO_DEF+1)
{
- player->CLOSE_GOSSIP_MENU();
- ((npc_escortAI*)(_Creature->AI()))->Start(false, false, false);
+ pPlayer->CLOSE_GOSSIP_MENU();
+ ((npc_escortAI*)(pCreature->AI()))->Start(false, true, false);
}
return true;
}
-/*######
-## AddSC
-######*/
-
void AddSC_shadowfang_keep()
{
Script *newscript;
newscript = new Script;
- newscript->Name="npc_shadowfang_prisoner";
+ newscript->Name = "npc_shadowfang_prisoner";
newscript->pGossipHello = &GossipHello_npc_shadowfang_prisoner;
newscript->pGossipSelect = &GossipSelect_npc_shadowfang_prisoner;
newscript->GetAI = &GetAI_npc_shadowfang_prisoner;
diff --git a/src/bindings/scripts/scripts/zone/shadowmoon_valley/boss_doomwalker.cpp b/src/bindings/scripts/scripts/zone/shadowmoon_valley/boss_doomwalker.cpp
index 014d7fe1153..ea84a299403 100644
--- a/src/bindings/scripts/scripts/zone/shadowmoon_valley/boss_doomwalker.cpp
+++ b/src/bindings/scripts/scripts/zone/shadowmoon_valley/boss_doomwalker.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -131,7 +131,7 @@ struct TRINITY_DLL_DECL boss_doomwalkerAI : public ScriptedAI
//remove enrage before casting earthquake because enrage + earthquake = 16000dmg over 8sec and all dead
if (InEnrage)
- m_creature->RemoveAura(SPELL_ENRAGE, 0);
+ m_creature->RemoveAura(SPELL_ENRAGE);
DoCast(m_creature,SPELL_EARTHQUAKE);
Quake_Timer = 30000 + rand()%25000;
diff --git a/src/bindings/scripts/scripts/zone/shadowmoon_valley/shadowmoon_valley.cpp b/src/bindings/scripts/scripts/zone/shadowmoon_valley/shadowmoon_valley.cpp
index 720d5aabb1c..0a84d13349e 100644
--- a/src/bindings/scripts/scripts/zone/shadowmoon_valley/shadowmoon_valley.cpp
+++ b/src/bindings/scripts/scripts/zone/shadowmoon_valley/shadowmoon_valley.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -57,6 +57,7 @@ struct TRINITY_DLL_DECL mob_mature_netherwing_drakeAI : public ScriptedAI
mob_mature_netherwing_drakeAI(Creature* c) : ScriptedAI(c)
{
PlayerGUID = 0;
+ Reset();
}
uint64 PlayerGUID;
@@ -93,7 +94,7 @@ struct TRINITY_DLL_DECL mob_mature_netherwing_drakeAI : public ScriptedAI
if(!caster)
return;
- if(caster->GetTypeId() == TYPEID_PLAYER && spell->Id == SPELL_PLACE_CARCASS && !m_creature->HasAura(SPELL_JUST_EATEN, 0) && !PlayerGUID)
+ if(caster->GetTypeId() == TYPEID_PLAYER && spell->Id == SPELL_PLACE_CARCASS && !m_creature->HasAura(SPELL_JUST_EATEN) && !PlayerGUID)
{
float PlayerX, PlayerY, PlayerZ;
caster->GetClosePoint(PlayerX, PlayerY, PlayerZ, m_creature->GetObjectSize());
@@ -180,6 +181,7 @@ struct TRINITY_DLL_DECL mob_enslaved_netherwing_drakeAI : public ScriptedAI
{
PlayerGUID = 0;
Tapped = false;
+ Reset();
}
uint64 PlayerGUID;
diff --git a/src/bindings/scripts/scripts/zone/shattrath/shattrath_city.cpp b/src/bindings/scripts/scripts/zone/shattrath/shattrath_city.cpp
index 82b4ca4e7bc..583a6324a00 100644
--- a/src/bindings/scripts/scripts/zone/shattrath/shattrath_city.cpp
+++ b/src/bindings/scripts/scripts/zone/shattrath/shattrath_city.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -350,64 +350,7 @@ CreatureAI* GetAI_npc_kservantAI(Creature *_Creature)
{
npc_kservantAI* kservantAI = new npc_kservantAI(_Creature);
- kservantAI->AddWaypoint(0, -1863.369019, 5419.517090, -10.463668, 4000);
- kservantAI->AddWaypoint(1, -1861.749023, 5416.465332, -10.508068);
- kservantAI->AddWaypoint(2, -1857.036133, 5410.966309, -12.428039);
- kservantAI->AddWaypoint(3, -1831.539185, 5365.472168, -12.428039);
- kservantAI->AddWaypoint(4, -1813.416504, 5333.776855, -12.428039);
- kservantAI->AddWaypoint(5, -1800.354370, 5313.290039, -12.428039);
- kservantAI->AddWaypoint(6, -1775.624878, 5268.786133, -38.809181);
- kservantAI->AddWaypoint(7, -1770.147339, 5259.268066, -38.829231);
- kservantAI->AddWaypoint(8, -1762.814209, 5261.098145, -38.848995);
- kservantAI->AddWaypoint(9, -1740.110474, 5268.858398, -40.208965);
- kservantAI->AddWaypoint(10, -1725.837402, 5270.936035, -40.208965);
- kservantAI->AddWaypoint(11, -1701.580322, 5290.323242, -40.209187);
- kservantAI->AddWaypoint(12, -1682.877808, 5291.406738, -34.429646);
- kservantAI->AddWaypoint(13, -1670.101685, 5291.201172, -32.786007);
- kservantAI->AddWaypoint(14, -1656.666870, 5294.333496, -37.862648);
- kservantAI->AddWaypoint(15, -1652.035767, 5295.413086, -40.245499);
- kservantAI->AddWaypoint(16, -1620.860596, 5300.133301, -40.208992);
- kservantAI->AddWaypoint(17, -1607.630981, 5293.983398, -38.577045, 5000);
- kservantAI->AddWaypoint(18, -1607.630981, 5293.983398, -38.577045, 5000);
- kservantAI->AddWaypoint(19, -1607.630981, 5293.983398, -38.577045, 5000);
- kservantAI->AddWaypoint(20, -1622.140869, 5301.955566, -40.208897);
- kservantAI->AddWaypoint(21, -1621.131836, 5333.112793, -40.208897);
- kservantAI->AddWaypoint(22, -1637.598999, 5342.134277, -40.208790);
- kservantAI->AddWaypoint(23, -1648.521606, 5352.309570, -47.496170);
- kservantAI->AddWaypoint(24, -1654.606934, 5357.419434, -45.870892);
- kservantAI->AddWaypoint(25, -1633.670044, 5422.067871, -42.835541);
- kservantAI->AddWaypoint(25, -1656.567505, 5426.236328, -40.405815);
- kservantAI->AddWaypoint(26, -1664.932373, 5425.686523, -38.846405);
- kservantAI->AddWaypoint(27, -1681.406006, 5425.871094, -38.810928);
- kservantAI->AddWaypoint(28, -1730.875977, 5427.413574, -12.427910);
- kservantAI->AddWaypoint(29, -1743.509521, 5369.599121, -12.427910);
- kservantAI->AddWaypoint(30, -1877.217041, 5303.710449, -12.427989);
- kservantAI->AddWaypoint(31, -1890.371216, 5289.273438, -12.428268);
- kservantAI->AddWaypoint(32, -1905.505737, 5266.534668, 2.630672);
- kservantAI->AddWaypoint(33, -1909.381348, 5273.008301, 1.663714, 10000);
- kservantAI->AddWaypoint(34, -1909.381348, 5273.008301, 1.663714, 12000);
- kservantAI->AddWaypoint(35, -1909.381348, 5273.008301, 1.663714, 8000);
- kservantAI->AddWaypoint(36, -1909.381348, 5273.008301, 1.663714, 15000);
- kservantAI->AddWaypoint(37, -1927.561401, 5275.324707, 1.984987);
- kservantAI->AddWaypoint(38, -1927.385498, 5300.879883, -12.427236);
- kservantAI->AddWaypoint(39, -1921.063965, 5314.318359, -12.427236);
- kservantAI->AddWaypoint(40, -1965.425415, 5379.298828, -12.427236);
- kservantAI->AddWaypoint(41, -1981.233154, 5450.743652, -12.427236);
- kservantAI->AddWaypoint(42, -1958.022461, 5455.904297, 0.487659);
- kservantAI->AddWaypoint(43, -1951.991455, 5463.580566, 0.874490, 10000);
- kservantAI->AddWaypoint(44, -1951.991455, 5463.580566, 0.874490, 12000);
- kservantAI->AddWaypoint(45, -1968.730225, 5481.752930, -12.427846);
- kservantAI->AddWaypoint(46, -1881.839844, 5554.040039, -12.427846);
- kservantAI->AddWaypoint(47, -1841.566650, 5545.965332, -12.427846);
- kservantAI->AddWaypoint(48, -1837.658325, 5523.780273, 0.558756);
- kservantAI->AddWaypoint(49, -1831.321777, 5534.821777, 1.221819, 6000);
- kservantAI->AddWaypoint(50, -1831.321777, 5534.821777, 1.221819, 8000);
- kservantAI->AddWaypoint(51, -1831.321777, 5534.821777, 1.221819, 5000);
- kservantAI->AddWaypoint(52, -1850.060669, 5472.610840, 0.857320, 6000);
- kservantAI->AddWaypoint(53, -1850.060669, 5472.610840, 0.857320, 8000);
- kservantAI->AddWaypoint(54, -1850.060669, 5472.610840, 0.857320, 9000);
- kservantAI->AddWaypoint(55, -1850.060669, 5472.610840, 0.857320, 9000);
- kservantAI->AddWaypoint(56, -1850.060669, 5472.610840, 0.857320, 4000);
+ kservantAI->FillPointMovementListForCreature();
return (CreatureAI*)kservantAI;
}
diff --git a/src/bindings/scripts/scripts/zone/silithus/silithus.cpp b/src/bindings/scripts/scripts/zone/silithus/silithus.cpp
index 35dca28ddc8..bd1ecf748a0 100644
--- a/src/bindings/scripts/scripts/zone/silithus/silithus.cpp
+++ b/src/bindings/scripts/scripts/zone/silithus/silithus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/silvermoon/silvermoon_city.cpp b/src/bindings/scripts/scripts/zone/silvermoon/silvermoon_city.cpp
index 330fcf937c2..b8119f82d6b 100644
--- a/src/bindings/scripts/scripts/zone/silvermoon/silvermoon_city.cpp
+++ b/src/bindings/scripts/scripts/zone/silvermoon/silvermoon_city.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -47,7 +47,7 @@ struct TRINITY_DLL_DECL npc_blood_knight_stillbladeAI : public ScriptedAI
void Reset()
{
lifeTimer = 120000;
- m_creature->SetUInt32Value(UNIT_DYNAMIC_FLAGS, 32);
+ m_creature->SetStandState(UNIT_STAND_STATE_DEAD);
m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,7); // lay down
spellHit = false;
}
@@ -63,7 +63,7 @@ struct TRINITY_DLL_DECL npc_blood_knight_stillbladeAI : public ScriptedAI
void UpdateAI(const uint32 diff)
{
- if (!m_creature->GetUInt32Value(UNIT_FIELD_BYTES_1))
+ if (m_creature->IsStandState())
{
if(lifeTimer < diff)
m_creature->AI()->EnterEvadeMode();
@@ -79,7 +79,7 @@ struct TRINITY_DLL_DECL npc_blood_knight_stillbladeAI : public ScriptedAI
{
((Player*)Hitter)->AreaExploredOrEventHappens(QUEST_REDEEMING_THE_DEAD);
DoCast(m_creature,SPELL_REVIVE_SELF);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,0);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
m_creature->SetUInt32Value(UNIT_DYNAMIC_FLAGS, 0);
//m_creature->RemoveAllAuras();
DoScriptText(SAY_HEAL, m_creature);
diff --git a/src/bindings/scripts/scripts/zone/silverpine_forest/silverpine_forest.cpp b/src/bindings/scripts/scripts/zone/silverpine_forest/silverpine_forest.cpp
index a4236c82cef..c975dea89cf 100644
--- a/src/bindings/scripts/scripts/zone/silverpine_forest/silverpine_forest.cpp
+++ b/src/bindings/scripts/scripts/zone/silverpine_forest/silverpine_forest.cpp
@@ -1,4 +1,4 @@
- /* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ /* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stonetalon_mountains/stonetalon_mountains.cpp b/src/bindings/scripts/scripts/zone/stonetalon_mountains/stonetalon_mountains.cpp
index cd42b046d94..fcb44c764f3 100644
--- a/src/bindings/scripts/scripts/zone/stonetalon_mountains/stonetalon_mountains.cpp
+++ b/src/bindings/scripts/scripts/zone/stonetalon_mountains/stonetalon_mountains.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stormwind/stormwind_city.cpp b/src/bindings/scripts/scripts/zone/stormwind/stormwind_city.cpp
index 81016febdae..64c3df4f0c3 100644
--- a/src/bindings/scripts/scripts/zone/stormwind/stormwind_city.cpp
+++ b/src/bindings/scripts/scripts/zone/stormwind/stormwind_city.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -27,6 +27,7 @@ npc_bartleby
npc_dashel_stonefist
npc_general_marcus_jonathan
npc_lady_katrana_prestor
+npc_harbor_taxi
EndContentData */
#include "precompiled.h"
@@ -74,7 +75,7 @@ struct TRINITY_DLL_DECL npc_bartlebyAI : public ScriptedAI
void Reset()
{
m_creature->setFaction(11);
- m_creature->setEmoteState(7);
+ m_creature->SetUInt32Value(UNIT_NPC_EMOTESTATE, 7);
PlayerGUID = 0;
}
@@ -131,7 +132,7 @@ struct TRINITY_DLL_DECL npc_dashel_stonefistAI : public ScriptedAI
void Reset()
{
m_creature->setFaction(11);
- m_creature->setEmoteState(7);
+ m_creature->SetUInt32Value(UNIT_NPC_EMOTESTATE, 7);
}
void DamageTaken(Unit *done_by, uint32 & damage)
@@ -173,6 +174,8 @@ CreatureAI* GetAI_npc_dashel_stonefist(Creature *_creature)
## npc_general_marcus_jonathan
######*/
+#define SAY_GREETING -1000005
+
bool ReceiveEmote_npc_general_marcus_jonathan(Player *player, Creature *_Creature, uint32 emote)
{
if(player->GetTeam() == ALLIANCE)
@@ -184,7 +187,7 @@ bool ReceiveEmote_npc_general_marcus_jonathan(Player *player, Creature *_Creatur
}
if (emote == TEXTEMOTE_WAVE)
{
- _Creature->MonsterSay("Greetings citizen",LANG_COMMON,0);
+ DoScriptText(SAY_GREETING, _Creature, player);
}
}
return true;
@@ -236,6 +239,28 @@ bool GossipSelect_npc_lady_katrana_prestor(Player *player, Creature *_Creature,
return true;
}
+/*######
+## npc_harbor_taxi
+######*/
+
+#define GOSSIP_STORMWIND "I'd like to take a flight around Stormwind Harbor."
+
+bool GossipHello_npc_stormwind_harbor_taxi(Player *player, Creature *_Creature)
+{
+ player->ADD_GOSSIP_ITEM(0, GOSSIP_STORMWIND, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 10);
+ player->SEND_GOSSIP_MENU(13454,_Creature->GetGUID());
+ return true;
+}
+
+bool GossipSelect_npc_stormwind_harbor_taxi(Player *player, Creature *_Creature, uint32 sender, uint32 action )
+{
+ if (action == GOSSIP_ACTION_INFO_DEF + 10)
+ {
+ player->GetSession()->SendDoFlight(1149, 1041);
+ }
+ return true;
+}
+
void AddSC_stormwind_city()
{
Script *newscript;
@@ -260,7 +285,7 @@ void AddSC_stormwind_city()
newscript = new Script;
newscript->Name = "npc_general_marcus_jonathan";
- newscript->pReceiveEmote = &ReceiveEmote_npc_general_marcus_jonathan;
+ //newscript->pReceiveEmote = &ReceiveEmote_npc_general_marcus_jonathan;
newscript->RegisterSelf();
newscript = new Script;
@@ -268,5 +293,11 @@ void AddSC_stormwind_city()
newscript->pGossipHello = &GossipHello_npc_lady_katrana_prestor;
newscript->pGossipSelect = &GossipSelect_npc_lady_katrana_prestor;
newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="npc_stormwind_harbor_taxi";
+ newscript->pGossipHello = &GossipHello_npc_stormwind_harbor_taxi;
+ newscript->pGossipSelect = &GossipSelect_npc_stormwind_harbor_taxi;
+ newscript->RegisterSelf();
}
diff --git a/src/bindings/scripts/scripts/zone/stranglethorn_vale/stranglethorn_vale.cpp b/src/bindings/scripts/scripts/zone/stranglethorn_vale/stranglethorn_vale.cpp
index c2aa57d8c49..2a46fe4d5dd 100644
--- a/src/bindings/scripts/scripts/zone/stranglethorn_vale/stranglethorn_vale.cpp
+++ b/src/bindings/scripts/scripts/zone/stranglethorn_vale/stranglethorn_vale.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/boss_baron_rivendare.cpp b/src/bindings/scripts/scripts/zone/stratholme/boss_baron_rivendare.cpp
index c8ad95038c0..aa897761344 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/boss_baron_rivendare.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/boss_baron_rivendare.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/boss_baroness_anastari.cpp b/src/bindings/scripts/scripts/zone/stratholme/boss_baroness_anastari.cpp
index c30f712a98b..57f70cf33dd 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/boss_baroness_anastari.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/boss_baroness_anastari.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/boss_cannon_master_willey.cpp b/src/bindings/scripts/scripts/zone/stratholme/boss_cannon_master_willey.cpp
index 08b754177bb..ce09bbc2cd0 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/boss_cannon_master_willey.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/boss_cannon_master_willey.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/boss_dathrohan_balnazzar.cpp b/src/bindings/scripts/scripts/zone/stratholme/boss_dathrohan_balnazzar.cpp
index 0e70b4a3b43..5b85cdc07fe 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/boss_dathrohan_balnazzar.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/boss_dathrohan_balnazzar.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/boss_magistrate_barthilas.cpp b/src/bindings/scripts/scripts/zone/stratholme/boss_magistrate_barthilas.cpp
index 5d0eda58c37..9402c601219 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/boss_magistrate_barthilas.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/boss_magistrate_barthilas.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/boss_maleki_the_pallid.cpp b/src/bindings/scripts/scripts/zone/stratholme/boss_maleki_the_pallid.cpp
index 652dd48e766..e08c97965b1 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/boss_maleki_the_pallid.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/boss_maleki_the_pallid.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/boss_nerubenkan.cpp b/src/bindings/scripts/scripts/zone/stratholme/boss_nerubenkan.cpp
index db425ebcca0..3233e5c9c50 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/boss_nerubenkan.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/boss_nerubenkan.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/boss_order_of_silver_hand.cpp b/src/bindings/scripts/scripts/zone/stratholme/boss_order_of_silver_hand.cpp
index 86602f40d34..9c2084f6cec 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/boss_order_of_silver_hand.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/boss_order_of_silver_hand.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/boss_postmaster_malown.cpp b/src/bindings/scripts/scripts/zone/stratholme/boss_postmaster_malown.cpp
index d6a87d43d8b..a8ed628ffc0 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/boss_postmaster_malown.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/boss_postmaster_malown.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/boss_ramstein_the_gorger.cpp b/src/bindings/scripts/scripts/zone/stratholme/boss_ramstein_the_gorger.cpp
index 2e16dc883cc..6ef1477ff35 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/boss_ramstein_the_gorger.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/boss_ramstein_the_gorger.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/boss_timmy_the_cruel.cpp b/src/bindings/scripts/scripts/zone/stratholme/boss_timmy_the_cruel.cpp
index f41c5f013b6..0555c5da57d 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/boss_timmy_the_cruel.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/boss_timmy_the_cruel.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/stratholme/def_stratholme.h b/src/bindings/scripts/scripts/zone/stratholme/def_stratholme.h
index 79dd277c999..b9246091a7c 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/def_stratholme.h
+++ b/src/bindings/scripts/scripts/zone/stratholme/def_stratholme.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/stratholme/instance_stratholme.cpp b/src/bindings/scripts/scripts/zone/stratholme/instance_stratholme.cpp
index 142c38f06d6..200195d76af 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/instance_stratholme.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/instance_stratholme.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -280,10 +280,10 @@ struct TRINITY_DLL_DECL instance_stratholme : public ScriptedInstance
if (!pGroupie)
continue;
- if (pGroupie->HasAura(SPELL_BARON_ULTIMATUM,0))
+ if (pGroupie->HasAura(SPELL_BARON_ULTIMATUM))
pGroupie->RemoveAurasDueToSpell(SPELL_BARON_ULTIMATUM);
}
- } else if (player->HasAura(SPELL_BARON_ULTIMATUM,0))
+ } else if (player->HasAura(SPELL_BARON_ULTIMATUM))
player->RemoveAurasDueToSpell(SPELL_BARON_ULTIMATUM);
if (Unit *temp = Unit::GetUnit(*player,GetData64(DATA_BARON)))
diff --git a/src/bindings/scripts/scripts/zone/stratholme/stratholme.cpp b/src/bindings/scripts/scripts/zone/stratholme/stratholme.cpp
index f22ca652fff..d7f16105f07 100644
--- a/src/bindings/scripts/scripts/zone/stratholme/stratholme.cpp
+++ b/src/bindings/scripts/scripts/zone/stratholme/stratholme.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -54,12 +54,12 @@ bool GOHello_go_gauntlet_gate(Player *player, GameObject* _GO)
continue;
if (pGroupie->GetQuestStatus(QUEST_DEAD_MAN_PLEA) == QUEST_STATUS_INCOMPLETE &&
- !pGroupie->HasAura(SPELL_BARON_ULTIMATUM,0) &&
+ !pGroupie->HasAura(SPELL_BARON_ULTIMATUM) &&
pGroupie->GetMap() == _GO->GetMap())
pGroupie->CastSpell(pGroupie,SPELL_BARON_ULTIMATUM,true);
}
} else if (player->GetQuestStatus(QUEST_DEAD_MAN_PLEA) == QUEST_STATUS_INCOMPLETE &&
- !player->HasAura(SPELL_BARON_ULTIMATUM,0) &&
+ !player->HasAura(SPELL_BARON_ULTIMATUM) &&
player->GetMap() == _GO->GetMap())
player->CastSpell(player,SPELL_BARON_ULTIMATUM,true);
@@ -72,10 +72,10 @@ bool GOHello_go_gauntlet_gate(Player *player, GameObject* _GO)
######*/
//Possibly more of these quotes around.
-#define SAY_ZAPPED0 "Thanks to Egan"
-#define SAY_ZAPPED1 "Rivendare must die"
-#define SAY_ZAPPED2 "Who you gonna call?"
-#define SAY_ZAPPED3 "Don't cross those beams!"
+#define SAY_ZAPPED0 -1329000
+#define SAY_ZAPPED1 -1329001
+#define SAY_ZAPPED2 -1329002
+#define SAY_ZAPPED3 -1329003
struct TRINITY_DLL_DECL mob_freed_soulAI : public ScriptedAI
{
@@ -85,10 +85,10 @@ struct TRINITY_DLL_DECL mob_freed_soulAI : public ScriptedAI
{
switch (rand()%4)
{
- case 0: DoSay(SAY_ZAPPED0,LANG_UNIVERSAL,NULL); break;
- case 1: DoSay(SAY_ZAPPED1,LANG_UNIVERSAL,NULL); break;
- case 2: DoSay(SAY_ZAPPED2,LANG_UNIVERSAL,NULL); break;
- case 3: DoSay(SAY_ZAPPED3,LANG_UNIVERSAL,NULL); break;
+ case 0: DoScriptText(SAY_ZAPPED0, m_creature); break;
+ case 1: DoScriptText(SAY_ZAPPED1, m_creature); break;
+ case 2: DoScriptText(SAY_ZAPPED2, m_creature); break;
+ case 3: DoScriptText(SAY_ZAPPED3, m_creature); break;
}
}
@@ -227,6 +227,32 @@ struct TRINITY_DLL_DECL mobs_spectral_ghostly_citizenAI : public ScriptedAI
DoMeleeAttackIfReady();
}
+
+ void ReciveEmote(Player *player, uint32 emote)
+ {
+ switch(emote)
+ {
+ case TEXTEMOTE_DANCE:
+ EnterEvadeMode();
+ break;
+ case TEXTEMOTE_RUDE:
+ //Should instead cast spell, kicking player back. Spell not found.
+ if (m_creature->IsWithinDistInMap(player, 5))
+ m_creature->HandleEmoteCommand(EMOTE_ONESHOT_RUDE);
+ else
+ m_creature->HandleEmoteCommand(EMOTE_ONESHOT_RUDE);
+ break;
+ case TEXTEMOTE_WAVE:
+ m_creature->HandleEmoteCommand(EMOTE_ONESHOT_WAVE);
+ break;
+ case TEXTEMOTE_BOW:
+ m_creature->HandleEmoteCommand(EMOTE_ONESHOT_BOW);
+ break;
+ case TEXTEMOTE_KISS:
+ m_creature->HandleEmoteCommand(EMOTE_ONESHOT_FLEX);
+ break;
+ }
+ }
};
CreatureAI* GetAI_mobs_spectral_ghostly_citizen(Creature *_Creature)
@@ -234,34 +260,6 @@ CreatureAI* GetAI_mobs_spectral_ghostly_citizen(Creature *_Creature)
return new mobs_spectral_ghostly_citizenAI (_Creature);
}
-bool ReciveEmote_mobs_spectral_ghostly_citizen(Player *player, Creature *_Creature, uint32 emote)
-{
- switch(emote)
- {
- case TEXTEMOTE_DANCE:
- ((mobs_spectral_ghostly_citizenAI*)_Creature->AI())->EnterEvadeMode();
- break;
- case TEXTEMOTE_RUDE:
- //Should instead cast spell, kicking player back. Spell not found.
- if (_Creature->IsWithinDistInMap(player, 5))
- _Creature->HandleEmoteCommand(EMOTE_ONESHOT_RUDE);
- else
- _Creature->HandleEmoteCommand(EMOTE_ONESHOT_RUDE);
- break;
- case TEXTEMOTE_WAVE:
- _Creature->HandleEmoteCommand(EMOTE_ONESHOT_WAVE);
- break;
- case TEXTEMOTE_BOW:
- _Creature->HandleEmoteCommand(EMOTE_ONESHOT_BOW);
- break;
- case TEXTEMOTE_KISS:
- _Creature->HandleEmoteCommand(EMOTE_ONESHOT_FLEX);
- break;
- }
-
- return true;
-}
-
void AddSC_stratholme()
{
Script *newscript;
@@ -284,7 +282,6 @@ void AddSC_stratholme()
newscript = new Script;
newscript->Name = "mobs_spectral_ghostly_citizen";
newscript->GetAI = &GetAI_mobs_spectral_ghostly_citizen;
- newscript->pReceiveEmote = &ReciveEmote_mobs_spectral_ghostly_citizen;
newscript->RegisterSelf();
}
diff --git a/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_brutallus.cpp b/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_brutallus.cpp
index 539548af9da..e848557f859 100644
--- a/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_brutallus.cpp
+++ b/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_brutallus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -133,7 +133,7 @@ struct TRINITY_DLL_DECL boss_brutallusAI : public ScriptedAI
Unit *Target = m_creature->getVictim();
DoCast(Target,SPELL_STOMP);
- if(Target->HasAura(45151,0)) Target->RemoveAura(45151,0);
+ if(Target->HasAura(45151)) Target->RemoveAura(45151);
StompTimer = 30000;
}else StompTimer -= diff;
diff --git a/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_eredar_twins.cpp b/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_eredar_twins.cpp
index 0b013d8fe93..34f0f98fef4 100644
--- a/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_eredar_twins.cpp
+++ b/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_eredar_twins.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -209,9 +209,9 @@ struct TRINITY_DLL_DECL boss_sacrolashAI : public ScriptedAI
switch(TouchedType)
{
case SPELL_FLAME_TOUCHED:
- if(!target->HasAura(SPELL_DARK_FLAME,0))
+ if(!target->HasAura(SPELL_DARK_FLAME))
{
- if(target->HasAura(SPELL_DARK_TOUCHED,0))
+ if(target->HasAura(SPELL_DARK_TOUCHED))
{
target->RemoveAurasDueToSpell(SPELL_DARK_TOUCHED);
target->CastSpell(target,SPELL_DARK_FLAME,true);
@@ -222,9 +222,9 @@ struct TRINITY_DLL_DECL boss_sacrolashAI : public ScriptedAI
}
break;
case SPELL_DARK_TOUCHED:
- if(!target->HasAura(SPELL_DARK_FLAME,0))
+ if(!target->HasAura(SPELL_DARK_FLAME))
{
- if(target->HasAura(SPELL_FLAME_TOUCHED,0))
+ if(target->HasAura(SPELL_FLAME_TOUCHED))
{
target->RemoveAurasDueToSpell(SPELL_FLAME_TOUCHED);
target->CastSpell(target,SPELL_DARK_FLAME,true);
@@ -507,9 +507,9 @@ struct TRINITY_DLL_DECL boss_alythessAI : public Scripted_NoMovementAI
switch(TouchedType)
{
case SPELL_FLAME_TOUCHED:
- if(!target->HasAura(SPELL_DARK_FLAME,0))
+ if(!target->HasAura(SPELL_DARK_FLAME))
{
- if(target->HasAura(SPELL_DARK_TOUCHED,0))
+ if(target->HasAura(SPELL_DARK_TOUCHED))
{
target->RemoveAurasDueToSpell(SPELL_DARK_TOUCHED);
target->CastSpell(target,SPELL_DARK_FLAME,true);
@@ -520,9 +520,9 @@ struct TRINITY_DLL_DECL boss_alythessAI : public Scripted_NoMovementAI
}
break;
case SPELL_DARK_TOUCHED:
- if(!target->HasAura(SPELL_DARK_FLAME,0))
+ if(!target->HasAura(SPELL_DARK_FLAME))
{
- if(target->HasAura(SPELL_FLAME_TOUCHED,0))
+ if(target->HasAura(SPELL_FLAME_TOUCHED))
{
target->RemoveAurasDueToSpell(SPELL_FLAME_TOUCHED);
target->CastSpell(target,SPELL_DARK_FLAME,true);
@@ -543,31 +543,31 @@ struct TRINITY_DLL_DECL boss_alythessAI : public Scripted_NoMovementAI
case 0: DoPlaySoundToSet(m_creature,SOUND_INTRO); return 0;
case 1:
if(Sacrolash)
- Sacrolash->Yell(YELL_INTRO_SAC_1, LANG_UNIVERSAL,NULL);
+ Sacrolash->MonsterYell(YELL_INTRO_SAC_1, LANG_UNIVERSAL,NULL);
return 1000;
case 2:
- m_creature->Yell(YELL_INTRO_ALY_2, LANG_UNIVERSAL,NULL);
+ m_creature->MonsterYell(YELL_INTRO_ALY_2, LANG_UNIVERSAL,NULL);
return 1000;
case 3:
if(Sacrolash)
- Sacrolash->Yell(YELL_INTRO_SAC_3, LANG_UNIVERSAL,NULL);
+ Sacrolash->MonsterYell(YELL_INTRO_SAC_3, LANG_UNIVERSAL,NULL);
return 2000;
case 4:
- m_creature->Yell(YELL_INTRO_ALY_4, LANG_UNIVERSAL,NULL);
+ m_creature->MonsterYell(YELL_INTRO_ALY_4, LANG_UNIVERSAL,NULL);
return 1000;
case 5:
if(Sacrolash)
- Sacrolash->Yell(YELL_INTRO_SAC_5, LANG_UNIVERSAL,NULL);
+ Sacrolash->MonsterYell(YELL_INTRO_SAC_5, LANG_UNIVERSAL,NULL);
return 2000;
case 6:
- m_creature->Yell(YELL_INTRO_ALY_6, LANG_UNIVERSAL,NULL);
+ m_creature->MonsterYell(YELL_INTRO_ALY_6, LANG_UNIVERSAL,NULL);
return 1000;
case 7:
if(Sacrolash)
- Sacrolash->Yell(YELL_INTRO_SAC_7, LANG_UNIVERSAL,NULL);
+ Sacrolash->MonsterYell(YELL_INTRO_SAC_7, LANG_UNIVERSAL,NULL);
return 3000;
case 8:
- m_creature->Yell(YELL_INTRO_ALY_8, LANG_UNIVERSAL,NULL);
+ m_creature->MonsterYell(YELL_INTRO_ALY_8, LANG_UNIVERSAL,NULL);
return 900000;
}
return 10000;
@@ -709,9 +709,9 @@ struct TRINITY_DLL_DECL mob_shadow_imageAI : public ScriptedAI
case SPELL_SHADOW_FURY:
case SPELL_DARK_STRIKE:
- if(!target->HasAura(SPELL_DARK_FLAME,0))
+ if(!target->HasAura(SPELL_DARK_FLAME))
{
- if(target->HasAura(SPELL_FLAME_TOUCHED,0))
+ if(target->HasAura(SPELL_FLAME_TOUCHED))
{
target->RemoveAurasDueToSpell(SPELL_FLAME_TOUCHED);
target->CastSpell(target,SPELL_DARK_FLAME,true);
@@ -726,7 +726,7 @@ struct TRINITY_DLL_DECL mob_shadow_imageAI : public ScriptedAI
void UpdateAI(const uint32 diff)
{
- if(!m_creature->HasAura(SPELL_IMAGE_VISUAL,0))
+ if(!m_creature->HasAura(SPELL_IMAGE_VISUAL))
DoCast(m_creature,SPELL_IMAGE_VISUAL);
if(kill_timer < diff)
diff --git a/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_felmyst.cpp b/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_felmyst.cpp
index 68bb0ae8e44..442ac05816c 100644
--- a/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_felmyst.cpp
+++ b/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_felmyst.cpp
@@ -491,7 +491,7 @@ struct TRINITY_DLL_DECL boss_felmystAI : public ScriptedAI
cell.SetNoCreate();
Trinity::AllCreaturesOfEntryInRange check(m_creature, entry, 100);
- Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(templist, check);
+ Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(m_creature, templist, check);
TypeContainerVisitor<Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange>, GridTypeMapContainer> cSearcher(searcher);
diff --git a/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_kalecgos.cpp b/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_kalecgos.cpp
index 23c783ffa88..c39c14b7f20 100644
--- a/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_kalecgos.cpp
+++ b/src/bindings/scripts/scripts/zone/sunwell_plateau/boss_kalecgos.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -133,7 +133,7 @@ struct TRINITY_DLL_DECL boss_kalecgosAI : public ScriptedAI
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE + UNIT_FLAG_NOT_SELECTABLE);
m_creature->RemoveUnitMovementFlag(MOVEMENTFLAG_ONTRANSPORT + MOVEMENTFLAG_LEVITATING);
m_creature->SetVisibility(VISIBILITY_ON);
- m_creature->SetStandState(PLAYER_STATE_SLEEP);
+ m_creature->SetStandState(UNIT_STAND_STATE_SLEEP);
ArcaneBuffetTimer = 8000;
FrostBreathTimer = 15000;
@@ -157,7 +157,7 @@ struct TRINITY_DLL_DECL boss_kalecgosAI : public ScriptedAI
void Aggro(Unit* who)
{
- m_creature->SetStandState(PLAYER_STATE_NONE);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
DoScriptText(SAY_EVIL_AGGRO, m_creature);
GameObject *Door = GameObject::GetGameObject(*m_creature, DoorGUID);
if(Door) Door->SetLootState(GO_ACTIVATED);
@@ -384,7 +384,7 @@ struct TRINITY_DLL_DECL boss_sathrovarrAI : public ScriptedAI
if(ResetThreat < diff)
{
- if ( ( m_creature->getVictim()->HasAura(AURA_SPECTRAL_EXHAUSTION,0)) && (m_creature->getVictim()->GetTypeId() == TYPEID_PLAYER) )
+ if ( ( m_creature->getVictim()->HasAura(AURA_SPECTRAL_EXHAUSTION)) && (m_creature->getVictim()->GetTypeId() == TYPEID_PLAYER) )
{
for(std::list<HostilReference*>::iterator itr = m_creature->getThreatManager().getThreatList().begin(); itr != m_creature->getThreatManager().getThreatList().end(); ++itr)
{
@@ -609,7 +609,7 @@ void boss_kalecgosAI::UpdateAI(const uint32 diff)
{
//this is a hack. we need to find a victim without aura in core
Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 0);
- if( ( target != m_creature->getVictim() ) && target->isAlive() && !(target->HasAura(AURA_SPECTRAL_EXHAUSTION, 0)) )
+ if( ( target != m_creature->getVictim() ) && target->isAlive() && !(target->HasAura(AURA_SPECTRAL_EXHAUSTION)) )
{
DoCast(target, SPELL_SPECTRAL_BLAST);
SpectralBlastTimer = 20000+(rand()%5000);
@@ -626,7 +626,7 @@ void boss_kalecgosAI::UpdateAI(const uint32 diff)
bool GOkalocegos_teleporter(Player *player, GameObject* _GO)
{
- if(player->HasAura(AURA_SPECTRAL_EXHAUSTION, 0))
+ if(player->HasAura(AURA_SPECTRAL_EXHAUSTION))
player->GetSession()->SendNotification(GO_FAILED);
else
player->CastSpell(player, SPELL_TELEPORT_SPECTRAL, true);
diff --git a/src/bindings/scripts/scripts/zone/sunwell_plateau/def_sunwell_plateau.h b/src/bindings/scripts/scripts/zone/sunwell_plateau/def_sunwell_plateau.h
index 0844d5dffe6..8ae61602616 100644
--- a/src/bindings/scripts/scripts/zone/sunwell_plateau/def_sunwell_plateau.h
+++ b/src/bindings/scripts/scripts/zone/sunwell_plateau/def_sunwell_plateau.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/sunwell_plateau/instance_sunwell_plateau.cpp b/src/bindings/scripts/scripts/zone/sunwell_plateau/instance_sunwell_plateau.cpp
index fd93aa15d6c..cd4f62584f0 100644
--- a/src/bindings/scripts/scripts/zone/sunwell_plateau/instance_sunwell_plateau.cpp
+++ b/src/bindings/scripts/scripts/zone/sunwell_plateau/instance_sunwell_plateau.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/tanaris/tanaris.cpp b/src/bindings/scripts/scripts/zone/tanaris/tanaris.cpp
index 45d9eba60d5..0278d40a7cb 100644
--- a/src/bindings/scripts/scripts/zone/tanaris/tanaris.cpp
+++ b/src/bindings/scripts/scripts/zone/tanaris/tanaris.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -191,7 +191,7 @@ struct TRINITY_DLL_DECL npc_custodian_of_timeAI : public npc_escortAI
if( who->GetTypeId() == TYPEID_PLAYER )
{
- if( ((Player*)who)->HasAura(34877,1) && ((Player*)who)->GetQuestStatus(10277) == QUEST_STATUS_INCOMPLETE )
+ if( ((Player*)who)->HasAura(34877) && ((Player*)who)->GetQuestStatus(10277) == QUEST_STATUS_INCOMPLETE )
{
float Radius = 10.0;
if( m_creature->IsWithinDistInMap(who, Radius) )
@@ -211,38 +211,11 @@ struct TRINITY_DLL_DECL npc_custodian_of_timeAI : public npc_escortAI
}
};
-CreatureAI* GetAI_npc_custodian_of_time(Creature *_Creature)
+CreatureAI* GetAI_npc_custodian_of_time(Creature* pCreature)
{
- npc_custodian_of_timeAI* custodian_of_timeAI = new npc_custodian_of_timeAI(_Creature);
-
- custodian_of_timeAI->AddWaypoint(0, -8535.57,-4212.61, -212.04);
- custodian_of_timeAI->AddWaypoint(1, -8456.48,-4211.77, -213.30);
- custodian_of_timeAI->AddWaypoint(2, -8374.93,-4250.21, -205.05,5000);
- custodian_of_timeAI->AddWaypoint(3, -8374.93,-4250.21, -204.38,16000);
- custodian_of_timeAI->AddWaypoint(4, -8374.93,-4250.21, -204.38,10000);
- custodian_of_timeAI->AddWaypoint(5, -8374.93,-4250.21, -204.38,2000);
- custodian_of_timeAI->AddWaypoint(6, -8439.40,-4180.05, -209.25);
- custodian_of_timeAI->AddWaypoint(7, -8437.82,-4120.84, -208.59,10000);
- custodian_of_timeAI->AddWaypoint(8, -8437.82,-4120.84, -208.59,16000);
- custodian_of_timeAI->AddWaypoint(9, -8437.82,-4120.84, -208.59,13000);
- custodian_of_timeAI->AddWaypoint(10, -8437.82,-4120.84, -208.59,18000);
- custodian_of_timeAI->AddWaypoint(11, -8437.82,-4120.84, -208.59,15000);
- custodian_of_timeAI->AddWaypoint(12, -8437.82,-4120.84, -208.59,2000);
- custodian_of_timeAI->AddWaypoint(13, -8467.26,-4198.63, -214.21);
- custodian_of_timeAI->AddWaypoint(14, -8667.76,-4252.13, -209.56);
- custodian_of_timeAI->AddWaypoint(15, -8703.71,-4234.58, -209.5,14000);
- custodian_of_timeAI->AddWaypoint(16, -8703.71,-4234.58, -209.5,2000);
- custodian_of_timeAI->AddWaypoint(17, -8642.81,-4304.37, -209.57);
- custodian_of_timeAI->AddWaypoint(18, -8649.06,-4394.36, -208.46,6000);
- custodian_of_timeAI->AddWaypoint(19, -8649.06,-4394.36, -208.46,18000);
- custodian_of_timeAI->AddWaypoint(20, -8649.06,-4394.36, -208.46,2000);
- custodian_of_timeAI->AddWaypoint(21, -8468.72,-4437.67, -215.45);
- custodian_of_timeAI->AddWaypoint(22, -8427.54,-4426, -211.13);
- custodian_of_timeAI->AddWaypoint(23, -8364.83,-4393.32, -205.91);
- custodian_of_timeAI->AddWaypoint(24, -8304.54,-4357.2, -208.2,18000);
- custodian_of_timeAI->AddWaypoint(25, -8304.54,-4357.2, -208.2,2000);
- custodian_of_timeAI->AddWaypoint(26, -8375.42,-4250.41, -205.14,5000);
- custodian_of_timeAI->AddWaypoint(27, -8375.42,-4250.41, -205.14,5000);
+ npc_custodian_of_timeAI* custodian_of_timeAI = new npc_custodian_of_timeAI(pCreature);
+
+ custodian_of_timeAI->FillPointMovementListForCreature();
return (CreatureAI*)custodian_of_timeAI;
}
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/arcatraz.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/arcatraz.cpp
index a61a9c9b163..b12a9eff520 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/arcatraz.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/arcatraz.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -347,7 +347,7 @@ struct TRINITY_DLL_DECL npc_warden_mellicharAI : public ScriptedAI
if( pInstance )
{
m_creature->InterruptNonMeleeSpells(true);
- m_creature->RemoveSpellsCausingAura(SPELL_AURA_DUMMY);
+ m_creature->RemoveAurasByType(SPELL_AURA_DUMMY);
switch( Phase )
{
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/boss_harbinger_skyriss.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/boss_harbinger_skyriss.cpp
index da2b392072a..ee8bacb930c 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/boss_harbinger_skyriss.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/boss_harbinger_skyriss.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/def_arcatraz.h b/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/def_arcatraz.h
index 76f8d575383..3f8dee8bbd0 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/def_arcatraz.h
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/def_arcatraz.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/instance_arcatraz.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/instance_arcatraz.cpp
index 5f1fb087655..a0d21e302b5 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/instance_arcatraz.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/arcatraz/instance_arcatraz.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_high_botanist_freywinn.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_high_botanist_freywinn.cpp
index c9f88c57b2d..85a644f7ab8 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_high_botanist_freywinn.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_high_botanist_freywinn.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_laj.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_laj.cpp
index e95d8328907..9a276ead142 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_laj.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_laj.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_warp_splinter.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_warp_splinter.cpp
index 5306aa690cf..bbd18dee029 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_warp_splinter.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/botanica/boss_warp_splinter.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_alar.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_alar.cpp
index 813222b52c9..3e5bbbf66da 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_alar.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_alar.cpp
@@ -241,12 +241,12 @@ struct TRINITY_DLL_DECL boss_alarAI : public ScriptedAI
WaitEvent = WE_DUMMY;
return;
case WE_DIE:
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, PLAYER_STATE_DEAD);
+ m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, UNIT_STAND_STATE_DEAD);
WaitTimer = 5000;
WaitEvent = WE_REVIVE;
return;
case WE_REVIVE:
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, PLAYER_STATE_NONE);
+ m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, UNIT_STAND_STATE_STAND);
m_creature->SetHealth(m_creature->GetMaxHealth());
m_creature->SetSpeed(MOVE_RUN, DefaultMoveSpeedRate);
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
@@ -348,7 +348,7 @@ struct TRINITY_DLL_DECL boss_alarAI : public ScriptedAI
if(Charge_Timer < diff)
{
- Unit *target= SelectUnit(SELECT_TARGET_RANDOM, 1, GetSpellMaxRange(SPELL_CHARGE), true);
+ Unit *target= SelectUnit(SELECT_TARGET_RANDOM, 1, GetSpellMaxRangeForHostile(SPELL_CHARGE), true);
DoCast(target, SPELL_CHARGE);
Charge_Timer = 30000;
}else Charge_Timer -= diff;
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_astromancer.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_astromancer.cpp
index bc215f8c683..340d3f23fc8 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_astromancer.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_astromancer.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -120,6 +120,7 @@ struct TRINITY_DLL_DECL boss_high_astromancer_solarianAI : public ScriptedAI
Jump_Timer=8000;
Wrath_Timer = 20000+rand()%5000;//twice in phase one
Phase = 1;
+ Wrath_Timer = 20000+rand()%5000;//twice in phase one
if(pInstance)
pInstance->SetData(DATA_HIGHASTROMANCERSOLARIANEVENT, NOT_STARTED);
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_kaelthas.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_kaelthas.cpp
index ae19cedf75a..dd1d9772f31 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_kaelthas.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_kaelthas.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -193,7 +193,7 @@ struct TRINITY_DLL_DECL advisorbase_ai : public ScriptedAI
if(pInstance && (pInstance->GetData(DATA_KAELTHASEVENT) == 1 || pInstance->GetData(DATA_KAELTHASEVENT) == 3))
{
Creature *Kaelthas = NULL;
- Kaelthas = (Creature*)(Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_KAELTHAS)));
+ Kaelthas = (Unit::GetCreature((*m_creature), pInstance->GetData64(DATA_KAELTHAS)));
if(Kaelthas)
Kaelthas->AI()->EnterEvadeMode();
@@ -238,7 +238,7 @@ struct TRINITY_DLL_DECL advisorbase_ai : public ScriptedAI
m_creature->SetUInt64Value(UNIT_FIELD_TARGET,0);
m_creature->GetMotionMaster()->Clear();
m_creature->GetMotionMaster()->MoveIdle();
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,PLAYER_STATE_DEAD);
+ m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1,UNIT_STAND_STATE_DEAD);
if (pInstance->GetData(DATA_KAELTHASEVENT) == 3)
JustDied(pKiller);
@@ -366,7 +366,7 @@ struct TRINITY_DLL_DECL boss_kaelthasAI : public ScriptedAI
Creature *pCreature;
for(uint8 i = 0; i < 4; ++i)
{
- pCreature = (Creature*)(Unit::GetUnit((*m_creature), AdvisorGuid[i]));
+ pCreature = (Unit::GetCreature((*m_creature), AdvisorGuid[i]));
if(pCreature)
{
pCreature->Respawn();
@@ -535,7 +535,7 @@ struct TRINITY_DLL_DECL boss_kaelthasAI : public ScriptedAI
case 1:
if(Phase_Timer < diff)
{
- Advisor = (Creature*)(Unit::GetUnit((*m_creature), AdvisorGuid[0]));
+ Advisor = (Unit::GetCreature((*m_creature), AdvisorGuid[0]));
if(Advisor)
{
@@ -553,8 +553,8 @@ struct TRINITY_DLL_DECL boss_kaelthasAI : public ScriptedAI
//Subphase 2 - Start
case 2:
- Advisor = (Creature*)(Unit::GetUnit((*m_creature), AdvisorGuid[0]));
- if(Advisor && (Advisor->GetUInt32Value(UNIT_FIELD_BYTES_1) == PLAYER_STATE_DEAD))
+ Advisor = (Unit::GetCreature((*m_creature), AdvisorGuid[0]));
+ if(Advisor && (Advisor->GetUInt32Value(UNIT_FIELD_BYTES_1) == UNIT_STAND_STATE_DEAD))
{
DoScriptText(SAY_INTRO_SANGUINAR, m_creature);
@@ -569,7 +569,7 @@ struct TRINITY_DLL_DECL boss_kaelthasAI : public ScriptedAI
case 3:
if(Phase_Timer < diff)
{
- Advisor = (Creature*)(Unit::GetUnit((*m_creature), AdvisorGuid[1]));
+ Advisor = (Unit::GetCreature((*m_creature), AdvisorGuid[1]));
if(Advisor)
{
@@ -587,8 +587,8 @@ struct TRINITY_DLL_DECL boss_kaelthasAI : public ScriptedAI
//Subphase 3 - Start
case 4:
- Advisor = (Creature*)(Unit::GetUnit((*m_creature), AdvisorGuid[1]));
- if(Advisor && (Advisor->GetUInt32Value(UNIT_FIELD_BYTES_1) == PLAYER_STATE_DEAD))
+ Advisor = (Unit::GetCreature((*m_creature), AdvisorGuid[1]));
+ if(Advisor && (Advisor->GetUInt32Value(UNIT_FIELD_BYTES_1) == UNIT_STAND_STATE_DEAD))
{
DoScriptText(SAY_INTRO_CAPERNIAN, m_creature);
@@ -603,7 +603,7 @@ struct TRINITY_DLL_DECL boss_kaelthasAI : public ScriptedAI
case 5:
if(Phase_Timer < diff)
{
- Advisor = (Creature*)(Unit::GetUnit((*m_creature), AdvisorGuid[2]));
+ Advisor = (Unit::GetCreature((*m_creature), AdvisorGuid[2]));
if(Advisor)
{
@@ -621,8 +621,8 @@ struct TRINITY_DLL_DECL boss_kaelthasAI : public ScriptedAI
//Subphase 4 - Start
case 6:
- Advisor = (Creature*)(Unit::GetUnit((*m_creature), AdvisorGuid[2]));
- if(Advisor && (Advisor->GetUInt32Value(UNIT_FIELD_BYTES_1) == PLAYER_STATE_DEAD))
+ Advisor = (Unit::GetCreature((*m_creature), AdvisorGuid[2]));
+ if(Advisor && (Advisor->GetUInt32Value(UNIT_FIELD_BYTES_1) == UNIT_STAND_STATE_DEAD))
{
DoScriptText(SAY_INTRO_TELONICUS, m_creature);
@@ -637,7 +637,7 @@ struct TRINITY_DLL_DECL boss_kaelthasAI : public ScriptedAI
case 7:
if(Phase_Timer < diff)
{
- Advisor = (Creature*)(Unit::GetUnit((*m_creature), AdvisorGuid[3]));
+ Advisor = (Unit::GetCreature((*m_creature), AdvisorGuid[3]));
if(Advisor)
{
@@ -657,8 +657,8 @@ struct TRINITY_DLL_DECL boss_kaelthasAI : public ScriptedAI
//End of phase 1
case 8:
- Advisor = (Creature*)(Unit::GetUnit((*m_creature), AdvisorGuid[3]));
- if(Advisor && (Advisor->GetUInt32Value(UNIT_FIELD_BYTES_1) == PLAYER_STATE_DEAD))
+ Advisor = (Unit::GetCreature((*m_creature), AdvisorGuid[3]));
+ if(Advisor && (Advisor->GetUInt32Value(UNIT_FIELD_BYTES_1) == UNIT_STAND_STATE_DEAD))
{
Phase = 2;
pInstance->SetData(DATA_KAELTHASEVENT, 2);
@@ -727,7 +727,7 @@ struct TRINITY_DLL_DECL boss_kaelthasAI : public ScriptedAI
Creature* Advisor;
for (uint32 i = 0; i < 4; ++i)
{
- Advisor = (Creature*)(Unit::GetUnit((*m_creature), AdvisorGuid[i]));
+ Advisor = (Unit::GetCreature((*m_creature), AdvisorGuid[i]));
if (!Advisor)
error_log("TSCR: Kael'Thas Advisor %u does not exist. Possibly despawned? Incorrectly Killed?", i);
else ((advisorbase_ai*)Advisor->AI())->Revive(Target);
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_void_reaver.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_void_reaver.cpp
index 708e5feffcd..65c8d2f87f3 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_void_reaver.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/boss_void_reaver.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/def_the_eye.h b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/def_the_eye.h
index 7162fb90199..d0d3ea09061 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/def_the_eye.h
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/def_the_eye.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/instance_the_eye.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/instance_the_eye.cpp
index c6352a9e67c..66e595ab729 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/instance_the_eye.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/instance_the_eye.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -77,7 +77,7 @@ struct TRINITY_DLL_DECL instance_the_eye : public ScriptedInstance
void OnCreatureCreate(Creature *creature, uint32 creature_entry)
{
- switch(creature_entry)
+ switch(creature->GetEntry())
{
case 20064: ThaladredTheDarkener = creature->GetGUID(); break;
case 20063: MasterEngineerTelonicus = creature->GetGUID(); break;
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/the_eye.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/the_eye.cpp
index ef3860c0581..7d73e08d9e5 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/the_eye.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_eye/the_eye.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_gyrokill.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_gyrokill.cpp
index c77989e27f3..268cfeb2918 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_gyrokill.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_gyrokill.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_ironhand.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_ironhand.cpp
index bd8fc581e9d..9bc8afc8aef 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_ironhand.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_gatewatcher_ironhand.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_nethermancer_sepethrea.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_nethermancer_sepethrea.cpp
index b3eddfa7ebe..b8cd2fc0cbe 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_nethermancer_sepethrea.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_nethermancer_sepethrea.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -109,7 +109,7 @@ struct TRINITY_DLL_DECL boss_nethermancer_sepethreaAI : public ScriptedAI
if(frost_attack_Timer < diff)
{
DoCast(m_creature->getVictim(),SPELL_FROST_ATTACK);
- frost_attack_Timer = 7000 + rand()%30000;
+ frost_attack_Timer = 7000 + rand()%3000;
}else frost_attack_Timer -= diff;
//Arcane Blast
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_pathaleon_the_calculator.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_pathaleon_the_calculator.cpp
index 338e115ef85..59f1748c9a5 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_pathaleon_the_calculator.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/boss_pathaleon_the_calculator.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/instance_mechanar.cpp b/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/instance_mechanar.cpp
index 05866eb27fb..e8806b62957 100644
--- a/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/instance_mechanar.cpp
+++ b/src/bindings/scripts/scripts/zone/tempest_keep/the_mechanar/instance_mechanar.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -56,7 +56,7 @@ struct TRINITY_DLL_DECL instance_mechanar : public ScriptedInstance
{
switch(type)
{
- case DATA_NETHERMANCER_EVENT: return Encounters[0];
+ case DATA_NETHERMANCER_EVENT: return Encounters[0];
}
return false;
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_bug_trio.cpp b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_bug_trio.cpp
index dc1e4df24ca..64c4fdae2c8 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_bug_trio.cpp
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_bug_trio.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_cthun.cpp b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_cthun.cpp
index c054340a4a5..86b04b28753 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_cthun.cpp
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_cthun.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -301,7 +301,7 @@ struct TRINITY_DLL_DECL eye_of_cthunAI : public Scripted_NoMovementAI
DoCast(m_creature,SPELL_RED_COLORATION);
//Freeze animation
- m_creature->setEmoteState(53);
+ m_creature->SetUInt32Value(UNIT_NPC_EMOTESTATE, 53);
//Darkbeam for 35 seconds
PhaseTimer = 35000;
@@ -351,7 +351,7 @@ struct TRINITY_DLL_DECL eye_of_cthunAI : public Scripted_NoMovementAI
m_creature->RemoveAurasDueToSpell(SPELL_RED_COLORATION);
//Freeze animation
- m_creature->setEmoteState(0);
+ m_creature->SetUInt32Value(UNIT_NPC_EMOTESTATE, 0);
m_creature->SetUInt32Value(UNIT_FIELD_FLAGS, 0);
//Eye Beam for 50 seconds
@@ -397,7 +397,7 @@ struct TRINITY_DLL_DECL eye_of_cthunAI : public Scripted_NoMovementAI
m_creature->RemoveAurasDueToSpell(SPELL_RED_COLORATION);
//Reset to normal emote state and prevent select and attack
- m_creature->setEmoteState(0);
+ m_creature->SetUInt32Value(UNIT_NPC_EMOTESTATE, 0);
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE | UNIT_FLAG_NON_ATTACKABLE);
//Remove Target field
@@ -566,13 +566,15 @@ struct TRINITY_DLL_DECL cthunAI : public Scripted_NoMovementAI
Map *map = m_creature->GetMap();
if(!map->IsDungeon()) return;
+ //Play random sound to the zone
Map::PlayerList const &PlayerList = map->GetPlayers();
- for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i)
+
+ if (!PlayerList.isEmpty())
{
- if (Player* i_pl = i->getSource())
+ for(Map::PlayerList::const_iterator itr = PlayerList.begin(); itr != PlayerList.end(); ++itr)
{
- //Play random sound to the zone
- i_pl->SendPlaySound(RANDOM_SOUND_WHISPER, true);
+ if (Player* pPlr = itr->getSource())
+ pPlr->PlayDirectSound(RANDOM_SOUND_WHISPER,pPlr);
}
}
@@ -963,7 +965,7 @@ struct TRINITY_DLL_DECL eye_tentacleAI : public Scripted_NoMovementAI
{
Unit* target = NULL;
target = SelectUnit(SELECT_TARGET_RANDOM,0);
- if (target && !target->HasAura(SPELL_DIGESTIVE_ACID, 0))
+ if (target && !target->HasAura(SPELL_DIGESTIVE_ACID))
DoCast(target,SPELL_MIND_FLAY);
//Mindflay every 10 seconds
@@ -1031,7 +1033,7 @@ struct TRINITY_DLL_DECL claw_tentacleAI : public Scripted_NoMovementAI
return;
}
- if (!target->HasAura(SPELL_DIGESTIVE_ACID, 0))
+ if (!target->HasAura(SPELL_DIGESTIVE_ACID))
{
m_creature->GetMap()->CreatureRelocation(m_creature, target->GetPositionX(), target->GetPositionY(), target->GetPositionZ(), 0);
Unit* p = DoSpawnCreature(MOB_SMALL_PORTAL,0,0,0,0,TEMPSUMMON_CORPSE_DESPAWN, 0);
@@ -1127,7 +1129,7 @@ struct TRINITY_DLL_DECL giant_claw_tentacleAI : public Scripted_NoMovementAI
return;
}
- if (!target->HasAura(SPELL_DIGESTIVE_ACID, 0))
+ if (!target->HasAura(SPELL_DIGESTIVE_ACID))
{
m_creature->GetMap()->CreatureRelocation(m_creature, target->GetPositionX(), target->GetPositionY(), target->GetPositionZ(), 0);
Unit* p = DoSpawnCreature(MOB_GIANT_PORTAL,0,0,0,0,TEMPSUMMON_CORPSE_DESPAWN, 0);
@@ -1211,7 +1213,7 @@ struct TRINITY_DLL_DECL giant_eye_tentacleAI : public Scripted_NoMovementAI
{
Unit* target = NULL;
target = SelectUnit(SELECT_TARGET_RANDOM,0);
- if (target && !target->HasAura(SPELL_DIGESTIVE_ACID, 0))
+ if (target && !target->HasAura(SPELL_DIGESTIVE_ACID))
DoCast(target,SPELL_GREEN_BEAM);
//Beam every 2 seconds
@@ -1249,7 +1251,7 @@ void flesh_tentacleAI::JustDied(Unit* killer)
{
if (!Parent)
{
- DoYell("Error: No Parent variable", LANG_UNIVERSAL, NULL);
+ error_log("TSCR: flesh_tentacle: No Parent variable");
return;
}
@@ -1257,7 +1259,7 @@ void flesh_tentacleAI::JustDied(Unit* killer)
if (Cthun)
((cthunAI*)(Cthun->AI()))->FleshTentcleKilled();
- else DoYell("Error: No Cthun", LANG_UNIVERSAL, NULL);
+ else error_log("TSCR: flesh_tentacle: No Cthun");
}
//GetAIs
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_fankriss.cpp b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_fankriss.cpp
index 0888c395489..9315817a460 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_fankriss.cpp
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_fankriss.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -135,34 +135,46 @@ struct TRINITY_DLL_DECL boss_fankrissAI : public ScriptedAI
case 0:
DoTeleportPlayer(target, -8106.0142,1289.2900,-74.419533,5.112);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-3, target->GetPositionY()-3, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-3, target->GetPositionY()+3, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-5, target->GetPositionY()-5, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-5, target->GetPositionY()+5, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
break;
case 1:
DoTeleportPlayer(target, -7990.135354,1155.1907,-78.849319,2.608);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-3, target->GetPositionY()-3, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-3, target->GetPositionY()+3, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-5, target->GetPositionY()-5, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-5, target->GetPositionY()+5, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
break;
case 2:
DoTeleportPlayer(target,-8159.7753,1127.9064,-76.868660,0.675);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-3, target->GetPositionY()-3, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-3, target->GetPositionY()+3, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-5, target->GetPositionY()-5, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
Hatchling = m_creature->SummonCreature(15962, target->GetPositionX()-5, target->GetPositionY()+5, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Hatchling)
((CreatureAI*)Hatchling->AI())->AttackStart(target);
break;
}
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_huhuran.cpp b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_huhuran.cpp
index 484a6260c86..3456fd19d87 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_huhuran.cpp
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_huhuran.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,6 +23,9 @@ EndScriptData */
#include "precompiled.h"
+#define EMOTE_GENERIC_FRENZY_KILL -1000001
+#define EMOTE_GENERIC_BERSERK -1000004
+
#define SPELL_FRENZY 26051
#define SPELL_BERSERK 26068
#define SPELL_POISONBOLT 26052
@@ -71,6 +74,7 @@ struct TRINITY_DLL_DECL boss_huhuranAI : public ScriptedAI
if (!Frenzy && Frenzy_Timer < diff)
{
DoCast(m_creature, SPELL_FRENZY);
+ DoScriptText(EMOTE_GENERIC_FRENZY_KILL, m_creature);
Frenzy = true;
PoisonBolt_Timer = 3000;
Frenzy_Timer = 25000 + rand()%10000;
@@ -119,7 +123,7 @@ struct TRINITY_DLL_DECL boss_huhuranAI : public ScriptedAI
if ( !Berserk && m_creature->GetHealth()*100 / m_creature->GetMaxHealth() < 31 )
{
m_creature->InterruptNonMeleeSpells(false);
- DoTextEmote("is going berserk", NULL);
+ DoScriptText(EMOTE_GENERIC_BERSERK, m_creature);
DoCast(m_creature, SPELL_BERSERK);
Berserk = true;
}
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_ouro.cpp b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_ouro.cpp
index 7f5827d398b..a5721c4bc92 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_ouro.cpp
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_ouro.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_sartura.cpp b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_sartura.cpp
index a9b0578279d..b1a0b4bdfea 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_sartura.cpp
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_sartura.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -94,8 +94,12 @@ struct TRINITY_DLL_DECL boss_sarturaAI : public ScriptedAI
if (WhirlWindRandom_Timer < diff)
{
//Attack random Gamers
- if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM,1))
- AttackStart(target);
+ Unit* target = NULL;
+ target = SelectUnit(SELECT_TARGET_RANDOM,1);
+ if (target)
+ m_creature->AddThreat(target, 1.0f);
+ m_creature->TauntApply(target);
+ AttackStart(target);
WhirlWindRandom_Timer = 3000 + rand()%4000;
}else WhirlWindRandom_Timer -= diff;
@@ -119,8 +123,12 @@ struct TRINITY_DLL_DECL boss_sarturaAI : public ScriptedAI
if (AggroReset_Timer < diff)
{
//Attack random Gamers
- if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM,1))
- m_creature->TauntApply(target);
+ Unit* target = NULL;
+ target = SelectUnit(SELECT_TARGET_RANDOM,1);
+ if (target)
+ m_creature->AddThreat(target, 1.0f);
+ m_creature->TauntApply(target);
+ AttackStart(target);
AggroReset = true;
AggroReset_Timer = 2000 + rand()%3000;
@@ -213,8 +221,12 @@ struct TRINITY_DLL_DECL mob_sartura_royal_guardAI : public ScriptedAI
if (WhirlWindRandom_Timer < diff)
{
//Attack random Gamers
- if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM,1))
- m_creature->TauntApply(target);
+ Unit* target = NULL;
+ target = SelectUnit(SELECT_TARGET_RANDOM,1);
+ if (target)
+ m_creature->AddThreat(target, 1.0f);
+ m_creature->TauntApply(target);
+ AttackStart(target);
WhirlWindRandom_Timer = 3000 + rand()%4000;
}else WhirlWindRandom_Timer -= diff;
@@ -230,8 +242,12 @@ struct TRINITY_DLL_DECL mob_sartura_royal_guardAI : public ScriptedAI
if (AggroReset_Timer < diff)
{
//Attack random Gamers
- if (Unit* target = SelectUnit(SELECT_TARGET_RANDOM,1))
- AttackStart(target);
+ Unit* target = NULL;
+ target = SelectUnit(SELECT_TARGET_RANDOM,1);
+ if (target)
+ m_creature->AddThreat(target, 1.0f);
+ m_creature->TauntApply(target);
+ AttackStart(target);
AggroReset = true;
AggroReset_Timer = 2000 + rand()%3000;
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_skeram.cpp b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_skeram.cpp
index 84311d725f5..c4f9401f869 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_skeram.cpp
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_skeram.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -261,6 +261,9 @@ struct TRINITY_DLL_DECL boss_skeramAI : public ScriptedAI
m_creature->SetVisibility(VISIBILITY_OFF);
m_creature->Relocate(bossc->x, bossc->y, bossc->z, bossc->r);
Invisible = true;
+ delete place1;
+ delete place2;
+ delete place3;
DoResetThreat();
DoStopAttack();
@@ -274,20 +277,24 @@ struct TRINITY_DLL_DECL boss_skeramAI : public ScriptedAI
Unit* target = SelectUnit(SELECT_TARGET_RANDOM,0);
Image1 = m_creature->SummonCreature(15263, i1->x, i1->y, i1->z, i1->r, TEMPSUMMON_CORPSE_DESPAWN, 30000);
- Image1->SetMaxHealth(m_creature->GetMaxHealth() / 5);
- Image1->SetHealth(m_creature->GetHealth() / 5);
- if (target)
- Image1->AI()->AttackStart(target);
+ if (Image1)
+ {
+ Image1->SetMaxHealth(m_creature->GetMaxHealth() / 5);
+ Image1->SetHealth(m_creature->GetHealth() / 5);
+ if (target)
+ Image1->AI()->AttackStart(target);
+ ((boss_skeramAI*)Image1->AI())->IsImage = true;
+ }
Image2 = m_creature->SummonCreature(15263,i2->x, i2->y, i2->z, i2->r, TEMPSUMMON_CORPSE_DESPAWN, 30000);
- Image2->SetMaxHealth(m_creature->GetMaxHealth() / 5);
- Image2->SetHealth(m_creature->GetHealth() / 5);
- if (target)
- Image2->AI()->AttackStart(target);
-
- ((boss_skeramAI*)Image1->AI())->IsImage = true;
- ((boss_skeramAI*)Image2->AI())->IsImage = true;
-
+ if (Image2)
+ {
+ Image2->SetMaxHealth(m_creature->GetMaxHealth() / 5);
+ Image2->SetHealth(m_creature->GetHealth() / 5);
+ if (target)
+ Image2->AI()->AttackStart(target);
+ ((boss_skeramAI*)Image2->AI())->IsImage = true;
+ }
Invisible = true;
}
};
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_twinemperors.cpp b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_twinemperors.cpp
index c707ad23cee..0abaf8e79d9 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_twinemperors.cpp
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_twinemperors.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -336,7 +336,7 @@ struct TRINITY_DLL_DECL boss_twinemperorsAI : public ScriptedAI
std::list<Creature*> unitList;
AnyBugCheck u_check(m_creature, 150);
- Trinity::CreatureListSearcher<AnyBugCheck> searcher(unitList, u_check);
+ Trinity::CreatureListSearcher<AnyBugCheck> searcher(m_creature, unitList, u_check);
TypeContainerVisitor<Trinity::CreatureListSearcher<AnyBugCheck>, GridTypeMapContainer > grid_creature_searcher(searcher);
CellLock<GridReadGuard> cell_lock(cell, p);
cell_lock->Visit(cell_lock, grid_creature_searcher, *(m_creature->GetMap()));
@@ -404,13 +404,6 @@ struct TRINITY_DLL_DECL boss_twinemperorsAI : public ScriptedAI
}
};
-class TRINITY_DLL_DECL BugAura : public Aura
-{
- public:
- BugAura(SpellEntry *spell, uint32 eff, int32 *bp, Unit *target, Unit *caster) : Aura(spell, eff, bp, target, caster, NULL)
- {}
-};
-
struct TRINITY_DLL_DECL boss_veknilashAI : public boss_twinemperorsAI
{
bool IAmVeklor() {return false;}
@@ -441,12 +434,14 @@ struct TRINITY_DLL_DECL boss_veknilashAI : public boss_twinemperorsAI
target->setFaction(14);
((CreatureAI*)target->AI())->AttackStart(m_creature->getThreatManager().getHostilTarget());
SpellEntry *spell = (SpellEntry *)GetSpellStore()->LookupEntry(SPELL_MUTATE_BUG);
+ uint8 eff_mask=0;
for (int i=0; i<3; i++)
{
if (!spell->Effect[i])
continue;
- target->AddAura(new BugAura(spell, i, NULL, target, target));
+ eff_mask|=1<<i;
}
+ target->AddAura(new Aura(spell, eff_mask, NULL, target, target));
target->SetHealth(target->GetMaxHealth());
}
@@ -524,12 +519,14 @@ struct TRINITY_DLL_DECL boss_veklorAI : public boss_twinemperorsAI
{
target->setFaction(14);
SpellEntry *spell = (SpellEntry *)GetSpellStore()->LookupEntry(SPELL_EXPLODEBUG);
+ uint8 eff_mask=0;
for (int i=0; i<3; i++)
{
if (!spell->Effect[i])
continue;
- target->AddAura(new BugAura(spell, i, NULL, target, target));
+ eff_mask|=1<<i;
}
+ target->AddAura(new Aura(spell, eff_mask, NULL, target, target));
target->SetHealth(target->GetMaxHealth());
}
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_viscidus.cpp b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_viscidus.cpp
index 7b310dfe10d..2bb9f1bfb0b 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_viscidus.cpp
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/boss_viscidus.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/def_temple_of_ahnqiraj.h b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/def_temple_of_ahnqiraj.h
index 95db307f778..5d545ed7c74 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/def_temple_of_ahnqiraj.h
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/def_temple_of_ahnqiraj.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/instance_temple_of_ahnqiraj.cpp b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/instance_temple_of_ahnqiraj.cpp
index 7ca0f33566f..9048591b774 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/instance_temple_of_ahnqiraj.cpp
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/instance_temple_of_ahnqiraj.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/mob_anubisath_sentinel.cpp b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/mob_anubisath_sentinel.cpp
index fd3e7c56cb1..0899fa5a610 100644
--- a/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/mob_anubisath_sentinel.cpp
+++ b/src/bindings/scripts/scripts/zone/temple_of_ahnqiraj/mob_anubisath_sentinel.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -174,7 +174,7 @@ struct TRINITY_DLL_DECL aqsentinelAI : public ScriptedAI
std::list<Creature*> assistList;
NearbyAQSentinel u_check(nears);
- Trinity::CreatureListSearcher<NearbyAQSentinel> searcher(assistList, u_check);
+ Trinity::CreatureListSearcher<NearbyAQSentinel> searcher(m_creature, assistList, u_check);
TypeContainerVisitor<Trinity::CreatureListSearcher<NearbyAQSentinel>, GridTypeMapContainer > grid_creature_searcher(searcher);
CellLock<GridReadGuard> cell_lock(cell, p);
cell_lock->Visit(cell_lock, grid_creature_searcher, *(nears->GetMap()));
@@ -220,6 +220,8 @@ struct TRINITY_DLL_DECL aqsentinelAI : public ScriptedAI
DoYell("I dont have enough buddies.", LANG_NEUTRAL, 0);*/
SendMyListToBuddies();
CallBuddiesToAttack(who);
+
+ delete[] chosenAbilities;
}
bool gatherOthersWhenAggro;
@@ -245,13 +247,16 @@ struct TRINITY_DLL_DECL aqsentinelAI : public ScriptedAI
void GainSentinelAbility(uint32 id)
{
const SpellEntry *spell = GetSpellStore()->LookupEntry(id);
+ uint8 eff_mask=0;
for (int i=0; i<3; i++)
{
if (!spell->Effect[i])
continue;
- SentinelAbilityAura *a = new SentinelAbilityAura(this, (SpellEntry *)spell, id, i);
- m_creature->AddAura(a);
+ eff_mask=1<<i;
}
+ SentinelAbilityAura *a = new SentinelAbilityAura(this, (SpellEntry *)spell, id, eff_mask);
+ m_creature->AddAura(a);
+
if (id == SPELL_KNOCK_BUFF)
{
m_creature->ApplySpellImmune(0, IMMUNITY_STATE, SPELL_AURA_MOD_TAUNT, true);
@@ -339,6 +344,5 @@ SentinelAbilityAura::SentinelAbilityAura(aqsentinelAI *abilityOwner, SpellEntry
{
aOwner = abilityOwner;
abilityId = ability;
- currentBasePoints = 0;
}
diff --git a/src/bindings/scripts/scripts/zone/terokkar_forest/terokkar_forest.cpp b/src/bindings/scripts/scripts/zone/terokkar_forest/terokkar_forest.cpp
index 9e7e809ba66..6deaa769ae5 100644
--- a/src/bindings/scripts/scripts/zone/terokkar_forest/terokkar_forest.cpp
+++ b/src/bindings/scripts/scripts/zone/terokkar_forest/terokkar_forest.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -60,7 +60,7 @@ struct TRINITY_DLL_DECL mob_unkor_the_ruthlessAI : public ScriptedAI
CanDoQuest = false;
UnkorUnfriendly_Timer = 0;
Pulverize_Timer = 3000;
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, PLAYER_STATE_NONE);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
m_creature->setFaction(FACTION_HOSTILE);
}
@@ -70,7 +70,7 @@ struct TRINITY_DLL_DECL mob_unkor_the_ruthlessAI : public ScriptedAI
{
DoScriptText(SAY_SUBMIT, m_creature);
m_creature->setFaction(FACTION_FRIENDLY);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, PLAYER_STATE_SIT);
+ m_creature->SetStandState(UNIT_STAND_STATE_SIT);
m_creature->RemoveAllAuras();
m_creature->DeleteThreatList();
m_creature->CombatStop();
diff --git a/src/bindings/scripts/scripts/zone/thousand_needles/thousand_needles.cpp b/src/bindings/scripts/scripts/zone/thousand_needles/thousand_needles.cpp
index 4e81d44a610..4c9c76010ca 100644
--- a/src/bindings/scripts/scripts/zone/thousand_needles/thousand_needles.cpp
+++ b/src/bindings/scripts/scripts/zone/thousand_needles/thousand_needles.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -259,19 +259,17 @@ struct TRINITY_DLL_DECL npc_pluckyAI : public ScriptedAI
DoMeleeAttackIfReady();
}
-};
-bool ReceiveEmote_npc_plucky( Player *player, Creature *_Creature, uint32 emote )
-{
- if( (emote == TEXTEMOTE_BECKON || emote == TEXTEMOTE_CHICKEN &&
- player->GetQuestStatus(QUEST_GET_THE_SCOOP) == QUEST_STATUS_INCOMPLETE) )
+ void ReceiveEmote( Player *player, uint32 emote )
{
- _Creature->SetInFront(player);
- ((npc_pluckyAI*)((Creature*)_Creature)->AI())->TransformHuman(emote);
+ if( (emote == TEXTEMOTE_BECKON || emote == TEXTEMOTE_CHICKEN &&
+ player->GetQuestStatus(QUEST_GET_THE_SCOOP) == QUEST_STATUS_INCOMPLETE) )
+ {
+ m_creature->SetInFront(player);
+ TransformHuman(emote);
+ }
}
-
- return true;
-}
+};
bool GossipHello_npc_plucky(Player *player, Creature *_Creature)
{
@@ -316,7 +314,6 @@ void AddSC_thousand_needles()
newscript = new Script;
newscript->Name = "npc_plucky";
newscript->GetAI = &GetAI_npc_plucky;
- newscript->pReceiveEmote = &ReceiveEmote_npc_plucky;
newscript->pGossipHello = &GossipHello_npc_plucky;
newscript->pGossipSelect = &GossipSelect_npc_plucky;
newscript->RegisterSelf();
diff --git a/src/bindings/scripts/scripts/zone/thunder_bluff/thunder_bluff.cpp b/src/bindings/scripts/scripts/zone/thunder_bluff/thunder_bluff.cpp
index 30312313ee8..8038b7e4c34 100644
--- a/src/bindings/scripts/scripts/zone/thunder_bluff/thunder_bluff.cpp
+++ b/src/bindings/scripts/scripts/zone/thunder_bluff/thunder_bluff.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/tirisfal_glades/tirisfal_glades.cpp b/src/bindings/scripts/scripts/zone/tirisfal_glades/tirisfal_glades.cpp
index 7a69eab5153..82f1afbff5d 100644
--- a/src/bindings/scripts/scripts/zone/tirisfal_glades/tirisfal_glades.cpp
+++ b/src/bindings/scripts/scripts/zone/tirisfal_glades/tirisfal_glades.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -100,7 +100,7 @@ GameObject* SearchMausoleumGo(Unit *source, uint32 entry, float range)
cell.SetNoCreate();
Trinity::NearestGameObjectEntryInObjectRangeCheck go_check(*source, entry, range);
- Trinity::GameObjectLastSearcher<Trinity::NearestGameObjectEntryInObjectRangeCheck> searcher(pGo, go_check);
+ Trinity::GameObjectLastSearcher<Trinity::NearestGameObjectEntryInObjectRangeCheck> searcher(source, pGo, go_check);
TypeContainerVisitor<Trinity::GameObjectLastSearcher<Trinity::NearestGameObjectEntryInObjectRangeCheck>, GridTypeMapContainer> go_searcher(searcher);
diff --git a/src/bindings/scripts/scripts/zone/uldaman/boss_ironaya.cpp b/src/bindings/scripts/scripts/zone/uldaman/boss_ironaya.cpp
index 14a788d29e2..030a5937caa 100644
--- a/src/bindings/scripts/scripts/zone/uldaman/boss_ironaya.cpp
+++ b/src/bindings/scripts/scripts/zone/uldaman/boss_ironaya.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,12 +23,11 @@ EndScriptData */
#include "precompiled.h"
-#define SPELL_ARCINGSMASH 39144
-#define SPELL_KNOCKAWAY 22893
-#define SPELL_WSTOMP 16727
+#define SAY_AGGRO -1070000
-#define SAY_AGGRO "None may steal the secrets of the makers!"
-#define SOUND_AGGRO 5851
+#define SPELL_ARCINGSMASH 8374
+#define SPELL_KNOCKAWAY 10101
+#define SPELL_WSTOMP 11876
struct TRINITY_DLL_DECL boss_ironayaAI : public ScriptedAI
{
@@ -47,8 +46,7 @@ struct TRINITY_DLL_DECL boss_ironayaAI : public ScriptedAI
void Aggro(Unit *who)
{
- DoYell(SAY_AGGRO,LANG_UNIVERSAL,NULL);
- DoPlaySoundToSet(m_creature,SOUND_AGGRO);
+ DoScriptText(SAY_AGGRO, m_creature);
}
void UpdateAI(const uint32 diff)
diff --git a/src/bindings/scripts/scripts/zone/uldaman/instance_uldaman.cpp b/src/bindings/scripts/scripts/zone/uldaman/instance_uldaman.cpp
index 7a5e50805f1..a8a1820f0a4 100644
--- a/src/bindings/scripts/scripts/zone/uldaman/instance_uldaman.cpp
+++ b/src/bindings/scripts/scripts/zone/uldaman/instance_uldaman.cpp
@@ -70,7 +70,7 @@ struct TRINITY_DLL_DECL instance_uldaman : public ScriptedInstance
break;
case ANCIENT_VAULT_DOOR:
- go->SetUInt32Value(GAMEOBJECT_STATE,1);
+ go->SetGoState(1);
go->SetUInt32Value(GAMEOBJECT_FLAGS, 33);
ancientVaultDoor = go->GetGUID();
break;
@@ -93,7 +93,7 @@ struct TRINITY_DLL_DECL instance_uldaman : public ScriptedInstance
return;
go->SetUInt32Value(GAMEOBJECT_FLAGS, 33);
- go->SetUInt32Value(GAMEOBJECT_STATE, 0);
+ go->SetGoState(0);
}
void ActivateStoneKeepers()
diff --git a/src/bindings/scripts/scripts/zone/uldaman/uldaman.cpp b/src/bindings/scripts/scripts/zone/uldaman/uldaman.cpp
index de5f4889fe4..cf30cdb8824 100644
--- a/src/bindings/scripts/scripts/zone/uldaman/uldaman.cpp
+++ b/src/bindings/scripts/scripts/zone/uldaman/uldaman.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_bjarngrim.cpp b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_bjarngrim.cpp
new file mode 100644
index 00000000000..48ecfdbbcbf
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_bjarngrim.cpp
@@ -0,0 +1,94 @@
+/* Script Data Start
+SDName: Boss bjarngrim
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//AURAS AND STANCES
+#define BUFF_BATTLE_AURA 41106
+#define SPELL_BATTLE_STANCE 53792
+#define BUFF_BERSEKER_AURA 41107
+#define SPELL_BERSEKER_STANCE 53791
+#define BUFF_DEFENSIVE_AURA 41105
+#define SPELL_DEFENSIVE_STANCE 53790
+
+//OTHER SPELLS
+#define SPELL_CHARGE_UP 52098
+#define SPELL_CLEAVE 15284
+#define SPELL_INTERCEPT 58769
+#define SPELL_IRONFORM 52022
+#define SPELL_KNOCK_AWAY 52029
+#define SPELL_MORTAL_STRIKE 15708
+#define SPELL_SLAM 52026
+#define SPELL_SPELL_REFLECTION 36096
+#define SPELL_WHIRLWIND 52027
+
+//Yell
+#define SAY_AGGRO -1602000
+#define SAY_SLAY_1 -1602001
+#define SAY_SLAY_2 -1602002
+#define SAY_SLAY_3 -1602003
+#define SAY_DEATH -1602004
+#define SAY_BATTLE_STANCE -1602005
+#define SAY_BERSEKER_STANCE -1602006
+#define SAY_DEFENSIVE_STANCE -1602007
+
+struct TRINITY_DLL_DECL boss_bjarngrimAI : public ScriptedAI
+{
+ boss_bjarngrimAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 whirlwind;
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_bjarngrim(Creature *_Creature)
+{
+ return new boss_bjarngrimAI (_Creature);
+}
+
+void AddSC_boss_bjarngrim()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_bjarngrim";
+ newscript->GetAI = GetAI_boss_bjarngrim;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_ionar.cpp b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_ionar.cpp
new file mode 100644
index 00000000000..1760c8d0032
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_ionar.cpp
@@ -0,0 +1,114 @@
+/* Script Data Start
+SDName: Boss ionar
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_ionar' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_BALL_LIGHTNING 52780
+#define SPELL_BALL_LIGHTNING_2 59800
+#define SPELL_DISPERSE 52770 //Disperse into Sparks of Ionar.
+#define SPELL_STATIC_OVERLOAD 52658 //Effect Apply Aura: Periodic Trigger Interval: 2 seconds Spell 52659
+#define SPELL_STATIC_OVERLOAD_2 52658 //Effect Apply Aura: Periodic Trigger Interval: 2 seconds Spell 59796
+
+//Spark of Ionar spells
+#define NPC_SPARK_OF_IONAR 28962 //invulnerable
+#define SPELL_ARCING_BURN 52617
+#define SPELL_ARCING_BURN_2 59834
+
+//Yell
+#define SAY_AGGRO -1602008
+#define SAY_SLAY_1 -1602009
+#define SAY_SLAY_2 -1602010
+#define SAY_SLAY_3 -1602011
+#define SAY_DEATH -1602012
+#define SAY_SPLIT_1 -1602013
+#define SAY_SPLIT_2 -1602014
+
+//he does "morph" every about 25% into 4 sparks of ionar that chase people around, they r slow and easily avoidable.
+
+struct TRINITY_DLL_DECL boss_ionarAI : public ScriptedAI
+{
+ boss_ionarAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+struct TRINITY_DLL_DECL npc_spark_of_ionarAI : public ScriptedAI
+{
+ npc_spark_of_ionarAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+CreatureAI* GetAI_npc_spark_of_ionar(Creature *_Creature)
+{
+ return new npc_spark_of_ionarAI (_Creature);
+}
+CreatureAI* GetAI_boss_ionar(Creature *_Creature)
+{
+ return new boss_ionarAI (_Creature);
+}
+
+void AddSC_boss_ionar()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_ionar";
+ newscript->GetAI = GetAI_boss_ionar;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="spark_of_ionar";
+ newscript->GetAI = GetAI_npc_spark_of_ionar;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_loken.cpp b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_loken.cpp
new file mode 100644
index 00000000000..e8b991a5172
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_loken.cpp
@@ -0,0 +1,86 @@
+/* Script Data Start
+SDName: Boss loken
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_loken' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_ARC_NOVA 52921
+//Effect #1 School Damage (Nature), Value: 3238 to 3762
+//Effect #2 Apply Aura: Dummy, Value: 3238 to 3762, Server-side script
+
+#define SPELL_LIGHTNING_NOVA 52960
+#define SPELL_LIGHTNING_NOVA_2 59835
+
+//Yell
+#define SAY_AGGRO -1602015
+#define SAY_INTRO_1 -1602016
+#define SAY_INTRO_2 -1602017
+#define SAY_SLAY_1 -1602018
+#define SAY_SLAY_2 -1602019
+#define SAY_SLAY_3 -1602020
+#define SAY_DEATH -1602021
+#define SAY_NOVA_1 -1602022
+#define SAY_NOVA_2 -1602023
+#define SAY_NOVA_3 -1602024
+#define SAY_75HEALTH -1602025
+#define SAY_50HEALTH -1602026
+#define SAY_25HEALTH -1602027
+
+struct TRINITY_DLL_DECL boss_lokenAI : public ScriptedAI
+{
+ boss_lokenAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_loken(Creature *_Creature)
+{
+ return new boss_lokenAI (_Creature);
+}
+
+void AddSC_boss_loken()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_loken";
+ newscript->GetAI = GetAI_boss_loken;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_volkhan.cpp b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_volkhan.cpp
new file mode 100644
index 00000000000..a613a084f02
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/boss_volkhan.cpp
@@ -0,0 +1,128 @@
+/* Script Data Start
+SDName: Boss volkhan
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_volkhan' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_HEAT 52387
+#define SPELL_HEAT_2 59528
+#define SPELL_SHATTERING_STOMP 52237
+#define SPELL_SHATTERING_STOMP_2 59529
+#define SPELL_TEMPER 52238 //Dummy ---> Strikes Volkhan's Anvil, creating a number of Molten Golems.
+
+#define NPC_VOLKHANS_ANVIL 28823
+#define MOB_MOLTEN_GOLEM 28695
+
+//Yells
+#define SAY_AGGRO -1602028
+#define SAY_SLAY_1 -1602029
+#define SAY_SLAY_2 -1602030
+#define SAY_SLAY_3 -1602031
+#define SAY_DEATH -1602032
+#define SAY_STOMP_1 -1602033
+#define SAY_STOMP_2 -1602034
+#define SAY_FORGE_1 -1602035
+#define SAY_FORGE_2 -1602036
+
+struct TRINITY_DLL_DECL boss_volkhanAI : public ScriptedAI
+{
+ boss_volkhanAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+/*######
+## Mob Molten Golem
+######*/
+//Molten Golem Spells
+#define SPELL_BLAST_WAVE 23113
+#define SPELL_IMMOLATION_STRIKE 52433
+#define SPELL_IMMOLATION_STRIKE_2 59530
+//Effect #1 Apply Aura: Periodic Damage, value: 900 every 3 seconds
+//Effect #2 School Damage (Fire), value: 900
+//Effect #3 Script Effect
+#define SPELL_SHATTER 52429
+//Effect #1 School Damage (Physical), value: 9250 to 10750, radius: 10 yards
+//Effect #2 Dummy, Server-side script
+#define SPELL_SHATTER_2
+
+struct TRINITY_DLL_DECL mob_molten_golemAI : public ScriptedAI
+{
+ mob_molten_golemAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+CreatureAI* GetAI_mob_molten_golem(Creature *_Creature)
+{
+ return new mob_molten_golemAI (_Creature);
+}
+
+CreatureAI* GetAI_boss_volkhan(Creature *_Creature)
+{
+ return new boss_volkhanAI (_Creature);
+}
+
+void AddSC_boss_volkhan()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_volkhan";
+ newscript->GetAI = GetAI_boss_volkhan;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="mob_molten_golem";
+ newscript->GetAI = GetAI_mob_molten_golem;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/def_halls_of_lightning.h b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/def_halls_of_lightning.h
new file mode 100644
index 00000000000..134e32850ae
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/def_halls_of_lightning.h
@@ -0,0 +1,4 @@
+#ifndef DEF_HALLS_OF_LIGHTNING_H
+#define DEF_HALLS_OF_LIGHTNING_H
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/instance_halls_of_lightning.cpp b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/instance_halls_of_lightning.cpp
new file mode 100644
index 00000000000..4e694df73a5
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/ulduar/halls_of_lightning/instance_halls_of_lightning.cpp
@@ -0,0 +1,21 @@
+#include "precompiled.h"
+#include "def_halls_of_lightning.h"
+
+struct TRINITY_DLL_DECL instance_halls_of_lightning : public ScriptedInstance
+{
+ instance_halls_of_lightning(Map *Map) : ScriptedInstance(Map) {Initialize();};
+};
+
+InstanceData* GetInstanceData_instance_halls_of_lightning(Map* map)
+{
+ return new instance_halls_of_lightning(map);
+}
+
+void AddSC_instance_halls_of_lightning()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_halls_of_lightning";
+ newscript->GetInstanceData = GetInstanceData_instance_halls_of_lightning;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_krystallus.cpp b/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_krystallus.cpp
new file mode 100644
index 00000000000..e58c2f8a2ac
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_krystallus.cpp
@@ -0,0 +1,73 @@
+/* Script Data Start
+SDName: Boss krystallus
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_krystallus' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_BOULDER_TOSS 50843
+#define SPELL_BOULDER_TOSS_2 59742
+#define SPELL_GROUND_SPIKE 59750
+#define SPELL_SHATTER 50810
+#define SPELL_SHATTER_2 61546
+#define SPELL_STOMP 48131
+#define SPELL_STOMP_2 59744
+
+//Yell
+#define SAY_AGGRO -1599000
+#define SAY_KILL -1599001
+#define SAY_DEATH -1599002
+#define SAY_SHATTER -1599003
+
+struct TRINITY_DLL_DECL boss_krystallusAI : public ScriptedAI
+{
+ boss_krystallusAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ DoScriptText(SAY_KILL, m_creature);
+ }
+};
+
+CreatureAI* GetAI_boss_krystallus(Creature *_Creature)
+{
+ return new boss_krystallusAI (_Creature);
+}
+
+void AddSC_boss_krystallus()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_krystallus";
+ newscript->GetAI = GetAI_boss_krystallus;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_maiden_of_grief.cpp b/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_maiden_of_grief.cpp
new file mode 100644
index 00000000000..f179e8d7a73
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_maiden_of_grief.cpp
@@ -0,0 +1,81 @@
+/* Script Data Start
+SDName: Boss maiden_of_grief
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_maiden_of_grief' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spell
+#define SPELL_PARTING_SORROW 59723
+#define SPELL_STORM_OF_GRIEF 50752
+#define SPELL_STORM_OF_GRIEF_2 59772
+#define SPELL_SHOCK_OF_SORROW 50760
+#define SPELL_SHOCK_OF_SORROW_2 59726
+#define SPELL_PILLAR_OF_WOE 50761
+#define SPELL_PILLAR_OF_WOE_2 59727
+
+//Yell
+#define SAY_AGGRO -1599004
+#define SAY_SLAY_1 -1599005
+#define SAY_SLAY_2 -1599006
+#define SAY_SLAY_3 -1599007
+#define SAY_SLAY_4 -1599008
+#define SAY_DEATH -1599009
+#define SAY_STUN -1599010
+
+struct TRINITY_DLL_DECL boss_maiden_of_griefAI : public ScriptedAI
+{
+ boss_maiden_of_griefAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_maiden_of_grief(Creature *_Creature)
+{
+ return new boss_maiden_of_griefAI (_Creature);
+}
+
+void AddSC_boss_maiden_of_grief()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_maiden_of_grief";
+ newscript->GetAI = GetAI_boss_maiden_of_grief;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_sjonnir.cpp b/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_sjonnir.cpp
new file mode 100644
index 00000000000..ddb048ee241
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/boss_sjonnir.cpp
@@ -0,0 +1,83 @@
+/* Script Data Start
+SDName: Boss sjonnir
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_sjonnir' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_LIGHTING_RING_1 50840 //Periodic Trigger (interval 2s) spell = 50841
+#define SPELL_LIGHTING_RING_2 51849 //Periodic Trigger (interval 2s) spell = 50841
+#define SPELL_LIGHTING_RING_2 59848 //Periodic Trigger (interval 2s) spell = 59849
+#define SPELL_LIGHTING_RING_3 59861 //Periodic Trigger (interval 2s) spell = 59849
+#define SPELL_STATIC_CHARGE_1 50834 //Periodic Trigger 2s interval, spell =50835
+#define SPELL_STATIC_CHARGE_2 59846 //Periodic Trigger 2s interval, spell =50847
+#define SPELL_CHAIN_LIGHTING_1 50830
+#define SPELL_CHAIN_LIGHTING_2 59844
+#define SPELL_LIGHTING_SHIELD_1 50831
+#define SPELL_LIGHTING_SHIELD_2 59845
+#define SPELL_FRENZY 28747
+
+//Yell
+#define SAY_AGGRO -1599011
+#define SAY_SLAY_1 -1599012
+#define SAY_SLAY_2 -1599013
+#define SAY_SLAY_3 -1599014
+#define SAY_DEATH -1599015
+
+struct TRINITY_DLL_DECL boss_sjonnirAI : public ScriptedAI
+{
+ boss_sjonnirAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_sjonnir(Creature *_Creature)
+{
+ return new boss_sjonnirAI (_Creature);
+}
+
+void AddSC_boss_sjonnir()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_sjonnir";
+ newscript->GetAI = GetAI_boss_sjonnir;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/def_halls_of_stone.h b/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/def_halls_of_stone.h
new file mode 100644
index 00000000000..ade934ad921
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/def_halls_of_stone.h
@@ -0,0 +1,4 @@
+#ifndef DEF_HALLS_OF_STONE_H
+#define DEF_HALLS_OF_STONE_H
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/instance_halls_of_stone.cpp b/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/instance_halls_of_stone.cpp
new file mode 100644
index 00000000000..3c7d3970b47
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/ulduar/halls_of_stone/instance_halls_of_stone.cpp
@@ -0,0 +1,21 @@
+#include "precompiled.h"
+#include "def_halls_of_stone.h"
+
+struct TRINITY_DLL_DECL instance_halls_of_stone : public ScriptedInstance
+{
+ instance_halls_of_stone(Map *Map) : ScriptedInstance(Map) {Initialize();};
+};
+
+InstanceData* GetInstanceData_instance_halls_of_stone(Map* map)
+{
+ return new instance_halls_of_stone(map);
+}
+
+void AddSC_instance_halls_of_stone()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_halls_of_stone";
+ newscript->GetInstanceData = GetInstanceData_instance_halls_of_stone;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/undercity/undercity.cpp b/src/bindings/scripts/scripts/zone/undercity/undercity.cpp
index b46acf1fcc2..3194ebc5439 100644
--- a/src/bindings/scripts/scripts/zone/undercity/undercity.cpp
+++ b/src/bindings/scripts/scripts/zone/undercity/undercity.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -110,7 +110,7 @@ struct TRINITY_DLL_DECL npc_lady_sylvanas_windrunnerAI : public ScriptedAI
m_creature->SummonCreature(ENTRY_HIGHBORNE_BUNNY, raX, raY, myZ, 0, TEMPSUMMON_TIMED_DESPAWN, 3000);
LamentEvent_Timer = 2000;
- if( !m_creature->HasAura(SPELL_SYLVANAS_CAST, 0))
+ if( !m_creature->HasAura(SPELL_SYLVANAS_CAST))
{
DoScriptText(SAY_LAMENT_END, m_creature);
DoScriptText(EMOTE_LAMENT_END, m_creature);
@@ -175,7 +175,7 @@ struct TRINITY_DLL_DECL npc_highborne_lamenterAI : public ScriptedAI
if( EventMove_Timer < diff )
{
m_creature->AddUnitMovementFlag(MOVEMENTFLAG_ONTRANSPORT | MOVEMENTFLAG_LEVITATING);
- m_creature->SendMonsterMoveWithSpeed(m_creature->GetPositionX(),m_creature->GetPositionY(),HIGHBORNE_LOC_Y_NEW,MOVEMENTFLAG_ONTRANSPORT,5000);
+ m_creature->SendMonsterMoveWithSpeed(m_creature->GetPositionX(),m_creature->GetPositionY(),HIGHBORNE_LOC_Y_NEW,5000);
m_creature->GetMap()->CreatureRelocation(m_creature,m_creature->GetPositionX(),m_creature->GetPositionY(),HIGHBORNE_LOC_Y_NEW,m_creature->GetOrientation());
EventMove = false;
}else EventMove_Timer -= diff;
@@ -210,7 +210,7 @@ bool GossipHello_npc_parqual_fintallas(Player *player, Creature *_Creature)
if (_Creature->isQuestGiver())
player->PrepareQuestMenu( _Creature->GetGUID() );
- if (player->GetQuestStatus(6628) == QUEST_STATUS_INCOMPLETE && !player->HasAura(SPELL_MARK_OF_SHAME,0) )
+ if (player->GetQuestStatus(6628) == QUEST_STATUS_INCOMPLETE && !player->HasAura(SPELL_MARK_OF_SHAME) )
{
player->ADD_GOSSIP_ITEM( 0, GOSSIP_HPF1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
player->ADD_GOSSIP_ITEM( 0, GOSSIP_HPF2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1);
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_dalronn.cpp b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_dalronn.cpp
new file mode 100644
index 00000000000..9512444458b
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_dalronn.cpp
@@ -0,0 +1,97 @@
+/* Script Data Start
+SDName: Boss dalronn
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_dalronn' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_DEBILITATE 43650
+#define SPELL_SHADOWBOLT 43649
+#define SPELL_SHADOWBOLT_2 59575
+#define SPELL_SUMMON_SKELETONS 52611 //Trigger Spell: 52612, summons NPC (28878)
+#define SPELL_SKARVALD_GHOST 48613 //When Skarvald dies
+
+//Yell
+#define SAY_AGGRO -1574005
+#define SAY_KILL -1574006
+#define SAY_DEATH_1 -1574007
+#define SAY_DEATH_2 -1574008
+#define SAY_RAISES -1574009
+
+struct TRINITY_DLL_DECL boss_dalronnAI : public ScriptedAI
+{
+ boss_dalronnAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 killed;
+ uint64 Skarvald;
+
+ void Reset()
+ {
+ Skarvald = 0;
+ }
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ if (Skarvald)
+ {
+ Creature* Skravald_m = (Unit::GetCreature((*m_creature), Skarvald));
+ if (Skravald_m)
+ {
+ if (!Skravald_m->isAlive())
+ {
+ DoCast(Skravald_m,SPELL_SKARVALD_GHOST);
+ DoScriptText(SAY_RAISES, m_creature);
+ }
+ }
+ }
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ killed++;
+ //On first death resurected instatly by Skarvald as a ghost, having the same abilities as when alive and is unatackable
+ //If Skarvald dies first, Dalron resurects him and says "SAY_RAISES"
+ if(killed ==2)
+ DoScriptText(SAY_DEATH_2,m_creature);
+ else
+ DoScriptText(SAY_DEATH_1,m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ DoScriptText(SAY_KILL, m_creature);
+ }
+};
+
+CreatureAI* GetAI_boss_dalronn(Creature *_Creature)
+{
+ return new boss_dalronnAI (_Creature);
+}
+
+void AddSC_boss_dalronn()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_dalronn";
+ newscript->GetAI = GetAI_boss_dalronn;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_ingvar_the_plunderer.cpp b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_ingvar_the_plunderer.cpp
new file mode 100644
index 00000000000..22e1b504446
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_ingvar_the_plunderer.cpp
@@ -0,0 +1,470 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Boss_Ingvar_The_Plunderer
+SD%Complete: 95
+SDComment: Some Problems with Annhylde Movement, Blizzlike Timers
+SDCategory: Udgarde Keep
+EndScriptData */
+
+#include "precompiled.h"
+#include "def_utgarde_keep.h"
+
+//Yells Ingvar
+#define YELL_AGGRO_1 "I'll paint my face with your blood!"
+#define SOUND_AGGRO_1 13207
+#define YELL_AGGRO_2 "I return! A second chance to carve out your skull!"
+#define SOUND_AGGRO_2 13209
+
+#define YELL_DEAD_1 "My life for the... death god!"
+#define SOUND_DEAD_1 13213
+#define YELL_DEAD_2 "No! I can do... better! I can..."
+#define SOUND_DEAD_2 13211
+
+#define YELL_KILL_1 "Mjul orm agn gjor!"
+#define SOUND_KILL_1 13212
+#define YELL_KILL_2 "I am a warriorborn!"
+#define SOUND_KILL_2 13214
+
+//Ingvar Spells human form
+#define MOB_INGVAR_HUMAN 23954
+#define SPELL_CLEAVE 42724
+#define SPELL_SMASH 42669
+#define H_SPELL_SMASH 59706
+#define SPELL_STAGGERING_ROAR 42708
+#define H_SPELL_STAGGERING_ROAR 59708
+#define SPELL_ENRAGE 42705
+#define H_SPELL_ENRAGE 59707
+
+#define MOB_ANNHYLDE_THE_CALLER 24068
+#define SPELL_INGVAR_FEIGN_DEATH 42795
+#define SPELL_SUMMON_BANSHEE 42912
+#define SPELL_SCOURG_RESURRECTION_EFFEKTSPAWN 42863 //Spawn resurrecteffekt around Ingvar
+
+#define MODEL_INGVAR_UNDEAD 26351
+#define MODEL_INGVAR_HUMAN 21953
+
+//Ingvar Spells undead form
+#define MOB_INGVAR_UNDEAD 23980
+#define SPELL_DARK_SMASH 42723
+#define SPELL_DREADFUL_ROAR 42729
+#define H_SPELL_DREADFUL_ROAR 59734
+#define SPELL_WOE_STRIKE 42730
+#define H_SPELL_WOE_STRIKE 59735
+
+#define ENTRY_THROW_TARGET 23996
+#define SPELL_SHADOW_AXE_SUMMON 42749
+
+struct TRINITY_DLL_DECL boss_ingvar_the_plundererAI : public ScriptedAI
+{
+ boss_ingvar_the_plundererAI(Creature *c) : ScriptedAI(c)
+ {
+ pInstance = ((ScriptedInstance*)c->GetInstanceData());
+ HeroicMode = c->GetMap()->IsHeroic();
+ }
+
+ ScriptedInstance* pInstance;
+
+ bool HeroicMode;
+ bool undead;
+ bool event_inProgress;
+
+ uint32 Cleave_Timer;
+ uint32 Smash_Timer;
+ uint32 Enrage_Timer;
+ uint32 Roar_Timer;
+ uint32 SpawnResTimer;
+ uint32 wait_Timer;
+
+
+ void Reset()
+ {
+ if(undead) // Visual Hack
+ m_creature->SetUInt32Value(UNIT_FIELD_DISPLAYID, MODEL_INGVAR_HUMAN);
+
+ undead = false;
+ event_inProgress = false;
+
+ m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_ATTACKABLE_2);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
+
+ Cleave_Timer = 2000;
+ Smash_Timer = 5000;
+ Enrage_Timer = 10000;
+ Roar_Timer = 15000;
+
+ SpawnResTimer = 3000;
+
+ wait_Timer = 0;
+
+ if(pInstance)
+ pInstance->SetData(DATA_INGVAR_EVENT, NOT_STARTED);
+ }
+
+ void DamageTaken(Unit *done_by, uint32 &damage)
+ {
+ if( damage >= m_creature->GetHealth() && !undead)
+ {
+ //DoCast(m_creature,SPELL_INGVAR_FEIGN_DEATH,true); // Dont work ???
+ // visuel hack
+ m_creature->SetHealth(0);
+ m_creature->InterruptNonMeleeSpells(true);
+ m_creature->RemoveAllAuras();
+ m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_ATTACKABLE_2);
+ m_creature->GetMotionMaster()->MovementExpired(false);
+ m_creature->GetMotionMaster()->MoveIdle();
+ m_creature->SetStandState(UNIT_STAND_STATE_DEAD);
+ // visuel hack end
+
+ event_inProgress = true;
+ undead = true;
+
+ DoYell(YELL_DEAD_1,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_DEAD_1);
+ }
+
+ if(event_inProgress)
+ {
+ damage = 0;
+ }
+ }
+
+ void StartZombiePhase()
+ {
+ undead = true;
+ event_inProgress = false;
+ m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_ATTACKABLE_2);
+ m_creature->GetMotionMaster()->MoveChase(m_creature->getVictim());
+ m_creature->AI()->AttackStart(m_creature->getVictim());
+
+ DoYell(YELL_AGGRO_2,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_AGGRO_2);
+ }
+
+ void Aggro(Unit *who)
+ {
+ DoYell(YELL_AGGRO_1,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_AGGRO_1);
+
+ if(pInstance)
+ pInstance->SetData(DATA_INGVAR_EVENT, IN_PROGRESS);
+ }
+
+ void JustDied(Unit* killer)
+ {
+ DoYell(YELL_DEAD_2,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_DEAD_2);
+
+ if(pInstance)
+ pInstance->SetData(DATA_INGVAR_EVENT, DONE);
+ }
+
+ void KilledUnit(Unit *victim)
+ {
+ if(undead)
+ {
+ DoYell(YELL_KILL_1,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_KILL_1);
+ }
+ else
+ {
+ DoYell(YELL_KILL_2,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_KILL_2);
+ }
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ if (!UpdateVictim())
+ return;
+
+ if(event_inProgress)
+ {
+ if(SpawnResTimer)
+ if(SpawnResTimer< diff)
+ {
+ DoCast(m_creature,SPELL_SUMMON_BANSHEE); // Summons direktly on caster position
+ //DoCast(m_creature,SPELL_SCOURG_RESURRECTION_EFFEKTSPAWN); // Dont needet ?
+ SpawnResTimer = 0;
+ }else SpawnResTimer -= diff;
+
+ return;
+ }
+
+ // This is used for a spell queue ... the spells should not castet if one spell is already casting
+ if(wait_Timer)
+ if(wait_Timer < diff)
+ {
+ wait_Timer = 0;
+ }else wait_Timer -= diff;
+
+ if(Cleave_Timer < diff)
+ {
+ if(!wait_Timer)
+ {
+ if(undead)
+ DoCast(m_creature->getVictim(),HeroicMode ? H_SPELL_WOE_STRIKE : SPELL_WOE_STRIKE);
+ else
+ DoCast(m_creature->getVictim(),SPELL_CLEAVE);
+ Cleave_Timer = rand()%5000 + 2000;
+
+ wait_Timer = 1000;
+ }
+ }else Cleave_Timer -= diff;
+
+ if(Smash_Timer < diff)
+ {
+ if(!wait_Timer)
+ {
+ if(undead)
+ DoCast(m_creature->getVictim(), SPELL_DARK_SMASH);
+ else
+ DoCast(m_creature->getVictim(),HeroicMode ? H_SPELL_SMASH : SPELL_SMASH);
+ Smash_Timer = 10000;
+
+ wait_Timer = 5000;
+ }
+ }else Smash_Timer -= diff;
+
+ if(!undead)
+ {
+ if(Enrage_Timer < diff)
+ {
+ DoCast(m_creature,HeroicMode ? H_SPELL_ENRAGE : SPELL_ENRAGE);
+ Enrage_Timer = 10000;
+ }else Enrage_Timer -= diff;
+ }else // In Undead form used to summon weapon
+ {
+ if(Enrage_Timer < diff)
+ {
+ if(!wait_Timer)
+ {
+ // Spawn target for Axe
+ Unit* target = SelectUnit(SELECT_TARGET_TOPAGGRO, 1);
+ if(target)
+ {
+ Creature* temp = m_creature->SummonCreature(ENTRY_THROW_TARGET,target->GetPositionX(),target->GetPositionY(),target->GetPositionZ(),0,TEMPSUMMON_TIMED_DESPAWN,2000);
+
+ DoCast(m_creature,SPELL_SHADOW_AXE_SUMMON);
+ }
+ Enrage_Timer = 30000;
+ }
+ }else Enrage_Timer -= diff;
+ }
+
+
+ if(Roar_Timer < diff)
+ {
+ if(!wait_Timer)
+ {
+ if(undead)
+ DoCast(m_creature,HeroicMode ? H_SPELL_DREADFUL_ROAR : SPELL_DREADFUL_ROAR);
+ else
+ DoCast(m_creature,HeroicMode ? H_SPELL_STAGGERING_ROAR : SPELL_STAGGERING_ROAR);
+ Roar_Timer = 10000;
+
+ wait_Timer = 5000;
+ }
+ }else Roar_Timer -= diff;
+
+ DoMeleeAttackIfReady();
+ }
+};
+
+CreatureAI* GetAI_boss_ingvar_the_plunderer(Creature *_Creature)
+{
+ return new boss_ingvar_the_plundererAI (_Creature);
+}
+
+#define YELL_RESSURECT "Ingvar! Your pathetic failure will serve as a warning to all... you are damned! Arise and carry out the master's will!"
+#define SOUND_RESSURECT 13754
+
+//Spells for Annhylde
+#define SPELL_SCOURG_RESURRECTION_HEAL 42704 //Heal Max + DummyAura
+#define SPELL_SCOURG_RESURRECTION_BEAM 42857 //Channeling Beam of Annhylde
+#define SPELL_SCOURG_RESURRECTION_DUMMY 42862 //Some Emote Dummy?
+#define SPELL_INGVAR_TRANSFORM 42796
+
+struct TRINITY_DLL_DECL mob_annhylde_the_callerAI : public ScriptedAI
+{
+ mob_annhylde_the_callerAI(Creature *c) : ScriptedAI(c)
+ {
+ pInstance = ((ScriptedInstance*)c->GetInstanceData());
+ }
+
+ float x,y,z;
+ ScriptedInstance* pInstance;
+ uint32 Resurect_Timer;
+ uint32 Resurect_Phase;
+
+ void Reset()
+ {
+ m_creature->AddUnitMovementFlag(MOVEMENTFLAG_FLYING + MOVEMENTFLAG_FLYING2);
+ m_creature->SetSpeed(MOVE_SWIM , 0.1f);
+ m_creature->SetSpeed(MOVE_RUN , 0.1f);
+ m_creature->SetSpeed(MOVE_WALK , 0.1f);
+ m_creature->SetSpeed(MOVE_FLIGHT , 0.1f);
+
+ m_creature->GetPosition(x,y,z);
+ DoTeleportTo(x+1,y,z+30);
+
+ Unit* ingvar = Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_INGVAR));
+ if(ingvar)
+ {
+ m_creature->GetMotionMaster()->MovePoint(1,x,y,z+15);
+
+ DoYell(YELL_RESSURECT,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_RESSURECT);
+ }
+ }
+
+ void MovementInform(uint32 type, uint32 id)
+ {
+ if(type != POINT_MOTION_TYPE)
+ return;
+ Unit* ingvar = Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_INGVAR));
+ if(ingvar)
+ {
+ switch (id)
+ {
+ case 1:
+ ingvar->RemoveAura(SPELL_SUMMON_BANSHEE);
+ ingvar->CastSpell(ingvar,SPELL_SCOURG_RESURRECTION_DUMMY,true);
+ DoCast(ingvar,SPELL_SCOURG_RESURRECTION_BEAM);
+ Resurect_Timer = 8000;
+ Resurect_Phase = 1;
+ break;
+ case 2:
+ m_creature->DealDamage(m_creature,m_creature->GetHealth());
+ m_creature->RemoveCorpse();
+ break;
+ }
+ }
+ }
+
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void Aggro(Unit *who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ if(Resurect_Timer)
+ if(Resurect_Timer < diff)
+ {
+ if(Resurect_Phase == 1)
+ {
+ Unit* ingvar = Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_INGVAR));
+ if(ingvar)
+ {
+ ingvar->SetStandState(UNIT_STAND_STATE_STAND);
+ ingvar->CastSpell(ingvar,SPELL_SCOURG_RESURRECTION_HEAL,false);
+ }
+ Resurect_Timer = 3000;
+ Resurect_Phase = 2;
+ }else if (Resurect_Phase == 2)
+ {
+ Unit* ingvar = Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_INGVAR));
+ if(ingvar)
+ {
+ ingvar->RemoveAurasDueToSpell(SPELL_SCOURG_RESURRECTION_DUMMY);
+ //ingvar->CastSpell(ingvar,SPELL_INGVAR_TRANSFORM,false);
+ ingvar->SetUInt32Value(UNIT_FIELD_DISPLAYID, MODEL_INGVAR_UNDEAD); // Visual Hack - when he dies he becomes human model -> wrong
+ Creature* c_ingvar = (Creature*)ingvar;
+
+ ((boss_ingvar_the_plundererAI*)(c_ingvar->AI()))->StartZombiePhase();
+
+ m_creature->GetMotionMaster()->MovePoint(2,x+1,y,z+30);
+ Resurect_Phase++;
+ }
+ }
+
+ }else Resurect_Timer -= diff;
+ }
+};
+
+CreatureAI* GetAI_mob_annhylde_the_caller(Creature *_Creature)
+{
+ return new mob_annhylde_the_callerAI (_Creature);
+}
+
+#define SPELL_SHADOW_AXE_DAMAGE 42750
+#define H_SPELL_SHADOW_AXE_DAMAGE 59719
+
+struct TRINITY_DLL_DECL mob_ingvar_throw_dummyAI : public ScriptedAI
+{
+ mob_ingvar_throw_dummyAI(Creature *c) : ScriptedAI(c)
+ {
+ pInstance = ((ScriptedInstance*)c->GetInstanceData());
+ HeroicMode = c->GetMap()->IsHeroic();
+ }
+
+ bool HeroicMode;
+ uint32 Despawn_Timer;
+
+ ScriptedInstance* pInstance;
+
+ void Reset()
+ {
+ Unit* target = FindCreature(ENTRY_THROW_TARGET,50,m_creature);
+ if(target)
+ {
+ DoCast(m_creature, HeroicMode ? H_SPELL_SHADOW_AXE_DAMAGE : SPELL_SHADOW_AXE_DAMAGE);
+ float x,y,z;
+ target->GetPosition(x,y,z);
+ m_creature->GetMotionMaster()->MovePoint(0,x,y,z);
+ }
+ Despawn_Timer = 7000;
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void Aggro(Unit *who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ if(Despawn_Timer < diff)
+ {
+ m_creature->DealDamage(m_creature,m_creature->GetHealth());
+ m_creature->RemoveCorpse();
+ Despawn_Timer = 0;
+ }else Despawn_Timer -= diff;
+ }
+};
+
+CreatureAI* GetAI_mob_ingvar_throw_dummy(Creature *_Creature)
+{
+ return new mob_ingvar_throw_dummyAI (_Creature);
+}
+
+void AddSC_boss_ingvar_the_plunderer()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_ingvar_the_plunderer";
+ newscript->GetAI = &GetAI_boss_ingvar_the_plunderer;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="mob_annhylde_the_caller";
+ newscript->GetAI = &GetAI_mob_annhylde_the_caller;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="mob_ingvar_throw_dummy";
+ newscript->GetAI = &GetAI_mob_ingvar_throw_dummy;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_keleseth.cpp b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_keleseth.cpp
new file mode 100644
index 00000000000..6e99f204666
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_keleseth.cpp
@@ -0,0 +1,338 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Boss_Prince_Keleseth
+SD%Complete: 90
+SDComment: Needs Prince Movements, Needs adjustments to blizzlike timers, Needs Shadowbolt castbar, Needs right Ressurect Visual, Needs Some Heroic Spells
+SDCategory: Utgarde Keep
+EndScriptData */
+
+#include "precompiled.h"
+#include "def_utgarde_keep.h"
+
+#define SPELL_SHADOWBOLT 43667
+#define SPELL_SHADOWBOLT_HEROIC 59389
+#define SPELL_FROST_TOMB 48400
+#define SPELL_FROST_TOMB_SUMMON 42714
+#define SPELL_DECREPIFY 42702
+#define SPELL_SCOURGE_RESSURRECTION 42704
+#define CREATURE_FROSTTOMB 23965
+#define CREATURE_SKELETON 23970
+
+#define SAY_AGGRO -1574000
+#define SAY_KILL -1574001
+#define SAY_DEATH -1574002
+#define SAY_FROST_TOMB -1574003
+#define SAY_SKELETONS -1574004
+
+#define SKELETONSPAWN_Z 42.8668
+
+float SkeletonSpawnPoint[5][5]=
+{
+ {156.2559, 259.2093},
+ {156.2559, 259.2093},
+ {156.2559, 259.2093},
+ {156.2559, 259.2093},
+ {156.2559, 259.2093},
+};
+
+float AttackLoc[3]={197.636, 194.046, 40.8164};
+
+struct TRINITY_DLL_DECL mob_frost_tombAI : public ScriptedAI
+{
+ mob_frost_tombAI(Creature *c) : ScriptedAI(c)
+ {
+ FrostTombGUID = 0;
+ }
+
+ uint64 FrostTombGUID;
+
+ void SetPrisoner(Unit* uPrisoner)
+ {
+ FrostTombGUID = uPrisoner->GetGUID();
+ }
+
+ void Reset(){ FrostTombGUID = 0; }
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+
+ void JustDied(Unit *killer)
+ {
+ if(FrostTombGUID)
+ {
+ Unit* FrostTomb = Unit::GetUnit((*m_creature),FrostTombGUID);
+ if(FrostTomb)
+ FrostTomb->RemoveAurasDueToSpell(SPELL_FROST_TOMB);
+ }
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ Unit* temp = Unit::GetUnit((*m_creature),FrostTombGUID);
+ if((temp && temp->isAlive() && !temp->HasAura(SPELL_FROST_TOMB)) || !temp )
+ m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
+ }
+};
+
+struct TRINITY_DLL_DECL boss_kelesethAI : public ScriptedAI
+{
+ boss_kelesethAI(Creature *c) : ScriptedAI(c)
+ {
+ pInstance = ((ScriptedInstance*)c->GetInstanceData());
+ Heroic = c->GetMap()->IsHeroic();
+ }
+
+ ScriptedInstance* pInstance;
+
+ uint32 FrostTombTimer;
+ uint32 SummonSkeletonsTimer;
+ uint32 RespawnSkeletonsTimer;
+ uint32 ShadowboltTimer;
+ uint64 SkeletonGUID[5];
+ bool Skeletons;
+ bool Heroic;
+ bool RespawnSkeletons;
+
+ void Reset()
+ {
+ ShadowboltTimer = 0;
+ Skeletons = false;
+
+ ResetTimer();
+
+ if(pInstance)
+ pInstance->SetData(DATA_PRINCEKELESETH_EVENT, NOT_STARTED);
+ }
+
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+
+ DoScriptText(SAY_KILL, m_creature);
+ }
+
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+
+ if(pInstance)
+ pInstance->SetData(DATA_PRINCEKELESETH_EVENT, DONE);
+ }
+
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ DoZoneInCombat();
+
+ if(pInstance)
+ pInstance->SetData(DATA_PRINCEKELESETH_EVENT, IN_PROGRESS);
+ }
+
+ void ResetTimer(uint32 inc = 0)
+ {
+ SummonSkeletonsTimer = 5000 + inc;
+ FrostTombTimer = 28000 + inc;
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ if (!UpdateVictim())
+ return;
+
+ if(ShadowboltTimer < diff)
+ {
+ Unit* target = SelectUnit(SELECT_TARGET_TOPAGGRO, 0);
+ if(target && target->isAlive() && target->GetTypeId() == TYPEID_PLAYER)
+ m_creature->CastSpell(target, Heroic ? SPELL_SHADOWBOLT_HEROIC : SPELL_SHADOWBOLT, true);
+ ShadowboltTimer = 10000;
+ }else ShadowboltTimer -= diff;
+
+ if(!Skeletons)
+ if((SummonSkeletonsTimer < diff))
+ {
+ Creature* Skeleton;
+ DoScriptText(SAY_SKELETONS, m_creature);
+ for(uint8 i = 0; i < 5; ++i)
+ {
+ Skeleton = m_creature->SummonCreature(CREATURE_SKELETON, SkeletonSpawnPoint[i][0], SkeletonSpawnPoint[i][1] , SKELETONSPAWN_Z, 0, TEMPSUMMON_CORPSE_TIMED_DESPAWN,20000);
+ if(Skeleton)
+ {
+ Skeleton->RemoveUnitMovementFlag(MOVEMENTFLAG_WALK_MODE);
+ Skeleton->GetMotionMaster()->MovePoint(0, m_creature->GetPositionX(), m_creature->GetPositionY() , m_creature->GetPositionZ());
+ Skeleton->AddThreat(m_creature->getVictim(), 0.0f);
+ DoZoneInCombat(Skeleton);
+ }
+ }
+ Skeletons = true;
+ }else SummonSkeletonsTimer -= diff;
+
+ if(FrostTombTimer < diff)
+ {
+ Unit* target = SelectUnit(SELECT_TARGET_RANDOM, 1);
+ if(target && target->isAlive() && target->GetTypeId() == TYPEID_PLAYER)
+ {
+ //DoCast(target, SPELL_FROST_TOMB_SUMMON, true);
+ Creature* Chains = m_creature->SummonCreature(CREATURE_FROSTTOMB, target->GetPositionX(), target->GetPositionY(), target->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_CORPSE_DESPAWN, 20000);
+ if(Chains)
+ {
+ ((mob_frost_tombAI*)Chains->AI())->SetPrisoner(target);
+ Chains->CastSpell(target, SPELL_FROST_TOMB, true);
+
+ DoScriptText(SAY_FROST_TOMB, m_creature);
+ }
+ }
+ FrostTombTimer = 15000;
+ }else FrostTombTimer -= diff;
+
+ DoMeleeAttackIfReady();
+ }
+};
+
+struct TRINITY_DLL_DECL mob_vrykul_skeletonAI : public ScriptedAI
+{
+ mob_vrykul_skeletonAI(Creature *c) : ScriptedAI(c)
+ {
+ pInstance = ((ScriptedInstance*)c->GetInstanceData());
+ }
+
+ ScriptedInstance *pInstance;
+ uint32 Respawn_Time;
+ uint64 Target_Guid;
+ uint32 Decrepify_Timer;
+
+ bool isDead;
+
+ void Reset()
+ {
+ Respawn_Time = 12000;
+ Decrepify_Timer = 10000 + rand()%20000;
+ isDead = false;
+ }
+
+ void Aggro(Unit *who){}
+ void DamageTaken(Unit *done_by, uint32 &damage)
+ {
+ if(done_by->GetGUID() == m_creature->GetGUID())
+ return;
+
+ if(damage >= m_creature->GetHealth())
+ {
+ PretendToDie();
+ damage = 0;
+ }
+ }
+
+
+ void PretendToDie()
+ {
+ isDead = true;
+ m_creature->InterruptNonMeleeSpells(true);
+ m_creature->RemoveAllAuras();
+ m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
+ m_creature->GetMotionMaster()->MovementExpired(false);
+ m_creature->GetMotionMaster()->MoveIdle();
+ m_creature->SetStandState(UNIT_STAND_STATE_DEAD);
+ };
+
+ void Resurrect()
+ {
+ isDead = false;
+ m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
+ m_creature->CastSpell(m_creature,SPELL_SCOURGE_RESSURRECTION,true);
+
+ if(m_creature->getVictim())
+ {
+ m_creature->GetMotionMaster()->MoveChase(m_creature->getVictim());
+ m_creature->AI()->AttackStart(m_creature->getVictim());
+ }
+ else
+ m_creature->GetMotionMaster()->Initialize();
+ };
+
+ void UpdateAI(const uint32 diff)
+ {
+ if(pInstance->GetData(DATA_PRINCEKELESETH_EVENT) == IN_PROGRESS)
+ {
+ if(isDead)
+ {
+ if(Respawn_Time < diff)
+ {
+ Resurrect();
+ Respawn_Time = 12000;
+ }else Respawn_Time -= diff;
+ }
+ else
+ {
+ if(!UpdateVictim())
+ return;
+
+ if(Decrepify_Timer < diff)
+ {
+ DoCast(m_creature->getVictim(),SPELL_DECREPIFY);
+ Decrepify_Timer = 30000;
+ }else Decrepify_Timer -= diff;
+
+ DoMeleeAttackIfReady();
+ }
+ }else
+ {
+ if(m_creature->isAlive())
+ m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
+ }
+
+ }
+};
+
+CreatureAI* GetAI_mob_frost_tomb(Creature *_Creature)
+{
+ return new mob_frost_tombAI(_Creature);
+}
+
+CreatureAI* GetAI_boss_keleseth(Creature *_Creature)
+{
+ return new boss_kelesethAI (_Creature);
+}
+
+CreatureAI* GetAI_mob_vrykul_skeleton(Creature *_Creature)
+{
+ return new mob_vrykul_skeletonAI (_Creature);
+}
+
+void AddSC_boss_keleseth()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_keleseth";
+ newscript->GetAI = &GetAI_boss_keleseth;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name = "mob_frost_tomb";
+ newscript->GetAI = &GetAI_mob_frost_tomb;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="mob_vrykul_skeleton";
+ newscript->GetAI = &GetAI_mob_vrykul_skeleton;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald.cpp b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald.cpp
new file mode 100644
index 00000000000..1fc9bc1c995
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald.cpp
@@ -0,0 +1,96 @@
+/* Script Data Start
+SDName: Boss skarvald
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_skarvald' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_CHARGE 43651 //randomly charges anyone but tank WoWradio video 14s afer aggro, and then every 5s change target
+#define SPELL_ENRAGE 48193
+#define SPELL_STONE_STRIKE 48583
+#define SPELL_DALRON_GHOST 48612 //When Dalron dies
+
+//Yells
+#define SAY_AGGRO -1574010
+#define SAY_KILL -1574011
+#define SAY_DEATH_1 -1574012
+#define SAY_DEATH_2 -1574013
+#define SAY_RAISES -1574014
+
+struct TRINITY_DLL_DECL boss_skarvaldAI : public ScriptedAI
+{
+ boss_skarvaldAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 kiled;
+ uint64 Dalronn;
+
+ void Reset()
+ {
+ Dalronn = 0;
+ }
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ if (Dalronn)
+ {
+ Creature* Dalronn_m = (Unit::GetCreature((*m_creature), Dalronn));
+ if (Dalronn_m)
+ {
+ if (!Dalronn_m->isAlive())
+ {
+ DoCast(Dalronn_m,SPELL_DALRON_GHOST);
+ DoScriptText(SAY_RAISES, m_creature);
+ }
+ }
+ }
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ kiled++;
+ //On first death resurected instatly by Dalron as a ghost, having the same abilities as when alive and is unatackable
+ //If Dalron dies first, Skarvald resurects him and says "SAY_RAISES"
+ if(kiled ==2)
+ DoScriptText(SAY_DEATH_2,m_creature);
+ else
+ DoScriptText(SAY_DEATH_1,m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ DoScriptText(SAY_KILL, m_creature);
+ }
+};
+
+CreatureAI* GetAI_boss_skarvald(Creature *_Creature)
+{
+ return new boss_skarvaldAI (_Creature);
+}
+
+void AddSC_boss_skarvald()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_skarvald";
+ newscript->GetAI = GetAI_boss_skarvald;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald_dalronn.cpp b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald_dalronn.cpp
new file mode 100644
index 00000000000..78bc29a770d
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/boss_skarvald_dalronn.cpp
@@ -0,0 +1,408 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Boss_Skarvald_Dalronn
+SD%Complete: 95
+SDComment: Needs adjustments to blizzlike timers, Yell Text + Sound to DB
+SDCategory: Utgarde Keep
+EndScriptData */
+
+#include "precompiled.h"
+#include "def_utgarde_keep.h"
+
+#define YELL_SKARVALD_AGGRO "Dalronn! See if you can muster the nerve to join my attack!"
+#define SOUND_SKARVALD_AGGRO 13229
+#define YELL_DALRONN_AGGRO "By all means, don't assess the situation, you halfwit! Just jump into the fray!"
+#define SOUND_DALRONN_AGGRO 13199
+
+#define YELL_SKARVALD_KILL "Jarggn olkt!"
+#define SOUND_SKARVALD_KILL 13232
+#define YELL_DALRONN_KILL "You may serve me yet."
+#define SOUND_DALRONN_KILL 13202
+
+#define YELL_DALRONN_DAL_DIEDFIRST "See... you... soon."
+#define SOUND_DALRONN_DAL_DIEDFIRST 13200
+#define YELL_SKARVALD_DAL_DIEDFIRST "Pagh! What sort of necromancer lets death stop him? I knew you were worthless!"
+#define SOUND_SKARVALD_DAL_DIEDFIRST 13233
+#define YELL_SKARVALD_DAL_DIED "A warrior's death."
+#define SOUND_SKARVALD_DAL_DIED 13231
+
+#define YELL_SKARVALD_SKA_DIEDFIRST "Not... over... yet."
+#define SOUND_SKARVALD_SKA_DIEDFIRST 13230
+#define YELL_DALRONN_SKA_DIEDFIRST "Skarvald, you incompetent slug! Return and make yourself useful!"
+#define SOUND_DALRONN_SKA_DIEDFIRST 13203
+#define YELL_DALRONN_SKA_DIED "There's no... greater... glory."
+#define SOUND_DALRONN_SKA_DIED 13201
+
+//Spells of Skarvald and his Ghost
+#define MOB_SKARVALD_THE_CONSTRUCTOR 24200
+#define SPELL_CHARGE 43651
+#define SPELL_STONE_STRIKE 48583
+#define SPELL_SUMMON_SKARVALD_GHOST 48613
+#define MOB_SKARVALD_GHOST 27390
+//Spells of Dalronn and his Ghost
+#define MOB_DALRONN_THE_CONTROLLER 24201
+#define SPELL_SHADOW_BOLT 43649
+#define H_SPELL_SHADOW_BOLT 59575
+#define H_SPELL_SUMMON_SKELETONS 52611
+#define SPELL_DEBILITATE 43650
+#define SPELL_SUMMON_DALRONN_GHOST 48612
+#define MOB_DALRONN_GHOST 27389
+
+struct TRINITY_DLL_DECL boss_skarvald_the_constructorAI : public ScriptedAI
+{
+ boss_skarvald_the_constructorAI(Creature *c) : ScriptedAI(c)
+ {
+ pInstance = ((ScriptedInstance*)c->GetInstanceData());
+ HeroicMode = m_creature->GetMap()->IsHeroic();
+ }
+
+ ScriptedInstance* pInstance;
+
+ bool ghost;
+ bool HeroicMode;
+ uint32 Charge_Timer;
+ uint32 StoneStrike_Timer;
+ uint32 Response_Timer;
+ uint32 Check_Timer;
+ bool Dalronn_isDead;
+
+ void Reset()
+ {
+ Charge_Timer = 5000;
+ StoneStrike_Timer = 10000;
+ Dalronn_isDead = false;
+ Check_Timer = 5000;
+
+ ghost = (m_creature->GetEntry() == MOB_SKARVALD_GHOST);
+ if(!ghost)
+ {
+ Unit* dalronn = Unit::GetUnit((*m_creature),pInstance->GetData64(DATA_DALRONN));
+ if(dalronn && dalronn->isDead())
+ ((Creature*)dalronn)->Respawn();
+
+ if(pInstance)
+ pInstance->SetData(DATA_SKARVALD_DALRONN_EVENT, NOT_STARTED);
+ }
+ }
+
+ void Aggro(Unit *who)
+ {
+ if(!ghost)
+ {
+ DoYell(YELL_SKARVALD_AGGRO,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_SKARVALD_AGGRO);
+
+ Unit* dalronn = Unit::GetUnit((*m_creature),pInstance->GetData64(DATA_DALRONN));
+ if(dalronn && dalronn->isAlive() && !dalronn->getVictim())
+ dalronn->getThreatManager().addThreat(who,0.0f);
+
+ if(pInstance)
+ pInstance->SetData(DATA_SKARVALD_DALRONN_EVENT, IN_PROGRESS);
+ }
+ }
+
+ void JustDied(Unit* Killer)
+ {
+ if(!ghost)
+ {
+ Unit* dalronn = Unit::GetUnit((*m_creature),pInstance->GetData64(DATA_DALRONN));
+ if(dalronn)
+ {
+ if(dalronn->isDead())
+ {
+ DoYell(YELL_SKARVALD_DAL_DIED,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_SKARVALD_DAL_DIED);
+
+ if(pInstance)
+ pInstance->SetData(DATA_SKARVALD_DALRONN_EVENT, DONE);
+ }
+ else
+ {
+ DoYell(YELL_SKARVALD_SKA_DIEDFIRST,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_SKARVALD_SKA_DIEDFIRST);
+
+ m_creature->RemoveFlag(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_LOOTABLE);
+ //DoCast(m_creature,SPELL_SUMMON_SKARVALD_GHOST,true);
+ Creature* temp = m_creature->SummonCreature(MOB_SKARVALD_GHOST,m_creature->GetPositionX(),m_creature->GetPositionY(),m_creature->GetPositionZ(),0,TEMPSUMMON_CORPSE_DESPAWN,5000);
+ temp->AI()->AttackStart(Killer);
+ }
+ }
+ }
+ }
+
+ void KilledUnit(Unit *victim)
+ {
+ if(!ghost)
+ {
+ DoYell(YELL_SKARVALD_KILL,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_SKARVALD_KILL);
+ }
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ if(ghost)
+ {
+ if(pInstance->GetData(DATA_SKARVALD_DALRONN_EVENT) != IN_PROGRESS)
+ {
+ m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
+ }
+ }
+
+ if(!UpdateVictim())
+ return;
+
+ if(!ghost)
+ {
+ if(Check_Timer)
+ if(Check_Timer < diff)
+ {
+ Check_Timer = 5000;
+ Unit* dalronn = Unit::GetUnit((*m_creature),pInstance->GetData64(DATA_DALRONN));
+ if(dalronn && dalronn->isDead())
+ {
+ Dalronn_isDead = true;
+ Response_Timer = 2000;
+ Check_Timer = 0;
+ }
+ }else Check_Timer -= diff;
+
+ if(Response_Timer)
+ if(Dalronn_isDead)
+ if(Response_Timer < diff)
+ {
+ DoYell(YELL_SKARVALD_DAL_DIEDFIRST,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_SKARVALD_DAL_DIEDFIRST);
+
+ Response_Timer = 0;
+ }else Response_Timer -= diff;
+ }
+
+ if(Charge_Timer < diff)
+ {
+ DoCast(SelectUnit(SELECT_TARGET_RANDOM, 1), SPELL_CHARGE);
+ Charge_Timer = 5000+rand()%5000;
+ }else Charge_Timer -= diff;
+
+ if(StoneStrike_Timer < diff)
+ {
+ DoCast(m_creature->getVictim(), SPELL_STONE_STRIKE);
+ StoneStrike_Timer = 5000+rand()%5000;
+ }else StoneStrike_Timer -= diff;
+
+ DoMeleeAttackIfReady();
+ }
+};
+
+CreatureAI* GetAI_boss_skarvald_the_constructor(Creature *_Creature)
+{
+ return new boss_skarvald_the_constructorAI (_Creature);
+}
+
+struct TRINITY_DLL_DECL boss_dalronn_the_controllerAI : public ScriptedAI
+{
+ boss_dalronn_the_controllerAI(Creature *c) : ScriptedAI(c)
+ {
+ pInstance = ((ScriptedInstance*)c->GetInstanceData());
+ HeroicMode = m_creature->GetMap()->IsHeroic();
+ }
+
+ ScriptedInstance* pInstance;
+
+ bool ghost;
+ bool HeroicMode;
+ uint32 ShadowBolt_Timer;
+ uint32 Debilitate_Timer;
+ uint32 Summon_Timer;
+
+ uint32 Response_Timer;
+ uint32 Check_Timer;
+ uint32 AggroYell_Timer;
+ bool Skarvald_isDead;
+
+
+ void Reset()
+ {
+ ShadowBolt_Timer = 1000;
+ Debilitate_Timer = 5000;
+ Summon_Timer = 10000;
+ Check_Timer = 5000;
+ Skarvald_isDead = false;
+ AggroYell_Timer = 0;
+
+ ghost = m_creature->GetEntry() == MOB_DALRONN_GHOST;
+ if(!ghost)
+ {
+ Unit* skarvald = Unit::GetUnit((*m_creature),pInstance->GetData64(DATA_SKARVALD));
+ if(skarvald && skarvald->isDead())
+ ((Creature*)skarvald)->Respawn();
+
+ if(pInstance)
+ pInstance->SetData(DATA_SKARVALD_DALRONN_EVENT, NOT_STARTED);
+ }
+ }
+
+ void Aggro(Unit *who)
+ {
+ if(!ghost)
+ {
+ Unit* skarvald = Unit::GetUnit((*m_creature),pInstance->GetData64(DATA_SKARVALD));
+ if(skarvald && skarvald->isAlive() && !skarvald->getVictim())
+ skarvald->getThreatManager().addThreat(who,0.0f);
+
+ AggroYell_Timer = 5000;
+
+ if(pInstance)
+ pInstance->SetData(DATA_SKARVALD_DALRONN_EVENT, IN_PROGRESS);
+ }
+ }
+
+ void JustDied(Unit* Killer)
+ {
+ if(!ghost)
+ {
+ Unit* skarvald = Unit::GetUnit((*m_creature),pInstance->GetData64(DATA_SKARVALD));
+ if(skarvald)
+ if(skarvald->isDead())
+ {
+ DoYell(YELL_DALRONN_SKA_DIED,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_DALRONN_SKA_DIED);
+
+ if(pInstance)
+ pInstance->SetData(DATA_SKARVALD_DALRONN_EVENT, DONE);
+ }
+ else
+ {
+ DoYell(YELL_DALRONN_DAL_DIEDFIRST,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_DALRONN_DAL_DIEDFIRST);
+
+ m_creature->RemoveFlag(UNIT_DYNAMIC_FLAGS, UNIT_DYNFLAG_LOOTABLE);
+ //DoCast(m_creature,SPELL_SUMMON_DALRONN_GHOST,true);
+ Creature* temp = m_creature->SummonCreature(MOB_DALRONN_GHOST,m_creature->GetPositionX(),m_creature->GetPositionY(),m_creature->GetPositionZ(),0,TEMPSUMMON_CORPSE_DESPAWN,5000);
+ temp->AI()->AttackStart(Killer);
+ }
+ }
+ }
+
+ void KilledUnit(Unit *victim)
+ {
+ if(!ghost)
+ {
+ DoYell(YELL_DALRONN_KILL,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_DALRONN_KILL);
+ }
+ }
+
+ void UpdateAI(const uint32 diff)
+ {
+ if(ghost)
+ {
+ if(pInstance->GetData(DATA_SKARVALD_DALRONN_EVENT) != IN_PROGRESS)
+ {
+ m_creature->DealDamage(m_creature, m_creature->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false);
+ }
+ }
+
+ if(!UpdateVictim())
+ return;
+
+ if(AggroYell_Timer)
+ if(AggroYell_Timer < diff)
+ {
+ DoYell(YELL_DALRONN_AGGRO,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_DALRONN_AGGRO);
+
+ AggroYell_Timer = 0;
+ }else AggroYell_Timer -= diff;
+
+ if(!ghost)
+ {
+ if(Check_Timer)
+ if(Check_Timer < diff)
+ {
+ Check_Timer = 5000;
+ Unit* skarvald = Unit::GetUnit((*m_creature),pInstance->GetData64(DATA_SKARVALD));
+ if(skarvald && skarvald->isDead())
+ {
+ Skarvald_isDead = true;
+ Response_Timer = 2000;
+ Check_Timer = 0;
+ }
+ }else Check_Timer -= diff;
+
+ if(Response_Timer)
+ if(Skarvald_isDead)
+ if(Response_Timer < diff)
+ {
+ DoYell(YELL_DALRONN_SKA_DIEDFIRST,LANG_UNIVERSAL,NULL);
+ DoPlaySoundToSet(m_creature,SOUND_DALRONN_SKA_DIEDFIRST);
+
+ Response_Timer = 0;
+ }else Response_Timer -= diff;
+ }
+
+ if(ShadowBolt_Timer < diff)
+ {
+ if (!m_creature->IsNonMeleeSpellCasted(false))
+ {
+ DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0),HeroicMode ? H_SPELL_SHADOW_BOLT : SPELL_SHADOW_BOLT);
+ ShadowBolt_Timer = 1000;
+ }
+ }else ShadowBolt_Timer -= diff;
+
+ if(Debilitate_Timer < diff)
+ {
+ if (!m_creature->IsNonMeleeSpellCasted(false))
+ {
+ DoCast(SelectUnit(SELECT_TARGET_RANDOM, 0),SPELL_DEBILITATE);
+ Debilitate_Timer = 5000+rand()%5000;
+ }
+ }else Debilitate_Timer -= diff;
+
+ if(HeroicMode)
+ if(Summon_Timer < diff)
+ {
+ DoCast(m_creature,H_SPELL_SUMMON_SKELETONS);
+ Summon_Timer = (rand()%10000) + 20000;
+ }else Summon_Timer -= diff;
+
+ DoMeleeAttackIfReady();
+ }
+};
+
+CreatureAI* GetAI_boss_dalronn_the_controller(Creature *_Creature)
+{
+ return new boss_dalronn_the_controllerAI (_Creature);
+}
+
+void AddSC_boss_skarvald_dalronn()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_skarvald_the_constructor";
+ newscript->GetAI = &GetAI_boss_skarvald_the_constructor;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="boss_dalronn_the_controller";
+ newscript->GetAI = &GetAI_boss_dalronn_the_controller;
+ newscript->RegisterSelf();
+} \ No newline at end of file
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/def_utgarde_keep.h b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/def_utgarde_keep.h
new file mode 100644
index 00000000000..ec416e5729a
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/def_utgarde_keep.h
@@ -0,0 +1,31 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#ifndef DEF_UTGARDE_KEEP_H
+#define DEF_UTGARDE_KEEP_H
+
+#define DATA_PRINCEKELESETH 1
+#define DATA_SKARVALD 3
+#define DATA_DALRONN 4
+#define DATA_INGVAR 6
+
+#define DATA_PRINCEKELESETH_EVENT 2
+#define DATA_SKARVALD_DALRONN_EVENT 5
+#define DATA_INGVAR_EVENT 7
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/instance_utgarde_keep.cpp b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/instance_utgarde_keep.cpp
new file mode 100644
index 00000000000..e0e243cbed9
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_keep/instance_utgarde_keep.cpp
@@ -0,0 +1,231 @@
+/*
+ * Copyright (C) 2009 Trinity <http://www.trinitycore.org/>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+/* ScriptData
+SDName: Instance_Utgarde_Keep
+SD%Complete: 90
+SDComment: Instance Data Scripts and functions to acquire mobs and set encounter status for use in various Utgarde Keep Scripts
+SDCategory: Utgarde Keep
+EndScriptData */
+
+#include "precompiled.h"
+#include "def_utgarde_keep.h"
+
+#define ENCOUNTERS 3
+
+/* Utgarde Keep encounters:
+0 - Prince Keleseth
+1 - Skarvald Dalronn
+2 - Ingvar the Plunderer
+*/
+
+struct TRINITY_DLL_DECL instance_utgarde_keep : public ScriptedInstance
+{
+ instance_utgarde_keep(Map *Map) : ScriptedInstance(Map) {Initialize();};
+
+ uint64 Keleseth;
+ uint64 Skarvald;
+ uint64 Dalronn;
+ uint64 Ingvar;
+
+ uint32 Encounters[ENCOUNTERS];
+ std::string str_data;
+
+ void Initialize()
+ {
+ Keleseth = 0;
+ Skarvald = 0;
+ Dalronn =0;
+ Ingvar =0;
+
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ Encounters[i] = NOT_STARTED;
+ }
+
+ bool IsEncounterInProgress() const
+ {
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ if(Encounters[i] == IN_PROGRESS) return true;
+
+ return false;
+ }
+
+ Player* GetPlayerInMap()
+ {
+ Map::PlayerList const& players = instance->GetPlayers();
+
+ if (!players.isEmpty())
+ {
+ for(Map::PlayerList::const_iterator itr = players.begin(); itr != players.end(); ++itr)
+ {
+ if (Player* plr = itr->getSource())
+ return plr;
+ }
+ }
+
+ debug_log("TSCR: Instance Utgarde Keep: GetPlayerInMap, but PlayerList is empty!");
+ return NULL;
+ }
+
+ void HandleGameObject(uint64 guid, uint32 state)
+ {
+ Player *player = GetPlayerInMap();
+
+ if (!player || !guid)
+ {
+ debug_log("TSCR: Utgarde Keep: HandleGameObject fail");
+ return;
+ }
+
+ if (GameObject *go = GameObject::GetGameObject(*player,guid))
+ go->SetGoState(state);
+ }
+
+ void OnCreatureCreate(Creature *creature, uint32 creature_entry)
+ {
+ switch(creature_entry)
+ {
+ case 23953: Keleseth = creature->GetGUID(); break;
+ case 24201: Dalronn = creature->GetGUID(); break;
+ case 24200: Skarvald = creature->GetGUID(); break;
+ case 23954: Ingvar = creature->GetGUID(); break;
+ }
+ }
+
+ void OnObjectCreate(GameObject* go)
+ {
+ //switch(go->GetEntry())
+ //{
+ //door and object id
+ //}
+ }
+
+ uint64 GetData64(uint32 identifier)
+ {
+ switch(identifier)
+ {
+ case DATA_PRINCEKELESETH: return Keleseth;
+ case DATA_DALRONN: return Dalronn;
+ case DATA_SKARVALD: return Skarvald;
+ case DATA_INGVAR: return Ingvar;
+ }
+
+ return 0;
+ }
+
+ void SetData(uint32 type, uint32 data)
+ {
+ switch(type)
+ {
+ case DATA_PRINCEKELESETH_EVENT:
+ if(data == DONE)
+ {
+ //HandleGameObject(doorname, 0);
+ }
+ Encounters[0] = data;break;
+ case DATA_SKARVALD_DALRONN_EVENT:
+ if(data == DONE)
+ {
+ //HandleGameObject(doorname, 0);
+ }
+ Encounters[1] = data; break;
+ case DATA_INGVAR_EVENT:
+ if(data == DONE)
+ {
+ //HandleGameObject(doorname, 0);
+ }
+ Encounters[2] = data; break;
+ }
+
+ if (data == DONE)
+ {
+ SaveToDB();
+ }
+ }
+
+ uint32 GetData(uint32 type)
+ {
+ switch(type)
+ {
+ case DATA_PRINCEKELESETH_EVENT: return Encounters[0];
+ case DATA_SKARVALD_DALRONN_EVENT: return Encounters[1];
+ case DATA_INGVAR_EVENT: return Encounters[2];
+ }
+
+ return 0;
+ }
+
+ const char* Save()
+ {
+ OUT_SAVE_INST_DATA;
+
+ std::ostringstream saveStream;
+ saveStream << "U K " << Encounters[0] << " " << Encounters[1] << " "
+ << Encounters[2];
+
+ str_data = saveStream.str();
+
+ OUT_SAVE_INST_DATA_COMPLETE;
+ return str_data.c_str();
+ }
+
+ void Load(const char* in)
+ {
+ if (!in)
+ {
+ OUT_LOAD_INST_DATA_FAIL;
+ return;
+ }
+
+ OUT_LOAD_INST_DATA(in);
+
+ char dataHead1, dataHead2;
+ uint16 data0,data1,data2;
+
+ std::istringstream loadStream(in);
+ loadStream >> dataHead1 >> dataHead2 >> data0 >> data1 >> data2;
+
+ if( dataHead1 == 'U' && dataHead2 == 'K')
+ {
+ Encounters[0] = data0;
+ Encounters[1] = data1;
+ Encounters[2] = data2;
+
+ for(uint8 i = 0; i < ENCOUNTERS; ++i)
+ if (Encounters[i] == IN_PROGRESS)
+ Encounters[i] = NOT_STARTED;
+
+ }else OUT_LOAD_INST_DATA_FAIL;
+
+ OUT_LOAD_INST_DATA_COMPLETE;
+ }
+};
+
+InstanceData* GetInstanceData_instance_utgarde_keep(Map* map)
+{
+ return new instance_utgarde_keep(map);
+}
+
+void AddSC_instance_utgarde_keep()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_utgarde_keep";
+ newscript->GetInstanceData = &GetInstanceData_instance_utgarde_keep;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_palehoof.cpp b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_palehoof.cpp
new file mode 100644
index 00000000000..d2351f1f458
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_palehoof.cpp
@@ -0,0 +1,78 @@
+/* Script Data Start
+SDName: Boss palehoof
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_palehoof' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_ARCING_SMASH 48260
+#define SPELL_IMPALE 48261
+#define SPELL_WITHERING_ROAR 48256
+
+//Yell
+#define SAY_AGGRO -1575000
+#define SAY_SLAY_1 -1575001
+#define SAY_SLAY_2 -1575002
+#define SAY_DEATH -1575003
+
+struct TRINITY_DLL_DECL boss_palehoofAI : public ScriptedAI
+{
+ boss_palehoofAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if (victim == m_creature)
+ return;
+
+ switch(rand()%2)
+ {
+ case 0:
+ DoScriptText(SAY_SLAY_1, m_creature);
+ break;
+ case 1:
+ DoScriptText(SAY_SLAY_2, m_creature);
+ break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_palehoof(Creature *_Creature)
+{
+ return new boss_palehoofAI (_Creature);
+}
+
+void AddSC_boss_palehoof()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_palehoof";
+ newscript->GetAI = GetAI_boss_palehoof;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_skadi.cpp b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_skadi.cpp
new file mode 100644
index 00000000000..e08f249b036
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_skadi.cpp
@@ -0,0 +1,89 @@
+/* Script Data Start
+SDName: Boss skadi
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_skadi' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Phase 0 "gauntlet even" Skadi on a flying mount, waves of adds charging to the group periodicaly carrying harpoons
+//Phase 1 Kill the Skadi drake mount with harppons launcher
+//Phase 2 Kill the Skadi
+
+//Skadi Spells
+#define SPELL_CRUSH 50234
+#define SPELL_POISONED_SPEAR 50225
+#define SPELL_WHIRLWIND 50228 //random target, but not the tank approx. every 20s
+
+//Yell
+#define SAY_AGGRO -1575004
+#define SAY_KILL_1 -1575005
+#define SAY_KILL_2 -1575006
+#define SAY_KILL_3 -1575007
+#define SAY_DEATH -1575008
+#define SAY_DRAKE_DEATH -1575009
+#define SAY_DRAKE_HIT_1 -1575010
+#define SAY_DRAKE_HIT_2 -1575011
+#define SAY_DRAKE_BREATH_1 -1575012
+#define SAY_DRAKE_BREATH_2 -1575013
+#define SAY_DRAKE_BREATH_3 -1575014
+
+struct TRINITY_DLL_DECL boss_skadiAI : public ScriptedAI
+{
+ boss_skadiAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 phase;
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ phase = 0;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_KILL_1, m_creature);break;
+ case 1: DoScriptText(SAY_KILL_2, m_creature);break;
+ case 2: DoScriptText(SAY_KILL_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_skadi(Creature *_Creature)
+{
+ return new boss_skadiAI (_Creature);
+}
+
+void AddSC_boss_skadi()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_skadi";
+ newscript->GetAI = GetAI_boss_skadi;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_svala.cpp b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_svala.cpp
new file mode 100644
index 00000000000..30064208cc3
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_svala.cpp
@@ -0,0 +1,83 @@
+/* Script Data Start
+SDName: Boss svala
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_svala' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_CALL_FLAMES 48258
+#define SPELL_RITUAL_OF_THE_SWORD 48276 //Effect #1 Teleport, Effect #2 Dummy
+#define SPELL_SINSTER_STRIKE 15667
+
+//Yells
+#define SAY_DIALOG_WITH_ARTHAS_1 -1575015
+#define SAY_DIALOG_WITH_ARTHAS_2 -1575016
+#define SAY_DIALOG_WITH_ARTHAS_3 -1575017
+#define SAY_AGGRO -1575018
+#define SAY_SLAY_1 -1575019
+#define SAY_SLAY_2 -1575020
+#define SAY_SLAY_3 -1575021
+#define SAY_DEATH -1575022
+#define SAY_SACRIFICE_PLAYER_1 -1575023
+#define SAY_SACRIFICE_PLAYER_2 -1575024
+#define SAY_SACRIFICE_PLAYER_3 -1575025
+#define SAY_SACRIFICE_PLAYER_4 -1575026
+#define SAY_SACRIFICE_PLAYER_5 -1575027
+
+struct TRINITY_DLL_DECL boss_svalaAI : public ScriptedAI
+{
+ boss_svalaAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_svala(Creature *_Creature)
+{
+ return new boss_svalaAI (_Creature);
+}
+
+void AddSC_boss_svala()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_svala";
+ newscript->GetAI = GetAI_boss_svala;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_ymiron.cpp b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_ymiron.cpp
new file mode 100644
index 00000000000..527a18d9af4
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/boss_ymiron.cpp
@@ -0,0 +1,85 @@
+/* Script Data Start
+SDName: Boss ymiron
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = 'boss_ymiron' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_BANE 48294
+#define SPELL_DARK_SLASH 48292
+#define SPELL_FETID_ROT 48291
+#define SPELL_SCREAMS_OF_THE_DEAD 51750
+#define SPELL_SPIRIT_BURST 48529
+#define SPELL_SPIRIT_STRIKE 48423
+//every 20% stuns the party and runs to a boat
+
+//Yell
+#define SAY_AGGRO -1575028
+#define SAY_SLAY_1 -1575029
+#define SAY_SLAY_2 -1575030
+#define SAY_SLAY_3 -1575031
+#define SAY_SLAY_4 -1575032
+#define SAY_DEATH -1575033
+#define SAY_SUMMON_BJORN -1575034
+#define SAY_SUMMON_HALDOR -1575035
+#define SAY_SUMMON_RANULF -1575036
+#define SAY_SUMMON_TORGYN -1575037
+
+struct TRINITY_DLL_DECL boss_ymironAI : public ScriptedAI
+{
+ boss_ymironAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%4)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ case 3: DoScriptText(SAY_SLAY_4, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_ymiron(Creature *_Creature)
+{
+ return new boss_ymironAI (_Creature);
+}
+
+void AddSC_boss_ymiron()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_ymiron";
+ newscript->GetAI = GetAI_boss_ymiron;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/def_pinnacle.h b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/def_pinnacle.h
new file mode 100644
index 00000000000..82e2173fab5
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/def_pinnacle.h
@@ -0,0 +1,4 @@
+#ifndef DEF_PINNACLE_H
+#define DEF_PINNACLE_H
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/instance_pinnacle.cpp b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/instance_pinnacle.cpp
new file mode 100644
index 00000000000..0772aee0647
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/utgarde_keep/utgarde_pinnacle/instance_pinnacle.cpp
@@ -0,0 +1,21 @@
+#include "precompiled.h"
+#include "def_pinnacle.h"
+
+struct TRINITY_DLL_DECL instance_pinnacle : public ScriptedInstance
+{
+ instance_pinnacle(Map *Map) : ScriptedInstance(Map) {Initialize();};
+};
+
+InstanceData* GetInstanceData_instance_pinnacle(Map* map)
+{
+ return new instance_pinnacle(map);
+}
+
+void AddSC_instance_pinnacle()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_pinnacle";
+ newscript->GetInstanceData = GetInstanceData_instance_pinnacle;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/vault_of_archavon/boss_archavon.cpp b/src/bindings/scripts/scripts/zone/vault_of_archavon/boss_archavon.cpp
new file mode 100644
index 00000000000..9eb629f2f5f
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/vault_of_archavon/boss_archavon.cpp
@@ -0,0 +1,93 @@
+/* Script Data Start
+SDName: Boss archavon
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells Archavon
+#define SPELL_ROCK_SHARDS 60883 //Instant -- Hurls a jagged rock shard, inflicting 707 to 793 Physical damage to any enemies within 5 of the target.
+#define SPELL_CRUSHING_LEAP 60895 //Instant (10-80yr range) -- Leaps at an enemy, inflicting 8000 Physical damage, knocking all nearby enemies away, and creating a cloud of choking debris.
+#define SPELL_CHOKING_CLOUD 61672 //Leaving behind CRUSHING_LEAP --> Slams into the ground, kicking up an asphyxiating cloud of debris, inflicting 2828 to 3172 Nature damage per second to all enemies caught within and reducing their chance to hit by 50%.
+//#define SPELL_STOMP //48131 or 55292 or 60880
+#define SPELL_IMPALE 60882 //Lifts an enemy off the ground with a spiked fist, inflicting 47125 to 52875 Physical damage and 9425 to 10575 additional damage each second for 8 sec.
+
+//Spells Archavon Warders
+#define SPELL_ROCK_SHOWER_N 60919
+#define SPELL_ROCK_SHOWER_H 60923
+#define SPELL_SHIELD_CRUSH_N 60897
+#define SPELL_SHIELD_CRUSH_H 60899
+#define SPELL_WHIRL_N 60902
+#define SPELL_WHIRL_H 60916
+
+//4 Warders spawned
+#define ARCHAVON_WARDER 32353 //npc 32353
+
+//Yell
+#define SAY_LEAP "Archavon the Stone Watcher lunges for $N!" //$N should be the target
+
+struct TRINITY_DLL_DECL boss_archavonAI : public ScriptedAI
+{
+ boss_archavonAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+};
+
+/*######
+## Mob Archavon Warder
+######*/
+struct TRINITY_DLL_DECL mob_warderAI : public ScriptedAI //npc 32353
+{
+ mob_warderAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+};
+
+CreatureAI* GetAI_mob_warder(Creature *_Creature)
+{
+ return new mob_warderAI (_Creature);
+}
+
+CreatureAI* GetAI_boss_archavon(Creature *_Creature)
+{
+ return new boss_archavonAI (_Creature);
+}
+
+void AddSC_boss_archavon()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_archavon";
+ newscript->GetAI = GetAI_boss_archavon;
+ newscript->RegisterSelf();
+
+ newscript = new Script;
+ newscript->Name="mob_archavon_warder";
+ newscript->GetAI = GetAI_mob_warder;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/vault_of_archavon/def_vault_of_archavon.h b/src/bindings/scripts/scripts/zone/vault_of_archavon/def_vault_of_archavon.h
new file mode 100644
index 00000000000..f46ba447945
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/vault_of_archavon/def_vault_of_archavon.h
@@ -0,0 +1,4 @@
+#ifndef DEF_ARCHAVON_H
+#define DEF_ARCHAVON_H
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/vault_of_archavon/instance_vault_of_archavon.cpp b/src/bindings/scripts/scripts/zone/vault_of_archavon/instance_vault_of_archavon.cpp
new file mode 100644
index 00000000000..94ee36212ec
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/vault_of_archavon/instance_vault_of_archavon.cpp
@@ -0,0 +1,21 @@
+#include "precompiled.h"
+#include "def_vault_of_archavon.h"
+
+struct TRINITY_DLL_DECL instance_archavon : public ScriptedInstance
+{
+ instance_archavon(Map *Map) : ScriptedInstance(Map) {Initialize();};
+};
+
+InstanceData* GetInstanceData_instance_archavon(Map* map)
+{
+ return new instance_archavon(map);
+}
+
+void AddSC_instance_archavon()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_archavon";
+ newscript->GetInstanceData = GetInstanceData_instance_archavon;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/violet_hold/boss_cyanigosa.cpp b/src/bindings/scripts/scripts/zone/violet_hold/boss_cyanigosa.cpp
new file mode 100644
index 00000000000..cf6833d94bb
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/violet_hold/boss_cyanigosa.cpp
@@ -0,0 +1,82 @@
+/* Script Data Start
+SDName: Boss cyanigosa
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_ARCANE_VACUM 58694
+#define SPELL_BLIZZARD 58693
+#define SPELL_MANA_DESTRUCTION 59374
+#define SPELL_TAIL_SWEEP 58690
+#define SPELL_UNCONTROLLABLE_ENERGY 58688
+
+//Yells
+#define SAY_AGGRO -1608000
+#define SAY_SLAY_1 -1608001
+#define SAY_SLAY_2 -1608002
+#define SAY_SLAY_3 -1608003
+#define SAY_DEATH -1608004
+#define SAY_SPAWN -1608005
+#define SAY_DISRUPTION -1608006
+#define SAY_BREATH_ATTACK -1608007
+#define SAY_SPECIAL_ATTACK_1 -1608008
+#define SAY_SPECIAL_ATTACK_2 -1608009
+
+struct TRINITY_DLL_DECL boss_cyanigosaAI : public ScriptedAI
+{
+ boss_cyanigosaAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_cyanigosa(Creature *_Creature)
+{
+ return new boss_cyanigosaAI (_Creature);
+}
+
+void AddSC_boss_cyanigosa()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_cyanigosa";
+ newscript->GetAI = GetAI_boss_cyanigosa;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/violet_hold/boss_erekem.cpp b/src/bindings/scripts/scripts/zone/violet_hold/boss_erekem.cpp
new file mode 100644
index 00000000000..c74b3e28b6f
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/violet_hold/boss_erekem.cpp
@@ -0,0 +1,82 @@
+/* Script Data Start
+SDName: Boss erekem
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_BLOODLUST 54516
+#define SPELL_BREAK_BONDS 59463
+#define SPELL_CHAIN_HEAL 54481
+#define SPELL_EARTH_SHIELD 54479
+#define SPELL_EARTH_SHOCK 54511
+#define SPELL_LIGHTNING_BOLT 53044
+#define SPELL_STORMSTRIKE 51876
+
+//Yells
+#define SAY_AGGRO -1608010
+#define SAY_SLAY_1 -1608011
+#define SAY_SLAY_2 -1608012
+#define SAY_SLAY_3 -1608013
+#define SAY_DEATH -1608014
+#define SAY_SPAWN -1608015
+#define SAY_ADD_KILED -1608016
+#define SAY_BOTH_ADDS_KILED -1608017
+
+struct TRINITY_DLL_DECL boss_erekemAI : public ScriptedAI
+{
+ boss_erekemAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_erekem(Creature *_Creature)
+{
+ return new boss_erekemAI (_Creature);
+}
+
+void AddSC_boss_erekem()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_erekem";
+ newscript->GetAI = GetAI_boss_erekem;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/violet_hold/boss_ichoron.cpp b/src/bindings/scripts/scripts/zone/violet_hold/boss_ichoron.cpp
new file mode 100644
index 00000000000..871eba33c32
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/violet_hold/boss_ichoron.cpp
@@ -0,0 +1,81 @@
+/* Script Data Start
+SDName: Boss ichoron
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_DRAINED 59820
+#define SPELL_FRENZY 54312
+#define SPELL_PROTECTIVE_BUBBLE 54306
+#define SPELL_WATER_BLAST 54237
+#define SPELL_WATER_BOLT_VOLLEY 54241
+
+//Yells
+#define SAY_AGGRO -1608018
+#define SAY_SLAY_1 -1608019
+#define SAY_SLAY_2 -1608020
+#define SAY_SLAY_3 -1608021
+#define SAY_DEATH -1608022
+#define SAY_SPAWN -1608023
+#define SAY_ENRAGE -1608024
+#define SAY_SHATTER -1608025
+#define SAY_BUBBLE -1608026
+
+struct TRINITY_DLL_DECL boss_ichoronAI : public ScriptedAI
+{
+ boss_ichoronAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_ichoron(Creature *_Creature)
+{
+ return new boss_ichoronAI (_Creature);
+}
+
+void AddSC_boss_ichoron()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_ichoron";
+ newscript->GetAI = GetAI_boss_ichoron;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/violet_hold/boss_lavanthor.cpp b/src/bindings/scripts/scripts/zone/violet_hold/boss_lavanthor.cpp
new file mode 100644
index 00000000000..2f88a6f2e30
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/violet_hold/boss_lavanthor.cpp
@@ -0,0 +1,52 @@
+/* Script Data Start
+SDName: Boss lavanthor
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_CAUTERIZING_FLAMES 59466
+#define SPELL_FIREBOLT 54235
+#define SPELL_FLAME_BREATH 54282
+#define SPELL_LAVA_BURN 54249
+
+struct TRINITY_DLL_DECL boss_lavanthorAI : public ScriptedAI
+{
+ boss_lavanthorAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+CreatureAI* GetAI_boss_lavanthor(Creature *_Creature)
+{
+ return new boss_lavanthorAI (_Creature);
+}
+
+void AddSC_boss_lavanthor()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_lavanthor";
+ newscript->GetAI = GetAI_boss_lavanthor;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/violet_hold/boss_moragg.cpp b/src/bindings/scripts/scripts/zone/violet_hold/boss_moragg.cpp
new file mode 100644
index 00000000000..72be8a72632
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/violet_hold/boss_moragg.cpp
@@ -0,0 +1,50 @@
+/* Script Data Start
+SDName: Boss moragg
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_CORROSICE_SALIVA 54527
+#define SPELL_OPTIC_LINK 54396
+
+struct TRINITY_DLL_DECL boss_moraggAI : public ScriptedAI
+{
+ boss_moraggAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who) {}
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer) {}
+};
+
+CreatureAI* GetAI_boss_moragg(Creature *_Creature)
+{
+ return new boss_moraggAI (_Creature);
+}
+
+void AddSC_boss_moragg()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_moragg";
+ newscript->GetAI = GetAI_boss_moragg;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/violet_hold/boss_xevozz.cpp b/src/bindings/scripts/scripts/zone/violet_hold/boss_xevozz.cpp
new file mode 100644
index 00000000000..e8653018cc9
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/violet_hold/boss_xevozz.cpp
@@ -0,0 +1,82 @@
+/* Script Data Start
+SDName: Boss xevozz
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_ARCANE_BARRAGE_VOLLEY 54202
+#define SPELL_ARCANE_BUFFET 54226
+#define SPELL_SUMMON_ETHEREAL_SPHERE_1 54102
+#define SPELL_SUMMON_ETHEREAL_SPHERE_2 54137
+#define SPELL_SUMMON_ETHEREAL_SPHERE_3 54138
+
+//Yells
+#define SAY_AGGRO -1608027
+#define SAY_SLAY_1 -1608028
+#define SAY_SLAY_2 -1608029
+#define SAY_SLAY_3 -1608030
+#define SAY_DEATH -1608031
+#define SAY_SPAWN -1608032
+#define SAY_CHARGED -1608033
+#define SAY_REPEAT_SUMMON_1 -1608034
+#define SAY_REPEAT_SUMMON_2 -1608035
+#define SAY_SUMMON_ENERGY -1608036
+
+struct TRINITY_DLL_DECL boss_xevozzAI : public ScriptedAI
+{
+ boss_xevozzAI(Creature *c) : ScriptedAI(c) {}
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_xevozz(Creature *_Creature)
+{
+ return new boss_xevozzAI (_Creature);
+}
+
+void AddSC_boss_xevozz()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_xevozz";
+ newscript->GetAI = GetAI_boss_xevozz;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/violet_hold/boss_zuramat.cpp b/src/bindings/scripts/scripts/zone/violet_hold/boss_zuramat.cpp
new file mode 100644
index 00000000000..e14c3ba672d
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/violet_hold/boss_zuramat.cpp
@@ -0,0 +1,82 @@
+/* Script Data Start
+SDName: Boss zuramat
+SDAuthor: LordVanMartin
+SD%Complete:
+SDComment:
+SDCategory:
+Script Data End */
+
+/*** SQL START ***
+update creature_template set scriptname = '' where entry = '';
+*** SQL END ***/
+#include "precompiled.h"
+
+//Spells
+#define SPELL_SHROUD_OF_DARKNESS 54524
+#define SPELL_SUMMON_VOID_SENTRY 54524
+#define SPELL_VOID_SHIFT 54524
+
+#define NPC_VOID_SENTRY 29364
+
+//Yells
+#define SAY_AGGRO -1608037
+#define SAY_SLAY_1 -1608038
+#define SAY_SLAY_2 -1608039
+#define SAY_SLAY_3 -1608040
+#define SAY_DEATH -1608041
+#define SAY_SPAWN -1608042
+#define SAY_SHIELD -1608043
+#define SAY_WHISPER -1608044
+
+struct TRINITY_DLL_DECL boss_zuramatAI : public ScriptedAI
+{
+ boss_zuramatAI(Creature *c) : ScriptedAI(c) {}
+
+ uint32 void_shift;
+
+ void Reset() {}
+ void Aggro(Unit* who)
+ {
+ DoScriptText(SAY_AGGRO, m_creature);
+ }
+ void AttackStart(Unit* who) {}
+ void MoveInLineOfSight(Unit* who) {}
+ void UpdateAI(const uint32 diff)
+ {
+ //Return since we have no target
+ if(!UpdateVictim())
+ return;
+
+ DoMeleeAttackIfReady();
+ }
+ void JustDied(Unit* killer)
+ {
+ DoScriptText(SAY_DEATH, m_creature);
+ }
+ void KilledUnit(Unit *victim)
+ {
+ if(victim == m_creature)
+ return;
+ switch(rand()%3)
+ {
+ case 0: DoScriptText(SAY_SLAY_1, m_creature);break;
+ case 1: DoScriptText(SAY_SLAY_2, m_creature);break;
+ case 2: DoScriptText(SAY_SLAY_3, m_creature);break;
+ }
+ }
+};
+
+CreatureAI* GetAI_boss_zuramat(Creature *_Creature)
+{
+ return new boss_zuramatAI (_Creature);
+}
+
+void AddSC_boss_zuramat()
+{
+ Script *newscript;
+
+ newscript = new Script;
+ newscript->Name="boss_zuramat";
+ newscript->GetAI = GetAI_boss_zuramat;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/violet_hold/def_violet_hold.h b/src/bindings/scripts/scripts/zone/violet_hold/def_violet_hold.h
new file mode 100644
index 00000000000..71bc0d18d2f
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/violet_hold/def_violet_hold.h
@@ -0,0 +1,4 @@
+#ifndef DEF_VIOLET_HOLD_H
+#define DEF_VIOLET_HOLD_H
+
+#endif
diff --git a/src/bindings/scripts/scripts/zone/violet_hold/instance_violet_hold.cpp b/src/bindings/scripts/scripts/zone/violet_hold/instance_violet_hold.cpp
new file mode 100644
index 00000000000..5d6ba3a5be3
--- /dev/null
+++ b/src/bindings/scripts/scripts/zone/violet_hold/instance_violet_hold.cpp
@@ -0,0 +1,21 @@
+#include "precompiled.h"
+#include "def_violet_hold.h"
+
+struct TRINITY_DLL_DECL instance_violet_hold : public ScriptedInstance
+{
+ instance_violet_hold(Map *Map) : ScriptedInstance(Map) {Initialize();};
+};
+
+InstanceData* GetInstanceData_instance_violet_hold(Map* map)
+{
+ return new instance_violet_hold(map);
+}
+
+void AddSC_instance_violet_hold()
+{
+ Script *newscript;
+ newscript = new Script;
+ newscript->Name = "instance_violet_hold";
+ newscript->GetInstanceData = GetInstanceData_instance_violet_hold;
+ newscript->RegisterSelf();
+}
diff --git a/src/bindings/scripts/scripts/zone/wailing_caverns/instance_wailing_caverns.cpp b/src/bindings/scripts/scripts/zone/wailing_caverns/instance_wailing_caverns.cpp
index 9aaa32725c1..5327bf7041d 100644
--- a/src/bindings/scripts/scripts/zone/wailing_caverns/instance_wailing_caverns.cpp
+++ b/src/bindings/scripts/scripts/zone/wailing_caverns/instance_wailing_caverns.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/western_plaguelands/western_plaguelands.cpp b/src/bindings/scripts/scripts/zone/western_plaguelands/western_plaguelands.cpp
index 3019331ea05..70033f7c97b 100644
--- a/src/bindings/scripts/scripts/zone/western_plaguelands/western_plaguelands.cpp
+++ b/src/bindings/scripts/scripts/zone/western_plaguelands/western_plaguelands.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/westfall/westfall.cpp b/src/bindings/scripts/scripts/zone/westfall/westfall.cpp
index 749296167fe..9f981d4a35c 100644
--- a/src/bindings/scripts/scripts/zone/westfall/westfall.cpp
+++ b/src/bindings/scripts/scripts/zone/westfall/westfall.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -38,7 +38,10 @@ EndContentData */
struct TRINITY_DLL_DECL npc_defias_traitorAI : public npc_escortAI
{
- npc_defias_traitorAI(Creature *c) : npc_escortAI(c) {}
+ npc_defias_traitorAI(Creature *c) : npc_escortAI(c)
+ {
+ IsWalking = false;
+ }
bool IsWalking;
@@ -114,55 +117,11 @@ bool QuestAccept_npc_defias_traitor(Player* player, Creature* creature, Quest co
return true;
}
-CreatureAI* GetAI_npc_defias_traitor(Creature *_Creature)
+CreatureAI* GetAI_npc_defias_traitor(Creature* pCreature)
{
- npc_defias_traitorAI* thisAI = new npc_defias_traitorAI(_Creature);
-
- thisAI->AddWaypoint(0, -10508.40, 1068.00, 55.21);
- thisAI->AddWaypoint(1, -10518.30, 1074.84, 53.96);
- thisAI->AddWaypoint(2, -10534.82, 1081.92, 49.88);
- thisAI->AddWaypoint(3, -10546.51, 1084.88, 50.13);
- thisAI->AddWaypoint(4, -10555.29, 1084.45, 45.75);
- thisAI->AddWaypoint(5, -10566.57, 1083.53, 42.10);
- thisAI->AddWaypoint(6, -10575.83, 1082.34, 39.46);
- thisAI->AddWaypoint(7, -10585.67, 1081.08, 37.77);
- thisAI->AddWaypoint(8, -10600.08, 1078.19, 36.23);
- thisAI->AddWaypoint(9, -10608.69, 1076.08, 35.88);
- thisAI->AddWaypoint(10, -10621.26, 1073.00, 35.40);
- thisAI->AddWaypoint(11, -10638.12, 1060.18, 33.61);
- thisAI->AddWaypoint(12, -10655.87, 1038.99, 33.48);
- thisAI->AddWaypoint(13, -10664.68, 1030.54, 32.70);
- thisAI->AddWaypoint(14, -10708.68, 1033.86, 33.32);
- thisAI->AddWaypoint(15, -10754.43, 1017.93, 32.79);
- thisAI->AddWaypoint(16, -10802.26, 1018.01, 32.16);
- thisAI->AddWaypoint(17, -10832.60, 1009.04, 32.71);
- thisAI->AddWaypoint(18, -10866.56, 1006.51, 31.71); // Fix waypoints from roughly this point, test first to get proper one
- thisAI->AddWaypoint(19, -10879.98, 1005.10, 32.84);
- thisAI->AddWaypoint(20, -10892.45, 1001.32, 34.46);
- thisAI->AddWaypoint(21, -10906.14, 997.11, 36.15);
- thisAI->AddWaypoint(22, -10922.26, 1002.23, 35.74);
- thisAI->AddWaypoint(23, -10936.32, 1023.38, 36.52);
- thisAI->AddWaypoint(24, -10933.35, 1052.61, 35.85);
- thisAI->AddWaypoint(25, -10940.25, 1077.66, 36.49);
- thisAI->AddWaypoint(26, -10957.09, 1099.33, 36.83);
- thisAI->AddWaypoint(27, -10956.53, 1119.90, 36.73);
- thisAI->AddWaypoint(28, -10939.30, 1150.75, 37.42);
- thisAI->AddWaypoint(29, -10915.14, 1202.09, 36.55);
- thisAI->AddWaypoint(30, -10892.59, 1257.03, 33.37);
- thisAI->AddWaypoint(31, -10891.93, 1306.66, 35.45);
- thisAI->AddWaypoint(32, -10896.17, 1327.86, 37.77);
- thisAI->AddWaypoint(33, -10906.03, 1368.05, 40.91);
- thisAI->AddWaypoint(34, -10910.18, 1389.33, 42.62);
- thisAI->AddWaypoint(35, -10915.42, 1417.72, 42.93);
- thisAI->AddWaypoint(36, -10926.37, 1421.18, 43.04); // walk here and say
- thisAI->AddWaypoint(37, -10952.31, 1421.74, 43.40);
- thisAI->AddWaypoint(38, -10980.04, 1411.38, 42.79);
- thisAI->AddWaypoint(39, -11006.06, 1420.47, 43.26);
- thisAI->AddWaypoint(40, -11021.98, 1450.59, 43.09);
- thisAI->AddWaypoint(41, -11025.36, 1491.59, 43.15);
- thisAI->AddWaypoint(42, -11036.09, 1508.32, 43.28);
- thisAI->AddWaypoint(43, -11060.68, 1526.72, 43.19);
- thisAI->AddWaypoint(44, -11072.75, 1527.77, 43.20, 5000);// say and quest credit
+ npc_defias_traitorAI* thisAI = new npc_defias_traitorAI(pCreature);
+
+ thisAI->FillPointMovementListForCreature();
return (CreatureAI*)thisAI;
}
diff --git a/src/bindings/scripts/scripts/zone/winterspring/winterspring.cpp b/src/bindings/scripts/scripts/zone/winterspring/winterspring.cpp
index 1986d2c1b27..db6555d058f 100644
--- a/src/bindings/scripts/scripts/zone/winterspring/winterspring.cpp
+++ b/src/bindings/scripts/scripts/zone/winterspring/winterspring.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zangarmarsh/zangarmarsh.cpp b/src/bindings/scripts/scripts/zone/zangarmarsh/zangarmarsh.cpp
index b5f194d8035..ebe549a0599 100644
--- a/src/bindings/scripts/scripts/zone/zangarmarsh/zangarmarsh.cpp
+++ b/src/bindings/scripts/scripts/zone/zangarmarsh/zangarmarsh.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulaman/boss_akilzon.cpp b/src/bindings/scripts/scripts/zone/zulaman/boss_akilzon.cpp
index ea832370ea3..704cadb0bcd 100644
--- a/src/bindings/scripts/scripts/zone/zulaman/boss_akilzon.cpp
+++ b/src/bindings/scripts/scripts/zone/zulaman/boss_akilzon.cpp
@@ -187,7 +187,7 @@ struct TRINITY_DLL_DECL boss_akilzonAI : public ScriptedAI
{
Trinity::AnyAoETargetUnitInObjectRangeCheck u_check(m_creature, m_creature, 999);
- Trinity::UnitListSearcher<Trinity::AnyAoETargetUnitInObjectRangeCheck> searcher(tempUnitMap, u_check);
+ Trinity::UnitListSearcher<Trinity::AnyAoETargetUnitInObjectRangeCheck> searcher(m_creature, tempUnitMap, u_check);
TypeContainerVisitor<Trinity::UnitListSearcher<Trinity::AnyAoETargetUnitInObjectRangeCheck>, WorldTypeMapContainer > world_unit_searcher(searcher);
TypeContainerVisitor<Trinity::UnitListSearcher<Trinity::AnyAoETargetUnitInObjectRangeCheck>, GridTypeMapContainer > grid_unit_searcher(searcher);
diff --git a/src/bindings/scripts/scripts/zone/zulaman/boss_halazzi.cpp b/src/bindings/scripts/scripts/zone/zulaman/boss_halazzi.cpp
index 6e7311d8917..b9601764d1b 100644
--- a/src/bindings/scripts/scripts/zone/zulaman/boss_halazzi.cpp
+++ b/src/bindings/scripts/scripts/zone/zulaman/boss_halazzi.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulaman/boss_hexlord.cpp b/src/bindings/scripts/scripts/zone/zulaman/boss_hexlord.cpp
index 8792a988c6f..95db93e71fb 100644
--- a/src/bindings/scripts/scripts/zone/zulaman/boss_hexlord.cpp
+++ b/src/bindings/scripts/scripts/zone/zulaman/boss_hexlord.cpp
@@ -237,8 +237,7 @@ struct TRINITY_DLL_DECL boss_hex_lord_malacrassAI : public ScriptedAI
SpawnAdds();
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 46916);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, 50268674);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 46916);
m_creature->SetByteValue(UNIT_FIELD_BYTES_2, 0, SHEATH_STATE_MELEE );
}
diff --git a/src/bindings/scripts/scripts/zone/zulaman/boss_janalai.cpp b/src/bindings/scripts/scripts/zone/zulaman/boss_janalai.cpp
index c70bd007c58..5c1d9177d6b 100644
--- a/src/bindings/scripts/scripts/zone/zulaman/boss_janalai.cpp
+++ b/src/bindings/scripts/scripts/zone/zulaman/boss_janalai.cpp
@@ -1,4 +1,4 @@
- /* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ /* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -238,7 +238,7 @@ struct TRINITY_DLL_DECL boss_janalaiAI : public ScriptedAI
cell.SetNoCreate();
Trinity::AllCreaturesOfEntryInRange check(m_creature, MOB_EGG, 100);
- Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(templist, check);
+ Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(m_creature, templist, check);
TypeContainerVisitor<Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange>, GridTypeMapContainer> cSearcher(searcher);
@@ -273,7 +273,7 @@ struct TRINITY_DLL_DECL boss_janalaiAI : public ScriptedAI
cell.SetNoCreate();
Trinity::AllCreaturesOfEntryInRange check(m_creature, MOB_FIRE_BOMB, 100);
- Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(templist, check);
+ Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(m_creature, templist, check);
TypeContainerVisitor<Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange>, GridTypeMapContainer> cSearcher(searcher);
@@ -397,7 +397,7 @@ struct TRINITY_DLL_DECL boss_janalaiAI : public ScriptedAI
m_creature->AttackStop();
m_creature->GetMotionMaster()->Clear();
- DoTeleportTo(JanalainPos[0][0],JanalainPos[0][1],JanalainPos[0][2]);
+ DoTeleportTo(JanalainPos[0][0],JanalainPos[0][1],JanalainPos[0][2]);
m_creature->StopMoving();
m_creature->CastSpell(m_creature, SPELL_HATCH_ALL, false);
HatchAllEggs(2);
@@ -517,7 +517,7 @@ struct TRINITY_DLL_DECL mob_amanishi_hatcherAI : public ScriptedAI
cell.SetNoCreate();
Trinity::AllCreaturesOfEntryInRange check(m_creature, 23817, 50);
- Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(templist, check);
+ Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(m_creature, templist, check);
TypeContainerVisitor<Trinity::CreatureListSearcher<Trinity::AllCreaturesOfEntryInRange>, GridTypeMapContainer> cSearcher(searcher);
diff --git a/src/bindings/scripts/scripts/zone/zulaman/boss_nalorakk.cpp b/src/bindings/scripts/scripts/zone/zulaman/boss_nalorakk.cpp
index 75d08661834..0212e4005f5 100644
--- a/src/bindings/scripts/scripts/zone/zulaman/boss_nalorakk.cpp
+++ b/src/bindings/scripts/scripts/zone/zulaman/boss_nalorakk.cpp
@@ -1,4 +1,4 @@
- /* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ /* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -142,7 +142,7 @@ struct TRINITY_DLL_DECL boss_nalorakkAI : public ScriptedAI
Berserk_Timer = 600000;
inBearForm = false;
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY + 1, 5122);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 1, 5122);
}
void SendAttacker(Unit* target)
@@ -158,7 +158,7 @@ struct TRINITY_DLL_DECL boss_nalorakkAI : public ScriptedAI
cell.SetNoCreate();
Trinity::AllFriendlyCreaturesInGrid check(m_creature);
- Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> searcher(templist, check);
+ Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid> searcher(m_creature, templist, check);
TypeContainerVisitor<Trinity::CreatureListSearcher<Trinity::AllFriendlyCreaturesInGrid>, GridTypeMapContainer> cSearcher(searcher);
@@ -360,7 +360,7 @@ struct TRINITY_DLL_DECL boss_nalorakkAI : public ScriptedAI
{
if(inBearForm)
{
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY + 1, 5122);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 1, 5122);
DoYell(YELL_SHIFTEDTOTROLL, LANG_UNIVERSAL, NULL);
DoPlaySoundToSet(m_creature, SOUND_YELL_TOTROLL);
m_creature->RemoveAurasDueToSpell(SPELL_BEARFORM);
@@ -372,7 +372,7 @@ struct TRINITY_DLL_DECL boss_nalorakkAI : public ScriptedAI
}
else
{
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY + 1, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + 1, 0);
DoYell(YELL_SHIFTEDTOBEAR, LANG_UNIVERSAL, NULL);
DoPlaySoundToSet(m_creature, SOUND_YELL_TOBEAR);
DoCast(m_creature, SPELL_BEARFORM, true);
@@ -394,7 +394,7 @@ struct TRINITY_DLL_DECL boss_nalorakkAI : public ScriptedAI
if(Mangle_Timer < diff)
{
- if(m_creature->getVictim() && !m_creature->getVictim()->HasAura(SPELL_MANGLEEFFECT, 0))
+ if(m_creature->getVictim() && !m_creature->getVictim()->HasAura(SPELL_MANGLEEFFECT))
{
DoCast(m_creature->getVictim(), SPELL_MANGLE);
Mangle_Timer = 1000;
@@ -406,7 +406,7 @@ struct TRINITY_DLL_DECL boss_nalorakkAI : public ScriptedAI
{
DoYell(YELL_SURGE, LANG_UNIVERSAL, NULL);
DoPlaySoundToSet(m_creature, SOUND_YELL_SURGE);
- Unit *target = SelectUnit(SELECT_TARGET_RANDOM, 1, GetSpellMaxRange(SPELL_SURGE), true);
+ Unit *target = SelectUnit(SELECT_TARGET_RANDOM, 1, GetSpellMaxRangeForHostile(SPELL_SURGE), true);
DoCast(target, SPELL_SURGE);
Surge_Timer = 15000 + rand()%5000;
}else Surge_Timer -= diff;
diff --git a/src/bindings/scripts/scripts/zone/zulaman/boss_zuljin.cpp b/src/bindings/scripts/scripts/zone/zulaman/boss_zuljin.cpp
index cf319c8f063..4150e0ec393 100644
--- a/src/bindings/scripts/scripts/zone/zulaman/boss_zuljin.cpp
+++ b/src/bindings/scripts/scripts/zone/zulaman/boss_zuljin.cpp
@@ -206,9 +206,9 @@ struct TRINITY_DLL_DECL boss_zuljinAI : public ScriptedAI
Summons.DespawnAll();
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 47174);
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, 218172674);
- m_creature->SetByteValue(UNIT_FIELD_BYTES_2, 0, SHEATH_STATE_MELEE);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 47174);
+ //m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_INFO, 218172674);
+ //m_creature->SetByteValue(UNIT_FIELD_BYTES_2, 0, SHEATH_STATE_MELEE);
}
void Aggro(Unit *who)
@@ -252,7 +252,7 @@ struct TRINITY_DLL_DECL boss_zuljinAI : public ScriptedAI
Summons.DespawnEntry(CREATURE_COLUMN_OF_FIRE);
if(Unit *Temp = Unit::GetUnit(*m_creature, SpiritGUID[3]))
- Temp->SetUInt32Value(UNIT_FIELD_BYTES_1,PLAYER_STATE_DEAD);
+ Temp->SetUInt32Value(UNIT_FIELD_BYTES_1,UNIT_STAND_STATE_DEAD);
}
void AttackStart(Unit *who)
@@ -339,7 +339,7 @@ struct TRINITY_DLL_DECL boss_zuljinAI : public ScriptedAI
case 4:
DoTeleportTo(CENTER_X, CENTER_Y, CENTER_Z, 100);
DoResetThreat();
- m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 0);
+ m_creature->SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID, 0);
m_creature->RemoveAurasDueToSpell(Transform[Phase].unaura);
DoCast(m_creature, Transform[Phase].spell);
DoYell(Transform[Phase].text, LANG_UNIVERSAL, NULL);
@@ -347,7 +347,7 @@ struct TRINITY_DLL_DECL boss_zuljinAI : public ScriptedAI
if(Phase > 0)
{
if(Unit *Temp = Unit::GetUnit(*m_creature, SpiritGUID[Phase - 1]))
- Temp->SetUInt32Value(UNIT_FIELD_BYTES_1,PLAYER_STATE_DEAD);
+ Temp->SetUInt32Value(UNIT_FIELD_BYTES_1,UNIT_STAND_STATE_DEAD);
}
if(Unit *Temp = Unit::GetUnit(*m_creature, SpiritGUID[NextPhase - 1]))
Temp->CastSpell(m_creature, SPELL_SIPHON_SOUL, false); // should m cast on temp
diff --git a/src/bindings/scripts/scripts/zone/zulaman/def_zulaman.h b/src/bindings/scripts/scripts/zone/zulaman/def_zulaman.h
index c249cf6b3ec..6fb0ef173bd 100644
--- a/src/bindings/scripts/scripts/zone/zulaman/def_zulaman.h
+++ b/src/bindings/scripts/scripts/zone/zulaman/def_zulaman.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/zulaman/instance_zulaman.cpp b/src/bindings/scripts/scripts/zone/zulaman/instance_zulaman.cpp
index a56cdf3f9a7..2ff8a6e9b8a 100644
--- a/src/bindings/scripts/scripts/zone/zulaman/instance_zulaman.cpp
+++ b/src/bindings/scripts/scripts/zone/zulaman/instance_zulaman.cpp
@@ -1,4 +1,4 @@
- /* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+ /* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -106,7 +106,7 @@ struct TRINITY_DLL_DECL instance_zulaman : public ScriptedInstance
void OnCreatureCreate(Creature *creature, uint32 creature_entry)
{
- switch(creature_entry)
+ switch(creature->GetEntry())
{
case 23578://janalai
case 23863://zuljin
@@ -140,7 +140,7 @@ struct TRINITY_DLL_DECL instance_zulaman : public ScriptedInstance
void OpenDoor(uint64 DoorGUID, bool open)
{
if(GameObject *Door = instance->GetGameObjectInMap(DoorGUID))
- Door->SetUInt32Value(GAMEOBJECT_STATE, open ? 0 : 1);
+ Door->SetGoState(open ? 0 : 1);
}
void SummonHostage(uint8 num)
diff --git a/src/bindings/scripts/scripts/zone/zulaman/zulaman.cpp b/src/bindings/scripts/scripts/zone/zulaman/zulaman.cpp
index 9f3588e387a..62130f9a863 100644
--- a/src/bindings/scripts/scripts/zone/zulaman/zulaman.cpp
+++ b/src/bindings/scripts/scripts/zone/zulaman/zulaman.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulfarrak/zulfarrak.cpp b/src/bindings/scripts/scripts/zone/zulfarrak/zulfarrak.cpp
index 3d233037d16..b53855990b3 100644
--- a/src/bindings/scripts/scripts/zone/zulfarrak/zulfarrak.cpp
+++ b/src/bindings/scripts/scripts/zone/zulfarrak/zulfarrak.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_arlokk.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_arlokk.cpp
index a472fff2076..102fef21467 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_arlokk.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_arlokk.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_gahzranka.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_gahzranka.cpp
index 7cf15d53416..e5e727b4843 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_gahzranka.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_gahzranka.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -23,7 +23,7 @@ EndScriptData */
#include "precompiled.h"
-#define SPELL_FROSTBREATH 21099
+#define SPELL_FROSTBREATH 16099
#define SPELL_MASSIVEGEYSER 22421 //Not working. Cause its a summon...
#define SPELL_SLAM 24326
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_grilek.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_grilek.cpp
index 623015acb73..dce2e76e157 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_grilek.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_grilek.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_hakkar.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_hakkar.cpp
index 0d490781ec7..592129b88da 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_hakkar.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_hakkar.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_hazzarah.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_hazzarah.cpp
index efe847045d5..bd341fdaf40 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_hazzarah.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_hazzarah.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_jeklik.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_jeklik.cpp
index aecc2f450db..62a057dc2cb 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_jeklik.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_jeklik.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_jindo.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_jindo.cpp
index 100d8881127..4ea62662ef9 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_jindo.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_jindo.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -54,10 +54,6 @@ struct TRINITY_DLL_DECL boss_jindoAI : public ScriptedAI
uint32 Delusions_Timer;
uint32 Teleport_Timer;
- Creature *Shade;
- Creature *Skeletons;
- Creature *HealingWard;
-
void Reset()
{
BrainWashTotem_Timer = 20000;
@@ -88,7 +84,7 @@ struct TRINITY_DLL_DECL boss_jindoAI : public ScriptedAI
if (HealingWard_Timer < diff)
{
//DoCast(m_creature, SPELL_POWERFULLHEALINGWARD);
- HealingWard = m_creature->SummonCreature(14987, m_creature->GetPositionX()+3, m_creature->GetPositionY()-2, m_creature->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN,30000);
+ m_creature->SummonCreature(14987, m_creature->GetPositionX()+3, m_creature->GetPositionY()-2, m_creature->GetPositionZ(), 0, TEMPSUMMON_TIMED_OR_DEAD_DESPAWN,30000);
HealingWard_Timer = 14000 + rand()%6000;
}else HealingWard_Timer -= diff;
@@ -110,7 +106,8 @@ struct TRINITY_DLL_DECL boss_jindoAI : public ScriptedAI
{
DoCast(target, SPELL_DELUSIONSOFJINDO);
- Shade = m_creature->SummonCreature(14986, target->GetPositionX(), target->GetPositionY(), target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ Creature *Shade = m_creature->SummonCreature(14986, target->GetPositionX(), target->GetPositionY(), target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Shade)
Shade->AI()->AttackStart(target);
}
@@ -129,23 +126,33 @@ struct TRINITY_DLL_DECL boss_jindoAI : public ScriptedAI
if(DoGetThreat(m_creature->getVictim()))
DoModifyThreatPercent(target,-100);
+ Creature *Skeletons;
Skeletons = m_creature->SummonCreature(14826, target->GetPositionX()+2, target->GetPositionY(), target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Skeletons)
Skeletons->AI()->AttackStart(target);
Skeletons = m_creature->SummonCreature(14826, target->GetPositionX()-2, target->GetPositionY(), target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Skeletons)
Skeletons->AI()->AttackStart(target);
Skeletons = m_creature->SummonCreature(14826, target->GetPositionX()+4, target->GetPositionY(), target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Skeletons)
Skeletons->AI()->AttackStart(target);
Skeletons = m_creature->SummonCreature(14826, target->GetPositionX()-4, target->GetPositionY(), target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Skeletons)
Skeletons->AI()->AttackStart(target);
Skeletons = m_creature->SummonCreature(14826, target->GetPositionX(), target->GetPositionY()+2, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Skeletons)
Skeletons->AI()->AttackStart(target);
Skeletons = m_creature->SummonCreature(14826, target->GetPositionX(), target->GetPositionY()-2, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Skeletons)
Skeletons->AI()->AttackStart(target);
Skeletons = m_creature->SummonCreature(14826, target->GetPositionX(), target->GetPositionY()+4, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Skeletons)
Skeletons->AI()->AttackStart(target);
Skeletons = m_creature->SummonCreature(14826, target->GetPositionX(), target->GetPositionY()-4, target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Skeletons)
Skeletons->AI()->AttackStart(target);
Skeletons = m_creature->SummonCreature(14826, target->GetPositionX()+3, target->GetPositionY(), target->GetPositionZ(), 0, TEMPSUMMON_TIMED_DESPAWN_OUT_OF_COMBAT, 15000);
+ if (Skeletons)
Skeletons->AI()->AttackStart(target);
}
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_mandokir.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_mandokir.cpp
index 87939596324..7ad5be3fefd 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_mandokir.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_mandokir.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_marli.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_marli.cpp
index 69588bdfbb8..44606438a02 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_marli.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_marli.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_renataki.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_renataki.cpp
index 1b01afd9aa1..42742437fec 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_renataki.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_renataki.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -65,9 +65,9 @@ struct TRINITY_DLL_DECL boss_renatakiAI : public ScriptedAI
if (Invisible_Timer < diff)
{
m_creature->InterruptSpell(CURRENT_GENERIC_SPELL);
- m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 0);
- m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_INFO , 218171138);
- m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_INFO + 1, 3);
+ m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_SLOT_ID, 0);
+ //m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_INFO , 218171138);
+ //m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_INFO + 1, 3);
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
m_creature->SetUInt32Value(UNIT_FIELD_DISPLAYID,11686);
Invisible = true;
@@ -99,9 +99,9 @@ struct TRINITY_DLL_DECL boss_renatakiAI : public ScriptedAI
m_creature->InterruptSpell(CURRENT_GENERIC_SPELL);
m_creature->SetUInt32Value(UNIT_FIELD_DISPLAYID,15268);
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_SLOT_DISPLAY, 31818);
- m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_INFO , 218171138);
- m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_INFO + 1, 3);
+ m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_SLOT_ID, 31818);
+ //m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_INFO , 218171138);
+ //m_creature->SetUInt32Value( UNIT_VIRTUAL_ITEM_INFO + 1, 3);
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
Invisible = false;
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_thekal.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_thekal.cpp
index 36e9fd9c84d..7a753dc9e01 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_thekal.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_thekal.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@@ -118,7 +118,7 @@ struct TRINITY_DLL_DECL boss_thekalAI : public ScriptedAI
{
//Resurrect LorKhan
Unit *pLorKhan = Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_LORKHAN));
- pLorKhan->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
+ pLorKhan->SetStandState(UNIT_STAND_STATE_STAND);
pLorKhan->setFaction(14);
pLorKhan->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
pLorKhan->SetHealth(int(pLorKhan->GetMaxHealth()*1.0));
@@ -128,7 +128,7 @@ struct TRINITY_DLL_DECL boss_thekalAI : public ScriptedAI
{
//Resurrect Zath
Unit *pZath = Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_ZATH));
- pZath->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
+ pZath->SetStandState(UNIT_STAND_STATE_STAND);
pZath->setFaction(14);
pZath->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
pZath->SetHealth(int(pZath->GetMaxHealth()*1.0));
@@ -153,7 +153,7 @@ struct TRINITY_DLL_DECL boss_thekalAI : public ScriptedAI
if (!PhaseTwo && !WasDead && m_creature->GetHealth() <= m_creature->GetMaxHealth() * 0.05)
{
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 3);
+ m_creature->SetStandState(UNIT_STAND_STATE_SLEEP);
m_creature->AttackStop();
if(pInstance)
@@ -169,7 +169,7 @@ struct TRINITY_DLL_DECL boss_thekalAI : public ScriptedAI
{
DoCast(m_creature,SPELL_TIGER_FORM);
m_creature->SetFloatValue(OBJECT_FIELD_SCALE_X, 2.00f);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
m_creature->SetHealth(int(m_creature->GetMaxHealth()*1.0));
const CreatureInfo *cinfo = m_creature->GetCreatureInfo();
@@ -328,7 +328,7 @@ struct TRINITY_DLL_DECL mob_zealot_lorkhanAI : public ScriptedAI
{
//Resurrect Thekal
Unit *pThekal = Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_THEKAL));
- pThekal->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
+ pThekal->SetStandState(UNIT_STAND_STATE_STAND);
pThekal->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
pThekal->setFaction(14);
pThekal->SetHealth(int(pThekal->GetMaxHealth()*1.0));
@@ -338,7 +338,7 @@ struct TRINITY_DLL_DECL mob_zealot_lorkhanAI : public ScriptedAI
{
//Resurrect Zath
Unit *pZath = Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_ZATH));
- pZath->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
+ pZath->SetStandState(UNIT_STAND_STATE_STAND);
pZath->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
pZath->setFaction(14);
pZath->SetHealth(int(pZath->GetMaxHealth()*1.0));
@@ -351,7 +351,7 @@ struct TRINITY_DLL_DECL mob_zealot_lorkhanAI : public ScriptedAI
if (m_creature->GetHealth() <= m_creature->GetMaxHealth() * 0.05)
{
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 3);
+ m_creature->SetStandState(UNIT_STAND_STATE_SLEEP);
m_creature->setFaction(35);
m_creature->AttackStop();
@@ -398,7 +398,7 @@ struct TRINITY_DLL_DECL mob_zealot_zathAI : public ScriptedAI
if(pInstance)
pInstance->SetData(DATA_ZATH_ALIVE, 0);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
+ m_creature->SetStandState(UNIT_STAND_STATE_STAND);
m_creature->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
}
@@ -459,7 +459,7 @@ struct TRINITY_DLL_DECL mob_zealot_zathAI : public ScriptedAI
{
//Resurrect LorKhan
Unit *pLorKhan = Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_LORKHAN));
- pLorKhan->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
+ pLorKhan->SetStandState(UNIT_STAND_STATE_STAND);
pLorKhan->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
pLorKhan->setFaction(14);
pLorKhan->SetHealth(int(pLorKhan->GetMaxHealth()*1.0));
@@ -469,7 +469,7 @@ struct TRINITY_DLL_DECL mob_zealot_zathAI : public ScriptedAI
{
//Resurrect Thekal
Unit *pThekal = Unit::GetUnit((*m_creature), pInstance->GetData64(DATA_THEKAL));
- pThekal->SetUInt32Value(UNIT_FIELD_BYTES_1, 0);
+ pThekal->SetStandState(UNIT_STAND_STATE_STAND);
pThekal->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
pThekal->setFaction(14);
pThekal->SetHealth(int(pThekal->GetMaxHealth()*1.0));
@@ -482,7 +482,7 @@ struct TRINITY_DLL_DECL mob_zealot_zathAI : public ScriptedAI
if (m_creature->GetHealth() <= m_creature->GetMaxHealth() * 0.05)
{
m_creature->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE);
- m_creature->SetUInt32Value(UNIT_FIELD_BYTES_1, 3);
+ m_creature->SetStandState(UNIT_STAND_STATE_SLEEP);
m_creature->setFaction(35);
m_creature->AttackStop();
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_venoxis.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_venoxis.cpp
index 29c79a28187..1dff6b63dbe 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_venoxis.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_venoxis.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/boss_wushoolay.cpp b/src/bindings/scripts/scripts/zone/zulgurub/boss_wushoolay.cpp
index c69e2c6204e..1776dfc5868 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/boss_wushoolay.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/boss_wushoolay.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/def_zulgurub.h b/src/bindings/scripts/scripts/zone/zulgurub/def_zulgurub.h
index fd1c905048e..f14bd8eca98 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/def_zulgurub.h
+++ b/src/bindings/scripts/scripts/zone/zulgurub/def_zulgurub.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software licensed under GPL version 2
* Please see the included DOCS/LICENSE.TXT for more information */
diff --git a/src/bindings/scripts/scripts/zone/zulgurub/instance_zulgurub.cpp b/src/bindings/scripts/scripts/zone/zulgurub/instance_zulgurub.cpp
index a49ff110b2d..eb3cbd1d495 100644
--- a/src/bindings/scripts/scripts/zone/zulgurub/instance_zulgurub.cpp
+++ b/src/bindings/scripts/scripts/zone/zulgurub/instance_zulgurub.cpp
@@ -1,4 +1,4 @@
-/* Copyright (C) 2006 - 2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
+/* Copyright (C) 2006 - 2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/>
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
diff --git a/src/bindings/scripts/sql/WotLK/npc_taxi.sql b/src/bindings/scripts/sql/WotLK/npc_taxi.sql
new file mode 100644
index 00000000000..b93f5dfdfca
--- /dev/null
+++ b/src/bindings/scripts/sql/WotLK/npc_taxi.sql
@@ -0,0 +1,10 @@
+#Taxi in Archerus
+UPDATE `creature_template` SET `ScriptName`='npc_acherus_taxi' WHERE `entry`='28864';
+
+#Stormwind Harbor
+UPDATE `creature_template` SET `ScriptName`='npc_stormwindharbor_taxi' WHERE `entry`='29154';
+
+#Taxis to the 3 parts of the Wyrmresttempel
+UPDATE `creature_template` SET `ScriptName`='npc_wyrmresttempelbottom_taxi' WHERE `entry`='26443';
+UPDATE `creature_template` SET `ScriptName`='npc_wyrmresttempelmiddle_taxi' WHERE `entry`='27575';
+UPDATE `creature_template` SET `ScriptName`='npc_wyrmresttempeltop_taxi' WHERE `entry`='26949';
diff --git a/src/bindings/scripts/sql/WotLK/script_texts_wotlk.sql b/src/bindings/scripts/sql/WotLK/script_texts_wotlk.sql
new file mode 100644
index 00000000000..de3de7b9464
--- /dev/null
+++ b/src/bindings/scripts/sql/WotLK/script_texts_wotlk.sql
@@ -0,0 +1,530 @@
+-- -1 574 000 UTGARDE KEEP
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Prince Keleseth
+ (-1574000, 'Your blood is mine!',13221,1,0,'keleseth SAY_AGGRO'),
+ (-1574001, 'Darkness waits',13223,1,0, 'keleseth SAY_KILL'),
+ (-1574002, 'I join... the night.',13225,1,0, 'keleseth SAY_DEATH'),
+ (-1574003, 'Not so fast.',13222,1,0, 'keleseth SAY_FROST_TOMB'),
+ (-1574004, 'Aranal, lidel! Their fate shall be yours!',13224,1,0, 'keleseth SAY_SKELETONS'),
+-- Dalronn the Controller
+ (-1574005, 'By all means, don\'t assess the situation, you halfwit! Just jump into the fray!',13199, 1,0,'dalronn SAY_AGGRO'),
+ (-1574006, 'You may serve me yet.',13202, 1,0,'dalronn SAY_KILL'),
+ (-1574007, 'See... you... soon.',13200, 1,0,'dalronn SAY_DEATH_1'),
+ (-1574008, 'There\'s no... greater... glory.',13201, 1,0,'dalronn SAY_DEATH_2'),
+ (-1574009, 'Skarvald, you incompetent slug! Return and make yourself useful!',13203,1,0, 'dalronn SAY_RAISES'),
+-- Skarvald the Constructor
+ (-1574010, 'Dalronn! See if you can muster the nerve to join my attack!',13229, 1,0,'skarvald SAY_AGGRO'),
+ (-1574011, '...',13232,1,0, 'skarvald SAY_KILL'),
+ (-1574012, 'Not... over... yet.',13230,1,0, 'skarvald SAY_DEATH_1'),
+ (-1574013, 'A warrior\'s death.',13231,1,0, 'skarvald SAY_DEATH_2'),
+ (-1574014, 'Pagh! What sort of necromancer lets death stop him? I knew you were worthless!',13233,1,0, 'skarvald SAY_RAISES'),
+-- Ingvar the Plunderer
+ (-1574015, 'I\'ll paint my face with your blood!',13207,1,0, 'ingvar SAY_AGGRO'),
+ (-1574016, 'I am a warrior born!',13214,1,0, 'ingvar SAY_KILL'),
+ (-1574017, 'My life for the... death god!',13213,1,0, 'ingvar SAY_DEATH'),
+ (-1574018, 'Fight on or face me!',13208,1,0, 'ingvar SAY_ATTACK_1'),
+ (-1574019, '...',13240, 1,0,'ingvar SAY_ATTACK_2'),
+ (-1574020, 'Slay them all, no excuses, no mercy, no rest!',13241,1,0, 'ingvar SAY_ATTACK_3'),
+ (-1574021, '... of destruction silence every ...!',13242,1,0, 'ingvar SAY_ATTACK_4'),
+ (-1574022, 'I return! A second chance to carve out your skull!',13208,1,0, 'ingvar SAY_PHASE2_AGGRO'),
+ (-1574023, 'Mjul orm agn gjor!',13212, 1,0,'ingvar SAY_PHASE2_KILL'),
+ (-1574024, 'No! I can do... better! I can...',13211,1,0, 'ingvar SAY_PHASE2_DEATH'),
+-- Said by Annhylde the Caller when resurecting Ingvar
+ (-1574025, 'Ingvar! Your pathetic failure will serve as a warning to all... you are damned! Arise and carry out the master\'s will!',13754, 1,0,'ingvar SAY_ANNHYLDE_THE_CALLER_RESURECTION');
+
+-- -1 575 000 UTGARDE PINNACLE
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Gortok Palehoof
+ (-1575000, 'What this place? I will destroy you!',13464,1,0, 'palehoof SAY_AGGRO'),
+ (-1575001, 'You die! That what master wants!',13465,1,0, 'palehoof SAY_SLAY_1'),
+ (-1575002, 'An easy task!',13466,1,0, 'palehoof SAY_SLAY_2'),
+ (-1575003, '...',13467,1,0, 'palehoof SAY_DEATH'),
+-- Skadi the Ruthless
+ (-1575004, 'What mongrels dare intrude here? Look alive, my brothers! A feast for the one that brings me their heads!',13497,1,0, 'skadi SAY_AGGRO'),
+ (-1575005, 'Mjor Na Ul Kaval!',13503,1,0, 'skadi SAY_KILL_1'),
+ (-1575006, 'Not so brash now, are you?',13504,1,0, 'skadi SAY_KILL_2'),
+ (-1575007, 'I\'ll mount your skull from the highest tower!',13505,1,0, 'skadi SAY_KILL_3'),
+ (-1575008, 'ARGH! You call that... an attack? I\'ll... show... aghhhh...',13506,1,0, 'skadi SAY_DEATH'),
+ (-1575009, 'You motherless knaves! Your corpses will make fine morsels for my new drake!',13507,1,0, 'skadi SAY_DRAKE_DEATH'),
+ (-1575010, 'I ask for ... to kill them, yet all I get is feeble whelps! By Ye.. SLAUGHTER THEM!',13501,1,0, 'skadi SAY_DRAKE_HIT_1'),
+ (-1575011, 'If one more harpoon touches my drake I\'ll flae my miserable heins.',13502,1,0, 'skadi SAY_DRAKE_HIT_2'),
+ (-1575012, 'Sear them to the bone!',13498,1,0, 'skadi SAY_DRAKE_BREATH_1'),
+ (-1575013, 'Go now! Leave nothing but ash in your wake!',13499,1,0, 'skadi SAY_DRAKE_BREATH_2'),
+ (-1575014, 'Cleanse our sacred halls with flame!',13500,1,0, 'skadi SAY_DRAKE_BREATH_3'),
+-- Svala Sorrowgrave
+ (-1575015, 'I will vanquish your soul!',13842,1,0, 'svala SAY_AGGRO'),
+ (-1575016, 'You were a fool to challenge the power of the Lich King!',13845, 1,0,'svala SAY_SLAY_1'),
+ (-1575017, 'Your will is done, my king.',13847,1,0, 'svala SAY_SLAY_2'),
+ (-1575018, 'Another soul for my master.',13848, 1,0,'svala SAY_SLAY_3'),
+ (-1575019, 'Nooo! I did not come this far... to...',13855,1,0, 'svala SAY_DEATH'),
+ (-1575020, 'Your death approaches.',13850,1,0, 'svala SAY_SACRIFICE_PLAYER_1'),
+ (-1575021, 'Go now to my master.',13851,1,0, 'svala SAY_SACRIFICE_PLAYER_2'),
+ (-1575022, 'Your end is inevitable.',13852,1,0, 'svala SAY_SACRIFICE_PLAYER_3'),
+ (-1575023, '...',13853,1,0, 'svala SAY_SACRIFICE_PLAYER_4'),
+ (-1575024, 'Any last words?',13854,1,0, 'svala SAY_SACRIFICE_PLAYER_5'),
+ (-1575025, 'My liege! I have done as you asked, and now beseech you for your blessing!',13856,1,0, 'svala SAY_SAY_DIALOG_WITH_ARTHAS_1'),
+ (-1575026, 'The sensation is... beyond my imagining. I am yours to command, my king.',13857,1,0, 'svala SAY_SAY_DIALOG_WITH_ARTHAS_2'),
+ (-1575027, 'I will be happy to slaughter them in your name! Come, enemies of the Scourge! I will show you the might of the Lich King!',13858,1,0, 'svala SAY_SAY_DIALOG_WITH_ARTHAS_3'),
+-- King Ymiron
+ (-1575028, 'You invade my home and then dare to challenge me? I will tear the hearts from your chests and offer them as gifts to the death god! Rualg nja gaborr!',13609, 1,0,'ymiron SAY_AGGRO'),
+ (-1575029, 'Your death is only the beginning!',13614,1,0, 'ymiron SAY_SLAY_1'),
+ (-1575030, 'You have failed your people!',13615, 1,0,'ymiron SAY_SLAY_2'),
+ (-1575031, 'There is a reason I am king!',13616, 1,0,'ymiron SAY_SLAY_3'),
+ (-1575032, 'Bleed no more!',13617, 1,0,'ymiron SAY_SLAY_4'),
+ (-1575033, 'What... awaits me... now?',13618,1,0, 'ymiron SAY_DEATH'),
+ (-1575034, 'Bjorn of the Black Storm! Honor me now with your presence!',13610,1,0, 'ymiron SAY_SUMMON_BJORN'),
+ (-1575035, 'Haldor of the rocky cliffs, grant me your strength!',13611, 1,0,'ymiron SAY_SUMMON_HALDOR'),
+ (-1575036, 'Ranulf of the screaming abyss, snuff these maggots with darkest night!',13612,1,0, 'ymiron SAY_SUMMON_RANULF'),
+ (-1575037, 'Tor of the Brutal Siege! Bestow your might upon me!',13613,1,0, 'ymiron SAY_SUMMON_TORGYN');
+
+-- -1 576 000 NEXUS
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Anomalus
+ (-1576000, 'Chaos beckons.',13186,1,0,'anomalus SAY_AGGRO'),
+ (-1576001, 'Expiration... is necessary...',13274,1,0,'anomalus SAY_KILL'),
+ (-1576002, 'Of course.',13187,1,0,'anomalus SAY_DEATH'),
+ (-1576003, 'Reality... unwoven.',13188,1,0,'anomalus SAY_RIFT'),
+ (-1576004, 'Indestructible.',13189,1,0,'anomalus SAY_SHIELD'),
+-- Keristrasza
+ (-1576005, 'Preserve? Why? There\'s no truth in it. No no no... only in the taking! I see that now!',13450,1,0,'keristrasza SAY_AGGRO'),
+ (-1576006, 'Now we\'ve come to the truth! ',13453,1,0,'keristrasza SAY_SLAY'),
+ (-1576007, 'Finish it! Finish it! Kill me, or I swear by the Dragonqueen you\'ll never see daylight again!',13452,1,0,'keristrasza SAY_ENRAGE'),
+ (-1576008, 'Dragonqueen... Life-Binder... preserve... me.',13454,1,0,'keristrasza SAY_DEATH'),
+ (-1576009, 'Stay. Enjoy your final moments.',13451,1,0,'keristrasza SAY_CRYSTAL_NOVA'),
+-- Grand Magus Telestra
+ (-1576010, 'You know what they say about curiosity.',13319,1,0,'magus_telestra SAY_AGGRO'),
+ (-1576011, 'Death becomes you!',13324,1,0,'magus_telestra SAY_KILL'),
+ (-1576012, 'Damn the... luck.',13320,1,0,'magus_telestra SAY_DEATH'),
+ (-1576013, 'Now to finish the job!',13323,1,0,'magus_telestra SAY_MERGE'),
+ (-1576014, 'There\'s plenty of me to go around.',13321,1,0,'magus_telestra SAY_SPLIT_1'),
+ (-1576015, 'I\'ll give you more than you can handle.',13322,1,0,'magus_telestra SAY_SPLIT_2'),
+-- Ormorok
+ (-1576016, 'Noo!',13328,1,0,'ormorok SAY_AGGRO'),
+ (-1576017, 'Aargh Kill!',13329,1,0,'ormorok SAY_KILL'),
+ (-1576018, 'Aaggh!',13330,1,0,'ormorok SAY_DEATH'),
+ (-1576019, 'Back!',13331,1,0,'ormorok SAY_REFLECT'),
+ (-1576020, 'Bleed!',13332,1,0,'ormorok SAY_ICE_SPIKES'),
+-- Commander Stoutbeard
+ (-1576021, 'What? Where in a..? Don\'t just stand around lads KILL SOMEBODY!',13193,1,0,'commander_stoutbeard SAY_AGGRO'),
+ (-1576022, 'Now we\re getting someplace!',13195,1,0,'commander_stoutbeard SAY_KILL'),
+ (-1576023, 'Is that all you\'ve... got?',13194,1,0,'commander_stoutbeard SAY_DEATH'),
+-- Commander Kolurg
+ (-1576024, 'What is this? Mag thorin Kar! Kill them!',13458,1,0,'commander_kolurg SAY_AGGRO'),
+ (-1576025, 'Our task is not yet done!',13459,1,0,'commander_kolurg SAY_KILL'),
+ (-1576026, 'GOOO!',13460,1,0,'commander_kolurg SAY_DEATH');
+
+-- -1 578 000 OCULUS
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Drakos the Interrogator
+ (-1578000, 'The prisoners shall not go free. The word of Malygos is law!',13594,1,0, 'drakos SAY_AGGRO'),
+ (-1578001, 'A fitting punishment!',13602, 1,0,'drakos SAY_KILL_1'),
+ (-1578002, 'Sentence: executed!',13603,1,0, 'drakos SAY_KILL_2'),
+ (-1578003, 'Another casualty of war!',13604, 1,0,'drakos SAY_KILL_3'),
+ (-1578004, 'The war... goes on.',13605,1,0, 'drakos SPELL_DEATH'),
+ (-1578005, 'It is too late to run!',13598, 1,0,'drakos SAY_PULL_1'),
+ (-1578006, 'Gather \'round! ',13599, 1,0,'drakos SAY_PULL_2'),
+ (-1578007, 'None shall escape!',13600, 1,0,'drakos SAY_PULL_3'),
+ (-1578008, 'I condemn you to death!',13601,1,0, 'drakos SAY_PULL_4'),
+ (-1578009, 'Tremble, worms!',13595,1,0, 'drakos SAY_STOMP_1'),
+ (-1578010, 'I will crush you!',13596, 1,0,'drakos SAY_STOMP_2'),
+ (-1578011, 'Can you fly?',13597, 1,0,'drakos SAY_STOMP_3'),
+-- Mage-Lord Urom
+ (-1578012, 'Poor blind fools!',13638,1,0, 'urom SAY_AGGRO'),
+ (-1578013, 'If only you understood!',13641,1,0, 'urom SAY_KILL_1'),
+ (-1578014, 'Now, do you see? DO YOU?!',13642,1,0, 'urom SAY_KILL_2'),
+ (-1578015, 'Unfortunate, but necessary.',13643,1,0, 'urom SAY_KILL_3'),
+ (-1578016, 'Everything I\'ve done... has been for Azeroth...',13644,1,0, 'urom SAY_DEATH'),
+ (-1578017, 'A taste... just a small taste... of the Spell-Weaver\'s power!',13639,1,0, 'urom SAY_EXPLOSION_1'),
+ (-1578018, 'So much unstable energy... but worth the risk to destroy you!',13640,1,0, 'urom SAY_EXPLOSION_2'),
+ (-1578019, 'What do we have here... those would defy the Spell-Weaver? Those without foresight or understanding. How could I make you see? Malygos is saving the world from itself! Bah! You are hardly worth my time!',13635,1,0, 'urom SAY_SUMMON_1'),
+ (-1578020, 'Clearly my pets failed. Perhaps another demonstration is in order.',13636,1,0, 'urom SAY_SUMMON_2'),
+ (-1578021, 'Still you fight. Still you cling to misguided principles. If you survive, you\'ll find me in the center ring.',13637,1,0, 'urom SAY_SUMMON_3'),
+-- Varos Cloudstrider
+ (-1578022, 'There will be no mercy!',13649,1,0, 'varos SAY_AGGRO'),
+ (-1578023, 'You were warned.',13653,1,0, 'varos SAY_KILL_1'),
+ (-1578024, 'The Oculus is ours.',13654,1,0, 'varos SAY_KILL_2'),
+ (-1578025, 'They are... too strong! Underestimated their... fortitude.',13655,1,0, 'varos SAY_DEATH'),
+ (-1578026, 'Blast them! Destroy them!',13650,1,0, 'varos SAY_STRIKE_1'),
+ (-1578027, 'Take no prisoners! Attack!',13651,1,0, 'varos SAY_STRIKE_2'),
+ (-1578028, 'Strike now! Obliterate them!',13652,1,0, 'varos SAY_STRIKE_3'),
+-- Varos says when Drakos dies
+ (-1578029, 'Intruders, your victory will be short-lived. I am Commander Varos Cloudstrider. My drakes control the skies and protest this conduit. I will see to it personally that the Oculus does not fall into your hands!',13648,1,0, 'varos SAY_SPAWN');
+
+-- -1 595 000 CULLING OF STRATHOLME
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Epoch
+ (-1595000, 'We\'ll see about that, young prince.',13409,1,0, 'epoch SAY_AGGRO'),
+ (-1595001, 'Tick tock, tick tock...',13410, 1,0,'epoch SAY_TIME_WARP_1'),
+ (-1595002, 'Not quick enough!',13411,1,0, 'epoch SAY_TIME_WARP_2'),
+ (-1595003, 'Let\'s get this over with. ',13412, 1,0,'epoch SAY_TIME_WARP_3'),
+ (-1595004, 'There is no future for you.',13413,1,0, 'epoch SAY_SLAY_1'),
+ (-1595005, 'This is the hour of our greatest triumph!',13414,1,0, 'epoch SAY_SLAY_2'),
+ (-1595006, 'You would destined to fail. ',13415,1,0, 'epoch SAY_SLAY_3'),
+ (-1595007, 'Prince Arthas Menethil, on this day, a powerful darkness has taken hold of your soul. The death you are destined to visit upon others will this day be your own.',13408,1,0, 'epoch SAY_INTRO'),
+ (-1595008, '*gurgles*',13416,1,0, 'epoch SAY_DEATH'),
+-- Mal'ganis
+ (-1595009, 'Yes...this is the beginning...I\'ve been waiting for you...young prince...I...am Mal\'Ganis..', 14410,1,0, 'mal_ganis SAY_INTRO_1'),
+ (-1595010, 'As you can see, your people...are now mine. I will now turn this city, household by household, until the flame of life has been snuffed out...forever...', 14411,1,0, 'mal_ganis SAY_INTRO_2'),
+ (-1595011, 'This will be a fine test...Prince Arthas...', 14413,1,0, 'mal_ganis SAY_AGGRO'),
+ (-1595012, 'All too easy...', 14416,1,0, 'mal_ganis SAY_KILL_1'),
+ (-1595013, 'The dark lord is displeased with your interference...', 14417, 1,0,'mal_ganis SAY_KILL_2'),
+ (-1595014, 'It is Prince Arthas I want...not you...', 14418,1,0, 'mal_ganis SAY_KILL_3'),
+ (-1595015, 'Anak\'Keri...', 14422, 1,0,'mal_ganis SAY_SLAY_1'),
+ (-1595016, 'My onslaught will wash over the Lich King\'s forces...', 14423,1,0, 'mal_ganis SAY_SLAY_2'),
+ (-1595017, 'Your death is in vain, tiny mortal...', 14424, 1,0,'mal_ganis SAY_SLAY_3'),
+ (-1595018, 'Your time has come to an end! ', 14425,1,0, 'mal_ganis SAY_SLAY_4'),
+ (-1595019, 'Time out...', 14414, 1,0,'mal_ganis SAY_SLEEP_1'),
+ (-1595020, 'You seem...tired... ', 14415,1,0, 'mal_ganis SAY_SLEEP_2'),
+ (-1595021, '*Struggling sounds* I spent too much time in that weak little shell... ', 14426,1,0, 'mal_ganis SAY_30HEALTH'),
+ (-1595022, '(Eredun) I AM MAL\'GANIS! I AM ETERNAL! ', 14427,1,0, 'mal_ganis SAY_15HEALTH'),
+ (-1595023, 'ENOUGH! I waste my time here...I must gather my strength on the home world...', 14428,1,0, 'mal_ganis SAY_ESCAPE_SPEECH_1'),
+ (-1595024, 'You\'ll never defeat the Lich King without my forces! I\'ll have my revenge...on him, AND you... ', 14429,1,0, 'mal_ganis SAY_ESCAPE_SPEECH_2'),
+ (-1595025, 'Your journey has just begun, young prince...Gather your forces, and meet me in the arctic land of Northrend...It is there we shall settle the score between us...It is there that your true destiny will unfold...', 14412,1,0, 'mal_ganis SAY_OUTRO'),
+-- Meathook
+ (-1595026, 'New toys!',13429,1,0, 'meathook SAY_AGGRO'),
+ (-1595027, 'Boring...',13430,1,0, 'meathook SAY_SLAY_1'),
+ (-1595028, 'Why you stop moving?',13431,1,0, 'meathook SAY_SLAY_2'),
+ (-1595029, 'Get up! Me not done! ',13432,1,0, 'meathook SAY_SLAY_3'),
+ (-1595030, 'Play time! ',13428,1,0, 'meathook SAY_SPAWN'),
+ (-1595031, 'This not fun...',13433,1,0, 'meathook SAY_DEATH'),
+-- Salramm the Fleshcrafter
+ (-1595032, 'Ah, the entertainment has arrived!',13472,1,0, 'salramm SAY_AGGRO'),
+ (-1595033, 'You are too late, champion of Lordaeron. The dead shall have their day. ',13471,1,0, 'salramm SAY_SPAWN'),
+ (-1595034, 'The fun is just beginning!',13473,1,0, 'salramm SAY_SLAY_1'),
+ (-1595035, 'Aah, quality materials!',13474, 1,0,'salramm SAY_SLAY_2'),
+ (-1595036, 'Don\'t worry, I\'ll make good use of you. ',137475, 1,0,'salramm SAY_SLAY_3'),
+ (-1595037, 'You only advance... the master\'s plan...',13483,1,0, 'salramm SAY_DEATH'),
+ (-1595038, 'BOOM! Hahahahah...',13478, 1,0,'salramm SAY_EXPLODE_GHOUL_1'),
+ (-1595039, 'Blood... destruction... EXHILARATING! ',13479,1,0, 'salramm SAY_EXPLODE_GHOUL_2'),
+ (-1595040, 'I want a sample...',13480,1,0, 'salramm SAY_STEAL_FLESH_1'),
+ (-1595041, 'Such strength... it must be mine!',13481,1,0, 'salramm SAY_STEAL_FLESH_2'),
+ (-1595042, 'Your flesh betrays you.',13482,1,0, 'salramm SAY_STEAL_FLESH_3'),
+ (-1595043, 'Say hello to some friends of mine.',13476,1,0, 'salramm SAY_SUMMON_GHOULS_1'),
+ (-1595044, 'Come, citizen of Stratholme! Meet your saviors.',13477,1,0, 'salramm SAY_SUMMON_GHOULS_2');
+
+-- -1 599 000 HALLS OF STONE
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Krystallus
+ (-1599000, 'Crush....', 14176, 1,0,'krystallus SAY_AGGRO'),
+ (-1599001, 'Ha...ha...ha...ha...', 14177,1,0, 'krystallus SAY_KILL'),
+ (-1599002, 'Uuuuhhhhhhhhhh......', 14179,1,0, 'krystallus SAY_DEATH'),
+ (-1599003, 'Break.... you....', 14178,1,0, 'krystallus SAY_SHATTER'),
+-- Maiden of Grief
+ (-1599004, 'You shouldn\'t have come...now you will die!',13487,1,0, 'maiden_of_grief SAY_AGGRO'),
+ (-1599005, 'Why must it be this way?',13488,1,0, 'maiden_of_grief SAY_SLAY_1'),
+ (-1599006, 'You had it coming!',13489, 1,0,'maiden_of_grief SAY_SLAY_2'),
+ (-1599007, 'My burden grows heavier.',13490,1,0, 'maiden_of_grief SAY_SLAY_3'),
+ (-1599008, 'This is your own fault!',13491,1,0, 'maiden_of_grief SAY_SLAY_4'),
+ (-1599009, 'I hope you all rot! I never...wanted...this.',13493, 1,0,'maiden_of_grief SAY_DEATH'),
+ (-1599010, 'So much lost time... that you\'ll never get back!',13492,1,0, 'maiden_of_grief SAY_STUN'),
+-- Sjonnir
+ (-1599011, 'Soft, vulnerable shells. Brief, fragile lives. You can not escape the curse of flesh!', 14180,1,0, 'sjonnir SAY_AGGRO'),
+ (-1599012, '...', 14181,1,0, 'sjonnir SAY_SLAY_1'),
+ (-1599013, 'Flesh is no match for iron!', 14182, 1,0,'sjonnir SAY_SLAY_2'),
+ (-1599014, 'Armies of iron will smother the world!', 14183, 1,0,'sjonnir SAY_SLAY_3'),
+ (-1599015, 'Loken will not rest, until the forge is retaken. You changed nothing!', 14184,1,0, 'sjonnir SAY_DEATH');
+
+-- -1 600 000 DRAK'THARON KEEP
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Novos the Summoner
+ (-1600000, 'The chill you feel is the herald of your doom.', 13173, 1,0, 'novos SAY_AGGRO'),
+ (-1600001, 'Such is the faith of all who oppose the Lich King!', 13175, 1,0, 'novos SAY_KILL'),
+ (-1600002, 'Your efforts... are in vain.', 13174, 1,0, 'novos SAY_DEATH'),
+ (-1600003, 'Surely you can see the futility of it all!', 13177, 1,0, 'novos SAY_REBUBLE_1'),
+ (-1600004, 'Just give up and die already!', 13178, 1,0, 'novos SAY_REBUBLE_2'),
+ (-1600005, 'Bolster my defenses! Hurry, curse you!', 13176, 1,0, 'novos SAY_NECRO_ADD'),
+-- Trollgore
+ (-1600006, 'Mogas moblath moghuld!', 13181, 1,0, 'trollgore SAY_AGGRO'),
+ (-1600007, '... I will eat you!', 13185, 1,0, 'trollgore SAY_KILL'),
+ (-1600008, '... .. so hungry, .. ... must\'t feed.', 13182, 1,0, 'trollgore SAY_CONSUME'),
+ (-1600009, '*laugh* Corpse go boom!', 13184, 1,0, 'trollgore SAY_EXPLODE'),
+ (-1600010, '...', 13183, 1,0, 'trollgore SAY_DEATH'),
+-- The Prophet Tharon'ja
+ (-1600011, 'Tharon\'ja sees all! The work of mortals shall not end the eternal dynasty!', 13862, 1, 0, 'tharon_ja SAY_AGGRO'),
+ (-1600012, 'As Tharon\'ja predicted.', 13863, 1, 0, 'tharon_ja SAY_KILL_1'),
+ (-1600013, 'As it was written.', 13863, 1, 0, 'tharon_ja SAY_KILL_2'),
+ (-1600014, 'Your flesh serves Tharon\'ja now!', 13865, 1, 0, 'tharon_ja SAY_FLESH_1'),
+ (-1600015, 'Tharon\'ja has a use for your mortal shell!', 13866, 1, 0, 'tharon_ja SAY_FLESH_2'),
+ (-1600016, 'No! A taste... all too brief!', 13868, 1, 0, 'tharon_ja SAY_SKELETON_1'),
+ (-1600017, 'Tharon\'ja will have more!', 13868, 1, 0, 'tharon_ja SAY_SKELETON_2'),
+ (-1600018, 'Im... impossible! Tharon\'ja is eternal! Tharon\'ja... is...', 13869, 1, 0, 'tharon_ja SAY_DEATH');
+
+-- -1 601 000 AZJOL-NERUB
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Anub'arak
+ (-1601000, 'Eternal agony awaits you!', 14054,1,0, 'anub_arak SAY_AGGRO'),
+ (-1601001, 'You shall experience my torment, first-hand!', 14055,1,0, 'anub_arak SAY_SLAY_1'),
+ (-1601002, 'You have made your choice.', 14056,1,0, 'anub_arak SAY_SLAY_2'),
+ (-1601003, 'Soon, the Master\'s voice will call to you.', 14057,1,0, 'anub_arak SAY_SLAY_3'),
+ (-1601004, 'Ahhh... RAAAAAGH! Never thought... I would be free of him...', 14069,1,0, 'anub_arak SAY_DEATH'),
+ (-1601005, 'Your armor is useless against my locusts!', 14060, 1,0,'anub_arak SAY_LOCUST_1'),
+ (-1601006, '?!!??!!!', 14067,1,0, 'anub_arak SAY_LOCUST_2'),
+ (-1601007, 'The pestilence upon you!', 14068,1,0, 'anub_arak SAY_LOCUST_3'),
+ (-1601008, '!!!???!!!', 14058,1,0, 'anub_arak SAY_SUBMERGE_1'),
+ (-1601009, 'Come forth, my brethren. Feast on their flesh!', 14059,1,0, 'anub_arak SAY_SUBMERGE_2'),
+ (-1601010, 'I was king of this empire once, long ago. In life I stood as champion. In death I returned as conqueror. Now I protect the kingdom once more. Ironic, yes?', 14053, 1,0,'anub_arak SAY_INTRO'),
+-- Krik'thir
+ (-1601011, 'This kingdom belongs to the Scourge! Only the dead may enter.', 14075,1,0, 'krik_thir SAY_AGGRO'),
+ (-1601012, 'Hash\'tak hi\'tak.', 14076,1,0, 'krik_thir SAY_SLAY_1'),
+ (-1601013, 'You were foolish to come.', 14077, 1,0,'krik_thir SAY_SLAY_2'),
+ (-1601014, 'As Anub\'Arak commands!', 14078,1,0, 'krik_thir SAY_SLAY_3'),
+ (-1601015, 'I should be grateful. But I long ago lost the capacity.', 14087,1,0, 'krik_thir SAY_DEATH'),
+ (-1601016, 'They hunger.', 14085,1,0, 'krik_thir SAY_SWARM_1'),
+ (-1601017, 'Dinner time, my pets.', 14086,1,0, 'krik_thir SAY_SWARM_2'),
+ (-1601018, 'We are besieged. Strike out and bring back their corpses!', 14079,1,0, 'krik_thir SAY_SEND_GROUP_1'),
+ (-1601019, 'We must hold the gate. Attack! Tear them limb from limb!', 14080,1,0, 'krik_thir SAY_SEND_GROUP_2'),
+ (-1601020, 'The gate must be protected at all costs. Rip them to shreds!', 14081,1,0, 'krik_thir SAY_SEND_GROUP_3'),
+ (-1601021, 'Keep an eye on the tunnel. We must not let anyone through!', 14082,1,0, 'krik_thir SAY_PREFIGHT_1'),
+ (-1601022, 'I hear footsteps. Be on your guard.', 14083,1,0, 'krik_thir SAY_PREFIGHT_2'),
+ (-1601023, 'I sense the living. Be ready.', 14084,1,0, 'krik_thir SAY_PREFIGHT_3');
+
+-- -1 602 000 HALLS OF LIGHTNING
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- General Bjarngrim
+ (-1602000, 'I am the greatest of my father\'s sons! Your end has come!', 14149,1,0,'bjarngrim SAY_AGGRO'),
+ (-1602001, 'So ends your curse!', 14153,1,0, 'bjarngrim SAY_SLAY_1'),
+ (-1602002, 'Flesh... is... weak!', 14154,1,0, 'bjarngrim SAY_SLAY_2'),
+ (-1602003, '...', 14155,1,0, 'bjarngrim SAY_SLAY_3'),
+ (-1602004, 'How can it be...? Flesh is not... stronger!', 14156,1,0, 'bjarngrim SAY_DEATH'),
+ (-1602005, 'Defend yourself, for all the good it will do!', 14151,1,0, 'bjarngrim SAY_BATTLE_STANCE'),
+ (-1602006, 'GRAAAAAH! Behold the fury of iron and steel!', 14152,1,0, 'bjarngrim SAY_BERSEKER_STANCE'),
+ (-1602007, 'Give me your worst!', 14150,1,0, 'bjarngrim SAY_DEFENSIVE_STANCE'),
+-- Ionar
+ (-1602008, 'You wish to confront the master? You must weather the storm!', 14453,1,0, 'ionar SAY_AGGRO'),
+ (-1602009, 'Shocking ... I know!', 14456,1,0, 'ionar SAY_SLAY_1'),
+ (-1602010, 'You atempt the unpossible.', 14457,1,0, 'ionar SAY_SLAY_2'),
+ (-1602011, 'Your spark of light is ... extinguish.', 14458,1,0, 'ionar SAY_SLAY_3'),
+ (-1602012, 'Master... you have guests.', 14459,1,0, 'ionar SAY_DEATH'),
+ (-1602013, 'The slightest spark shall be your undoing.', 14454,1,0, 'ionar SAY_SPLIT_1'),
+ (-1602014, 'No one is safe!', 14455,1,0, 'ionar SAY_SPLIT_2'),
+-- Loken
+ (-1602015, 'What hope is there for you? None!', 14162,1,0, 'loken SAY_AGGRO0'),
+ (-1602016, 'I have witnessed the rise and fall of empires. The birth and extinction of entire species. Over countless millennia the foolishness of mortals has remained beyond a constant. Your presence here confirms this.', 14160,1,0, 'loken SAY_INTRO_1'),
+ (-1602017, 'My master has shown me the future, and you have no place in it. Azeroth will be reborn in darkness. Yogg-Saron shall be released! The Pantheon shall fall!', 14162,1,0, 'loken SAY_INTRO_2'),
+ (-1602018, 'Only mortal...', 14166,1,0, 'loken SAY_SLAY_1'),
+ (-1602019, 'I... am... FOREVER!', 14167,1,0, 'loken SAY_SLAY_2'),
+ (-1602020, 'What little time you had, you wasted!', 14168,1,0, 'loken SAY_SLAY_3'),
+ (-1602021, 'My death... heralds the end of this world.', 14172,1,0, 'loken SAY_DEATH'),
+ (-1602022, 'You cannot hide from fate!', 14163,1,0, 'lokenSAY_NOVA_1'),
+ (-1602023, 'Come closer. I will make it quick.', 14164,1,0, 'loken SAY_NOVA_2'),
+ (-1602024, 'Your flesh cannot hold out for long.', 14165,1,0, 'loken SAY_NOVA_3'),
+ (-1602025, 'You stare blindly into the abyss!', 14169,1,0, 'loken SAY_75HEALTH'),
+ (-1602026, 'Your ignorance is profound. Can you not see where this path leads?', 14170,1,0, 'loken SAY_50HEALTH'),
+ (-1602027, 'You cross the precipice of oblivion!', 14171,1,0, 'loken SAY_25HEALTH'),
+-- Volkhan
+ (-1602028, 'It is you who have destroyed my children? You... shall... pay!',13960,1,0, 'volkhan SAY_AGGRO'),
+ (-1602029, 'The armies of iron will conquer all!',13965, 1,0,'volkhan SAY_SLAY_1'),
+ (-1602030, 'Ha, pathetic!',13966,1,0, 'volkhan SAY_SLAY_2'),
+ (-1602031, 'You have cost me too much work!',13967,1,0, 'volkhan SAY_SLAY_3'),
+ (-1602032, 'The master was right... to be concerned.',13968, 1,0,'volkhan SAY_DEATH'),
+ (-1602033, 'I will crush you beneath my boots!',13963, 1,0,'volkhan SAY_STOMP_1'),
+ (-1602034, 'All my work... undone!',13964, 1,0,'volkhan SAY_STOMP_2'),
+ (-1602035, 'Life from the lifelessness... death for you.',13961,1,0, 'volkhan SAY_FORGE_1'),
+ (-1602036, 'Nothing is wasted in the process. You will see....',13962, 1,0,'volkhan SAY_FORGE_2');
+
+-- -1 603 000 ULDUAR (RAID NIU)
+
+-- -1 604 000 GUNDRAK
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Gal'darah
+ (-1604000, 'I\'m gonna spil your guts, man!', 14430, 1,0,'gal_darah SAY_AGGRO'),
+ (-1604001, 'What a rush.', 14436,1,0, 'gal_darah SAY_SLAY_1'),
+ (-1604002, 'Who needs gods, when we ARE gods!', 14437, 1,0,'gal_darah SAY_SLAY_2'),
+ (-1604003, 'I told ya so ...', 14438,1,0, 'gal_darah SAY_SLAY_3'),
+ (-1604004, 'Even the mighty ... can .. fall.', 14439,1,0, 'gal_darah SAY_DEATH'),
+ (-1604005, 'God damn! Impale them!', 14433, 1,0,'gal_darah SAY_SUMMON_RHINO_1'),
+ (-1604006, 'Kill them ALL!', 14434, 1,0,'gal_darah SAY_SUMMON_RHINO_2'),
+ (-1604007, 'Say hello to my BIG friend.', 14435,1,0, 'gal_darah SAY_SUMMON_RHINO_3'),
+ (-1604008, 'Ain\'t gonna bee nothig left after this.', 14431,1,0, 'gal_darah SAY_TRANSFORM_1'),
+ (-1604009, 'You wanna see POWER? I\'m gonna show you POWER!', 14432,1,0, 'gal_darah SAY_TRANSFORM_2'),
+-- Moorabi
+ (-1604010, 'We fought back the Scourge. What chance you be thinking you got?', 14721,1,0, 'moorabi SAY_AGGRO'),
+ (-1604011, 'I crush you, cockroaches!', 14725,1,0, 'moorabi SAY_SLAY_1'),
+ (-1604012, 'Who gonna stop me, you?', 14726,1,0, 'moorabi SAY_SLAY_2'),
+ (-1604013, 'Not so tough now.', 14727,1,0, 'moorabi SAY_SLAY_3'),
+ (-1604014, 'If our gods can die, then so can we.', 14728,1,0, 'moorabi SAY_DEATH'),
+ (-1604015, 'Get ready for something much bigger!', 14722,1,0, 'moorabi SAY_TRANSFORM'),
+ (-1604016, 'The ground will swallow you up!', 14723,1,0, 'moorabi SAY_QUAKE'),
+-- Slad'ran
+ (-1604017, 'Drak\'thari gonna kill anybody who trespass on this lands.', 14443,1,0, 'slad_ran SAY_AGGRO'),
+ (-1604018, 'Can not breath then, good ...', 14446,1,0, 'slad_ran SAY_SLAY_1'),
+ (-1604019, 'You\'re scared now.', 14447,1,0, 'slad_ran SAY_SLAY_2'),
+ (-1604020, 'I eat you next man!', 14448,1,0, 'slad_ran SAY_SLAY_3'),
+ (-1604021, 'I ... see now. Scourge was not tha greatest enemy.', 14449,1,0, 'slad_ran SAY_DEATH'),
+ (-1604022, 'Minions of this ... heed my call.', 14444,1,0, 'slad_ran SAY_SUMMON_SNAKES'),
+ (-1604023, 'A thousand fangs gonna rim yar flesh.', 14445,1,0, 'slad_ran SAY_SUMMON_CONSTRICTORS');
+
+-- -1 608 000 VIOLET HOLD
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Cyanigosa
+ (-1608000, 'We finish this now, champions of Kirin Tor!', 13947, 1, 0, 'cyanigosa SAY_AGGRO'),
+ (-1608001, 'I will end the Kirin Tor!', 13952, 1, 0, 'cyanigosa SAY_SLAY_1'),
+ (-1608002, 'Dalaran will fall!', 13953, 1, 0, 'cyanigosa SAY_SLAY_2'),
+ (-1608003, 'So ends your defiance of the Spell-Weaver!', 13954, 1, 0, 'cyanigosa SAY_SLAY_3'),
+ (-1608004, 'Perhaps... we have... underestimated... you.', 13955, 1, 0, 'cyanigosa SAY_DEATH'),
+ (-1608005, 'A valiant defense, but this city must be razed. I will fulfill Malygos\'s wishes myself!', 13946, 1, 0, 'cyanigosa SAY_SPAWN'),
+ (-1608006, 'Am I interrupting?', 13951, 1, 0, 'cyanigosa SAY_DISRUPTION'),
+ (-1608007, 'Shiver and die!', 13948, 1, 0, 'cyanigosa SAY_BREATH_ATTACK'),
+ (-1608008, 'The world has forgotten what true magic is! Let this be a reminder!', 13949, 1, 0, 'cyanigosa SAY_SPECIAL_ATTACK_1'),
+ (-1608009, 'Who among you can withstand my power?', 13950, 1, 0, 'cyanigosa SAY_SPECIAL_ATTACK_2'),
+-- Erekem
+ (-1608010, 'Notcawwget in way ofrrak-rrakflee!', 14219, 1, 0, 'erekem SAY_AGGRO'),
+ (-1608011, '...', 14222, 1, 0, 'erekem SAY_SLAY_1'),
+ (-1608012, 'Precious life ... wasted.', 14223, 1, 0, 'erekem SAY_SLAY_2'),
+ (-1608013, 'Only strong ... survive.', 14224, 1, 0, 'erekem SAY_SLAY_3'),
+ (-1608014, 'Nokaw, kawflee...', 14225, 1, 0, 'erekem SAY_DEATH'),
+ (-1608015, 'Free tommfly onw. Ra-aak... Not find usekh-ekh! Escape!', 14218, 1, 0, 'erekem SAY_SPAWN'),
+ (-1608016, 'My-raaakfavorite! Awk awk awk! Raa-kaa!', 14220, 1, 0, 'erekem SAY_ADD_KILLED'),
+ (-1608017, 'Nasty little...A-ak, kaw! Kill! Yes, kill you!', 14221, 1, 0, 'erekem SAY_BOTH_ADDS_KILLED'),
+-- Ichoron
+ (-1608018, 'Stand aside, mortals!', 14230, 1, 0, 'ichoron SAY_AGGRO'),
+ (-1608019, 'I am a force of nature!', 14234, 1, 0, 'ichoron SAY_SLAY_1'),
+ (-1608020, 'I shall pass!', 14235, 1, 0, 'ichoron SAY_SLAY_2'),
+ (-1608021, 'You can not stop the tide!', 14236, 1, 0, 'ichoron SAY_SLAY_3'),
+ (-1608022, 'I... recede.', 14237, 1, 0, 'ichoron SAY_DEATH'),
+ (-1608023, 'I... am fury... unrestrained!', 14239, 1, 0, 'ichoron SAY_SPAWN'),
+ (-1608024, 'I shall consume, decimate, devastate, and destroy! Yield now to the wrath of the pounding sea!', 14231, 1, 0, 'ichoron SAY_ENRAGE'),
+ (-1608025, 'I will not be contained! Ngyah!!', 14233, 1, 0, 'ichoron SAY_SHATTER'),
+ (-1608026, 'Water can hold any form, take any shape... overcome any obstacle.', 14232, 1, 0, 'ichoron SAY_BUBBLE'),
+-- Xevozz
+ (-1608027, 'It seems my freedom must be bought with blood...', 14499, 1, 0, 'xevozz SAY_AGGRO'),
+ (-1608028, 'Nothing personal.', 14504, 1, 0, 'xevozz SAY_SLAY_1'),
+ (-1608029, 'Business concluded.', 14505, 1, 0, 'xevozz SAY_SLAY_2'),
+ (-1608030, 'Profit!', 14506, 1, 0, 'xevozz SAY_SLAY_3'),
+ (-1608031, 'This is an... unrecoverable... loss.', 14507, 1, 0, 'xevozz SAY_DEATH'),
+ (-1608032, 'Back in business! Now to execute an exit strategy.', 14498, 1, 0, 'xevozz SAY_SPAWNED'),
+ (-1608033, 'It would seem that a renegotiation is in order.', 14503, 1, 0, 'xevozz SAY_CHARGED'),
+ (-1608034, 'The air teems with latent energy... quite the harvest!', 14501, 1, 0, 'xevozz SAY_REPEAT_SUMMON_1'),
+ (-1608035, 'Plentiful, exploitable resources... primed for acquisition!', 14502, 1, 0, 'xevozz SAY_REPEAT_SUMMON_2'),
+ (-1608036, 'Intriguing... a high quantity of arcane energy is near. Time for some prospecting...', 14500, 1, 0, 'xevozz SAY_SUMMON_ENERGY'),
+-- Zuramat
+ (-1608037, 'Eradicate.', 13996, 1, 0, 'zuramat SAY_AGGRO'),
+ (-1608038, 'More... energy.', 13999, 1, 0, 'zuramat SAY_SLAY_1'),
+ (-1608039, 'Relinquish.', 14000, 1, 0, 'zuramat SAY_SLAY_2'),
+ (-1608040, 'Fall... to shadow.', 14001, 1, 0, 'zuramat SAY_SLAY_3'),
+ (-1608041, 'Disperse.', 14002, 1, 0, 'zuramat SAY_DEATH'),
+ (-1608042, 'I am... renewed.', 13995, 1, 0, 'zuramat SAY_SPAWN'),
+ (-1608043, 'Know... my... pain.', 13997, 1, 0, 'zuramat SAY_SHIELD'),
+ (-1608044, 'Gaze... into the void.', 13998, 1, 0, 'zuramat SAY_WHISPER');
+
+-- -1 615 000 OBSIDIAN SANCTUM
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Shadron
+ (-1615000, 'I fear nothing! Least of all you!', 14111,1,0, 'shadron SAY_SHADRON_AGGRO'),
+ (-1615001, 'You are insignificant!', 14112,1,0, 'shadron SAY_SHADRON_SLAY_1'),
+ (-1615002, 'Such mediocre resistance!', 14113,1,0, 'shadron SAY_SHADRON_SLAY_2'),
+ (-1615003, 'We...are superior! How could this...be...', 14118, 1,0,'shadron SAY_SHADRON_DEATH'),
+ (-1615004, 'You are easily bested! ', 14114,1,0, 'shadron SAY_SHADRON_BREATH'),
+ (-1615005, 'I will take pity on you Sartharion, just this once.', 14117, 1,0,'shadron SAY_SHADRON_RESPOND'),
+ (-1615006, 'Father tought me well!', 14115,1,0, 'shadron SAY_SHADRON_SPECIAL_1'),
+ (-1615007, 'On your knees!', 14116,1,0, 'shadron SAY_SHADRON_SPECIAL_2'),
+-- Tenebron
+ (-1615008, 'You have no place here. Your place is among the departed.', 14122,1,0, 'tenebron SAY_TENEBRON_AGGRO'),
+ (-1615009, 'No contest.', 14123,1,0, 'tenebron SAY_TENEBRON_SLAY_1'),
+ (-1615010, 'Typical... Just as I was having fun.', 14124,1,0, 'tenebron SAY_TENEBRON_SLAY_2'),
+ (-1615011, 'I should not... have held back...', 14129,1,0, 'tenebron SAY_TENEBRON_DEATH'),
+ (-1615012, 'To darkness I condemn you...', 14125,1,0, 'tenebron SAY_TENEBRON_BREATH'),
+ (-1615013, 'It is amusing to watch you struggle. Very well, witness how it is done.', 14128, 1,0,'tenebron SAY_TENEBRON_RESPOND'),
+ (-1615014, 'Arrogant little creatures! To challenge powers you do not yet understand...', 14126,1,0, 'tenebron SAY_TENEBRON_SPECIAL_1'),
+ (-1615015, 'I am no mere dragon! You will find I am much, much, more...', 14127, 1,0,'tenebron SAY_TENEBRON_SPECIAL_2'),
+-- Sartharion
+ (-1615016, 'It is my charge to watch over these eggs. I will see you burn before any harm comes to them!', 14093,1,0, 'sartharion SAY_SARTHARION_AGGRO'),
+ (-1615017, 'This pathetic siege ends NOW!', 14103,1,0, 'sartharion SAY_SARTHARION_BERSERK'),
+ (-1615018, 'Burn, you miserable wretches!', 14098, 1,0,'sartharion SAY_SARTHARION_BREATH'),
+ (-1615019, 'Shadron! Come to me, all is at risk!', 14105,1,0, 'sartharion SARTHARION_CALL_SHADRON'),
+ (-1615020, 'Tenebron! The eggs are yours to protect as well!', 14106,1,0, 'sartharion SAY_SARTHARION_CALL_TENEBRON'),
+ (-1615021, 'Vesperon! The clutch is in danger! Assist me!', 14104,1,0, 'sartharion SAY_SARTHARION_CALL_VESPERON'),
+ (-1615022, 'Such is the price... of failure...', 14107,1,0, 'sartharion SAY_SARTHARION_DEATH'),
+ (-1615023, 'Such flammable little insects....', 14099,1,0, 'sartharion SAY_SARTHARION_SPECIAL_1'),
+ (-1615024, 'Your charred bones will litter the floor!', 14100,1,0, 'sartharion SAY_SARTHARION_SPECIAL_2'),
+ (-1615025, 'How much heat can you take?', 14101,1,0, 'sartharion SAY_SARTHARION_SPECIAL_3'),
+ (-1615026, 'All will be reduced to ash!', 14102,1,0, 'sartharion SAY_SARTHARION_SPECIAL_4'),
+ (-1615027, 'You will make a fine meal for the hatchlings.', 14094,1,0, 'sartharion SAY_SARTHARION_SLAY_1'),
+ (-1615028, 'You are the grave disadvantage.', 14096,1,0, 'sartharion SAY_SARTHARION_SLAY_2'),
+ (-1615029, 'This is why we call you lesser beeings.', 14097,1,0, 'sartharion SAY_SARTHARION_SLAY_3'),
+-- Vesperon
+ (-1615030, 'You pose no threat, lesser beings...give me your worst!', 14133, 1,0,'vesperon SAY_VESPERON_AGGRO'),
+ (-1615031, 'The least you could do is put up a fight...', 14134,1,0, 'vesperon SAY_VESPERON_SLAY_1'),
+ (-1615032, 'Was that the best you can do?', 14135,1,0, 'vesperon SAY_VESPERON_SLAY_2'),
+ (-1615033, 'I still have some...fight..in...me...', 14140, 1,0,'vesperon SAY_VESPERON_DEATH'),
+ (-1615034, 'I will pick my teeth with your bones!', 14136,1,0, 'vesperon SAY_VESPERON_BREATH'),
+ (-1615035, 'Father was right about you, Sartharion...You are a weakling!', 14139,1,0, 'vesperon SAY_VESPERON_RESPOND'),
+ (-1615036, 'Aren\'t you tricky...I have a few tricks of my own...', 14137,1,0, 'vesperon SAY_VESPERON_SPECIAL_1'),
+ (-1615037, 'Unlike, I have many talents.', 14138,1,0, 'vesperon SAY_VESPERON_SPECIAL_2');
+
+-- -1 616 000 EYE OF ETERNITY
+INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Malygos
+ (-1616000, 'I will teach you IGNORANT children just how little you know of magic...', 14524,1,0, 'malygos SAY_ANTI_MAGIC_SHELL'),
+ (-1616001, 'YOU WILL NOT SUCCEED WHILE I DRAW BREATH!', 14518,1,0, 'malygos SAY_BREATH_ATTACK'),
+ (-1616002, 'I AM UNSTOPPABLE!', 14533,1,0, 'malygos SAY_HIGH_DAMAGE_MODE'),
+ (-1616003, 'Watch helplessly as your hopes are swept away...', 14525, 1,0,'malygos SAY_MAGIC_BLAST'),
+ (-1616004, 'Still standing? Not for long...', 14537, 1,0,'malygos SAY_GENERIC_SPELL_1'),
+ (-1616005, 'Your cause is lost!', 14538, 1,0,'malygos SAY_GENERIC_SPELL_2'),
+ (-1616006, 'Your fragile mind will be shattered! ', 14539,1,0, 'malygos SAY_GENERIC_SPELL_3'),
+ (-1616007, 'UNTHINKABLE! The mortals will destroy...e-everything...my sister...what have you-', 14540,1,0, 'malygos SAY_DEATH'),
+ (-1616008, 'Lesser beings, intruding here! A shame that your excess courage does not compensate for your stupidity!', 14512,1,0, 'malygos SAY_PREFIGHT_1'),
+ (-1616009, 'None but the blue dragonflight are welcome here! Perhaps this is the work of Alexstrasza? Well then, she has sent you to your deaths.', 14513,1,0, 'malygos SAY_PREFIGHT_2'),
+ (-1616010, 'What could you hope to accomplish, to storm brassily into my domain? To employ MAGIC? Against ME? *Laughs*', 14514,1,0, 'malygos SAY_PREFIGHT_3'),
+ (-1616011, 'I am without limits here...the rules of your cherished reality do not apply...In this realm, I am in control...', 14515, 1,0,'malygos SAY_PREFIGHT_4'),
+ (-1616012, 'I give you one chance. Pledge loyalty to me, and perhaps I won\'t slaughter you for your insolence!', 14516,1,0, 'malygos SAY_PREFIGHT_5'),
+ (-1616013, 'My patience has reached its limit, I WILL BE RID OF YOU!', 14517,1,0, 'malygos SAY_PHASE1_AGGRO'),
+ (-1616014, 'I had hoped to end your lives quickly, but you have proven more...resilient then I had anticipated. None the less, your efforts are in vain, it is you reckless, careless mortals who are to blame for this war! I do what I must...And if it means your...extinction...THEN SO BE IT!', 14522,1,0, 'malygos SAY_PHASE1_END'),
+ (-1616015, 'Your stupidity has finally caught up to you!', 14519,1,0, 'malygos SAY_PHASE1_SLAY_1'),
+ (-1616016, 'More artifacts to confiscate...', 14520, 1,0,'malygos SAY_PHASE1_SLAY_2'),
+ (-1616017, '*Laughs* How very...naive.. ', 14521,1,0, 'malygos SAY_PHASE1_SLAY_3'),
+ (-1616018, 'Few have experienced the pain I will now inflict on you!', 14523, 1,0,'malygos SAY_PHASE2_AGGRO'),
+ (-1616019, 'ENOUGH! If you intend to reclaim Azeroth\'s magic, then you shall have it... ', 14529,1,0, 'malygos SAY_PHASE2_END'),
+ (-1616020, 'Your energy will be put to good use!', 14526,1,0, 'malygos SAY_PHASE2_SLAY_1'),
+ (-1616021, 'I AM THE SPELL WEAVER! My power is INFINITE!', 14527, 1,0,'malygos SAY_PHASE2_SLAY_2'),
+ (-1616022, 'Your spirit will linger here forever!', 14528, 1,0,'malygos SAY_PHASE2_SLAY_3'),
+ (-1616023, 'Now your benefactors make their appearance...But they are too late. The powers contained here are powerful enough to destroy the world ten times over! What do you think they will do to you?', 14530,1,0, 'malygos SAY_PHASE3_INTRO'),
+ (-1616024, 'SUBMIT!', 14531,1,0, 'malygos SAY_PHASE3_AGGRO'),
+ (-1616025, 'Alexstrasza! Another of your brood falls!', 14534,1,0, 'malygos SAY_PHASE3_SLAY_1'),
+ (-1616026, 'Little more then gnats!', 14535, 1,0,'malygos SAY_PHASE3_SLAY_2'),
+ (-1616027, 'Your red allies will share your fate...', 14536, 1,0,'slad_ran SAY_PHASE3_SLAY_3'),
+ (-1616028, 'The powers at work here exceed anything you could possibly imagine!', 14532, 1,0,'malygos SAY_PHASE3_BIG_ATTACK');
+
+-- -1 619 000 AHN'KAHET
+ INSERT INTO `script_texts` (`entry`,`content_default`,`sound`,`type`,`language`,`comment`) VALUES
+-- Jedoga Shadowseeker
+ (-1619000, 'These are sacred halls, your intrusion will be met with death', 14343, 1, 0, 'jedoga SAY_AGGRO'),
+ (-1619001, 'Who among you is devoted', 14344, 1, 0, 'jedoga SAY_C_SACRIFICE_1'),
+ (-1619002, 'You there! Step foward', 14345, 1, 0, 'jedoga SAY_C_SACRIFICE_2'),
+ (-1619003, 'Yogg-Saron, grant me your power!', 14346, 1, 0, 'jedoga SAY_SACRIFICE_1'),
+ (-1619004, 'Master, a gift for you!', 14347, 1, 0, 'jedoga SAY_SACRIFICE_2'),
+ (-1619005, 'Glory to the Yogg-Saron!', 14348, 1, 0, 'jedoga SAY_SLAY_1'),
+ (-1619006, 'You are unworthy', 14349, 1, 0, 'jedoga SAY_SLAY_2'),
+ (-1619007, 'Get up! You haven\'t suffered enough', 14350, 1, 0, 'jedoga SAY_SLAY_3'),
+ (-1619008, 'Do not expect your sacrilege... to go unpunished.', 14351, 1, 0, 'jedoga SAY_DEATH'),
+ (-1619009, 'The elements themselves will rise up against the civilized world! Only the faithful will be spared!', 14352, 1, 0, 'jedoga SAY_PREACHING_1'),
+ (-1619010, 'Immortality can be yours. But only if you pledge yourself fully to Yogg-Saron!', 14353, 1, 0, 'jedoga SAY_PREACHING_2'),
+ (-1619011, 'Here on the very borders of his domain. You will expirience powers you would never have imagined!', 14354, 1, 0, 'jedoga SAY_PREACHING_3'),
+ (-1619012, 'You have traveled long and risked much to be here. Your devotion shall be rewarded.', 14355, 1, 0, 'jedoga SAY_PREACHING_4'),
+ (-1619013, 'The faithful shall be exalted! But there is more work to be done. We will press on until all of Azeroth lies beneath his shadow!', 14356, 1, 0, 'jedoga SAY_PREACHING_5'),
+-- Elder Nadox
+ (-1619014, 'The secrets of the deep shall remain hidden.', 14033, 1, 0, 'nadox SAY_AGGRO'),
+ (-1619015, 'Sleep now, in the cold dark.', 14036, 1, 0, 'nadox SAY_SLAY_1'),
+ (-1619016, 'For the Lich King!', 14307, 1, 0, 'nadox SAY_SLAY_2'),
+ (-1619017, 'Perhaps we will be allies soon.', 14038, 1, 0, 'nadox SAY_SLAY_3'),
+ (-1619018, 'Master, is my service complete?', 14039, 1, 0, 'nadox SAY_DEATH'),
+ (-1619019, 'The young must not grow hungry.', 14034, 1, 0, 'nadox SAY_EGG_SAC_1'),
+ (-1619020, 'Shad\'ak kerish\'akak', 14035, 1, 0, 'nadox SAY_EGG_SAC_2'),
+-- Prince Taldaram
+ (-1619021, 'I will feast on your remains.', 14360, 1, 0, 'taldaram SAY_AGGRO'),
+ (-1619022, '(Elfish)', 14365, 1, 0, 'taldaram SAY_SLAY_1'),
+ (-1619023, 'I will drink no blood before it is time.', 14366, 1, 0, 'taldaram SAY_SLAY_2'),
+ (-1619024, 'One final embrace.', 14367, 1, 0, 'taldaram SAY_SLAY_3'),
+ (-1619025, 'Still ... I hunger, still ... I thirst...', 14368, 1, 0, 'taldaram SAY_DEATH'),
+ (-1619026, 'Your heartbeat is music to my ears.', 14361, 1, 0, 'taldaram SAY_VANISH_1'),
+ (-1619027, 'I am nowhere. I am everywhere. I am the watcher, unseen.', 14362, 1, 0, 'taldaram SAY_VANISH_2'),
+ (-1619028, 'So appetizing.', 14363, 1, 0, 'taldaram SAY_FEED_1'),
+ (-1619029, 'Fresh, warm blood. It has been too long.', 14364, 1, 0, 'taldaram SAY_FEED_2'),
+-- Herald Volazj
+ (-1619030, '??? ??? ???', 14043, 1, 0, 'volazj SAY_AGGRO'),
+ (-1619031, 'Ywaq ma phgwa\\\'cul hnakf. - They are the whisper on the shivering wind.', 14045, 1, 0, 'volazj SAY_AGGRO'),
+ (-1619032, '?!? !?! ?!?', 14046, 1, 0, 'volazj SAY_AGGRO'),
+ (-1619033, '!?! !?! !?!', 14047, 1, 0, 'volazj SAY_AGGRO'),
+ (-1619034, 'Iilth vwah, uhn\'agth fhssh za. - Where one falls, many shall take its place.', 14048, 1, 0, 'volazj SAY_AGGRO'),
+ (-1619035, '... ...! ...?', 14049, 1, 0, 'volazj SAY_AGGRO'),
+ (-1619036, 'Phasing', 14044, 1, 0, 'volazj SAY_AGGRO');
diff --git a/src/bindings/scripts/sql/WotLK/wotlk_bosses.sql b/src/bindings/scripts/sql/WotLK/wotlk_bosses.sql
new file mode 100644
index 00000000000..f8d10a64cf3
--- /dev/null
+++ b/src/bindings/scripts/sql/WotLK/wotlk_bosses.sql
@@ -0,0 +1,124 @@
+/* */
+/* AZJOL-NERUB */
+/* */
+
+/* AHN'KAHET */
+UPDATE `instance_template` SET `script`='instance_ahn_kahet' WHERE `map`=4494;
+UPDATE `creature_template` SET `ScriptName`='boss_jedoga' WHERE `entry`='29310';
+UPDATE `creature_template` SET `ScriptName`='boss_nadox' WHERE `entry`='29309';
+UPDATE `creature_template` SET `ScriptName`='boss_taldaram' WHERE `entry`='29308';
+UPDATE `creature_template` SET `ScriptName`='boss_volazj' WHERE `entry`='29311';
+
+/* AZJOL-NERUB */
+UPDATE `instance_template` SET `script`='instance_azjol_nerub' WHERE `map`=3477;
+UPDATE `creature_template` SET `ScriptName`='boss_anub_arak' WHERE `entry`='29120';
+UPDATE `creature_template` SET `ScriptName`='boss_hardronox' WHERE `entry`='28921';
+UPDATE `creature_template` SET `ScriptName`='boss_krik_thir' WHERE `entry`='28684';
+
+/* THE CULLING OF STRATHOLME */
+UPDATE `instance_template` SET `script`='instance_culling_of_stratholme' WHERE `map`=4100;
+UPDATE `creature_template` SET `ScriptName`='boss_epoch' WHERE `entry`='26532';
+UPDATE `creature_template` SET `ScriptName`='boss_mal_ganis' WHERE `entry`='26533';
+UPDATE `creature_template` SET `ScriptName`='boss_meathook' WHERE `entry`='26529';
+UPDATE `creature_template` SET `ScriptName`='boss_salramm' WHERE `entry`='26530';
+
+/* DRAK'THARON KEEP */
+UPDATE `instance_template` SET `script`='instance_drak_tharon' WHERE `map`=4196;
+UPDATE `creature_template` SET `ScriptName`='boss_dred' WHERE `entry`='27483';
+UPDATE `creature_template` SET `ScriptName`='boss_novos' WHERE `entry`='26631';
+UPDATE `creature_template` SET `ScriptName`='boss_tharon_ja' WHERE `entry`='26632';
+UPDATE `creature_template` SET `ScriptName`='boss_trollgore' WHERE `entry`='26630';
+
+/* GUNDRAK */
+UPDATE `instance_template` SET `script`='instance_gundrak' WHERE `map` =4375;
+UPDATE `creature_template` SET `ScriptName`='boss_eck' WHERE `entry`='29932';
+UPDATE `creature_template` SET `ScriptName`='boss_drakkari_colossus' WHERE `entry`='29307';
+UPDATE `creature_template` SET `ScriptName`='boss_gal_darah' WHERE `entry`='29306';
+UPDATE `creature_template` SET `ScriptName`='boss_moorabi' WHERE `entry`='29305';
+UPDATE `creature_template` SET `ScriptName`='boss_slad_ran' WHERE `entry`='29304';
+
+/* */
+/* THE NEXUS */
+/* */
+
+/* EYE OF ETERNITY */
+UPDATE `instance_template` SET `script`='instance_eye_of_eternity' WHERE `map`=4500;
+UPDATE `creature_template` SET `ScriptName`='boss_malygos' WHERE `entry`='28859';
+
+/* NEXUS */
+UPDATE `instance_template` SET `script`='instance_nexus' WHERE `map`=4120;
+UPDATE `creature_template` SET `ScriptName`='boss_anomalus' WHERE `entry`='26763';
+UPDATE `creature_template` SET `ScriptName`='npc_chaotic_rift' WHERE `entry`='26918';
+UPDATE `creature_template` SET `ScriptName`='mob_crazed_mana_wraith' WHERE `entry`='26746';
+UPDATE `creature_template` SET `ScriptName`='boss_keristrasza' WHERE `entry`='26723';
+UPDATE `creature_template` SET `ScriptName`='boss_magus_telestra' WHERE `entry`='26731';
+UPDATE `creature_template` SET `ScriptName`='boss_ormorok' WHERE `entry`='26794';
+UPDATE `creature_template` SET `ScriptName`='boss_commander_stoutbeard' WHERE `entry`='26796';
+UPDATE `creature_template` SET `ScriptName`='boss_commander_kolurg' WHERE `entry`='26798';
+
+/* OCULUS */
+UPDATE `instance_template` SET `script`='instance_oculus' WHERE `map`=4228;
+UPDATE `creature_template` SET `ScriptName`='boss_drakos' WHERE `entry`='27654';
+UPDATE `creature_template` SET `ScriptName`='boss_eregos' WHERE `entry`='27656';
+UPDATE `creature_template` SET `ScriptName`='boss_urom' WHERE `entry`='27655';
+UPDATE `creature_template` SET `ScriptName`='boss_varos' WHERE `entry`='27447';
+
+/* OBSIDIAN SANCTUM */
+UPDATE `instance_template` SET `script`='instance_obsidian_sanctum' WHERE `map`=4493;
+UPDATE `creature_template` SET `ScriptName`='boss_sartharion' WHERE `entry`='28860';
+UPDATE `creature_template` SET `ScriptName`='mob_vesperon' WHERE `entry`='30449';
+UPDATE `creature_template` SET `ScriptName`='mob_shadron' WHERE `entry`='30451';
+UPDATE `creature_template` SET `ScriptName`='mob_tenebron' WHERE `entry`='30452';
+UPDATE `creature_template` SET `ScriptName`='mob_whelp' WHERE `entry`='30890';
+UPDATE `creature_template` SET `ScriptName`='mob_whelp' WHERE `entry`='31214';
+
+/* */
+/* ULDUAR */
+/* */
+
+/* HALLS OF LIGHTNING */
+UPDATE `instance_template` SET `script`='instance_halls_of_lightning' WHERE `map`=4272;
+UPDATE `creature_template` SET `ScriptName`='boss_bjarngrim' WHERE `entry`='28586';
+UPDATE `creature_template` SET `ScriptName`='boss_ionar' WHERE `entry`='28546';
+UPDATE `creature_template` SET `ScriptName`='spark_of_ionar' WHERE `entry`='28962';
+UPDATE `creature_template` SET `ScriptName`='boss_volkhan' WHERE `entry`='28587';
+UPDATE `creature_template` SET `ScriptName`='mob_molten_golem' WHERE `entry`='28695';
+UPDATE `creature_template` SET `ScriptName`='boss_loken' WHERE `entry`='28923';
+/* HALLS OF STONE */
+UPDATE `instance_template` SET `script`='instance_halls_of_stone' WHERE `map`=4264;
+UPDATE `creature_template` SET `ScriptName`='boss_krystallus' WHERE `entry`='27977';
+UPDATE `creature_template` SET `ScriptName`='boss_maiden_of_grief' WHERE `entry`='27975';
+UPDATE `creature_template` SET `ScriptName`='boss_sjonnir' WHERE `entry`='27978';
+
+/* */
+/* UTGARDE KEEP */
+/* */
+
+/* UTGARDE KEEP */
+UPDATE `instance_template` SET `script`='instance_keep' WHERE `map`=206;
+UPDATE `creature_template` SET `ScriptName`='boss_dalronn' WHERE `entry`='24201';
+UPDATE `creature_template` SET `ScriptName`='boss_ingvar' WHERE `entry`='23954';
+UPDATE `creature_template` SET `ScriptName`='boss_keleseth' WHERE `entry`='23953';
+UPDATE `creature_template` SET `ScriptName`='boss_skarvald' WHERE `entry`='24200';
+
+/* UTGARDE PINNACLE */
+UPDATE `instance_template` SET `script`='instance_pinnacle' WHERE `map`=1196;
+UPDATE `creature_template` SET `ScriptName`='boss_palehoof' WHERE `entry`='26687';
+UPDATE `creature_template` SET `ScriptName`='boss_skadi' WHERE `entry`='26693';
+UPDATE `creature_template` SET `ScriptName`='boss_svala' WHERE `entry`='26668';
+UPDATE `creature_template` SET `ScriptName`='boss_ymiron' WHERE `entry`='26861';
+
+/* VAULT OF ARCHAVON */
+UPDATE `instance_template` SET `script`='instance_archavon' WHERE `map`=4603;
+UPDATE `creature_template` SET `ScriptName`='boss_archavon' WHERE `entry`='31125';
+UPDATE `creature_template` SET `ScriptName`='mob_archavon_warder' WHERE `entry`='32353';
+
+/* VIOLET HOLD */
+UPDATE `instance_template` SET `script`='instance_violet_hold' WHERE `map`=4415;
+UPDATE `creature_template` SET `ScriptName`='boss_cyanigosa' WHERE `entry`='31134';
+UPDATE `creature_template` SET `ScriptName`='boss_erekem' WHERE `entry`='29315';
+UPDATE `creature_template` SET `ScriptName`='boss_ichoron' WHERE `entry`='29313';
+UPDATE `creature_template` SET `ScriptName`='boss_lavanthor' WHERE `entry`='29312';
+UPDATE `creature_template` SET `ScriptName`='boss_moragg' WHERE `entry`='29316';
+UPDATE `creature_template` SET `ScriptName`='boss_xevozz' WHERE `entry`='29266';
+UPDATE `creature_template` SET `ScriptName`='boss_zuramat' WHERE `entry`='29314';
diff --git a/src/bindings/scripts/system.cpp b/src/bindings/scripts/system.cpp
index 893e476e2fd..ab62e530681 100644
--- a/src/bindings/scripts/system.cpp
+++ b/src/bindings/scripts/system.cpp
@@ -1,7 +1,7 @@
/*
- * Copyright (C) 2008 Trinity <http://www.trinitycore.org/>
+ * Copyright (C) 2008-2009 Trinity <http://www.trinitycore.org/>
*
- * Thanks to the original authors: MaNGOS <http://www.mangosproject.org/>
+ * Thanks to the original authors: MaNGOS <http://getmangos.com/>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by