diff options
1481 files changed, 14682 insertions, 4681 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 816eb4e9b98..5eeb5911ca9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/PreLoad.cmake b/PreLoad.cmake index f7cf5a1ebe6..5914118186a 100644 --- a/PreLoad.cmake +++ b/PreLoad.cmake @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/cmake/genrev.cmake b/cmake/genrev.cmake index db722f9fdb8..5c013756f09 100644 --- a/cmake/genrev.cmake +++ b/cmake/genrev.cmake @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/cmake/macros/CheckBuildDir.cmake b/cmake/macros/CheckBuildDir.cmake index 9a89de0b29d..468253d6bda 100644 --- a/cmake/macros/CheckBuildDir.cmake +++ b/cmake/macros/CheckBuildDir.cmake @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/cmake/macros/FindGit.cmake b/cmake/macros/FindGit.cmake index f5b0c6a9a3b..3577428f43c 100644 --- a/cmake/macros/FindGit.cmake +++ b/cmake/macros/FindGit.cmake @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/cmake/macros/GroupSources.cmake b/cmake/macros/GroupSources.cmake index 3acb03e7b4c..198d8c3e187 100644 --- a/cmake/macros/GroupSources.cmake +++ b/cmake/macros/GroupSources.cmake @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/cmake/options.cmake b/cmake/options.cmake index 486cc909605..19615001307 100644 --- a/cmake/options.cmake +++ b/cmake/options.cmake @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/cmake/showoptions.cmake b/cmake/showoptions.cmake index 3136730a6b4..110b2f01a64 100644 --- a/cmake/showoptions.cmake +++ b/cmake/showoptions.cmake @@ -56,6 +56,13 @@ else() endif() if( WITH_COREDEBUG ) + message("") + message(" *** WITH_COREDEBUG - WARNING!") + message(" *** additional core debug logs have been enabled!") + message(" *** this setting doesn't help to get better crash logs!") + message(" *** in case you are searching for better crash logs use") + message(" *** -DCMAKE_BUILD_TYPE=RelWithDebug") + message(" *** DO NOT ENABLE IT UNLESS YOU KNOW WHAT YOU'RE DOING!") message("* Use coreside debug : Yes") add_definitions(-DTRINITY_DEBUG) else() diff --git a/contrib/conf_merge/tc-conf-merger.pl b/contrib/conf_merge/tc-conf-merger.pl index 074689979af..23c8385f0c8 100644 --- a/contrib/conf_merge/tc-conf-merger.pl +++ b/contrib/conf_merge/tc-conf-merger.pl @@ -1,6 +1,6 @@ #!/usr/bin/perl -w -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # Author: leak # Date: 2010-12-06 # Note: Based on conf file format of rev 10507 diff --git a/dep/CMakeLists.txt b/dep/CMakeLists.txt index f829956b7bf..7f4f1cd884c 100644 --- a/dep/CMakeLists.txt +++ b/dep/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/dep/bzip2/CMakeLists.txt b/dep/bzip2/CMakeLists.txt index 37f44be7686..d3aadbe002e 100644 --- a/dep/bzip2/CMakeLists.txt +++ b/dep/bzip2/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/dep/g3dlite/CMakeLists.txt b/dep/g3dlite/CMakeLists.txt index 67564ee699a..f1166c72e6d 100644 --- a/dep/g3dlite/CMakeLists.txt +++ b/dep/g3dlite/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/dep/gsoap/CMakeLists.txt b/dep/gsoap/CMakeLists.txt index e339ccb00ea..b5fed7809af 100644 --- a/dep/gsoap/CMakeLists.txt +++ b/dep/gsoap/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/dep/jemalloc/CMakeLists.txt b/dep/jemalloc/CMakeLists.txt index 8f0692fc82c..cf0ac435f0a 100644 --- a/dep/jemalloc/CMakeLists.txt +++ b/dep/jemalloc/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/dep/libmpq/CMakeLists.txt b/dep/libmpq/CMakeLists.txt index e993d669d0c..1213e6b11b7 100644 --- a/dep/libmpq/CMakeLists.txt +++ b/dep/libmpq/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/dep/recastnavigation/Detour/CMakeLists.txt b/dep/recastnavigation/Detour/CMakeLists.txt index 9aebeacd892..b21e4ca6273 100644 --- a/dep/recastnavigation/Detour/CMakeLists.txt +++ b/dep/recastnavigation/Detour/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/dep/recastnavigation/Recast/CMakeLists.txt b/dep/recastnavigation/Recast/CMakeLists.txt index ab6772aa031..738c010eb05 100644 --- a/dep/recastnavigation/Recast/CMakeLists.txt +++ b/dep/recastnavigation/Recast/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/dep/zlib/CMakeLists.txt b/dep/zlib/CMakeLists.txt index d91b2c202b7..7feb134bcd5 100644 --- a/dep/zlib/CMakeLists.txt +++ b/dep/zlib/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/doc/UnixInstall.txt b/doc/UnixInstall.txt index a97fdd2bd31..c11cc2b074c 100644 --- a/doc/UnixInstall.txt +++ b/doc/UnixInstall.txt @@ -1,5 +1,5 @@ = TrinityCore -- Linux installation = -Copyright (C) 2008-2015 TrinityCore (http://www.trinitycore.org/) +Copyright (C) 2008-2016 TrinityCore (http://www.trinitycore.org/) ========================================================= WARNING: THIS DOCUMENTATION IS NOT ALWAYS UP TO DATE. diff --git a/issue_template.md b/issue_template.md new file mode 100644 index 00000000000..87f2e21af41 --- /dev/null +++ b/issue_template.md @@ -0,0 +1,23 @@ +**Description**: + +**Current behaviour**: Tell us what happens + +**Expected behaviour**: Tell us what should happen instead + +**Steps to reproduce the problem**: + +1. +2. +3. + +**Branch(es)**: 335/6x + +**TC hash/commit**: + +**TDB version**: + +**Operating system**: + + +[//]: # (This template is for problem reports, for other type of reports edit it accordingly) +[//]: # (If this is a crash report, include the crashlog with https://gist.github.com/) diff --git a/pull_request_template.md b/pull_request_template.md new file mode 100644 index 00000000000..7438ed561cf --- /dev/null +++ b/pull_request_template.md @@ -0,0 +1,13 @@ +**Changes proposed**: + +- +- +- + +**Target branch(es)**: 335/6x + +**Issues addressed**: Fixes # + +**Tests performed**: (Does it build? Tested in-game?) + +**Known issues and TODO list**: diff --git a/revision_data.h.in.cmake b/revision_data.h.in.cmake index f21c3d26bda..64c754c700b 100644 --- a/revision_data.h.in.cmake +++ b/revision_data.h.in.cmake @@ -7,7 +7,7 @@ #define _MYSQL_EXECUTABLE "@MYSQL_EXECUTABLE@" #define _FULL_DATABASE "TDB_full_world_335.60_2015_11_07.sql" #define VER_COMPANYNAME_STR "TrinityCore Developers" - #define VER_LEGALCOPYRIGHT_STR "(c)2008-2015 TrinityCore" + #define VER_LEGALCOPYRIGHT_STR "(c)2008-2016 TrinityCore" #define VER_FILEVERSION 0,0,0 #define VER_FILEVERSION_STR "@rev_hash@ @rev_date@ (@rev_branch@ branch)" #define VER_PRODUCTVERSION VER_FILEVERSION diff --git a/sql/base/auth_database.sql b/sql/base/auth_database.sql index b11f5002bc7..0ac0ffaf9d1 100644 --- a/sql/base/auth_database.sql +++ b/sql/base/auth_database.sql @@ -375,7 +375,7 @@ CREATE TABLE `rbac_linked_permissions` ( LOCK TABLES `rbac_linked_permissions` WRITE; /*!40000 ALTER TABLE `rbac_linked_permissions` DISABLE KEYS */; -INSERT INTO `rbac_linked_permissions` VALUES (192,21),(192,42),(192,43),(192,193),(192,196),(192,778),(192,779),(192,780),(192,781),(192,782),(192,783),(192,784),(192,785),(192,786),(192,787),(192,788),(192,789),(192,790),(192,791),(192,792),(192,793),(192,794),(192,795),(192,796),(192,835),(193,48),(193,194),(193,197),(194,1),(194,2),(194,11),(194,13),(194,14),(194,15),(194,16),(194,17),(194,18),(194,19),(194,20),(194,22),(194,23),(194,25),(194,26),(194,27),(194,28),(194,29),(194,30),(194,31),(194,32),(194,33),(194,34),(194,35),(194,36),(194,37),(194,38),(194,39),(194,40),(194,41),(194,44),(194,46),(194,47),(194,51),(194,195),(194,198),(194,632),(194,798),(195,3),(195,4),(195,5),(195,6),(195,24),(195,49),(195,199),(196,200),(196,201),(196,226),(196,227),(196,230),(196,231),(196,233),(196,234),(196,235),(196,238),(196,239),(196,240),(196,241),(196,242),(196,243),(196,244),(196,245),(196,246),(196,247),(196,248),(196,249),(196,250),(196,251),(196,252),(196,253),(196,254),(196,255),(196,256),(196,257),(196,258),(196,259),(196,260),(196,261),(196,262),(196,264),(196,265),(196,266),(196,267),(196,268),(196,269),(196,270),(196,271),(196,272),(196,279),(196,280),(196,283),(196,287),(196,288),(196,289),(196,290),(196,291),(196,292),(196,293),(196,294),(196,295),(196,296),(196,297),(196,298),(196,299),(196,302),(196,303),(196,304),(196,305),(196,306),(196,307),(196,308),(196,309),(196,310),(196,313),(196,314),(196,319),(196,320),(196,321),(196,322),(196,323),(196,324),(196,325),(196,326),(196,327),(196,328),(196,329),(196,330),(196,331),(196,332),(196,333),(196,334),(196,335),(196,336),(196,337),(196,338),(196,339),(196,340),(196,341),(196,342),(196,343),(196,344),(196,345),(196,346),(196,347),(196,348),(196,349),(196,350),(196,351),(196,352),(196,353),(196,354),(196,355),(196,356),(196,357),(196,358),(196,359),(196,360),(196,361),(196,362),(196,363),(196,364),(196,365),(196,366),(196,373),(196,375),(196,400),(196,401),(196,402),(196,403),(196,404),(196,405),(196,406),(196,407),(196,417),(196,418),(196,419),(196,420),(196,421),(196,422),(196,423),(196,424),(196,425),(196,426),(196,427),(196,428),(196,429),(196,434),(196,435),(196,436),(196,437),(196,438),(196,439),(196,440),(196,441),(196,442),(196,443),(196,444),(196,445),(196,446),(196,447),(196,448),(196,449),(196,450),(196,451),(196,452),(196,453),(196,454),(196,455),(196,456),(196,457),(196,458),(196,459),(196,461),(196,463),(196,464),(196,465),(196,472),(196,473),(196,474),(196,475),(196,476),(196,477),(196,478),(196,488),(196,489),(196,491),(196,492),(196,493),(196,495),(196,497),(196,498),(196,499),(196,500),(196,502),(196,503),(196,505),(196,508),(196,511),(196,513),(196,514),(196,516),(196,519),(196,522),(196,523),(196,526),(196,527),(196,529),(196,530),(196,533),(196,535),(196,536),(196,537),(196,538),(196,539),(196,540),(196,541),(196,556),(196,581),(196,582),(196,592),(196,593),(196,596),(196,602),(196,603),(196,604),(196,605),(196,606),(196,607),(196,608),(196,609),(196,610),(196,611),(196,612),(196,613),(196,614),(196,615),(196,616),(196,617),(196,618),(196,619),(196,620),(196,621),(196,622),(196,623),(196,624),(196,625),(196,626),(196,627),(196,628),(196,629),(196,630),(196,631),(196,633),(196,634),(196,635),(196,636),(196,637),(196,638),(196,639),(196,640),(196,641),(196,642),(196,643),(196,644),(196,645),(196,646),(196,647),(196,648),(196,649),(196,650),(196,651),(196,652),(196,653),(196,654),(196,655),(196,656),(196,657),(196,658),(196,659),(196,660),(196,661),(196,662),(196,663),(196,664),(196,665),(196,666),(196,667),(196,668),(196,669),(196,670),(196,671),(196,672),(196,673),(196,674),(196,675),(196,676),(196,677),(196,678),(196,679),(196,680),(196,681),(196,682),(196,683),(196,684),(196,685),(196,686),(196,687),(196,688),(196,689),(196,690),(196,691),(196,692),(196,693),(196,694),(196,695),(196,696),(196,697),(196,698),(196,699),(196,700),(196,701),(196,702),(196,703),(196,704),(196,705),(196,706),(196,707),(196,708),(196,709),(196,710),(196,711),(196,712),(196,713),(196,714),(196,715),(196,716),(196,717),(196,718),(196,719),(196,721),(196,722),(196,723),(196,724),(196,725),(196,726),(196,727),(196,728),(196,729),(196,730),(196,733),(196,734),(196,735),(196,736),(196,738),(196,739),(196,748),(196,753),(196,757),(196,773),(196,777),(197,232),(197,236),(197,237),(197,273),(197,274),(197,275),(197,276),(197,277),(197,284),(197,285),(197,286),(197,301),(197,311),(197,387),(197,388),(197,389),(197,390),(197,391),(197,392),(197,393),(197,394),(197,395),(197,396),(197,397),(197,398),(197,399),(197,479),(197,480),(197,481),(197,482),(197,485),(197,486),(197,487),(197,494),(197,506),(197,509),(197,510),(197,517),(197,518),(197,521),(197,542),(197,543),(197,550),(197,558),(197,568),(197,571),(197,572),(197,573),(197,574),(197,575),(197,576),(197,577),(197,578),(197,579),(197,580),(197,583),(197,584),(197,585),(197,586),(197,587),(197,588),(197,589),(197,590),(197,591),(197,594),(197,595),(197,601),(197,743),(197,750),(197,758),(197,761),(197,762),(197,763),(197,764),(197,765),(197,766),(197,767),(197,768),(197,769),(197,770),(197,771),(197,772),(197,774),(198,218),(198,300),(198,312),(198,315),(198,316),(198,317),(198,318),(198,367),(198,368),(198,369),(198,370),(198,371),(198,372),(198,374),(198,376),(198,377),(198,378),(198,379),(198,380),(198,381),(198,382),(198,383),(198,384),(198,385),(198,386),(198,408),(198,409),(198,410),(198,411),(198,412),(198,413),(198,414),(198,415),(198,416),(198,430),(198,431),(198,432),(198,433),(198,462),(198,466),(198,467),(198,468),(198,469),(198,470),(198,471),(198,483),(198,484),(198,490),(198,504),(198,512),(198,515),(198,520),(198,524),(198,528),(198,531),(198,532),(198,544),(198,545),(198,546),(198,547),(198,548),(198,549),(198,551),(198,552),(198,553),(198,554),(198,555),(198,557),(198,559),(198,560),(198,561),(198,562),(198,563),(198,564),(198,565),(198,566),(198,567),(198,569),(198,570),(198,597),(198,598),(198,599),(198,600),(198,737),(198,740),(198,741),(198,742),(198,744),(198,745),(198,746),(198,747),(198,749),(198,751),(198,752),(198,754),(198,755),(198,756),(198,759),(198,760),(199,217),(199,221),(199,222),(199,223),(199,225),(199,263),(199,496),(199,501),(199,507),(199,525),(199,534),(199,797); +INSERT INTO `rbac_linked_permissions` VALUES (192,21),(192,42),(192,43),(192,193),(192,196),(192,778),(192,779),(192,780),(192,781),(192,782),(192,783),(192,784),(192,785),(192,786),(192,787),(192,788),(192,789),(192,790),(192,791),(192,792),(192,793),(192,794),(192,795),(192,796),(192,835),(193,48),(193,194),(193,197),(194,1),(194,2),(194,11),(194,13),(194,14),(194,15),(194,16),(194,17),(194,18),(194,19),(194,20),(194,22),(194,23),(194,25),(194,26),(194,27),(194,28),(194,29),(194,30),(194,31),(194,32),(194,33),(194,34),(194,35),(194,36),(194,37),(194,38),(194,39),(194,40),(194,41),(194,44),(194,46),(194,47),(194,51),(194,195),(194,198),(194,632),(194,798),(195,3),(195,4),(195,5),(195,6),(195,24),(195,49),(195,199),(196,200),(196,201),(196,226),(196,227),(196,230),(196,231),(196,233),(196,234),(196,235),(196,238),(196,239),(196,240),(196,241),(196,242),(196,243),(196,244),(196,245),(196,246),(196,247),(196,248),(196,249),(196,250),(196,251),(196,252),(196,253),(196,254),(196,255),(196,256),(196,257),(196,258),(196,259),(196,260),(196,261),(196,262),(196,264),(196,265),(196,266),(196,267),(196,268),(196,269),(196,270),(196,271),(196,272),(196,279),(196,280),(196,283),(196,287),(196,288),(196,289),(196,290),(196,291),(196,292),(196,293),(196,294),(196,295),(196,296),(196,297),(196,298),(196,299),(196,302),(196,303),(196,304),(196,305),(196,306),(196,307),(196,308),(196,309),(196,310),(196,313),(196,314),(196,319),(196,320),(196,321),(196,322),(196,323),(196,324),(196,325),(196,326),(196,327),(196,328),(196,329),(196,330),(196,331),(196,332),(196,333),(196,334),(196,335),(196,336),(196,337),(196,338),(196,339),(196,340),(196,341),(196,342),(196,343),(196,344),(196,345),(196,346),(196,347),(196,348),(196,349),(196,350),(196,351),(196,352),(196,353),(196,354),(196,355),(196,356),(196,357),(196,358),(196,359),(196,360),(196,361),(196,362),(196,363),(196,364),(196,365),(196,366),(196,373),(196,375),(196,400),(196,401),(196,402),(196,403),(196,404),(196,405),(196,406),(196,407),(196,417),(196,418),(196,419),(196,420),(196,421),(196,422),(196,423),(196,424),(196,425),(196,426),(196,427),(196,428),(196,429),(196,434),(196,435),(196,436),(196,437),(196,438),(196,439),(196,440),(196,441),(196,442),(196,443),(196,444),(196,445),(196,446),(196,447),(196,448),(196,449),(196,450),(196,451),(196,452),(196,453),(196,454),(196,455),(196,456),(196,457),(196,458),(196,459),(196,461),(196,463),(196,464),(196,465),(196,472),(196,473),(196,474),(196,475),(196,476),(196,477),(196,478),(196,488),(196,489),(196,491),(196,492),(196,493),(196,495),(196,497),(196,498),(196,499),(196,500),(196,502),(196,503),(196,505),(196,508),(196,511),(196,513),(196,514),(196,516),(196,519),(196,522),(196,523),(196,526),(196,527),(196,529),(196,530),(196,533),(196,535),(196,536),(196,537),(196,538),(196,539),(196,540),(196,541),(196,556),(196,581),(196,582),(196,592),(196,593),(196,596),(196,602),(196,603),(196,604),(196,605),(196,606),(196,607),(196,608),(196,609),(196,610),(196,611),(196,612),(196,613),(196,614),(196,615),(196,616),(196,617),(196,618),(196,619),(196,620),(196,621),(196,622),(196,623),(196,624),(196,625),(196,626),(196,627),(196,628),(196,629),(196,630),(196,631),(196,633),(196,634),(196,635),(196,636),(196,637),(196,638),(196,639),(196,640),(196,641),(196,642),(196,643),(196,644),(196,645),(196,646),(196,647),(196,648),(196,649),(196,650),(196,651),(196,652),(196,653),(196,654),(196,655),(196,656),(196,657),(196,658),(196,659),(196,660),(196,661),(196,662),(196,663),(196,664),(196,665),(196,666),(196,667),(196,668),(196,669),(196,670),(196,671),(196,672),(196,673),(196,674),(196,675),(196,676),(196,677),(196,678),(196,679),(196,680),(196,681),(196,682),(196,683),(196,684),(196,685),(196,686),(196,687),(196,688),(196,689),(196,690),(196,691),(196,692),(196,693),(196,694),(196,695),(196,696),(196,697),(196,698),(196,699),(196,700),(196,701),(196,702),(196,703),(196,704),(196,705),(196,706),(196,707),(196,708),(196,709),(196,710),(196,711),(196,712),(196,713),(196,714),(196,715),(196,716),(196,717),(196,718),(196,719),(196,721),(196,722),(196,723),(196,724),(196,725),(196,726),(196,727),(196,728),(196,729),(196,730),(196,733),(196,734),(196,735),(196,736),(196,738),(196,739),(196,748),(196,753),(196,757),(196,773),(196,777),(196,836),(197,232),(197,236),(197,237),(197,273),(197,274),(197,275),(197,276),(197,277),(197,284),(197,285),(197,286),(197,301),(197,311),(197,387),(197,388),(197,389),(197,390),(197,391),(197,392),(197,393),(197,394),(197,395),(197,396),(197,397),(197,398),(197,399),(197,479),(197,480),(197,481),(197,482),(197,485),(197,486),(197,487),(197,494),(197,506),(197,509),(197,510),(197,517),(197,518),(197,521),(197,542),(197,543),(197,550),(197,558),(197,568),(197,571),(197,572),(197,573),(197,574),(197,575),(197,576),(197,577),(197,578),(197,579),(197,580),(197,583),(197,584),(197,585),(197,586),(197,587),(197,588),(197,589),(197,590),(197,591),(197,594),(197,595),(197,601),(197,743),(197,750),(197,758),(197,761),(197,762),(197,763),(197,764),(197,765),(197,766),(197,767),(197,768),(197,769),(197,770),(197,771),(197,772),(197,774),(198,218),(198,300),(198,312),(198,315),(198,316),(198,317),(198,318),(198,367),(198,368),(198,369),(198,370),(198,371),(198,372),(198,374),(198,376),(198,377),(198,378),(198,379),(198,380),(198,381),(198,382),(198,383),(198,384),(198,385),(198,386),(198,408),(198,409),(198,410),(198,411),(198,412),(198,413),(198,414),(198,415),(198,416),(198,430),(198,431),(198,432),(198,433),(198,462),(198,466),(198,467),(198,468),(198,469),(198,470),(198,471),(198,483),(198,484),(198,490),(198,504),(198,512),(198,515),(198,520),(198,524),(198,528),(198,531),(198,532),(198,544),(198,545),(198,546),(198,547),(198,548),(198,549),(198,551),(198,552),(198,553),(198,554),(198,555),(198,557),(198,559),(198,560),(198,561),(198,562),(198,563),(198,564),(198,565),(198,566),(198,567),(198,569),(198,570),(198,597),(198,598),(198,599),(198,600),(198,737),(198,740),(198,741),(198,742),(198,744),(198,745),(198,746),(198,747),(198,749),(198,751),(198,752),(198,754),(198,755),(198,756),(198,759),(198,760),(199,217),(199,221),(199,222),(199,223),(199,225),(199,263),(199,496),(199,501),(199,507),(199,525),(199,534),(199,797); /*!40000 ALTER TABLE `rbac_linked_permissions` ENABLE KEYS */; UNLOCK TABLES; @@ -399,7 +399,7 @@ CREATE TABLE `rbac_permissions` ( LOCK TABLES `rbac_permissions` WRITE; /*!40000 ALTER TABLE `rbac_permissions` DISABLE KEYS */; -INSERT INTO `rbac_permissions` VALUES (1,'Instant logout'),(2,'Skip Queue'),(3,'Join Normal Battleground'),(4,'Join Random Battleground'),(5,'Join Arenas'),(6,'Join Dungeon Finder'),(11,'Log GM trades'),(13,'Skip Instance required bosses check'),(14,'Skip character creation team mask check'),(15,'Skip character creation class mask check'),(16,'Skip character creation race mask check'),(17,'Skip character creation reserved name check'),(18,'Skip character creation heroic min level check'),(19,'Skip needed requirements to use channel check'),(20,'Skip disable map check'),(21,'Skip reset talents when used more than allowed check'),(22,'Skip spam chat check'),(23,'Skip over-speed ping check'),(24,'Two side faction characters on the same account'),(25,'Allow say chat between factions'),(26,'Allow channel chat between factions'),(27,'Two side mail interaction'),(28,'See two side who list'),(29,'Add friends of other faction'),(30,'Save character without delay with .save command'),(31,'Use params with .unstuck command'),(32,'Can be assigned tickets with .assign ticket command'),(33,'Notify if a command was not found'),(34,'Check if should appear in list using .gm ingame command'),(35,'See all security levels with who command'),(36,'Filter whispers'),(37,'Use staff badge in chat'),(38,'Resurrect with full Health Points'),(39,'Restore saved gm setting states'),(40,'Allows to add a gm to friend list'),(41,'Use Config option START_GM_LEVEL to assign new character level'),(42,'Allows to use CMSG_WORLD_TELEPORT opcode'),(43,'Allows to use CMSG_WHOIS opcode'),(44,'Receive global GM messages/texts'),(45,'Join channels without announce'),(46,'Change channel settings without being channel moderator'),(47,'Enables lower security than target check'),(48,'Enable IP, Last Login and EMail output in pinfo'),(49,'Forces to enter the email for confirmation on password change'),(50,'Allow user to check his own email with .account'),(51,'Allow trading between factions'),(192,'Role: Sec Level Administrator'),(193,'Role: Sec Level Gamemaster'),(194,'Role: Sec Level Moderator'),(195,'Role: Sec Level Player'),(196,'Role: Administrator Commands'),(197,'Role: Gamemaster Commands'),(198,'Role: Moderator Commands'),(199,'Role: Player Commands'),(200,'Command: rbac'),(201,'Command: rbac account'),(202,'Command: rbac account list'),(203,'Command: rbac account grant'),(204,'Command: rbac account deny'),(205,'Command: rbac account revoke'),(206,'Command: rbac list'),(217,'Command: account'),(218,'Command: account addon'),(219,'Command: account create'),(220,'Command: account delete'),(221,'Command: account lock'),(222,'Command: account lock country'),(223,'Command: account lock ip'),(224,'Command: account onlinelist'),(225,'Command: account password'),(226,'Command: account set'),(227,'Command: account set addon'),(228,'Command: account set gmlevel'),(229,'Command: account set password'),(230,'Command: achievement'),(231,'Command: achievement add'),(232,'Command: arena'),(233,'Command: arena captain'),(234,'Command: arena create'),(235,'Command: arena disband'),(236,'Command: arena info'),(237,'Command: arena lookup'),(238,'Command: arena rename'),(239,'Command: ban'),(240,'Command: ban account'),(241,'Command: ban character'),(242,'Command: ban ip'),(243,'Command: ban playeraccount'),(244,'Command: baninfo'),(245,'Command: baninfo account'),(246,'Command: baninfo character'),(247,'Command: baninfo ip'),(248,'Command: banlist'),(249,'Command: banlist account'),(250,'Command: banlist character'),(251,'Command: banlist ip'),(252,'Command: unban'),(253,'Command: unban account'),(254,'Command: unban character'),(255,'Command: unban ip'),(256,'Command: unban playeraccount'),(257,'Command: bf'),(258,'Command: bf start'),(259,'Command: bf stop'),(260,'Command: bf switch'),(261,'Command: bf timer'),(262,'Command: bf enable'),(263,'Command: account email'),(264,'Command: account set sec'),(265,'Command: account set sec email'),(266,'Command: account set sec regmail'),(267,'Command: cast'),(268,'Command: cast back'),(269,'Command: cast dist'),(270,'Command: cast self'),(271,'Command: cast target'),(272,'Command: cast dest'),(273,'Command: character'),(274,'Command: character customize'),(275,'Command: character changefaction'),(276,'Command: character changerace'),(277,'Command: character deleted'),(279,'Command: character deleted list'),(280,'Command: character deleted restore'),(283,'Command: character level'),(284,'Command: character rename'),(285,'Command: character reputation'),(286,'Command: character titles'),(287,'Command: levelup'),(288,'Command: pdump'),(289,'Command: pdump load'),(290,'Command: pdump write'),(291,'Command: cheat'),(292,'Command: cheat casttime'),(293,'Command: cheat cooldown'),(294,'Command: cheat explore'),(295,'Command: cheat god'),(296,'Command: cheat power'),(297,'Command: cheat status'),(298,'Command: cheat taxi'),(299,'Command: cheat waterwalk'),(300,'Command: debug'),(301,'Command: debug anim'),(302,'Command: debug areatriggers'),(303,'Command: debug arena'),(304,'Command: debug bg'),(305,'Command: debug entervehicle'),(306,'Command: debug getitemstate'),(307,'Command: debug getitemvalue'),(308,'Command: debug getvalue'),(309,'Command: debug hostil'),(310,'Command: debug itemexpire'),(311,'Command: debug lootrecipient'),(312,'Command: debug los'),(313,'Command: debug mod32value'),(314,'Command: debug moveflags'),(315,'Command: debug play'),(316,'Command: debug play cinematics'),(317,'Command: debug play movie'),(318,'Command: debug play sound'),(319,'Command: debug send'),(320,'Command: debug send buyerror'),(321,'Command: debug send channelnotify'),(322,'Command: debug send chatmessage'),(323,'Command: debug send equiperror'),(324,'Command: debug send largepacket'),(325,'Command: debug send opcode'),(326,'Command: debug send qinvalidmsg'),(327,'Command: debug send qpartymsg'),(328,'Command: debug send sellerror'),(329,'Command: debug send setphaseshift'),(330,'Command: debug send spellfail'),(331,'Command: debug setaurastate'),(332,'Command: debug setbit'),(333,'Command: debug setitemvalue'),(334,'Command: debug setvalue'),(335,'Command: debug setvid'),(336,'Command: debug spawnvehicle'),(337,'Command: debug threat'),(338,'Command: debug update'),(339,'Command: debug uws'),(340,'Command: wpgps'),(341,'Command: deserter'),(342,'Command: deserter bg'),(343,'Command: deserter bg add'),(344,'Command: deserter bg remove'),(345,'Command: deserter instance'),(346,'Command: deserter instance add'),(347,'Command: deserter instance remove'),(348,'Command: disable'),(349,'Command: disable add'),(350,'Command: disable add achievement_criteria'),(351,'Command: disable add battleground'),(352,'Command: disable add map'),(353,'Command: disable add mmap'),(354,'Command: disable add outdoorpvp'),(355,'Command: disable add quest'),(356,'Command: disable add spell'),(357,'Command: disable add vmap'),(358,'Command: disable remove'),(359,'Command: disable remove achievement_criteria'),(360,'Command: disable remove battleground'),(361,'Command: disable remove map'),(362,'Command: disable remove mmap'),(363,'Command: disable remove outdoorpvp'),(364,'Command: disable remove quest'),(365,'Command: disable remove spell'),(366,'Command: disable remove vmap'),(367,'Command: event'),(368,'Command: event activelist'),(369,'Command: event start'),(370,'Command: event stop'),(371,'Command: gm'),(372,'Command: gm chat'),(373,'Command: gm fly'),(374,'Command: gm ingame'),(375,'Command: gm list'),(376,'Command: gm visible'),(377,'Command: go'),(378,'Command: go creature'),(379,'Command: go graveyard'),(380,'Command: go grid'),(381,'Command: go object'),(382,'Command: go taxinode'),(383,'Command: go ticket'),(384,'Command: go trigger'),(385,'Command: go xyz'),(386,'Command: go zonexy'),(387,'Command: gobject'),(388,'Command: gobject activate'),(389,'Command: gobject add'),(390,'Command: gobject add temp'),(391,'Command: gobject delete'),(392,'Command: gobject info'),(393,'Command: gobject move'),(394,'Command: gobject near'),(395,'Command: gobject set'),(396,'Command: gobject set phase'),(397,'Command: gobject set state'),(398,'Command: gobject target'),(399,'Command: gobject turn'),(400,'debug transport'),(401,'Command: guild'),(402,'Command: guild create'),(403,'Command: guild delete'),(404,'Command: guild invite'),(405,'Command: guild uninvite'),(406,'Command: guild rank'),(407,'Command: guild rename'),(408,'Command: honor'),(409,'Command: honor add'),(410,'Command: honor add kill'),(411,'Command: honor update'),(412,'Command: instance'),(413,'Command: instance listbinds'),(414,'Command: instance unbind'),(415,'Command: instance stats'),(416,'Command: instance savedata'),(417,'Command: learn'),(418,'Command: learn all'),(419,'Command: learn all my'),(420,'Command: learn all my class'),(421,'Command: learn all my pettalents'),(422,'Command: learn all my spells'),(423,'Command: learn all my talents'),(424,'Command: learn all gm'),(425,'Command: learn all crafts'),(426,'Command: learn all default'),(427,'Command: learn all lang'),(428,'Command: learn all recipes'),(429,'Command: unlearn'),(430,'Command: lfg'),(431,'Command: lfg player'),(432,'Command: lfg group'),(433,'Command: lfg queue'),(434,'Command: lfg clean'),(435,'Command: lfg options'),(436,'Command: list'),(437,'Command: list creature'),(438,'Command: list item'),(439,'Command: list object'),(440,'Command: list auras'),(441,'Command: list mail'),(442,'Command: lookup'),(443,'Command: lookup area'),(444,'Command: lookup creature'),(445,'Command: lookup event'),(446,'Command: lookup faction'),(447,'Command: lookup item'),(448,'Command: lookup itemset'),(449,'Command: lookup object'),(450,'Command: lookup quest'),(451,'Command: lookup player'),(452,'Command: lookup player ip'),(453,'Command: lookup player account'),(454,'Command: lookup player email'),(455,'Command: lookup skill'),(456,'Command: lookup spell'),(457,'Command: lookup spell id'),(458,'Command: lookup taxinode'),(459,'Command: lookup tele'),(460,'Command: lookup title'),(461,'Command: lookup map'),(462,'Command: announce'),(463,'Command: channel'),(464,'Command: channel set'),(465,'Command: channel set ownership'),(466,'Command: gmannounce'),(467,'Command: gmnameannounce'),(468,'Command: gmnotify'),(469,'Command: nameannounce'),(470,'Command: notify'),(471,'Command: whispers'),(472,'Command: group'),(473,'Command: group leader'),(474,'Command: group disband'),(475,'Command: group remove'),(476,'Command: group join'),(477,'Command: group list'),(478,'Command: group summon'),(479,'Command: pet'),(480,'Command: pet create'),(481,'Command: pet learn'),(482,'Command: pet unlearn'),(483,'Command: send'),(484,'Command: send items'),(485,'Command: send mail'),(486,'Command: send message'),(487,'Command: send money'),(488,'Command: additem'),(489,'Command: additemset'),(490,'Command: appear'),(491,'Command: aura'),(492,'Command: bank'),(493,'Command: bindsight'),(494,'Command: combatstop'),(495,'Command: cometome'),(496,'Command: commands'),(497,'Command: cooldown'),(498,'Command: damage'),(499,'Command: dev'),(500,'Command: die'),(501,'Command: dismount'),(502,'Command: distance'),(503,'Command: flusharenapoints'),(504,'Command: freeze'),(505,'Command: gps'),(506,'Command: guid'),(507,'Command: help'),(508,'Command: hidearea'),(509,'Command: itemmove'),(510,'Command: kick'),(511,'Command: linkgrave'),(512,'Command: listfreeze'),(513,'Command: maxskill'),(514,'Command: movegens'),(515,'Command: mute'),(516,'Command: neargrave'),(517,'Command: pinfo'),(518,'Command: playall'),(519,'Command: possess'),(520,'Command: recall'),(521,'Command: repairitems'),(522,'Command: respawn'),(523,'Command: revive'),(524,'Command: saveall'),(525,'Command: save'),(526,'Command: setskill'),(527,'Command: showarea'),(528,'Command: summon'),(529,'Command: unaura'),(530,'Command: unbindsight'),(531,'Command: unfreeze'),(532,'Command: unmute'),(533,'Command: unpossess'),(534,'Command: unstuck'),(535,'Command: wchange'),(536,'Command: mmap'),(537,'Command: mmap loadedtiles'),(538,'Command: mmap loc'),(539,'Command: mmap path'),(540,'Command: mmap stats'),(541,'Command: mmap testarea'),(542,'Command: morph'),(543,'Command: demorph'),(544,'Command: modify'),(545,'Command: modify arenapoints'),(546,'Command: modify bit'),(547,'Command: modify drunk'),(548,'Command: modify energy'),(549,'Command: modify faction'),(550,'Command: modify gender'),(551,'Command: modify honor'),(552,'Command: modify hp'),(553,'Command: modify mana'),(554,'Command: modify money'),(555,'Command: modify mount'),(556,'Command: modify phase'),(557,'Command: modify rage'),(558,'Command: modify reputation'),(559,'Command: modify runicpower'),(560,'Command: modify scale'),(561,'Command: modify speed'),(562,'Command: modify speed all'),(563,'Command: modify speed backwalk'),(564,'Command: modify speed fly'),(565,'Command: modify speed walk'),(566,'Command: modify speed swim'),(567,'Command: modify spell'),(568,'Command: modify standstate'),(569,'Command: modify talentpoints'),(570,'Command: npc'),(571,'Command: npc add'),(572,'Command: npc add formation'),(573,'Command: npc add item'),(574,'Command: npc add move'),(575,'Command: npc add temp'),(576,'Command: npc add delete'),(577,'Command: npc add delete item'),(578,'Command: npc add follow'),(579,'Command: npc add follow stop'),(580,'Command: npc set'),(581,'Command: npc set allowmove'),(582,'Command: npc set entry'),(583,'Command: npc set factionid'),(584,'Command: npc set flag'),(585,'Command: npc set level'),(586,'Command: npc set link'),(587,'Command: npc set model'),(588,'Command: npc set movetype'),(589,'Command: npc set phase'),(590,'Command: npc set spawndist'),(591,'Command: npc set spawntime'),(592,'Command: npc set data'),(593,'Command: npc info'),(594,'Command: npc near'),(595,'Command: npc move'),(596,'Command: npc playemote'),(597,'Command: npc say'),(598,'Command: npc textemote'),(599,'Command: npc whisper'),(600,'Command: npc yell'),(601,'Command: npc tame'),(602,'Command: quest'),(603,'Command: quest add'),(604,'Command: quest complete'),(605,'Command: quest remove'),(606,'Command: quest reward'),(607,'Command: reload'),(608,'Command: reload access_requirement'),(609,'Command: reload achievement_criteria_data'),(610,'Command: reload achievement_reward'),(611,'Command: reload all'),(612,'Command: reload all achievement'),(613,'Command: reload all area'),(614,'Command: broadcast_text'),(615,'Command: reload all gossips'),(616,'Command: reload all item'),(617,'Command: reload all locales'),(618,'Command: reload all loot'),(619,'Command: reload all npc'),(620,'Command: reload all quest'),(621,'Command: reload all scripts'),(622,'Command: reload all spell'),(623,'Command: reload areatrigger_involvedrelation'),(624,'Command: reload areatrigger_tavern'),(625,'Command: reload areatrigger_teleport'),(626,'Command: reload auctions'),(627,'Command: reload autobroadcast'),(628,'Command: reload command'),(629,'Command: reload conditions'),(630,'Command: reload config'),(631,'Command: reload battleground_template'),(632,'Command: .mutehistory'),(633,'Command: reload creature_linked_respawn'),(634,'Command: reload creature_loot_template'),(635,'Command: reload creature_onkill_reputation'),(636,'Command: reload creature_questender'),(637,'Command: reload creature_queststarter'),(638,'Command: reload creature_summon_groups'),(639,'Command: reload creature_template'),(640,'Command: reload creature_text'),(641,'Command: reload disables'),(642,'Command: reload disenchant_loot_template'),(643,'Command: reload event_scripts'),(644,'Command: reload fishing_loot_template'),(645,'Command: reload game_graveyard_zone'),(646,'Command: reload game_tele'),(647,'Command: reload gameobject_questender'),(648,'Command: reload gameobject_loot_template'),(649,'Command: reload gameobject_queststarter'),(650,'Command: reload gm_tickets'),(651,'Command: reload gossip_menu'),(652,'Command: reload gossip_menu_option'),(653,'Command: reload item_enchantment_template'),(654,'Command: reload item_loot_template'),(655,'Command: reload item_set_names'),(656,'Command: reload lfg_dungeon_rewards'),(657,'Command: reload locales_achievement_reward'),(658,'Command: reload locales_creature'),(659,'Command: reload locales_creature_text'),(660,'Command: reload locales_gameobject'),(661,'Command: reload locales_gossip_menu_option'),(662,'Command: reload locales_item'),(663,'Command: reload locales_item_set_name'),(664,'Command: reload locales_npc_text'),(665,'Command: reload locales_page_text'),(666,'Command: reload locales_points_of_interest'),(667,'Command: reload locales_quest'),(668,'Command: reload mail_level_reward'),(669,'Command: reload mail_loot_template'),(670,'Command: reload milling_loot_template'),(671,'Command: reload npc_spellclick_spells'),(672,'Command: reload npc_trainer'),(673,'Command: reload npc_vendor'),(674,'Command: reload page_text'),(675,'Command: reload pickpocketing_loot_template'),(676,'Command: reload points_of_interest'),(677,'Command: reload prospecting_loot_template'),(678,'Command: reload quest_poi'),(679,'Command: reload quest_template'),(680,'Command: reload rbac'),(681,'Command: reload reference_loot_template'),(682,'Command: reload reserved_name'),(683,'Command: reload reputation_reward_rate'),(684,'Command: reload reputation_spillover_template'),(685,'Command: reload skill_discovery_template'),(686,'Command: reload skill_extra_item_template'),(687,'Command: reload skill_fishing_base_level'),(688,'Command: reload skinning_loot_template'),(689,'Command: reload smart_scripts'),(690,'Command: reload spell_required'),(691,'Command: reload spell_area'),(692,'Command: reload spell_bonus_data'),(693,'Command: reload spell_group'),(694,'Command: reload spell_learn_spell'),(695,'Command: reload spell_loot_template'),(696,'Command: reload spell_linked_spell'),(697,'Command: reload spell_pet_auras'),(698,'Command: reload spell_proc_event'),(699,'Command: reload spell_proc'),(700,'Command: reload spell_scripts'),(701,'Command: reload spell_target_position'),(702,'Command: reload spell_threats'),(703,'Command: reload spell_group_stack_rules'),(704,'Command: reload trinity_string'),(705,'Command: reload warden_action'),(706,'Command: reload waypoint_scripts'),(707,'Command: reload waypoint_data'),(708,'Command: reload vehicle_accessory'),(709,'Command: reload vehicle_template_accessory'),(710,'Command: reset'),(711,'Command: reset achievements'),(712,'Command: reset honor'),(713,'Command: reset level'),(714,'Command: reset spells'),(715,'Command: reset stats'),(716,'Command: reset talents'),(717,'Command: reset all'),(718,'Command: server'),(719,'Command: server corpses'),(720,'Command: server exit'),(721,'Command: server idlerestart'),(722,'Command: server idlerestart cancel'),(723,'Command: server idleshutdown'),(724,'Command: server idleshutdown cancel'),(725,'Command: server info'),(726,'Command: server plimit'),(727,'Command: server restart'),(728,'Command: server restart cancel'),(729,'Command: server set'),(730,'Command: server set closed'),(731,'Command: server set difftime'),(732,'Command: server set loglevel'),(733,'Command: server set motd'),(734,'Command: server shutdown'),(735,'Command: server shutdown cancel'),(736,'Command: server motd'),(737,'Command: tele'),(738,'Command: tele add'),(739,'Command: tele del'),(740,'Command: tele name'),(741,'Command: tele group'),(742,'Command: ticket'),(743,'Command: ticket assign'),(744,'Command: ticket close'),(745,'Command: ticket closedlist'),(746,'Command: ticket comment'),(747,'Command: ticket complete'),(748,'Command: ticket delete'),(749,'Command: ticket escalate'),(750,'Command: ticket escalatedlist'),(751,'Command: ticket list'),(752,'Command: ticket onlinelist'),(753,'Command: ticket reset'),(754,'Command: ticket response'),(755,'Command: ticket response append'),(756,'Command: ticket response appendln'),(757,'Command: ticket togglesystem'),(758,'Command: ticket unassign'),(759,'Command: ticket viewid'),(760,'Command: ticket viewname'),(761,'Command: titles'),(762,'Command: titles add'),(763,'Command: titles current'),(764,'Command: titles remove'),(765,'Command: titles set'),(766,'Command: titles set mask'),(767,'Command: wp'),(768,'Command: wp add'),(769,'Command: wp event'),(770,'Command: wp load'),(771,'Command: wp modify'),(772,'Command: wp unload'),(773,'Command: wp reload'),(774,'Command: wp show'),(777,'Command: mailbox'),(778,'Command: ahbot'),(779,'Command: ahbot items'),(780,'Command: ahbot items gray'),(781,'Command: ahbot items white'),(782,'Command: ahbot items green'),(783,'Command: ahbot items blue'),(784,'Command: ahbot items purple'),(785,'Command: ahbot items orange'),(786,'Command: ahbot items yellow'),(787,'Command: ahbot ratio'),(788,'Command: ahbot ratio alliance'),(789,'Command: ahbot ratio horde'),(790,'Command: ahbot ratio neutral'),(791,'Command: ahbot rebuild'),(792,'Command: ahbot reload'),(793,'Command: ahbot status'),(794,'Command: .guild info'),(795,'Command: .instance setbossstate'),(796,'Command: instance getbossstate'),(797,'Command: pvpstats'),(798,'Command: .mod xp'),(835,'Command: debug loadcells'); +INSERT INTO `rbac_permissions` VALUES (1,'Instant logout'),(2,'Skip Queue'),(3,'Join Normal Battleground'),(4,'Join Random Battleground'),(5,'Join Arenas'),(6,'Join Dungeon Finder'),(11,'Log GM trades'),(13,'Skip Instance required bosses check'),(14,'Skip character creation team mask check'),(15,'Skip character creation class mask check'),(16,'Skip character creation race mask check'),(17,'Skip character creation reserved name check'),(18,'Skip character creation heroic min level check'),(19,'Skip needed requirements to use channel check'),(20,'Skip disable map check'),(21,'Skip reset talents when used more than allowed check'),(22,'Skip spam chat check'),(23,'Skip over-speed ping check'),(24,'Two side faction characters on the same account'),(25,'Allow say chat between factions'),(26,'Allow channel chat between factions'),(27,'Two side mail interaction'),(28,'See two side who list'),(29,'Add friends of other faction'),(30,'Save character without delay with .save command'),(31,'Use params with .unstuck command'),(32,'Can be assigned tickets with .assign ticket command'),(33,'Notify if a command was not found'),(34,'Check if should appear in list using .gm ingame command'),(35,'See all security levels with who command'),(36,'Filter whispers'),(37,'Use staff badge in chat'),(38,'Resurrect with full Health Points'),(39,'Restore saved gm setting states'),(40,'Allows to add a gm to friend list'),(41,'Use Config option START_GM_LEVEL to assign new character level'),(42,'Allows to use CMSG_WORLD_TELEPORT opcode'),(43,'Allows to use CMSG_WHOIS opcode'),(44,'Receive global GM messages/texts'),(45,'Join channels without announce'),(46,'Change channel settings without being channel moderator'),(47,'Enables lower security than target check'),(48,'Enable IP, Last Login and EMail output in pinfo'),(49,'Forces to enter the email for confirmation on password change'),(50,'Allow user to check his own email with .account'),(51,'Allow trading between factions'),(192,'Role: Sec Level Administrator'),(193,'Role: Sec Level Gamemaster'),(194,'Role: Sec Level Moderator'),(195,'Role: Sec Level Player'),(196,'Role: Administrator Commands'),(197,'Role: Gamemaster Commands'),(198,'Role: Moderator Commands'),(199,'Role: Player Commands'),(200,'Command: rbac'),(201,'Command: rbac account'),(202,'Command: rbac account list'),(203,'Command: rbac account grant'),(204,'Command: rbac account deny'),(205,'Command: rbac account revoke'),(206,'Command: rbac list'),(217,'Command: account'),(218,'Command: account addon'),(219,'Command: account create'),(220,'Command: account delete'),(221,'Command: account lock'),(222,'Command: account lock country'),(223,'Command: account lock ip'),(224,'Command: account onlinelist'),(225,'Command: account password'),(226,'Command: account set'),(227,'Command: account set addon'),(228,'Command: account set gmlevel'),(229,'Command: account set password'),(230,'Command: achievement'),(231,'Command: achievement add'),(232,'Command: arena'),(233,'Command: arena captain'),(234,'Command: arena create'),(235,'Command: arena disband'),(236,'Command: arena info'),(237,'Command: arena lookup'),(238,'Command: arena rename'),(239,'Command: ban'),(240,'Command: ban account'),(241,'Command: ban character'),(242,'Command: ban ip'),(243,'Command: ban playeraccount'),(244,'Command: baninfo'),(245,'Command: baninfo account'),(246,'Command: baninfo character'),(247,'Command: baninfo ip'),(248,'Command: banlist'),(249,'Command: banlist account'),(250,'Command: banlist character'),(251,'Command: banlist ip'),(252,'Command: unban'),(253,'Command: unban account'),(254,'Command: unban character'),(255,'Command: unban ip'),(256,'Command: unban playeraccount'),(257,'Command: bf'),(258,'Command: bf start'),(259,'Command: bf stop'),(260,'Command: bf switch'),(261,'Command: bf timer'),(262,'Command: bf enable'),(263,'Command: account email'),(264,'Command: account set sec'),(265,'Command: account set sec email'),(266,'Command: account set sec regmail'),(267,'Command: cast'),(268,'Command: cast back'),(269,'Command: cast dist'),(270,'Command: cast self'),(271,'Command: cast target'),(272,'Command: cast dest'),(273,'Command: character'),(274,'Command: character customize'),(275,'Command: character changefaction'),(276,'Command: character changerace'),(277,'Command: character deleted'),(279,'Command: character deleted list'),(280,'Command: character deleted restore'),(283,'Command: character level'),(284,'Command: character rename'),(285,'Command: character reputation'),(286,'Command: character titles'),(287,'Command: levelup'),(288,'Command: pdump'),(289,'Command: pdump load'),(290,'Command: pdump write'),(291,'Command: cheat'),(292,'Command: cheat casttime'),(293,'Command: cheat cooldown'),(294,'Command: cheat explore'),(295,'Command: cheat god'),(296,'Command: cheat power'),(297,'Command: cheat status'),(298,'Command: cheat taxi'),(299,'Command: cheat waterwalk'),(300,'Command: debug'),(301,'Command: debug anim'),(302,'Command: debug areatriggers'),(303,'Command: debug arena'),(304,'Command: debug bg'),(305,'Command: debug entervehicle'),(306,'Command: debug getitemstate'),(307,'Command: debug getitemvalue'),(308,'Command: debug getvalue'),(309,'Command: debug hostil'),(310,'Command: debug itemexpire'),(311,'Command: debug lootrecipient'),(312,'Command: debug los'),(313,'Command: debug mod32value'),(314,'Command: debug moveflags'),(315,'Command: debug play'),(316,'Command: debug play cinematics'),(317,'Command: debug play movie'),(318,'Command: debug play sound'),(319,'Command: debug send'),(320,'Command: debug send buyerror'),(321,'Command: debug send channelnotify'),(322,'Command: debug send chatmessage'),(323,'Command: debug send equiperror'),(324,'Command: debug send largepacket'),(325,'Command: debug send opcode'),(326,'Command: debug send qinvalidmsg'),(327,'Command: debug send qpartymsg'),(328,'Command: debug send sellerror'),(329,'Command: debug send setphaseshift'),(330,'Command: debug send spellfail'),(331,'Command: debug setaurastate'),(332,'Command: debug setbit'),(333,'Command: debug setitemvalue'),(334,'Command: debug setvalue'),(335,'Command: debug setvid'),(336,'Command: debug spawnvehicle'),(337,'Command: debug threat'),(338,'Command: debug update'),(339,'Command: debug uws'),(340,'Command: wpgps'),(341,'Command: deserter'),(342,'Command: deserter bg'),(343,'Command: deserter bg add'),(344,'Command: deserter bg remove'),(345,'Command: deserter instance'),(346,'Command: deserter instance add'),(347,'Command: deserter instance remove'),(348,'Command: disable'),(349,'Command: disable add'),(350,'Command: disable add achievement_criteria'),(351,'Command: disable add battleground'),(352,'Command: disable add map'),(353,'Command: disable add mmap'),(354,'Command: disable add outdoorpvp'),(355,'Command: disable add quest'),(356,'Command: disable add spell'),(357,'Command: disable add vmap'),(358,'Command: disable remove'),(359,'Command: disable remove achievement_criteria'),(360,'Command: disable remove battleground'),(361,'Command: disable remove map'),(362,'Command: disable remove mmap'),(363,'Command: disable remove outdoorpvp'),(364,'Command: disable remove quest'),(365,'Command: disable remove spell'),(366,'Command: disable remove vmap'),(367,'Command: event'),(368,'Command: event activelist'),(369,'Command: event start'),(370,'Command: event stop'),(371,'Command: gm'),(372,'Command: gm chat'),(373,'Command: gm fly'),(374,'Command: gm ingame'),(375,'Command: gm list'),(376,'Command: gm visible'),(377,'Command: go'),(378,'Command: go creature'),(379,'Command: go graveyard'),(380,'Command: go grid'),(381,'Command: go object'),(382,'Command: go taxinode'),(383,'Command: go ticket'),(384,'Command: go trigger'),(385,'Command: go xyz'),(386,'Command: go zonexy'),(387,'Command: gobject'),(388,'Command: gobject activate'),(389,'Command: gobject add'),(390,'Command: gobject add temp'),(391,'Command: gobject delete'),(392,'Command: gobject info'),(393,'Command: gobject move'),(394,'Command: gobject near'),(395,'Command: gobject set'),(396,'Command: gobject set phase'),(397,'Command: gobject set state'),(398,'Command: gobject target'),(399,'Command: gobject turn'),(400,'debug transport'),(401,'Command: guild'),(402,'Command: guild create'),(403,'Command: guild delete'),(404,'Command: guild invite'),(405,'Command: guild uninvite'),(406,'Command: guild rank'),(407,'Command: guild rename'),(408,'Command: honor'),(409,'Command: honor add'),(410,'Command: honor add kill'),(411,'Command: honor update'),(412,'Command: instance'),(413,'Command: instance listbinds'),(414,'Command: instance unbind'),(415,'Command: instance stats'),(416,'Command: instance savedata'),(417,'Command: learn'),(418,'Command: learn all'),(419,'Command: learn all my'),(420,'Command: learn all my class'),(421,'Command: learn all my pettalents'),(422,'Command: learn all my spells'),(423,'Command: learn all my talents'),(424,'Command: learn all gm'),(425,'Command: learn all crafts'),(426,'Command: learn all default'),(427,'Command: learn all lang'),(428,'Command: learn all recipes'),(429,'Command: unlearn'),(430,'Command: lfg'),(431,'Command: lfg player'),(432,'Command: lfg group'),(433,'Command: lfg queue'),(434,'Command: lfg clean'),(435,'Command: lfg options'),(436,'Command: list'),(437,'Command: list creature'),(438,'Command: list item'),(439,'Command: list object'),(440,'Command: list auras'),(441,'Command: list mail'),(442,'Command: lookup'),(443,'Command: lookup area'),(444,'Command: lookup creature'),(445,'Command: lookup event'),(446,'Command: lookup faction'),(447,'Command: lookup item'),(448,'Command: lookup itemset'),(449,'Command: lookup object'),(450,'Command: lookup quest'),(451,'Command: lookup player'),(452,'Command: lookup player ip'),(453,'Command: lookup player account'),(454,'Command: lookup player email'),(455,'Command: lookup skill'),(456,'Command: lookup spell'),(457,'Command: lookup spell id'),(458,'Command: lookup taxinode'),(459,'Command: lookup tele'),(460,'Command: lookup title'),(461,'Command: lookup map'),(462,'Command: announce'),(463,'Command: channel'),(464,'Command: channel set'),(465,'Command: channel set ownership'),(466,'Command: gmannounce'),(467,'Command: gmnameannounce'),(468,'Command: gmnotify'),(469,'Command: nameannounce'),(470,'Command: notify'),(471,'Command: whispers'),(472,'Command: group'),(473,'Command: group leader'),(474,'Command: group disband'),(475,'Command: group remove'),(476,'Command: group join'),(477,'Command: group list'),(478,'Command: group summon'),(479,'Command: pet'),(480,'Command: pet create'),(481,'Command: pet learn'),(482,'Command: pet unlearn'),(483,'Command: send'),(484,'Command: send items'),(485,'Command: send mail'),(486,'Command: send message'),(487,'Command: send money'),(488,'Command: additem'),(489,'Command: additemset'),(490,'Command: appear'),(491,'Command: aura'),(492,'Command: bank'),(493,'Command: bindsight'),(494,'Command: combatstop'),(495,'Command: cometome'),(496,'Command: commands'),(497,'Command: cooldown'),(498,'Command: damage'),(499,'Command: dev'),(500,'Command: die'),(501,'Command: dismount'),(502,'Command: distance'),(503,'Command: flusharenapoints'),(504,'Command: freeze'),(505,'Command: gps'),(506,'Command: guid'),(507,'Command: help'),(508,'Command: hidearea'),(509,'Command: itemmove'),(510,'Command: kick'),(511,'Command: linkgrave'),(512,'Command: listfreeze'),(513,'Command: maxskill'),(514,'Command: movegens'),(515,'Command: mute'),(516,'Command: neargrave'),(517,'Command: pinfo'),(518,'Command: playall'),(519,'Command: possess'),(520,'Command: recall'),(521,'Command: repairitems'),(522,'Command: respawn'),(523,'Command: revive'),(524,'Command: saveall'),(525,'Command: save'),(526,'Command: setskill'),(527,'Command: showarea'),(528,'Command: summon'),(529,'Command: unaura'),(530,'Command: unbindsight'),(531,'Command: unfreeze'),(532,'Command: unmute'),(533,'Command: unpossess'),(534,'Command: unstuck'),(535,'Command: wchange'),(536,'Command: mmap'),(537,'Command: mmap loadedtiles'),(538,'Command: mmap loc'),(539,'Command: mmap path'),(540,'Command: mmap stats'),(541,'Command: mmap testarea'),(542,'Command: morph'),(543,'Command: demorph'),(544,'Command: modify'),(545,'Command: modify arenapoints'),(546,'Command: modify bit'),(547,'Command: modify drunk'),(548,'Command: modify energy'),(549,'Command: modify faction'),(550,'Command: modify gender'),(551,'Command: modify honor'),(552,'Command: modify hp'),(553,'Command: modify mana'),(554,'Command: modify money'),(555,'Command: modify mount'),(556,'Command: modify phase'),(557,'Command: modify rage'),(558,'Command: modify reputation'),(559,'Command: modify runicpower'),(560,'Command: modify scale'),(561,'Command: modify speed'),(562,'Command: modify speed all'),(563,'Command: modify speed backwalk'),(564,'Command: modify speed fly'),(565,'Command: modify speed walk'),(566,'Command: modify speed swim'),(567,'Command: modify spell'),(568,'Command: modify standstate'),(569,'Command: modify talentpoints'),(570,'Command: npc'),(571,'Command: npc add'),(572,'Command: npc add formation'),(573,'Command: npc add item'),(574,'Command: npc add move'),(575,'Command: npc add temp'),(576,'Command: npc add delete'),(577,'Command: npc add delete item'),(578,'Command: npc add follow'),(579,'Command: npc add follow stop'),(580,'Command: npc set'),(581,'Command: npc set allowmove'),(582,'Command: npc set entry'),(583,'Command: npc set factionid'),(584,'Command: npc set flag'),(585,'Command: npc set level'),(586,'Command: npc set link'),(587,'Command: npc set model'),(588,'Command: npc set movetype'),(589,'Command: npc set phase'),(590,'Command: npc set spawndist'),(591,'Command: npc set spawntime'),(592,'Command: npc set data'),(593,'Command: npc info'),(594,'Command: npc near'),(595,'Command: npc move'),(596,'Command: npc playemote'),(597,'Command: npc say'),(598,'Command: npc textemote'),(599,'Command: npc whisper'),(600,'Command: npc yell'),(601,'Command: npc tame'),(602,'Command: quest'),(603,'Command: quest add'),(604,'Command: quest complete'),(605,'Command: quest remove'),(606,'Command: quest reward'),(607,'Command: reload'),(608,'Command: reload access_requirement'),(609,'Command: reload achievement_criteria_data'),(610,'Command: reload achievement_reward'),(611,'Command: reload all'),(612,'Command: reload all achievement'),(613,'Command: reload all area'),(614,'Command: broadcast_text'),(615,'Command: reload all gossips'),(616,'Command: reload all item'),(617,'Command: reload all locales'),(618,'Command: reload all loot'),(619,'Command: reload all npc'),(620,'Command: reload all quest'),(621,'Command: reload all scripts'),(622,'Command: reload all spell'),(623,'Command: reload areatrigger_involvedrelation'),(624,'Command: reload areatrigger_tavern'),(625,'Command: reload areatrigger_teleport'),(626,'Command: reload auctions'),(627,'Command: reload autobroadcast'),(628,'Command: reload command'),(629,'Command: reload conditions'),(630,'Command: reload config'),(631,'Command: reload battleground_template'),(632,'Command: .mutehistory'),(633,'Command: reload creature_linked_respawn'),(634,'Command: reload creature_loot_template'),(635,'Command: reload creature_onkill_reputation'),(636,'Command: reload creature_questender'),(637,'Command: reload creature_queststarter'),(638,'Command: reload creature_summon_groups'),(639,'Command: reload creature_template'),(640,'Command: reload creature_text'),(641,'Command: reload disables'),(642,'Command: reload disenchant_loot_template'),(643,'Command: reload event_scripts'),(644,'Command: reload fishing_loot_template'),(645,'Command: reload game_graveyard_zone'),(646,'Command: reload game_tele'),(647,'Command: reload gameobject_questender'),(648,'Command: reload gameobject_loot_template'),(649,'Command: reload gameobject_queststarter'),(650,'Command: reload gm_tickets'),(651,'Command: reload gossip_menu'),(652,'Command: reload gossip_menu_option'),(653,'Command: reload item_enchantment_template'),(654,'Command: reload item_loot_template'),(655,'Command: reload item_set_names'),(656,'Command: reload lfg_dungeon_rewards'),(657,'Command: reload locales_achievement_reward'),(658,'Command: reload locales_creature'),(659,'Command: reload locales_creature_text'),(660,'Command: reload locales_gameobject'),(661,'Command: reload locales_gossip_menu_option'),(662,'Command: reload locales_item'),(663,'Command: reload locales_item_set_name'),(664,'Command: reload locales_npc_text'),(665,'Command: reload locales_page_text'),(666,'Command: reload locales_points_of_interest'),(667,'Command: reload locales_quest'),(668,'Command: reload mail_level_reward'),(669,'Command: reload mail_loot_template'),(670,'Command: reload milling_loot_template'),(671,'Command: reload npc_spellclick_spells'),(672,'Command: reload npc_trainer'),(673,'Command: reload npc_vendor'),(674,'Command: reload page_text'),(675,'Command: reload pickpocketing_loot_template'),(676,'Command: reload points_of_interest'),(677,'Command: reload prospecting_loot_template'),(678,'Command: reload quest_poi'),(679,'Command: reload quest_template'),(680,'Command: reload rbac'),(681,'Command: reload reference_loot_template'),(682,'Command: reload reserved_name'),(683,'Command: reload reputation_reward_rate'),(684,'Command: reload reputation_spillover_template'),(685,'Command: reload skill_discovery_template'),(686,'Command: reload skill_extra_item_template'),(687,'Command: reload skill_fishing_base_level'),(688,'Command: reload skinning_loot_template'),(689,'Command: reload smart_scripts'),(690,'Command: reload spell_required'),(691,'Command: reload spell_area'),(692,'Command: reload spell_bonus_data'),(693,'Command: reload spell_group'),(694,'Command: reload spell_learn_spell'),(695,'Command: reload spell_loot_template'),(696,'Command: reload spell_linked_spell'),(697,'Command: reload spell_pet_auras'),(698,'Command: reload spell_proc_event'),(699,'Command: reload spell_proc'),(700,'Command: reload spell_scripts'),(701,'Command: reload spell_target_position'),(702,'Command: reload spell_threats'),(703,'Command: reload spell_group_stack_rules'),(704,'Command: reload trinity_string'),(705,'Command: reload warden_action'),(706,'Command: reload waypoint_scripts'),(707,'Command: reload waypoint_data'),(708,'Command: reload vehicle_accessory'),(709,'Command: reload vehicle_template_accessory'),(710,'Command: reset'),(711,'Command: reset achievements'),(712,'Command: reset honor'),(713,'Command: reset level'),(714,'Command: reset spells'),(715,'Command: reset stats'),(716,'Command: reset talents'),(717,'Command: reset all'),(718,'Command: server'),(719,'Command: server corpses'),(720,'Command: server exit'),(721,'Command: server idlerestart'),(722,'Command: server idlerestart cancel'),(723,'Command: server idleshutdown'),(724,'Command: server idleshutdown cancel'),(725,'Command: server info'),(726,'Command: server plimit'),(727,'Command: server restart'),(728,'Command: server restart cancel'),(729,'Command: server set'),(730,'Command: server set closed'),(731,'Command: server set difftime'),(732,'Command: server set loglevel'),(733,'Command: server set motd'),(734,'Command: server shutdown'),(735,'Command: server shutdown cancel'),(736,'Command: server motd'),(737,'Command: tele'),(738,'Command: tele add'),(739,'Command: tele del'),(740,'Command: tele name'),(741,'Command: tele group'),(742,'Command: ticket'),(743,'Command: ticket assign'),(744,'Command: ticket close'),(745,'Command: ticket closedlist'),(746,'Command: ticket comment'),(747,'Command: ticket complete'),(748,'Command: ticket delete'),(749,'Command: ticket escalate'),(750,'Command: ticket escalatedlist'),(751,'Command: ticket list'),(752,'Command: ticket onlinelist'),(753,'Command: ticket reset'),(754,'Command: ticket response'),(755,'Command: ticket response append'),(756,'Command: ticket response appendln'),(757,'Command: ticket togglesystem'),(758,'Command: ticket unassign'),(759,'Command: ticket viewid'),(760,'Command: ticket viewname'),(761,'Command: titles'),(762,'Command: titles add'),(763,'Command: titles current'),(764,'Command: titles remove'),(765,'Command: titles set'),(766,'Command: titles set mask'),(767,'Command: wp'),(768,'Command: wp add'),(769,'Command: wp event'),(770,'Command: wp load'),(771,'Command: wp modify'),(772,'Command: wp unload'),(773,'Command: wp reload'),(774,'Command: wp show'),(777,'Command: mailbox'),(778,'Command: ahbot'),(779,'Command: ahbot items'),(780,'Command: ahbot items gray'),(781,'Command: ahbot items white'),(782,'Command: ahbot items green'),(783,'Command: ahbot items blue'),(784,'Command: ahbot items purple'),(785,'Command: ahbot items orange'),(786,'Command: ahbot items yellow'),(787,'Command: ahbot ratio'),(788,'Command: ahbot ratio alliance'),(789,'Command: ahbot ratio horde'),(790,'Command: ahbot ratio neutral'),(791,'Command: ahbot rebuild'),(792,'Command: ahbot reload'),(793,'Command: ahbot status'),(794,'Command: .guild info'),(795,'Command: .instance setbossstate'),(796,'Command: instance getbossstate'),(797,'Command: pvpstats'),(798,'Command: .mod xp'),(835,'Command: debug loadcells'),(836,'Command: .debug boundary'); /*!40000 ALTER TABLE `rbac_permissions` ENABLE KEYS */; UNLOCK TABLES; @@ -486,7 +486,7 @@ CREATE TABLE `updates` ( LOCK TABLES `updates` WRITE; /*!40000 ALTER TABLE `updates` DISABLE KEYS */; -INSERT INTO `updates` VALUES ('2014_11_10_00_auth.sql','0E3CB119442D09DD88E967015319BBC8DAFBBFE0','ARCHIVED','2015-03-21 21:44:12',0),('2014_11_10_01_auth.sql','327E77A1DA3546D5275AB249915DD57EDD6FDD3D','ARCHIVED','2015-03-21 21:44:12',0),('2014_12_10_00_auth.sql','821703A96D80F9080074852B5A46E2909C9562EA','ARCHIVED','2015-03-21 21:44:12',0),('2014_12_21_00_auth.sql','CE2E5D2CD82E79C25294539ADED27A1429105B43','ARCHIVED','2015-03-21 21:44:12',0),('2015_03_20_00_auth.sql','E8C5B74BB45F0F35DEC182C72BACF435C7066FB0','ARCHIVED','2015-03-21 21:44:12',0),('2015_03_20_01_auth.sql','862961815354DA2746F5F71FBC8155F57CBE75AB','ARCHIVED','2015-03-21 21:44:12',0),('2015_03_20_02_auth.sql','33E4F94086590768EF5D4855DD43D7DE7C06ADA4','ARCHIVED','2015-03-21 21:44:51',0),('2015_08_21_00_auth.sql','C31A9E1D28E11B60BE8F8198637DD51F6D75123F','ARCHIVED','2015-10-05 23:16:19',0),('2015_11_07_00_auth.sql','BAF9F6B8F97A30D04BDBBA8127A62A1720F9B904','RELEASED','2015-11-07 15:40:47',0); +INSERT INTO `updates` VALUES ('2014_11_10_00_auth.sql','0E3CB119442D09DD88E967015319BBC8DAFBBFE0','ARCHIVED','2015-03-21 21:44:12',0),('2014_11_10_01_auth.sql','327E77A1DA3546D5275AB249915DD57EDD6FDD3D','ARCHIVED','2015-03-21 21:44:12',0),('2014_12_10_00_auth.sql','821703A96D80F9080074852B5A46E2909C9562EA','ARCHIVED','2015-03-21 21:44:12',0),('2014_12_21_00_auth.sql','CE2E5D2CD82E79C25294539ADED27A1429105B43','ARCHIVED','2015-03-21 21:44:12',0),('2015_03_20_00_auth.sql','E8C5B74BB45F0F35DEC182C72BACF435C7066FB0','ARCHIVED','2015-03-21 21:44:12',0),('2015_03_20_01_auth.sql','862961815354DA2746F5F71FBC8155F57CBE75AB','ARCHIVED','2015-03-21 21:44:12',0),('2015_03_20_02_auth.sql','33E4F94086590768EF5D4855DD43D7DE7C06ADA4','ARCHIVED','2015-03-21 21:44:51',0),('2015_08_21_00_auth.sql','C31A9E1D28E11B60BE8F8198637DD51F6D75123F','ARCHIVED','2015-10-05 23:16:19',0),('2015_11_07_00_auth.sql','BAF9F6B8F97A30D04BDBBA8127A62A1720F9B904','RELEASED','2015-11-07 15:40:47',0),('2016_01_13_00_auth.sql','24615CC69B3CD7BB4699874647C35BA86E8A93FD','RELEASED','2016-01-13 00:00:00',0); /*!40000 ALTER TABLE `updates` ENABLE KEYS */; UNLOCK TABLES; diff --git a/sql/base/characters_database.sql b/sql/base/characters_database.sql index 69c6c990e1e..02061aaf976 100644 --- a/sql/base/characters_database.sql +++ b/sql/base/characters_database.sql @@ -783,6 +783,7 @@ CREATE TABLE `character_instance` ( `guid` int(10) unsigned NOT NULL DEFAULT '0', `instance` int(10) unsigned NOT NULL DEFAULT '0', `permanent` tinyint(3) unsigned NOT NULL DEFAULT '0', + `extendState` TINYINT(2) UNSIGNED NOT NULL DEFAULT '1', PRIMARY KEY (`guid`,`instance`), KEY `instance` (`instance`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8; @@ -2539,7 +2540,7 @@ CREATE TABLE `updates` ( LOCK TABLES `updates` WRITE; /*!40000 ALTER TABLE `updates` DISABLE KEYS */; -INSERT INTO `updates` VALUES ('2015_03_20_00_characters.sql','B761760804EA73BD297F296C5C1919687DF7191C','ARCHIVED','2015-03-21 21:44:15',0),('2015_03_20_01_characters.sql','894F08B70449A5481FFAF394EE5571D7FC4D8A3A','ARCHIVED','2015-03-21 21:44:15',0),('2015_03_20_02_characters.sql','97D7BE0CAADC79F3F11B9FD296B8C6CD40FE593B','ARCHIVED','2015-03-21 21:44:51',0),('2015_06_26_00_characters_335.sql','C2CC6E50AFA1ACCBEBF77CC519AAEB09F3BBAEBC','ARCHIVED','2015-07-13 23:49:22',0),('2015_09_28_00_characters_335.sql','F8682A431D50E54BDC4AC0E7DBED21AE8AAB6AD4','ARCHIVED','2015-09-28 21:00:00',0),('2015_08_26_00_characters_335.sql','C7D6A3A00FECA3EBFF1E71744CA40D3076582374','ARCHIVED','2015-08-26 21:00:00',0),('2015_10_06_00_characters.sql','16842FDD7E8547F2260D3312F53EFF8761EFAB35','ARCHIVED','2015-10-06 16:06:38',0),('2015_10_07_00_characters.sql','E15AB463CEBE321001D7BFDEA4B662FF618728FD','ARCHIVED','2015-10-07 23:32:00',0),('2015_10_12_00_characters.sql','D6F9927BDED72AD0A81D6EC2C6500CBC34A39FA2','ARCHIVED','2015-10-12 15:35:47',0),('2015_10_28_00_characters.sql','622A9CA8FCE690429EBE23BA071A37C7A007BF8B','ARCHIVED','2015-10-19 14:32:22',0),('2015_10_29_00_characters_335.sql','4555A7F35C107E54C13D74D20F141039ED42943E','ARCHIVED','2015-10-29 17:05:43',0),('2015_11_03_00_characters.sql','CC045717B8FDD9733351E52A5302560CD08AAD57','ARCHIVED','2015-10-12 15:23:33',0),('2015_11_07_00_characters.sql','BAF9F6B8F97A30D04BDBBA8127A62A1720F9B904','RELEASED','2015-11-07 15:40:47',0); +INSERT INTO `updates` VALUES ('2015_03_20_00_characters.sql','B761760804EA73BD297F296C5C1919687DF7191C','ARCHIVED','2015-03-21 21:44:15',0),('2015_03_20_01_characters.sql','894F08B70449A5481FFAF394EE5571D7FC4D8A3A','ARCHIVED','2015-03-21 21:44:15',0),('2015_03_20_02_characters.sql','97D7BE0CAADC79F3F11B9FD296B8C6CD40FE593B','ARCHIVED','2015-03-21 21:44:51',0),('2015_06_26_00_characters_335.sql','C2CC6E50AFA1ACCBEBF77CC519AAEB09F3BBAEBC','ARCHIVED','2015-07-13 23:49:22',0),('2015_09_28_00_characters_335.sql','F8682A431D50E54BDC4AC0E7DBED21AE8AAB6AD4','ARCHIVED','2015-09-28 21:00:00',0),('2015_08_26_00_characters_335.sql','C7D6A3A00FECA3EBFF1E71744CA40D3076582374','ARCHIVED','2015-08-26 21:00:00',0),('2015_10_06_00_characters.sql','16842FDD7E8547F2260D3312F53EFF8761EFAB35','ARCHIVED','2015-10-06 16:06:38',0),('2015_10_07_00_characters.sql','E15AB463CEBE321001D7BFDEA4B662FF618728FD','ARCHIVED','2015-10-07 23:32:00',0),('2015_10_12_00_characters.sql','D6F9927BDED72AD0A81D6EC2C6500CBC34A39FA2','ARCHIVED','2015-10-12 15:35:47',0),('2015_10_28_00_characters.sql','622A9CA8FCE690429EBE23BA071A37C7A007BF8B','ARCHIVED','2015-10-19 14:32:22',0),('2015_10_29_00_characters_335.sql','4555A7F35C107E54C13D74D20F141039ED42943E','ARCHIVED','2015-10-29 17:05:43',0),('2015_11_03_00_characters.sql','CC045717B8FDD9733351E52A5302560CD08AAD57','ARCHIVED','2015-10-12 15:23:33',0),('2015_11_07_00_characters.sql','BAF9F6B8F97A30D04BDBBA8127A62A1720F9B904','RELEASED','2015-11-07 15:40:47',0),('2016_02_10_00_characters.sql','F1B4DA202819CABC7319A4470A2D224A34609E97','RELEASED','2016-02-10 00:00:00',0); /*!40000 ALTER TABLE `updates` ENABLE KEYS */; UNLOCK TABLES; diff --git a/sql/updates/auth/2016_01_13_00_auth.sql b/sql/updates/auth/2016_01_13_00_auth.sql new file mode 100644 index 00000000000..c70d4c09468 --- /dev/null +++ b/sql/updates/auth/2016_01_13_00_auth.sql @@ -0,0 +1,6 @@ +-- +DELETE FROM `rbac_permissions` WHERE `id`=836; +INSERT INTO `rbac_permissions` (`id`,`name`) VALUES (836,"Command: .debug boundary"); + +DELETE FROM `rbac_linked_permissions` WHERE `linkedId`=836; +INSERT INTO `rbac_linked_permissions` (`id`,`linkedId`) VALUES (196, 836); diff --git a/sql/updates/characters/2016_02_10_00_characters.sql b/sql/updates/characters/2016_02_10_00_characters.sql new file mode 100644 index 00000000000..d49ed155bc8 --- /dev/null +++ b/sql/updates/characters/2016_02_10_00_characters.sql @@ -0,0 +1,2 @@ +-- extend=0 is expired, extend=1 is normal, extend=2 is extended +ALTER TABLE `character_instance` ADD COLUMN `extendState` TINYINT(2) UNSIGNED NOT NULL DEFAULT '1'; diff --git a/sql/updates/world/2015_11_09_02_world335.sql b/sql/updates/world/2015_11_09_02_world_335.sql index 84c0fd423ad..84c0fd423ad 100644 --- a/sql/updates/world/2015_11_09_02_world335.sql +++ b/sql/updates/world/2015_11_09_02_world_335.sql diff --git a/sql/updates/world/2015_12_16_02_world335.sql b/sql/updates/world/2015_12_16_02_world_335.sql index 20c1ac94a39..20c1ac94a39 100644 --- a/sql/updates/world/2015_12_16_02_world335.sql +++ b/sql/updates/world/2015_12_16_02_world_335.sql diff --git a/sql/updates/world/2015_12_20_00_world.sql b/sql/updates/world/2015_12_20_00_world.sql index 51f762c5fd7..7c658877f13 100644 --- a/sql/updates/world/2015_12_20_00_world.sql +++ b/sql/updates/world/2015_12_20_00_world.sql @@ -1,5 +1,5 @@ SET @OGUID:=78976; -DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+543; +DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+544; INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES (@OGUID+0 , 187567, 530, 1, 1, -2972.565, 2562.675, 83.66947, 5.829401, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3744) (@OGUID+1 , 187567, 530, 1, 1, -2955.605, 2554.495, 110.3285, 5.846854, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3744) diff --git a/sql/updates/world/2015_12_31_00_world.sql b/sql/updates/world/2015_12_31_00_world.sql new file mode 100644 index 00000000000..b7c310323ed --- /dev/null +++ b/sql/updates/world/2015_12_31_00_world.sql @@ -0,0 +1,55 @@ +-- +SET @guid=87490; +DELETE FROM `creature` WHERE `guid` BETWEEN @guid+0 AND @guid+23; +INSERT INTO `creature` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `modelid`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `currentwaypoint`, `curhealth`, `curmana`, `MovementType`) VALUES +(@guid+0, 32262, 571, 1, 1, 0, 0, 8210.67, 2058.87, 550.78, 1.8675, 300, 0, 0, 10080, 17272, 0), +(@guid+1, 32262, 571, 1, 1, 0, 0, 8194.63, 2063.66, 550.78, 0.698132, 300, 0, 0, 10080, 17272, 0), +(@guid+2, 32262, 571, 1, 1, 0, 0, 8200.36, 2050.99, 550.78, 1.43117, 300, 0, 0, 10080, 17272, 0), +(@guid+3, 32297, 571, 1, 1, 0, 0, 8174.97, 2127.87, 499.92, 1.6057, 300, 0, 0, 10080, 17628, 0), +(@guid+4, 32297, 571, 1, 1, 0, 0, 8204.41, 2125.31, 499.837, 4.72564, 300, 0, 0, 10080, 17628, 0), +(@guid+5, 32297, 571, 1, 1, 0, 0, 8199.44, 2123.24, 499.837, 6.07577, 300, 0, 0, 10080, 17628, 0), +(@guid+6, 32297, 571, 1, 1, 0, 0, 8151.77, 2128.06, 499.92, 1.65806, 300, 0, 0, 10080, 17628, 0), +(@guid+7, 32297, 571, 1, 1, 0, 0, 8163.05, 2127.68, 499.92, 1.65806, 300, 0, 0, 10080, 17628, 0), +(@guid+8, 32297, 571, 1, 1, 0, 0, 8144.97, 2100.36, 499.92, 4.7822, 300, 0, 0, 10080, 17628, 0), +(@guid+9, 32297, 571, 1, 1, 0, 0, 8133.19, 2100.51, 499.92, 4.66003, 300, 0, 0, 10080, 17628, 0), +(@guid+10, 32297, 571, 1, 1, 0, 0, 8157.47, 2102.37, 499.92, 3.08923, 300, 0, 0, 10080, 17628, 0), +(@guid+11, 32297, 571, 1, 1, 0, 0, 8183.99, 2100.45, 499.92, 4.59022, 300, 0, 0, 10080, 17628, 0), +(@guid+12, 32297, 571, 1, 1, 0, 0, 8172.34, 2100.43, 499.92, 4.67748, 300, 0, 0, 10080, 17628, 0), +(@guid+13, 32297, 571, 1, 1, 0, 0, 8168.38, 2100.2, 499.92, 4.72984, 300, 0, 0, 10080, 17628, 0), +(@guid+14, 32297, 571, 1, 1, 0, 0, 8202.52, 2103.62, 499.92, 0.10472, 300, 0, 0, 10080, 17628, 0), +(@guid+15, 32297, 571, 1, 1, 0, 0, 8192.9, 2100.59, 499.92, 4.81711, 300, 0, 0, 10080, 17628, 0), +(@guid+16, 32297, 571, 1, 1, 0, 0, 8214, 2126.49, 499.92, 6.26573, 300, 0, 0, 10080, 17628, 0), +(@guid+17, 32297, 571, 1, 1, 0, 0, 8132.54, 2115.139, 499.837, 1.874436, 300, 0, 0, 10080, 17628, 0), +(@guid+18, 32297, 571, 1, 1, 0, 0, 8133.218, 2119.662, 499.737, 3.914777, 300, 0, 0, 10080, 17628, 0), +(@guid+19, 32297, 571, 1, 1, 0, 0, 8129.094, 2118.386, 499.737, 5.876702, 300, 0, 0, 10080, 17628, 0), +(@guid+20, 32297, 571, 1, 1, 0, 0, 8203.914, 2120.223, 499.737, 2.054170, 300, 0, 0, 10080, 17628, 0), +(@guid+21, 32297, 571, 1, 1, 0, 0, 8158.015, 2134.9663, 499.737, 4.673187, 300, 0, 0, 10080, 17628, 0), +(@guid+22, 32297, 571, 1, 1, 0, 0, 8169.999, 2134.4260, 499.737, 4.708543, 300, 0, 0, 10080, 17628, 0), +(@guid+23, 32276, 571, 1, 1, 0, 0, 8029.4, 2172.71, 499.918, 3.01942, 300, 0, 0, 12175, 0, 0); + +DELETE FROM `creature_addon` WHERE `guid` BETWEEN @guid+0 AND @guid+23; +INSERT INTO `creature_addon` (`guid`, `bytes2`, `emote`) VALUES +(@guid+0, 1, 0), +(@guid+1, 1, 0), +(@guid+2, 1, 0), +(@guid+3, 1, 69), +(@guid+4, 1, 396), +(@guid+5, 1, 396), +(@guid+6, 1, 69), +(@guid+7, 1, 69), +(@guid+8, 1, 69), +(@guid+9, 1, 69), +(@guid+10, 1, 69), +(@guid+11, 1, 69), +(@guid+12, 1, 69), +(@guid+13, 1, 69), +(@guid+14, 1, 69), +(@guid+15, 1, 69), +(@guid+16, 1, 69), +(@guid+17, 1, 396), +(@guid+18, 1, 396), +(@guid+19, 1, 396), +(@guid+20, 1, 396), +(@guid+21, 1, 69), +(@guid+22, 1, 69), +(@guid+23, 1, 0); diff --git a/sql/updates/world/2015_12_31_01_world.sql b/sql/updates/world/2015_12_31_01_world.sql new file mode 100644 index 00000000000..3bee62963ef --- /dev/null +++ b/sql/updates/world/2015_12_31_01_world.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `trinity_string` WHERE `entry`=11014; +INSERT INTO `trinity_string` (`entry`,`content_default`) VALUES +(11014,"You are already locked to %s."); diff --git a/sql/updates/world/2016_01_01_00_world.sql b/sql/updates/world/2016_01_01_00_world.sql new file mode 100644 index 00000000000..38991837113 --- /dev/null +++ b/sql/updates/world/2016_01_01_00_world.sql @@ -0,0 +1,3 @@ +-- Wretched Captive +UPDATE `waypoint_data` SET `orientation`=4.212851 WHERE `id`=586910; +UPDATE `creature` SET `orientation`=4.212851 WHERE `guid`=58691; diff --git a/sql/updates/world/2016_01_01_01_world.sql b/sql/updates/world/2016_01_01_01_world.sql new file mode 100644 index 00000000000..025f2c07f9c --- /dev/null +++ b/sql/updates/world/2016_01_01_01_world.sql @@ -0,0 +1,2 @@ +-- +DELETE FROM `spell_area` WHERE `spell` IN(46023); diff --git a/sql/updates/world/2016_01_02_00_world_335.sql b/sql/updates/world/2016_01_02_00_world_335.sql new file mode 100644 index 00000000000..b46a41bc6e9 --- /dev/null +++ b/sql/updates/world/2016_01_02_00_world_335.sql @@ -0,0 +1,20 @@ +-- Move EPL tower gryphon master to SAI +DELETE FROM `gossip_menu_option` WHERE menu_id = 7379; +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(7379, 0, 0, 'Take me to Northpass Tower.',13562,1,1,0,0,0,0,NULL,0), +(7379, 1, 0, 'Take me to Eastwall Tower.',13563,1,1,0,0,0,0,NULL,0), +(7379, 2, 0, 'Take me to Crown Guard Tower.',13564,1,1,0,0,0,0,NULL,0); + +-- Creating a new SmartAI script for [Creature] ENTRY 17209 (name: William Kielar) + +-- Table creature_template +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 17209; + +-- Table smart_scripts +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = 17209); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(17209, 0, 0, 3, 62, 0, 100, 0, 7379, 0, 0, 0, 52, 494, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'William Kielar - On Gossip Option 0 Selected - Activate Taxi Path 494'), +(17209, 0, 1, 3, 62, 0, 100, 0, 7379, 1, 0, 0, 52, 495, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'William Kielar - On Gossip Option 1 Selected - Activate Taxi Path 495'), +(17209, 0, 2, 3, 62, 0, 100, 0, 7379, 2, 0, 0, 52, 496, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'William Kielar - On Gossip Option 2 Selected - Activate Taxi Path 496'), +(17209, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'William Kielar - On Gossip Option 0 Selected - Close Gossip'); + diff --git a/sql/updates/world/2016_01_02_01_world.sql b/sql/updates/world/2016_01_02_01_world.sql new file mode 100644 index 00000000000..b862cc0e644 --- /dev/null +++ b/sql/updates/world/2016_01_02_01_world.sql @@ -0,0 +1,37 @@ +-- +-- SAI script for Wyrmrest Temple taxi Flight Paths + +SET @Tariolstrasz := 26443; +SET @Torastrasza := 26949; +SET @Afrasastrasz := 27575; + +-- Ground ----> Top: 878 (@Tariolstrasz,9455,0) +-- Ground -> Middle: 883 (@Tariolstrasz,9455,1) +-- Top ----> Ground: 879 (@Torastrasza, 9457,0) +-- Top ----> Middle: 880 (@Torastrasza, 9457,1) +-- Middle ----> Top: 881 (@Afrasastrasz,9563,0) +-- Middle -> Ground: 882 (@Afrasastrasz,9563,1) + +-- Set AIName and remove old ScriptName in creature_template for all 3 NPCs +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName`= '' WHERE `entry` IN (@Tariolstrasz,@Torastrasza,@Afrasastrasz); + +-- Tariolstrasz (Steward of Wyrmrest Temple) +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = @Tariolstrasz); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(@Tariolstrasz, 0, 0, 2, 62, 0, 100, 0, 9455, 0, 0, 0, 52, 878, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Tariolstrasz - On Gossip Option 0 Selected - Activate Taxi Path 878'), +(@Tariolstrasz, 0, 1, 2, 62, 0, 100, 0, 9455, 1, 0, 0, 52, 883, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Tariolstrasz - On Gossip Option 1 Selected - Activate Taxi Path 883'), +(@Tariolstrasz, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Tariolstrasz - On Gossip Options Selected - Close Gossip'); + +-- Torastrasza (Majordomo to the Ruling Council) +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = @Torastrasza); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(@Torastrasza, 0, 0, 2, 62, 0, 100, 0, 9457, 0, 0, 0, 52, 879, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Torastrasza - On Gossip Option 0 Selected - Activate Taxi Path 879'), +(@Torastrasza, 0, 1, 2, 62, 0, 100, 0, 9457, 1, 0, 0, 52, 880, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Torastrasza - On Gossip Option 1 Selected - Activate Taxi Path 880'), +(@Torastrasza, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Torastrasza - On Gossip Options Selected - Close Gossip'); + +-- Lord Afrasastrasz (Commander of Wyrmrest Temple Defenses) +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = @Afrasastrasz); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(@Afrasastrasz, 0, 0, 2, 62, 0, 100, 0, 9563, 0, 0, 0, 52, 881, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Lord Afrasastrasz - On Gossip Option 0 Selected - Activate Taxi Path 881'), +(@Afrasastrasz, 0, 1, 2, 62, 0, 100, 0, 9563, 1, 0, 0, 52, 882, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Lord Afrasastrasz - On Gossip Option 1 Selected - Activate Taxi Path 882'), +(@Afrasastrasz, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Lord Afrasastrasz - On Gossip Options Selected - Close Gossip'); diff --git a/sql/updates/world/2016_01_03_00_world_335.sql b/sql/updates/world/2016_01_03_00_world_335.sql new file mode 100644 index 00000000000..658b180a41a --- /dev/null +++ b/sql/updates/world/2016_01_03_00_world_335.sql @@ -0,0 +1,4 @@ +DELETE FROM `spell_script_names` WHERE `ScriptName`='spell_dru_bear_form_passive'; +INSERT INTO `spell_script_names` (`spell_id`,`ScriptName`) VALUES +(1178,'spell_dru_bear_form_passive'), +(9635,'spell_dru_bear_form_passive'); diff --git a/sql/updates/world/2016_01_03_01_world.sql b/sql/updates/world/2016_01_03_01_world.sql new file mode 100644 index 00000000000..3ddb56a9c72 --- /dev/null +++ b/sql/updates/world/2016_01_03_01_world.sql @@ -0,0 +1,26 @@ +-- +-- Sergeant Kan'ren, Wretched Captive and Novice Ranger SAI +SET @Sergeant := 16924; +SET @Captive := 16916; +SET @Ranger := 16923; + +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry` in (@Sergeant, @Captive, @Ranger); +DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@Sergeant, @Ranger, @Captive) AND `source_type`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@Sergeant*100 AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@Sergeant,0,0,0,1,0,100,0,60000,100000,100000,120000,80,@Sergeant*100,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sergeant Kan'ren - Out of Combat - Action list"), +(@Sergeant*100,9,0,0,0,0,100,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sergeant Kan'ren - Action list - Say Line 0"), +(@Sergeant*100,9,1,0,0,0,100,0,5000,5000,0,0,5,18,0,0,0,0,0,19,@Captive,10,0,0,0,0,0,"Sergeant Kan'ren - Action list - Captive Play Emote 18"), +(@Sergeant*100,9,2,0,0,0,100,0,0,0,0,0,1,0,0,0,0,0,0,19,@Captive,10,0,0,0,0,0,"Sergeant Kan'ren - Action list - Captive Say Line 0"), +(@Sergeant*100,9,3,0,0,0,100,0,8000,8000,0,0,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sergeant Kan'ren - Action list - Say Line 1"), +(@Captive,0,0,0,1,0,100,0,14000,14000,14000,14000,5,20,0,0,0,0,0,1,0,0,0,0,0,0,0,"Wretched Captive - Out of Combat - Play Emote 20"), +(@Ranger,0,0,0,1,0,100,0,50000,70000,70000,80000,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Ranger - Out of Combat - Say text"); + +UPDATE `creature` SET `movementtype`=0 WHERE `guid`=58691; +UPDATE `creature_addon` SET `path_id`=0 WHERE `guid`=58691; +DELETE FROM `waypoint_data` WHERE `id`=586910; +DELETE FROM `waypoint_scripts` WHERE `id` IN (66, 67, 68, 69, 70); + +DELETE FROM `creature_text` WHERE `entry`=@Ranger; +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`comment`,`BroadcastTextID`) VALUES +(@Ranger,0,0, 'I might just have to go hunting for that Wretched beast now that there''s a bounty on his head.',12,1,100,0,0,0, 'Ranger', 12832); diff --git a/sql/updates/world/2016_01_03_02_world.sql b/sql/updates/world/2016_01_03_02_world.sql new file mode 100644 index 00000000000..79eba012e41 --- /dev/null +++ b/sql/updates/world/2016_01_03_02_world.sql @@ -0,0 +1,9 @@ +-- Issue #16168 +-- Orbaz Bloodbane: Fix incorrect creature texts +-- By: dr-j +UPDATE `creature_text` SET `BroadcastTextId`=31961 WHERE `entry`=31283 AND `groupid`=1 AND `id`=0; +UPDATE `creature_text` SET `BroadcastTextId`=31962 WHERE `entry`=31283 AND `groupid`=2 AND `id`=0; +UPDATE `creature_text` SET `BroadcastTextId`=31963 WHERE `entry`=31283 AND `groupid`=3 AND `id`=0; +UPDATE `creature_text` SET `BroadcastTextId`=31966 WHERE `entry`=31283 AND `groupid`=4 AND `id`=0; +UPDATE `creature_text` SET `BroadcastTextId`=31967 WHERE `entry`=31283 AND `groupid`=5 AND `id`=0; +UPDATE `creature_text` SET `BroadcastTextId`=31964 WHERE `entry`=31283 AND `groupid`=6 AND `id`=0; diff --git a/sql/updates/world/2016_01_03_03_world.sql b/sql/updates/world/2016_01_03_03_world.sql new file mode 100644 index 00000000000..1b1766ee557 --- /dev/null +++ b/sql/updates/world/2016_01_03_03_world.sql @@ -0,0 +1,10 @@ +-- Betrayal (Drakuru) fixes: +-- Fix "Blight Fog" cast behavior +-- Fix "Throw Blight Crystal" cast timing +-- By: dr-j +UPDATE `smart_scripts` SET `event_param2`=7500, `event_param3`=10000, `event_param4`=20000 WHERE `entryorguid`=28998 AND `source_type`=0 AND `id`=5 AND `link`=0; + +DELETE FROM `smart_scripts` WHERE `entryorguid`=28998 AND `source_type`=0 AND `id` in(13,14); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(28998, 0, 13, 0, 0, 0, 100, 0, 0, 0, 60000, 60000, 28, 54104, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - IC - Remove Aura (Blight Fog'), +(28998, 0, 14, 0, 0, 0, 100, 0, 45000, 45000, 60000, 60000, 11, 54104, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Drakuru - IC - Cast Blight Fog'); diff --git a/sql/updates/world/2016_01_03_04_world.sql b/sql/updates/world/2016_01_03_04_world.sql new file mode 100644 index 00000000000..ffe8eb07fd5 --- /dev/null +++ b/sql/updates/world/2016_01_03_04_world.sql @@ -0,0 +1 @@ +UPDATE `creature_template` SET `faction`=2109 WHERE `entry`=30012; diff --git a/sql/updates/world/2016_01_03_05_world.sql b/sql/updates/world/2016_01_03_05_world.sql new file mode 100644 index 00000000000..4c2fe0817f0 --- /dev/null +++ b/sql/updates/world/2016_01_03_05_world.sql @@ -0,0 +1,25 @@ +-- Add sniffed gossip texts to menu +DELETE FROM `gossip_menu_option` WHERE `menu_id` IN (8095, 8096, 8100); +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(8095, 0, 2, 'Show me where I can fly.',12271,1,1,0,0,0,0,'',0), +(8096, 0, 0, 'Send me to Honor Point!',18200,1,1,0,0,0,0,'',0), +(8096, 1, 0, 'Send me to the Abyssal Shelf!',17936,1,1,0,0,0,0,'',0), +(8100, 0, 0, 'Send me to Shatter Point!',17937,1,1,0,0,0,0,'',0); + +-- Migrate NPC to use SmartAI +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '', `gossip_menu_id` = 8096 WHERE `entry` = 20235; + +-- Condition: Gossip menu ID 0 needs either quest ID 10163 or quest ID 10346 to be incomplete. +-- Condition: Gossip menu ID 1 needs quest ID 10382 to be complete +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`= 15 AND `SourceGroup` = 8096 AND `SourceEntry`IN (0,1); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(15,8096,0,0,0,9,0,10163,0,0,0,0,'','Gryphoneer Windbellow - Show gossip option 0 if player has taken quest ID 10163'), +(15,8096,0,0,1,9,0,10346,0,0,0,0,'','Gryphoneer Windbellow - Show gossip option 0 if player has taken quest ID 10346'), +(15,8096,1,0,0,28,0,10382,0,0,0,0,'','Gryphoneer Windbellow - Show gossip option 1 if quest ID 10382 is completed'); + +-- Create SmartAI for Gryphoneer Windbellow +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = 20235); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(20235,0,0,2,62,0,100,0,8096,0,0,0,11,33899,0,0,0,0,0,7,0,0,0,0,0,0,0,'Gryphoneer Windbellow - On Gossip Option 0 Selected - Cast Spell 33899'), +(20235,0,1,2,62,0,100,0,8096,1,0,0,11,35065,0,0,0,0,0,7,0,0,0,0,0,0,0,'Gryphoneer Windbellow - On Gossip Option 1 Selected - Cast Spell 35065'), +(20235,0,2,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Gryphoneer Windbellow - On Linked Actions - Close Gossip'); diff --git a/sql/updates/world/2016_01_04_00_world.sql b/sql/updates/world/2016_01_04_00_world.sql new file mode 100644 index 00000000000..57236a6f66e --- /dev/null +++ b/sql/updates/world/2016_01_04_00_world.sql @@ -0,0 +1,67 @@ +-- Vyragosa (32630) & Time-Lost Proto-Drake (32491) band-aid fix by nelegalno +SET @POOL := 60002; +SET @VYRA := 32630; +SET @TLPD := 32491; + +-- TLPD & Vyragosa set respawn to 6h (current 25 sec) +UPDATE `creature` SET `spawntimesecs`=21600 WHERE `id` IN (@VYRA,@TLPD); + +-- Remove old pool data +DELETE FROM `pool_template` WHERE `entry` IN (@VYRA,@TLPD,@POOL); +DELETE FROM `pool_creature` WHERE `pool_entry` IN (@VYRA,@TLPD,@POOL); +DELETE FROM `pool_pool` WHERE `mother_pool`=@POOL OR `pool_id` IN (@VYRA,@TLPD); + +-- Insert new pool structure +INSERT INTO `pool_template` (`entry`, `max_limit`, `description`) VALUES +(@POOL,1,"Vyragosa (32630) & Time-Lost Proto Drake (32491)"), +(@VYRA,1,"Vyragosa (32630)"), +(@TLPD,1,"Time-Lost Proto Drake (32491)"); + +INSERT INTO `pool_pool` (`pool_id`, `mother_pool`, `chance`, `description`) VALUES +(@VYRA,@POOL,80,"Vyragosa (32630)"), +(@TLPD,@POOL,20,"Time-Lost Proto Drake (32491)"); + +INSERT INTO `pool_creature` (`guid`, `pool_entry`, `chance`, `description`) VALUES +-- spawns 1-20 for both NPCs are from old pool +(202461,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 1"), +(202462,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 2"), +(202463,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 3"), +(202464,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 4"), +(202465,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 5"), +(202466,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 6"), +(202467,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 7"), +(202468,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 8"), +(202469,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 9"), +(202470,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 10"), +(202471,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 11"), +(202472,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 12"), +(202473,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 13"), +(202474,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 14"), +(202475,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 15"), +(202476,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 16"), +(202477,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 17"), +(202478,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 18"), +(202479,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 19"), +(202480,@TLPD,0,"Time-Lost Proto Drake (32491) - Spawn 20"), +(202441,@VYRA,0,"Vyragosa (32630) - Spawn 1"), +(202442,@VYRA,0,"Vyragosa (32630) - Spawn 2"), +(202443,@VYRA,0,"Vyragosa (32630) - Spawn 3"), +(202444,@VYRA,0,"Vyragosa (32630) - Spawn 4"), +(202445,@VYRA,0,"Vyragosa (32630) - Spawn 5"), +(202446,@VYRA,0,"Vyragosa (32630) - Spawn 6"), +(202447,@VYRA,0,"Vyragosa (32630) - Spawn 7"), +(202448,@VYRA,0,"Vyragosa (32630) - Spawn 8"), +(202449,@VYRA,0,"Vyragosa (32630) - Spawn 9"), +(202450,@VYRA,0,"Vyragosa (32630) - Spawn 10"), +(202451,@VYRA,0,"Vyragosa (32630) - Spawn 11"), +(202452,@VYRA,0,"Vyragosa (32630) - Spawn 12"), +(202453,@VYRA,0,"Vyragosa (32630) - Spawn 13"), +(202454,@VYRA,0,"Vyragosa (32630) - Spawn 14"), +(202455,@VYRA,0,"Vyragosa (32630) - Spawn 15"), +(202456,@VYRA,0,"Vyragosa (32630) - Spawn 16"), +(202457,@VYRA,0,"Vyragosa (32630) - Spawn 17"), +(202458,@VYRA,0,"Vyragosa (32630) - Spawn 18"), +(202459,@VYRA,0,"Vyragosa (32630) - Spawn 19"), +(202460,@VYRA,0,"Vyragosa (32630) - Spawn 20"), +-- spawned in TDB but not in the old pool +(202602,@VYRA,0,"Vyragosa (32630) - Spawn 21"); diff --git a/sql/updates/world/2016_01_05_00_world.sql b/sql/updates/world/2016_01_05_00_world.sql new file mode 100644 index 00000000000..3f7f01449fc --- /dev/null +++ b/sql/updates/world/2016_01_05_00_world.sql @@ -0,0 +1,20 @@ +DELETE FROM `spell_area` WHERE `spell` IN(52214,50735); + +INSERT INTO `spell_area` (`spell`, `area`, `quest_start`, `quest_end`, `aura_spell`, `racemask`, `gender`, `autocast`, `quest_start_status`, `quest_end_status`) VALUES +(52214, 3711, 12572, 12572, 0, 0, 2, 1, 74, 11), -- Gods Like Shiny Things +(52214, 3711, 12704, 12704, 0, 0, 2, 1, 74, 11), -- Appeasing the Great Rainstone +(50735, 3711, 12532, 12532, 0, 0, 2, 1, 74, 11), -- Flown the Coop! +(50735, 3711, 12702, 12702, 0, 0, 2, 1, 74, 11); -- Chicken Party! + +DELETE FROM `smart_scripts` WHERE `entryorguid`=28138 AND `source_type`=0 AND `id`=3 AND `link`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=28138 AND `source_type`=0 AND `id`=1 AND `link`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=28138 AND `source_type`=0 AND `id`=2 AND `link`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=28138 AND `source_type`=0 AND `id`=0 AND `link`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=28027 AND `source_type`=0 AND `id`=9 AND `link`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=28027 AND `source_type`=0 AND `id`=10 AND `link`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=28027 AND `source_type`=0 AND `id`=11 AND `link`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=28120 AND `source_type`=0 AND `id`=13 AND `link`=0; + +UPDATE `smart_scripts` SET `event_flags`=0 WHERE `entryorguid` IN(28214,28215,28216, 28120, 28121,28122,28362) AND `source_type`=0; +UPDATE `smart_scripts` SET `event_param3`=60000, `event_param4`=60000 WHERE `entryorguid`=28362 AND `source_type`=0 AND `id`=0 AND `link`=0; + diff --git a/sql/updates/world/2016_01_05_01_world.sql b/sql/updates/world/2016_01_05_01_world.sql new file mode 100644 index 00000000000..dc1064a75b9 --- /dev/null +++ b/sql/updates/world/2016_01_05_01_world.sql @@ -0,0 +1,24 @@ +-- Add gossip texts to menu +DELETE FROM `gossip_menu_option` WHERE `menu_id` = 8718; +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(8718, 0, 0, 'Yes, I''d love a ride to Blackwind Landing.',21550,1,1,0,0,0,0,'',0); + +DELETE FROM `npc_text` WHERE `ID` = 10977; +INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `BroadcastTextID0`, `lang0`, `Probability0`, `em0_0`, `em0_1`, `em0_2`, `em0_3`, `em0_4`, `em0_5`) VALUES +(10977, '', 'Hey, comrade. If you get yourself in good with the Skyguard, I can offer you a direct flight to our base, Blackwind Landing, in the Skethyl Mountains.$B$BDo you like my beautiful nether ray? It is lovely.', 21547, 0, 1, 0, 1, 0, 6, 0, 0); +-- Other npc_text (10978) is already set in DB + +-- Migrate NPC to use SmartAI +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 23413; + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` IN (14, 15) AND `SourceGroup` = 8718; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(14,8718,10977,0,0,5,0,1031,224,0,1,0,'','Skyguard Handler Irena - Show gossip menu text below Honored reputation with faction 1031'), +(14,8718,10978,0,0,5,0,1031,224,0,0,0,'','Skyguard Handler Irena - Show gossip menu text above Honored reputation with faction 1031'), +(15,8718,0,0,0,5,0,1031,224,0,0,0,'','Skyguard Handler Irena - Show gossip option 0 if player has reputation Honored or above with faction 1031'); + +-- Create SmartAI for Skyguard Handler Irena +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = 23413); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(23413,0,0,1,62,0,100,0,8718,0,0,0,11,41278,0,0,0,0,0,7,0,0,0,0,0,0,0,'Skyguard Handler Irena - On Gossip Option 0 Selected - Cast Spell 41278'), +(23413,0,1,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Skyguard Handler Irena - On Linked Actions - Close Gossip'); diff --git a/sql/updates/world/2016_01_05_02_world.sql b/sql/updates/world/2016_01_05_02_world.sql new file mode 100644 index 00000000000..64909129e60 --- /dev/null +++ b/sql/updates/world/2016_01_05_02_world.sql @@ -0,0 +1,21 @@ +-- Add gossip texts to menu +DELETE FROM `gossip_menu_option` WHERE `menu_id` = 8719; +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(8719,0,0,'Absolutely! Send me to the Skyguard Outpost.',21553,1,1,0,0,0,0,'',0); +-- This was already here but I think rather enumerate from 0 than 1 in gossip_menu_option + +-- Migrate NPC to use SmartAI +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 23415; + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` IN (14, 15) AND `SourceGroup` = 8719; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(14,8719,10980,0,0,5,0,1031,224,0,1,0,'','Skyguard Handler Deesak - Show gossip menu text below Honored reputation with faction 1031'), +(14,8719,10979,0,0,5,0,1031,224,0,0,0,'','Skyguard Handler Deesak - Show gossip menu text above Honored reputation with faction 1031'), +(15,8719,0,0,0,5,0,1031,224,0,0,0,'','Skyguard Handler Deesak - Show gossip option 0 if player has reputation Honored or above with faction 1031'); +-- Not sure if the missing condition is necessary, but it makes things a lot clearer when looking at the table. + +-- Create SmartAI for Skyguard Handler Deesak +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = 23415); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(23415,0,0,1,62,0,100,0,8719,0,0,0,11,41279,0,0,0,0,0,7,0,0,0,0,0,0,0,'Skyguard Handler Deesak - On Gossip Option 0 Selected - Cast Spell 41279'), +(23415,0,1,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Skyguard Handler Deesak - On Linked Actions - Close Gossip'); diff --git a/sql/updates/world/2016_01_07_00_world.sql b/sql/updates/world/2016_01_07_00_world.sql new file mode 100644 index 00000000000..d36dda80e50 --- /dev/null +++ b/sql/updates/world/2016_01_07_00_world.sql @@ -0,0 +1,25 @@ +-- Add sniffed gossip texts to menu +DELETE FROM `gossip_menu_option` WHERE `menu_id` = 7970; +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(7970, 0, 0, 'I''m on a bombing mission for Forward Commander Kingston. I need a gryphon destroyer!',18198,1,1,0,0,0,0,'',0), +(7970, 1, 0, 'Send me to Shatter Point!',17935,1,1,0,0,0,0,'',0); + +-- Migrate NPC to use SmartAI +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '', `gossip_menu_id` = 7970 WHERE `entry` = 19409; + +-- Condition: Gossip menu ID 0 needs either quest ID 10146 to be incomplete. +-- Condition: Gossip menu ID 1 needs quest ID 10340 to not be rewarded +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`= 15 AND `SourceGroup` = 7970 AND `SourceEntry`IN (0,1); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(15,7970,0,0,0,9,0,10146,0,0,0,0,'','Wing Commander Dabir''ee - Show gossip option 0 if player has taken quest ID 10146'), +(15,7970,1,0,0,8,0,10340,0,0,1,0,'','Wing Commander Dabir''ee - Show gossip option 1 if quest ID 10340 is not rewarded'); + +-- Create SmartAI for Wing Commander Dabir'ee +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = 19409); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(19409,0,0,2,62,0,100,0,7970,0,0,0,11,33768,0,0,0,0,0,7,0,0,0,0,0,0,0,'Wing Commander Dabir''ee - On Gossip Option 0 Selected - Cast Spell 33768'), +(19409,0,1,2,62,0,100,0,7970,1,0,0,11,35069,0,0,0,0,0,7,0,0,0,0,0,0,0,'Wing Commander Dabir''ee - On Gossip Option 1 Selected - Cast Spell 35069'), +(19409,0,2,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Wing Commander Dabir''ee - On Linked Actions - Close Gossip'); + +-- Misc creature fixes +UPDATE `creature` SET `MovementType` = 0 WHERE id = 22987 AND guid IN (79007, 79008, 79009); diff --git a/sql/updates/world/2016_01_07_01_world.sql b/sql/updates/world/2016_01_07_01_world.sql new file mode 100644 index 00000000000..4a15aa405ec --- /dev/null +++ b/sql/updates/world/2016_01_07_01_world.sql @@ -0,0 +1,2 @@ +-- +DELETE FROM `creature` WHERE `id`=22972; diff --git a/sql/updates/world/2016_01_07_02_world.sql b/sql/updates/world/2016_01_07_02_world.sql new file mode 100644 index 00000000000..7724b42ac9d --- /dev/null +++ b/sql/updates/world/2016_01_07_02_world.sql @@ -0,0 +1,2 @@ +-- fix a start-up warning +UPDATE `creature` SET `spawndist`=0 WHERE `guid` IN (79007,79008,79009); diff --git a/sql/updates/world/2016_01_08_00_world.sql b/sql/updates/world/2016_01_08_00_world.sql new file mode 100644 index 00000000000..55ed3ddf336 --- /dev/null +++ b/sql/updates/world/2016_01_08_00_world.sql @@ -0,0 +1,18 @@ +UPDATE `creature_template` SET +`spell1` = 62225, -- Claw +`spell2` = 47480, -- Thrash +`spell3` = 47481, -- Gnaw +`spell4` = 47482, -- Leap +`spell5` = 47484, -- Huddle +`spell6` = 47496 -- Explode +WHERE `entry` = 30230; + +DELETE FROM `spell_script_names` WHERE `ScriptName` IN ('spell_dk_raise_ally_initial', 'spell_dk_raise_ally', 'spell_dk_ghoul_thrash'); +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(61999, 'spell_dk_raise_ally_initial'), +(46619, 'spell_dk_raise_ally'), +(47480, 'spell_dk_ghoul_thrash'); + +DELETE FROM `spell_dbc` WHERE `Id`=62214; +INSERT INTO `spell_dbc` (`Id`,`Attributes`,`AttributesEx`,`AttributesEx2`,`AttributesEx3`,`AttributesEx4`,`AttributesEx5`,`AttributesEx6`,`DurationIndex`,`RangeIndex`,`Effect1`,`EffectImplicitTargetA1`,`EffectApplyAuraName1`,`Comment`) VALUES +(62214,0xA9800100,0x10000420,0x10084005,0x00130000,0x00800080,0x00060008,0x00001404,21,13,6,25,279,'Mirror Name'); diff --git a/sql/updates/world/2016_01_08_01_world.sql b/sql/updates/world/2016_01_08_01_world.sql new file mode 100644 index 00000000000..ebf4560d326 --- /dev/null +++ b/sql/updates/world/2016_01_08_01_world.sql @@ -0,0 +1,52 @@ +-- +SET @Oguid :=6008; +DELETE FROM `gameobject` WHERE `id`=186487; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@Oguid, 186487, 571, 1, 1, 2821.75, -3603.67, 245.555, 3.49556, 0, 0, 0.984379, -0.176061, -300, 0, 1); + +SET @CGUID := 76053; +DELETE FROM `creature_template_addon` WHERE `entry` IN (24029); +INSERT INTO `creature_template_addon` (`entry`, `mount`, `bytes1`, `bytes2`, `auras`) VALUES +(24029, 0, 0x0, 0x1, 12544); -- Wyrmcaller Vile - Frost Armor + +DELETE FROM `creature_addon` WHERE `guid` IN (@CGUID+5); +INSERT INTO `creature_addon` (`guid`, `mount`, `bytes1`, `bytes2`, `auras`) VALUES +(@CGUID+5, 0, 0x0, 0x1, 43570); -- Invisible Stalker (Floating) - Frost State + +DELETE FROM `spell_linked_spell` WHERE `spell_trigger` IN(43568,43569); +INSERT INTO `spell_linked_spell` (`spell_trigger`, `spell_effect`, `type`, `comment`) VALUES +(43568, 34872, 1, 'Frost Strike'), +(43569, 34872, 1, 'Frost trigger '); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry` IN(43568); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(13,1,43568,0,0,31,0,3,15214,0,0,0,0,'',"Spell 'Frost Strike' Effect 0 can hit 'Invisible Stalker'"); + +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID AND @CGUID+8; +INSERT INTO `creature` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `MovementType`) VALUES +(@CGUID, 15214, 571, 1, 1, 2842.762, -3599.551, 247.2563, 1.658063, 120, 0, 0), -- Invisible Stalker (Area: -Unknown-) +(@CGUID+1, 15214, 571, 1, 1, 2807.391, -3586.93, 247.6916, 3.455752, 120, 0, 0), -- Invisible Stalker (Area: -Unknown-) +(@CGUID+2, 15214, 571, 1, 1, 2833.016, -3621.016, 247.373, 1.850049, 120, 0, 0), -- Invisible Stalker (Area: -Unknown-) +(@CGUID+3, 23033, 571, 1, 1, 2831.685, -3611.948, 257.9287, 0.2479207, 120, 0, 0), -- Invisible Stalker (Floating) (Area: -Unknown-) (Auras: 43570 - Frost State) +(@CGUID+4, 23033, 571, 1, 1, 2832.849, -3638.875, 246.9362, 0.5235988, 120, 0, 0), -- Invisible Stalker (Floating) (Area: -Unknown-) +(@CGUID+5, 23033, 571, 1, 1, 2820.243, -3602.598, 261.4395, 6.161012, 120, 0, 0), -- Invisible Stalker (Floating) (Area: -Unknown-) +(@CGUID+6, 23033, 571, 1, 1, 2855.824, -3596.345, 248.4855, 5.131268, 120, 0, 0), -- Invisible Stalker (Floating) (Area: -Unknown-) +(@CGUID+7, 24029, 571, 1, 1, 2820.328, -3602.552, 247.9988, 3.665191, 120, 0, 0), -- Wyrmcaller Vile (Area: -Unknown-) (Auras: 12544 - Frost Armor) +(@CGUID+8, 23033, 571, 1, 1, 2818.341, -3604.437, 252.666, 3.845377, 120, 0, 0); -- Invisible Stalker (Floating) (Area: -Unknown-) + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=24029; +DELETE FROM `smart_scripts` WHERE `entryorguid` IN (24029,-106031,-@CGUID,-(@CGUID+1),-(@CGUID+2),-(@CGUID+5),-(@CGUID+8)) AND `source_type`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@CGUID*100,@CGUID*100+1) AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(24029,0,0,0,1,0,100,1,0,0,3000,3000,11,43576,2,0,0,0,0,1,0,0,0,0,0,0,0,'Wyrmcaller Vile - OOC - Cast \'Frost Power\''), +(24029,0,1,0,0,0,100,0,0,0,4000,4000,11,9672,0,0,0,0,0,2,0,0,0,0,0,0,0,'Wyrmcaller Vile - IC - Cast \'Frostbolt\''), +(24029,0,2,0,0,0,100,0,0,0,6000,10000,11,15532,0,0,0,0,0,2,0,0,0,0,0,0,0,'Wyrmcaller Vile - IC - Cast \'Frost Nova\''), +(24029,0,3,0,1,0,100,0,0,0,3000,3000,45,0,1,0,0,0,0,19,23033,10,0,0,0,0,0,'Wyrmcaller Vile - OOC - Cast \'Set Data\''), +(-106031,0,0,0,8,0,100,0,43568,0,0,0,80,@CGUID*100,0,0,0,0,0,1,0,0,0,0,0,0,0,'Invisible Stalker - On SpellHit \'Frost Strike\' - Call ActionList'), +(-@CGUID,0,0,0,8,0,100,0,43568,0,0,0,80,@CGUID*100,0,0,0,0,0,1,0,0,0,0,0,0,0,'Invisible Stalker - On SpellHit \'Frost Strike\' - Call ActionList'), +(-(@CGUID+1),0,0,0,8,0,100,0,43568,0,0,0,80,@CGUID*100,0,0,0,0,0,1,0,0,0,0,0,0,0,'Invisible Stalker - On SpellHit \'Frost Strike\' - Call ActionList'), +(-(@CGUID+2),0,0,0,8,0,100,0,43568,0,0,0,80,@CGUID*100+1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Invisible Stalker - On SpellHit \'Frost Strike\' - Call ActionList'), +(@CGUID*100,9,0,0,0,0,100,0,2400,2400,0,0,11,43569,2,0,0,0,0,19,23033,19,0,0,0,0,0,'Invisible Stalker - Action list - Cast \'Frost\''), +(@CGUID*100+1,9,0,0,0,0,100,0,2400,2400,0,0,11,43569,2,0,0,0,0,10,@CGUID+4,23033,0,0,0,0,0,'Invisible Stalker - Action list - Cast \'Frost\''), +(-(@CGUID+5),0,0,0,1,0,100,0,0,0,5000,7000,11,43591,2,0,0,0,0,19,24029,16,0,0,0,0,0,'Invisible Stalker - OOC - Cast \'Soul Siphon\''), +(-(@CGUID+8),0,0,0,38,0,100,0,0,1,0,0,11,43568,2,0,0,0,0,1,0,0,0,0,0,0,0,'Invisible Stalker - On data set - Cast \'Frost Strike\''); diff --git a/sql/updates/world/2016_01_08_02_world.sql b/sql/updates/world/2016_01_08_02_world.sql new file mode 100644 index 00000000000..28e55dfba3b --- /dev/null +++ b/sql/updates/world/2016_01_08_02_world.sql @@ -0,0 +1,35 @@ +-- +DELETE FROM `creature_formations` WHERE `leaderGUID`=79010; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`, `point_1`, `point_2`) VALUES +(79010, 79010, 0, 0, 2, 0, 0), +(79010, 79012, 6, 360, 2, 0, 0); + +-- Pathing for Entry: 22987 'TDB FORMAT' +SET @NPC := 79010; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-3376.641,`position_y`=3642.897,`position_z`=285.1084 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-3376.641,3642.897,285.1084,0,0,0,0,100,0), -- 00:15:15 +(@PATH,2,-3372.496,3645.907,284.7475,0,0,0,0,100,0), -- 00:15:16 +(@PATH,3,-3376.866,3642.62,285.2078,0,0,0,0,100,0), -- 00:15:22 +(@PATH,4,-3381.402,3626.403,279.4974,0,0,0,0,100,0), -- 00:15:26 +(@PATH,5,-3382.558,3624.162,278.2544,0,0,0,0,100,0), -- 00:15:31 +(@PATH,6,-3385.898,3620.779,276.7867,0,0,0,0,100,0), -- 00:15:33 +(@PATH,7,-3389.558,3619.429,276.3516,0,0,0,0,100,0), -- 00:15:35 +(@PATH,8,-3393.407,3613.085,276.4259,0,0,0,0,100,0), -- 00:15:38 +(@PATH,9,-3390.018,3604.891,276.2281,0,0,0,0,100,0), -- 00:15:41 +(@PATH,10,-3397.005,3597.193,277.0055,0,0,0,0,100,0), -- 00:15:44 +(@PATH,11,-3393.93,3598.741,276.5433,0,0,0,0,100,0), -- 00:15:48 +(@PATH,12,-3390.969,3600.254,276.3882,0,0,0,0,100,0), -- 00:15:50 +(@PATH,13,-3389.908,3605.303,276.3074,0,0,0,0,100,0), -- 00:15:51 +(@PATH,14,-3390.732,3618.796,276.4376,0,0,0,0,100,0), -- 00:15:55 +(@PATH,15,-3384.879,3620.886,277.2273,0,0,0,0,100,0), -- 00:15:58 +(@PATH,16,-3382.095,3624.67,278.3322,0,0,0,0,100,0), -- 00:16:01 +(@PATH,17,-3381.752,3635.601,284.2187,0,0,0,0,100,0), -- 00:16:03 +(@PATH,18,-3379.75,3638.496,285.585,0,0,0,0,100,0), -- 00:16:08 +(@PATH,19,-3376.617,3642.928,285.1052,0,0,0,0,100,0), -- 00:16:12 +(@PATH,20,-3372.458,3645.933,284.7447,0,0,0,0,100,0); -- 00:16:13 +-- 0x1C011842401672C000002500008BC617 .go -3376.641 3642.897 285.1084 diff --git a/sql/updates/world/2016_01_08_03_world.sql b/sql/updates/world/2016_01_08_03_world.sql new file mode 100644 index 00000000000..2899c6e06eb --- /dev/null +++ b/sql/updates/world/2016_01_08_03_world.sql @@ -0,0 +1,3 @@ +-- +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=25968; +DELETE FROM `creature` WHERE `id`=25801; diff --git a/sql/updates/world/2016_01_09_00_world.sql b/sql/updates/world/2016_01_09_00_world.sql new file mode 100644 index 00000000000..534e17ccb00 --- /dev/null +++ b/sql/updates/world/2016_01_09_00_world.sql @@ -0,0 +1,16 @@ +-- +-- Enable Landmine Knockback Achievement by removing it from disables +DELETE FROM `disables` WHERE `sourceType`= 4 AND `entry`= 5258; + +-- Insert missing Landmine Knockback Achievement criteria data +DELETE FROM `achievement_criteria_data` WHERE `criteria_id`= 5258; +INSERT INTO `achievement_criteria_data` (`criteria_id`, `type`, `value1`, `value2`, `ScriptName`) VALUES +(5258,0,57064,0,''); + +-- Update description for the linked spells 54355 and 54402 +UPDATE `spell_linked_spell` SET `comment`= 'Trigger Detonation with Land Mine Knockback' WHERE `spell_trigger` = 54355; + +-- Insert spell script name for spell 57099 +DELETE FROM `spell_script_names` WHERE `ScriptName`='spell_gen_landmine_knockback_achievement'; +INSERT INTO `spell_script_names` (`spell_id`,`ScriptName`) VALUES +(57099,'spell_gen_landmine_knockback_achievement'); diff --git a/sql/updates/world/2016_01_10_00_world.sql b/sql/updates/world/2016_01_10_00_world.sql new file mode 100644 index 00000000000..83ed21c8489 --- /dev/null +++ b/sql/updates/world/2016_01_10_00_world.sql @@ -0,0 +1,3 @@ +-- +UPDATE `creature_text` SET `text`='Windroc Matriarch lets loose a terrifying shriek.', `BroadcastTextId`=16149 WHERE `entry`=19055; +UPDATE `smart_scripts` SET `action_type`=49, `action_param1`=0 WHERE `entryorguid`=1905500 AND `id`=3; diff --git a/sql/updates/world/2016_01_10_01_world.sql b/sql/updates/world/2016_01_10_01_world.sql new file mode 100644 index 00000000000..c79c157a1a1 --- /dev/null +++ b/sql/updates/world/2016_01_10_01_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `unit_flags`=32832 WHERE `entry`= 18689; diff --git a/sql/updates/world/2016_01_10_02_world.sql b/sql/updates/world/2016_01_10_02_world.sql new file mode 100644 index 00000000000..eca8ef07849 --- /dev/null +++ b/sql/updates/world/2016_01_10_02_world.sql @@ -0,0 +1,6 @@ +-- +UPDATE `creature_template` SET `AIName`='SmartAI', `ScriptName`='' WHERE `entry`=25623; +DELETE FROM `smart_scripts` WHERE `entryorguid`=25623 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(25623, 0, 0, 0, 0, 0, 100, 0, 3000, 5000, 4000, 6000, 11, 54185, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Harvest Collector - IC - Cast Claw Slash'), +(25623, 0, 1, 0, 8, 0, 100, 0, 47166, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Harvest Collector - On spell hit - Despawn'); diff --git a/sql/updates/world/2016_01_10_03_world.sql b/sql/updates/world/2016_01_10_03_world.sql new file mode 100644 index 00000000000..5ac352ffe10 --- /dev/null +++ b/sql/updates/world/2016_01_10_03_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `smart_scripts` SET `action_param6`=2 WHERE `entryorguid`=-96556 AND `id`=0 AND `source_type`=0; diff --git a/sql/updates/world/2016_01_10_04_world.sql b/sql/updates/world/2016_01_10_04_world.sql new file mode 100644 index 00000000000..da6eed191ad --- /dev/null +++ b/sql/updates/world/2016_01_10_04_world.sql @@ -0,0 +1,11 @@ +-- +DELETE FROM `instance_template` WHERE `map` = 169; +INSERT INTO `instance_template` (`map`, `parent`, `script`, `allowMount`) VALUES +(169, 0, '', 0); + +DELETE FROM `game_tele` WHERE `id` IN (1425, 1426, 1427, 1428); +INSERT INTO `game_tele` (`id`, `position_x`, `position_y`, `position_z`, `orientation`, `map`, `name`) VALUES +(1425, -366.091, 3097.86, 92.317, 0.0487625, 169, 'EmeraldDream'), +(1426, 2781.566406, 3006.763184, 23.221882, 0.5, 169, 'EmeraldStatue'), +(1427, -2128.12, -1005.89, 132.213, 0.5, 169, 'VerdantFields'), +(1428, 2732.93, -3319.63, 101.284, 0.5, 169, 'EmeraldForest'); diff --git a/sql/updates/world/2016_01_10_05_world_335.sql b/sql/updates/world/2016_01_10_05_world_335.sql new file mode 100644 index 00000000000..7fb021cc9dd --- /dev/null +++ b/sql/updates/world/2016_01_10_05_world_335.sql @@ -0,0 +1,21 @@ +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` IN (19,20) AND `SourceEntry` IN (5066,5090,5091,5093,5094,5095,10373,10374); + +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(19, 0, 5066, 0, 0, 14, 0, 5092, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(20, 0, 5066, 0, 0, 14, 0, 5092, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(19, 0, 5090, 0, 0, 14, 0, 5092, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(20, 0, 5090, 0, 0, 14, 0, 5092, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(19, 0, 5091, 0, 0, 14, 0, 5092, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(20, 0, 5091, 0, 0, 14, 0, 5092, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(19, 0, 5093, 0, 0, 14, 0, 5096, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(20, 0, 5093, 0, 0, 14, 0, 5096, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(19, 0, 5094, 0, 0, 14, 0, 5096, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(20, 0, 5094, 0, 0, 14, 0, 5096, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(19, 0, 5095, 0, 0, 14, 0, 5096, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(20, 0, 5095, 0, 0, 14, 0, 5096, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(19, 0, 10373, 0, 0, 14, 0, 5092, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(20, 0, 10373, 0, 0, 14, 0, 5092, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(19, 0, 10374, 0, 0, 14, 0, 5096, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'), +(20, 0, 10374, 0, 0, 14, 0, 5096, 0, 0, 0, 0, 0, '', 'Call to Arms: The Plaguelands (Breadcrumb)'); + +UPDATE `quest_template_addon` SET `NextQuestID`=0 WHERE `ID` IN (5066,5090,5091,5093,5094,5095,10373,10374); diff --git a/sql/updates/world/2016_01_12_00_world.sql b/sql/updates/world/2016_01_12_00_world.sql new file mode 100644 index 00000000000..8ed4099450b --- /dev/null +++ b/sql/updates/world/2016_01_12_00_world.sql @@ -0,0 +1,125 @@ +-- Susurrus +-- Add sniffed gossip text to menu +DELETE FROM `gossip_menu_option` WHERE `menu_id` = 7415; +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(7415, 0, 0, 'I am ready to be flown down to the Exodar.',14010,1,1,0,0,0,0,'',0); + +DELETE FROM `npc_text` WHERE `ID` = 8955; +INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `BroadcastTextID0`, `lang0`, `Probability0`, `em0_0`, `em0_1`, `em0_2`, `em0_3`, `em0_4`, `em0_5`) VALUES +(8955, 'Are you ready, $n?', '', 14012, 0, 1, 0, 0, 0, 0, 0, 0); + +-- Set second gossip in gossip menu +DELETE FROM `gossip_menu` WHERE `entry` = 7415; +INSERT INTO `gossip_menu` (`entry`, `text_id`) VALUES +(7415, 8954), +(7415, 8955); + +-- Migrate NPC to use SmartAI +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 17435; + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` IN (14, 15) AND `SourceGroup` = 7415; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(14,7415,8954,0,0,2,0,23843,1,0,1,0,'','Susurrus - Show gossip menu text if player does not have item 23843 in inventory'), +(14,7415,8955,0,0,2,0,23843,1,0,0,0,'','Susurrus - Show gossip menu text if player has item 23843 in inventory'), +(15,7415,0,0,0,2,0,23843,1,0,0,0,'','Susurrus - Show gossip option 0 if player has item 23843 in inventory'); + +-- Create SmartAI for Susurrus +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = 17435); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(17435,0,0,1,62,0,100,0,7415,0,0,0,11,32474,0,0,0,0,0,7,0,0,0,0,0,0,0,'Susurrus - On Gossip Option 0 Selected - Cast Spell 32474'), +(17435,0,1,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Susurrus - On Linked Actions - Close Gossip'); + + +-- Protectorate Nether Drake +-- Add sniffed gossip text to menu +DELETE FROM `gossip_menu_option` WHERE `menu_id` = 8229; +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(8229, 0, 0, 'I''m ready to fly! Take me up, dragon!',18637,1,1,0,0,0,0,'',0); + +-- Migrate NPC to use SmartAI +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 20903; + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` = 15 AND `SourceGroup` = 8229; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(15,8229,0,0,0,2,0,29778,1,0,0,0,'','Protectorate Nether Drake - Show gossip option 0 if player has item 23843 in inventory'), +(15,8229,0,0,0,9,0,10438,0,0,0,0,'','Protectorate Nether Drake - Show gossip option 0 if player has quest 10438'); +-- Create SmartAI for Protectorate Nether Drake +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = 20903); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(20903,0,0,1,62,0,100,0,8229,0,0,0,52,627,0,0,0,0,0,7,0,0,0,0,0,0,0,'Protectorate Nether Drake - On Gossip Option 0 Selected - Init Taxi Path 627'), +(20903,0,1,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Protectorate Nether Drake - On Linked Actions - Close Gossip'); + + +-- Veronia +-- Add sniffed gossip text to menu +DELETE FROM `gossip_menu_option` WHERE `menu_id` = 8082; +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(8082, 0, 0, 'I''m as ready as I''ll ever be.',17761,1,1,0,0,0,0,'',0); + +DELETE FROM `gossip_menu` WHERE `entry` = 8082; +INSERT INTO `gossip_menu` (`entry`, `text_id`) VALUES +(8082, 9989), +(8082, 9990); + +-- Migrate NPC to use SmartAI +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 20162; + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` IN (14,15) AND `SourceGroup` = 8082; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(14,8082,9989,0,0,28,0,10652,0,0,1,0,'','Veronia - Show gossip menu text if player does not have quest 10652'), +(14,8082,9990,0,0,28,0,10652,0,0,0,0,'','Veronia - Show gossip menu text if player has quest 10652'), +(15,8082,0,0,0,28,0,10652,0,0,0,0,'','Veronia - Show gossip option 0 if player has quest 10652'); +-- Create SmartAI for Veronia +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = 20162); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(20162,0,0,1,62,0,100,0,8082,0,0,0,85,34905,0,0,0,0,0,7,0,0,0,0,0,0,0,'Veronia - On Gossip Option 0 Selected - Invoker Cast \'Stealth Flight\''), +(20162,0,1,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Veronia - On Linked Actions - Close Gossip'); + + +-- Cassa Crimsonwing +-- Add sniffed gossip text to menu +DELETE FROM `gossip_menu_option` WHERE `menu_id` = 8782; +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(8782, 0, 0, 'Lady Jaina told me to speak to you about using a gryphon to survey Alcaz Island.',22176,1,1,0,0,0,0,'',0); + +-- Migrate NPC to use SmartAI +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 23704; + +-- Condition: Gossip menu ID 0 needs quest ID 11142 to be incomplete. +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`= 15 AND `SourceGroup` = 8782 AND `SourceEntry` = 0; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(15,8782,0,0,0,9,0,11142,0,0,0,0,'','Cassa Crimsonwing - Show gossip option 0 if player has taken quest ID 11142'); + +-- Create SmartAI for Cassa Crimsonwing +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = 23704); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(23704,0,0,1,62,0,100,0,8782,0,0,0,11,42295,0,0,0,0,0,7,0,0,0,0,0,0,0,'Cassa Crimsonwing - On Gossip Option 0 Selected - Cast Spell 42295'), +(23704,0,1,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Cassa Crimsonwing - On Linked Actions - Close Gossip'); + + +-- Brazen +-- Add sniffed gossip text to menu +DELETE FROM `gossip_menu_option` WHERE `menu_id` = 7959; +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(7959, 0, 0, 'I''m ready to go to Durnholde Keep.',16461,1,1,0,0,0,0,'',0); + +DELETE FROM `gossip_menu` WHERE `entry` = 7959; +INSERT INTO `gossip_menu` (`entry`, `text_id`) VALUES +(7959, 9779), +(7959, 9780); + +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName` = '' WHERE `entry` = 18725; + +-- Condition: On gossip menu click, if item exists, perform linked action +-- Condition: On gossip menu click, if item exists, perform linked action +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`IN (14, 15) AND `SourceGroup` = 7959; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(14,7959,9779,0,0,2,0,25853,1,0,0,0,'','Brazen - Show gossip menu text if player has item 25853'), +(14,7959,9780,0,0,2,0,25853,1,0,1,0,'','Brazen - Show gossip menu text if player does not have item 25853'), +(15,7959,0,0,0,2,0,25853,1,0,0,0,'','Brazen - Show gossip option 0 if player has item 25853'); + +-- Create SmartAI for Brazen +DELETE FROM `smart_scripts` WHERE (source_type = 0 AND entryorguid = 18725); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(18725,0,0,1,62,0,100,0,7959,0,0,0,52,534,0,0,0,0,0,7,0,0,0,0,0,0,0,'Brazen - On Gossip Option 0 Selected - Activate Taxi Path 534'), +(18725,0,1,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Brazen - On Linked Actions - Close Gossip'); diff --git a/sql/updates/world/2016_01_12_01_world_335.sql b/sql/updates/world/2016_01_12_01_world_335.sql new file mode 100644 index 00000000000..c3206e70ac4 --- /dev/null +++ b/sql/updates/world/2016_01_12_01_world_335.sql @@ -0,0 +1,5 @@ +-- Insert missing gossip_menu_option 21213 for Sorcerer Ashcrombe and 21214 for Deathstalker Adamant: +DELETE FROM `gossip_menu_option` WHERE `menu_id` IN (21213,21214) AND `OptionBroadcastTextID`= 2802; +INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`,`BoxBroadcastTextID`) VALUES +(21213,0,0,'Please unlock the courtyard door.',2802,1,1,0,0,0,0,'',0), +(21214,0,0,'Please unlock the courtyard door.',2802,1,1,0,0,0,0,'',0); diff --git a/sql/updates/world/2016_01_12_02_world_335.sql b/sql/updates/world/2016_01_12_02_world_335.sql new file mode 100644 index 00000000000..354d0bc129d --- /dev/null +++ b/sql/updates/world/2016_01_12_02_world_335.sql @@ -0,0 +1,4 @@ +-- Insert missing gossip_menu_option 3801 for Myranda the Hag: +DELETE FROM `gossip_menu_option` WHERE `menu_id`= 3801 AND `OptionBroadcastTextID`= 7306; +INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`,`BoxBroadcastTextID`) VALUES +(3801,0,0,'I am ready for the illusion, Myranda.',7306,2,3,0,0,0,0,'',0); diff --git a/sql/updates/world/2016_01_12_03_world.sql b/sql/updates/world/2016_01_12_03_world.sql new file mode 100644 index 00000000000..6ff3a769918 --- /dev/null +++ b/sql/updates/world/2016_01_12_03_world.sql @@ -0,0 +1,15 @@ +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=32820; +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=32820; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(32820,0,0,0,6,0,100,0,0,0,0,0,11,62014,2,0,0,0,0,7,0,0,0,0,0,0,0,"Wild Turkey - On Just Died - Cast 'Turkey Tracker'"); + +DELETE FROM `creature_text` WHERE `entry`=32820; +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`BroadcastTextId`,`TextRange`,`comment`) VALUES +(32820,0,0,'Turkey Hunter!',42,0,100,0,0,0,33163,0,'Wild Turkey'), +(32820,1,0,'Turkey Domination!',42,0,100,0,0,0,33164,0,'Wild Turkey'), +(32820,2,0,'Turkey Slaughter!',42,0,100,0,0,0,33165,0,'Wild Turkey'), +(32820,3,0,'TURKEY TRIUMPH!',42,0,100,0,0,0,33167,0,'Wild Turkey'); + +DELETE FROM `spell_script_names` WHERE `ScriptName`='spell_pilgrims_bounty_turkey_tracker'; +INSERT INTO `spell_script_names` (`spell_id`,`ScriptName`) VALUES +(62014,'spell_pilgrims_bounty_turkey_tracker'); diff --git a/sql/updates/world/2016_01_12_04_world.sql b/sql/updates/world/2016_01_12_04_world.sql new file mode 100644 index 00000000000..7cee9220060 --- /dev/null +++ b/sql/updates/world/2016_01_12_04_world.sql @@ -0,0 +1,14 @@ +SET @OGUID:=79521; +SET @CGUID:=52265; +SET @Event:=2; + +DELETE FROM `gameobject` WHERE `guid` IN (@OGUID+0); +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0, 187567, 530, 1, 1, -690.7932, 2724.943, 100.9289, 6.265733, 0, 0, 0, 1, 120, 255, 1); -- 187567 (Area: 3483) + +DELETE FROM `game_event_gameobject` WHERE `guid` IN (@OGUID+0); +INSERT INTO `game_event_gameobject` (`eventEntry`, `guid`) VALUES +(@Event, @OGUID+0); + +DELETE FROM `game_event_creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+4 AND `eventEntry`=@Event; +INSERT INTO `game_event_creature` SELECT @Event, creature.guid FROM `creature` WHERE creature.guid BETWEEN @CGUID+0 AND @CGUID+4; diff --git a/sql/updates/world/2016_01_13_00_world.sql b/sql/updates/world/2016_01_13_00_world.sql new file mode 100644 index 00000000000..cba5d3a18a1 --- /dev/null +++ b/sql/updates/world/2016_01_13_00_world.sql @@ -0,0 +1,10 @@ +-- +DELETE FROM `command` WHERE `permission`=836; +INSERT INTO `command` (`name`,`permission`,`help`) VALUES ("debug boundary",836,"Syntax: .debug boundary [fill] [duration] +Flood fills the targeted unit's movement boundary and marks the edge of said boundary with debug creatures.\nSpecify 'fill' as first parameter to fill the entire area with debug creatures."); + +DELETE FROM `trinity_string` WHERE `entry` IN (11011,11012,11013); +INSERT INTO `trinity_string` (`entry`,`content_default`) VALUES +(11011,"VisualizeBoundary warning: No interior point of the creature's boundary could be found - check if you have mutually exclusive boundaries!"), +(11012,"VisualizeBoundary error: Creature movement is unbounded"), +(11013,"VisualizeBoundary warning: Reached fail-safe flood boundary - check is your boundary is unbounded!"); diff --git a/sql/updates/world/2016_01_15_00_world.sql b/sql/updates/world/2016_01_15_00_world.sql new file mode 100644 index 00000000000..b5f3da2dd99 --- /dev/null +++ b/sql/updates/world/2016_01_15_00_world.sql @@ -0,0 +1,29 @@ +-- +SET @GUID := 52323; +SET @pool_id := 1107; + +DELETE FROM `creature` WHERE `guid` BETWEEN @GUID AND @GUID+3; +INSERT INTO `creature` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`modelid`,`equipment_id`,`position_x`,`position_y`,`position_z`,`orientation`,`spawntimesecs`,`spawndist`,`curhealth`,`curmana`,`MovementType`) VALUES +(@GUID+0, 18684, 530, 1, 1, 0, 0, -1768.23, 6737.47, -21.3348, 6.18901, 28800, 15, 9784, 5692, 1), +(@GUID+1, 18684, 530, 1, 1, 0, 0, -2585.25, 6416.29, 26.8608, 5.44446, 28800, 15, 9784, 5692, 1), +(@GUID+2, 18684, 530, 1, 1, 0, 0, -2002.52, 7622.98, -88.0942, 5.61332, 28800, 15, 9784, 5692, 1), +(@GUID+3, 18684, 530, 1, 1, 0, 0, -1200.42, 8810.52, 41.1305, 4.35118, 28800, 15, 9784, 5692, 1); + +DELETE FROM `pool_template` WHERE `entry` = @pool_id; +INSERT INTO `pool_template` (`entry`, `max_limit`, `description`) VALUES +(@pool_id, 1, 'Bro''Gaz the Clanless'); + +DELETE FROM `pool_creature` WHERE `guid` BETWEEN @GUID AND @GUID+3; +INSERT INTO `pool_creature` (`guid`, `pool_entry`, `chance`, `description`) VALUES +(@GUID+0, @pool_id, 0, 'Bro''Gaz the Clanless - Spawn 1'), +(@GUID+1, @pool_id, 0, 'Bro''Gaz the Clanless - Spawn 2'), +(@GUID+2, @pool_id, 0, 'Bro''Gaz the Clanless - Spawn 3'), +(@GUID+3, @pool_id, 0, 'Bro''Gaz the Clanless - Spawn 4'); + +SET @ENTRY := 18684; +UPDATE `creature_template` SET `AIName`='SmartAI', `unit_flags`=0 WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=@ENTRY; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,0,0,100,0,2000,7000,10000,16000,11,12468,0,0,0,0,0,2,0,0,0,0,0,0,0,'Bro''Gaz the Clanless - IC - Cast Flamestrike'), +(@ENTRY,0,1,0,0,0,100,0,8000,11000,12000,15000,11,15586,0,0,0,0,0,1,0,0,0,0,0,0,0,'Bro''Gaz the Clanless IC - Cast heal'), +(@ENTRY,0,2,0,0,0,100,0,6000,10000,9000,10000,11,12555,0,0,0,0,0,2,0,0,0,0,0,0,0,'Bro''Gaz the Clanless IC - Cast Pummel'); diff --git a/sql/updates/world/2016_01_16_00_world_335.sql b/sql/updates/world/2016_01_16_00_world_335.sql new file mode 100644 index 00000000000..14362432555 --- /dev/null +++ b/sql/updates/world/2016_01_16_00_world_335.sql @@ -0,0 +1,5 @@ +-- +UPDATE `creature` SET `phaseMask`=1 WHERE `id` IN (25328,31105) AND `guid` IN (26169,68282); +UPDATE `creature` SET `phaseMask`=16 WHERE `id` IN (38421, 37950); +UPDATE `creature` SET `phaseMask`=64 WHERE `id` IN (31314, 30698, 31306, 31428); +UPDATE `creature` SET `phaseMask`=255 WHERE `phaseMask` =131; diff --git a/sql/updates/world/2016_01_16_01_world.sql b/sql/updates/world/2016_01_16_01_world.sql new file mode 100644 index 00000000000..235378a7a84 --- /dev/null +++ b/sql/updates/world/2016_01_16_01_world.sql @@ -0,0 +1,3 @@ +-- +DELETE FROM `npc_text` WHERE `ID` = 10884; +DELETE FROM `gossip_menu` WHERE `entry`=8441 AND `text_id`=10884; diff --git a/sql/updates/world/2016_01_16_02_world.sql b/sql/updates/world/2016_01_16_02_world.sql new file mode 100644 index 00000000000..b36d7d69ff6 --- /dev/null +++ b/sql/updates/world/2016_01_16_02_world.sql @@ -0,0 +1,7 @@ +-- +DELETE FROM `creature_template_addon` WHERE `entry` IN (16525); +INSERT INTO `creature_template_addon` (`entry`, `bytes2`, `auras`) VALUES +(16525, 1, '29920'); + +UPDATE `smart_scripts` SET `event_chance`=100 WHERE `entryorguid`=16525 AND `source_type`=0; +UPDATE `smart_scripts` SET `event_flags`=3, `event_param1`=0, `event_param2`=0, `event_param3`=0, `event_param4`=0, `action_type`=28, `comment`="Spell Shade - In Combat - Remove Aura 'Phasing Invisibility' (Normal Dungeon)" WHERE `entryorguid`=16525 AND `source_type`=0 AND `id`=3; diff --git a/sql/updates/world/2016_01_16_03_world.sql b/sql/updates/world/2016_01_16_03_world.sql new file mode 100644 index 00000000000..5a06cfaecca --- /dev/null +++ b/sql/updates/world/2016_01_16_03_world.sql @@ -0,0 +1,11 @@ +-- +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=29333; +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=29333; +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid` IN (29329, 29330, 29338) AND `id`=2; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(29329,0,2,0,8,0,100,0,52741,0,0,0,41,1000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Onslaught Paladin - On spell hit "Darkmender''s Tincture" - Despawn'), +(29330,0,2,0,8,0,100,0,52741,0,0,0,41,1000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Onslaught Harbor Guard - On spell hit "Darkmender''s Tincture" - Despawn'), +(29338,0,2,0,8,0,100,0,52741,0,0,0,41,1000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Raven Bishop - On spell hit "Darkmender''s Tincture" - Despawn'), +(29333,0,0,0,8,0,100,0,52741,0,0,0,41,1000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Onslaught Gryphon Rider - On spell hit "Darkmender''s Tincture" - Despawn'); + +UPDATE `spell_scripts` SET `datalong2`=2, `dataint`=0 WHERE `id`=52741 AND `command`=15; diff --git a/sql/updates/world/2016_01_16_04_world.sql b/sql/updates/world/2016_01_16_04_world.sql new file mode 100644 index 00000000000..a6bb7ae185c --- /dev/null +++ b/sql/updates/world/2016_01_16_04_world.sql @@ -0,0 +1,3 @@ +DELETE FROM `spell_script_names` WHERE `spell_id`=53651; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(53651, 'spell_pal_light_s_beacon'); diff --git a/sql/updates/world/2016_01_16_05_world.sql b/sql/updates/world/2016_01_16_05_world.sql new file mode 100644 index 00000000000..46511cb0de8 --- /dev/null +++ b/sql/updates/world/2016_01_16_05_world.sql @@ -0,0 +1,32 @@ +-- +SET @guid=87572; +DELETE FROM `creature` WHERE `guid` BETWEEN 87572 AND 87592; +INSERT INTO `creature` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `modelid`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `curhealth`) VALUES +(@Guid+0, 23008, 530, 1, 1, 0, 0, 3647.45, 1918.92, 118.17, 3.80525, 600, 0, 13285), +(@Guid+1, 23008, 530, 1, 1, 0, 0, 3600.99, 1898.07, 111.36, 4.56316, 600, 0, 13285), +(@Guid+2, 23008, 530, 1, 1, 0, 0, 3573.03, 1861.43, 108.895, 2.74103, 600, 0, 13285), +(@Guid+3, 23008, 530, 1, 1, 0, 0, 3669.82, 1815.83, 126.059, 6.17322, 600, 0, 13285), +(@Guid+4, 23008, 530, 1, 1, 0, 0, 3685.04, 1772.15, 130.008, 5.97294, 600, 0, 13285), +(@Guid+5, 23008, 530, 1, 1, 0, 0, 3718.62, 1728.71, 138.644, 5.75303, 600, 0, 13285), +(@Guid+6, 23008, 530, 1, 1, 0, 0, 3770.45, 1704.41, 149.751, 4.0016, 600, 0, 13285), +(@Guid+7, 23008, 530, 1, 1, 0, 0, 3793.48, 1638.27, 135.625, 0.0691063, 600, 0, 13285), +(@Guid+8, 23008, 530, 1, 1, 0, 0, 3805.98, 1573.23, 118.196, 1.39643, 600, 0, 13285), +(@Guid+9, 23008, 530, 1, 1, 0, 0, 3835.62, 1614.66, 127.926, 1.56529, 600, 0, 13285), +(@Guid+10, 23008, 530, 1, 1, 0, 0, 3894.74, 1649.2, 127.552, 4.65976, 600, 0, 13285), +(@Guid+11, 23008, 530, 1, 1, 0, 0, 3930.28, 1647.93, 126.538, 0.685644, 600, 0, 13285), +(@Guid+12, 23008, 530, 1, 1, 0, 0, 4057.55, 1698.7, 136.879, 4.81684, 600, 0, 13285), +(@Guid+13, 23008, 530, 1, 1, 0, 0, 4097.41, 1710.19, 137.963, 0.756329, 600, 0, 13285), +(@Guid+14, 23008, 530, 1, 1, 0, 0, 4123.97, 1661.08, 126.587, 0.316505, 600, 0, 13285), +(@Guid+15, 23008, 530, 1, 1, 0, 0, 4162.44, 1671.21, 116.169, 1.18437, 600, 0, 13285), +(@Guid+16, 23008, 530, 1, 1, 0, 0, 4196.29, 1697.37, 118.356, 1.66346, 600, 0, 13285), +(@Guid+17, 23008, 530, 1, 1, 0, 0, 4227.59, 1710.46, 121.084, 2.26429, 600, 0, 13285), +(@Guid+18, 23008, 530, 1, 1, 0, 0, 4221.32, 1766.66, 130.509, 2.1779, 600, 0, 13285), +(@Guid+19, 23008, 530, 1, 1, 0, 0, 4252.49, 1835.95, 143.106, 2.0758, 600, 0, 13285), +(@Guid+20, 23008, 530, 1, 1, 0, 0, 4285.64, 1900.79, 134.852, 2.0758, 600, 0, 13285); + +SET @ENTRY := 23008; +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=@ENTRY; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,0,0,100,0,3000,4000,12000,16000,11,35924,0,0,0,0,0,2,0,0,0,0,0,0,0,'Ethereum Jailor - IC - Cast Energy Flux'), +(@ENTRY,0,1,0,0,0,100,0,4000,5000,9000,17000,11,36513,0,0,0,0,0,2,0,0,0,0,0,0,0,'Ethereum Jailor - IC - Cast Intangible Presence'); diff --git a/sql/updates/world/2016_01_17_00_world_335.sql b/sql/updates/world/2016_01_17_00_world_335.sql new file mode 100644 index 00000000000..abb3579fb07 --- /dev/null +++ b/sql/updates/world/2016_01_17_00_world_335.sql @@ -0,0 +1,26 @@ +-- +SET @NPC := 26577; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-2369.16,`position_y`=-876.936,`position_z`=-9.42208 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-2369.16,-876.936,-9.42208,0,0,0,0,100,0), +(@PATH,2,-2366.53,-856.691,-9.36085,0,0,0,0,100,0), +(@PATH,3,-2357.15,-811.864,-9.42138,0,0,0,0,100,0), +(@PATH,4,-2345.23,-748.967,-9.42454,0,0,0,0,100,0), +(@PATH,5,-2341.13,-700.582,-9.29519,0,0,0,0,100,0), +(@PATH,6,-2335.57,-673.555,-9.41523,0,0,0,0,100,0), +(@PATH,7,-2323.8,-641.711,-9.34184,0,0,0,0,100,0), +(@PATH,8,-2310.09,-613.217,-9.42431,0,0,0,0,100,0), +(@PATH,9,-2295.38,-586.808,-9.4231,2.396761,21600,0,0,100,0), +(@PATH,10,-2323.09,-595.375,-9.42242,0,0,0,0,100,0), +(@PATH,11,-2312.27,-614.66,-9.42405,0,0,0,0,100,0), +(@PATH,12,-2326.41,-645.536,-9.34993,0,0,0,0,100,0), +(@PATH,13,-2336.51,-676.214,-9.40864,0,0,0,0,100,0), +(@PATH,14,-2344.05,-723.843,-9.42353,0,0,0,0,100,0), +(@PATH,15,-2346.75,-760.367,-9.42353,0,0,0,0,100,0), +(@PATH,16,-2357.56,-811.652,-9.42353,0,0,0,0,100,0), +(@PATH,17,-2366.12,-855.675,-9.32695,0,0,0,0,100,0), +(@PATH,18,-2376.83,-896.428,-9.39643,6.216497,21600,0,0,100,0); diff --git a/sql/updates/world/2016_01_17_01_world.sql b/sql/updates/world/2016_01_17_01_world.sql new file mode 100644 index 00000000000..8e5bcd22a07 --- /dev/null +++ b/sql/updates/world/2016_01_17_01_world.sql @@ -0,0 +1,9 @@ +-- +DELETE FROM `creature_template_addon` WHERE `entry` IN (21694,21914,17796,17797,20629,20630); +INSERT INTO `creature_template_addon` (`entry`, `mount`, `bytes1`, `bytes2`, `auras`) VALUES +(21694,0,0x0,0x1,'18950'), -- 21694 - 18950 +(21914,0,0x0,0x1,'18950'), -- 21914 - 18950 +(17796,0,0x0,0x1,'18950'), -- 17796 - 18950 +(17797,0,0x0,0x1,'18950'), -- 17797 - 18950 +(20629,0,0x0,0x1,'18950'), -- 20629 - 18950 +(20630,0,0x0,0x1,'18950'); -- 20630 - 18950 diff --git a/sql/updates/world/2016_01_17_02_world.sql b/sql/updates/world/2016_01_17_02_world.sql new file mode 100644 index 00000000000..f019b927228 --- /dev/null +++ b/sql/updates/world/2016_01_17_02_world.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `creature_onkill_reputation` WHERE `creature_id`=20477; +INSERT INTO `creature_onkill_reputation` (`creature_id`, `RewOnKillRepFaction1`, `RewOnKillRepFaction2`, `MaxStanding1`, `IsTeamAward1`, `RewOnKillRepValue1`, `MaxStanding2`, `IsTeamAward2`, `RewOnKillRepValue2`, `TeamDependent`) VALUES +(20477, 942, 0, 5, 0, 7, 0, 0, 0, 0); diff --git a/sql/updates/world/2016_01_17_03_world.sql b/sql/updates/world/2016_01_17_03_world.sql new file mode 100644 index 00000000000..cf43c650888 --- /dev/null +++ b/sql/updates/world/2016_01_17_03_world.sql @@ -0,0 +1,46 @@ +SET @OGUID:=66937; +SET @CGUID:=12545; +SET @Event:=2; + +-- Add missing xmas ornaments in silvermoon +DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+26; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0, 187567, 530, 1, 1, 9757.145, -7186.155, 23.50618, 2.897245, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+1, 187567, 530, 1, 1, 9799.123, -7310.608, 35.23363, 2.199115, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+2, 187567, 530, 1, 1, 9790.945, -7316.393, 35.23556, 2.234018, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+3, 187567, 530, 1, 1, 9752.514, -7336.514, 34.97601, 1.919862, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+4, 187567, 530, 1, 1, 9724.499, -7346.248, 34.95547, 1.919862, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+5, 187567, 530, 1, 1, 9743.402, -7339.749, 34.94567, 1.902409, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+6, 187567, 530, 1, 1, 9734.03, -7343.019, 35.02362, 1.902409, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+7, 187567, 530, 1, 1, 9767.382, -7480.58, 28.18164, 3.194002, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+8, 187567, 530, 1, 1, 9767.383, -7495.052, 28.28906, 3.054327, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+9, 187567, 530, 1, 1, 9694.368, -7495.957, 25.62033, 1.605702, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+10, 187567, 530, 1, 1, 9683.361, -7495.406, 26.99795, 1.53589, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+11, 187567, 530, 1, 1, 9638.369, -7397.279, 22.68563, 4.782203, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+12, 187567, 530, 1, 1, 9672.388, -7495.991, 25.67016, 1.53589, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+13, 187567, 530, 1, 1, 9648.386, -7152.304, 23.26344, 1.570796, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+14, 187567, 530, 1, 1, 9665.867, -7135.831, 23.16022, 3.106652, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+15, 187567, 530, 1, 1, 9631.138, -7135.575, 23.11801, 6.265733, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+16, 187567, 530, 1, 1, 9648.528, -7119.087, 23.2984, 4.729844, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+17, 187567, 530, 1, 1, 9485.029, -7132.405, 24.43083, 0, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3487) +(@OGUID+18, 187194, 530, 1, 1, 9954.997, -7098.571, 59.86189, 3.996807, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+19, 187194, 530, 1, 1, 10007.34, -7030.903, 57.97285, 4.06662, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+20, 187194, 530, 1, 1, 10002.23, -7202.467, 44.06782, 1.466076, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+21, 187194, 530, 1, 1, 10010.68, -7199.167, 44.22095, 2.478367, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+22, 187194, 530, 1, 1, 9992.33, -7205.063, 44.06255, 2.18166, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+23, 187194, 530, 1, 1, 9952.419, -7232.268, 43.9028, 2.234018, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+24, 187194, 530, 1, 1, 9945.498, -7242.049, 43.90578, 2.792518, 0, 0, 0, 1, 120, 255, 1), -- 187194 (Area: 3487) +(@OGUID+25, 187235, 530, 1, 1, 9982.972, -7098.827, 47.70499, 6.056293, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3487) +(@OGUID+26, 187235, 530, 1, 1, 9987.122, -7093.597, 47.70498, 5.253442, 0, 0, 0, 1, 120, 255, 1); -- 187235 (Area: 3487) + +DELETE FROM `game_event_gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+26 AND `eventEntry`=@Event; +INSERT INTO `game_event_gameobject` SELECT @Event, gameobject.guid FROM `gameobject` WHERE gameobject.guid BETWEEN @OGUID+0 AND @OGUID+26; + +-- Add spawns Pat's Snowcloud Guy +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+1; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `curhealth`) VALUES +(@CGUID+0, 15730, 530, 9346.396, -7265.283, 20.67977, 6.021386, 120, 0), -- 15730 (Area: 0) (Auras: 26000 - 26000) +(@CGUID+1, 15730, 530, 9347.098, -7267.961, 20.6914, 3.263766, 120, 0); -- 15730 (Area: 0) (Auras: 26000 - 26000) + +DELETE FROM `game_event_creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+1 AND `eventEntry`=@Event; +INSERT INTO `game_event_creature` SELECT @Event, creature.guid FROM `creature` WHERE creature.guid BETWEEN @CGUID+0 AND @CGUID+1; diff --git a/sql/updates/world/2016_01_17_04_world.sql b/sql/updates/world/2016_01_17_04_world.sql new file mode 100644 index 00000000000..6d72807e0b1 --- /dev/null +++ b/sql/updates/world/2016_01_17_04_world.sql @@ -0,0 +1,81 @@ +SET @OGUID:=79522; +SET @CGUID:=52022; +SET @Event:=2; + +-- Add missing xmas ornaments in Azuremyst Isle (Exodar) +DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+61; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0 , 178425, 530, 1, 1, -3949.436, -11658.67, -138.7108, 3.141593, 0, 0, 0, 1, 120, 255, 1), -- 178425 (Area: 0) +(@OGUID+1 , 178746, 530, 1, 1, -3954.361, -11657.59, -138.7044, 2.513274, 0, 0, 0, 1, 120, 255, 1), -- 178746 (Area: 0) +(@OGUID+2 , 178428, 530, 1, 1, -3951.378, -11661.31, -138.977, 0.7504908, 0, 0, 0, 1, 120, 255, 1), -- 178428 (Area: 0) +(@OGUID+3 , 178428, 530, 1, 1, -3953.229, -11658.62, -138.7581, 2.426008, 0, 0, 0, 1, 120, 255, 1), -- 178428 (Area: 0) +(@OGUID+4 , 178428, 530, 1, 1, -3951.486, -11658.68, -138.7432, 4.677484, 0, 0, 0, 1, 120, 255, 1), -- 178428 (Area: 0) +(@OGUID+5 , 178429, 530, 1, 1, -3950.01, -11652.94, -138.6416, 5.358162, 0, 0, 0, 1, 120, 255, 1), -- 178429 (Area: 0) +(@OGUID+6 , 178429, 530, 1, 1, -3950.755, -11660.4, -138.7645, 5.654869, 0, 0, 0, 1, 120, 255, 1), -- 178429 (Area: 0) +(@OGUID+7 , 178430, 530, 1, 1, -3952.516, -11660.61, -138.7691, 3.38594, 0, 0, 0, 1, 120, 255, 1), -- 178430 (Area: 0) +(@OGUID+8 , 178430, 530, 1, 1, -3949.488, -11653.97, -138.6341, 1.954769, 0, 0, 0, 1, 120, 255, 1), -- 178430 (Area: 0) +(@OGUID+9 , 178430, 530, 1, 1, -3951.285, -11659.1, -138.3316, 1.047198, 0, 0, 0, 1, 120, 255, 1), -- 178430 (Area: 0) +(@OGUID+10, 178431, 530, 1, 1, -3952.399, -11660.72, -138.4649, 2.426008, 0, 0, 0, 1, 120, 255, 1), -- 178431 (Area: 0) +(@OGUID+11, 178431, 530, 1, 1, -3950.715, -11659.36, -138.9473, 1.134463, 0, 0, 0, 1, 120, 255, 1), -- 178431 (Area: 0) +(@OGUID+12, 178432, 530, 1, 1, -3950.486, -11661.66, -138.9796, 6.073746, 0, 0, 0, 1, 120, 255, 1), -- 178432 (Area: 0) +(@OGUID+13, 178432, 530, 1, 1, -3951.252, -11654.2, -138.6518, 4.468043, 0, 0, 0, 1, 120, 255, 1), -- 178432 (Area: 0) +(@OGUID+14, 178432, 530, 1, 1, -3952.455, -11658.96, -138.7532, 2.705255, 0, 0, 0, 1, 120, 255, 1), -- 178432 (Area: 0) +(@OGUID+15, 178433, 530, 1, 1, -3949.59, -11660.9, -138.9695, 4.921829, 0, 0, 0, 1, 120, 255, 1), -- 178433 (Area: 0) +(@OGUID+16, 178433, 530, 1, 1, -3953.01, -11659.64, -138.7615, 1.815142, 0, 0, 0, 1, 120, 255, 1), -- 178433 (Area: 0) +(@OGUID+17, 178433, 530, 1, 1, -3950.47, -11653.59, -138.645, 4.01426, 0, 0, 0, 1, 120, 255, 1), -- 178433 (Area: 0) +(@OGUID+18, 187567, 530, 1, 1, -4213.729, -11685.4, -130.8234, 0.9424766, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 0) +(@OGUID+19, 187567, 530, 1, 1, -4145.799, -11745.62, -124.1529, 2.024579, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 0) +(@OGUID+20, 187567, 530, 1, 1, -4205.994, -12527.13, 50.12775, 0.7155849, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 0) +(@OGUID+21, 187567, 530, 1, 1, -4152.035, -12529.42, 49.52319, 2.670348, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3576) +(@OGUID+22, 187567, 530, 1, 1, -4171.053, -13734.39, 82.08741, 2.775069, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3526) +(@OGUID+23, 187567, 530, 1, 1, -4054.646, -13772.28, 84.39475, 5.881761, 0, 0, 0, 1, 120, 255, 1), -- 187567 (Area: 3527) +(@OGUID+24, 187235, 530, 1, 1, -4214.633, -12476, 45.07409, 5.497789, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+25, 187235, 530, 1, 1, -4212.527, -12510.34, 45.44406, 0.2268925, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+26, 187235, 530, 1, 1, -4209.379, -12517.65, 45.81722, 0.3316107, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+27, 187235, 530, 1, 1, -4185.712, -12504.83, 44.36132, 3.560473, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+28, 187235, 530, 1, 1, -4158.139, -12463.08, 45.08138, 3.717554, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+29, 187235, 530, 1, 1, -4176.958, -12493.97, 44.361, 1.361356, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+30, 187235, 530, 1, 1, -4171.624, -12506.62, 44.36132, 5.550147, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+31, 187235, 530, 1, 1, -4153.742, -12484.6, 44.51342, 3.909541, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+32, 187235, 530, 1, 1, -4158.644, -12533.33, 45.45204, 2.129301, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3576) +(@OGUID+33, 187235, 530, 1, 1, -3928.31, -11712.54, -135.2059, 5.148723, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+34, 187235, 530, 1, 1, -3938.107, -11702.05, -135.2763, 1.500983, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+35, 187235, 530, 1, 1, -3891.189, -11640.65, -134.4907, 1.291542, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+36, 187235, 530, 1, 1, -3919.52, -11641.97, -134.8313, 0.2094394, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+37, 187235, 530, 1, 1, -3905.643, -11638.75, -134.6634, 5.864307, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+38, 187235, 530, 1, 1, -3943.941, -11674.08, -135.2386, 3.595379, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+39, 187235, 530, 1, 1, -3939.98, -11660.92, -135.1454, 3.874631, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+40, 187235, 530, 1, 1, -3943.487, -11689.1, -135.2892, 0.6108634, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+41, 187235, 530, 1, 1, -3931.237, -11649.39, -135.003, 1.710422, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+42, 187235, 530, 1, 1, -3877.953, -11647.35, -134.3679, 4.677484, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+43, 187235, 530, 1, 1, -4040.372, -11581.41, -138.4519, 0.6806767, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+44, 187235, 530, 1, 1, -4025.329, -11590.4, -138.3277, 1.762782, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+45, 187235, 530, 1, 1, -4006.567, -11572.73, -138.0419, 2.670348, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+46, 187235, 530, 1, 1, -4228.949, -11818.94, -115.9345, 0.802851, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 0) +(@OGUID+47, 187235, 530, 1, 1, -4048.503, -13778.93, 75.01585, 0.2967052, 0, 0, 0, 1, 120, 255, 1), -- 187235 (Area: 3527) +(@OGUID+48, 187193, 530, 1, 1, -3929.128, -11744.82, -138.6122, 0.6283169, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+49, 187193, 530, 1, 1, -3970.78, -11722.88, -138.8356, 1.518436, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+50, 187193, 530, 1, 1, -3862.003, -11617.36, -136.8326, 4.939284, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+51, 187193, 530, 1, 1, -3935.253, -11599.68, -138.455, 5.654869, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+52, 187193, 530, 1, 1, -3903.503, -11599.64, -137.7858, 3.926996, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+53, 187193, 530, 1, 1, -3821.196, -11515.72, -138.6442, 1.518436, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+54, 187193, 530, 1, 1, -3843.451, -11503.5, -139.0975, 0.7853968, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+55, 187193, 530, 1, 1, -3753.633, -11517.73, -134.327, 2.094393, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+56, 187193, 530, 1, 1, -3898.609, -11445.35, -132.8523, 0.1047193, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+57, 187193, 530, 1, 1, -3732.545, -11501.01, -134.0293, 2.373644, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+58, 187193, 530, 1, 1, -3657.605, -11491.42, -119.0973, 1.989672, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+59, 187193, 530, 1, 1, -3640.533, -11468.59, -118.8086, 3.019413, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+60, 187193, 530, 1, 1, -3903.453, -11420.75, -132.7737, 0.1919852, 0, 0, 0, 1, 120, 255, 1), -- 187193 (Area: 0) +(@OGUID+61, 187193, 530, 1, 1, -3985.045, -11695.91, -139.3659, 5.742135, 0, 0, 0, 1, 120, 255, 1); -- 187193 (Area: 0) + +DELETE FROM `game_event_gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+61 AND `eventEntry`=@Event; +INSERT INTO `game_event_gameobject` SELECT @Event, gameobject.guid FROM `gameobject` WHERE gameobject.guid BETWEEN @OGUID+0 AND @OGUID+61; + +-- Add spawns Pat's Snowcloud Guy +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+1; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `curhealth`) VALUES +(@CGUID+0, 15730, 530, -3997.986, -11908.32, -1.411356, 0.2617994, 120, 0), -- 15730 (Area: 0) (Auras: 26000 - 26000) +(@CGUID+1, 15730, 530, -3997.807, -11908.79, 0.8329293, 4.782202, 120, 0); -- 15730 (Area: 0) (Auras: 26000 - 26000) + +DELETE FROM `game_event_creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+1 AND `eventEntry`=@Event; +INSERT INTO `game_event_creature` SELECT @Event, creature.guid FROM `creature` WHERE creature.guid BETWEEN @CGUID+0 AND @CGUID+1; diff --git a/sql/updates/world/2016_01_17_05_world.sql b/sql/updates/world/2016_01_17_05_world.sql new file mode 100644 index 00000000000..2d253bae713 --- /dev/null +++ b/sql/updates/world/2016_01_17_05_world.sql @@ -0,0 +1,16 @@ +UPDATE`spell_dbc` SET `Effect1`=28, `EffectMiscValueB1`=64 WHERE `Id`IN(14313,14307,14252); + +-- Spell 14313 Summon Enraged Gryphon +-- Spell 14307 Summon Enraged Wyvern +-- Spell 14252 Summon Enraged Felbat +-- Spell 14329 Summon Enraged Hippogryph + +DELETE FROM `smart_scripts` WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9297 AND `id`=1; +DELETE FROM `smart_scripts` WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9526 AND `id`=1; +DELETE FROM `smart_scripts` WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9521 AND `id`=1; +DELETE FROM `smart_scripts` WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9527 AND `id`=1; + +UPDATE `smart_scripts` SET `action_type`=11, `action_param1`=14307, `action_param2`=2, `action_param3`=0,`link`=0 WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9297; +UPDATE `smart_scripts` SET `action_type`=11, `action_param1`=14313, `action_param2`=2, `action_param3`=0,`link`=0 WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9526; +UPDATE `smart_scripts` SET `action_type`=11, `action_param1`=14252, `action_param2`=2, `action_param3`=0,`link`=0 WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9521; +UPDATE `smart_scripts` SET `action_type`=11, `action_param1`=14329, `action_param2`=2, `action_param3`=0,`link`=0 WHERE `source_type` =0 AND `action_type` =12 AND `action_param1` =9527; diff --git a/sql/updates/world/2016_01_17_06_world.sql b/sql/updates/world/2016_01_17_06_world.sql new file mode 100644 index 00000000000..659f146845a --- /dev/null +++ b/sql/updates/world/2016_01_17_06_world.sql @@ -0,0 +1,5 @@ +UPDATE `smart_scripts` SET `id`=5 WHERE `source_type` = 9 AND `entryorguid` = 2229300 AND `id`=4 AND `action_type`=51; + +DELETE FROM `smart_scripts` WHERE `source_type` = 9 AND `entryorguid` = 2229300 AND `id`=4; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(2229300, 9, 4, 0, 0, 0, 100, 0, 0, 0, 0, 0, 85, 38758, 2, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Inactive Fel Reaver - Action list - Invoker Cast [PH] Quest reward: Nether Gas In a Fel Fire Engine'); diff --git a/sql/updates/world/2016_01_17_07_world.sql b/sql/updates/world/2016_01_17_07_world.sql new file mode 100644 index 00000000000..df588168d38 --- /dev/null +++ b/sql/updates/world/2016_01_17_07_world.sql @@ -0,0 +1,22 @@ +DELETE FROM `creature_formations` WHERE `leaderGUID`=33658; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(33658, 33658, 0, 0, 1), +(33658, 33657, 10, 0, 2); + +-- Pathing for Hazzas Entry: 5722 'TDB FORMAT' +SET @NPC := 33658; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-649.7056,`position_y`=131.495,`position_z`=-90.5838 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-649.7056,131.495,-90.5838,0,0,1,0,100,0), -- 14:04:57 +(@PATH,2,-665.5804,131.4927,-90.58052,0,0,1,0,100,0), -- 14:05:00 +(@PATH,3,-673.0132,94.911,-90.58176,0,0,1,0,100,0), -- 14:05:02 +(@PATH,4,-673.0271,83.92074,-90.58344,0,0,1,0,100,0), -- 14:05:04 +(@PATH,5,-665.4554,60.56186,-90.5854,0,0,1,0,100,0), -- 14:05:07 +(@PATH,6,-649.9196,60.34818,-90.58607,0,0,1,0,100,0), -- 14:05:08 +(@PATH,7,-641.7787,99.33066,-90.58942,0,0,1,0,100,0), -- 14:05:10 +(@PATH,8,-644.1965,115.6559,-90.58284,0,0,1,0,100,0); -- 14:05:13 +-- 0x1C30A00DA00596800034A9000018FBD3 .go -649.7056 131.495 -90.5838 diff --git a/sql/updates/world/2016_01_17_08_world.sql b/sql/updates/world/2016_01_17_08_world.sql new file mode 100644 index 00000000000..48cd420a242 --- /dev/null +++ b/sql/updates/world/2016_01_17_08_world.sql @@ -0,0 +1,408 @@ +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57733; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4259.922,`position_y`=-11744.17,`position_z`=-132.7823 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4259.922,-11744.17,-132.7823,0,0,0,0,100,0), -- 10:11:34 +(@PATH,2,-4253.737,-11752.62,-132.103,0,0,0,0,100,0), -- 10:11:50 +(@PATH,3,-4251.487,-11755.87,-132.603,0,0,0,0,100,0), -- 10:11:50 +(@PATH,4,-4248.737,-11759.37,-132.603,0,0,0,0,100,0), -- 10:11:50 +(@PATH,5,-4242.487,-11767.87,-131.853,0,0,0,0,100,0), -- 10:11:50 +(@PATH,6,-4234.163,-11770.65,-131.4757,0,0,0,0,100,0), -- 10:12:04 +(@PATH,7,-4205.663,-11771.65,-131.9757,0,0,0,0,100,0), -- 10:12:04 +(@PATH,8,-4199.815,-11770.93,-132.2653,0,0,0,0,100,0), -- 10:12:20 +(@PATH,9,-4176.882,-11762.18,-132.0013,0,0,0,0,100,0), -- 10:12:29 +(@PATH,10,-4166.132,-11757.68,-136.7513,0,0,0,0,100,0), -- 10:12:29 +(@PATH,11,-4166.266,-11739.91,-136.6903,0,0,0,0,100,0), -- 10:12:36 +(@PATH,12,-4166.516,-11733.41,-136.6903,0,0,0,0,100,0), -- 10:12:36 +(@PATH,13,-4166.766,-11730.66,-136.6903,0,0,0,0,100,0), -- 10:12:36 +(@PATH,14,-4179.53,-11763.62,-132.2955,0,0,0,0,100,0), -- 10:13:15 +(@PATH,15,-4180.446,-11764.02,-132.2955,0,0,0,0,100,0), -- 10:13:15 +(@PATH,16,-4200.114,-11771.23,-132.5309,0,0,0,0,100,0), -- 10:13:15 +(@PATH,17,-4202.051,-11771.94,-132.4386,0,0,0,0,100,0), -- 10:13:15 +(@PATH,18,-4202.051,-11771.94,-132.4386,0,0,0,0,100,0), -- 10:13:15 +(@PATH,19,-4205.86,-11771.68,-132.0416,0,0,0,0,100,0), -- 10:13:17 +(@PATH,20,-4234.11,-11770.68,-131.5416,0,0,0,0,100,0), -- 10:13:17 +(@PATH,21,-4248.942,-11759.42,-132.5334,0,0,0,0,100,0), -- 10:13:33 +(@PATH,22,-4251.192,-11755.92,-132.5334,0,0,0,0,100,0), -- 10:13:33 +(@PATH,23,-4253.692,-11752.67,-132.0334,0,0,0,0,100,0), -- 10:13:33 +(@PATH,24,-4258.692,-11745.92,-132.5334,0,0,0,0,100,0), -- 10:13:33 +(@PATH,25,-4259.942,-11744.17,-132.7834,0,0,0,0,100,0); -- 10:13:33 + +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57732; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4216.665,`position_y`=-11647.06,`position_z`=-143.7448 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4216.665,-11647.06,-143.7448,4.590216,5000,0,0,100,0), -- 10:39:00 +(@PATH,2,-4216.917,-11623.43,-132.8519,0,0,0,0,100,0), -- 10:39:16 +(@PATH,3,-4216.917,-11613.93,-128.6019,0,0,0,0,100,0), -- 10:39:16 +(@PATH,4,-4216.917,-11607.68,-125.8519,0,0,0,0,100,0), -- 10:39:16 +(@PATH,5,-4216.917,-11604.68,-125.8519,0,0,0,0,100,0), -- 10:39:16 +(@PATH,6,-4216.917,-11602.93,-125.8519,0,0,0,0,100,0), -- 10:39:16 +(@PATH,7,-4217.17,-11602.3,-125.959,4.817109,5000,0,0,100,0), -- 10:39:36 +(@PATH,8,-4197.176,-11597.41,-124.0743,0,0,0,0,100,0), -- 10:39:56 +(@PATH,9,-4195.676,-11597.16,-125.3243,0,0,0,0,100,0), -- 10:39:56 +(@PATH,10,-4187.176,-11595.16,-124.8243,0,0,0,0,100,0), -- 10:39:56 +(@PATH,11,-4183.45,-11596.95,-124.1946,0,0,0,0,100,0), -- 10:40:08 +(@PATH,12,-4179.45,-11604.45,-121.1946,0,0,0,0,100,0), -- 10:40:08 +(@PATH,13,-4175.45,-11610.7,-119.1946,0,0,0,0,100,0), -- 10:40:08 +(@PATH,14,-4164.444,-11628.77,-104.9988,0,0,0,0,100,0), -- 10:40:21 +(@PATH,15,-4160.194,-11635.52,-97.99881,0,0,0,0,100,0), -- 10:40:21 +(@PATH,16,-4162.848,-11643.82,-98.11985,0,0,0,0,100,0), -- 10:40:31 +(@PATH,17,-4165.893,-11649.45,-98.40599,3.246312,5000,0,0,100,0), -- 10:40:39 +(@PATH,18,-4166.085,-11630.18,-104.5746,0,0,0,0,100,0), -- 10:40:53 +(@PATH,19,-4174.826,-11610.26,-119.0268,0,0,0,0,100,0), -- 10:41:04 +(@PATH,20,-4178.826,-11602.76,-121.5268,0,0,0,0,100,0), -- 10:41:04 +(@PATH,21,-4182.576,-11596.51,-124.0268,0,0,0,0,100,0), -- 10:41:04 +(@PATH,22,-4186.426,-11593.54,-124.7621,0,0,0,0,100,0), -- 10:41:19 +(@PATH,23,-4193.426,-11591.54,-124.7621,0,0,0,0,100,0), -- 10:41:19 +(@PATH,24,-4198.176,-11589.79,-125.2621,0,0,0,0,100,0), -- 10:41:19 +(@PATH,25,-4209.176,-11586.04,-125.5121,0,0,0,0,100,0), -- 10:41:19 +(@PATH,26,-4211.554,-11587.69,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,27,-4212.304,-11589.44,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,28,-4213.554,-11592.69,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,29,-4215.804,-11597.44,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,30,-4217.054,-11600.69,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,31,-4217.554,-11601.69,-125.6955,0,0,0,0,100,0), -- 10:41:30 +(@PATH,32,-4218.49,-11603.42,-126.0363,4.834562,5000,0,0,100,0), -- 10:41:39 +(@PATH,33,-4217.827,-11613.99,-128.6406,0,0,0,0,100,0), -- 10:41:55 +(@PATH,34,-4217.577,-11622.99,-132.6406,0,0,0,0,100,0), -- 10:41:55 +(@PATH,35,-4217.077,-11638.74,-139.8906,0,0,0,0,100,0), -- 10:41:55 +(@PATH,36,-4216.827,-11644.74,-143.3906,0,0,0,0,100,0); -- 10:41:55 + +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57731; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4055.538,`position_y`=-11719.55,`position_z`=-138.8952 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4055.538,-11719.55,-138.8952,0,0,0,0,100,0), -- 10:45:16 +(@PATH,2,-4069.275,-11725.09,-138.3611,0,0,0,0,100,0), -- 10:45:34 +(@PATH,3,-4092.408,-11723.83,-139.1332,0,0,0,0,100,0), -- 10:45:49 +(@PATH,4,-4099.328,-11724.08,-139.0543,0,0,0,0,100,0), -- 10:45:56 +(@PATH,5,-4111.578,-11729.58,-139.3043,0,0,0,0,100,0), -- 10:45:56 +(@PATH,6,-4117.578,-11732.08,-136.3043,0,0,0,0,100,0), -- 10:45:56 +(@PATH,7,-4119.328,-11733.08,-136.3043,0,0,0,0,100,0), -- 10:45:56 +(@PATH,8,-4139.16,-11723.72,-136.5828,0,0,0,0,100,0), -- 10:46:09 +(@PATH,9,-4143.91,-11720.22,-136.5828,0,0,0,0,100,0), -- 10:46:09 +(@PATH,10,-4125.933,-11733.08,-136.3418,0,0,0,0,100,0), -- 10:46:21 +(@PATH,11,-4117.555,-11732.18,-136.3103,0,0,0,0,100,0), -- 10:46:31 +(@PATH,12,-4111.555,-11729.43,-139.3103,0,0,0,0,100,0), -- 10:46:31 +(@PATH,13,-4099.305,-11723.93,-139.0603,0,0,0,0,100,0), -- 10:46:31 +(@PATH,14,-4080.146,-11728.12,-138.7241,0,0,0,0,100,0), -- 10:46:43 +(@PATH,15,-4069.389,-11725.02,-138.4003,0,0,0,0,100,0), -- 10:46:51 +(@PATH,16,-4067.389,-11724.27,-138.4003,0,0,0,0,100,0), -- 10:46:51 +(@PATH,17,-4055.639,-11719.52,-138.9003,0,0,0,0,100,0); -- 10:46:51 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=57722; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(57722, 57722, 0, 0, 1), +(57722, 57723, 2, 270, 2); + +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57722; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4035.478,`position_y`=-11451.96,`position_z`=-55.53455 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4035.478,-11451.96,-55.53455,0,15000,0,0,100,0), -- 10:28:52 +(@PATH,2,-4038.098,-11441.65,-62.00945,0,0,0,0,100,0), -- 10:29:19 +(@PATH,3,-4048.067,-11425.79,-72.46973,0,0,0,0,100,0), -- 10:29:29 +(@PATH,4,-4072.011,-11409.6,-88.05364,0,0,0,0,100,0), -- 10:29:37 +(@PATH,5,-4090.952,-11407.41,-98.80654,0,0,0,0,100,0), -- 10:29:48 +(@PATH,6,-4100.202,-11406.66,-104.3065,0,0,0,0,100,0), -- 10:29:48 +(@PATH,7,-4118.357,-11413.92,-114.891,0,0,0,0,100,0), -- 10:30:01 +(@PATH,8,-4134.707,-11426.21,-125.61,0,0,0,0,100,0), -- 10:30:13 +(@PATH,9,-4137.963,-11431.42,-128.7505,0,0,0,0,100,0), -- 10:30:21 +(@PATH,10,-4144.455,-11462.52,-130.7656,0,0,0,0,100,0), -- 10:30:26 +(@PATH,11,-4143.278,-11481.03,-130.6259,0,0,0,0,100,0), -- 10:30:36 +(@PATH,12,-4141.778,-11489.78,-130.6259,0,0,0,0,100,0), -- 10:30:36 +(@PATH,13,-4133.984,-11497.89,-130.5813,0,0,0,0,100,0), -- 10:30:46 +(@PATH,14,-4123.734,-11506.64,-135.3313,0,0,0,0,100,0), -- 10:30:46 +(@PATH,15,-4118.456,-11529.87,-135.6161,0,0,0,0,100,0), -- 10:30:57 +(@PATH,16,-4118.632,-11541.07,-135.6777,0,15000,0,0,100,0), -- 10:31:08 +(@PATH,17,-4107.033,-11536.5,-135.5405,0,0,0,0,100,0), -- 10:31:33 +(@PATH,18,-4095.169,-11530.58,-135.5151,0,0,0,0,100,0), -- 10:31:43 +(@PATH,19,-4072.678,-11526.62,-135.1866,0,0,0,0,100,0), -- 10:31:50 +(@PATH,20,-4068.678,-11527.37,-135.6866,0,0,0,0,100,0), -- 10:31:50 +(@PATH,21,-4062.178,-11528.87,-138.1866,0,0,0,0,100,0), -- 10:31:50 +(@PATH,22,-4044.695,-11532.02,-138.1443,0,0,0,0,100,0), -- 10:31:59 +(@PATH,23,-4042.251,-11532.67,-138.0262,0,0,0,0,100,0), -- 10:32:05 +(@PATH,24,-4035.501,-11537.42,-138.0262,0,0,0,0,100,0), -- 10:32:05 +(@PATH,25,-4028.77,-11550.78,-137.9687,0,0,0,0,100,0), -- 10:32:09 +(@PATH,26,-4026.27,-11555.78,-137.9687,0,0,0,0,100,0), -- 10:32:09 +(@PATH,27,-4020.903,-11567.01,-137.9309,0,0,0,0,100,0), -- 10:32:18 +(@PATH,28,-4006.608,-11590.79,-135.6749,0,0,0,0,100,0), -- 10:32:27 +(@PATH,29,-4001.739,-11597.25,-134.446,0,15000,0,0,100,0), -- 10:32:37 +(@PATH,30,-4003.607,-11589.51,-135.0951,0,0,0,0,100,0), -- 10:33:00 +(@PATH,31,-4008.607,-11582.01,-137.5951,0,0,0,0,100,0), -- 10:33:00 +(@PATH,32,-4020.018,-11566.11,-137.9106,0,0,0,0,100,0), -- 10:33:08 +(@PATH,33,-4028.915,-11551.29,-137.955,0,0,0,0,100,0), -- 10:33:18 +(@PATH,34,-4035.739,-11537.94,-137.9934,0,0,0,0,100,0), -- 10:33:27 +(@PATH,35,-4044.477,-11531.19,-138.0956,0,0,0,0,100,0), -- 10:33:30 +(@PATH,36,-4064.476,-11525.09,-135.8434,0,0,0,0,100,0), -- 10:33:36 +(@PATH,37,-4070.578,-11522.78,-135.0313,0,0,0,0,100,0), -- 10:33:44 +(@PATH,38,-4073.483,-11514.04,-135.0202,0,15000,0,0,100,0), -- 10:33:47 +(@PATH,39,-4112.552,-11504.43,-135.4866,0,0,0,0,100,0), -- 10:34:12 +(@PATH,40,-4118.729,-11500.47,-135.2996,0,0,0,0,100,0), -- 10:34:27 +(@PATH,41,-4131.229,-11491.97,-130.2996,0,0,0,0,100,0), -- 10:34:27 +(@PATH,42,-4134.815,-11481.72,-130.2471,0,0,0,0,100,0), -- 10:34:37 +(@PATH,43,-4135.565,-11478.97,-130.2471,0,0,0,0,100,0), -- 10:34:37 +(@PATH,44,-4136.778,-11458.39,-130.6105,0,0,0,0,100,0), -- 10:34:47 +(@PATH,45,-4136.778,-11457.14,-130.6105,0,0,0,0,100,0), -- 10:34:47 +(@PATH,46,-4133.271,-11441.38,-130.0716,0,0,0,0,100,0), -- 10:34:56 +(@PATH,47,-4122.668,-11422.46,-118.9364,0,0,0,0,100,0), -- 10:35:04 +(@PATH,48,-4108.187,-11412.36,-108.8878,0,0,0,0,100,0), -- 10:35:11 +(@PATH,49,-4089.786,-11408.53,-98.16229,0,0,0,0,100,0), -- 10:35:20 +(@PATH,50,-4071.33,-11410.57,-87.74048,0,0,0,0,100,0), -- 10:35:28 +(@PATH,51,-4054.675,-11419.34,-76.96556,0,0,0,0,100,0), -- 10:35:37 +(@PATH,52,-4047.425,-11424.59,-72.71556,0,0,0,0,100,0), -- 10:35:37 +(@PATH,53,-4042.097,-11435.35,-65.71899,0,0,0,0,100,0), -- 10:35:48 +(@PATH,54,-4039.347,-11441.85,-62.21899,0,0,0,0,100,0); -- 10:35:48 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=57721; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(57721, 57721, 0, 0, 1), +(57721, 57720, 2, 270, 2); + +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57721; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-3967.541,`position_y`=-11439.45,`position_z`=-136.5146 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-3967.541,-11439.45,-136.5146,0,0,0,0,100,0), -- 10:19:30 +(@PATH,2,-3988.034,-11458.35,-136.91,0,0,0,0,100,0), -- 10:19:56 +(@PATH,3,-3995.157,-11467.58,-136.9,0,0,0,0,100,0), -- 10:20:09 +(@PATH,4,-3998.407,-11481.33,-137.15,0,0,0,0,100,0), -- 10:20:09 +(@PATH,5,-3998.143,-11483.91,-137.1721,0,0,0,0,100,0), -- 10:20:18 +(@PATH,6,-3993.893,-11490.66,-137.1721,0,0,0,0,100,0), -- 10:20:18 +(@PATH,7,-3991.643,-11494.16,-136.9221,0,0,0,0,100,0), -- 10:20:18 +(@PATH,8,-3990.893,-11495.41,-136.9221,0,0,0,0,100,0), -- 10:20:18 +(@PATH,9,-3985.393,-11504.16,-136.9221,0,0,0,0,100,0), -- 10:20:18 +(@PATH,10,-3982.393,-11509.16,-136.9221,0,0,0,0,100,0), -- 10:20:18 +(@PATH,11,-3978.886,-11514.21,-136.8319,0,0,0,0,100,0), -- 10:20:31 +(@PATH,12,-3965.32,-11535.52,-135.6286,0,0,0,0,100,0), -- 10:20:39 +(@PATH,13,-3962.82,-11541.27,-134.3786,0,0,0,0,100,0), -- 10:20:39 +(@PATH,14,-3962.07,-11543.27,-134.1286,0,0,0,0,100,0), -- 10:20:39 +(@PATH,15,-3960.32,-11547.27,-134.1286,0,0,0,0,100,0), -- 10:20:39 +(@PATH,16,-3953.078,-11561.7,-133.8862,0,0,0,0,100,0), -- 10:20:49 +(@PATH,17,-3952.157,-11563.7,-133.8141,0,0,0,0,100,0), -- 10:20:55 +(@PATH,18,-3954.035,-11559.74,-134.0775,0,0,0,0,100,0), -- 10:21:18 +(@PATH,19,-3958.522,-11542.85,-134.0628,0,0,0,0,100,0), -- 10:21:24 +(@PATH,20,-3958.772,-11541.35,-134.3128,0,0,0,0,100,0), -- 10:21:24 +(@PATH,21,-3959.772,-11534.6,-135.5628,0,0,0,0,100,0), -- 10:21:24 +(@PATH,22,-3960.772,-11530.1,-136.5628,0,0,0,0,100,0), -- 10:21:24 +(@PATH,23,-3976.953,-11511.68,-136.8674,0,0,0,0,100,0), -- 10:21:33 +(@PATH,24,-3980.453,-11507.68,-136.8674,0,0,0,0,100,0), -- 10:21:33 +(@PATH,25,-3984.203,-11503.68,-136.8674,0,0,0,0,100,0), -- 10:21:33 +(@PATH,26,-3991.703,-11495.68,-136.8674,0,0,0,0,100,0), -- 10:21:33 +(@PATH,27,-3992.703,-11494.68,-136.8674,0,0,0,0,100,0), -- 10:21:33 +(@PATH,28,-3995.201,-11491.97,-137.0053,0,0,0,0,100,0), -- 10:21:52 +(@PATH,29,-4000.951,-11484.97,-137.0053,0,0,0,0,100,0), -- 10:21:52 +(@PATH,30,-4001.701,-11483.97,-137.0053,0,0,0,0,100,0), -- 10:21:52 +(@PATH,31,-3997.792,-11464.48,-137.0493,0,0,0,0,100,0), -- 10:22:02 +(@PATH,32,-3990.042,-11456.23,-136.7993,0,0,0,0,100,0), -- 10:22:02 +(@PATH,33,-3987.292,-11453.23,-136.7993,0,0,0,0,100,0), -- 10:22:02 +(@PATH,34,-3986.042,-11451.73,-136.7993,0,0,0,0,100,0); -- 10:22:02 + +-- Pathing for Exodar Peacekeeper Entry: 16733 'TDB FORMAT' +SET @NPC := 57735; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4251.791,`position_y`=-11767.84,`position_z`=-93.89223 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4251.791,-11767.84,-93.89223,0,0,0,0,100,0), -- 10:07:56 +(@PATH,2,-4253.477,-11770.7,-93.53635,0,0,0,0,100,0), -- 10:08:00 +(@PATH,3,-4266.667,-11783.95,-93.56421,0,0,0,0,100,0), -- 10:08:04 +(@PATH,4,-4287.891,-11793.3,-94.06949,0,0,0,0,100,0), -- 10:08:13 +(@PATH,5,-4292.896,-11799.17,-94.09827,0,0,0,0,100,0), -- 10:08:21 +(@PATH,6,-4291.396,-11801.67,-94.09827,0,0,0,0,100,0), -- 10:08:21 +(@PATH,7,-4284.396,-11814.92,-99.59827,0,0,0,0,100,0), -- 10:08:21 +(@PATH,8,-4283.396,-11816.67,-99.59827,0,0,0,0,100,0), -- 10:08:21 +(@PATH,9,-4271.257,-11813.78,-99.64638,0,0,0,0,100,0), -- 10:08:33 +(@PATH,10,-4247.323,-11799.34,-95.82317,0,0,0,0,100,0), -- 10:08:40 +(@PATH,11,-4244.717,-11797.41,-95.79004,0,0,0,0,100,0), -- 10:08:50 +(@PATH,12,-4237.407,-11793.06,-95.55835,0,0,0,0,100,0), -- 10:08:53 +(@PATH,13,-4233.212,-11797.79,-95.51921,0,0,0,0,100,0), -- 10:08:57 +(@PATH,14,-4230.32,-11804.69,-95.54309,0,0,0,0,100,0), -- 10:08:59 +(@PATH,15,-4242.375,-11806.88,-95.75206,0,0,0,0,100,0), -- 10:09:02 +(@PATH,16,-4249.163,-11807,-98.797,0,0,0,0,100,0), -- 10:09:08 +(@PATH,17,-4271.709,-11816.08,-99.78216,0,0,0,0,100,0), -- 10:09:15 +(@PATH,18,-4278.459,-11818.83,-99.78216,0,0,0,0,100,0), -- 10:09:15 +(@PATH,19,-4278.884,-11823.21,-99.79669,0,0,0,0,100,0), -- 10:09:21 +(@PATH,20,-4277.884,-11824.96,-99.79669,0,0,0,0,100,0), -- 10:09:21 +(@PATH,21,-4267.689,-11842.01,-112.3755,0,0,0,0,100,0), -- 10:09:25 +(@PATH,22,-4266.437,-11843.94,-112.2757,0,0,0,0,100,0), -- 10:09:34 +(@PATH,23,-4257.481,-11844.73,-112.4191,0,0,0,0,100,0), -- 10:09:36 +(@PATH,24,-4256.231,-11843.73,-112.4191,0,0,0,0,100,0), -- 10:09:36 +(@PATH,25,-4255.231,-11843.23,-112.1691,0,0,0,0,100,0), -- 10:09:36 +(@PATH,26,-4249.231,-11839.98,-115.6691,0,0,0,0,100,0), -- 10:09:36 +(@PATH,27,-4239.349,-11833.89,-115.6299,0,0,0,0,100,0), -- 10:09:43 +(@PATH,28,-4231.849,-11829.14,-115.6299,0,0,0,0,100,0), -- 10:09:43 +(@PATH,29,-4226.349,-11825.89,-115.6299,0,0,0,0,100,0), -- 10:09:43 +(@PATH,30,-4221.665,-11822.42,-116.7485,0,0,0,0,100,0), -- 10:09:55 +(@PATH,31,-4219.165,-11820.92,-117.9985,0,0,0,0,100,0), -- 10:09:55 +(@PATH,32,-4216.665,-11819.17,-119.2485,0,0,0,0,100,0), -- 10:09:55 +(@PATH,33,-4207.821,-11811.86,-123.7914,0,0,0,0,100,0), -- 10:10:00 +(@PATH,34,-4204.571,-11808.86,-125.5414,0,0,0,0,100,0), -- 10:10:00 +(@PATH,35,-4202.321,-11806.86,-126.7914,0,0,0,0,100,0), -- 10:10:00 +(@PATH,36,-4199.845,-11803.17,-128.7961,0,0,0,0,100,0), -- 10:10:08 +(@PATH,37,-4198.095,-11800.17,-130.2961,0,0,0,0,100,0), -- 10:10:08 +(@PATH,38,-4194.845,-11794.67,-132.7961,0,0,0,0,100,0), -- 10:10:08 +(@PATH,39,-4199.826,-11803.24,-128.946,0,0,0,0,100,0), -- 10:10:15 +(@PATH,40,-4207.697,-11811.62,-124.236,0,0,0,0,100,0), -- 10:10:20 +(@PATH,41,-4210.447,-11813.87,-122.736,0,0,0,0,100,0), -- 10:10:20 +(@PATH,42,-4216.582,-11818.92,-119.3844,0,0,0,0,100,0), -- 10:10:27 +(@PATH,43,-4218.832,-11820.67,-118.1344,0,0,0,0,100,0), -- 10:10:27 +(@PATH,44,-4221.582,-11822.42,-116.6344,0,0,0,0,100,0), -- 10:10:27 +(@PATH,45,-4222.832,-11823.42,-115.6344,0,0,0,0,100,0), -- 10:10:27 +(@PATH,46,-4224.417,-11824.55,-115.6566,0,0,0,0,100,0), -- 10:10:32 +(@PATH,47,-4226.417,-11825.8,-115.6566,0,0,0,0,100,0), -- 10:10:32 +(@PATH,48,-4231.917,-11829.3,-115.9066,0,0,0,0,100,0), -- 10:10:32 +(@PATH,49,-4239.417,-11833.8,-115.9066,0,0,0,0,100,0), -- 10:10:32 +(@PATH,50,-4255.09,-11843.43,-112.396,0,0,0,0,100,0), -- 10:10:44 +(@PATH,51,-4255.84,-11843.93,-112.396,0,0,0,0,100,0), -- 10:10:44 +(@PATH,52,-4257.34,-11844.68,-112.396,0,0,0,0,100,0), -- 10:10:44 +(@PATH,53,-4259.59,-11846.18,-112.396,0,0,0,0,100,0), -- 10:10:44 +(@PATH,54,-4266.089,-11844.57,-112.6297,0,0,0,0,100,0), -- 10:10:51 +(@PATH,55,-4267.195,-11842.41,-112.1786,0,0,0,0,100,0), -- 10:10:54 +(@PATH,56,-4278.661,-11823.64,-99.84711,0,0,0,0,100,0), -- 10:11:03 +(@PATH,57,-4271.714,-11815.94,-99.62749,0,0,0,0,100,0), -- 10:11:06 +(@PATH,58,-4269.714,-11815.19,-99.62749,0,0,0,0,100,0), -- 10:11:06 +(@PATH,59,-4266.714,-11813.94,-99.62749,0,0,0,0,100,0), -- 10:11:06 +(@PATH,60,-4249.543,-11807.19,-99.2198,0,0,0,0,100,0), -- 10:11:13 +(@PATH,61,-4238.826,-11807.14,-95.64388,0,0,0,0,100,0), -- 10:11:21 +(@PATH,62,-4234.899,-11806.84,-95.56003,0,0,0,0,100,0), -- 10:11:25 +(@PATH,63,-4230.451,-11804.73,-95.52745,0,0,0,0,100,0), -- 10:11:28 +(@PATH,64,-4237.342,-11793.27,-95.53383,0,0,0,0,100,0), -- 10:11:30 +(@PATH,65,-4244.645,-11797.43,-95.85562,0,0,0,0,100,0), -- 10:11:34 +(@PATH,66,-4247.373,-11799.21,-95.78325,0,0,0,0,100,0), -- 10:11:38 +(@PATH,67,-4252.373,-11802.46,-99.03325,0,0,0,0,100,0), -- 10:11:38 +(@PATH,68,-4270.794,-11813.47,-99.60289,0,0,0,0,100,0), -- 10:11:48 +(@PATH,69,-4284.358,-11814.79,-99.57885,0,0,0,0,100,0), -- 10:11:55 +(@PATH,70,-4291.358,-11801.79,-94.07885,0,0,0,0,100,0), -- 10:11:55 +(@PATH,71,-4292.858,-11799.29,-94.07885,0,0,0,0,100,0), -- 10:11:55 +(@PATH,72,-4294.358,-11796.54,-94.07885,0,0,0,0,100,0), -- 10:11:55 +(@PATH,73,-4282.959,-11793.07,-93.84309,0,0,0,0,100,0), -- 10:12:07 +(@PATH,74,-4266.636,-11784.24,-93.59824,0,0,0,0,100,0), -- 10:12:14 +(@PATH,75,-4252.229,-11768.59,-93.55703,0,0,0,0,100,0); -- 10:12:24 + +-- Pathing for Worker Entry: 18800 'TDB FORMAT' +SET @NPC := 67155; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-4045.227,`position_y`=-11567.36,`position_z`=-138.4557 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-4045.227,-11567.36,-138.4557,2.657736,60000,0,0,100,0), -- 10:20:52 +(@PATH,2,-4041.453,-11566.98,-138.16,0,0,0,0,100,0), -- 10:21:06 +(@PATH,3,-4037.367,-11566.4,-138.3107,0,0,0,0,100,0), -- 10:21:08 +(@PATH,4,-4031.307,-11552.28,-137.9972,0,0,0,0,100,0), -- 10:21:13 +(@PATH,5,-4042.002,-11530.51,-138.0085,0,0,0,0,100,0), -- 10:21:19 +(@PATH,6,-4041.574,-11527.51,-138.0677,0,0,0,0,100,0), -- 10:21:24 +(@PATH,7,-4038.824,-11520.26,-141.0677,0,0,0,0,100,0), -- 10:21:24 +(@PATH,8,-4026.281,-11500.64,-140.7895,0,0,0,0,100,0), -- 10:21:29 +(@PATH,9,-4015.825,-11486.67,-139.4373,0,0,0,0,100,0), -- 10:21:42 +(@PATH,10,-4014.075,-11484.67,-138.1873,0,0,0,0,100,0), -- 10:21:42 +(@PATH,11,-4012.325,-11483.17,-137.1873,0,0,0,0,100,0), -- 10:21:42 +(@PATH,12,-4009.575,-11480.42,-137.1873,0,0,0,0,100,0), -- 10:21:42 +(@PATH,13,-3995.471,-11465.6,-136.9284,0,0,0,0,100,0), -- 10:21:51 +(@PATH,14,-3967.808,-11441.67,-136.644,0,0,0,0,100,0), -- 10:22:00 +(@PATH,15,-3952.092,-11437.37,-136.3886,0,0,0,0,100,0), -- 10:22:13 +(@PATH,16,-3933.094,-11436.87,-134.5441,0,0,0,0,100,0), -- 10:22:20 +(@PATH,17,-3913.105,-11438.32,-132.681,0,0,0,0,100,0), -- 10:22:28 +(@PATH,18,-3905.355,-11438.57,-132.681,0,0,0,0,100,0), -- 10:22:28 +(@PATH,19,-3898.855,-11439.07,-132.681,0,0,0,0,100,0), -- 10:22:28 +(@PATH,20,-3894.605,-11439.32,-132.681,0,0,0,0,100,0), -- 10:22:28 +(@PATH,21,-3878.679,-11443.58,-132.5145,0,0,0,0,100,0), -- 10:22:44 +(@PATH,22,-3872.179,-11446.33,-132.2645,0,0,0,0,100,0), -- 10:22:44 +(@PATH,23,-3840.745,-11457.86,-131.9258,0,0,0,0,100,0), -- 10:22:59 +(@PATH,24,-3839.995,-11457.86,-131.9258,0,0,0,0,100,0), -- 10:22:59 +(@PATH,25,-3834.995,-11459.36,-135.1758,0,0,0,0,100,0), -- 10:22:59 +(@PATH,26,-3829.995,-11461.11,-138.1758,0,0,0,0,100,0), -- 10:22:59 +(@PATH,27,-3828.745,-11461.61,-138.1758,0,0,0,0,100,0), -- 10:22:59 +(@PATH,28,-3825.995,-11462.36,-138.1758,0,0,0,0,100,0), -- 10:22:59 +(@PATH,29,-3819.628,-11464.71,-138.4012,0,0,0,0,100,0), -- 10:23:11 +(@PATH,30,-3812.128,-11467.21,-138.1512,0,0,0,0,100,0), -- 10:23:11 +(@PATH,31,-3795.622,-11472.34,-137.6514,0,0,0,0,100,0), -- 10:23:21 +(@PATH,32,-3789.372,-11473.84,-134.6514,0,0,0,0,100,0), -- 10:23:21 +(@PATH,33,-3786.872,-11474.34,-134.4014,0,0,0,0,100,0), -- 10:23:21 +(@PATH,34,-3778.248,-11477.4,-134.2023,0,20000,0,0,100,0), -- 10:23:29 +(@PATH,35,-3779.69,-11479.03,-134.2154,0,0,0,0,100,0), -- 10:23:51 +(@PATH,36,-3790.385,-11476.55,-134.3773,0,0,0,0,100,0), -- 10:23:57 +(@PATH,37,-3795.885,-11475.05,-137.3773,0,0,0,0,100,0), -- 10:23:57 +(@PATH,38,-3796.885,-11474.8,-137.8773,0,0,0,0,100,0), -- 10:23:57 +(@PATH,39,-3798.306,-11474.22,-137.853,0,0,0,0,100,0), -- 10:24:02 +(@PATH,40,-3800.556,-11473.22,-137.853,0,0,0,0,100,0), -- 10:24:02 +(@PATH,41,-3812.556,-11467.97,-137.853,0,0,0,0,100,0), -- 10:24:02 +(@PATH,42,-3819.806,-11464.72,-138.103,0,0,0,0,100,0), -- 10:24:02 +(@PATH,43,-3825.306,-11462.22,-138.103,0,0,0,0,100,0), -- 10:24:02 +(@PATH,44,-3829.718,-11460.37,-138.1092,0,0,0,0,100,0), -- 10:24:15 +(@PATH,45,-3834.718,-11458.62,-135.1092,0,0,0,0,100,0), -- 10:24:15 +(@PATH,46,-3839.718,-11456.87,-132.1092,0,0,0,0,100,0), -- 10:24:15 +(@PATH,47,-3840.718,-11456.62,-132.1092,0,0,0,0,100,0), -- 10:24:15 +(@PATH,48,-3872.166,-11446.86,-132.4203,0,0,0,0,100,0), -- 10:24:22 +(@PATH,49,-3880.416,-11444.36,-132.4203,0,0,0,0,100,0), -- 10:24:22 +(@PATH,50,-3894.63,-11440.23,-132.5016,0,0,0,0,100,0), -- 10:24:39 +(@PATH,51,-3898.38,-11438.98,-132.7516,0,0,0,0,100,0), -- 10:24:39 +(@PATH,52,-3905.38,-11436.98,-132.7516,0,0,0,0,100,0), -- 10:24:39 +(@PATH,53,-3909.953,-11436.46,-132.7919,0,0,0,0,100,0), -- 10:24:49 +(@PATH,54,-3919.703,-11436.96,-132.7919,0,0,0,0,100,0), -- 10:24:49 +(@PATH,55,-3932.703,-11437.46,-134.2919,0,0,0,0,100,0), -- 10:24:49 +(@PATH,56,-3955.675,-11438.13,-136.1737,0,0,0,0,100,0), -- 10:25:01 +(@PATH,57,-3967.982,-11443.01,-136.5633,0,0,0,0,100,0), -- 10:25:10 +(@PATH,58,-3987.157,-11453.09,-136.8458,0,0,0,0,100,0), -- 10:25:22 +(@PATH,59,-3990.157,-11456.09,-136.8458,0,0,0,0,100,0), -- 10:25:22 +(@PATH,60,-3998.407,-11464.34,-137.0958,0,0,0,0,100,0), -- 10:25:22 +(@PATH,61,-3999.407,-11465.34,-137.0958,0,0,0,0,100,0), -- 10:25:22 +(@PATH,62,-4014.187,-11479.69,-137.1316,0,0,0,0,100,0), -- 10:25:33 +(@PATH,63,-4015.437,-11481.19,-138.1316,0,0,0,0,100,0), -- 10:25:33 +(@PATH,64,-4017.937,-11483.44,-139.6316,0,0,0,0,100,0), -- 10:25:33 +(@PATH,65,-4019.687,-11485.19,-140.6316,0,0,0,0,100,0), -- 10:25:33 +(@PATH,66,-4020.62,-11486.18,-140.636,0,0,0,0,100,0), -- 10:25:41 +(@PATH,67,-4029.12,-11499.68,-140.886,0,0,0,0,100,0), -- 10:25:41 +(@PATH,68,-4042.905,-11526.72,-138.0882,0,0,0,0,100,0), -- 10:25:57 +(@PATH,69,-4041.908,-11531.32,-138.0012,0,0,0,0,100,0), -- 10:26:02 +(@PATH,70,-4035.658,-11537.57,-138.0012,0,0,0,0,100,0), -- 10:26:02 +(@PATH,71,-4033.483,-11539.54,-137.9768,0,0,0,0,100,0), -- 10:26:08 +(@PATH,72,-4033.447,-11555.33,-138.039,0,0,0,0,100,0), -- 10:26:12 +(@PATH,73,-4041.411,-11566.91,-138.1366,0,0,0,0,100,0), -- 10:26:19 +(@PATH,74,-4043.277,-11567.36,-138.179,0,0,0,0,100,0); -- 10:26:21 + +-- Add missing Exodar Peace Keepers +SET @CGUID:=87912; +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+15; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `curhealth`) VALUES +(@CGUID+0, 16733, 530, -4014.95, -11691.79, -134.8826, 3.211406, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+1, 16733, 530, -3872.768, -11745.65, -107.2824, 1.937315, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+2, 16733, 530, -3858.128, -11736.21, -107.0747, 2.111848, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+3, 16733, 530, -3874.034, -11619.76, -137.4797, 4.118977, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+4, 16733, 530, -3896.759, -11608.23, -137.7288, 4.13643, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+5, 16733, 530, -3883.912, -11577.22, -132.7659, 1.169371, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+6, 16733, 530, -3857.081, -11591.1, -132.5431, 0.8901179, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+7, 16733, 530, -3928.165, -11568.19, -150.2529, 1.012291, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+8, 16733, 530, -3983.486, -11659.17, -139.0413, 6.126106, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+9, 16733, 530, -4128.439, -11441.22, -130.4346, 3.892084, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+10, 16733, 530, -4145.358, -11432.4, -130.6977, 4.13643, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+11, 16733, 530, -3958.252, -11432.68, -136.5482, 3.089233, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+12, 16733, 530, -3957.141, -11443.25, -136.5704, 2.984513, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+13, 16733, 530, -3914.363, -11441.08, -132.8212, 0.01745329, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+14, 16733, 530, -3915.224, -11430.32, -132.7888, 0, 120, 0), -- 16733 (Area: -1) (Auras: ) +(@CGUID+15, 16733, 530, -3735.099, -11505.95, -133.9994, 2.722714, 120, 0); -- 16733 (Area: -1) (Auras: ) diff --git a/sql/updates/world/2016_01_17_09_world.sql b/sql/updates/world/2016_01_17_09_world.sql new file mode 100644 index 00000000000..85e6f535866 --- /dev/null +++ b/sql/updates/world/2016_01_17_09_world.sql @@ -0,0 +1,31 @@ +SET @OGUID:=6362; +SET @CGUID:=78301; +SET @Event:=2; + +DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+2; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0, 180796, 0, 1, 1, -3826.189, -771.3663, 8.083211, 2.146753, 0, 0, 0, 1, 120, 255, 1), -- 180796 (Area: 150) +(@OGUID+1, 180797, 0, 1, 1, -3825.66, -770.9445, 8.083211, 5.270896, 0, 0, 0, 1, 120, 255, 1), -- 180797 (Area: 150) +(@OGUID+2, 178746, 0, 1, 1, -3822.936, -769.4861, 8.083211, 1.518436, 0, 0, 0, 1, 120, 255, 1); -- 178746 (Area: 150) + +DELETE FROM `game_event_gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+2 AND `eventEntry`=@Event; +INSERT INTO `game_event_gameobject` SELECT @Event, gameobject.guid FROM `gameobject` WHERE gameobject.guid BETWEEN @OGUID+0 AND @OGUID+2; + +-- Add spawns Pat's Snowcloud Guy & Wonderform Operator <Smokywood Pastures> +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+10; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `curhealth`) VALUES +(@CGUID+0, 15730, 0, 2051.343, 272.4555, 57.25123, 0, 120, 0), -- 15730 (Area: 159) (Auras: 26000 - 26000) +(@CGUID+1, 15730, 0, 2051.359, 272.4567, 57.25214, 0, 120, 0), -- 15730 (Area: 159) (Auras: 26000 - 26000) +(@CGUID+2, 15730, 0, -5049.26, -818.5426, 495.3753, 0, 120, 0), -- 15730 (Area: 809) (Auras: 26000 - 26000) +(@CGUID+3, 15730, 0, -5049.293, -818.5344, 495.3785, 0, 120, 0), -- 15730 (Area: 809) (Auras: 26000 - 26000) +(@CGUID+4, 15730, 0, -8823.889, 540.5417, 96.89484, 5.951573, 120, 0), -- 15730 (Area: 5148) (Auras: 26000 - 26000) +(@CGUID+5, 15730, 0, -8823.89, 540.528, 96.89533, 2.443461, 120, 0), -- 15730 (Area: 5148) (Auras: 26000 - 26000) +(@CGUID+6, 15730, 0, -14294.22, 516.1476, 9.037167, 5.340707, 120, 0), -- 15730 (Area: 35) (Auras: 26000 - 26000) +(@CGUID+7, 15730, 0, -14294.3, 516.146, 9.037253, 1.815142, 120, 0), -- 15730 (Area: 35) (Auras: 26000 - 26000) +(@CGUID+8, 15730, 0, -3826.132, -771.75, 8.083211, 0.1396263, 120, 0), -- 15730 (Area: 150) (Auras: 26000 - 26000) +(@CGUID+9, 15730, 0, -3826.108, -771.7864, 8.083211, 3.665191, 120, 0), -- 15730 (Area: 150) (Auras: 26000 - 26000) +(@CGUID+10, 15732, 0, -3821.368, -768.9375, 8.083211, 1.745329, 120, 0); -- 15732 (Area: 150) + +DELETE FROM `game_event_creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+10 AND `eventEntry`=@Event; +INSERT INTO `game_event_creature` SELECT @Event, creature.guid FROM `creature` WHERE creature.guid BETWEEN @CGUID+0 AND @CGUID+10; + diff --git a/sql/updates/world/2016_01_17_10_world.sql b/sql/updates/world/2016_01_17_10_world.sql new file mode 100644 index 00000000000..0fdc04eb60f --- /dev/null +++ b/sql/updates/world/2016_01_17_10_world.sql @@ -0,0 +1 @@ +UPDATE `creature` SET `MovementType`=0 WHERE `guid`=131180; diff --git a/sql/updates/world/2016_01_17_11_world.sql b/sql/updates/world/2016_01_17_11_world.sql new file mode 100644 index 00000000000..9ab963a2ff2 --- /dev/null +++ b/sql/updates/world/2016_01_17_11_world.sql @@ -0,0 +1,10 @@ +UPDATE `smart_scripts` SET `event_type`=4 WHERE `entryorguid` in (18942,7823,18789,16587,17554,2859,2858,523,352,26876,3615,18937,24032,26852,16192,4312,27344,1571,12596,2409,931,6026,12577,16822,1572,8610,4407,1387,3310,19181,18808,1573,2995,2835,3838,2389,12740,2226,18939,3841,2299,26879,18931,2432,10897,6726,2851,2861,2941,12578,4321,3305,4314,11899,15178,31426,12636,4267,26881,4317,4319,4551,22935,6706,7824,8018,8019,8020,20762,18791,8609,12616,18807,19317,26878,10378,11138,11139,37915,26846,22485,11900,11901,12617,13177,18938,15177,16189,16227,17555,24366,18785,18788,18809,26602,18930,18953,19558,20234,21107,26844,22936,23736,24061,24155,26847,25288,26566,26845,26848,26850,26853,26877,26880,29762,30271) and id =2; +UPDATE `smart_scripts` SET `link`=3, `event_type`=4 WHERE `entryorguid`=18931 AND `source_type`=0 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `link`=2 WHERE `entryorguid`=26602 AND `source_type`=0 AND `id`=0 AND `link`=0; +UPDATE `smart_scripts` SET `link`=2 WHERE `entryorguid`=26853 AND `source_type`=0 AND `id`=0 AND `link`=0; +UPDATE `smart_scripts` SET `link`=2 WHERE `entryorguid`=26881 AND `source_type`=0 AND `id`=0 AND `link`=0; +UPDATE `smart_scripts` SET `link`=2 WHERE `entryorguid`=20234 AND `source_type`=0 AND `id`=0 AND `link`=0; +UPDATE `smart_scripts` SET `link`=2 WHERE `entryorguid`=26876 AND `source_type`=0 AND `id`=0 AND `link`=0; +UPDATE `smart_scripts` SET `link`=3, `event_type`=4 WHERE `entryorguid`=18930 AND `source_type`=0 AND `id`=2 AND `link`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=2385900 AND `source_type`=9 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `action_type`=11, `action_param1`=14313, `action_param2`=2, `action_param3`=0, `target_type`=1 WHERE `entryorguid`=2385900 AND `source_type`=9 AND `id`=1 AND `link`=0; diff --git a/sql/updates/world/2016_01_17_12_world.sql b/sql/updates/world/2016_01_17_12_world.sql new file mode 100644 index 00000000000..e4e8ab5e9e2 --- /dev/null +++ b/sql/updates/world/2016_01_17_12_world.sql @@ -0,0 +1,30 @@ +-- +SET @pool_id=369; +SET @GUID=87572; +DELETE FROM `pool_template` WHERE `entry` = @pool_id; +INSERT INTO `pool_template` (`entry`, `max_limit`, `description`) VALUES +(@pool_id, 5, 'Ethereum Jailor'); + +DELETE FROM `pool_creature` WHERE `guid` BETWEEN @GUID AND @GUID+20; +INSERT INTO `pool_creature` (`guid`, `pool_entry`, `chance`, `description`) VALUES +(@GUID+0, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+1, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+2, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+3, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+4, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+5, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+6, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+7, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+8, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+9, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+10, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+11, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+12, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+13, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+14, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+15, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+16, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+17, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+18, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+19, @pool_id, 0, 'Ethereum Jailor'), +(@Guid+20, @pool_id, 0, 'Ethereum Jailor'); diff --git a/sql/updates/world/2016_01_17_13_world.sql b/sql/updates/world/2016_01_17_13_world.sql new file mode 100644 index 00000000000..163aa3fb659 --- /dev/null +++ b/sql/updates/world/2016_01_17_13_world.sql @@ -0,0 +1,3 @@ +-- +DELETE FROM `creature` WHERE `guid`=66270; +UPDATE `creature` SET `position_x`=-3047.323, `position_y`=4081.128, `position_z`=2.707369, `orientation`=5.484657, `spawndist`=10, `MovementType`=1 WHERE `guid`=66343; diff --git a/sql/updates/world/2016_01_17_14_world.sql b/sql/updates/world/2016_01_17_14_world.sql new file mode 100644 index 00000000000..c8b9405abff --- /dev/null +++ b/sql/updates/world/2016_01_17_14_world.sql @@ -0,0 +1,203 @@ +-- Delete all existing spawns +DELETE FROM `creature` WHERE `guid` IN (97259, 97261, 97258, 97257, 97256, 97255, 131106, 109804, 109803, 109802); + +-- Respawn all spawns +SET @CGUID:=134849; +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+31; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `curhealth`) VALUES +(@CGUID+0 , 27284, 571, 3970.129, -831.1373, 123.1972, 1.419617, 120, 10, 0), -- 27284 (Area: 4177) (possible waypoints or random movement) +(@CGUID+1 , 27284, 571, 3892.15, -898.545, 116.7031, 4.747295, 120, 0, 0), -- 27284 (Area: 0) (Auras: 51307 - 51307) +(@CGUID+2 , 27284, 571, 3877.338, -886.6799, 119.6563, 5.410521, 120, 0, 0), -- 27284 (Area: 0) (Auras: 51307 - 51307) +(@CGUID+3 , 27284, 571, 3981.821, -915.338, 103.8165, 0.4941546, 120, 10, 0), -- 27284 (Area: 4178) (possible waypoints or random movement) +(@CGUID+4 , 27284, 571, 4063.601, -863.5172, 112.0916, 3.294994, 120, 10, 0), -- 27284 (Area: 0) (possible waypoints or random movement) +(@CGUID+5 , 27284, 571, 4029.796, -817.8798, 122.6137, 5.148721, 120, 10, 0), -- 27284 (Area: 0) (possible waypoints or random movement) +(@CGUID+6 , 27284, 571, 4020.966, -913.8099, 107.1895, 1.902651, 120, 0, 0), -- 27284 (Area: 0) +(@CGUID+7 , 27401, 571, 4012.309, -778.3416, 119.4081, 5.117236, 120, 10, 0), -- 27401 (Area: 4177) (Auras: ) (possible waypoints or random movement) +(@CGUID+8 , 27401, 571, 3957.39, -879.4473, 120.6337, 1.665177, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+9 , 27401, 571, 3979.763, -878.6928, 118.7674, 2.167667, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+10, 27401, 571, 3891.449, -871.9622, 110.0855, 4.131083, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+11, 27401, 571, 3908.99, -867.735, 108.25, 0.07704493, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+12, 27401, 571, 4005.749, -911.3463, 107.528, 3.572126, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+13, 27401, 571, 4018.18, -838.5659, 120.1189, 3.396627, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+14, 27401, 571, 3997.235, -935.1, 104.7279, 0.895307, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+15, 27401, 571, 4046.337, -872.1385, 115.5023, 2.777797, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+16, 27401, 571, 4040.803, -824.1927, 119.995, 3.689994, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+17, 27401, 571, 4079.794, -860.7454, 111.5424, 3.844261, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+18, 27401, 571, 4112.891, -862.1273, 114.5041, 5.726786, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+19, 27401, 571, 3962.095, -841.9584, 121.1146, 1.314913, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+20, 27401, 571, 3972.828, -817.3924, 124.1117, 1.684451, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+21, 27401, 571, 3927.054, -862.1707, 121.9197, 5.969274, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+22, 27401, 571, 3983.165, -884.7412, 117.6653, 3.801475, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+23, 27401, 571, 4000.266, -806.4115, 124.4378, 2.8901, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+24, 27401, 571, 3996.695, -804.8523, 124.5836, 5.710121, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+25, 27401, 571, 4029.536, -842.3114, 117.1135, 5.811058, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+26, 27401, 571, 4063.478, -903.8126, 115.2312, 3.785855, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+27, 27401, 571, 3971.025, -913.7602, 104.5964, 1.58825, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+28, 27401, 571, 3992.506, -939.1702, 105.5502, 4.213991, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+29, 27401, 571, 3930.066, -870.2675, 104.4508, 0.4872836, 120, 10, 0), -- 27401 (Area: 0) (Auras: ) (possible waypoints or random movement) +(@CGUID+30, 27401, 571, 3961.272, -872.5833, 104.2002, 2.95032, 120, 0, 0), -- 27401 (Area: 0) (Auras: ) +(@CGUID+31, 27401, 571, 3912.686, -865.0364, 120.8479, 6.199958, 120, 0, 0); -- 27401 (Area: 0) (Auras: ) + +-- Pathing for Risen Wintergarde Defender Entry: 27284 'TDB FORMAT' +SET @NPC := 134849; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=3962.255,`position_y`=-845.7626,`position_z`=120.7226 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,3962.255,-845.7626,120.7226,0,0,0,0,100,0), -- 17:07:32 +(@PATH,2,3964.674,-842.7882,121.4607,0,0,0,0,100,0), -- 17:07:33 +(@PATH,3,3967.174,-837.5382,122.2107,0,0,0,0,100,0), -- 17:07:33 +(@PATH,4,3971.408,-823.0021,124.1822,0,0,0,0,100,0), -- 17:07:39 +(@PATH,5,3972.536,-818.4142,124.181,0,0,0,0,100,0), -- 17:07:44 +(@PATH,6,3974.286,-811.9142,124.181,0,0,0,0,100,0), -- 17:07:44 +(@PATH,7,3977.374,-807.4382,123.8934,0,0,0,0,100,0), -- 17:07:49 +(@PATH,8,3990.374,-797.4382,122.8934,0,0,0,0,100,0), -- 17:07:49 +(@PATH,9,3996.358,-796.3887,122.3552,0,0,0,0,100,0), -- 17:07:58 +(@PATH,10,4002.608,-795.8887,121.8552,0,0,0,0,100,0), -- 17:07:58 +(@PATH,11,4005.141,-794.809,121.2954,0,0,0,0,100,0), -- 17:08:19 +(@PATH,12,3991.292,-796.7651,122.3158,0,0,0,0,100,0), -- 17:08:19 +(@PATH,13,3989.065,-798.5057,122.8027,0,0,0,0,100,0), -- 17:08:23 +(@PATH,14,3977.315,-807.5057,123.8027,0,0,0,0,100,0), -- 17:08:23 +(@PATH,15,3973.799,-814.1797,124.0833,0,0,0,0,100,0), -- 17:08:32 +(@PATH,16,3972.049,-819.9297,124.0833,0,0,0,0,100,0), -- 17:08:32 +(@PATH,17,3971.736,-820.819,124.0339,0,0,0,0,100,0), -- 17:08:37 +(@PATH,18,3970.236,-831.069,123.5339,0,0,0,0,100,0), -- 17:08:37 +(@PATH,19,3967.212,-837.6317,122.1643,0,0,0,0,100,0), -- 17:08:41 +(@PATH,20,3964.712,-842.6317,121.4143,0,0,0,0,100,0), -- 17:08:41 +(@PATH,21,3955.197,-848.4968,121.6359,0,0,0,0,100,0), -- 17:08:48 +(@PATH,22,3950.197,-850.4968,122.3859,0,0,0,0,100,0), -- 17:08:48 +(@PATH,23,3946.476,-852.2645,122.539,0,0,0,0,100,0), -- 17:08:54 +(@PATH,24,3938.226,-855.0145,122.289,0,0,0,0,100,0), -- 17:08:54 +(@PATH,25,3935.217,-855.6635,122.2252,0,0,0,0,100,0), -- 17:08:59 +(@PATH,26,3928.967,-856.4135,121.7252,0,0,0,0,100,0), -- 17:08:59 +(@PATH,27,3935.146,-855.8206,122.0987,0,0,0,0,100,0), -- 17:09:05 +(@PATH,28,3938.241,-854.9574,122.219,0,0,0,0,100,0), -- 17:09:07 +(@PATH,29,3946.491,-852.2074,122.719,0,0,0,0,100,0), -- 17:09:07 +(@PATH,30,3954.914,-848.747,121.6653,0,0,0,0,100,0); -- 17:09:13 + +-- Pathing for Risen Wintergarde Defender Entry: 27284 'TDB FORMAT' +SET @NPC := 134854; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=4008.271,`position_y`=-870.0803,`position_z`=117.5745 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,4008.271,-870.0803,117.5745,0,0,0,0,100,0), -- 16:58:23 +(@PATH,2,3996.876,-880.48,118.3026,0,0,0,0,100,0), -- 16:58:29 +(@PATH,3,3991.834,-882.1507,118.5546,0,0,0,0,100,0), -- 16:58:32 +(@PATH,4,3961.252,-886.0806,119.2003,0,0,0,0,100,0), -- 16:58:43 +(@PATH,5,3958.834,-887.8701,119.2766,0,0,0,0,100,0), -- 16:58:47 +(@PATH,6,3958.712,-888.809,119.2599,0,0,0,0,100,0), -- 16:58:48 +(@PATH,7,3983.712,-886.309,118.0099,0,0,0,0,100,0), -- 16:58:48 +(@PATH,8,3990.516,-884.9421,118.4627,0,0,0,0,100,0), -- 16:58:59 +(@PATH,9,4001.527,-882.609,118.6914,0,0,0,0,100,0), -- 16:59:05 +(@PATH,10,4009.196,-881.325,118.3849,0,0,0,0,100,0), -- 16:59:09 +(@PATH,11,4017.301,-863.9352,116.9195,0,0,0,0,100,0), -- 16:59:16 +(@PATH,12,4023.301,-849.1852,116.9195,0,0,0,0,100,0), -- 16:59:16 +(@PATH,13,4025.668,-847.6936,116.7459,0,0,0,0,100,0), -- 16:59:23 +(@PATH,14,4036.918,-842.1936,116.7459,0,0,0,0,100,0), -- 16:59:23 +(@PATH,15,4041.683,-837.2839,117.6779,0,0,0,0,100,0), -- 16:59:31 +(@PATH,16,4031.176,-820.0336,121.8801,0,0,0,0,100,0), -- 16:59:47 +(@PATH,17,4027.651,-834.1048,118.0815,0,0,0,0,100,0), -- 16:59:47 +(@PATH,18,4023.714,-843.688,117.5524,0,0,0,0,100,0), -- 16:59:50 +(@PATH,19,4020.757,-848.9363,117.5502,0,0,0,0,100,0), -- 16:59:55 +(@PATH,20,4010.505,-867.1548,117.3328,0,0,0,0,100,0); -- 17:00:03 + +-- Pathing for Risen Wintergarde Defender Entry: 27284 'TDB FORMAT' +SET @NPC := 134855; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=3998.09,`position_y`=-941.3831,`position_z`=105.5378 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,3998.09,-941.3831,105.5378,0,0,0,0,100,0), -- 16:58:00 +(@PATH,2,3982.87,-921.863,104.2338,0,0,0,0,100,0), -- 16:58:00 +(@PATH,3,3980.532,-918.3081,104.4937,0,0,0,0,100,0), -- 16:58:01 +(@PATH,4,3980.812,-915.6993,104.2544,0,0,0,0,100,0), -- 16:58:03 +(@PATH,5,3993.312,-909.1993,106.0044,0,0,0,0,100,0), -- 16:58:03 +(@PATH,6,4001.392,-906.8644,107.0495,0,0,0,0,100,0), -- 16:58:10 +(@PATH,7,4005.606,-907.3997,107.3568,0,0,0,0,100,0), -- 16:58:13 +(@PATH,8,4018.356,-914.8997,106.8568,0,0,0,0,100,0), -- 16:58:13 +(@PATH,9,4019.2,-915.515,107.0822,0,0,0,0,100,0), -- 16:58:21 +(@PATH,10,4016.712,-901.4606,107.2446,0,0,0,0,100,0), -- 16:58:23 +(@PATH,11,4006.091,-900.8485,107.6517,0,0,0,0,100,0), -- 16:58:28 +(@PATH,12,3999.341,-903.3485,107.4017,0,0,0,0,100,0), -- 16:58:28 +(@PATH,13,3990.741,-907.1246,106.0392,0,0,0,0,100,0), -- 16:58:38 +(@PATH,14,3981.241,-911.3746,104.0392,0,0,0,0,100,0), -- 16:58:38 +(@PATH,15,3998.09,-941.3831,105.5378,0,0,0,0,100,0); -- 16:59:21 + +-- Pathing for Risen Wintergarde Defender Entry: 27284 'TDB FORMAT' +SET @NPC := 134852; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=3954.649,`position_y`=-896.4279,`position_z`=104.172 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,3954.649,-896.4279,104.172,0,0,0,0,100,0), -- 16:57:59 +(@PATH,2,3956.389,-893.2208,104.3171,0,0,0,0,100,0), -- 16:58:01 +(@PATH,3,3950.639,-880.2208,104.8171,0,0,0,0,100,0), -- 16:58:01 +(@PATH,4,3948.071,-877.5638,104.6277,0,0,0,0,100,0), -- 16:58:09 +(@PATH,5,3934.321,-870.3138,103.8777,0,0,0,0,100,0), -- 16:58:09 +(@PATH,6,3933.527,-870.0614,103.9755,0,0,0,0,100,0), -- 16:58:16 +(@PATH,7,3922.027,-870.3114,105.9755,0,0,0,0,100,0), -- 16:58:16 +(@PATH,8,3917.903,-870.4968,106.363,0,0,0,0,100,0), -- 16:58:22 +(@PATH,9,3905.903,-870.4968,108.363,0,0,0,0,100,0), -- 16:58:22 +(@PATH,10,3897.389,-869.1989,109.0091,0,0,0,0,100,0), -- 16:58:28 +(@PATH,11,3895.139,-868.6989,109.0091,0,0,0,0,100,0), -- 16:58:28 +(@PATH,12,3893.163,-868.3932,109.3621,0,0,0,0,100,0), -- 16:58:33 +(@PATH,13,3903.502,-871.1569,108.7203,0,0,0,0,100,0), -- 16:58:34 +(@PATH,14,3918.319,-872.118,105.7782,0,0,0,0,100,0), -- 16:58:49 +(@PATH,15,3935.749,-871.7728,103.4062,0,0,0,0,100,0), -- 16:58:49 +(@PATH,16,3937.464,-872.5975,104.0017,0,0,0,0,100,0), -- 16:58:51 +(@PATH,17,3946.714,-877.3475,104.5017,0,0,0,0,100,0), -- 16:58:51 +(@PATH,18,3953.698,-875.124,104.5628,0,0,0,0,100,0), -- 16:58:57 +(@PATH,19,3959.198,-868.874,104.0628,0,0,0,0,100,0), -- 16:58:57 +(@PATH,20,3964.888,-870.4577,104.2536,0,0,0,0,100,0), -- 16:59:04 +(@PATH,21,3960.319,-875.5621,104.8488,0,0,0,0,100,0), -- 16:59:07 +(@PATH,22,3955.069,-879.8121,104.8488,0,0,0,0,100,0), -- 16:59:07 +(@PATH,23,3953.761,-883.5623,104.9101,0,0,0,0,100,0), -- 16:59:13 +(@PATH,24,3954.511,-894.0623,104.4101,0,0,0,0,100,0); -- 16:59:13 + +-- Pathing for Risen Wintergarde Defender Entry: 27284 'TDB FORMAT' +SET @NPC := 134853; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=4070.011,`position_y`=-911.9304,`position_z`=115.397 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,4070.011,-911.9304,115.397,0,0,0,0,100,0), -- 17:00:27 +(@PATH,2,4063.844,-904.7043,115.3745,0,0,0,0,100,0), -- 17:00:29 +(@PATH,3,4058.64,-895.9709,115.1423,0,0,0,0,100,0), -- 17:00:34 +(@PATH,4,4057.89,-894.7209,115.1423,0,0,0,0,100,0), -- 17:00:34 +(@PATH,5,4055.97,-891.5008,115.2825,0,0,0,0,100,0), -- 17:00:38 +(@PATH,6,4052.97,-881.5008,114.5325,0,0,0,0,100,0), -- 17:00:38 +(@PATH,7,4052.165,-878.6388,114.2091,0,0,0,0,100,0), -- 17:00:44 +(@PATH,8,4051.415,-864.6388,113.4591,0,0,0,0,100,0), -- 17:00:44 +(@PATH,9,4054.136,-862.9764,112.8409,0,0,0,0,100,0), -- 17:00:50 +(@PATH,10,4066.636,-860.9764,112.3409,0,0,0,0,100,0), -- 17:00:50 +(@PATH,11,4072.034,-859.8044,112.1062,0,0,0,0,100,0), -- 17:00:57 +(@PATH,12,4086.284,-857.0544,112.1062,0,0,0,0,100,0), -- 17:00:57 +(@PATH,13,4091.908,-853.9102,112.7256,0,0,0,0,100,0), -- 17:01:05 +(@PATH,14,4101.408,-844.1602,113.7256,0,0,0,0,100,0), -- 17:01:05 +(@PATH,15,4105.021,-846.8843,114.2492,0,0,0,0,100,0), -- 17:01:14 +(@PATH,16,4106.521,-848.6343,114.2492,0,0,0,0,100,0), -- 17:01:14 +(@PATH,17,4109.933,-852.9023,114.737,0,0,0,0,100,0), -- 17:01:18 +(@PATH,18,4111.266,-854.6176,115.0273,0,0,0,0,100,0), -- 17:01:19 +(@PATH,19,4108.093,-862.4123,113.6716,0,0,0,0,100,0), -- 17:01:22 +(@PATH,20,4093.593,-861.4123,113.6716,0,0,0,0,100,0), -- 17:01:22 +(@PATH,21,4087.883,-860.7225,112.5768,0,0,0,0,100,0), -- 17:01:30 +(@PATH,22,4084.479,-860.3036,112.2872,0,0,0,0,100,0), -- 17:01:32 +(@PATH,23,4063.229,-863.3036,112.5372,0,0,0,0,100,0), -- 17:01:32 +(@PATH,24,4059.42,-867.1846,112.8684,0,0,0,0,100,0), -- 17:01:43 +(@PATH,25,4058.17,-873.9346,113.6184,0,0,0,0,100,0), -- 17:01:43 +(@PATH,26,4058.563,-877.7594,113.9066,0,0,0,0,100,0), -- 17:01:47 +(@PATH,27,4060.313,-890.0094,114.1566,0,0,0,0,100,0), -- 17:01:47 +(@PATH,28,4065.274,-896.5776,114.7585,0,0,0,0,100,0), -- 17:01:54 +(@PATH,29,4071.021,-903.6585,115.7979,0,0,0,0,100,0), -- 17:02:00 +(@PATH,30,4073.021,-911.4085,115.0479,0,0,0,0,100,0); -- 17:02:00 diff --git a/sql/updates/world/2016_01_17_15_world.sql b/sql/updates/world/2016_01_17_15_world.sql new file mode 100644 index 00000000000..da949d7100d --- /dev/null +++ b/sql/updates/world/2016_01_17_15_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_text` SET `TextRange`=3 WHERE `entry`=32871; diff --git a/sql/updates/world/2016_01_18_00_world.sql b/sql/updates/world/2016_01_18_00_world.sql new file mode 100644 index 00000000000..85f41cfc0c5 --- /dev/null +++ b/sql/updates/world/2016_01_18_00_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `smart_scripts` SET `action_param2`=0 WHERE `entryorguid`=21126 AND `source_type`=0 AND `id` IN (4,5); diff --git a/sql/updates/world/2016_01_18_01_world.sql b/sql/updates/world/2016_01_18_01_world.sql new file mode 100644 index 00000000000..9768ecda6c0 --- /dev/null +++ b/sql/updates/world/2016_01_18_01_world.sql @@ -0,0 +1,8 @@ +UPDATE `creature` SET `MovementType`=1 WHERE `guid` IN (134870, 134856, 134857, 134859, 134861, 134862, 134863, 134864, 134865, 134866, 134868, 134871, 134878, 134872, 134873, 134874, 134875); +UPDATE `creature` SET `spawndist`=0 WHERE `guid`=131180; + +UPDATE `smart_scripts` SET `event_type`=61 WHERE `entryorguid`=26853 AND `source_type`=0 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `event_type`=61 WHERE `entryorguid`=26881 AND `source_type`=0 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `event_type`=61 WHERE `entryorguid`=20234 AND `source_type`=0 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `event_type`=61 WHERE `entryorguid`=26876 AND `source_type`=0 AND `id`=2 AND `link`=0; +UPDATE `smart_scripts` SET `event_type`=61 WHERE `entryorguid`=26602 AND `source_type`=0 AND `id`=2 AND `link`=0; diff --git a/sql/updates/world/2016_01_18_02_world.sql b/sql/updates/world/2016_01_18_02_world.sql new file mode 100644 index 00000000000..ec9a8748cc8 --- /dev/null +++ b/sql/updates/world/2016_01_18_02_world.sql @@ -0,0 +1,39 @@ +DELETE FROM `smart_scripts` WHERE `entryorguid`IN(27450,27355) AND `source_type`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`IN(2735500) AND `source_type`=9; + +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(27450,0,0,1,8,0,100,0,48790,0,0,0,64,1,0,0,0,0,0,7,0,0,0,0,0,0,0,'Neltharions Flame Control Bunny - On Spellhit (Neltharions Flame) - Store Targetlist'), +(27450,0,1,2,61,0,100,0,48790,0,0,0,33,27450,0,0,0,0,0,7,0,0,0,0,0,0,0,'Neltharions Flame Control Bunny - On Spellhit (Neltharions Flame) - Give Kill Credit'), +(27450,0,2,3,61,0,100,0,0,0,0,0,45,1,1,0,0,0,0,9,27449,0,200,0,0,0,0, 'Neltharions Flame Control Bunny - Linked with Previous Event - Set Data 1 1 on Neltharions Flame Fire Bunny'), +(27450,0,3,4,61,0,100,0,0,0,0,0,45,1,1,0,0,0,0,9,27355,0,200,0,0,0,0, 'Neltharions Flame Control Bunny - Linked with Previous Event - Set Data 1 1 on Rothin the Decaying'), +(27450,0,4,0,61,0,100,0,0,0,0,0,100,1,0,0,0,0,0,9,27355,0,200,0,0,0,0, 'Neltharions Flame Control Bunny - Linked with Previous Event - Send Targetlist to Rothin the Decaying'), +(27355,0,0,0,25,0,100,0,0,0,0,0,22,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - On Reset - Set Phase 0'), +(27355,0,1,2,4,0,100,0,0,0,0,0,11,9613,0,0,0,0,0,7,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - On Agro - Cast Shadowbolt'), +(27355,0,2,0,61,0,100,0,0,0,0,0,22,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - Linked with Previous Event - Set Phase 1'), +(27355,0,3,0,9,1,100,0,0,40,3400,4800,11,9613,64,0,0,0,0,7,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - On Range (Phase 1) - Cast Shadow Bolt'), +(27355,0,4,0,0,0,100,0,12000,17000,15000,20000,11,51337,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - IC - On Range (Phase 1) - Cast Shadow Flame'), +(27355,0,5,0,2,0,100,1,0,30,9500,11000,11,51512,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - On Less than 30% HP - Cast Aegis of Neltharion'), +(27355,0,6,0,6,0,100,0,0,0,0,0,1,2,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - On Death - Say'), +(27355,0,7,0,1,0,100,0,10000,10000,10000,10000,11,48685,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying - OOC - Cast Imbue Power'), +(27355,0,8,0,25,0,100,0,0,0,0,0,8,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying - On Reset - Set Passive'), +(27355,0,9,0,38,0,100,0,1,1,30000,30000,80,2735500,2,0,0,0,0,1,0,0,0,0,0,0,0, 'Rothin the Decaying - On Data Set 1 1 - Run Script'), +(2735500,9,0,0,0,0,100,0,0,0,0,0,66,0,0,0,0,0,0,12,1,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - Script - Face Target'), +(2735500,9,1,0,0,0,100,0,0,0,0,0,28,48685,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - Script - Remove Aura Imbue Power'), +(2735500,9,2,0,0,0,100,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - Script - Say'), +(2735500,9,3,0,0,0,100,0,7000,7000,0,0,28,48695,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying - Script - Remove Aura Imbue Power Shield State'), +(2735500,9,4,0,0,0,100,0,0,0,0,0,8,2,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying - Script - Set Aggresive'), +(2735500,9,5,0,0,0,100,0,0,0,0,0,1,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Rothin the Decaying <Cult of the Damned> - script - Say'), +(2735500,9,6,0,0,0,100,0,0,0,0,0,49,0,0,0,0,0,0,12,1,0,0,0,0,0,0,'Rothin the Decaying - Script - Attack Target'); + +DELETE FROM `creature_template_addon` WHERE `entry`=27355; +INSERT INTO `creature_template_addon` (`entry`, `path_id`, `mount`, `bytes1`, `bytes2`, `emote`, `auras`) VALUES +(27355, 0, 0, 0x0, 0x1, 0, '48695'); -- -- 27355 - 48695 - 48695 + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry`=48685; +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=22 AND `SourceEntry`=27355; + +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(13, 1, 48685, 0, 0, 31, 0, 3, 27418, 0, 0, 0, 0, '', 'Imbue Power targets Rothins Spell Bunny'), +(13, 1, 48685, 0, 1, 31, 0, 3, 26475, 0, 0, 0, 0, '', 'Imbue Power targets Magmawyrm'), +(22, 10, 27355, 0, 0, 36, 1, 0, 0, 0, 0, 0, 0, '', 'Only execute SAI if Rothin the Decaying alive'), +(22, 2, 27355, 0, 0, 1, 1, 48695, 0, 0, 1, 0, 0, '', 'Only execute SAI if Rothin the Decaying does not have aura Imbue Power Shield State'); diff --git a/sql/updates/world/2016_01_18_03_world.sql b/sql/updates/world/2016_01_18_03_world.sql new file mode 100644 index 00000000000..4b8eb4ae0c9 --- /dev/null +++ b/sql/updates/world/2016_01_18_03_world.sql @@ -0,0 +1,6 @@ +-- +DELETE FROM `creature_text` WHERE `entry` = 11856; +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`BroadcastTextId`,`TextRange`,`comment`) VALUES +(11856, 0, 0, "Let's go before they find out I'm free!", 12, 0, 100, 1, 0, 0, 8327, 0, 'Kaya SAY_START'), +(11856, 1, 0, "Look out! We're under attack!", 12, 0, 100, 5, 0, 0, 8328, 0, 'Kaya SAY_AMBUSH'), +(11856, 2, 0, "Thank you for helping me. I know my way back from here.", 12, 0, 100, 3, 0, 0, 8329, 0, 'Kaya SAY_END'); diff --git a/sql/updates/world/2016_01_18_04_world.sql b/sql/updates/world/2016_01_18_04_world.sql new file mode 100644 index 00000000000..28ab2d96731 --- /dev/null +++ b/sql/updates/world/2016_01_18_04_world.sql @@ -0,0 +1,5 @@ +-- +DELETE FROM `creature` WHERE id=27535; +DELETE FROM `vehicle_template_accessory` WHERE `entry` IN (27761); +INSERT INTO `vehicle_template_accessory` (`entry`, `accessory_entry`, `minion`, `description`, `summontype`) VALUES (27761, 27535,1, "Fordragon Battle Steed", 7); +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=27761; diff --git a/sql/updates/world/2016_01_18_05_world.sql b/sql/updates/world/2016_01_18_05_world.sql new file mode 100644 index 00000000000..0d28cd17642 --- /dev/null +++ b/sql/updates/world/2016_01_18_05_world.sql @@ -0,0 +1,3 @@ +-- +UPDATE `creature` SET `MovementType`= 1 WHERE `guid`= 134869 AND `id`= 27401; +DELETE FROM `creature_addon` WHERE `guid` IN (97255,97256,97257,97258,97259,97261,131106); diff --git a/sql/updates/world/2016_01_18_06_world.sql b/sql/updates/world/2016_01_18_06_world.sql new file mode 100644 index 00000000000..f8b90c15f54 --- /dev/null +++ b/sql/updates/world/2016_01_18_06_world.sql @@ -0,0 +1,3 @@ +-- +UPDATE `disenchant_loot_template` SET `MinCount`=2,`MaxCount`=3 WHERE `Entry` IN (15,34) AND `Item`=34054; +UPDATE `disenchant_loot_template` SET `MinCount`=4,`MaxCount`=7 WHERE `Entry` IN (16,35) AND `Item`=34054; diff --git a/sql/updates/world/2016_01_19_00_world.sql b/sql/updates/world/2016_01_19_00_world.sql new file mode 100644 index 00000000000..f210b95c13a --- /dev/null +++ b/sql/updates/world/2016_01_19_00_world.sql @@ -0,0 +1,5 @@ +-- +DELETE FROM `achievement_criteria_data` WHERE `criteria_id`=11142; +INSERT INTO `achievement_criteria_data` (`criteria_id`, `type`, `value1`, `value2`) VALUES +(11142, 5, 66303, 0), +(11142, 16, 404, 0); diff --git a/sql/updates/world/2016_01_19_01_world.sql b/sql/updates/world/2016_01_19_01_world.sql new file mode 100644 index 00000000000..a10bc7e278f --- /dev/null +++ b/sql/updates/world/2016_01_19_01_world.sql @@ -0,0 +1,28 @@ +-- +DELETE FROM `gossip_menu` WHERE `entry` IN (7482, 7483); +INSERT INTO `gossip_menu` (`entry`, `text_id`) VALUES +(7482, 9067), +(7483, 9068); + +DELETE FROM `npc_text` WHERE `ID` IN (9068); +INSERT INTO `npc_text` (`ID`, `text0_0`, `text0_1`, `lang0`, `Probability0`, `em0_0`, `BroadcastTextID0`) VALUES +(9068, 'How did you learn about the ore? Not even the Baron knew...$B$BTake the cursed things. They''ve brought me nothing but misfortune anyway. I hid them IN the stables just off the courtyard.$B$B<A low growl begins TO emanate FROM the back of Landen''s throat.>', '', 0, 1, 20, 14393); + +DELETE FROM `gossip_menu_option` WHERE (`menu_id`=7482); +INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`,`BoxBroadcastTextID`) VALUES +(7482,0,0,'Listen to me, human. I care nothing for your plight, but you have something I require. Tell me where to find the bloodforged ingots.',14392,1,1,7483,0,0,0,'',0); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=7482; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(15,7482,0,0,9,9692,0,0,0,'', 'gossip option on Landen Stilwell requires The Path of the Adept taken'); + +UPDATE `creature_template` SET `npcflag`=1,`gossip_menu_id` =7482, `AIName`='SmartAI', `flags_extra`=0 WHERE `entry` =17822; + +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=17822; +DELETE FROM `smart_scripts` WHERE `source_type`=9 AND `entryorguid`=1782200; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(17822,0,0,0,64,0,100,1,0,0,0,0,80,1782200,2,0,0,0,0,1,0,0,0,0,0,0,0,'Landen Stilwell - on gossip hello - Actionlist'), +(1782200,9,0,0,0,0,100,0,20000,20000,0,0,11,31310,0,0,0,0,0,1,0,0,0,0,0,0,0,'Landen Stilwell - Action list - cast Landen Stilwell Transform'), +(1782200,9,1,0,0,0,100,0,0,0,0,0,2,14,0,0,0,0,0,1,0,0,0,0,0,0,0,'Landen Stilwell - Action list - set faction'), +(1782200,9,2,0,0,0,100,0,0,0,0,0,49,0,0,0,0,0,0,21,50,0,0,0,0,0,0,'Landen Stilwell - Action list - start attack'), +(17822,0,1,0,0,0,100,1,0,0,0,0,11,31310,0,0,0,0,0,1,0,0,0,0,0,0,0,'Landen Stilwell - IC - cast Landen Stilwell Transform'); diff --git a/sql/updates/world/2016_01_19_02_world.sql b/sql/updates/world/2016_01_19_02_world.sql new file mode 100644 index 00000000000..7c71156b248 --- /dev/null +++ b/sql/updates/world/2016_01_19_02_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `BaseAttackTime` = 1200 WHERE `entry` = 15516; diff --git a/sql/updates/world/2016_01_19_03_world.sql b/sql/updates/world/2016_01_19_03_world.sql new file mode 100644 index 00000000000..0d559ace044 --- /dev/null +++ b/sql/updates/world/2016_01_19_03_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `InhabitType` = 5 WHERE `entry` = 14517; diff --git a/sql/updates/world/2016_01_19_04_world.sql b/sql/updates/world/2016_01_19_04_world.sql new file mode 100644 index 00000000000..f4fe95f5539 --- /dev/null +++ b/sql/updates/world/2016_01_19_04_world.sql @@ -0,0 +1,6 @@ +-- +DELETE FROM `gameobject` WHERE `guid`=7230 AND `id`=175946; +DELETE FROM `gameobject` WHERE `guid`=250 AND `id`=175946; +UPDATE `gameobject` SET `orientation`=5.323256 WHERE `guid`=67867; +UPDATE `gameobject_template` SET `faction`=114, `flags`=32 WHERE `entry`=176965; +UPDATE `gameobject_template` SET `faction`=14 WHERE `entry`=177807; diff --git a/sql/updates/world/2016_01_19_05_world.sql b/sql/updates/world/2016_01_19_05_world.sql new file mode 100644 index 00000000000..5afd9e2b8a5 --- /dev/null +++ b/sql/updates/world/2016_01_19_05_world.sql @@ -0,0 +1 @@ +DELETE FROM `creature_text` WHERE `entry` IN (17900,17901) AND `BroadcastTextId`=8329; diff --git a/sql/updates/world/2016_01_19_06_world.sql b/sql/updates/world/2016_01_19_06_world.sql new file mode 100644 index 00000000000..cece0c623bf --- /dev/null +++ b/sql/updates/world/2016_01_19_06_world.sql @@ -0,0 +1,97 @@ +-- gothik the harvester rework +-- creature (13 entries) +SET @CGUID = 127618; -- PR NOTE: This needs to match the value set in boss_gothik.cpp for the CGUID_TRIGGER const + +-- boss messages +DELETE FROM `creature_text` WHERE `entry`=16060; +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`probability`,`sound`,`BroadcastTextId`,`TextRange`,`comment`) VALUES +(16060,0,0,"Foolishly you have sought your own demise.",14,100,8807,13030,3,"Gothik SAY_INTRO_1"), +(16060,1,0,"Brazenly you have disregarded powers beyond your understanding.",14,100,0,13031,3,"Gothik SAY_INTRO_2"), +(16060,2,0,"You have fought hard to invade the realm of the harvester.",14,100,0,13032,3,"Gothik SAY_INTRO_3"), +(16060,3,0,"Now there is only one way out- to walk the lonely path of the damned.",14,100,0,13033,3,"Gothik SAY_INTRO_4"), +(16060,4,0,"I have waited long enough. Now you face the harvester of souls.",14,100,8808,13028,3,"Gothik SAY_PHASE_TWO"), +(16060,5,0,"I... am... undone.",14,100,8805,13026,3,"Gothik SAY_DEATH"), +(16060,6,0,"Death is the only escape!",14,20,8806,13027,3,"Gothik SAY_KILL"), +(16060,7,0,"%s teleports into the fray!",41,100,0,32306,3,"Gothik EMOTE_PHASE_TWO"), +(16060,8,0,"The central gate opens!",41,100,0,32307,3,"Gothik EMOTE_GATE_OPENED"); + +-- minion AI +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_livingtrainee" WHERE `entry`=16124; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_livingknight" WHERE `entry`=16125; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_livingrider" WHERE `entry`=16126; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_spectraltrainee" WHERE `entry`=16127; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_spectralknight" WHERE `entry`=16148; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_spectralrider" WHERE `entry`=16150; +UPDATE `creature_template` SET `ScriptName`="npc_gothik_minion_spectralhorse" WHERE `entry`=16149; + +-- minion difficulty spell entries +DELETE FROM `spelldifficulty_dbc` WHERE `id` IN (55604,27825,27831,27989,56408,27993,55606,27994,55648); +INSERT INTO `spelldifficulty_dbc` (`id`,`spellid0`,`spellid1`) VALUES +(55604,55604,55645), -- death plague +(27831,27831,55638), -- shadow bolt volley +(27989,27989,56407), -- arcane explosion +(55606,55606,55608), -- unholy aura +(27994,27994,55646), -- drain life +(55648,55648,27995); -- unholy frenzy + +-- rider damage aura + visual aura +DELETE FROM `creature_template_addon` WHERE `entry` IN (16126,29986,16148,29990,16150,29988); +INSERT INTO `creature_template_addon` (`entry`,`mount`,`auras`) VALUES +(16126,25278,"55606"), +(29986,25278,"55608"), +(16148, 0,"10848"), +(29990, 0,"10848"), +(16150, 0,"55606 10848"), +(29988, 0,"55608 10848"); + +-- trigger AI +UPDATE `creature_template` SET `ScriptName`="npc_gothik_trigger",`InhabitType`=7 WHERE `entry`=16137; +-- re-do spawn locations for triggers +DELETE FROM `creature` WHERE `id`=16137; +INSERT INTO `creature` (`guid`,`id`,`map`,`spawnMask`,`phaseMask`,`position_x`,`position_y`,`position_z`,`orientation`,`spawntimesecs`,`spawndist`,`movementtype`) VALUES +(@CGUID+00,16137,533,3,1,2643.731,-3399.681,284.1829,0,0,0,0), -- living side soul trigger (south) +(@CGUID+01,16137,533,3,1,2739.995,-3399.779,284.2946,0,0,0,0), -- living side soul trigger (north) +(@CGUID+02,16137,533,3,1,2643.731,-3321.727,284.2327,0,0,0,0), -- spectral side soul trigger (south) +(@CGUID+03,16137,533,3,1,2739.995,-3321.727,284.2316,0,0,0,0), -- spectral side soul trigger (north) +(@CGUID+04,16137,533,3,1,2692.161,-3430.746,268.6462,0,0,0,0), -- living side spawn trigger (center back) +(@CGUID+05,16137,533,3,1,2714.562,-3430.61 ,268.6462,0,0,0,0), -- living side spawn trigger (north) +(@CGUID+06,16137,533,3,1,2692.213,-3428.783,268.6462,0,0,0,0), -- living side spawn trigger (center front) +(@CGUID+07,16137,533,3,1,2669.581,-3428.859,268.6462,0,0,0,0), -- living side spawn trigger (south) +(@CGUID+08,16137,533,3,1,2733.457,-3349.388,267.7677,0,0,0,0), -- spectral side spawn trigger (northeast) +(@CGUID+09,16137,533,3,1,2725.818,-3309.567,267.7686,0,0,0,0), -- spectral side spawn trigger (northwest) +(@CGUID+10,16137,533,3,1,2700.269,-3322.354,267.7678,0,0,0,0), -- spectral side spawn trigger (center) +(@CGUID+11,16137,533,3,1,2664.872,-3340.749,267.7674,0,0,0,0), -- spectral side spawn trigger (southeast) +(@CGUID+12,16137,533,3,1,2683.886,-3304.213,267.768 ,0,0,0,0); -- spectral side spawn trigger (southwest) + +-- make visuals target proper triggers +-- to anchor 1: 27892 (Trainee), 27928 (DK), 27935 (Rider) +-- to anchor 2: 27893 (Trainee), 27929 (DK), 27936 (Rider) +-- anchor -> skull: 27915 (Trainee), 27931 (DK), 27937 (Rider) +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry` IN (27892,27928,27935,27893,27929,27936,27915,27931,27937); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`ConditionTypeOrReference`,`ConditionTarget`,`ElseGroup`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`Comment`) VALUES +(13,1,27892,31,0,0,3,16137,@CGUID+0,"To Anchor 1 - Target Anchor Living South"), +(13,1,27892,31,0,1,3,16137,@CGUID+1,"To Anchor 1 - Target Anchor Living North"), +(13,1,27928,31,0,0,3,16137,@CGUID+0,"To Anchor 1 - Target Anchor Living South"), +(13,1,27928,31,0,1,3,16137,@CGUID+1,"To Anchor 1 - Target Anchor Living North"), +(13,1,27935,31,0,0,3,16137,@CGUID+0,"To Anchor 1 - Target Anchor Living South"), +(13,1,27935,31,0,1,3,16137,@CGUID+1,"To Anchor 1 - Target Anchor Living North"), + +(13,1,27893,31,0,0,3,16137,@CGUID+2,"To Anchor 2 - Target Anchor Spectral South"), +(13,1,27893,31,0,1,3,16137,@CGUID+3,"To Anchor 2 - Target Anchor Spectral North"), +(13,1,27929,31,0,0,3,16137,@CGUID+2,"To Anchor 2 - Target Anchor Spectral South"), +(13,1,27929,31,0,1,3,16137,@CGUID+3,"To Anchor 2 - Target Anchor Spectral North"), +(13,1,27936,31,0,0,3,16137,@CGUID+2,"To Anchor 2 - Target Anchor Spectral South"), +(13,1,27936,31,0,1,3,16137,@CGUID+3,"To Anchor 2 - Target Anchor Spectral North"); + +-- disable LoS check for visuals to ensure they always work +DELETE FROM `disables` WHERE `sourceType`=0 AND `entry` IN (27892,27928,27935,27893,27929,27936,27915,27931,27937); +INSERT INTO `disables` (`sourceType`,`entry`,`flags`,`comment`) VALUES +(0,27892,64,"Gothik - To Anchor 1 - Ignore LoS"), +(0,27928,64,"Gothik - To Anchor 1 - Ignore LoS"), +(0,27935,64,"Gothik - To Anchor 1 - Ignore LoS"), +(0,27893,64,"Gothik - To Anchor 2 - Ignore LoS"), +(0,27929,64,"Gothik - To Anchor 2 - Ignore LoS"), +(0,27936,64,"Gothik - To Anchor 2 - Ignore LoS"), +(0,27915,64,"Gothik - Anchor To Skulls - Ignore LoS"), +(0,27931,64,"Gothik - Anchor To Skulls - Ignore LoS"), +(0,27937,64,"Gothik - Anchor To Skulls - Ignore LoS"); diff --git a/sql/updates/world/2016_01_19_07_world.sql b/sql/updates/world/2016_01_19_07_world.sql new file mode 100644 index 00000000000..e1a72398a5f --- /dev/null +++ b/sql/updates/world/2016_01_19_07_world.sql @@ -0,0 +1,23 @@ +-- four horsemen rewrite +UPDATE `creature_template` SET `ScriptName`='boss_four_horsemen_baron' WHERE `entry`=30549; +UPDATE `creature_template` SET `ScriptName`='boss_four_horsemen_thane' WHERE `entry`=16064; +UPDATE `creature_template` SET `ScriptName`='boss_four_horsemen_lady' WHERE `entry`=16065; +UPDATE `creature_template` SET `ScriptName`='boss_four_horsemen_sir' WHERE `entry`=16063; + +-- add ragecast texts +DELETE FROM `creature_text` WHERE `entry` IN (16064,16065,16063,30549) AND `groupid`=7; +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`probability`,`BroadcastTextId`,`TextRange`,`comment`) VALUES +(16063,7,0,"%s casts Condemnation on everyone!",41,100,33088,3,"zeliek EMOTE_RAGECAST"), +(16065,7,0,"%s casts Unyielding Pain on everyone!",41,100,33087,3,"blaumeux EMOTE_RAGECAST"); +-- slay text probability to DB +UPDATE `creature_text` SET `probability`=30 WHERE `entry` IN (16064,16065,16063,30549) AND `groupid`=3; + +-- difficulty based spell ids +DELETE FROM `spelldifficulty_dbc` WHERE `id` IN (28882,28884,57374,28863,57376,28883); +INSERT INTO `spelldifficulty_dbc` (`id`,`spellid0`,`spellid1`) VALUES +(28882,28882,57369), -- Rivendare: Unholy Shadow +(28884,28884,57467), -- Korth'azz: Meteor +(57374,57374,57464), -- Blaumeux: Shadow Bolt +(28863,28863,57463), -- Blaumeux: Void Zone +(57376,57376,57465), -- Zeliek: Holy Bolt +(28883,28883,57466); -- Zeliek: Holy Wrath diff --git a/sql/updates/world/2016_01_19_08_world.sql b/sql/updates/world/2016_01_19_08_world.sql new file mode 100644 index 00000000000..d078c059201 --- /dev/null +++ b/sql/updates/world/2016_01_19_08_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `npcflag`=3, `gossip_menu_id`=140 WHERE `entry`=1139; diff --git a/sql/updates/world/2016_01_20_00_world.sql b/sql/updates/world/2016_01_20_00_world.sql new file mode 100644 index 00000000000..26ce069edd8 --- /dev/null +++ b/sql/updates/world/2016_01_20_00_world.sql @@ -0,0 +1,70 @@ +DELETE FROM gossip_menu_option WHERE `menu_id` IN (11013, 11014, 11015, 11016, 11017, 11018); +INSERT INTO gossip_menu_option (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(11013, 1, 0, 'Teleport to the Oratory of the Damned.', 37722, 1, 1, 0, 0, 0, 0, '', 0), -- Light's Hammer +(11013, 3, 0, 'Teleport to the Rampart of Skulls.', 37723, 1, 1, 0, 0, 0, 0, '', 0), -- Light's Hammer +(11013, 4, 0, 'Teleport to the Deathbringer''s Rise.', 37724, 1, 1, 0, 0, 0, 0, '', 0), -- Light's Hammer +(11013, 5, 0, 'Teleport to the Upper Spire.', 37725, 1, 1, 0, 0, 0, 0, '', 0), -- Light's Hammer +(11013, 6, 0, 'Teleport to Sindragosa''s Lair.', 37728, 1, 1, 0, 0, 0, 0, '', 0), -- Light's Hammer + +(11014, 0, 0, 'Teleport to Light''s Hammer.', 37671, 1, 1, 0, 0, 0, 0, '', 0), -- Oratory of the Damned +(11014, 3, 0, 'Teleport to the Rampart of Skulls.', 37723, 1, 1, 0, 0, 0, 0, '', 0), -- Oratory of the Damned +(11014, 4, 0, 'Teleport to the Deathbringer''s Rise.', 37724, 1, 1, 0, 0, 0, 0, '', 0), -- Oratory of the Damned +(11014, 5, 0, 'Teleport to the Upper Spire.', 37725, 1, 1, 0, 0, 0, 0, '', 0), -- Oratory of the Damned +(11014, 6, 0, 'Teleport to Sindragosa''s Lair.', 37728, 1, 1, 0, 0, 0, 0, '', 0), -- Oratory of the Damned + +(11015, 0, 0, 'Teleport to Light''s Hammer.', 37671, 1, 1, 0, 0, 0, 0, '', 0), -- Rampart of Skulls +(11015, 1, 0, 'Teleport to the Oratory of the Damned.', 37722, 1, 1, 0, 0, 0, 0, '', 0), -- Rampart of Skulls +(11015, 4, 0, 'Teleport to the Deathbringer''s Rise.', 37724, 1, 1, 0, 0, 0, 0, '', 0), -- Rampart of Skulls +(11015, 5, 0, 'Teleport to the Upper Spire.', 37725, 1, 1, 0, 0, 0, 0, '', 0), -- Rampart of Skulls +(11015, 6, 0, 'Teleport to Sindragosa''s Lair.', 37728, 1, 1, 0, 0, 0, 0, '', 0), -- Rampart of Skulls + +(11016, 0, 0, 'Teleport to Light''s Hammer.', 37671, 1, 1, 0, 0, 0, 0, '', 0), -- Deathbringer's Rise +(11016, 1, 0, 'Teleport to the Oratory of the Damned.', 37722, 1, 1, 0, 0, 0, 0, '', 0), -- Deathbringer's Rise +(11016, 3, 0, 'Teleport to the Rampart of Skulls.', 37723, 1, 1, 0, 0, 0, 0, '', 0), -- Deathbringer's Rise +(11016, 5, 0, 'Teleport to the Upper Spire.', 37725, 1, 1, 0, 0, 0, 0, '', 0), -- Deathbringer's Rise +(11016, 6, 0, 'Teleport to Sindragosa''s Lair.', 37728, 1, 1, 0, 0, 0, 0, '', 0), -- Deathbringer's Rise + +(11017, 0, 0, 'Teleport to Light''s Hammer.', 37671, 1, 1, 0, 0, 0, 0, '', 0), -- Upper Spire +(11017, 1, 0, 'Teleport to the Oratory of the Damned.', 37722, 1, 1, 0, 0, 0, 0, '', 0), -- Upper Spire +(11017, 3, 0, 'Teleport to the Rampart of Skulls.', 37723, 1, 1, 0, 0, 0, 0, '', 0), -- Upper Spire +(11017, 4, 0, 'Teleport to the Deathbringer''s Rise.', 37724, 1, 1, 0, 0, 0, 0, '', 0), -- Upper Spire +(11017, 6, 0, 'Teleport to Sindragosa''s Lair.', 37728, 1, 1, 0, 0, 0, 0, '', 0), -- Upper Spire + +(11018, 0, 0, 'Teleport to Light''s Hammer.', 37671, 1, 1, 0, 0, 0, 0, '', 0), -- Sindragosa's Lair +(11018, 1, 0, 'Teleport to the Oratory of the Damned.', 37722, 1, 1, 0, 0, 0, 0, '', 0), -- Sindragosa's Lair +(11018, 3, 0, 'Teleport to the Rampart of Skulls.', 37723, 1, 1, 0, 0, 0, 0, '', 0), -- Sindragosa's Lair +(11018, 4, 0, 'Teleport to the Deathbringer''s Rise.', 37724, 1, 1, 0, 0, 0, 0, '', 0), -- Sindragosa's Lair +(11018, 5, 0, 'Teleport to the Upper Spire.', 37725, 1, 1, 0, 0, 0, 0, '', 0); -- Sindragosa's Lair + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup` IN (11013, 11014, 11015, 11016, 11017, 11018); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorType`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(15,11013,1,0,0,13,0,0,3,2,0,0,0,'','Show option ''Teleport to the Oratory of the Damned.'' only if BossState DATA_LORD_MARROWGAR is DONE'), +(15,11013,3,0,0,13,0,1,3,2,0,0,0,'','Show option ''Teleport to the Rampart of Skulls.'' only if BossState DATA_LADY_DEATHWHISPER is DONE'), +(15,11013,4,0,0,13,0,2,3,2,0,0,0,'','Show option ''Teleport to the Deathbringer''s Rise.'' only if BossState DATA_ICECROWN_GUNSHIP_BATTLE is DONE'), +(15,11013,5,0,0,13,0,41,3,0,0,0,0,'','Show option ''Teleport to the Upper Spire.'' only if DATA_UPPERSPIRE_TELE_ACT is DONE'), +(15,11013,6,0,0,13,0,10,3,2,0,0,0,'','Show option ''Teleport to Sindragosa''s Lair.'' only if BossState DATA_VALITHRIA_DREAMWALKER is DONE'), + +(15,11014,3,0,0,13,0,1,3,2,0,0,0,'','Show option ''Teleport to the Rampart of Skulls.'' only if BossState DATA_LADY_DEATHWHISPER is DONE'), +(15,11014,4,0,0,13,0,2,3,2,0,0,0,'','Show option ''Teleport to the Deathbringer''s Rise.'' only if BossState DATA_ICECROWN_GUNSHIP_BATTLE is DONE'), +(15,11014,5,0,0,13,0,41,3,0,0,0,0,'','Show option ''Teleport to the Upper Spire.'' only if DATA_UPPERSPIRE_TELE_ACT is DONE'), +(15,11014,6,0,0,13,0,10,3,2,0,0,0,'','Show option ''Teleport to Sindragosa''s Lair.'' only if BossState DATA_VALITHRIA_DREAMWALKER is DONE'), + +(15,11015,1,0,0,13,0,0,3,2,0,0,0,'','Show option ''Teleport to the Oratory of the Damned.'' only if BossState DATA_LORD_MARROWGAR is DONE'), +(15,11015,4,0,0,13,0,2,3,2,0,0,0,'','Show option ''Teleport to the Deathbringer''s Rise.'' only if BossState DATA_ICECROWN_GUNSHIP_BATTLE is DONE'), +(15,11015,5,0,0,13,0,41,3,0,0,0,0,'','Show option ''Teleport to the Upper Spire.'' only if DATA_UPPERSPIRE_TELE_ACT is DONE'), +(15,11015,6,0,0,13,0,10,3,2,0,0,0,'','Show option ''Teleport to Sindragosa''s Lair.'' only if BossState DATA_VALITHRIA_DREAMWALKER is DONE'), + +(15,11016,1,0,0,13,0,0,3,2,0,0,0,'','Show option ''Teleport to the Oratory of the Damned.'' only if BossState DATA_LORD_MARROWGAR is DONE'), +(15,11016,3,0,0,13,0,1,3,2,0,0,0,'','Show option ''Teleport to the Rampart of Skulls.'' only if BossState DATA_LADY_DEATHWHISPER is DONE'), +(15,11016,5,0,0,13,0,41,3,0,0,0,0,'','Show option ''Teleport to the Upper Spire.'' only if DATA_UPPERSPIRE_TELE_ACT is DONE'), +(15,11016,6,0,0,13,0,10,3,2,0,0,0,'','Show option ''Teleport to Sindragosa''s Lair.'' only if BossState DATA_VALITHRIA_DREAMWALKER is DONE'), + +(15,11017,1,0,0,13,0,0,3,2,0,0,0,'','Show option ''Teleport to the Oratory of the Damned.'' only if BossState DATA_LORD_MARROWGAR is DONE'), +(15,11017,3,0,0,13,0,1,3,2,0,0,0,'','Show option ''Teleport to the Rampart of Skulls.'' only if BossState DATA_LADY_DEATHWHISPER is DONE'), +(15,11017,4,0,0,13,0,2,3,2,0,0,0,'','Show option ''Teleport to the Deathbringer''s Rise.'' only if BossState DATA_ICECROWN_GUNSHIP_BATTLE is DONE'), +(15,11017,6,0,0,13,0,10,3,2,0,0,0,'','Show option ''Teleport to Sindragosa''s Lair.'' only if BossState DATA_VALITHRIA_DREAMWALKER is DONE'), + +(15,11018,1,0,0,13,0,0,3,2,0,0,0,'','Show option ''Teleport to the Oratory of the Damned.'' only if BossState DATA_LORD_MARROWGAR is DONE'), +(15,11018,3,0,0,13,0,1,3,2,0,0,0,'','Show option ''Teleport to the Rampart of Skulls.'' only if BossState DATA_LADY_DEATHWHISPER is DONE'), +(15,11018,4,0,0,13,0,2,3,2,0,0,0,'','Show option ''Teleport to the Deathbringer''s Rise.'' only if BossState DATA_ICECROWN_GUNSHIP_BATTLE is DONE'), +(15,11018,5,0,0,13,0,41,3,0,0,0,0,'','Show option ''Teleport to the Upper Spire.'' only if DATA_UPPERSPIRE_TELE_ACT is DONE'); diff --git a/sql/updates/world/2016_01_20_01_world.sql b/sql/updates/world/2016_01_20_01_world.sql new file mode 100644 index 00000000000..b1c6e0de756 --- /dev/null +++ b/sql/updates/world/2016_01_20_01_world.sql @@ -0,0 +1,4 @@ +-- +DELETE FROM `gossip_menu` WHERE `entry` IN (9578) AND `text_id`=12927; +INSERT INTO `gossip_menu` (`entry`, `text_id`) VALUES +(9578, 12927); diff --git a/sql/updates/world/2016_01_20_02_world.sql b/sql/updates/world/2016_01_20_02_world.sql new file mode 100644 index 00000000000..d026c3cb478 --- /dev/null +++ b/sql/updates/world/2016_01_20_02_world.sql @@ -0,0 +1,475 @@ +DELETE FROM `creature_formations` WHERE `leaderGUID`=12869; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(12869, 12869, 0, 0, 2), +(12869, 12853, 10, 90, 2), +(12869, 12854, 10, 270, 2); + +DELETE FROM `creature_formations` WHERE `leaderGUID`=12866; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(12866, 12866, 0, 0, 2), +(12866, 12851, 10, 90, 2), +(12866, 12852, 10, 270, 2); + +DELETE FROM `creature_formations` WHERE `leaderGUID`=13415; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(13415, 13415, 0, 0, 2), +(13415, 13414, 3, 90, 2); + +-- Pathing for Aqueous Spawn Entry: 22883 'TDB FORMAT' +SET @NPC := 13415; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=467.9448,`position_y`=847.3433,`position_z`=15.00103 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,467.9448,847.3433,15.00103,0,0,1,0,100,0), -- 20:18:04 +(@PATH,2,469.2407,849.0333,14.97786,0,0,1,0,100,0), -- 20:18:07 +(@PATH,3,473.5281,853.7736,15.31754,0,0,1,0,100,0), -- 20:18:07 +(@PATH,4,474.0281,857.5236,15.31754,0,0,1,0,100,0), -- 20:18:07 +(@PATH,5,473.7495,860.6138,15.416,0,0,1,0,100,0), -- 20:18:10 +(@PATH,6,472.7495,861.8638,15.416,0,0,1,0,100,0), -- 20:18:10 +(@PATH,7,471.7495,864.1138,15.166,0,0,1,0,100,0), -- 20:18:10 +(@PATH,8,467.3445,873.2086,15.48424,0,0,1,0,100,0), -- 20:18:12 +(@PATH,9,466.7931,879.0881,15.64043,0,0,1,0,100,0), -- 20:18:15 +(@PATH,10,465.5614,888.2678,15.55727,0,0,1,0,100,0), -- 20:18:17 +(@PATH,11,465.6077,896.3718,15.43029,0,0,1,0,100,0), -- 20:18:20 +(@PATH,12,467.8163,900.2317,15.73285,0,0,1,0,100,0), -- 20:18:21 +(@PATH,13,468.6377,905.9084,15.83779,0,0,1,0,100,0), -- 20:18:22 +(@PATH,14,466.0126,916.0297,15.82569,0,0,1,0,100,0), -- 20:18:24 +(@PATH,15,470.3526,931.8629,14.75142,0,0,1,0,100,0), -- 20:18:27 +(@PATH,16,469.243,921.0674,15.69238,0,0,1,0,100,0), -- 20:18:33 +(@PATH,17,466.0515,931.413,15.39575,0,0,1,0,100,0), -- 20:18:37 +(@PATH,18,466.0515,916.163,15.89575,0,0,1,0,100,0), -- 20:18:37 +(@PATH,19,466.9939,913.4012,15.84451,0,0,1,0,100,0), -- 20:18:44 +(@PATH,20,468.8083,905.5721,15.84772,0,0,1,0,100,0), -- 20:18:46 +(@PATH,21,465.8907,896.822,15.64862,0,0,1,0,100,0), -- 20:18:48 +(@PATH,22,465.9131,888.7125,15.57837,0,0,1,0,100,0), -- 20:18:50 +(@PATH,23,466.5535,879.3544,15.68201,0,0,1,0,100,0), -- 20:18:52 +(@PATH,24,468.5858,869.7411,15.54825,0,0,1,0,100,0), -- 20:18:55 +(@PATH,25,472.7863,862.353,15.26673,0,0,1,0,100,0), -- 20:18:57 +(@PATH,26,473.7863,860.603,15.51673,0,0,1,0,100,0), -- 20:18:57 +(@PATH,27,473.6846,860.4615,15.38147,0,0,1,0,100,0), -- 20:18:58 +(@PATH,28,474.4346,859.4615,15.38147,0,0,1,0,100,0), -- 20:18:58 +(@PATH,29,474.1846,858.2115,15.38147,0,0,1,0,100,0), -- 20:18:58 +(@PATH,30,473.6846,854.2115,15.13147,0,0,1,0,100,0), -- 20:18:58 +(@PATH,31,473.1513,852.6404,15.02536,0,0,1,0,100,0); -- 20:19:01 +-- 0x1C16F446801658C0006A5B000A1D4854 .go 467.9448 847.3433 15.00103 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=13418; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(13418, 13418, 0, 0, 2), +(13418, 13416, 3, 90, 2); + +-- Pathing for Aqueous Spawn Entry: 22883 'TDB FORMAT' +SET @NPC := 13418; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=277.868,`position_y`=842.4459,`position_z`=-23.75307 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,277.868,842.4459,-23.75307,0,0,1,0,100,0), -- 20:20:58 +(@PATH,2,277.4133,846.7463,-23.75651,0,0,1,0,100,0), -- 20:21:00 +(@PATH,3,278.9133,848.4963,-23.75651,0,0,1,0,100,0), -- 20:21:00 +(@PATH,4,280.4133,850.2463,-23.75651,0,0,1,0,100,0), -- 20:21:00 +(@PATH,5,282.6633,852.9963,-23.50651,0,0,1,0,100,0), -- 20:21:00 +(@PATH,6,283.827,860.8285,-23.04886,0,0,1,0,100,0), -- 20:21:01 +(@PATH,7,284.327,862.8285,-23.04886,0,0,1,0,100,0), -- 20:21:01 +(@PATH,8,282.827,867.8285,-23.79886,0,0,1,0,100,0), -- 20:21:01 +(@PATH,9,281.3427,869.1567,-23.76081,0,0,1,0,100,0), -- 20:21:02 +(@PATH,10,277.5927,871.6567,-23.76081,0,0,1,0,100,0), -- 20:21:02 +(@PATH,11,277.0927,875.9067,-23.76081,0,0,1,0,100,0), -- 20:21:02 +(@PATH,12,276.0927,884.1567,-23.76081,0,0,1,0,100,0), -- 20:21:02 +(@PATH,13,275.7303,886.521,-23.90997,0,0,1,0,100,0), -- 20:21:04 +(@PATH,14,277.0383,899.6908,-30.63255,0,0,1,0,100,0), -- 20:21:05 +(@PATH,15,280.329,915.5177,-38.46265,0,0,1,0,100,0), -- 20:21:06 +(@PATH,16,281.5613,931.75,-46.90573,0,0,1,0,100,0), -- 20:21:07 +(@PATH,17,277.2371,957.6002,-59.79856,0,0,1,0,100,0), -- 20:21:09 +(@PATH,18,276.8787,969.0604,-59.80925,0,0,1,0,100,0), -- 20:21:11 +(@PATH,19,280.0755,977.5538,-60.08774,0,0,1,0,100,0), -- 20:21:12 +(@PATH,20,283.3255,979.3038,-60.08774,0,0,1,0,100,0), -- 20:21:12 +(@PATH,21,284.8255,980.0538,-60.08774,0,0,1,0,100,0), -- 20:21:12 +(@PATH,22,289.5755,980.3038,-60.33774,0,0,1,0,100,0), -- 20:21:12 +(@PATH,23,292.3255,980.3038,-60.33774,0,0,1,0,100,0), -- 20:21:12 +(@PATH,24,295.7121,979.2697,-60.03576,0,0,1,0,100,0), -- 20:21:13 +(@PATH,25,299.2121,976.2697,-60.03576,0,0,1,0,100,0), -- 20:21:13 +(@PATH,26,295.9117,979.6497,-60.04585,0,0,1,0,100,0), -- 20:21:16 +(@PATH,27,292.6617,980.3997,-60.04585,0,0,1,0,100,0), -- 20:21:16 +(@PATH,28,289.9117,980.3997,-60.04585,0,0,1,0,100,0), -- 20:21:16 +(@PATH,29,285.0618,980.2185,-60.09282,0,0,1,0,100,0), -- 20:21:17 +(@PATH,30,283.3118,979.2185,-60.09282,0,0,1,0,100,0), -- 20:21:17 +(@PATH,31,280.0618,977.4685,-60.09282,0,0,1,0,100,0), -- 20:21:17 +(@PATH,32,278.8118,976.9685,-60.09282,0,0,1,0,100,0), -- 20:21:17 +(@PATH,33,276.8872,969.0083,-59.83573,0,0,1,0,100,0), -- 20:21:18 +(@PATH,34,277.1372,958.0083,-59.83573,0,0,1,0,100,0), -- 20:21:18 +(@PATH,35,281.6861,931.6771,-46.47077,0,0,1,0,100,0), -- 20:21:22 +(@PATH,36,280.2155,915.3389,-38.22446,0,0,1,0,100,0), -- 20:21:23 +(@PATH,37,276.9022,899.6358,-30.47937,0,0,1,0,100,0), -- 20:21:24 +(@PATH,38,275.9023,884.4814,-23.95735,0,0,1,0,100,0), -- 20:21:26 +(@PATH,39,276.1523,882.4814,-23.95735,0,0,1,0,100,0), -- 20:21:26 +(@PATH,40,276.9797,876.0508,-23.88462,0,0,1,0,100,0), -- 20:21:27 +(@PATH,41,277.4797,871.5508,-23.88462,0,0,1,0,100,0), -- 20:21:27 +(@PATH,42,281.2297,869.0508,-23.88462,0,0,1,0,100,0), -- 20:21:27 +(@PATH,43,282.8904,867.748,-23.63595,0,0,1,0,100,0), -- 20:21:28 +(@PATH,44,284.3904,863.248,-23.13595,0,0,1,0,100,0), -- 20:21:28 +(@PATH,45,283.8904,860.998,-23.13595,0,0,1,0,100,0), -- 20:21:28 +(@PATH,46,282.8904,853.748,-23.13595,0,0,1,0,100,0), -- 20:21:28 +(@PATH,47,280.6286,850.2665,-24.00388,0,0,1,0,100,0), -- 20:21:29 +(@PATH,48,278.8786,848.5165,-23.75388,0,0,1,0,100,0), -- 20:21:29 +(@PATH,49,277.3786,846.7665,-23.75388,0,0,1,0,100,0); -- 20:21:29 +-- 0x1C16F446801658C0006A5B000B1D4854 .go 277.868 842.4459 -23.75307 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=13774; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(13774, 13774, 0, 0, 2), +(13774, 13429, 3, 270, 2); + +-- Pathing for Aqueous Spawn Entry: 22883 'TDB FORMAT' +SET @NPC := 13774; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=226.3641,`position_y`=842.9598,`position_z`=-23.60787 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,226.3641,842.9598,-23.60787,0,0,1,0,100,0), -- 20:18:44 +(@PATH,2,224.6499,848.3411,-23.63753,0,0,1,0,100,0), -- 20:18:46 +(@PATH,3,222.3999,850.3411,-23.63753,0,0,1,0,100,0), -- 20:18:46 +(@PATH,4,219.3999,852.8411,-23.13753,0,0,1,0,100,0), -- 20:18:46 +(@PATH,5,220.1499,858.5911,-23.13753,0,0,1,0,100,0), -- 20:18:46 +(@PATH,6,220.6499,863.3411,-23.13753,0,0,1,0,100,0), -- 20:18:46 +(@PATH,7,220.7801,865.7321,-23.06377,0,0,1,0,100,0), -- 20:18:48 +(@PATH,8,223.5301,867.7321,-23.31377,0,0,1,0,100,0), -- 20:18:48 +(@PATH,9,226.2801,869.7321,-23.81377,0,0,1,0,100,0), -- 20:18:48 +(@PATH,10,229.0301,872.2321,-24.31377,0,0,1,0,100,0), -- 20:18:48 +(@PATH,11,230.5301,873.4821,-24.81377,0,0,1,0,100,0), -- 20:18:48 +(@PATH,12,231.5301,874.2321,-25.56377,0,0,1,0,100,0), -- 20:18:48 +(@PATH,13,234.6127,879.7501,-25.39395,0,0,1,0,100,0), -- 20:18:49 +(@PATH,14,235.3627,886.7501,-25.39395,0,0,1,0,100,0), -- 20:18:49 +(@PATH,15,235.054,896.0424,-30.38491,0,0,1,0,100,0), -- 20:18:50 +(@PATH,16,235.666,933.9497,-49.77283,0,0,1,0,100,0), -- 20:18:54 +(@PATH,17,235.166,951.4497,-58.52283,0,0,1,0,100,0), -- 20:18:54 +(@PATH,18,239.472,955.8605,-61.06985,0,0,1,0,100,0), -- 20:18:56 +(@PATH,19,241.722,957.8605,-62.31985,0,0,1,0,100,0), -- 20:18:56 +(@PATH,20,245.0305,960.8606,-62.1322,0,0,1,0,100,0), -- 20:18:57 +(@PATH,21,241.0371,985.8208,-62.71188,0,0,1,0,100,0), -- 20:18:58 +(@PATH,22,237.0147,1001.326,-62.45633,0,0,1,0,100,0), -- 20:19:00 +(@PATH,23,236.5147,1005.076,-62.45633,0,0,1,0,100,0), -- 20:19:00 +(@PATH,24,230.5381,1024.512,-61.63638,0,0,1,0,100,0), -- 20:19:02 +(@PATH,25,228.5381,1026.512,-60.88638,0,0,1,0,100,0), -- 20:19:02 +(@PATH,26,225.485,1029.62,-60.43474,0,0,1,0,100,0), -- 20:19:03 +(@PATH,27,223.485,1032.12,-60.43474,0,0,1,0,100,0), -- 20:19:03 +(@PATH,28,220.485,1035.37,-59.68474,0,0,1,0,100,0), -- 20:19:03 +(@PATH,29,220.5529,1045.221,-59.55603,0,0,1,0,100,0), -- 20:19:05 +(@PATH,30,224.0529,1048.471,-59.80603,0,0,1,0,100,0), -- 20:19:05 +(@PATH,31,225.0529,1049.221,-60.30603,0,0,1,0,100,0), -- 20:19:05 +(@PATH,32,226.3029,1050.721,-60.55603,0,0,1,0,100,0), -- 20:19:05 +(@PATH,33,228.6076,1053.052,-60.2848,0,0,1,0,100,0), -- 20:19:06 +(@PATH,34,229.8576,1054.552,-60.5348,0,0,1,0,100,0), -- 20:19:06 +(@PATH,35,230.8576,1055.552,-61.2848,0,0,1,0,100,0), -- 20:19:06 +(@PATH,36,233.3576,1058.052,-62.2848,0,0,1,0,100,0), -- 20:19:06 +(@PATH,37,230.8576,1061.052,-61.2848,0,0,1,0,100,0), -- 20:19:06 +(@PATH,38,229.8576,1062.302,-60.2848,0,0,1,0,100,0), -- 20:19:06 +(@PATH,39,227.7166,1065.36,-60.65356,0,0,1,0,100,0), -- 20:19:07 +(@PATH,40,227.7166,1066.86,-60.65356,0,0,1,0,100,0), -- 20:19:07 +(@PATH,41,229.6661,1062.701,-60.48591,0,0,1,0,100,0), -- 20:19:10 +(@PATH,42,230.9161,1061.201,-61.48591,0,0,1,0,100,0), -- 20:19:10 +(@PATH,43,233.2057,1058.173,-62.12091,0,0,1,0,100,0), -- 20:19:12 +(@PATH,44,230.7057,1055.173,-61.37091,0,0,1,0,100,0), -- 20:19:12 +(@PATH,45,229.9557,1054.423,-60.62091,0,0,1,0,100,0), -- 20:19:12 +(@PATH,46,228.7057,1052.923,-60.37091,0,0,1,0,100,0), -- 20:19:12 +(@PATH,47,226.2057,1050.923,-60.37091,0,0,1,0,100,0), -- 20:19:12 +(@PATH,48,224.9557,1049.423,-60.37091,0,0,1,0,100,0), -- 20:19:12 +(@PATH,49,224.1507,1048.499,-59.69673,0,0,1,0,100,0), -- 20:19:13 +(@PATH,50,220.6507,1045.249,-59.69673,0,0,1,0,100,0), -- 20:19:13 +(@PATH,51,220.4007,1035.749,-59.69673,0,0,1,0,100,0), -- 20:19:13 +(@PATH,52,223.1507,1032.499,-59.94673,0,0,1,0,100,0), -- 20:19:13 +(@PATH,53,225.6915,1029.523,-60.42624,0,0,1,0,100,0), -- 20:19:14 +(@PATH,54,228.1915,1026.773,-60.92624,0,0,1,0,100,0), -- 20:19:14 +(@PATH,55,230.4415,1024.773,-61.42624,0,0,1,0,100,0), -- 20:19:14 +(@PATH,56,231.6957,1023.582,-61.96358,0,0,1,0,100,0), -- 20:19:16 +(@PATH,57,236.1957,1005.332,-62.21358,0,0,1,0,100,0), -- 20:19:16 +(@PATH,58,236.6957,1001.582,-62.21358,0,0,1,0,100,0), -- 20:19:16 +(@PATH,59,239.3251,989.6144,-62.72815,0,0,1,0,100,0), -- 20:19:18 +(@PATH,60,239.3251,989.1144,-62.72815,0,0,1,0,100,0), -- 20:19:18 +(@PATH,61,241.0751,985.1144,-62.72815,0,0,1,0,100,0), -- 20:19:18 +(@PATH,62,244.6287,965.7533,-62.47226,0,0,1,0,100,0), -- 20:19:19 +(@PATH,63,242.1768,958.4319,-62.1866,0,0,1,0,100,0), -- 20:19:21 +(@PATH,64,239.1768,956.1819,-61.1866,0,0,1,0,100,0), -- 20:19:21 +(@PATH,65,235.3233,952.653,-59.28426,0,0,1,0,100,0), -- 20:19:22 +(@PATH,66,236.0733,933.903,-49.78426,0,0,1,0,100,0), -- 20:19:22 +(@PATH,67,235.6809,889.4034,-27.06503,0,0,1,0,100,0), -- 20:19:25 +(@PATH,68,235.3604,887.6078,-26.10506,0,0,1,0,100,0), -- 20:19:28 +(@PATH,69,234.6104,879.8578,-25.60506,0,0,1,0,100,0), -- 20:19:28 +(@PATH,70,231.5102,874.4667,-25.5617,0,0,1,0,100,0), -- 20:19:29 +(@PATH,71,229.0102,872.4667,-24.3117,0,0,1,0,100,0), -- 20:19:29 +(@PATH,72,226.2602,869.9667,-23.8117,0,0,1,0,100,0), -- 20:19:29 +(@PATH,73,223.6137,867.7607,-23.35828,0,0,1,0,100,0), -- 20:19:30 +(@PATH,74,220.8637,865.5107,-23.10828,0,0,1,0,100,0), -- 20:19:30 +(@PATH,75,220.6137,863.5107,-23.10828,0,0,1,0,100,0), -- 20:19:30 +(@PATH,76,219.2268,853.074,-23.14473,0,0,1,0,100,0), -- 20:19:31 +(@PATH,77,221.9768,850.824,-23.39473,0,0,1,0,100,0), -- 20:19:31 +(@PATH,78,224.7268,848.324,-23.64473,0,0,1,0,100,0), -- 20:19:31 +(@PATH,79,225.7792,847.1718,-23.69841,0,0,1,0,100,0); -- 20:19:33 +-- 0x1C16F446801658C0006A5B000D1D4854 .go 226.3641 842.9598 -23.60787 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=13411; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(13411, 13411, 0, 0, 2), +(13411, 13410, 3, 90, 2); + +-- Pathing for Aqueous Spawn Entry: 22883 'TDB FORMAT' +SET @NPC := 13411; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=341.5303,`position_y`=833.1406,`position_z`=3.273792 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,341.5303,833.1406,3.273792,0,0,1,0,100,0), -- 20:28:58 +(@PATH,2,348.7275,829.2892,1.651913,0,0,1,0,100,0), -- 20:29:00 +(@PATH,3,354.4775,827.0392,3.901913,0,0,1,0,100,0), -- 20:29:00 +(@PATH,4,359.5842,829.374,5.242831,0,0,1,0,100,0), -- 20:29:01 +(@PATH,5,361.0842,829.874,5.742831,0,0,1,0,100,0), -- 20:29:01 +(@PATH,6,364.5842,835.374,7.242831,0,0,1,0,100,0), -- 20:29:01 +(@PATH,7,367.8342,835.374,8.242831,0,0,1,0,100,0), -- 20:29:01 +(@PATH,8,373.5842,835.124,10.74283,0,0,1,0,100,0), -- 20:29:01 +(@PATH,9,379.5842,835.124,12.49283,0,0,1,0,100,0), -- 20:29:01 +(@PATH,10,385.9604,833.4543,14.87675,0,0,1,0,100,0), -- 20:29:04 +(@PATH,11,389.4604,828.2043,16.12675,0,0,1,0,100,0), -- 20:29:04 +(@PATH,12,385.9604,833.4543,14.87675,0,0,1,0,100,0), -- 20:29:04 +(@PATH,13,379.3574,835.0835,12.43179,0,0,1,0,100,0), -- 20:29:05 +(@PATH,14,373.6074,835.0835,10.93179,0,0,1,0,100,0), -- 20:29:05 +(@PATH,15,367.6338,835.3248,8.312333,0,0,1,0,100,0), -- 20:29:06 +(@PATH,16,364.6338,835.3248,7.062333,0,0,1,0,100,0), -- 20:29:06 +(@PATH,17,360.7854,829.9193,5.526537,0,0,1,0,100,0), -- 20:29:07 +(@PATH,18,359.5354,829.4193,5.276537,0,0,1,0,100,0), -- 20:29:07 +(@PATH,19,354.5487,827.0881,3.989071,0,0,1,0,100,0), -- 20:29:08 +(@PATH,20,348.5487,829.3381,1.739071,0,0,1,0,100,0); -- 20:29:08 +-- 0x1C16F446801658C0006A5B000E1D4854 .go 341.5303 833.1406 3.273792 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=13412; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(13412, 13412, 0, 0, 2), +(13412, 13413, 3, 270, 2); + +-- Pathing for Aqueous Spawn Entry: 22883 'TDB FORMAT' +SET @NPC := 13412; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=225.5994,`position_y`=787.1674,`position_z`=-24.18544 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,225.5994,787.1674,-24.18544,0,0,1,0,100,0), -- 20:21:40 +(@PATH,2,226.2546,784.0085,-23.94931,0,0,1,0,100,0), -- 20:21:42 +(@PATH,3,219.7546,774.2585,-23.44931,0,0,1,0,100,0), -- 20:21:42 +(@PATH,4,219.399,766.433,-23.47102,0,0,1,0,100,0), -- 20:21:44 +(@PATH,5,225.7847,743.8611,-23.80148,0,0,1,0,100,0), -- 20:21:45 +(@PATH,6,225.8589,730.2358,-15.95089,0,0,1,0,100,0), -- 20:21:46 +(@PATH,7,226.6089,726.4858,-13.95089,0,0,1,0,100,0), -- 20:21:46 +(@PATH,8,236.528,706.583,-4.811245,0,0,1,0,100,0), -- 20:21:50 +(@PATH,9,265.2675,707.3212,-4.301136,0,0,1,0,100,0), -- 20:21:51 +(@PATH,10,272.3554,719.12,-10.19584,0,0,1,0,100,0), -- 20:21:52 +(@PATH,11,275.1298,743.1734,-24.00938,0,0,1,0,100,0), -- 20:21:54 +(@PATH,12,279.3289,758.15,-23.90574,0,0,1,0,100,0), -- 20:21:56 +(@PATH,13,281.9902,760.6749,-23.69596,0,0,1,0,100,0), -- 20:21:57 +(@PATH,14,282.8818,767.9795,-23.45871,0,0,1,0,100,0), -- 20:21:58 +(@PATH,15,277.356,793.042,-24.15166,0,0,1,0,100,0), -- 20:22:00 +(@PATH,16,285.9649,799.7314,-23.8582,0,0,1,0,100,0), -- 20:22:01 +(@PATH,17,292.1205,799.7032,-22.67317,0,0,1,0,100,0), -- 20:22:02 +(@PATH,18,303.1205,795.2032,-17.17317,0,0,1,0,100,0), -- 20:22:02 +(@PATH,19,295.6266,798.3845,-20.68238,0,0,1,0,100,0), -- 20:22:04 +(@PATH,20,286.1266,799.6345,-23.93238,0,0,1,0,100,0), -- 20:22:04 +(@PATH,21,276.8643,782.9451,-23.92551,0,0,1,0,100,0), -- 20:22:07 +(@PATH,22,282.1143,770.6951,-23.42551,0,0,1,0,100,0), -- 20:22:07 +(@PATH,23,279.3628,758.2788,-24.0036,0,0,1,0,100,0), -- 20:22:09 +(@PATH,24,275.2263,743.7703,-24.04942,0,0,1,0,100,0), -- 20:22:10 +(@PATH,25,272.4308,719.3824,-10.38001,0,0,1,0,100,0), -- 20:22:12 +(@PATH,26,266.0668,708.079,-4.459149,0,0,1,0,100,0), -- 20:22:14 +(@PATH,27,258.0668,704.329,-4.959149,0,0,1,0,100,0), -- 20:22:14 +(@PATH,28,236.2906,706.6432,-3.633104,0,0,1,0,100,0), -- 20:22:16 +(@PATH,29,226.6268,726.214,-13.62222,0,0,1,0,100,0), -- 20:22:18 +(@PATH,30,225.8902,730.3877,-15.93307,0,0,1,0,100,0), -- 20:22:19 +(@PATH,31,226.0625,743.5709,-23.90323,0,0,1,0,100,0), -- 20:22:20 +(@PATH,32,220.6384,762.8275,-23.16604,0,0,1,0,100,0), -- 20:22:21 +(@PATH,33,218.6304,769.206,-23.46703,0,0,1,0,100,0), -- 20:22:23 +(@PATH,34,226.297,784.1191,-24.1624,0,0,1,0,100,0); -- 20:22:25 +-- 0x1C16F446801658C0006A5B000C1D4854 .go 225.5994 787.1674 -24.18544 + +-- Update spawn distance & movementype so they move around randomly +UPDATE `creature` SET `spawndist`=5, `MovementType`=1 WHERE `guid` IN (13393, 13395, 13399, 13396, 13236, 13268, 13398, 13255, 13316, 13397, 13408, 13401, 13407, 13403, 13402, 13409, 13406, 13404, 13405, 13400); + +-- Pathing for Bonechewer Taskmaster Entry: 23028 'TDB FORMAT' +SET @NPC := 53819; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=824.2386,`position_y`=922.0986,`position_z`=56.91497 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,824.2386,922.0986,56.91497,0,0,0,0,100,0), -- 20:24:16 +(@PATH,2,821.0174,923.827,56.86291,0,0,0,0,100,0), -- 20:24:21 +(@PATH,3,818.0731,927.4094,57.30012,0,0,0,0,100,0), -- 20:24:23 +(@PATH,4,814.8231,931.1594,56.80012,0,0,0,0,100,0), -- 20:24:23 +(@PATH,5,812.9963,933.0051,56.42346,0,0,0,0,100,0), -- 20:24:28 +(@PATH,6,812.416,948.0172,56.81141,0,0,0,0,100,0), -- 20:24:31 +(@PATH,7,813.5654,956.6572,55.9874,0,0,0,0,100,0), -- 20:24:35 +(@PATH,8,814.4669,959.6799,55.61625,0,0,0,0,100,0), -- 20:24:39 +(@PATH,9,815.8135,960.5793,55.61554,0,0,0,0,100,0), -- 20:24:44 +(@PATH,10,813.7318,955.5559,56.19109,0,0,0,0,100,0), -- 20:24:47 +(@PATH,11,812.7902,950.8799,56.58345,0,0,0,0,100,0), -- 20:24:50 +(@PATH,12,812.5013,941.1736,56.22784,0,0,0,0,100,0), -- 20:24:54 +(@PATH,13,816.401,926.7815,57.39321,0,0,0,0,100,0), -- 20:24:57 +(@PATH,14,818.651,925.7815,57.39321,0,0,0,0,100,0); -- 20:24:57 +-- 0x1C16F44680167D00006A5B00001D4972 .go 824.2386 922.0986 56.91497 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=53817; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(53817, 53817, 0, 0, 2), +(53817, 53818, 4, 270, 2); + +-- Pathing for Bonechewer Taskmaster Entry: 23028 'TDB FORMAT' +SET @NPC := 53817; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=779.7964,`position_y`=907.3997,`position_z`=55.31417 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,779.7964,907.3997,55.31417,0,0,0,0,100,0), -- 20:24:46 +(@PATH,2,787.9648,919.118,56.01221,0,0,0,0,100,0), -- 20:24:51 +(@PATH,3,793.1609,922.2444,56.78314,0,0,0,0,100,0), -- 20:24:55 +(@PATH,4,795.3989,923.1378,56.98447,0,0,0,0,100,0), -- 20:24:57 +(@PATH,5,801.3021,923.3855,57.17341,0,0,0,0,100,0), -- 20:25:00 +(@PATH,6,808.4121,919.6089,57.23282,0,0,0,0,100,0), -- 20:25:04 +(@PATH,7,812.0118,913.3118,57.18176,0,0,0,0,100,0), -- 20:25:06 +(@PATH,8,812.204,913.6752,57.22612,0,0,0,0,100,0), -- 20:25:12 +(@PATH,9,808.2915,919.7905,57.18939,0,0,0,0,100,0), -- 20:25:14 +(@PATH,10,801.1031,923.2393,57.11441,0,0,0,0,100,0), -- 20:25:18 +(@PATH,11,790.0347,920.629,56.37698,0,0,0,0,100,0), -- 20:25:21 +(@PATH,12,786.2445,917.2216,55.7047,0,0,0,0,100,0), -- 20:25:23 +(@PATH,13,783.3309,914.0374,55.27817,0,0,0,0,100,0); -- 20:25:27 +-- 0x1C16F44680167D00006A5B00009D4972 .go 779.7964 907.3997 55.31417 + +-- Pathing for Bonechewer Taskmaster Entry: 23028 'TDB FORMAT' +SET @NPC := 53815; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=614.9688,`position_y`=905.1718,`position_z`=59.02773 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,614.9688,905.1718,59.02773,0,0,0,0,100,0), -- 20:27:39 +(@PATH,2,602.5994,900.3304,59.40689,0,0,0,0,100,0), -- 20:27:41 +(@PATH,3,601.3251,900.2347,59.64486,0,0,0,0,100,0), -- 20:27:45 +(@PATH,4,596.3672,905.3165,59.73195,0,0,0,0,100,0), -- 20:27:47 +(@PATH,5,594.7749,909.9604,59.21187,0,0,0,0,100,0), -- 20:27:49 +(@PATH,6,598.7663,913.3591,58.69057,0,0,0,0,100,0), -- 20:27:53 +(@PATH,7,609.4606,912.4673,58.62482,0,0,0,0,100,0), -- 20:27:57 +(@PATH,8,615.0436,905.1978,58.98429,0,0,0,0,100,0); -- 20:28:00 +-- 0x1C16F44680167D00006A5B00019D4973 .go 614.9688 905.1718 59.02773 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=53820; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(53820, 53820, 0, 0, 2), +(53820, 53821, 4, 270, 2); + +-- Pathing for Bonechewer Taskmaster Entry: 23028 'TDB FORMAT' +SET @NPC := 53820; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=633.2257,`position_y`=963.4147,`position_z`=55.95343 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,633.2257,963.4147,55.95343,0,0,0,0,100,0), -- 20:24:38 +(@PATH,2,626.0544,963.9803,56.37569,0,0,0,0,100,0), -- 20:24:42 +(@PATH,3,620.5211,966.0339,56.25259,0,0,0,0,100,0), -- 20:24:43 +(@PATH,4,620.7354,966.1735,56.31302,0,0,0,0,100,0), -- 20:24:49 +(@PATH,5,626.1029,963.9597,56.25856,0,0,0,0,100,0), -- 20:24:52 +(@PATH,6,639.0172,964.6981,55.65588,0,0,0,0,100,0), -- 20:24:55 +(@PATH,7,640.4229,965.3899,55.41632,0,0,0,0,100,0), -- 20:24:58 +(@PATH,8,640.1735,965.0356,55.36687,0,0,0,0,100,0), -- 20:25:03 +(@PATH,9,634.595,963.6308,56.07304,0,0,0,0,100,0); -- 20:25:05 +-- 0x1C16F44680167D00006A5B00001D4973 .go 633.2257 963.4147 55.95343 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=52890; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(52890, 52890, 0, 0, 2), +(52890, 52889, 4, 270, 2); + +-- Pathing for Dragonmaw Wyrmcaller Entry: 22960 'TDB FORMAT' +SET @NPC := 52890; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=648.1636,`position_y`=938.5795,`position_z`=55.75506 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,648.1636,938.5795,55.75506,0,0,0,0,100,0), -- 20:22:53 +(@PATH,2,645.2552,922.6402,57.29848,0,0,0,0,100,0), -- 20:22:58 +(@PATH,3,645.6837,916.9199,58.23938,0,0,0,0,100,0), -- 20:23:03 +(@PATH,4,646.1837,910.1699,58.73938,0,0,0,0,100,0), -- 20:23:03 +(@PATH,5,645.2875,920.4247,58.00103,0,0,0,0,100,0), -- 20:23:11 +(@PATH,6,645.5131,925.1226,56.93448,0,0,0,0,100,0), -- 20:23:15 +(@PATH,7,645.7631,930.8726,56.43448,0,0,0,0,100,0), -- 20:23:15 +(@PATH,8,650.084,943.375,55.52758,0,0,0,0,100,0); -- 20:23:21 +-- 0x1C16F44680166C00006A5B00031D4972 .go 648.1636 938.5795 55.75506 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=52887; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(52887, 52887, 0, 0, 2), +(52887, 52888, 4, 270, 2); + +-- Pathing for Dragonmaw Wyrmcaller Entry: 22960 'TDB FORMAT' +SET @NPC := 52887; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=785.6938,`position_y`=775.3997,`position_z`=66.39993 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,785.6938,775.3997,66.39993,0,0,0,0,100,0), -- 20:24:19 +(@PATH,2,785.8984,794.7227,65.27033,0,0,0,0,100,0), -- 20:24:27 +(@PATH,3,786.6484,798.7227,64.77033,0,0,0,0,100,0), -- 20:24:27 +(@PATH,4,787.1109,818.1139,62.89856,0,0,0,0,100,0), -- 20:24:34 +(@PATH,5,787.1109,821.1139,62.39856,0,0,0,0,100,0), -- 20:24:34 +(@PATH,6,787.1893,815.1113,63.54066,0,0,0,0,100,0), -- 20:24:44 +(@PATH,7,787.1893,811.3613,64.04066,0,0,0,0,100,0), -- 20:24:44 +(@PATH,8,785.7648,793.4683,65.52825,0,0,0,0,100,0), -- 20:24:51 +(@PATH,9,785.2648,789.4683,66.27825,0,0,0,0,100,0), -- 20:24:51 +(@PATH,10,787.0689,764.1604,68.09256,0,0,0,0,100,0); -- 20:25:00 +-- 0x1C16F44680166C00006A5B00021D4972 .go 785.6938 775.3997 66.39993 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=52873; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(52873, 52873, 0, 0, 2), +(52873, 52874, 4, 270, 2); + +-- Pathing for Dragonmaw Wyrmcaller Entry: 22960 'TDB FORMAT' +SET @NPC := 52873; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=703.7258,`position_y`=793.4444,`position_z`=63.46073 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,703.7258,793.4444,63.46073,0,0,0,0,100,0), -- 20:22:58 +(@PATH,2,707.7258,805.4444,62.96073,0,0,0,0,100,0), -- 20:22:58 +(@PATH,3,707.654,812.1962,61.59881,0,0,0,0,100,0), -- 20:23:08 +(@PATH,4,706.654,814.9462,60.84881,0,0,0,0,100,0), -- 20:23:08 +(@PATH,5,705.904,817.9462,60.09881,0,0,0,0,100,0), -- 20:23:08 +(@PATH,6,705.404,820.6962,59.59881,0,0,0,0,100,0), -- 20:23:08 +(@PATH,7,704.5902,823.67,59.79628,0,0,0,0,100,0), -- 20:23:15 +(@PATH,8,704.8102,841.6521,58.77011,0,0,0,0,100,0), -- 20:23:20 +(@PATH,9,704.6913,842.5567,58.75265,0,0,0,0,100,0), -- 20:23:27 +(@PATH,10,704.126,829.2064,60.07757,0,0,0,0,100,0), -- 20:23:31 +(@PATH,11,707.3738,813.0848,61.42086,0,0,0,0,100,0), -- 20:23:36 +(@PATH,12,706.2325,801.4998,63.37791,0,0,0,0,100,0), -- 20:23:42 +(@PATH,13,702.9825,791.2498,63.87791,0,0,0,0,100,0), -- 20:23:42 +(@PATH,14,700.8631,770.6361,65.44987,0,0,0,0,100,0), -- 20:23:52 +(@PATH,15,700.8631,765.6361,65.94987,0,0,0,0,100,0), -- 20:23:52 +(@PATH,16,700.9891,782.0386,64.53194,0,0,0,0,100,0); -- 20:24:04 +-- 0x1C16F44680166C00006A5B00011D4972 .go 703.7258 793.4444 63.46073 diff --git a/sql/updates/world/2016_01_23_00_world.sql b/sql/updates/world/2016_01_23_00_world.sql new file mode 100644 index 00000000000..02eaa7c370d --- /dev/null +++ b/sql/updates/world/2016_01_23_00_world.sql @@ -0,0 +1,43 @@ +DELETE FROM `creature_formations` WHERE `leaderGUID`=63381; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(63381, 63381, 0, 0, 1), +(63381, 63380, 2, 270, 2); + +-- Pathing for Blade of Argus Entry: 17659 'TDB FORMAT' +SET @NPC := 63381; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-2393.32,`position_y`=-12009.38,`position_z`=26.83788 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-2393.32,-12009.38,26.83788,0,0,0,0,100,0), -- 09:35:02 +(@PATH,2,-2430.895,-12030.52,28.6322,0,0,0,0,100,0), -- 09:35:35 +(@PATH,3,-2449.131,-12041.39,30.04015,0,0,0,0,100,0), -- 09:35:47 +(@PATH,4,-2469.279,-12052.41,30.91039,0,0,0,0,100,0), -- 09:35:58 +(@PATH,5,-2485.917,-12057.62,31.67413,0,0,0,0,100,0), -- 09:36:06 +(@PATH,6,-2499.339,-12060.41,32.19662,0,0,0,0,100,0), -- 09:36:16 +(@PATH,7,-2551.131,-12097.43,31.56079,0,0,0,0,100,0), -- 09:36:26 +(@PATH,8,-2561.849,-12106.37,30.36333,0,0,0,0,100,0), -- 09:36:45 +(@PATH,9,-2594.441,-12132.8,25.2879,0,0,0,0,100,0), -- 09:36:59 +(@PATH,10,-2614.055,-12144.08,22.40907,0,0,0,0,100,0), -- 09:37:10 +(@PATH,11,-2646.337,-12163.92,17.16356,0,0,0,0,100,0), -- 09:37:24 +(@PATH,12,-2662.804,-12174.26,14.88417,0,0,0,0,100,0), -- 09:37:33 +(@PATH,13,-2684.956,-12188.63,12.24028,0,0,0,0,100,0), -- 09:37:43 +(@PATH,14,-2717.39,-12205.54,9.461565,0,0,0,0,100,0), -- 09:37:57 +(@PATH,15,-2734.083,-12209.19,8.946226,0,0,0,0,100,0), -- 09:38:09 +(@PATH,16,-2734.196,-12209.07,8.88302,0,0,0,0,100,0), -- 09:38:21 +(@PATH,17,-2716.481,-12205.85,9.632504,0,0,0,0,100,0), -- 09:38:31 +(@PATH,18,-2690.927,-12193.18,11.25666,0,0,0,0,100,0), -- 09:38:43 +(@PATH,19,-2673.976,-12180.86,13.79457,0,0,0,0,100,0), -- 09:38:55 +(@PATH,20,-2653.271,-12168.26,16.31552,0,0,0,0,100,0), -- 09:39:06 +(@PATH,21,-2634.485,-12156.3,19.4272,0,0,0,0,100,0), -- 09:39:16 +(@PATH,22,-2600.122,-12135.83,24.54786,0,0,0,0,100,0), -- 09:39:29 +(@PATH,23,-2580.325,-12122.89,27.64962,0,0,0,0,100,0), -- 09:39:40 +(@PATH,24,-2535.282,-12085.34,32.13941,0,0,0,0,100,0), -- 09:39:54 +(@PATH,25,-2520.165,-12073.53,32.51933,0,0,0,0,100,0), -- 09:40:14 +(@PATH,26,-2475.724,-12055.97,31.22906,0,0,0,0,100,0), -- 09:40:24 +(@PATH,27,-2463.655,-12049.68,30.5184,0,0,0,0,100,0), -- 09:40:33 +(@PATH,28,-2435.532,-12033.4,29.11832,0,0,0,0,100,0), -- 09:40:42 +(@PATH,29,-2407.538,-12018.4,27.76891,0,0,0,0,100,0), -- 09:40:53 +(@PATH,30,-2393.296,-12009.36,26.8369,0,0,0,0,100,0); -- 09:41:05 diff --git a/sql/updates/world/2016_01_24_00_world.sql b/sql/updates/world/2016_01_24_00_world.sql new file mode 100644 index 00000000000..a28b3fa25b8 --- /dev/null +++ b/sql/updates/world/2016_01_24_00_world.sql @@ -0,0 +1,62 @@ +-- +SET @guid:=134881; +DELETE FROM `creature` WHERE `guid` BETWEEN @guid+0 AND @guid+53; +INSERT INTO `creature` (`guid`, `id`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `modelid`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `currentwaypoint`, `curhealth`, `curmana`, `MovementType`, `npcflag`, `unit_flags`, `dynamicflags`, `VerifiedBuild`) VALUES +(@guid+0, 18927, 571, 0, 0, 1, 1, 18800, 0, 5740.71, 686.122, 643.896, 3.82227, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+1, 18927, 571, 0, 0, 1, 1, 18801, 0, 5739.36, 684.622, 644.191, 0.872665, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+2, 18927, 571, 0, 0, 1, 1, 18800, 0, 5664.31, 666.273, 652.064, 1.39626, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+3, 18927, 571, 0, 0, 1, 1, 18801, 0, 5664.37, 668.047, 652.051, 4.90438, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+4, 18927, 0, 0, 0, 1, 1, 18800, 0, -8364.87207, 617.860, 95.345, 2.580013, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+5, 18927, 0, 0, 0, 1, 1, 18801, 0, -8367.4511, 619.1992, 95.2811, 5.804225, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+6, 19169, 530, 0, 0, 1, 1, 18785, 0, 9375.07, -7157.06, 9.25588, 1.6057, 5, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+7, 19169, 530, 0, 0, 1, 1, 18793, 0, 9374.67, -7155.09, 9.33675, 4.95674, 5, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+8, 19169, 530, 0, 0, 1, 1, 18785, 0, 9689.33, -7345.39, 11.9144, 4.20624, 180, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+9, 19169, 530, 0, 0, 1, 1, 18793, 0, 9687.96, -7346.09, 11.956, 1.50098, 180, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+10, 19169, 530, 0, 0, 1, 1, 18785, 0, 9556.56, -7157.38, 14.2799, 6.10865, 120, 0, 0, 1, 0, 0, 3, 0, 0, 0), +(@guid+11, 19169, 530, 0, 0, 1, 1, 18793, 0, 9558.34, -7157.94, 14.3132, 2.63545, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+12, 19169, 530, 0, 0, 1, 1, 18785, 0, 9757.39, -7485.7, 13.6171, 4.76475, 120, 0, 0, 1, 0, 0, 3, 0, 0, 0), +(@guid+13, 19169, 530, 0, 0, 1, 1, 18793, 0, 9757.64, -7487.37, 13.6167, 1.55334, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+14, 19169, 571, 0, 0, 1, 1, 18785, 0, 5942.95, 629.234, 650.668, 1.5708, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+15, 19169, 571, 0, 0, 1, 1, 18793, 0, 5943.17, 630.894, 650.666, 4.90438, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+16, 19169, 571, 0, 0, 1, 1, 18785, 0, 5899.04, 532.766, 640.979, 4.90438, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+17, 19169, 571, 0, 0, 1, 1, 18793, 0, 5899.1, 530.898, 641.056, 1.67552, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+18, 19171, 530, 0, 0, 1, 1, 18795, 0, -4270.06, -11333.1, 5.57545, 4.67748, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@guid+19, 19171, 530, 0, 0, 1, 1, 18794, 0, -4269.71, -11336.5, 5.80931, 1.69297, 120, 0, 0, 1, 0, 0, 3, 0, 0, 0), +(@guid+20, 19175, 1, 0, 0, 1, 1, 18804, 0, 1609.47, -4323.21, 2.33176, 3.34811, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+21, 19175, 1, 0, 0, 1, 1, 18805, 0, 1605.95, -4324.2, 2.19915, 0.0101724, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+22, 19177, 1, 0, 0, 1, 1, 18808, 0, 1748.94, -4497.53, 28.793, 5.47104, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+23, 19177, 1, 0, 0, 1, 1, 18808, 0, 1752.58, -4499.43, 28.2911, 2.89886, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+24, 19178, 0, 0, 0, 1, 1, 18810, 0, 1629.95, 219.238, -43.1027, 1.91079, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+25, 20102, 0, 0, 0, 1, 1, 19342, 0, -14313.5, 508.853, 8.69121, 4.27606, 180, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+26, 20102, 0, 0, 0, 1, 1, 19339, 0, -14314, 507.109, 8.68829, 1.22173, 180, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+27, 20102, 1, 0, 0, 1, 1, 19342, 0, -1030.97, -3678.41, 23.2479, 1.62316, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+28, 20102, 1, 0, 0, 1, 1, 19339, 0, -1031.03, -3676.2, 23.1851, 4.69494, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+29, 20102, 1, 0, 0, 1, 1, 19342, 0, -924.656, -3715.91, 9.13173, 5.06145, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+30, 20102, 1, 0, 0, 1, 1, 19339, 0, -924.099, -3718, 9.18514, 1.69297, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+31, 20102, 1, 0, 0, 1, 1, 19342, 0, 6791.34, -4747.01, 701.617, 2.21657, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+32, 20102, 1, 0, 0, 1, 1, 19339, 0, -7144.12, -3830.95, 8.50543, 3.26377, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+33, 20102, 1, 0, 0, 1, 1, 19342, 0, -7147.06, -3830.22, 8.51396, 6.05629, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+34, 20102, 1, 0, 0, 1, 1, 19339, 0, -7217.57, -3735.16, 8.45314, 2.28638, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+35, 20102, 1, 0, 0, 1, 1, 19342, 0, -7219.66, -3731.91, 8.4635, 5.13127, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+36, 20102, 1, 0, 0, 1, 1, 19339, 0, -7053.62, -3777.21, 10.2047, 5.25344, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+37, 20102, 1, 0, 0, 1, 1, 19342, 0, -7053, -3779.9, 10.1478, 1.53589, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+38, 20102, 530, 0, 0, 1, 1, 19339, 0, -1818.99, 5305.67, -12.3448, 4.03171, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+39, 20102, 530, 0, 0, 1, 1, 19342, 0, -1821.12, 5303.35, -12.3448, 0.767945, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+40, 20102, 530, 0, 0, 1, 1, 19339, 0, -1748.08, 5493.86, -12.3448, 4.2586, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+41, 20102, 530, 0, 0, 1, 1, 19342, 0, -1747.9, 5492.11, -12.3448, 1.3439, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+42, 20102, 530, 0, 0, 1, 1, 19339, 0, -1978.82, 5365.21, -12.3448, 3.63029, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+43, 20102, 530, 0, 0, 1, 1, 19342, 0, -1980.72, 5364.88, -12.3225, 0.226893, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+44, 20102, 530, 0, 0, 1, 1, 19339, 0, -1875.93, 5376.2, -12.3448, 0.820305, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+45, 20102, 530, 0, 0, 1, 1, 19342, 0, -1875.06, 5378.04, -12.3448, 4.36332, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+46, 20102, 530, 0, 0, 1, 1, 19339, 0, -2175.76, 5414.62, 50.3112, 5.60251, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+47, 20102, 530, 0, 0, 1, 1, 19342, 0, -2174.14, 5413.06, 50.3112, 2.56563, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+48, 20102, 530, 0, 0, 1, 1, 19339, 0, -1809.92, 5418.64, -12.3448, 5.55015, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+49, 20102, 530, 0, 0, 1, 1, 19342, 0, -1808.36, 5417.01, -12.3448, 2.32129, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+50, 20102, 530, 0, 0, 1, 1, 19339, 0, -1917.81, 5441.85, -12.3448, 2.35619, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+51, 20102, 530, 0, 0, 1, 1, 19342, 0, -1920.17, 5443.52, -12.3448, 5.86431, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+52, 20102, 530, 0, 0, 1, 1, 19339, 0, -1883.61, 5769.28, 129.641, 4.15388, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0), +(@guid+53, 20102, 530, 0, 0, 1, 1, 19342, 0, -1884.14, 5766.55, 129.641, 1.309, 300, 0, 0, 42, 0, 0, 0, 0, 0, 0); + +SET @Event=2; +DELETE FROM `game_event_creature` WHERE `guid` BETWEEN @guid+0 AND @guid+53 AND `eventEntry`=@Event; +INSERT INTO `game_event_creature` SELECT @Event, creature.guid FROM `creature` WHERE creature.guid BETWEEN @guid+0 AND @guid+53; diff --git a/sql/updates/world/2016_01_26_00_world.sql b/sql/updates/world/2016_01_26_00_world.sql new file mode 100644 index 00000000000..71fe8dc21e3 --- /dev/null +++ b/sql/updates/world/2016_01_26_00_world.sql @@ -0,0 +1,11 @@ +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=28931; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(28931, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 19, 256, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Data Set 1 1 - Set Unit Flags'), +(28931, 0, 1, 6, 7, 0, 100, 0, 0, 0, 0, 0, 19, 256, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Evade - Set Unit Flags'), +(28931, 0, 2, 0, 8, 0, 100, 0, 61492, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Spellhit (Despawn Blightblood) - Despawn'), +(28931, 0, 3, 7, 54, 0, 100, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Just Summoned - Set Phase 1'), +(28931, 0, 4, 0, 4, 0, 100, 1, 0, 0, 0, 0, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Agro - Set Phase 2'), +(28931, 0, 5, 6, 8, 0, 100, 0, 53103, 0, 30000, 30000, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Spellhit (Charm Blightblood Troll) - Set Phase 2'), +(28931, 0, 6, 0, 61, 0, 100, 0, 0, 0, 0, 0, 8, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Spellhit (Charm Blightblood Troll) - Set Aggresie'), +(28931, 0, 7, 0, 61, 0, 100, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Blightblood Troll - On Just Summoned - Set Passive'), +(28931, 0, 8, 0, 1, 2, 100, 1, 0, 0, 0, 0, 45, 3, 3, 0, 0, 0, 0, 19, 29100, 10, 0, 0, 0, 0, 0, 'Blightblood Troll - OOC (Phase 2) - Set Data 3 3 on Totally Generic Bunny (JSB)'); diff --git a/sql/updates/world/2016_01_28_00_world_335.sql b/sql/updates/world/2016_01_28_00_world_335.sql new file mode 100644 index 00000000000..64b32cb2d89 --- /dev/null +++ b/sql/updates/world/2016_01_28_00_world_335.sql @@ -0,0 +1,12 @@ +-- Create new gossip_menu_option 3223 for Apothecary Dithers and 3228 for Alchemist Arbington: +DELETE FROM `gossip_menu_option` WHERE `menu_id` IN (3223,3228,3229) AND `OptionBroadcastTextID` IN (6516,6517,6518,6519,6531); +INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`,`BoxBroadcastTextID`) VALUES +(3223,0,0,"What's needed for the cauldron at Felstone Field?",6516,3,131,0,0,0,0,'',0), +(3223,1,0,"What's needed for the cauldron at Dalson's Tears?",6517,3,131,0,0,0,0,'',0), +(3223,2,0,"What's needed for the cauldron at the Writhing Haunt?",6518,3,131,0,0,0,0,'',0), +(3223,3,0,"What's needed for the cauldron at Gahrron's Withering?",6519,3,131,0,0,0,0,'',0), +(3228,0,0,"What's needed for the cauldron at Felstone Field?",6516,3,131,0,0,0,0,'',0), +(3228,1,0,"What's needed for the cauldron at Dalson's Tears?",6517,3,131,0,0,0,0,'',0), +(3228,2,0,"What's needed for the cauldron at the Writhing Haunt?",6518,3,131,0,0,0,0,'',0), +(3228,3,0,"What's needed for the cauldron at Gahrron's Withering?",6519,3,131,0,0,0,0,'',0), +(3229,0,0,"I need a Vitreous Focuser.",6531,3,131,0,0,0,0,'',0); diff --git a/sql/updates/world/2016_01_28_01_world.sql b/sql/updates/world/2016_01_28_01_world.sql new file mode 100644 index 00000000000..3c4cadb310d --- /dev/null +++ b/sql/updates/world/2016_01_28_01_world.sql @@ -0,0 +1,194 @@ +SET @ENTRY := 177226; +SET @GOSSIP_ID := 7058; +SET @NPC_TEXT_UNLEARN := 8321; +SET @NPC_TEXT_LEARN_ENG := 6; +SET @NPC_TEXT_LEARN_LW := 7; +UPDATE `gameobject_template` SET `ScriptName`='go_soothsaying_for_dummies' WHERE `entry`=@ENTRY; +-- Missing gossip texts +DELETE FROM `npc_text` WHERE `ID` IN (@NPC_TEXT_LEARN_ENG,@NPC_TEXT_LEARN_LW); +INSERT INTO `npc_text` (`ID`,`text0_0`,`text0_1`,`BroadcastTextID0`,`lang0`,`Probability0`,`em0_0`,`em0_1`,`em0_2`,`em0_3`,`em0_4`,`em0_5`,`text1_0`,`text1_1`,`BroadcastTextID1`,`lang1`,`Probability1`,`em1_0`,`em1_1`,`em1_2`,`em1_3`,`em1_4`,`em1_5`,`text2_0`,`text2_1`,`BroadcastTextID2`,`lang2`,`Probability2`,`em2_0`,`em2_1`,`em2_2`,`em2_3`,`em2_4`,`em2_5`,`text3_0`,`text3_1`,`BroadcastTextID3`,`lang3`,`Probability3`,`em3_0`,`em3_1`,`em3_2`,`em3_3`,`em3_4`,`em3_5`,`text4_0`,`text4_1`,`BroadcastTextID4`,`lang4`,`Probability4`,`em4_0`,`em4_1`,`em4_2`,`em4_3`,`em4_4`,`em4_5`,`text5_0`,`text5_1`,`BroadcastTextID5`,`lang5`,`Probability5`,`em5_0`,`em5_1`,`em5_2`,`em5_3`,`em5_4`,`em5_5`,`text6_0`,`text6_1`,`BroadcastTextID6`,`lang6`,`Probability6`,`em6_0`,`em6_1`,`em6_2`,`em6_3`,`em6_4`,`em6_5`,`text7_0`,`text7_1`,`BroadcastTextID7`,`lang7`,`Probability7`,`em7_0`,`em7_1`,`em7_2`,`em7_3`,`em7_4`,`em7_5`,`VerifiedBuild`) VALUES +(@NPC_TEXT_LEARN_ENG,'Hundreds of various diagrams and schematics begin to take shape on the pages of the book. You recognize some of the diagrams while others remain foreign but familiar.','Hundreds of various diagrams and schematics begin to take shape on the pages of the book. You recognize some of the diagrams while others remain foreign but familiar.',11875,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,0), +(@NPC_TEXT_LEARN_LW,'The assortment of images, shapes, and markings come together before your eyes. The book seems to know your skill with leatherworking and offers you a choice - but be warned - you may only select one and once you have done so, may not change your mind!:','The assortment of images, shapes, and markings come together before your eyes. The book seems to know your skill with leatherworking and offers you a choice - but be warned - you may only select one and once you have done so, may not change your mind!:',11892,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,'','',0,0,0,0,0,0,0,0,0,0); +-- Link gossip to menu +DELETE FROM `gossip_menu` WHERE `entry`=@GOSSIP_ID AND `text_id` IN (@NPC_TEXT_LEARN_ENG,@NPC_TEXT_LEARN_LW); +INSERT INTO `gossip_menu` (`entry`,`text_id`) VALUES +(@GOSSIP_ID, @NPC_TEXT_LEARN_ENG), +(@GOSSIP_ID, @NPC_TEXT_LEARN_LW); + +DELETE FROM `gossip_menu_option` WHERE `menu_id`=@GOSSIP_ID; +INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`,`BoxBroadcastTextID`) VALUES +(@GOSSIP_ID,0,0,'I wish to unlearn my Gnomish Engineering specialization!',36143,1,0,0,0,0,1500000,'Do you really want to unlearn your Gnomish Engineering specialization and lose all associated recipes?',36144), +(@GOSSIP_ID,1,0,'I wish to unlearn my Goblin Engineering specialization!',36146,1,0,0,0,0,1500000,'Do you really want to unlearn your Goblin Engineering specialization and lose all associated recipes?',36145), +(@GOSSIP_ID,2,0,'I am 100% confident that I wish to learn in the ways of gnomish engineering.',11878,1,0,0,0,0,0,'',0), +(@GOSSIP_ID,3,0,'I am 100% confident that I wish to learn in the ways of goblin engineering.',11876,1,0,0,0,0,0,'',0), +(@GOSSIP_ID,4,0,'I am absolutely certain that I want to learn dragonscale leatherworking.',11889,1,0,0,0,0,0,'',0), +(@GOSSIP_ID,5,0,'I am absolutely certain that I want to learn elemental leatherworking.',11890,1,0,0,0,0,0,'',0), +(@GOSSIP_ID,6,0,'I am absolutely certain that I want to learn tribal leatherworking.',11891,1,0,0,0,0,0,'',0); + +-- Conditions +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId` IN (14,15) AND `SourceGroup`=@GOSSIP_ID; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorType`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,0,7,0,202,200,0,0,0,0,'','Show this menu if player has engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,0,8,0,3639,0,0,0,0,0,'','Show this menu if player has rewarded Show your Work [Goblin]'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,0,25,0,20219,0,0,1,0,0,'','Show this menu if player doesn''t have Gnomish Engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,0,25,0,20222,0,0,1,0,0,'','Show this menu if player doesn''t have Goblin Engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,1,7,0,202,200,0,0,0,0,'','Show this menu if player has engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,1,8,0,3641,0,0,0,0,0,'','Show this menu if player has rewarded Show your Work [Alliance]'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,1,25,0,20219,0,0,1,0,0,'','Show this menu if player doesn''t have Gnomish Engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,1,25,0,20222,0,0,1,0,0,'','Show this menu if player doesn''t have Goblin Engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,2,7,0,202,200,0,0,0,0,'','Show this menu if player has engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,2,8,0,3643,0,0,0,0,0,'','Show this menu if player has rewarded Show your Work [Horde]'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,2,25,0,20219,0,0,1,0,0,'','Show this menu if player doesn''t have Gnomish Engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_ENG,0,2,25,0,20222,0,0,1,0,0,'','Show this menu if player doesn''t have Goblin Engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,0,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,0,8,0,5141,0,0,0,0,0,'','Show this menu if player has rewarded Dragonscale Leatherworking [Alliance]'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,0,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,0,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,0,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,1,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,1,8,0,5143,0,0,0,0,0,'','Show this menu if player has rewarded Tribal Leatherworking [Alliance]'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,1,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,1,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,1,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,2,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,2,8,0,5144,0,0,0,0,0,'','Show this menu if player has rewarded Elemental Leatherworking [Alliance]'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,2,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,2,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,2,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,3,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,3,8,0,5145,0,0,0,0,0,'','Show this menu if player has rewarded Dragonscale Leatherworking [Horde]'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,3,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,3,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,3,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,4,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,4,8,0,5148,0,0,0,0,0,'','Show this menu if player has rewarded Tribal Leatherworking [Horde]'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,4,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,4,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,4,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,5,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,5,8,0,5146,0,0,0,0,0,'','Show this menu if player has rewarded Elemental Leatherworking [Horde]'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,5,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,5,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_LEARN_LW,0,5,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(14,@GOSSIP_ID,@NPC_TEXT_UNLEARN,0,0,7,0,202,200,0,0,0,0,'','Show this menu if player has engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_UNLEARN,0,0,25,0,20219,0,0,0,0,0,'','Show this menu if player does have Gnomish Engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_UNLEARN,0,1,7,0,202,200,0,0,0,0,'','Show this menu if player has engineering'), +(14,@GOSSIP_ID,@NPC_TEXT_UNLEARN,0,1,25,0,20222,0,0,0,0,0,'','Show this menu if player does have Goblin Engineering'), +(15,@GOSSIP_ID,0,0,0,7,0,202,200,0,0,0,0,'','Show option if player has engineering'), +(15,@GOSSIP_ID,0,0,0,25,0,20219,0,0,0,0,0,'','Show option if player does have Gnomish Engineering'), +(15,@GOSSIP_ID,1,0,0,7,0,202,200,0,0,0,0,'','Show option if player has engineering'), +(15,@GOSSIP_ID,1,0,0,25,0,20222,0,0,0,0,0,'','Show option if player does have Gnomish Engineering'), +(15,@GOSSIP_ID,2,0,0,7,0,202,200,0,0,0,0,'','Show option if player has engineering'), +(15,@GOSSIP_ID,2,0,0,8,0,3639,0,0,0,0,0,'','Show option if player has rewarded Show your Work [Goblin]'), +(15,@GOSSIP_ID,2,0,0,25,0,20219,0,0,1,0,0,'','Show option if player doesn''t have Gnomish Engineering'), +(15,@GOSSIP_ID,2,0,0,25,0,20222,0,0,1,0,0,'','Show option if player doesn''t have Goblin Engineering'), +(15,@GOSSIP_ID,2,0,1,7,0,202,200,0,0,0,0,'','Show option if player has engineering'), +(15,@GOSSIP_ID,2,0,1,8,0,3641,0,0,0,0,0,'','Show option if player has rewarded Show your Work [Alliance]'), +(15,@GOSSIP_ID,2,0,1,25,0,20219,0,0,1,0,0,'','Show option if player doesn''t have Gnomish Engineering'), +(15,@GOSSIP_ID,2,0,1,25,0,20222,0,0,1,0,0,'','Show option if player doesn''t have Goblin Engineering'), +(15,@GOSSIP_ID,2,0,2,7,0,202,200,0,0,0,0,'','Show option if player has engineering'), +(15,@GOSSIP_ID,2,0,2,8,0,3643,0,0,0,0,0,'','Show option if player has rewarded Show your Work [Horde]'), +(15,@GOSSIP_ID,2,0,2,25,0,20219,0,0,1,0,0,'','Show option if player doesn''t have Gnomish Engineering'), +(15,@GOSSIP_ID,2,0,2,25,0,20222,0,0,1,0,0,'','Show option if player doesn''t have Goblin Engineering'), +(15,@GOSSIP_ID,3,0,0,7,0,202,200,0,0,0,0,'','Show option if player has engineering'), +(15,@GOSSIP_ID,3,0,0,8,0,3639,0,0,0,0,0,'','Show option if player has rewarded Show your Work [Goblin]'), +(15,@GOSSIP_ID,3,0,0,25,0,20219,0,0,1,0,0,'','Show option if player doesn''t have Gnomish Engineering'), +(15,@GOSSIP_ID,3,0,0,25,0,20222,0,0,1,0,0,'','Show option if player doesn''t have Goblin Engineering'), +(15,@GOSSIP_ID,3,0,1,7,0,202,200,0,0,0,0,'','Show option if player has engineering'), +(15,@GOSSIP_ID,3,0,1,8,0,3641,0,0,0,0,0,'','Show option if player has rewarded Show your Work [Alliance]'), +(15,@GOSSIP_ID,3,0,1,25,0,20219,0,0,1,0,0,'','Show option if player doesn''t have Gnomish Engineering'), +(15,@GOSSIP_ID,3,0,1,25,0,20222,0,0,1,0,0,'','Show option if player doesn''t have Goblin Engineering'), +(15,@GOSSIP_ID,3,0,2,7,0,202,200,0,0,0,0,'','Show option if player has engineering'), +(15,@GOSSIP_ID,3,0,2,8,0,3643,0,0,0,0,0,'','Show option if player has rewarded Show your Work [Horde]'), +(15,@GOSSIP_ID,3,0,2,25,0,20219,0,0,1,0,0,'','Show option if player doesn''t have Gnomish Engineering'), +(15,@GOSSIP_ID,3,0,2,25,0,20222,0,0,1,0,0,'','Show option if player doesn''t have Goblin Engineering'), +(15,@GOSSIP_ID,4,0,0,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,4,0,0,8,0,5141,0,0,0,0,0,'','Show this menu if player has rewarded Dragonscale Leatherworking [Alliance]'), +(15,@GOSSIP_ID,4,0,0,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,4,0,0,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,4,0,0,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,4,0,1,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,4,0,1,8,0,5143,0,0,0,0,0,'','Show this menu if player has rewarded Tribal Leatherworking [Alliance]'), +(15,@GOSSIP_ID,4,0,1,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,4,0,1,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,4,0,1,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,4,0,2,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,4,0,2,8,0,5144,0,0,0,0,0,'','Show this menu if player has rewarded Elemental Leatherworking [Alliance]'), +(15,@GOSSIP_ID,4,0,2,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,4,0,2,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,4,0,2,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,4,0,3,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,4,0,3,8,0,5145,0,0,0,0,0,'','Show this menu if player has rewarded Dragonscale Leatherworking [Horde]'), +(15,@GOSSIP_ID,4,0,3,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,4,0,3,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,4,0,3,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,4,0,4,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,4,0,4,8,0,5148,0,0,0,0,0,'','Show this menu if player has rewarded Tribal Leatherworking [Horde]'), +(15,@GOSSIP_ID,4,0,4,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,4,0,4,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,4,0,4,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,4,0,5,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,4,0,5,8,0,5146,0,0,0,0,0,'','Show this menu if player has rewarded Elemental Leatherworking [Horde]'), +(15,@GOSSIP_ID,4,0,5,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,4,0,5,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,4,0,5,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,5,0,0,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,5,0,0,8,0,5141,0,0,0,0,0,'','Show this menu if player has rewarded Dragonscale Leatherworking [Alliance]'), +(15,@GOSSIP_ID,5,0,0,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,5,0,0,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,5,0,0,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,5,0,1,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,5,0,1,8,0,5143,0,0,0,0,0,'','Show this menu if player has rewarded Tribal Leatherworking [Alliance]'), +(15,@GOSSIP_ID,5,0,1,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,5,0,1,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,5,0,1,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,5,0,2,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,5,0,2,8,0,5144,0,0,0,0,0,'','Show this menu if player has rewarded Elemental Leatherworking [Alliance]'), +(15,@GOSSIP_ID,5,0,2,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,5,0,2,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,5,0,2,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,5,0,3,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,5,0,3,8,0,5145,0,0,0,0,0,'','Show this menu if player has rewarded Dragonscale Leatherworking [Horde]'), +(15,@GOSSIP_ID,5,0,3,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,5,0,3,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,5,0,3,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,5,0,4,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,5,0,4,8,0,5148,0,0,0,0,0,'','Show this menu if player has rewarded Tribal Leatherworking [Horde]'), +(15,@GOSSIP_ID,5,0,4,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,5,0,4,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,5,0,4,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,5,0,5,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,5,0,5,8,0,5146,0,0,0,0,0,'','Show this menu if player has rewarded Elemental Leatherworking [Horde]'), +(15,@GOSSIP_ID,5,0,5,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,5,0,5,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,5,0,5,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,6,0,0,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,6,0,0,8,0,5141,0,0,0,0,0,'','Show this menu if player has rewarded Dragonscale Leatherworking [Alliance]'), +(15,@GOSSIP_ID,6,0,0,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,6,0,0,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,6,0,0,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,6,0,1,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,6,0,1,8,0,5143,0,0,0,0,0,'','Show this menu if player has rewarded Tribal Leatherworking [Alliance]'), +(15,@GOSSIP_ID,6,0,1,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,6,0,1,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,6,0,1,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,6,0,2,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,6,0,2,8,0,5144,0,0,0,0,0,'','Show this menu if player has rewarded Elemental Leatherworking [Alliance]'), +(15,@GOSSIP_ID,6,0,2,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,6,0,2,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,6,0,2,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,6,0,3,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,6,0,3,8,0,5145,0,0,0,0,0,'','Show this menu if player has rewarded Dragonscale Leatherworking [Horde]'), +(15,@GOSSIP_ID,6,0,3,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,6,0,3,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,6,0,3,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,6,0,4,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,6,0,4,8,0,5148,0,0,0,0,0,'','Show this menu if player has rewarded Tribal Leatherworking [Horde]'), +(15,@GOSSIP_ID,6,0,4,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,6,0,4,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,6,0,4,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'), +(15,@GOSSIP_ID,6,0,5,7,0,165,225,0,0,0,0,'','Show this menu if player has leatherworking'), +(15,@GOSSIP_ID,6,0,5,8,0,5146,0,0,0,0,0,'','Show this menu if player has rewarded Elemental Leatherworking [Horde]'), +(15,@GOSSIP_ID,6,0,5,25,0,10656,0,0,1,0,0,'','Show this menu if player doesn''t have Dragonscale Leatherworking'), +(15,@GOSSIP_ID,6,0,5,25,0,10658,0,0,1,0,0,'','Show this menu if player doesn''t have Elemental Leatherworking'), +(15,@GOSSIP_ID,6,0,5,25,0,10660,0,0,1,0,0,'','Show this menu if player doesn''t have Tribal Leatherworking'); diff --git a/sql/updates/world/2016_01_30_00_world_335.sql b/sql/updates/world/2016_01_30_00_world_335.sql new file mode 100644 index 00000000000..43025f581d7 --- /dev/null +++ b/sql/updates/world/2016_01_30_00_world_335.sql @@ -0,0 +1,65 @@ +-- NPC 4488 Parqual Fintallas creature_template script name update: +UPDATE `creature_template` SET `AIName` = 'SmartAI', `ScriptName`= '' WHERE `entry` = 4488; + +-- new gossip_menu_option 4764: +DELETE FROM `gossip_menu_option` WHERE `menu_id`= 4764 AND `id` IN (0,1,2,3); +INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`,`BoxBroadcastTextID`) VALUES +(4764, 0, 0, "Kel'Thuzad is my answer.", 8377, 1, 1, 0,0,0,0,'',0), +(4764, 1, 0, "Gul'dan is my answer.", 8378, 1, 1, 0,0,0,0,'',0), +(4764, 2, 0, "Kil'jaeden is my answer.", 8379, 1, 1, 0,0,0,0,'',0), +(4764, 3, 0, "Ner'zhul is my answer.", 8380, 1, 1, 0,0,0,0,'',0); + +-- new gossip_menu.entry linking quest text to gossip menu: +DELETE FROM `gossip_menu` WHERE `entry`= 4764 AND `text_id`= 5822; +INSERT INTO `gossip_menu` (`entry`,`text_id`) VALUES (4764, 5822); + +-- broadcast_text English grammar correction: +UPDATE `broadcast_text` SET `MaleText`= "Kel'Thuzad? If you know that name at all, then perhaps you did read the book I sent you to get.$B$BUnfortunately, your answer is incorrect." WHERE `ID`= 8373; + +-- creature_text (say lines) in reply to the selected options: +DELETE FROM `creature_text` WHERE `entry` = 4488 AND `groupid` IN (0,1,2,3,4); +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`BroadcastTextId`,`TextRange`,`comment`) VALUES +(4488,0,0,"Kel'Thuzad? If you know that name at all, then perhaps you did read the book I sent you to get.$B$BUnfortunately, your answer is incorrect.",12,0,100,1,5000,0,8373,0,'Parqual replies to option 1'), +(4488,1,0,"Gul'dan. Not a name many have heard on Azeroth.$B$BUnfortunately, not the correct answer.", 12,0,100,1,5000,0,8374,0,'Parqual replies to option 2'), +(4488,2,0,'An interesting response to my question... and the wrong one.', 12,0,100,1,5000,0,8375,0,'Parqual replies to option 3'), +(4488,3,0,"Ah, Ner'zhul. Not a name that should be uttered lightly, but I did ask you for an answer.$B$BAnd Ner'zhul is the correct one.", 12,0,100,1,5000,0,8376,0,'Parqual replies to option 4'), +(4488,4,0,"I'm afraid not, $n. Now, feel the shame you have brought upon yourself.", 12,0,100,1,3000,0,8394,0,'Parqual, reply 2 to option 1-3'); + +-- new SmartAI script for NPC 4488 Parqual Fintallas: +DELETE FROM `smart_scripts` WHERE `entryorguid` = 4488 AND `source_type` = 0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(4488,0, 0, 1, 62,0,100,0, 4764, 0,0,0, 83, 3, 0,0,0,0,0, 10, 32022, 4488,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 0 Selected - Remove npcflags Gossip & Questgiver'), +(4488,0, 1, 2, 61,0,100,0, 0, 0,0,0, 72, 0, 0,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 0 Selected - Close Gossip'), +(4488,0, 2, 0, 61,0,100,0, 0, 0,0,0, 1, 0, 5000,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 0 Selected - Say Text 0'), +(4488,0, 3, 0, 52,0,100,0, 0, 4488,0,0, 1, 4, 3000,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Text 0 Over - Say Text 4'), +(4488,0, 4, 5, 52,0,100,0, 4, 4488,0,0, 11, 6767, 2,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Text 4 Over - Cast \'Mark of Shame\''), +(4488,0, 5, 0, 61,0,100,0, 0, 0,0,0, 81, 3, 0,0,0,0,0, 10, 32022, 4488,0,0,0,0,0,'Parqual Fintallas - On Text 4 Over - Set npcflags Gossip & Questgiver'), +(4488,0, 6, 7, 62,0,100,0, 4764, 1,0,0, 83, 3, 0,0,0,0,0, 10, 32022, 4488,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 1 Selected - Remove npcflags Gossip & Questgiver'), +(4488,0, 7, 8, 61,0,100,0, 0, 0,0,0, 72, 0, 0,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 1 Selected - Close Gossip'), +(4488,0, 8, 0, 61,0,100,0, 0, 0,0,0, 1, 1, 5000,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 1 Selected - Say Text 1'), +(4488,0, 9, 0, 52,0,100,0, 1, 4488,0,0, 1, 4, 3000,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Text 1 Over - Say Text 4'), +(4488,0, 10, 11, 62,0,100,0, 4767, 2,0,0, 83, 3, 0,0,0,0,0, 10, 32022, 4488,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 2 Selected - Remove npcflags Gossip & Questgiver'), +(4488,0, 11, 12, 61,0,100,0, 0, 0,0,0, 72, 0, 0,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 2 Selected - Close Gossip'), +(4488,0, 12, 0, 61,0,100,0, 0, 0,0,0, 1, 2, 5000,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 2 Selected - Say Text 2'), +(4488,0, 13, 0, 52,0,100,0, 2, 4488,0,0, 1, 4, 3000,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Text 2 Over - Say Text 4'), +(4488,0, 14, 15, 62,0,100,0, 4764, 3,0,0, 83, 3, 0,0,0,0,0, 10, 32022, 4488,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 3 Selected - Remove npcflags Gossip & Questgiver'), +(4488,0, 15, 16, 61,0,100,0, 0, 0,0,0, 72, 0, 0,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 3 Selected - Close Gossip'), +(4488,0, 16, 17, 61,0,100,0, 0, 0,0,0, 1, 3, 3000,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 3 Selected - Say Text 3'), +(4488,0, 17, 18, 61,0,100,0, 0, 0,0,0, 5, 2, 0,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 3 Selected - Play Emote 2 '), +(4488,0, 18, 19, 61,0,100,0, 0, 0,0,0, 15, 6628, 0,0,0,0,0, 7, 0, 0,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 3 Selected - Credit quest 6628 \'Test of Lore\''), +(4488,0, 19, 0, 61,0,100,0, 0, 0,0,0, 81, 3, 0,0,0,0,0, 10, 32022, 4488,0,0,0,0,0,'Parqual Fintallas - On Gossip Option 3 Selected - Set npcflags Gossip & Questgiver'); + +-- conditions showing gossip menu and gossip menu options only when Quest 6628 is active and Mark of Shame is not. +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`= 14 AND `SourceGroup`= 4764 AND `SourceEntry` IN (5821,5822); +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`= 15 AND `SourceGroup`= 4764 AND `SourceEntry` IN (0,1,2,3); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorType`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(14, 4764, 5821, 0, 0, 9, 0, 6628, 0, 0, 1, 0, 0, '', 'Show gossip dialog text 5821 if Quest 6628 is NOT taken'), +(14, 4764, 5822, 0, 0, 9, 0, 6628, 0, 0, 0, 0, 0, '', 'Show gossip dialog text 5822 if Quest 6628 is taken (active)'), +(15, 4764, 0, 0, 0, 9, 0, 6628, 0, 0, 0, 0, 0, '', 'Show gossip option 4764 id 0 if Quest 6628 is taken (active)'), +(15, 4764, 1, 0, 0, 9, 0, 6628, 0, 0, 0, 0, 0, '', 'Show gossip option 4764 id 1 if Quest 6628 is taken (active)'), +(15, 4764, 2, 0, 0, 9, 0, 6628, 0, 0, 0, 0, 0, '', 'Show gossip option 4764 id 2 if Quest 6628 is taken (active)'), +(15, 4764, 3, 0, 0, 9, 0, 6628, 0, 0, 0, 0, 0, '', 'Show gossip option 4764 id 3 if Quest 6628 is taken (active)'), +(15, 4764, 0, 0, 0, 1, 0, 6767, 0, 0, 1, 0, 0, '', 'Show gossip option 4764 id 0 if Player does NOT have Aura from spell 6767'), +(15, 4764, 1, 0, 0, 1, 0, 6767, 0, 0, 1, 0, 0, '', 'Show gossip option 4764 id 1 if Player does NOT have Aura from spell 6767'), +(15, 4764, 2, 0, 0, 1, 0, 6767, 0, 0, 1, 0, 0, '', 'Show gossip option 4764 id 2 if Player does NOT have Aura from spell 6767'), +(15, 4764, 3, 0, 0, 1, 0, 6767, 0, 0, 1, 0, 0, '', 'Show gossip option 4764 id 3 if Player does NOT have Aura from spell 6767'); diff --git a/sql/updates/world/2016_01_30_01_world.sql b/sql/updates/world/2016_01_30_01_world.sql new file mode 100644 index 00000000000..c9405c4ee61 --- /dev/null +++ b/sql/updates/world/2016_01_30_01_world.sql @@ -0,0 +1,6 @@ +-- +SET @Guid:=6177; +DELETE FROM `gameobject` WHERE `guid` IN (@Guid+0, @Guid+1); +INSERT INTO `gameobject` (`guid`, `id`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`, `VerifiedBuild`) VALUES +(@Guid+0, 201888, 631, 0, 0, 15, 1, 4312.29, 3025.22, 360.518, 2.92954, 0, 0, 0.994384, 0.105829, 604800, 0, 1, 0), +(@Guid+1, 201889, 631, 0, 0, 15, 1, 4403.27, 3027.19, 360.52, 0.0274907, 0, 0, 0.0137449, 0.999906, 604800, 0, 1, 0); diff --git a/sql/updates/world/2016_01_30_02_world.sql b/sql/updates/world/2016_01_30_02_world.sql new file mode 100644 index 00000000000..25325dddd7a --- /dev/null +++ b/sql/updates/world/2016_01_30_02_world.sql @@ -0,0 +1,336 @@ +SET @CGUID := 106855; + +UPDATE `creature_template` SET `unit_flags`=33536 WHERE `entry`=31029; +UPDATE `creature_template` SET `unit_flags`=33088 WHERE `entry`=31016; +UPDATE `creature_template` SET `unit_flags`=768 WHERE `entry`=31083; +UPDATE `creature_template` SET `InhabitType`=4 WHERE `entry` IN(31050,31030,31029,31087); +UPDATE `creature_template` SET `unit_flags`=256 WHERE `entry`=31050; +UPDATE `creature_template` SET `unit_flags`=33555200 WHERE `entry`=31077; +UPDATE `creature_template_addon` SET `auras`='0' WHERE `entry`=31083; + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry` IN(4020); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(13, 1, 4020, 0, 0, 31, 0, 3, 31077, 0, 0, 0, 0, '', ''); + +DELETE FROM `creature` WHERE `id`=31077; +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+23 AND `id` IN(31030,31077); +INSERT INTO `creature` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `MovementType`) VALUES +(@CGUID+0, 31030, 571, 1, 1, 7108.229, 4428.539, 837.9857, 4.782202, 120, 0, 0), -- 31030 (Area: 210) (Auras: 4366 - 4366) (possible waypoints or random movement) +(@CGUID+1, 31030, 571, 1, 1, 7092.146, 4431.81, 836.628, 4.590216, 120, 0, 0), -- 31030 (Area: 210) (Auras: 4366 - 4366) (possible waypoints or random movement) +(@CGUID+2, 31030, 571, 1, 1, 7118.42, 4432.598, 837.9554, 4.869469, 120, 0, 0), -- 31030 (Area: 210) (Auras: 4366 - 4366) (possible waypoints or random movement) +(@CGUID+3, 31030, 571, 1, 1, 7083.883, 4438.466, 834.9834, 4.572762, 120, 0, 0), -- 31030 (Area: 210) (Auras: 4366 - 4366) (possible waypoints or random movement) +(@CGUID+4, 31030, 571, 1, 1, 7111.272, 4445.171, 838.5065, 4.834562, 120, 0, 0), -- 31030 (Area: 210) (Auras: 4366 - 4366) (possible waypoints or random movement) +(@CGUID+5, 31030, 571, 1, 1, 7090.73, 4446.96, 837.0818, 3.402185, 120, 0, 0), -- 31030 (Area: 210) (Auras: 4366 - 4366) +(@CGUID+6, 31077, 571, 1, 1, 7081.854, 4311.559, 871.1456, 0.8552113, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+7, 31077, 571, 1, 1, 7097.221, 4343.909, 871.829, 4.24115, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+8, 31077, 571, 1, 1, 7073.036, 4321.123, 871.2318, 4.118977, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+9, 31077, 571, 1, 1, 7058.097, 4318.563, 871.0363, 2.216568, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+10, 31077, 571, 1, 1, 7069.263, 4307.413, 870.969, 3.769911, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+11, 31077, 571, 1, 1, 7091.653, 4324.766, 871.4558, 6.161012, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+12, 31077, 571, 1, 1, 7105.507, 4331.751, 871.8961, 5.270895, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+13, 31077, 571, 1, 1, 7081.499, 4355.459, 871.8806, 3.089233, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+14, 31077, 571, 1, 1, 7107.956, 4349.756, 872.166, 3.316126, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+15, 31077, 571, 1, 1, 7060.825, 4333.478, 871.3121, 2.565634, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+16, 31077, 571, 1, 1, 7077.684, 4338.44, 871.5625, 1.710423, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+17, 31077, 571, 1, 1, 7103.35, 4365.286, 872.2496, 2.792527, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+18, 31077, 571, 1, 1, 7069.498, 4374.775, 872.0762, 3.700098, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+19, 31077, 571, 1, 1, 7056.396, 4366.188, 871.9349, 4.415683, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+20, 31077, 571, 1, 1, 7088.755, 4385.249, 872.4426, 0.4014257, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+21, 31077, 571, 1, 1, 7084.891, 4370.708, 872.1652, 3.525565, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+22, 31077, 571, 1, 1, 7065.018, 4353.726, 871.6901, 5.899213, 120, 0, 0), -- 31077 (Area: 210) +(@CGUID+23, 31077, 571, 1, 1, 7048.843, 4346.518, 871.6175, 2.984513, 120, 0, 0); -- 31077 (Area: 210) + +DELETE FROM `vehicle_template_accessory` WHERE `entry`=31050; +INSERT INTO `vehicle_template_accessory` (`entry`, `accessory_entry`, `seat_id`, `minion`, `description`, `summontype`, `summontimer`) VALUES +(31050, 31016, 0, 0, '31050 - 31016', 6, 30000); -- 31050 - 31016 + +DELETE FROM `npc_spellclick_spells` WHERE `npc_entry`=31050; +INSERT INTO `npc_spellclick_spells` (`npc_entry`, `spell_id`, `cast_flags`, `user_type`) VALUES +(31050, 46598, 1, 0); + +DELETE FROM `spell_group` WHERE `id`=4307; + +DELETE FROM `spell_group_stack_rules` WHERE `group_id`=4307; + +DELETE FROM `creature_addon` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+5; +INSERT INTO `creature_addon` (`guid`, `mount`, `bytes1`, `bytes2`, `auras`) VALUES +(@CGUID+0, 26882, 0x3000000, 0x1, '4366'), -- 31030 - 4366 - 4366 0xF130793600719D57 +(@CGUID+1, 26882, 0x3000000, 0x1, '4366'), -- 31030 - 4366 - 4366 0xF130793600719D58 +(@CGUID+2, 26882, 0x3000000, 0x1, '4366'), -- 31030 - 4366 - 4366 0xF130793600719D59 +(@CGUID+3, 26882, 0x3000000, 0x1, '4366'), -- 31030 - 4366 - 4366 0xF130793600719D5A +(@CGUID+4, 26882, 0x3000000, 0x1, '4366'), -- 31030 - 4366 - 4366 0xF130793600719D5B +(@CGUID+5, 26882, 0x3000000, 0x1, '4366'); -- 31030 - 4366 - 4366 0xF130793600719D5C + +DELETE FROM `creature_template_addon` WHERE `entry` IN(31016,31083,31029,31050); +INSERT INTO `creature_template_addon` (`entry`, `mount`, `bytes1`, `bytes2`, `auras`) VALUES +(31016, 0, 0x0, 0x1, '61081'), -- 31016 - 61081 +(31083, 0, 0x0, 0x1, '34427'), -- 31083 - 34427 +(31029, 0, 0x3000000, 0x1, '58102'), -- 31029 - 58102 +(31050, 0, 0x3000000, 0x1, ''); -- 31050 - 4366 + +DELETE FROM `event_scripts` WHERE `id`=20108; +INSERT INTO `event_scripts` (`id`,`delay`,`command`,`datalong`,`datalong2`,`dataint`,`x`,`y`,`z`,`o`) VALUES +(20108,0,10,31029,1800000,0,7116.824,4308.362,883.3842,2.46227), -- Possessed Vardmadra 0xF130793500719D55 +(20108,0,16,14969,0,0,0,0,0,0); + +UPDATE `gameobject_template` SET `AIName`='SmartGameObjectAI' WHERE `entry`=193028; +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`IN(31016,31029,31030,31050,31083,31087,31077); +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`IN(31016,31029,31030,31050,31083,31087,31077); +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid` BETWEEN -@CGUID-5 AND -@CGUID-0; +DELETE FROM `smart_scripts` WHERE `source_type`=9 AND `entryorguid`IN(3105000,3105001,3101600,3108300,3108301,19302800); +DELETE FROM `smart_scripts` WHERE `source_type`=1 AND `entryorguid`IN(193028); + +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(31077, 0, 0, 0, 8, 0, 100, 0, 4020, 0, 0, 0, 11, 4307, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrangs Chill target - On Spell Hit Safirdrangs Chill - Cast Safirdrangs Chill'), +(31077, 0, 1, 2, 25, 0, 100, 0, 0, 0, 0, 0, 19, 256, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrangs Chill target - On Reset - Set Unit Flags'), +(31077, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 2, 14, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrangs Chill target - On Reset - Set Faction'), +(193028, 1, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 32, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'War Horn of Jotunheim - On Data Set - Reset Go'), +(31083, 0, 0, 0, 54, 0, 100, 0, 0, 0, 0, 0, 80, 3108300, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - On Just Summoned Run Script'), +(31083, 0, 1, 0, 38, 0, 100, 0, 1, 1, 0, 0, 53, 0, 3108300, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - On Data Set - Start WP (Path 2)'), +(31083, 0, 2, 0, 40, 0, 100, 0, 1, 3108300, 0, 0, 80, 3108301, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - On Reached WP1 (Path 2) - Run Script 2'), +(31083, 0, 3, 0, 40, 0, 100, 0, 4, 31083, 0, 0, 66, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 4.468043, 'The Lich King - On Reached WP4 (Path 1) - Set Orientation'), +(31083, 0, 4, 5, 40, 0, 100, 0, 2, 31083, 0, 0, 54, 35600, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - On Reached WP2 (Path 1) - Set Pause WP'), +(31083, 0, 5, 0, 61, 0, 100, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'The Lich King - On Reached WP2 (Path 1) - Face Possessed Vardmadra'), +(3108300, 9, 0, 0, 0, 0, 100, 0, 1000, 1000, 0, 0, 11, 34427, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Cast Ethereal Teleport'), +(3108300, 9, 1, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 45, 3, 3, 0, 0, 0, 0, 10, @CGUID+0, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script - Despawn Balargarde Elite'), +(3108300, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 3, 3, 0, 0, 0, 0, 10, @CGUID+1, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script - Despawn Balargarde Elite'), +(3108300, 9, 3, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 3, 3, 0, 0, 0, 0, 10, @CGUID+2, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script - Despawn Balargarde Elite'), +(3108300, 9, 4, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 3, 3, 0, 0, 0, 0, 10, @CGUID+3, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script - Despawn Balargarde Elite'), +(3108300, 9, 5, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 3, 3, 0, 0, 0, 0, 10, @CGUID+4, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script - Despawn Balargarde Elite'), +(3108300, 9, 6, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 3, 3, 0, 0, 0, 0, 10, @CGUID+5, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script - Despawn Balargarde Elite'), +(3108300, 9, 7, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 53274, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Cast Icebound Visage'), +(3108300, 9, 8, 0, 0, 0, 100, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Face Possessed Vardmadra'), +(3108300, 9, 9, 0, 0, 0, 100, 0, 4000, 4000, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Say Line 0 '), +(3108300, 9, 10, 0, 0, 0, 100, 0, 4000, 4000, 0, 0, 45, 3, 3, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Set Data on Possessed Vardmadra'), +(3108300, 9, 11, 0, 0, 0, 100, 0, 2000, 2000, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Say Line 1 '), +(3108300, 9, 12, 0, 0, 0, 100, 0, 0, 0, 0, 0, 53, 0, 31083, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Start WP '), +(3108300, 9, 13, 0, 0, 0, 100, 0, 9000, 9000, 0, 0, 1, 2, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Say Line 2 on Possessed Vardmadra '), +(3108300, 9, 14, 0, 0, 0, 100, 0, 4000, 4000, 0, 0, 1, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Say Line 2 '), +(3108300, 9, 15, 0, 0, 0, 100, 0, 9000, 9000, 0, 0, 11, 42904, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Cast Cosmetic - Combat Special Attack 2H (Whirlwind SFX) '), +(3108300, 9, 16, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Set Data on Possessed Vardmadra '), +(3108300, 9, 17, 0, 0, 0, 100, 0, 600, 600, 0, 0, 45, 5, 5, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Set Data on Possessed Vardmadra '), +(3108300, 9, 18, 0, 0, 0, 100, 0, 4000, 4000, 0, 0, 4, 15714, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Play sound 15714'), +(3108300, 9, 19, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 1, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Say Line 3 '), +(3108300, 9, 20, 0, 0, 0, 100, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 19, 31016, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Face Overthane Balargarde <Master of Jotunheim>'), +(3108300, 9, 21, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 1, 6, 0, 0, 0, 0, 0, 19, 31016, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Say Line 6 on Overthane Balargarde <Master of Jotunheim> '), +(3108300, 9, 22, 0, 0, 0, 100, 0, 4000, 4000, 0, 0, 1, 4, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Say Line 4 '), +(3108300, 9, 23, 0, 0, 0, 100, 0, 7000, 7000, 0, 0, 1, 7, 0, 0, 0, 0, 0, 19, 31016, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Say Line 7 on Overthane Balargarde <Master of Jotunheim> '), +(3108300, 9, 24, 0, 0, 0, 100, 0, 1000, 1000, 0, 0, 45, 3, 3, 0, 0, 0, 0, 19, 31016, 0, 0, 0, 0, 0, 0, 'The Lich King - Script - Set Data on Overthane Balargarde <Master of Jotunheim> '), +(3108301, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 4, 4, 0, 0, 0, 0, 19, 31050, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Set Data on Safirdrang '), +(3108301, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 21, 100, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Face Player'), +(3108301, 9, 2, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 1, 5, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Say Line 5'), +(3108301, 9, 3, 0, 0, 0, 100, 0, 8000, 8000, 0, 0, 1, 6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Say Line 6'), +(3108301, 9, 4, 0, 0, 0, 100, 0, 8000, 8000, 0, 0, 11, 34427, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Cast Ethereal Teleport'), +(3108301, 9, 5, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+0, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Despawn Balargarde Elite'), +(3108301, 9, 6, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+1, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Despawn Balargarde Elite'), +(3108301, 9, 7, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+2, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Despawn Balargarde Elite'), +(3108301, 9, 8, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+3, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Despawn Balargarde Elite'), +(3108301, 9, 9, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+4, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Despawn Balargarde Elite'), +(3108301, 9, 10, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+5, 31030, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Despawn Balargarde Elite'), +(3108301, 9, 11, 0, 0, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 19, 31050, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Despawn Safirdrang'), +(3108301, 9, 12, 0, 0, 0, 100, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 19, 31087, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Despawn Lady Nightswood'), +(3108301, 9, 13, 0, 0, 0, 100, 0, 0, 0, 0, 0, 41, 1000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'The Lich King - Script 2 - Despawn'), +(31087, 0, 0, 0, 1, 0, 100, 1, 20000, 20000, 0, 0, 53, 1, 31087, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lady Nightswood - OOC (No repeat) - Start WP'), +(31087, 0, 1, 0, 40, 0, 100, 0, 3, 31087, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Lady Nightswood - On Reached WP3 - Despawn'), +(31087, 0, 2, 0, 54, 0, 100, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 19, 31083, 0, 0, 0, 0, 0, 0, 'Lady Nightswood - On Just Summoned - Face The Lich King'), +(31016, 0, 1, 2, 38, 0, 100, 0, 1, 1, 0, 0, 19, 256, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Data Set - Remove Flags Immune to PC'), +(31016, 0, 2, 3, 61, 0, 100, 0, 1, 1, 0, 0, 101, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Data Set - Set Home Position'), +(31016, 0, 3, 0, 61, 0, 100, 0, 1, 1, 0, 0, 49, 0, 0, 0, 0, 0, 0, 21, 100, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Data Set - Start Attack'), +(31016, 0, 4, 18, 4, 0, 100, 0, 0, 0, 0, 0, 42, 0, 49, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Agro - Set Invincibility HP'), +(31016, 0, 5, 6, 7, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 19, 31050, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Evade - Set Data Safirdrang'), +(31016, 0, 6, 7, 61, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+0, 31030, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Evade - Set Data Balargarde Elite'), +(31016, 0, 7, 8, 61, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+1, 31030, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Evade - Set Data Balargarde Elite'), +(31016, 0, 8, 9, 61, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+2, 31030, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Evade - Set Data Balargarde Elite'), +(31016, 0, 9, 10, 61, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+3, 31030, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Evade - Set Data Balargarde Elite'), +(31016, 0, 10, 11, 61, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+4, 31030, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Evade - Set Data Balargarde Elite'), +(31016, 0, 11, 12, 61, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, @CGUID+5, 31030, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Evade - Set Data Balargarde Elite'), +(31016, 0, 12, 22, 61, 0, 100, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - Evade - Despawn'), +(31016, 0, 13, 0, 38, 0, 100, 0, 2, 2, 0, 0, 28, 4366, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Data Set - Set Visible'), +(31016,0,14,0,0,3,100,0,20000,30000,25000,32000,11,60108,0,0,0,0,0,5,0,0,0,0,0,0,0,"Overthane Balargarde - In Combat (Phase 1 & 2) - Cast 'Heroic Leap'"), +(31016,0,15,0,9,3,100,0,0,5,60000,90000,11,61076,0,0,0,0,0,1,0,0,0,0,0,0,0,"Overthane Balargarde - On Range (Phase 1 & 2) - Cast 'Whirlwind'"), +(31016,0,16,0,0,3,100,0,20000,25000,25000,30000,11,15043,0,0,0,0,0,2,0,0,0,0,0,0,0,"Overthane Balargarde - In Combat (Phase 1 & 2) - Cast 'Frostbolt'"), +(31016,0,17,0,0,3,100,0,15000,25000,25000,35000,11,61085,0,0,0,0,0,5,0,0,0,0,0,0,0,"Overthane Balargarde - In Combat (Phase 1 & 2) - Cast 'Blizzard'"), +(31016, 0, 18, 0, 61, 0, 100, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Agro - Set Phase 1'), +(31016, 0, 19, 20, 2, 0, 100, 1, 0, 80, 0, 0, 1, 4, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - At 80% HP - Say Line 4'), +(31016, 0, 20, 0, 61, 0, 100, 0, 0, 0, 0, 0, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - At 80% HP - Set Phase 2'), +(31016, 0, 21, 0, 2, 0, 100, 1, 0, 50, 0, 0, 80, 3101600, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - At 50% HP - Run Script'), +(31016, 0, 22, 28, 61, 0, 100, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 19, 31083, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Agro - Set Phase 1'), +(31016, 0, 23, 24, 38, 0, 100, 0, 3, 3, 0, 0, 20, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Data Set - Enable Attack'), +(31016, 0, 24, 25, 61, 0, 100, 0, 0, 0, 0, 0, 21, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Data Set - Enable Comabt Movement'), +(31016, 0, 25, 26, 61, 0, 100, 0, 0, 0, 0, 0, 42, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Data Set - Turn Invincebility HP Off'), +(31016, 0, 26, 33, 61, 0, 100, 0, 0, 0, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Data Set - Set Phase 1'), +(31016, 0, 27, 29, 6, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 31083, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Death - Set Data on the Lich King'), +(31016, 0, 28, 29, 61, 0, 100, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 19, 31087, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Agro - Set Phase 1'), +(31016, 0, 29, 32, 61, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 14, 62011, 193028, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - Link - Set Data on War Horn of Jotunheim'), +(31016,0,31,0,0,2,100,0,3000,5000,13000,14000,45,3,3,0,0,0,0,19,31050,0,0,0,0,0,0,"Overthane Balargarde - In Combat (Phase 2) - Set Data on Safirdrang"), +(31016, 0, 32, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - On Agro - Set Phase 1'), +(31016, 0, 33, 0, 61, 0, 100, 0, 0, 0, 0, 0, 91, 8, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - Script - Remove Bytes 1'), +(31016, 0, 34, 0, 0, 4, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31083, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - IC (Phase 3) - Face the Lich King'), +(3101600, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 22, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - Script - Set Phase 3'), +(3101600, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - Script - Stop Attack'), +(3101600, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 21, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - Script - Disable Combat Movement'), +(3101600, 9, 3, 0, 0, 0, 100, 0, 0, 0, 0, 0, 1, 5, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - Script - Say Line 5'), +(3101600, 9, 4, 0, 0, 0, 100, 0, 0, 0, 0, 0, 12, 31083, 8, 0, 0, 0, 0, 8, 0, 0, 0, 7088.768, 4385.59, 872.4484, 4.468043, 'Overthane Balargarde <Master of Jotunheim> - Script - Summon The Lich King'), +(3101600, 9, 5, 0, 0, 0, 100, 0, 0, 0, 0, 0, 18, 33554432, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - Script - Add Unit Flags UNIT_FLAG_NOT_SELECTABLE'), +(3101600, 9, 6, 0, 0, 0, 100, 0, 0, 0, 0, 0, 90, 8, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - Script - Set Bytes 1'), +(3101600, 9, 7, 0, 0, 0, 100, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 19, 31083, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - Script - Face the Lich King'), +(3101600, 9, 8, 0, 0, 0, 100, 0, 100, 100, 0, 0, 19, 33554432, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overthane Balargarde <Master of Jotunheim> - Script - Remove Unit Flags UNIT_FLAG_NOT_SELECTABLE'), +(31029, 0, 0, 0, 54, 0, 100, 0, 0, 0, 0, 0, 53, 1, 31029, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Just Summoned - Start WP'), +(31029, 0, 1, 2, 40, 0, 100, 0, 4, 31029, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+0, 31030, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Reached WP4 - Set Data Balargarde Elite'), +(31029, 0, 2, 3, 61, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+1, 31030, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Reached WP4 - Set Data Balargarde Elite'), +(31029, 0, 3, 4, 61, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+2, 31030, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Reached WP4 - Set Data Balargarde Elite'), +(31029, 0, 4, 5, 61, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+3, 31030, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Reached WP4 - Set Data Balargarde Elite'), +(31029, 0, 5, 6, 61, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+4, 31030, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Reached WP4 - Set Data Balargarde Elite'), +(31029, 0, 6, 7, 61, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, @CGUID+5, 31030, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Reached WP4 - Set Data Balargarde Elite'), +(31029, 0, 7, 8, 61, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 19, 31016, 0, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Just Summoned - Set Data Balargarde Elite'), +(31029, 0, 8, 0, 61, 0, 100, 0, 0, 0, 0, 0, 12, 31050, 8, 0, 0, 0, 0, 8, 0, 0, 0, 7097.292,4416.581,831.8486,4.485496, 'Possessed Vardmadra - On Data Set - Start WP Path 2'), +(31029, 0, 9, 10, 38, 0, 100, 0, 1, 1, 0, 0, 11, 58359, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Data Set - Cast Banshees Revenge: Summon Lady Nightswood'), +(31029, 0, 10, 16, 61, 0, 100, 0, 0, 0, 0, 0, 11, 51744, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Data Set - Cast Suicide (No Log)'), +(31029, 0, 12, 13, 38, 0, 100, 0, 3, 3, 0, 0, 90, 8, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Data Set - Set Bytes 1'), +(31029, 0, 13, 14, 61, 0, 100, 0, 0, 0, 0, 0, 53, 1, 3102900, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Data Set - Start WP (Path 2)'), +(31029, 0, 14, 0, 61, 0, 100, 0, 0, 0, 0, 0, 60, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Data Set - Turn Fly Off'), +(31029, 0, 15, 0, 40, 0, 100, 0, 4, 31029, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Reached WP4 - Say Line 0'), +(31029, 0, 16, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 15000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Data Set - Despawn after 15 seconds'), +(31029, 0, 17, 0, 38, 0, 100, 0, 5, 5, 0, 0, 1, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Possessed Vardmadra - On Data Set - Say Line 3'), +(31050, 0, 0, 3, 54, 0, 100, 0, 0, 0, 0, 0, 53, 1, 31050, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrang - On Data Set - Start WP'), +(31050, 0, 1, 0, 40, 0, 100, 0, 6, 31050, 0, 0, 80, 3105000, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrang - On Reached WP6 - Run Script'), +(31050, 0, 2, 0, 38, 0, 100, 0, 2, 2, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrang - On Data Set - Despawn'), +(31050, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 28, 4366, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrang - On Data Set - Set Visible'), +(31050, 0, 4, 0, 38, 0, 100, 0, 3, 3, 0, 0, 80, 3105001, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrang - On Data Set - Run Script'), +(31050, 0, 5, 0, 38, 0, 100, 0, 4, 4, 0, 0, 53, 1, 3105000, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrang - On Data Set - Start WP (Path 2)'), +(31050, 0, 6, 0, 40, 0, 100, 0, 4, 3105000, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrang - On Reached WP4 (Path 2) - Despawn'), +(3105001, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 66, 0, 0, 0, 0, 0, 0, 21, 100, 0, 0, 0, 0, 0, 0, 'Safirdrang - Script 2 - Face Player'), +(3105001, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 4020, 0, 0, 0, 0, 0, 21, 100, 0, 0, 0, 0, 0, 0, 'Safirdrang - Script 2 - Cast Safirdrangs Chill'), +(3105001, 9, 2, 0, 0, 0, 100, 0, 2000, 2000, 0, 0, 66, 0, 0, 0, 0, 0, 0, 21, 100, 0, 0, 0, 0, 0, 0, 'Safirdrang - Script 2 - Face Player'), +(3105000, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 19, 31016, 0, 0, 0, 0, 0, 0, 'Safirdrang - Script - Say Line 1 on Overthane Balargarde'), -- 20:05:22.766 +(3105000, 9, 1, 0, 0, 0, 100, 0, 6000, 6000, 0, 0, 1, 1, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'Safirdrang - Script - Say Line 1 on Possessed Vardmadra'), -- 20:05:28.375 +(3105000, 9, 2, 0, 0, 0, 100, 0, 6000, 6000, 0, 0, 1, 2, 0, 0, 0, 0, 0, 19, 31016, 0, 0, 0, 0, 0, 0, 'Safirdrang - Script - Say Line 2 on Overthane Balargarde'), -- 20:05:34.422 +(3105000, 9, 3, 0, 0, 0, 100, 0, 6000, 6000, 0, 0, 1, 3, 0, 0, 0, 0, 0, 19, 31016, 0, 0, 0, 0, 0, 0, 'Safirdrang - Script - Say Line 3 on Overthane Balargarde'), -- 20:05:40.828 +(3105000, 9, 4, 0, 0, 0, 100, 0, 0, 0, 0, 0, 28, 46598, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrang - Script - Eject Overthane Balargarde'), -- 20:05:22.766 +(3105000, 9, 5, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 45, 1, 1, 0, 0, 0, 0, 19, 31016, 0, 0, 0, 0, 0, 0, 'Safirdrang - Script - Eject Overthane Balargarde'), -- 20:05:22.766 +(3105000, 9, 6, 0, 0, 0, 100, 0, 0, 0, 0, 0, 101, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Safirdrang - Script - Set Home Position'), -- 20:05:22.766 +(-@CGUID-0, 0, 0, 3, 38, 0, 100, 0, 1, 1, 0, 0, 53, 1, 3103001, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Start WP'), +(-@CGUID-1, 0, 0, 3, 38, 0, 100, 0, 1, 1, 0, 0, 53, 1, 3103002, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Start WP'), +(-@CGUID-2, 0, 0, 3, 38, 0, 100, 0, 1, 1, 0, 0, 53, 1, 3103003, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Start WP'), +(-@CGUID-3, 0, 0, 3, 38, 0, 100, 0, 1, 1, 0, 0, 53, 1, 3103004, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Start WP'), +(-@CGUID-4, 0, 0, 3, 38, 0, 100, 0, 1, 1, 0, 0, 53, 1, 3103005, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Start WP'), +(-@CGUID-5, 0, 0, 3, 38, 0, 100, 0, 1, 1, 0, 0, 53, 1, 3103006, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Start WP'), +(-@CGUID-0, 0, 1, 0, 40, 0, 100, 0, 5, 3103001, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Reached WP5 - Set Phase 1'), +(-@CGUID-1, 0, 1, 0, 40, 0, 100, 0, 5, 3103002, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Reached WP5 - Set Phase 1'), +(-@CGUID-2, 0, 1, 0, 40, 0, 100, 0, 5, 3103003, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Reached WP5 - Set Phase 1'), +(-@CGUID-3, 0, 1, 0, 40, 0, 100, 0, 6, 3103004, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Reached WP6 - Set Phase 1'), +(-@CGUID-4, 0, 1, 0, 40, 0, 100, 0, 5, 3103005, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Reached WP5 - Set Phase 1'), +(-@CGUID-5, 0, 1, 0, 40, 0, 100, 0, 8, 3103006, 0, 0, 22, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Reached WP8 - Set Phase 1'), +(-@CGUID-0, 0, 2, 0, 38, 0, 100, 0, 2, 2, 0, 0, 24, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Evade'), +(-@CGUID-1, 0, 2, 0, 38, 0, 100, 0, 2, 2, 0, 0, 24, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Evade'), +(-@CGUID-2, 0, 2, 0, 38, 0, 100, 0, 2, 2, 0, 0, 24, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Evade'), +(-@CGUID-3, 0, 2, 0, 38, 0, 100, 0, 2, 2, 0, 0, 24, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Evade'), +(-@CGUID-4, 0, 2, 0, 38, 0, 100, 0, 2, 2, 0, 0, 24, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Evade'), +(-@CGUID-5, 0, 2, 0, 38, 0, 100, 0, 2, 2, 0, 0, 24, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Evade'), +(-@CGUID-0, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 28, 4366, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Remove Aura'), +(-@CGUID-1, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 28, 4366, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Remove Aura'), +(-@CGUID-2, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 28, 4366, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Remove Aura'), +(-@CGUID-3, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 28, 4366, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Remove Aura'), +(-@CGUID-4, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 28, 4366, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Remove Aura'), +(-@CGUID-5, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 28, 4366, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Remove Aura'), +(-@CGUID-0, 0, 4, 0, 38, 0, 100, 0, 3, 3, 0, 0, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Set Phase 2'), +(-@CGUID-1, 0, 4, 0, 38, 0, 100, 0, 3, 3, 0, 0, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Set Phase 2'), +(-@CGUID-2, 0, 4, 0, 38, 0, 100, 0, 3, 3, 0, 0, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Set Phase 2'), +(-@CGUID-3, 0, 4, 0, 38, 0, 100, 0, 3, 3, 0, 0, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Set Phase 2'), +(-@CGUID-4, 0, 4, 0, 38, 0, 100, 0, 3, 3, 0, 0, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Set Phase 2'), +(-@CGUID-5, 0, 4, 0, 38, 0, 100, 0, 3, 3, 0, 0, 22, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - On Data Set - Set Phase 2'), +(-@CGUID-0, 0, 5, 0, 1, 1, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 1) - Face Possessed Vardmadra'), +(-@CGUID-1, 0, 5, 0, 1, 1, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 1) - Face Possessed Vardmadra'), +(-@CGUID-2, 0, 5, 0, 1, 1, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 1) - Face Possessed Vardmadra'), +(-@CGUID-3, 0, 5, 0, 1, 1, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 1) - Face Possessed Vardmadra'), +(-@CGUID-4, 0, 5, 0, 1, 1, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 1) - Face Possessed Vardmadra'), +(-@CGUID-5, 0, 5, 0, 1, 1, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31029, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 1) - Face Possessed Vardmadra'), +(-@CGUID-0, 0, 6, 0, 1, 2, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31083, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 2) - Face The Lich King'), +(-@CGUID-1, 0, 6, 0, 1, 2, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31083, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 2) - Face The Lich King'), +(-@CGUID-2, 0, 6, 0, 1, 2, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31083, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 2) - Face The Lich King'), +(-@CGUID-3, 0, 6, 0, 1, 2, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31083, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 2) - Face The Lich King'), +(-@CGUID-4, 0, 6, 0, 1, 2, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31083, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 2) - Face The Lich King'), +(-@CGUID-5, 0, 6, 0, 1, 2, 100, 0, 1000, 1000, 1000, 1000, 66, 0, 0, 0, 0, 0, 0, 19, 31083, 0, 0, 0, 0, 0, 0, 'Balargarde Elite - OOC (Phase 2) - Face The Lich King'); + +-- Texts +DELETE FROM `creature_text` WHERE `entry` IN(31016,31029,31083); +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `BroadcastTextID`, `comment`) VALUES +(31016, 1, 0, 'You dare to challenge me? You haven''t earned the right!', 14, 0, 100, 25, 0, 15633, 31597, 'Overthane Balargarde to Safirdrang'), +(31016, 2, 0, 'Vardmadra?! Did the Lich King send you personally?', 14, 0, 100, 66, 0, 15634, 31599, 'Overthane Balargarde to Possessed Vardmadra'), +(31016, 3, 0, 'Very well. I will dispatch these creatures. It is only an inconvenience. Prepare to die!', 14, 0, 100, 0, 0, 15635, 31600, 'Overthane Balargarde to Possessed Vardmadra'), +(31016, 4, 0, 'Safirdrang, let them feel the chill of Icecrown!', 14, 0, 100, 0, 0, 15636, 31601, 'Overthane Balargarde to 0'), +(31016, 5, 0, 'STOP! Kneel you fools, it''s the Lich King!', 14, 0, 100, 0, 0, 15637, 31627, 'Overthane Balargarde to The Lich King'), +(31016, 6, 0, 'But, my lord...?', 14, 0, 100, 0, 0, 15638, 31635, 'Overthane Balargarde to The Lich King'), +(31016, 7, 0, 'DIE DOGS!', 14, 0, 100, 0, 0, 15639, 31637, 'Overthane Balargarde to The Lich King'), +(31029, 0, 0, 'He''s on his way!', 14, 0, 100, 457, 0, 15643, 31595, 'Possessed Vardmadra to Player'), +(31029, 1, 0, 'Wrong, Balargarde. You WILL accept this challenge!', 14, 0, 100, 457, 0, 15644, 31598, 'Possessed Vardmadra to Overthane Balargarde'), +(31029, 2, 0, 'My lord.', 14, 0, 100, 457, 0, 15645, 31631, 'Possessed Vardmadra to The Lich King'), +(31029, 3, 0, 'But...!', 14, 0, 100, 0, 0, 15646, 31633, 'Possessed Vardmadra to The Lich King'), +(31083, 0, 0, 'Honor guard stay where you are.', 14, 0, 100, 1, 0, 15600, 31628, 'The Lich King to 0'), +(31083, 1, 0, 'Vardmadra. I''d wondered where you disappeared to. How is Iskalder?', 14, 0, 100, 6, 0, 15601, 31629, 'The Lich King to 0'), +(31083, 2, 0, 'I see through your disguise, Lady Nightswood. YOU THINK THAT YOU CAN FOOL ME?!', 14, 0, 100, 5, 0, 15602, 31632, 'The Lich King to 0'), +(31083, 3, 0, 'You may continue your combat, overthane.', 14, 0, 100, 25, 0, 15603, 31634, 'The Lich King to 0'), +(31083, 4, 0, 'But nothing! Finish them! DO NOT FAIL ME, BALARGARDE!', 14, 0, 100, 5, 0, 15604, 31636, 'The Lich King to Overthane Balargarde'), +(31083, 5, 0, 'You have bested one of my finest, but your efforts are for naught.', 14, 0, 100, 1, 0, 15605, 31693, 'The Lich King to 0'), +(31083, 6, 0, 'The frozen heart of Icecrown awaits....', 14, 0, 100, 1, 0, 15606, 31695, 'The Lich King to 0'); + +-- Waypoints +DELETE FROM `waypoints` WHERE `entry` IN(31029,31050,3103001,3103002,3103003,3103004,3103005,3103006,31087,3105000,31083,3108300,3102900); +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES +(31029, 1, 7119.714 , 4305.82 , 883.7371, 'Possessed Vardmadra'), +(31029, 2, 7119.045 , 4306.563 , 883.7371, 'Possessed Vardmadra'), +(31029, 3, 7094.592 , 4326.246 , 879.7935, 'Possessed Vardmadra'), +(31029, 4, 7094.592 , 4326.246 , 879.7935, 'Possessed Vardmadra'), +(3102900, 1, 7094.592, 4326.246, 871.4232, 'Possessed Vardmadra (Path 2)'), +(31087, 1, 7079.599, 4301.017, 874.3533, 'Lady Nightswood'), +(31087, 2, 7082.374, 4283.685, 878.2528, 'Lady Nightswood'), +(31087, 3, 7093.269, 4251.247, 855.1418, 'Lady Nightswood'), +(31050, 1, 7097.518 ,4417.555 ,831.8486, 'Safirdrang'), +(31050, 2, 7097.292 ,4416.581 ,831.8486, 'Safirdrang'), +(31050, 3, 7097.876 ,4416.293 ,832.2352, 'Safirdrang'), +(31050, 4, 7096.67 ,4412.85 ,892.0963, 'Safirdrang'), +(31050, 5, 7083.72 ,4365.534 ,886.1511, 'Safirdrang'), +(31050, 6, 7083.72 ,4365.534 ,886.1511, 'Safirdrang'), +(3105000, 1, 7053.937, 4377.317, 901.5513, 'Safirdrang (Path 2)'), +(3105000, 2, 7020.913, 4415.733, 938.7733, 'Safirdrang (Path 2)'), +(3105000, 3, 7014.491, 4475.228, 933.1346, 'Safirdrang (Path 2)'), +(3105000, 4, 7053.163, 4507.731, 899.1902, 'Safirdrang (Path 2)'), +(3103001, 1, 7108.212 ,4429.457 ,837.8948, 'Balargarde Elite Path 1'), +(3103001, 2, 7108.282 ,4428.459 ,837.8948, 'Balargarde Elite Path 1'), +(3103001, 3, 7106.677 ,4418.644 ,890.2556, 'Balargarde Elite Path 1'), +(3103001, 4, 7105.132 ,4316.933 ,890.2556, 'Balargarde Elite Path 1'), +(3103001, 5, 7105.132 ,4316.933 ,890.2556, 'Balargarde Elite Path 1'), +(3103002, 1, 7092.335 ,4432.937 ,836.562, 'Balargarde Elite Path 2'), +(3103002, 2, 7092.213 ,4431.944 ,836.562, 'Balargarde Elite Path 2'), +(3103002, 3, 7088.707 ,4422.627 ,890.4507, 'Balargarde Elite Path 2'), +(3103002, 4, 7042.402 ,4334.195 ,890.4507, 'Balargarde Elite Path 2'), +(3103002, 5, 7042.402 ,4334.195 ,890.4507, 'Balargarde Elite Path 2'), +(3103003, 1, 7118.292 ,4433.163 ,837.6826, 'Balargarde Elite Path 3'), +(3103003, 2, 7118.448 ,4432.175 ,837.6826, 'Balargarde Elite Path 3'), +(3103003, 3, 7118.339 ,4415.652 ,891.2397, 'Balargarde Elite Path 3'), +(3103003, 4, 7116.423 ,4360.689 ,891.2397, 'Balargarde Elite Path 3'), +(3103003, 5, 7116.423 ,4360.689 ,891.2397, 'Balargarde Elite Path 3'), +(3103004, 1, 7084.022 ,4439.456 ,834.9834, 'Balargarde Elite Path 4'), +(3103004, 2, 7083.883 ,4438.466 ,834.9834, 'Balargarde Elite Path 4'), +(3103004, 3, 7084.125 ,4439.286 ,835.0841, 'Balargarde Elite Path 4'), +(3103004, 4, 7078.116 ,4422.103 ,891.0005, 'Balargarde Elite Path 4'), +(3103004, 5, 7052.648 ,4376.112 ,891.0005, 'Balargarde Elite Path 4'), +(3103004, 6, 7052.648 ,4376.112 ,891.0005, 'Balargarde Elite Path 4'), +(3103005, 1, 7111.17 ,4446.118 ,838.3093, 'Balargarde Elite Path 5'), +(3103005, 2, 7111.292 ,4445.125 ,838.3093, 'Balargarde Elite Path 5'), +(3103005, 3, 7097.193 ,4415.753 ,886.4199, 'Balargarde Elite Path 5'), +(3103005, 4, 7091.205 ,4393.473 ,886.4199, 'Balargarde Elite Path 5'), +(3103005, 5, 7091.205 ,4393.473 ,886.4199, 'Balargarde Elite Path 5'), +(3103006, 1, 7095.478 ,4449.356 ,836.9002, 'Balargarde Elite Path 6'), +(3103006, 2, 7095.443 ,4448.357 ,836.9002, 'Balargarde Elite Path 6'), +(3103006, 3, 7052.521 ,4434.108 ,838.8722, 'Balargarde Elite Path 6'), +(3103006, 4, 7003.175 ,4398.929 ,844.0392, 'Balargarde Elite Path 6'), +(3103006, 5, 6988.518 ,4335.11 ,856.9001, 'Balargarde Elite Path 6'), +(3103006, 6, 7018.119 ,4279.629 ,875.7885, 'Balargarde Elite Path 6'), +(3103006, 7, 7067.475 ,4300.513 ,892.5076, 'Balargarde Elite Path 6'), +(3103006, 8, 7067.475 ,4300.513 ,892.5076, 'Balargarde Elite Path 6'), +(31083, 1, 7092.936, 4343.906, 871.9753, 'The Lich King'), +(31083, 2, 7094.104, 4331.222, 871.5023, 'The Lich King'), +(31083, 3, 7092.936, 4343.906, 871.9331, 'The Lich King'), +(31083, 4, 7088.768, 4385.59, 872.3639, 'The Lich King'), +(3108300, 1, 7091.374, 4344.362, 871.9679, 'The Lich King Path 2'); diff --git a/sql/updates/world/2016_01_30_03_world.sql b/sql/updates/world/2016_01_30_03_world.sql new file mode 100644 index 00000000000..06c4b0826c0 --- /dev/null +++ b/sql/updates/world/2016_01_30_03_world.sql @@ -0,0 +1,136 @@ +-- Pathing for Bloodcursed Naga Entry: 17713 'TDB FORMAT' +SET @NPC := 63485; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-1928.789,`position_y`=-12869.43,`position_z`=86.3521 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-1928.789,-12869.43,86.3521,0,0,0,0,100,0), -- 09:15:24 +(@PATH,2,-1926.808,-12868.42,86.50182,0,0,0,0,100,0), -- 09:15:32 +(@PATH,3,-1915.362,-12863.29,87.48274,0,0,0,0,100,0), -- 09:15:37 +(@PATH,4,-1895.262,-12862.47,87.17763,0,0,0,0,100,0), -- 09:15:44 +(@PATH,5,-1888.151,-12870.06,85.72816,0,0,0,0,100,0), -- 09:15:50 +(@PATH,6,-1881.628,-12885.19,81.05202,0,0,0,0,100,0), -- 09:15:58 +(@PATH,7,-1882.931,-12895.07,76.1616,0,0,0,0,100,0), -- 09:16:03 +(@PATH,8,-1896.266,-12915.07,69.35283,0,0,0,0,100,0), -- 09:16:13 +(@PATH,9,-1908.279,-12924.68,66.72368,0,0,0,0,100,0), -- 09:16:19 +(@PATH,10,-1933.388,-12933.09,64.4604,0,0,0,0,100,0), -- 09:16:28 +(@PATH,11,-1947.921,-12933.25,61.58389,0,0,0,0,100,0), -- 09:16:36 +(@PATH,12,-1964.046,-12931.37,54.13368,0,0,0,0,100,0), -- 09:16:45 +(@PATH,13,-1985.971,-12921.06,46.1943,0,0,0,0,100,0), -- 09:16:54 +(@PATH,14,-2008.113,-12899.47,43.04699,0,0,0,0,100,0), -- 09:17:06 +(@PATH,15,-2009.894,-12861.36,40.86951,0,0,0,0,100,0), -- 09:17:15 +(@PATH,16,-2002.674,-12851.02,38.75832,0,0,0,0,100,0), -- 09:17:26 +(@PATH,17,-1982.862,-12829.53,35.24951,0,0,0,0,100,0), -- 09:17:38 +(@PATH,18,-1963.942,-12804.68,29.6003,0,0,0,0,100,0), -- 09:17:50 +(@PATH,19,-1947.879,-12792.53,25.92624,0,0,0,0,100,0), -- 09:18:00 +(@PATH,20,-1936.599,-12789.01,24.07749,0,0,0,0,100,0), -- 09:18:06 +(@PATH,21,-1922.057,-12789.15,21.28288,0,0,0,0,100,0), -- 09:18:15 +(@PATH,22,-1919.057,-12789.16,20.79777,0,0,0,0,100,0), -- 09:18:16 +(@PATH,23,-1910.856,-12787.78,18.40594,0,0,0,0,100,0), -- 09:18:17 +(@PATH,24,-1865.516,-12783.02,8.171058,0,0,0,0,100,0), -- 09:18:33 +(@PATH,25,-1828.088,-12780.68,5.281821,0,0,0,0,100,0), -- 09:18:47 +(@PATH,26,-1821.925,-12778.83,4.372193,0,0,0,0,100,0), -- 09:18:55 +(@PATH,27,-1808.465,-12775.22,3.311753,0,0,0,0,100,0), -- 09:19:11 +(@PATH,28,-1840.72,-12785.45,6.14157,0,0,0,0,100,0), -- 09:19:26 +(@PATH,29,-1857.858,-12783.72,7.100934,0,0,0,0,100,0), -- 09:19:32 +(@PATH,30,-1882.401,-12782.23,10.96099,0,0,0,0,100,0), -- 09:19:47 +(@PATH,31,-1918.945,-12788.79,20.91866,0,0,0,0,100,0), -- 09:20:03 +(@PATH,32,-1946.804,-12792.22,25.9647,0,0,0,0,100,0), -- 09:20:12 +(@PATH,33,-1957.95,-12798.83,28.51275,0,0,0,0,100,0), -- 09:20:18 +(@PATH,34,-1972.832,-12814.32,31.96672,0,0,0,0,100,0), -- 09:20:28 +(@PATH,35,-1998.71,-12847.28,38.17815,0,0,0,0,100,0), -- 09:20:41 +(@PATH,36,-2010.876,-12865.39,41.37553,0,0,0,0,100,0), -- 09:20:52 +(@PATH,37,-2008.604,-12898.32,42.78571,0,0,0,0,100,0), -- 09:21:03 +(@PATH,38,-1999.134,-12909.23,44.42824,0,0,0,0,100,0), -- 09:21:12 +(@PATH,39,-1977.069,-12925.9,48.62286,0,0,0,0,100,0), -- 09:21:25 +(@PATH,40,-1960.811,-12931.79,56.09935,0,0,0,0,100,0), -- 09:21:34 +(@PATH,41,-1938.755,-12933.6,63.95058,0,0,0,0,100,0), -- 09:21:43 +(@PATH,42,-1901.555,-12919.94,68.1657,0,0,0,0,100,0), -- 09:21:59 +(@PATH,43,-1892.329,-12910.31,70.69868,0,0,0,0,100,0), -- 09:22:05 +(@PATH,44,-1881.857,-12893.26,77.24239,0,0,0,0,100,0), -- 09:22:15 +(@PATH,45,-1882.775,-12878.57,83.94725,0,0,0,0,100,0), -- 09:22:21 +(@PATH,46,-1903.748,-12860.37,87.55596,0,0,0,0,100,0), -- 09:22:30 +(@PATH,47,-1921.45,-12865.49,86.99675,0,0,0,0,100,0), -- 09:22:34 +(@PATH,48,-1928.858,-12869.55,86.33754,0,0,0,0,100,0); -- 09:22:43 +-- 0x1C09E44240114C4000002500002C696C .go -1928.789 -12869.43 86.3521 + +-- Pathing for Bloodcursed Naga Entry: 17713 'TDB FORMAT' +SET @NPC := 63492; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-1796.121,`position_y`=-12771.99,`position_z`=2.181608 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-1796.121,-12771.99,2.181608,0,0,0,0,100,0), -- 09:11:36 +(@PATH,2,-1808.465,-12775.22,3.311753,0,0,0,0,100,0), -- 09:11:53 +(@PATH,3,-1840.747,-12785.32,6.340456,0,0,0,0,100,0), -- 09:12:08 +(@PATH,4,-1857.898,-12783.8,7.071639,0,0,0,0,100,0), -- 09:12:14 +(@PATH,5,-1882.401,-12782.29,10.8823,0,0,0,0,100,0), -- 09:12:29 +(@PATH,6,-1921.118,-12788.98,21.68076,0,0,0,0,100,0), -- 09:12:45 +(@PATH,7,-1946.973,-12792.21,25.87914,0,0,0,0,100,0), -- 09:12:55 +(@PATH,8,-1957.784,-12798.69,28.39876,0,0,0,0,100,0), -- 09:13:01 +(@PATH,9,-1972.893,-12814.4,31.85242,0,0,0,0,100,0), -- 09:13:10 +(@PATH,10,-1998.871,-12847.28,38.12544,0,0,0,0,100,0), -- 09:13:23 +(@PATH,11,-2009.722,-12860.75,40.77156,0,0,0,0,100,0), -- 09:13:34 +(@PATH,12,-2008.599,-12898.46,42.77578,0,0,0,0,100,0), -- 09:13:46 +(@PATH,13,-1998.956,-12909.28,44.34562,0,0,0,0,100,0), -- 09:13:55 +(@PATH,14,-1977.231,-12926.03,48.51125,0,0,0,0,100,0), -- 09:14:07 +(@PATH,15,-1960.969,-12931.87,56.10593,0,0,0,0,100,0), -- 09:14:15 +(@PATH,16,-1938.779,-12933.54,63.8186,0,0,0,0,100,0), -- 09:14:25 +(@PATH,17,-1913.007,-12927.43,66.26051,0,0,0,0,100,0), -- 09:14:34 +(@PATH,18,-1898.97,-12917.32,68.56851,0,0,0,0,100,0), -- 09:14:42 +(@PATH,19,-1893.777,-12912.74,70.14345,0,0,0,0,100,0), -- 09:14:47 +(@PATH,20,-1881.76,-12893.25,77.15878,0,0,0,0,100,0), -- 09:14:57 +(@PATH,21,-1882.529,-12878.56,83.82611,0,0,0,0,100,0), -- 09:15:03 +(@PATH,22,-1903.836,-12860.37,87.51022,0,0,0,0,100,0), -- 09:15:11 +(@PATH,23,-1921.361,-12865.68,87.0482,0,0,0,0,100,0), -- 09:15:17 +(@PATH,24,-1928.789,-12869.43,86.3521,0,0,0,0,100,0), -- 09:15:24 +(@PATH,25,-1926.808,-12868.42,86.50182,0,0,0,0,100,0), -- 09:15:32 +(@PATH,26,-1915.362,-12863.29,87.48274,0,0,0,0,100,0), -- 09:15:37 +(@PATH,27,-1895.262,-12862.47,87.17763,0,0,0,0,100,0), -- 09:15:44 +(@PATH,28,-1888.151,-12870.06,85.72816,0,0,0,0,100,0), -- 09:15:50 +(@PATH,29,-1881.628,-12885.19,81.05202,0,0,0,0,100,0), -- 09:15:58 +(@PATH,30,-1882.931,-12895.07,76.1616,0,0,0,0,100,0), -- 09:16:03 +(@PATH,31,-1896.266,-12915.07,69.35283,0,0,0,0,100,0), -- 09:16:13 +(@PATH,32,-1908.279,-12924.68,66.72368,0,0,0,0,100,0), -- 09:16:19 +(@PATH,33,-1933.388,-12933.09,64.4604,0,0,0,0,100,0), -- 09:16:28 +(@PATH,34,-1947.921,-12933.25,61.58389,0,0,0,0,100,0), -- 09:16:36 +(@PATH,35,-1964.046,-12931.37,54.13368,0,0,0,0,100,0), -- 09:16:45 +(@PATH,36,-1985.971,-12921.06,46.1943,0,0,0,0,100,0), -- 09:16:54 +(@PATH,37,-2008.113,-12899.47,43.04699,0,0,0,0,100,0), -- 09:17:06 +(@PATH,38,-2009.894,-12861.36,40.86951,0,0,0,0,100,0), -- 09:17:15 +(@PATH,39,-2002.674,-12851.02,38.75832,0,0,0,0,100,0), -- 09:17:26 +(@PATH,40,-1982.862,-12829.53,35.24951,0,0,0,0,100,0), -- 09:17:38 +(@PATH,41,-1963.942,-12804.68,29.6003,0,0,0,0,100,0), -- 09:17:50 +(@PATH,42,-1947.879,-12792.53,25.92624,0,0,0,0,100,0), -- 09:18:00 +(@PATH,43,-1936.599,-12789.01,24.07749,0,0,0,0,100,0), -- 09:18:06 +(@PATH,44,-1922.057,-12789.15,21.28288,0,0,0,0,100,0), -- 09:18:15 +(@PATH,45,-1919.057,-12789.16,20.79777,0,0,0,0,100,0), -- 09:18:16 +(@PATH,46,-1910.856,-12787.78,18.40594,0,0,0,0,100,0), -- 09:18:17 +(@PATH,47,-1870.516,-12782.52,8.421058,0,0,0,0,100,0), -- 09:18:33 +(@PATH,48,-1828.088,-12780.68,5.281821,0,0,0,0,100,0), -- 09:18:47 +(@PATH,49,-1821.925,-12778.83,4.372193,0,0,0,0,100,0), -- 09:18:55 +(@PATH,50,-1808.465,-12775.22,3.311753,0,0,0,0,100,0); -- 09:19:11 +-- 0x1C09E44240114C4000002500002C696C .go -1796.121 -12771.99 2.181608 + +-- Bloodcursed Naga SAI +SET @ENTRY := 17713; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,25,0,100,0,0,0,0,0,11,12544,0,0,0,0,0,1,0,0,0,0,0,0,0,"Bloodcursed Naga - On Reset - Cast 'Frost Armor'"); + +-- Pathing for Lord Xiz Entry: 17701 'TDB FORMAT' +SET @NPC := 63448; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=-2226.604,`position_y`=-12321.21,`position_z`=57.54912 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,-2253.258,-12320.91,57.29495,0,0,0,0,100,0), -- 09:08:14 +(@PATH,2,-2214.95,-12321.52,57.30329,0,0,0,0,100,0); -- 09:08:29 +-- 0x1C09E4424011494000002500002C576E .go -2226.604 -12321.21 57.54912 diff --git a/sql/updates/world/2016_01_30_04_world.sql b/sql/updates/world/2016_01_30_04_world.sql new file mode 100644 index 00000000000..b90e7b95810 --- /dev/null +++ b/sql/updates/world/2016_01_30_04_world.sql @@ -0,0 +1,11 @@ +-- Pathing for Mine Car Entry: 23289 'TDB FORMAT' +SET @NPC := 143599; +SET @PATH := @NPC * 10; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, '40684'); + +-- Pathing for Mine Car Entry: 23289 'TDB FORMAT' +SET @NPC := 143600; +SET @PATH := @NPC * 10; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, '40684'); diff --git a/sql/updates/world/2016_01_30_05_world.sql b/sql/updates/world/2016_01_30_05_world.sql new file mode 100644 index 00000000000..1e341506dfc --- /dev/null +++ b/sql/updates/world/2016_01_30_05_world.sql @@ -0,0 +1,2 @@ +UPDATE `smart_scripts` SET `event_param1`=60600, `event_param2`=60600 WHERE `entryorguid`=3101600 AND `source_type`=9 AND `id`=8 AND `link`=0; +UPDATE `smart_scripts` SET `action_param1`=2, `comment`='Overthane Balargarde <Master of Jotunheim> - On Data Set - Set Phase 2' WHERE `entryorguid`=31016 AND `source_type`=0 AND `id`=26 AND `link`=33; diff --git a/sql/updates/world/2016_01_31_00_world.sql b/sql/updates/world/2016_01_31_00_world.sql new file mode 100644 index 00000000000..f64d9182784 --- /dev/null +++ b/sql/updates/world/2016_01_31_00_world.sql @@ -0,0 +1,2 @@ +-- fix cyanigosa hitbox +UPDATE `creature_model_info` SET `BoundingRadius`=0.2325, `CombatReach`=6.25 WHERE `DisplayID`=27340; diff --git a/sql/updates/world/2016_02_02_00_world.sql b/sql/updates/world/2016_02_02_00_world.sql new file mode 100644 index 00000000000..ce561af3a61 --- /dev/null +++ b/sql/updates/world/2016_02_02_00_world.sql @@ -0,0 +1,5 @@ +-- Transition some creatures to use new CREATURE_FLAGS_EXTRA_NO_PLAYER_DAMAGE_REQ +-- 27685/27686/27531: Target creatures for Quest 12416 ("Heated Battle") +-- 24051/24063: Target creatures for Quest 11243 ("If Valgarde Falls...") +-- 28034/28035/28036: Targets for Quest 12508 ("Mopping Up") +UPDATE `creature_template` SET `flags_extra`=(`flags_extra`|2097152) WHERE `entry` IN (27685,27686,27531,24051,24063,28034,28035,28036); diff --git a/sql/updates/world/2016_02_02_01_world.sql b/sql/updates/world/2016_02_02_01_world.sql new file mode 100644 index 00000000000..f1b181a29e3 --- /dev/null +++ b/sql/updates/world/2016_02_02_01_world.sql @@ -0,0 +1,4 @@ +-- new gossip_menu for NPC 3678 Disciple of Naralex: +DELETE FROM `gossip_menu_option` WHERE `menu_id`= 201 AND `OptionBroadcastTextID`= 2662; +INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`,`BoxBroadcastTextID`) VALUES +(201, 0, 0, 'Let the event begin!', 2662, 1, 1, 0, 0, 0, 0, '', 0); diff --git a/sql/updates/world/2016_02_04_00_world.sql b/sql/updates/world/2016_02_04_00_world.sql new file mode 100644 index 00000000000..758286544af --- /dev/null +++ b/sql/updates/world/2016_02_04_00_world.sql @@ -0,0 +1,54 @@ +UPDATE `quest_template` SET `AllowableRaces`=1101 WHERE `ID`=11921; +UPDATE `quest_template` SET `AllowableRaces`=690 WHERE `ID`=11926; +UPDATE `quest_template` SET `TimeAllowed`=45 WHERE `ID` IN (11922,11731); +UPDATE `quest_template` SET `TimeAllowed`=90 WHERE `ID` IN (11921,11926); +UPDATE `quest_template_addon` SET `PrevQuestId`=11731 WHERE `ID`=11921; -- More Torch Tossing(A) requires Torch Tossing +UPDATE `quest_template_addon` SET `PrevQuestId`=11922 WHERE `ID`=11926; -- More Torch Tossing(H) requires Torch Tossing +UPDATE `quest_template_addon` SET `PrevQuestId`=11731 WHERE `ID`=11657; -- Torch Catching(A) requires Torch Tossing(A) +UPDATE `quest_template_addon` SET `PrevQuestId`=11922 WHERE `ID`=11923; -- Torch Catching(H) requires Torch Tossing(H) +UPDATE `quest_template_addon` SET `PrevQuestId`=11657 WHERE `ID`=11924; -- More Torch Catching(A) requires Torch Catching +UPDATE `quest_template_addon` SET `PrevQuestId`=11923 WHERE `ID`=11925; -- More Torch Catching(H) requires Torch Catching + +DELETE FROM `creature_queststarter` WHERE `id` IN (26113,25975); +-- Master Flame/Fire Eater SAI +UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry` IN (25975,26113); +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`IN (25975,26113); +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(25975,0,0,0,19,0,100,0,11731,0,0,0,11,45716,2,0,0,0,0,7,0,0,0,0,0,0,0,'Master Fire Eater - On Quest \'Torch Tossing\' Accepted - Cast \'Torch Tossing Training\''), +(25975,0,1,0,19,0,100,0,11921,0,0,0,11,46630,2,0,0,0,0,7,0,0,0,0,0,0,0,'Master Fire Eater - On Quest \'More Torch Tossing\' Accepted - Cast \'Torch Tossing Practice\''), +(26113,0,0,0,19,0,100,0,11922,0,0,0,11,45716,2,0,0,0,0,7,0,0,0,0,0,0,0,'Master Flame Eater - On Quest \'Torch Tossing\' Accepted - Cast \'Torch Tossing Training\''), +(26113,0,1,0,19,0,100,0,11926,0,0,0,11,46630,2,0,0,0,0,7,0,0,0,0,0,0,0,'Master Flame Eater - On Quest \'More Torch Tossing\' Accepted - Cast \'Torch Tossing Practice\''); + +-- [DNT] Torch Tossing Target Bunny +DELETE FROM `creature_template_addon` WHERE `entry`=25535; +INSERT INTO `creature_template_addon` (`entry`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES +(25535,0,0,0,0,0,45720); + +UPDATE `creature_template` SET `AIName`= 'SmartAI' WHERE `entry`=25535; +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid`=25535; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(25535,0,0,0,8,0,100,0,45732,0,0,0,11,45724,2,0,0,0,0,7,0,0,0,0,0,0,0,'[DNT] Torch Tossing Target Bunny - On Spellhit \'Torch Land\' - Cast \'Brazzier Hit\''); + +-- [DNT] Torch Tossing Target Bunny Controller +UPDATE `creature_template` SET `ScriptName`='npc_torch_tossing_target_bunny_controller' WHERE `entry`=25536; + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=13 AND `SourceEntry` IN (45732); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition` ,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(13,1,45732,0,0,1,0,45723,0,0,0,0,'','Spell \'Torch Toss\' can only hit targets with Aura \'Target Indicator\''); + +DELETE FROM `spell_linked_spell` WHERE `spell_trigger` IN (45719,46651,46630,45723,-46630,45716,-45716); +INSERT INTO `spell_linked_spell` (`spell_trigger`,`spell_effect`,`type`,`comment`) VALUES +(45719,-46630,0,'Torch Tossing Success remove Torch Tossing Practice'), +(46651,-45716,0,'Torch Tossing Success remove Torch Tossing Training'), +(46630,45725 ,2,'Torch Tossing Practice trigger Detect Invisibility'), +(45716,45725 ,2,'Torch Tossing Training trigger Detect Invisibility'), +(46630,-45724,0,'Torch Tossing Practice remove Brazier Hit'), +(45716,-45724,0,'Torch Tossing Training remove Brazier Hit'), +(-46630,-45724,0,'Torch Tossing Practice expired - clear Braziers Hit!'), +(-45716,-45724,0,'Torch Tossing Training expired - clear Braziers Hit!'), +(45723,43313,2,'Target Indicator(duration) trigger Target Indicator(visual)'); + +-- Fix A Thief's Reward +DELETE FROM `creature_queststarter` WHERE `quest` IN (9365, 9339); +UPDATE `quest_template_addon` SET `NextQuestID`=9365 WHERE `ID` IN (9324,9325,9326,11935); +UPDATE `quest_template_addon` SET `NextQuestID`=9339 WHERE `ID` IN (9330,9331,9332,11933); diff --git a/sql/updates/world/2016_02_05_00_world.sql b/sql/updates/world/2016_02_05_00_world.sql new file mode 100644 index 00000000000..46f2b488b9a --- /dev/null +++ b/sql/updates/world/2016_02_05_00_world.sql @@ -0,0 +1,6 @@ +-- Implement "Toy Train Set" and "Wind-Up Train Wrecker" +UPDATE `gameobject_template` SET `ScriptName`="go_toy_train_set" WHERE `entry`=193963; +UPDATE `creature_template` SET `ScriptName`="npc_train_wrecker" WHERE `entry`=33404; +DELETE FROM `spell_script_names` WHERE `spell_id`=61551; +INSERT INTO `spell_script_names` (`spell_id`,`ScriptName`) VALUES +(61551,"spell_item_toy_train_set_pulse"); diff --git a/sql/updates/world/2016_02_06_00_world.sql b/sql/updates/world/2016_02_06_00_world.sql new file mode 100644 index 00000000000..d303a8b5b85 --- /dev/null +++ b/sql/updates/world/2016_02_06_00_world.sql @@ -0,0 +1,2 @@ +-- Implement Egbert's running +UPDATE creature_template SET ScriptName = "npc_egbert" WHERE entry = 23258; diff --git a/sql/updates/world/2016_02_06_01_world.sql b/sql/updates/world/2016_02_06_01_world.sql new file mode 100644 index 00000000000..6812c4af52e --- /dev/null +++ b/sql/updates/world/2016_02_06_01_world.sql @@ -0,0 +1,3 @@ +-- +-- Stinky + Precious - Knockbackimmunity +UPDATE `creature_template` SET `flags_extra`=`flags_extra`|0x40000000 WHERE `entry` IN (37025, 38064, 37217, 38103); diff --git a/sql/updates/world/2016_02_06_02_world.sql b/sql/updates/world/2016_02_06_02_world.sql new file mode 100644 index 00000000000..b9fd7cd9d63 --- /dev/null +++ b/sql/updates/world/2016_02_06_02_world.sql @@ -0,0 +1,20 @@ +-- +-- Knockbackimmunity Cleanup +UPDATE `creature_template` SET `flags_extra`=`flags_extra`|0x40000000 WHERE `entry` IN ( +-- npc_kinetic_bomb +38454, 38775, 38776, 38777, +-- npc_iron_roots +33088, 33396, 33168, 33397, +-- npc_saronite_vapors +33488, 33789, +-- NPC_GAS_CLOUD +37562, 38602, 38760, 38761, +-- NPC_VOLATILE_OOZE +37697, 38604, 38758, 38759, +-- npc_training_dummy +2673, 2674, 17578, 16111, 24792, 32543, 32546, 32547, 32542, 32545, 30527, 31143, 31144, 31146, 32541, 32666, 32667, +-- npc_tournament_training_dummy +33229, 33243, 33272, +-- npc_ice_tomb +36980, 38320, 38321, 38322 +); diff --git a/sql/updates/world/2016_02_06_03_world.sql b/sql/updates/world/2016_02_06_03_world.sql new file mode 100644 index 00000000000..85f8d3c6ae7 --- /dev/null +++ b/sql/updates/world/2016_02_06_03_world.sql @@ -0,0 +1,6 @@ +-- +-- Warsong Recruitment Officer gives dublicate quest +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=19 AND (`SourceEntry`=11586 OR `SourceEntry`=11585); +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceEntry`,`ConditionTypeOrReference`,`ConditionValue1`,`Comment`) VALUES +(19, 11586, 14, 10172, "Accept quest 11586 - Quest 10172 needs to be incomplete"), +(19, 11585, 8, 10172, "Accept quest 11585 - Quest 10172 needs to be rewarded"); diff --git a/sql/updates/world/2016_02_06_04_world.sql b/sql/updates/world/2016_02_06_04_world.sql new file mode 100644 index 00000000000..188b3b5f2a7 --- /dev/null +++ b/sql/updates/world/2016_02_06_04_world.sql @@ -0,0 +1,6 @@ +-- +-- Quest: Scalps! +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=17 AND `SourceEntry`=52090 AND `ElseGroup`=1; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(17, 0, 52090, 0, 1, 31, 1, 3, 28465, 0, 0, 173, 0, '', 'Item 38731 "Ahunae\'s Knife" targets 28465 "Heb\'Drakkar Striker'), +(17, 0, 52090, 0, 1, 36, 1, 0, 0, 0, 1, 173, 0, '', 'Item 38731 "Ahunae\'s Knife" targets 28465 "Heb\'Drakkar Striker'); diff --git a/sql/updates/world/2016_02_06_05_world.sql b/sql/updates/world/2016_02_06_05_world.sql new file mode 100644 index 00000000000..823a8abaca6 --- /dev/null +++ b/sql/updates/world/2016_02_06_05_world.sql @@ -0,0 +1,20 @@ +-- +-- Silithus Stone spells should ignore LoS +DELETE FROM `disables` WHERE `sourceType`=0 AND `entry` IN (24803,24745,24747,24757,24759,24761,24762,24766,24769,24771,24773,24785,24787,24791,24792,24793); +INSERT INTO `disables` (`sourceType`, `entry`, `flags`, `params_0`, `params_1`, `comment`) VALUES +(0, 24803, 64, '', '', 'Abyssal Punishment ignores LoS'), +(0, 24745, 64, '', '', 'Summon Templar, Trigger ignores LoS'), +(0, 24747, 64, '', '', 'Summon Templar Fire, Trigger ignores LoS'), +(0, 24757, 64, '', '', 'Summon Templar Air, Trigger ignores LoS'), +(0, 24759, 64, '', '', 'Summon Templar Earth, Trigger ignores LoS'), +(0, 24761, 64, '', '', 'Summon Templar Water, Trigger ignores LoS'), +(0, 24762, 64, '', '', 'Summon Duke, Trigger ignores LoS'), +(0, 24766, 64, '', '', 'Summon Duke Fire, Trigger ignores LoS'), +(0, 24769, 64, '', '', 'Summon Duke Air, Trigger ignores LoS'), +(0, 24771, 64, '', '', 'Summon Duke Earth, Trigger ignores LoS'), +(0, 24773, 64, '', '', 'Summon Duke Water, Trigger ignores LoS'), +(0, 24785, 64, '', '', 'Summon Royal, Trigger ignores LoS'), +(0, 24787, 64, '', '', 'Summon Royal Fire, Trigger ignores LoS'), +(0, 24791, 64, '', '', 'Summon Royal Air, Trigger ignores LoS'), +(0, 24792, 64, '', '', 'Summon Royal Earth, Trigger ignores LoS'), +(0, 24793, 64, '', '', 'Summon Royal Water, Trigger ignores LoS'); diff --git a/sql/updates/world/2016_02_06_06_world.sql b/sql/updates/world/2016_02_06_06_world.sql new file mode 100644 index 00000000000..37df2ef0868 --- /dev/null +++ b/sql/updates/world/2016_02_06_06_world.sql @@ -0,0 +1,7 @@ +-- +-- Defias Gunpowder SAI +SET @ENTRY := 17155; +UPDATE `gameobject_template` SET `AIName`="SmartGameObjectAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=1; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,1,0,0,70,0,100,0,2,0,0,0,12,4417,3,120000,1,0,0,8,0,0,0,-123.77,-613.586,14.126,6.035,"Defias Gunpowder - On Gossip Hello - Summon Creature 'Defias Taskmaster' (No Repeat)"); diff --git a/sql/updates/world/2016_02_06_07_world.sql b/sql/updates/world/2016_02_06_07_world.sql new file mode 100644 index 00000000000..c5d6434321a --- /dev/null +++ b/sql/updates/world/2016_02_06_07_world.sql @@ -0,0 +1,8 @@ +-- +-- Pustulating Horror SAI +SET @ENTRY := 10404; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,0,0,100,0,2000,6000,10000,10000,11,71089,0,0,0,0,0,5,0,0,0,0,0,0,0,"Pustulating Horror - In Combat - Cast 'Bubbling Pus'"), +(@ENTRY,0,1,0,2,0,100,0,0,10,60000,60000,11,71088,0,0,0,0,0,1,0,0,0,0,0,0,0,"Pustulating Horror - Between 0-10% Health - Cast 'Blight Bomb'"); diff --git a/sql/updates/world/2016_02_06_08_world.sql b/sql/updates/world/2016_02_06_08_world.sql new file mode 100644 index 00000000000..f0855ba348a --- /dev/null +++ b/sql/updates/world/2016_02_06_08_world.sql @@ -0,0 +1,9 @@ +-- +-- DB/Creature: Koren - Gossipoptions +DELETE FROM `gossip_menu_option` WHERE `menu_id`=7435; +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(7435, 0, 1, 'I\'m in need of your skill as a blacksmith, Koren.', 14188, 3, 128, 0, 0, 0, 0, NULL, 0); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceID` = 15 AND `SourceGroup` = 7435; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(15, 7435, 0, 0, 0, 5, 0, 967, 224, 0, 0, 0, 0, '', 'Koren - Show Vendor option if Honored Exalted with Violet Eye'); diff --git a/sql/updates/world/2016_02_06_09_world.sql b/sql/updates/world/2016_02_06_09_world.sql new file mode 100644 index 00000000000..bf92b89e1c2 --- /dev/null +++ b/sql/updates/world/2016_02_06_09_world.sql @@ -0,0 +1,3 @@ +-- +-- Fiery Payback mage talent +DELETE FROM `spell_ranks` WHERE `first_spell_id`=44440; diff --git a/sql/updates/world/2016_02_06_10_world.sql b/sql/updates/world/2016_02_06_10_world.sql new file mode 100644 index 00000000000..291bd0bb333 --- /dev/null +++ b/sql/updates/world/2016_02_06_10_world.sql @@ -0,0 +1,19 @@ + +-- Estelle Gendry - Gossip +DELETE FROM `gossip_menu_option` WHERE (`menu_id`=161 AND `id`=0); +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(161, 0, 0, 'I need another set of thieves'' tools.', 2643, 1, 1, 0, 0, 0, 0, NULL, 0); + +-- Estelle Gendry SAI +SET @ENTRY := 6566; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,1,62,0,100,0,161,0,0,0,11,9949,2,0,0,0,0,7,0,0,0,0,0,0,0,"Estelle Gendry - On Gossip Option 0 Selected - Invoker Cast 'Thieves' Tool Rack Conjure'"), +(@ENTRY,0,1,0,61,0,100,0,161,0,0,0,72,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Estelle Gendry - On Gossip Option 0 Selected - Close Gossip"); + + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=161 AND `SourceEntry`=0; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`ErrorTextId`,`ScriptName`,`Comment`, `NegativeCondition`) VALUES +(15,161,0,0,0,9,0,1999,0,0,0,"","Show Gossip if player has Quest: Tools of the Trade", 0), +(15,161,0,0,0,2,0,5060,1,1,0,"","Show Gossip if player has not item: Thieves' Tools", 1); diff --git a/sql/updates/world/2016_02_06_11_world.sql b/sql/updates/world/2016_02_06_11_world.sql new file mode 100644 index 00000000000..cea352fec36 --- /dev/null +++ b/sql/updates/world/2016_02_06_11_world.sql @@ -0,0 +1,2 @@ +-- Implement Pandaran Monk's pet abilitys +UPDATE creature_template SET ScriptName = "npc_pandaren_monk" WHERE entry = 36911; diff --git a/sql/updates/world/2016_02_06_12_world.sql b/sql/updates/world/2016_02_06_12_world.sql new file mode 100644 index 00000000000..df550156bc1 --- /dev/null +++ b/sql/updates/world/2016_02_06_12_world.sql @@ -0,0 +1,4 @@ +-- +-- DB/Conditions: Meridith the Mermaiden +UPDATE `conditions` SET `NegativeCondition`=0 WHERE `SourceTypeOrReferenceId`=14 AND `SourceGroup`=6658 AND `SourceEntry`=7916; +UPDATE `conditions` SET `NegativeCondition`=1 WHERE `SourceTypeOrReferenceId`=14 AND `SourceGroup`=6658 AND `SourceEntry`=7917; diff --git a/sql/updates/world/2016_02_06_13_world_335.sql b/sql/updates/world/2016_02_06_13_world_335.sql new file mode 100644 index 00000000000..22bd5596d98 --- /dev/null +++ b/sql/updates/world/2016_02_06_13_world_335.sql @@ -0,0 +1,3 @@ +-- +-- DB/Quest: Avenging The Fallen +UPDATE `quest_template_addon` SET `SpecialFlags`=0 WHERE `Id`=7830; diff --git a/sql/updates/world/2016_02_06_14_world.sql b/sql/updates/world/2016_02_06_14_world.sql new file mode 100644 index 00000000000..7bf05b61c71 --- /dev/null +++ b/sql/updates/world/2016_02_06_14_world.sql @@ -0,0 +1,3 @@ +-- +-- DB/Quest: Venomhide Eggs +UPDATE `quest_template_addon` SET `PrevQuestID`=13850 WHERE `ID`=13887; diff --git a/sql/updates/world/2016_02_07_00_world.sql b/sql/updates/world/2016_02_07_00_world.sql new file mode 100644 index 00000000000..5a49f8fd310 --- /dev/null +++ b/sql/updates/world/2016_02_07_00_world.sql @@ -0,0 +1,5 @@ +-- +-- Creature: Injured Goblin Miner conditional gossip +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceID` = 15 AND `SourceGroup` = 9859 AND `SourceEntry` = 0; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`NegativeCondition`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(15,9859,0,0,0,9,0,12832,0,0,0,0,'','Injured Goblin Miner - Show gossip option 0 if player has taken quest ID 12832'); diff --git a/sql/updates/world/2016_02_07_01_world_335.sql b/sql/updates/world/2016_02_07_01_world_335.sql new file mode 100644 index 00000000000..5f1d5f4280e --- /dev/null +++ b/sql/updates/world/2016_02_07_01_world_335.sql @@ -0,0 +1,8 @@ +-- DB/Item: "Deprecated BKP "Impact" Shot" +-- Restore correct values for bullet item "Deprecated BKP "Impact" Shot": +UPDATE `item_template` SET `name`= 'Deprecated BKP "Impact" Shot', `Quality`= 1, + `Flags`= 16, `FlagsExtra`= 8192, `BuyCount`= 200, `BuyPrice`= 450, `SellPrice`= 0, + `ItemLevel`= 35, `RequiredLevel`= 30, `stackable`= 1000, `StatsCount`= 0, + `stat_type1`= 0, `stat_value1`= 0, `stat_type2`= 0, `stat_value2`= 0, `dmg_min1`= 9, + `dmg_max1`= 9, `armor`= 0, `delay`= 3000, `bonding`= 0, `MaxDurability`= 0, `BagFamily`= 2, + `RequiredDisenchantSkill`= -1, `DisenchantID`= 0 WHERE `entry`= 3034; diff --git a/sql/updates/world/2016_02_07_02_world_335.sql b/sql/updates/world/2016_02_07_02_world_335.sql new file mode 100644 index 00000000000..ea4608f3a6b --- /dev/null +++ b/sql/updates/world/2016_02_07_02_world_335.sql @@ -0,0 +1,13 @@ +-- +-- DB/Quest: Escape Through Force +DELETE FROM `smart_scripts` WHERE `entryorguid`=3692 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(3692, 0, 0, 1, 19, 0, 100, 0, 994, 0, 0, 0, 64, 1, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Volcor - On Quest \'Escape Through Force\' Taken - Store Targetlist'), +(3692, 0, 1, 2, 61, 0, 100, 0, 0, 0, 0, 0, 19, 768, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Volcor - On Quest \'Escape Through Force\' Taken - Set Unit Flags'), +(3692, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 80, 369200, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Volcor - On Quest \'Escape Through Force\' Taken - Run Script'), +(3692, 0, 3, 4, 19, 0, 100, 0, 995, 0, 0, 0, 64, 1, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Volcor - On Quest \'Escape Through Stealth\' Taken - Store Targetlist'), +(3692, 0, 4, 5, 61, 0, 100, 0, 0, 0, 0, 0, 19, 768, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Volcor - On Quest \'Escape Through Stealth\' Taken - Set Unit Flags'), +(3692, 0, 5, 0, 61, 0, 100, 0, 995, 0, 0, 0, 80, 369201, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Volcor - On Quest \'Escape Through Stealth\' Taken - Run Script'), +(3692, 0, 6, 0, 40, 0, 100, 0, 15, 3692, 0, 0, 41, 5000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Volcor - On Waypoint 15 Reached - Despawn 5 Seconds'); + +UPDATE `smart_scripts` SET `target_type`=12, `target_param1`=1 WHERE `entryorguid` IN(369200,369201) AND `source_type`=9 AND `id`IN(2,3); diff --git a/sql/updates/world/2016_02_07_03_world_335.sql b/sql/updates/world/2016_02_07_03_world_335.sql new file mode 100644 index 00000000000..8322ff59c4c --- /dev/null +++ b/sql/updates/world/2016_02_07_03_world_335.sql @@ -0,0 +1,65 @@ +-- +-- Sorrow Wing (3.3.5) loot items +DELETE FROM `creature_loot_template` WHERE `Entry`= 5928; +INSERT INTO `creature_loot_template` (`Entry`,`Item`,`Reference`,`Chance`,`QuestRequired`,`LootMode`,`GroupID`,`MinCount`,`MaxCount`,`Comment`) VALUES +(5928, 5808,0, 50, 1,1,0,1,1,'Pridewing Venom Sac (Quest item)'), +(5928, 5137,0, 0.8, 0,1,0,1,2,'Bright Eyeball'), +(5928, 1686,0, 10, 0,1,0,1,2,'Bristly Whisker'), +(5928, 7073,0, 88, 0,1,0,1,2,'Broken Fang'), +(5928, 3381,0,0.19, 0,1,0,1,1,'Cross-Stitched Bracers'), +(5928, 1783,0, 0.3, 0,1,0,1,1,'Cross-Stitched Gloves'), +(5928, 2785,0,0.16, 0,1,0,1,1,'Stiff Recurve Bow'), +(5928, 2221,0, 0.2, 0,1,0,1,1,'Targe Shield'), +(5928, 1808,0,0.16, 0,1,0,1,1,'Tough Leather Pants'), +(5928, 5136,0, 0.8, 0,1,0,1,2,'Torn Furry Ear'), +(5928, 9837,0, 0.9, 0,1,0,1,1,'Banded Bracers'), +(5928, 9838,0, 1.3, 0,1,0,1,1,'Banded Cloak'), +(5928, 9839,0, 0.8, 0,1,0,1,1,'Banded Gauntlets'), +(5928, 9840,0, 0.3, 0,1,0,1,1,'Banded Girdle'), +(5928, 6592,0, 1.2, 0,1,0,1,1,'Battleforge Armor'), +(5928, 6590,0, 1.4, 0,1,0,1,1,'Battleforge Boots'), +(5928, 6595,0, 3, 0,1,0,1,1,'Battleforge Gauntlets'), +(5928, 6594,0, 3, 0,1,0,1,1,'Battleforge Girdle'), +(5928, 6596,0, 4, 0,1,0,1,1,'Battleforge Legguards'), +(5928, 6597,0, 3, 0,1,0,1,1,'Battleforge Shoulderguards'), +(5928, 6591,0, 3, 0,1,0,1,1,'Battleforge Wristguards'), +(5928, 6600,0, 3, 0,1,0,1,1,'Dervish Belt'), +(5928, 6601,0, 5, 0,1,0,1,1,'Dervish Boots'), +(5928, 6602,0, 3, 0,1,0,1,1,'Dervish Bracers'), +(5928, 6605,0, 3, 0,1,0,1,1,'Dervish Gloves'), +(5928, 7415,0, 1.5, 0,1,0,1,1,'Dervish Spaulders'), +(5928, 6607,0, 1.3, 0,1,0,1,1,'Dervish Leggings'), +(5928, 6603,0, 2, 0,1,0,1,1,'Dervish Tunic'), +(5928,10404,0, 1.6, 0,1,0,1,1,'Durable Belt'), +(5928, 9820,0, 0.4, 0,1,0,1,1,'Durable Boots'), +(5928, 9821,0, 1.1, 0,1,0,1,1,'Durable Bracers'), +(5928, 9822,0, 1.3, 0,1,0,1,1,'Durable Cape'), +(5928, 9823,0, 0.5, 0,1,0,1,1,'Durable Gloves'), +(5928, 7355,0, 0.8, 0,1,0,1,1,'Elders Bracers'), +(5928, 7356,0, 0.9, 0,1,0,1,1,'Elders Cloak'), +(5928, 7370,0, 0.7, 0,1,0,1,1,'Elders Sash'), +(5928, 4715,0, 6, 0,1,0,1,1,'Emblazoned Cloak'), +(5928, 7410,0, 0.7, 0,1,0,1,1,'Infiltrator Bracers'), +(5928, 7411,0, 0.6, 0,1,0,1,1,'Infiltrator Cloak'), +(5928, 9796,0, 3, 0,1,0,1,1,'Ivycloth Mantle'), +(5928, 9797,0, 3, 0,1,0,1,1,'Ivycloth Pants'), +(5928, 9791,0, 1.3, 0,1,0,1,1,'Ivycloth Tunic'), +(5928, 7416,0, 0.6, 0,1,0,1,1,'Phalanx Bracers'), +(5928, 7419,0, 1.1, 0,1,0,1,1,'Phalanx Cloak'), +(5928, 6612,0, 3, 0,1,0,1,1,'Sages Boots'), +(5928, 6613,0, 4, 0,1,0,1,1,'Sages Bracers'), +(5928,10288,0, 0.8, 0,1,0,1,1,'Sages Circlet'), +(5928, 6614,0, 4, 0,1,0,1,1,'Sages Cloak'), +(5928, 6615,0, 0.9, 0,1,0,1,1,'Sages Gloves'), +(5928, 6617,0, 1.2, 0,1,0,1,1,'Sages Mantle'), +(5928, 6611,0, 2, 0,1,0,1,1,'Sages Sash'), +(5928, 9831,0, 1.8, 0,1,0,1,1,'Scaled Cloak'), +(5928, 9827,0, 0.8, 0,1,0,1,1,'Scaled Leather Belt'), +(5928, 9828,0, 0.9, 0,1,0,1,1,'Scaled Leather Boots'), +(5928, 9829,0, 1.6, 0,1,0,1,1,'Scaled Leather Bracers'), +(5928, 9832,0, 0.9, 0,1,0,1,1,'Scaled Leather Gloves'), +(5928, 9806,0, 3, 0,1,0,1,1,'Superior Gloves'), +(5928, 9808,0, 3, 0,1,0,1,1,'Superior Leggings'), +(5928, 9807,0, 3, 0,1,0,1,1,'Superior Shoulders'), +(5928, 9809,0, 4, 0,1,0,1,1,'Superior Tunic'), +(5928,15539,0,0.03, 0,1,0,1,1,'Wicked Chain Waistband'); diff --git a/sql/updates/world/2016_02_07_04_world.sql b/sql/updates/world/2016_02_07_04_world.sql new file mode 100644 index 00000000000..3a3a7a393d7 --- /dev/null +++ b/sql/updates/world/2016_02_07_04_world.sql @@ -0,0 +1,67 @@ +-- DB/Quest: The Collapse +DELETE FROM `event_scripts` WHERE `id`=16929; +INSERT INTO `event_scripts` (`id`, `delay`, `command`, `datalong`, `datalong2`, `dataint`, `x`, `y`, `z`, `o`) VALUES +(16929, 10, 8, 25742, 0, 0, 0, 0, 0, 0), +(16929, 3, 10, 25742, 360000, 0, 3517.290039, 4538.782715, -12.983689, 4.428759), +(16929, 7, 10, 25629, 360000, 0, 3492.105469, 4478.011719, -12.997340, 0.210166), +(16929, 7, 10, 25652, 360000, 0, 3507.666260, 4509.300293, -14.792936, 0.945820), +(16929, 7, 10, 25652, 360000, 0, 3505.954834, 4506.928223, -14.817587, 0.945820), +(16929, 7, 10, 25652, 360000, 0, 3505.296631, 4506.016113, -14.837238, 0.945820), +(16929, 7, 10, 25652, 360000, 0, 3504.330322, 4504.676758, -14.837238, 0.945820); + +-- Alluvius SAI +SET @ENTRY := 25742; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,54,0,100,0,0,0,0,0,53,1,25742,0,0,0,0,1,0,0,0,0,0,0,0,"Alluvius - On Just Summoned - Start Waypoint"), +(@ENTRY,0,1,0,40,0,100,0,1,25742,0,0,80,@ENTRY*100+00,2,0,0,0,0,1,0,0,0,0,0,0,0,"Alluvius - On Waypoint 1 Reached - Run Script"); + +DELETE FROM `waypoints` WHERE `entry`=25742; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES +(25742, 1, 3511.336426, 4519.295898, -11.937509, 'Alluvius'); + +-- Actionlist SAI +SET @ENTRY := 2574200; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,9,0,0,0,0,100,0,5000,5000,5000,5000,45,1,1,0,0,0,0,9,25652,0,25,0,0,0,0,"Alluvius - On Script - Set Data 1 1"), +(@ENTRY,9,1,0,0,0,100,0,0,0,0,0,5,36,0,0,0,0,0,1,0,0,0,0,0,0,0,"Alluvius - On Script - Play Emote 36"), +(@ENTRY,9,2,0,0,0,100,0,10000,10000,10000,10000,41,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Alluvius - On Script - Despawn Instant"); + +-- Nerub'ar Scarab SAI +SET @ENTRY := 25652; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,38,0,100,0,1,1,0,0,53,0,25652,0,0,0,0,1,0,0,0,0,0,0,0,"Nerub'ar Scarab - On Data Set 1 1 - Start Waypoint"), +(@ENTRY,0,1,0,40,0,100,0,6,25652,0,0,41,1000,0,0,0,0,0,1,0,0,0,0,0,0,0,"Nerub'ar Scarab - On Waypoint 6 Reached - Despawn In 1000 ms"); + +DELETE FROM `waypoints` WHERE `entry`=25652; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES +(25652, 1, 3509.71, 4510.5, -14.6752, 'Nerub\'ar Scarab'), +(25652, 2, 3515.16, 4512.57, -13.4052, 'Nerub\'ar Scarab'), +(25652, 3, 3520.58, 4511.77, -12.5632, 'Nerub\'ar Scarab'), +(25652, 4, 3530.14, 4507.88, -12.9948, 'Nerub\'ar Scarab'), +(25652, 5, 3536.34, 4508.6, -12.9948, 'Nerub\'ar Scarab'), +(25652, 6, 3553.48, 4510.25, -12.9948, 'Nerub\'ar Scarab'); + +-- Lord Kryxix SAI +SET @ENTRY := 25629; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,1,54,0,100,0,0,0,0,0,53,1,25629,0,0,0,2,1,0,0,0,0,0,0,0,"Lord Kryxix - On Just Summoned - Start Waypoint"), +(@ENTRY,0,1,0,61,0,100,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Lord Kryxix - On Just Summoned - Say Line 0"), +(@ENTRY,0,2,0,40,0,100,0,4,25629,0,0,49,0,0,0,0,0,0,21,80,0,0,0,0,0,0,"Lord Kryxix - On Waypoint 4 Reached - Start Attacking"); + +DELETE FROM `waypoints` WHERE `entry`=25629; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES +(25629, 1, 3529.33, 4490.55, -12.9951, 'Lord Kryxix'), +(25629, 2, 3534.51, 4509.94, -12.9951, 'Lord Kryxix'), +(25629, 3, 3533.52, 4527.86, -12.9951, 'Lord Kryxix'), +(25629, 4, 3512.91, 4539.59, -12.987, 'Lord Kryxix'); + +DELETE FROM `creature_text` WHERE `entry`=25629; +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `comment`, `BroadcastTextId`) VALUES +(25629, 0, 0, 'Foolish elemental slave! You an your master will pay for your medding!', 14, 0, 100, 0, 0, 0, 'Lord Kryxix', 24956); diff --git a/sql/updates/world/2016_02_07_05_world_335.sql b/sql/updates/world/2016_02_07_05_world_335.sql new file mode 100644 index 00000000000..794b3d80411 --- /dev/null +++ b/sql/updates/world/2016_02_07_05_world_335.sql @@ -0,0 +1,4 @@ +-- +-- Wotlk armor value +UPDATE `creature_classlevelstats` SET `basearmor`=10643 WHERE `level`=83 AND `class`=1; +UPDATE `creature_classlevelstats` SET `basearmor`=10643 WHERE `level`=83 AND `class`=2; diff --git a/sql/updates/world/2016_02_07_06_world.sql b/sql/updates/world/2016_02_07_06_world.sql new file mode 100644 index 00000000000..31ecf826660 --- /dev/null +++ b/sql/updates/world/2016_02_07_06_world.sql @@ -0,0 +1,71 @@ +-- +-- Diremaul North Rndmemotes +-- Gordok Mauler SAI +SET @ENTRY := 11442; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`=4; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,4,0,1,0,100,0,3000,3000,5000,10000,10,1,11,391,0,0,0,1,0,0,0,0,0,0,0,"Gordok Mauler - Out of Combat - Play Random Emote (1, 11, 391)"); + +-- Gordok Mage-Lord SAI +SET @ENTRY := 11444; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`=7; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,7,0,1,0,100,0,3000,3000,5000,10000,10,1,11,391,0,0,0,1,0,0,0,0,0,0,0,"Gordok Mage Lord - Out of Combat - Play Random Emote (1, 11, 391)"); + +-- Gordok Brute SAI +SET @ENTRY := 11441; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`=6; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,6,0,1,0,100,0,3000,3000,5000,10000,10,1,11,391,0,0,0,1,0,0,0,0,0,0,0,"Gordok Brute - Out of Combat - Play Random Emote (1, 11, 391)"); + +-- Stomper Kreeg SAI +SET @ENTRY := 14322; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`=6; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,6,0,1,0,100,0,1000,1000,20000,20000,80,@ENTRY*100+00,2,0,0,0,0,1,0,0,0,0,0,0,0,"Stomper Kreeg - Out of Combat - Run Script"); +-- Actionlist SAI +SET @ENTRY := 1432200; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,9,0,0,0,0,100,0,1000,1000,0,0,90,3,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stomper Kreeg - On Script - Set Flag Standstate Sleep"), +(@ENTRY,9,1,0,0,0,100,0,8000,8000,0,0,91,3,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stomper Kreeg - On Script - Remove Flag Standstate Sleep"), +(@ENTRY,9,2,0,0,0,100,0,2000,2000,0,0,17,10,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stomper Kreeg - On Script - Set Emote State 10"); + +-- Gordok Bushwacker SAI +SET @ENTRY := 14351; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`=3; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,3,0,1,0,100,0,3000,3000,5000,10000,10,1,11,391,0,0,0,1,0,0,0,0,0,0,0,"Gordok Bushwacker - Out of Combat - Play Random Emote (1, 11, 391)"); + +-- Gordok Reaver SAI +SET @ENTRY := 11450; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`=3; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,3,0,1,0,100,0,3000,3000,5000,10000,10,1,11,391,0,0,0,1,0,0,0,0,0,0,0,"Gordok Reaver - Out of Combat - Play Random Emote (1, 11, 391)"); + +-- Gordok Warlock SAI +SET @ENTRY := 11448; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`=7; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,7,0,1,0,100,0,3000,3000,5000,10000,10,1,11,391,0,0,0,1,0,0,0,0,0,0,0,"Gordok Warlock - Out of Combat - Play Random Emote (1, 11, 391)"); + +-- Gordok Spirit SAI +SET @ENTRY := 11446; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,1,0,100,0,3000,3000,5000,10000,10,1,11,391,0,0,0,1,0,0,0,0,0,0,0,"Gordok Spirit - Out of Combat - Play Random Emote (1, 11, 397)"); + +-- Gordok Captain SAI +SET @ENTRY := 11445; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`=4; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,4,0,1,0,100,0,3000,3000,5000,10000,10,1,11,391,0,0,0,1,0,0,0,0,0,0,0,"Gordok Captain - Out of Combat - Play Random Emote (1, 11, 397)"); diff --git a/sql/updates/world/2016_02_07_07_world_335.sql b/sql/updates/world/2016_02_07_07_world_335.sql new file mode 100644 index 00000000000..af323a47bda --- /dev/null +++ b/sql/updates/world/2016_02_07_07_world_335.sql @@ -0,0 +1,6 @@ +-- +-- Remove skinning_loot_template 100008 from non-skinnable beasts: +UPDATE `creature_template` SET `skinloot`= 0 WHERE `skinloot`= 100008 AND `entry` NOT IN (1042,1043,1069); + +UPDATE `skinning_loot_template` SET `Comment`='Light Leather' WHERE `Item`= 2318 AND `Entry` IN (3098,3124); +UPDATE `skinning_loot_template` SET `Comment`='Ruined Leather Scraps' WHERE `Item`= 2934 AND `Entry` IN (3098,3124); diff --git a/sql/updates/world/2016_02_07_08_world_335.sql b/sql/updates/world/2016_02_07_08_world_335.sql new file mode 100644 index 00000000000..2b78a317f95 --- /dev/null +++ b/sql/updates/world/2016_02_07_08_world_335.sql @@ -0,0 +1,72 @@ +-- DB/Quest: Urok Doomhowl - Summonscript +SET @MAGUS = 10602; +SET @ENFORCER = 10601; +SET @UROK = 10584; +SET @OGUID = 21202; + +UPDATE `creature_template` SET `faction`=40 WHERE `entry`IN(10601,10602); + + +DELETE FROM `gameobject` WHERE `id` IN(175571,175584); +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0, 175571, 229, 3, 1, -47.90947, -369.0891, 51.54253, 1.378809, 0, 0, 0, 1, -1, 255, 1), -- 175571 (Area: 0) +(@OGUID+1, 175571, 229, 3, 1, -27.88039, -385.8911, 48.50668, 3.700105, 0, 0, 0, 1, -1, 255, 1), -- 175571 (Area: 0) +(@OGUID+2, 175571, 229, 3, 1, -13.72754, -384.8161, 48.97457, 3.68265, 0, 0, 0, 1, -1, 255, 1), -- 175571 (Area: 0) +(@OGUID+3, 175571, 229, 3, 1, -12.36894, -376.4748, 49.335, 5.044002, 0, 0, 0, 1, -1, 255, 1), -- 175571 (Area: 0) +(@OGUID+4, 175571, 229, 3, 1, -24.88243, -369.6189, 49.70592, 3.403396, 0, 0, 0, 1, -1, 255, 1), -- 175571 (Area: 0) +(@OGUID+5, 175584, 229, 3, 1, -14.3415, -395.7287, 48.53813, 2.862335, 0, 0, 0, 1, -1, 255, 0), -- 175584 (Area: 0) +(@OGUID+6, 175571, 229, 3, 1, -34.54366, -370.2325, 50.3396, 5.358161, 0, 0, 0, 1, -1, 255, 1); -- 175571 (Area: 0) + +UPDATE `gameobject` SET `position_y`=-395.729 WHERE `guid`=99791; + +DELETE FROM `event_scripts` WHERE `id`=4845; +INSERT INTO `event_scripts` (`id`, `delay`, `command`, `datalong`, `datalong2`, `dataint`, `x`, `y`, `z`, `o`) VALUES +(4845, 0, 9, @OGUID+0, 66, 0, 0, 0, 0, 0), +(4845, 0, 9, @OGUID+1, 66, 0, 0, 0, 0, 0), +(4845, 0, 9, @OGUID+2, 66, 0, 0, 0, 0, 0), +(4845, 0, 9, @OGUID+3, 66, 0, 0, 0, 0, 0), +(4845, 0, 9, @OGUID+4, 66, 0, 0, 0, 0, 0), +(4845, 0, 9, @OGUID+5, 66, 0, 0, 0, 0, 0), +(4845, 0, 9, @OGUID+6, 66, 0, 0, 0, 0, 0), + +(4845, 5, 10, @MAGUS, 900000, 0, -33.04, -385.57, 48.60, 5.98), +(4845, 5, 10, @ENFORCER, 900000, 0, -16.12, -376.99, 49.20, 4.89), +(4845, 5, 10, @ENFORCER, 900000, 0, -25.13, -376.60, 48.94, 5.17), +(4845, 13, 10, @MAGUS, 900000, 0, -14.93, -381.99, 49.04, 4.70), +(4845, 28, 10, @MAGUS, 900000, 0, -35.47, -371.36, 50.22, 4.79), +(4845, 28, 10, @ENFORCER, 900000, 0, -47.54, -368.11, 51.67, 5.70), +(4845, 42, 10, @MAGUS, 900000, 0, -33.04, -385.57, 48.60, 5.98), +(4845, 42, 10, @MAGUS, 900000, 0, -14.58, -375.16, 49.31, 4.73), +(4845, 42, 10, @ENFORCER, 900000, 0, -24.91, -376.41, 48.95, 4.67), +(4845, 58, 10, @MAGUS, 900000, 0, -47.54, -368.11, 51.67, 5.70), +(4845, 66, 10, @UROK, 900000, 0, -23.97, -391.89, 48.58, 1.68); + +-- Urok Ogre Magus SAI +SET @ENTRY := 10602; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,0,0,100,2,0,0,3400,4700,11,15979,64,0,0,0,0,2,0,0,0,0,0,0,0,"Urok Ogre Magus - In Combat - Cast 'Arcane Bolt' (Normal Dungeon)"), +(@ENTRY,0,1,2,2,0,100,3,0,15,0,0,25,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Urok Ogre Magus - Between 0-15% Health - Flee For Assist (No Repeat) (Normal Dungeon)"), +(@ENTRY,0,2,0,61,0,100,3,0,15,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Urok Ogre Magus - Between 0-15% Health - Say Line 0 (No Repeat) (Normal Dungeon)"), +(@ENTRY,0,3,0,16,0,100,2,6742,30,10000,15000,11,6742,0,0,0,0,0,7,0,0,0,0,0,0,0,"Urok Ogre Magus - On Friendly Unit Missing Buff 'Bloodlust' - Cast 'Bloodlust' (Normal Dungeon)"), +(@ENTRY,0,4,0,0,0,100,2,3000,4000,5000,8000,11,13747,1,0,0,0,0,2,0,0,0,0,0,0,0,"Urok Ogre Magus - In Combat - Cast 'Slow' (Normal Dungeon)"), +(@ENTRY,0,5,0,54,0,100,1,0,0,0,0,11,64195,2,0,0,0,0,1,0,0,0,0,0,0,0,"Urok Ogre Magus - On Just Summoned - Cast 'Simple Teleport' (No Repeat)"), +(@ENTRY,0,6,0,54,0,100,1,0,0,0,0,49,0,0,0,0,0,0,21,50,0,0,0,0,0,0,"Urok Ogre Magus - On Just Summoned - Start Attacking (No Repeat)"); + +-- NPC talk text insert +SET @ENTRY := 10602; +DELETE FROM `creature_text` WHERE `entry`=@ENTRY; +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`comment`, `BroadcastTextId`) VALUES +(@ENTRY,0,0, '%s attempts to run away in fear!',16,0,100,0,0,0, 'combat Flee', 1150); + +-- Urok Enforcer SAI +SET @ENTRY := 10601; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,0,0,100,2,3000,5000,3000,6000,11,16856,2,0,0,0,0,2,0,0,0,0,0,0,0,"Urok Enforcer - In Combat - Cast 'Mortal Strike' (Normal Dungeon)"), +(@ENTRY,0,1,0,0,0,100,1,0,1000,6000,7000,11,11084,2,0,0,0,0,2,0,0,0,0,0,0,0,"Urok Enforcer - In Combat - Cast 'Shock' (No Repeat)"), +(@ENTRY,0,2,0,0,0,100,2,8000,8000,12000,17000,11,14516,2,0,0,0,0,2,0,0,0,0,0,0,0,"Urok Enforcer - In Combat - Cast 'Strike' (Normal Dungeon)"), +(@ENTRY,0,3,0,54,0,100,1,0,0,0,0,11,64195,2,0,0,0,0,1,0,0,0,0,0,0,0,"Urok Enforcer - On Just Summoned - Cast 'Simple Teleport' (No Repeat)"), +(@ENTRY,0,4,0,54,0,100,1,0,0,0,0,49,0,0,0,0,0,0,21,50,0,0,0,0,0,0,"Urok Enforcer - On Just Summoned - Start Attacking (No Repeat)"); diff --git a/sql/updates/world/2016_02_07_09_world.sql b/sql/updates/world/2016_02_07_09_world.sql new file mode 100644 index 00000000000..8057534fbb8 --- /dev/null +++ b/sql/updates/world/2016_02_07_09_world.sql @@ -0,0 +1,6 @@ +-- +-- Solace of the Defeated/Solace of the Fallen (Normal/Heroic) proc fix +DELETE FROM `spell_proc_event` WHERE `entry` IN (67698,67752); +INSERT INTO `spell_proc_event` (`entry`,`SchoolMask`,`SpellFamilyName`,`SpellFamilyMask0`,`SpellFamilyMask1`,`SpellFamilyMask2`,`procFlags`,`procEx`,`ppmRate`,`CustomChance`,`Cooldown`) VALUES +(67698, 0, 0, 0, 0, 0, 0, 65536, 0, 0, 0), +(67752, 0, 0, 0, 0, 0, 0, 65536, 0, 0, 0); diff --git a/sql/updates/world/2016_02_07_10_world.sql b/sql/updates/world/2016_02_07_10_world.sql new file mode 100644 index 00000000000..c2e59c15d9c --- /dev/null +++ b/sql/updates/world/2016_02_07_10_world.sql @@ -0,0 +1,7 @@ +-- DB/Item: Bryntroll, the Bone Arbiter +UPDATE `item_template` SET `spellcooldown_1`=-1 WHERE `entry`=50415; +UPDATE `item_template` SET `spellppmRate_1`=2 WHERE `entry` IN (50415,50709); +DELETE FROM `spell_bonus_data` WHERE `entry` IN (71839,71838); +INSERT INTO `spell_bonus_data` (`entry`, `direct_bonus`, `dot_bonus`, `ap_bonus`, `ap_dot_bonus`, `comments`) VALUES +(71839,0,0,0,0,'Drain Life'), +(71838,0,0,0,0,'Drain Life'); diff --git a/sql/updates/world/2016_02_07_11_world.sql b/sql/updates/world/2016_02_07_11_world.sql new file mode 100644 index 00000000000..c40b663c205 --- /dev/null +++ b/sql/updates/world/2016_02_07_11_world.sql @@ -0,0 +1,29 @@ +-- +-- Razorthorn Ravager SAI +SET @ENTRY := 24922; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id` >=3; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,3,4,8,0,100,0,44935,0,0,0,69,0,0,0,0,0,0,20,187073,30,0,0,0,0,0,"Razorthorn Ravager - On Spellhit 'Expose Razorthorn Root' - Move To Closest Gameobject 'Razorthorn Dirt Mound'"), +(@ENTRY,0,4,5,61,0,100,0,44935,0,0,0,45,1,1,0,0,0,0,20,187073,30,0,0,0,0,0,"Razorthorn Ravager - On Spellhit 'Expose Razorthorn Root' - Set Data 1 1"), +(@ENTRY,0,5,0,61,0,100,0,44935,0,0,0,80,@ENTRY*100,2,0,0,0,0,1,0,0,0,0,0,0,0,"Razorthorn Ravager - On Spellhit 'Expose Razorthorn Root' - Run Script"); + +-- Actionlist SAI +SET @ENTRY := 2492200; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,9,0,0,0,0,100,0,3000,3000,0,0,11,44941,2,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Cast 'Summon Razorthorn Root'"); + +-- Razorthorn Dirt Mound SAI +SET @ENTRY := 187073; +UPDATE `gameobject_template` SET `AIName`="SmartGameObjectAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=1; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,1,0,0,38,0,100,0,1,1,0,0,80,18707300,2,0,0,0,0,1,0,0,0,0,0,0,0,"Razorthorn Dirt Mound - On Data Set 1 1 - Run Script"); + +-- Actionlist SAI +SET @ENTRY := 18707300; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,9,0,0,0,0,100,0,10,10,0,0,44,2,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Set Phase 2"), +(@ENTRY,9,1,0,0,0,100,0,120000,120000,0,0,44,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Set Phase 1"); diff --git a/sql/updates/world/2016_02_07_12_world.sql b/sql/updates/world/2016_02_07_12_world.sql new file mode 100644 index 00000000000..c85265d857d --- /dev/null +++ b/sql/updates/world/2016_02_07_12_world.sql @@ -0,0 +1,29 @@ +-- DB/Quest: Drop It then Rock It! +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry` IN (24640, 24015); + +DELETE FROM `smart_scripts` WHERE `entryorguid` IN (24640, 24015) AND `source_type`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid` IN (2464000, 24015*100) AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(24640, 0, 0, 0, 54, 0, 100, 0, 0, 0, 0, 0, 80, 2464000, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Alliance Banner - just summoned - Action list'), +(24640, 0, 1, 0, 0, 0, 100, 0, 1000, 1000, 2000, 2000, 19, 2048, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Alliance Banner - IC- remove unit flag'), +(24640, 0, 2, 0, 1, 0, 100, 0, 1000, 1000, 2000, 2000, 19, 2048, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Alliance Banner - OOC - remove unit flag'), +(2464000, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 8, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Alliance Banner - Action list - Set react passif'), +(2464000, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 103, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Alliance Banner - Action list - Set root'), +(2464000, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 102, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Alliance Banner - Action list - Set health regen off'), +(2464000, 9, 3, 0, 0, 0, 100, 0, 5000, 5000, 0, 0, 12, 24015, 4, 60000, 0, 1, 0, 8, 0, 0, 0, 1483.793091, -5352.790039, 192.023712, 1.431473, 'Alliance Banner - Action list - Summon Winterskorn Defender'), +(2464000, 9, 4, 0, 0, 0, 100, 0, 20000, 20000, 0, 0, 12, 24015, 4, 60000, 0, 1, 0, 8, 0, 0, 0, 1460.096436, -5342.498535, 195.991714, 0.339768, 'Alliance Banner - Action list - Summon Winterskorn Defender'), +(2464000, 9, 5, 0, 0, 0, 100, 0, 20000, 20000, 0, 0, 12, 24015, 4, 60000, 0, 1, 0, 8, 0, 0, 0, 1468.549561, -5300.886230, 195.633850, 5.760584, 'Alliance Banner - Action list - Summon Winterskorn Defender'), +(2464000, 9, 6, 0, 0, 0, 100, 0, 20000, 20000, 0, 0, 11, 44124, 0, 0, 0, 0, 0, 23, 0, 0, 0, 0, 0, 0, 0, 'Alliance Banner - Action list - Quest Credit'), +(2464000, 9, 7, 0, 0, 0, 100, 0, 100, 100, 0, 0, 41, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Alliance Banner - Action list - Despawn'), + +(24015, 0, 0, 0, 0, 0, 100, 0, 3000, 5000, 5000, 7000, 11, 15496, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0,0,'Winterskorn Defender - IC - Cast Cleave'), +(24015, 0, 1, 0, 0, 0, 100, 0, 5000, 10000, 10000, 15000, 11, 18812, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0,0,'Winterskorn Defender - IC - Cast Knockdown'), +(24015, 0, 2, 0, 54, 0, 100, 0, 0, 0, 0, 0, 80, 24015*100, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0,0,'Winterskorn Defender - Just sumoned - Action list'), +(24015*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Winterskorn Defender - Action list - Talk'), +(24015*100, 9, 1, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 69, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 1499.201538, -5319.049316, 195.300629, 0.451290, 'Winterskorn Defender - Action list - move to pos'); + +DELETE FROM `creature_text` WHERE `entry` IN (24015); +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES +(24015, 0, 0, 'Your remains will be fed TO the sharks of Daggercap!', 14, 0, 100, 0, 0, 0, 23619, 0, 'Winterskorn Defender'), +(24015, 0, 1, 'The sacrifices NOW bring themselves TO us? Have you NO sense!?', 14, 0, 100, 0, 0, 0, 23618, 0, 'Winterskorn Defender'), +(24015, 0, 2, 'You dare challenge Winterskorn?! I will impale you ON your own puny flag!', 14, 0, 100, 0, 0, 0, 23617, 0, 'Winterskorn Defender'); diff --git a/sql/updates/world/2016_02_07_13_world.sql b/sql/updates/world/2016_02_07_13_world.sql new file mode 100644 index 00000000000..612fef2274d --- /dev/null +++ b/sql/updates/world/2016_02_07_13_world.sql @@ -0,0 +1,413 @@ +DELETE FROM `creature_formations` WHERE `leaderGUID`=81531; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(81531, 81531, 0, 0, 1), +(81531, 81532, 2, 310, 2), +(81531, 81530, 2, 40, 2); + +-- Pathing for Sul'lithuz Sandcrawler Entry: 8095 'TDB FORMAT' +SET @NPC := 81531; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=1843.703,`position_y`=1193.693,`position_z`=9.399462 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1843.703,1193.693,9.399462,0,0,0,0,100,0), -- 09:47:28 +(@PATH,2,1853.01,1172.636,11.64427,0,0,0,0,100,0), -- 09:47:34 +(@PATH,3,1866.308,1173.398,9.788191,0,0,0,0,100,0), -- 09:47:39 +(@PATH,4,1872.583,1166.405,9.729328,0,0,0,0,100,0), -- 09:47:46 +(@PATH,5,1871.299,1156.692,10.96628,0,0,0,0,100,0), -- 09:47:47 +(@PATH,6,1871.138,1151.655,11.56361,0,0,0,0,100,0), -- 09:47:52 +(@PATH,7,1868.171,1128.227,15.75623,0,0,0,0,100,0), -- 09:47:54 +(@PATH,8,1867.59,1117.35,10.0786,0,0,0,0,100,0), -- 09:48:03 +(@PATH,9,1867.531,1112.539,9.42872,0,0,0,0,100,0), -- 09:48:08 +(@PATH,10,1869.916,1103.111,9.419256,0,0,0,0,100,0), -- 09:48:11 +(@PATH,11,1885.483,1101.25,12.69302,0,0,0,0,100,0), -- 09:48:15 +(@PATH,12,1895.659,1106.266,13.07423,0,0,0,0,100,0), -- 09:48:20 +(@PATH,13,1899.068,1114.828,11.51437,0,0,0,0,100,0), -- 09:48:24 +(@PATH,14,1897.243,1124.311,9.819095,0,0,0,0,100,0), -- 09:48:27 +(@PATH,15,1895.536,1129.667,9.065989,0,0,0,0,100,0), -- 09:48:32 +(@PATH,16,1892.813,1140.595,9.251789,0,0,0,0,100,0), -- 09:48:36 +(@PATH,17,1895.494,1145.588,9.251789,0,0,0,0,100,0), -- 09:48:38 +(@PATH,18,1912.283,1152.97,9.721882,0,0,0,0,100,0), -- 09:48:42 +(@PATH,19,1918.871,1158.545,10.8794,0,0,0,0,100,0), -- 09:48:45 +(@PATH,20,1920.596,1160.717,11.4007,0,0,0,0,100,0), -- 09:48:49 +(@PATH,21,1918.562,1168.737,10.45978,0,0,0,0,100,0), -- 09:48:51 +(@PATH,22,1911.641,1178.46,9.442093,0,0,0,0,100,0), -- 09:48:55 +(@PATH,23,1909.036,1182.083,9.251789,0,0,0,0,100,0), -- 09:48:59 +(@PATH,24,1902.43,1192.171,9.225698,0,0,0,0,100,0), -- 09:49:02 +(@PATH,25,1901.362,1201.077,9.209784,0,0,0,0,100,0), -- 09:49:06 +(@PATH,26,1904.497,1211.609,9.074608,0,0,0,0,100,0), -- 09:49:10 +(@PATH,27,1909.629,1219.002,9.34004,0,0,0,0,100,0), -- 09:49:13 +(@PATH,28,1893.508,1226.117,9.880462,0,0,0,0,100,0), -- 09:49:16 +(@PATH,29,1882.001,1223.113,9.380271,0,0,0,0,100,0), -- 09:49:20 +(@PATH,30,1874.822,1220.509,9.350756,0,0,0,0,100,0), -- 09:49:27 +(@PATH,31,1857.651,1200.784,9.280435,0,0,0,0,100,0), -- 09:49:33 +(@PATH,32,1856.005,1198.657,9.078081,0,0,0,0,100,0); -- 09:49:37 +-- 0x1C16F41A2007E7C00020100000370E69 .go 1843.703 1193.693 9.399462 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=81581; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(81581, 81581, 0, 0, 1), +(81581, 81583, 2, 310, 2), +(81581, 81582, 2, 40, 2); + +-- Pathing for Sul'lithuz Sandcrawler Entry: 8095 'TDB FORMAT' +SET @NPC := 81581; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=1675.997,`position_y`=1232.113,`position_z`=8.987229 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1675.997,1232.113,8.987229,0,0,0,0,100,0), -- 09:41:26 +(@PATH,2,1664.236,1222.652,9.116917,0,0,0,0,100,0), -- 09:41:35 +(@PATH,3,1652.006,1213.038,9.562586,0,0,0,0,100,0), -- 09:41:42 +(@PATH,4,1637.653,1203.694,9.001921,0,0,0,0,100,0), -- 09:41:48 +(@PATH,5,1629.32,1192.027,9.076674,0,0,0,0,100,0), -- 09:41:52 +(@PATH,6,1625.091,1172.658,10.96705,0,0,0,0,100,0), -- 09:41:57 +(@PATH,7,1626.96,1164.297,9.917568,0,0,0,0,100,0), -- 09:42:02 +(@PATH,8,1629.299,1156.629,9.361486,0,0,0,0,100,0), -- 09:42:07 +(@PATH,9,1636.125,1149.019,9.258444,0,0,0,0,100,0), -- 09:42:11 +(@PATH,10,1643.561,1144.494,9.247617,0,0,0,0,100,0), -- 09:42:13 +(@PATH,11,1655.12,1139.766,9.255368,0,0,0,0,100,0), -- 09:42:18 +(@PATH,12,1661.656,1140.804,9.253,0,0,0,0,100,0), -- 09:42:20 +(@PATH,13,1668.802,1147.428,9.253811,0,0,0,0,100,0), -- 09:42:24 +(@PATH,14,1676.315,1157.238,9.244503,0,0,0,0,100,0), -- 09:42:29 +(@PATH,15,1685.79,1169.683,9.239374,0,0,0,0,100,0), -- 09:42:34 +(@PATH,16,1692.607,1177.311,9.237229,0,0,0,0,100,0), -- 09:42:37 +(@PATH,17,1699.878,1182.912,9.244503,0,0,0,0,100,0), -- 09:42:41 +(@PATH,18,1713.954,1196.856,10.56152,0,0,0,0,100,0), -- 09:42:44 +(@PATH,19,1723.85,1206.719,12.34495,0,0,0,0,100,0), -- 09:42:49 +(@PATH,20,1727.292,1213.318,11.02762,0,0,0,0,100,0), -- 09:42:54 +(@PATH,21,1729.919,1225.602,9.878916,0,0,0,0,100,0), -- 09:42:57 +(@PATH,22,1731.314,1244.776,10.92413,0,0,0,0,100,0), -- 09:43:04 +(@PATH,23,1728.812,1260.437,12.06071,0,0,0,0,100,0), -- 09:43:10 +(@PATH,24,1727.822,1263.875,12.22826,0,0,0,0,100,0), -- 09:43:15 +(@PATH,25,1711.478,1264.379,11.21737,0,0,0,0,100,0), -- 09:43:20 +(@PATH,26,1713.401,1265.821,11.66045,0,0,0,0,100,0), -- 09:43:25 +(@PATH,27,1716.675,1267.497,11.77379,0,0,0,0,100,0), -- 09:43:28 +(@PATH,28,1729.911,1256.21,11.58052,0,0,0,0,100,0), -- 09:43:32 +(@PATH,29,1731.174,1235.849,10.49311,0,0,0,0,100,0), -- 09:43:38 +(@PATH,30,1731.024,1231.776,10.09937,0,0,0,0,100,0), -- 09:43:44 +(@PATH,31,1725.16,1208.78,11.51352,0,0,0,0,100,0), -- 09:43:50 +(@PATH,32,1720.919,1203.628,11.9393,0,0,0,0,100,0), -- 09:43:54 +(@PATH,33,1709.198,1192.878,9.553079,0,0,0,0,100,0), -- 09:43:57 +(@PATH,34,1706.149,1190.558,9.102777,0,0,0,0,100,0), -- 09:44:02 +(@PATH,35,1699.551,1182.485,9.240244,0,0,0,0,100,0), -- 09:44:06 +(@PATH,36,1692.22,1177.217,9.237229,0,0,0,0,100,0), -- 09:44:10 +(@PATH,37,1685.667,1169.501,9.244503,0,0,0,0,100,0), -- 09:44:13 +(@PATH,38,1675.968,1157.188,9.250818,0,0,0,0,100,0), -- 09:44:19 +(@PATH,39,1668.579,1147.053,9.257448,0,0,0,0,100,0), -- 09:44:23 +(@PATH,40,1661.406,1140.643,9.253025,0,0,0,0,100,0), -- 09:44:26 +(@PATH,41,1655.021,1139.765,9.252222,0,0,0,0,100,0), -- 09:44:29 +(@PATH,42,1643.208,1144.652,9.247617,0,0,0,0,100,0), -- 09:44:34 +(@PATH,43,1635.916,1149.401,9.287905,0,0,0,0,100,0), -- 09:44:37 +(@PATH,44,1626.234,1167.293,10.93676,0,0,0,0,100,0), -- 09:44:41 +(@PATH,45,1623.834,1178.643,9.497221,0,0,0,0,100,0), -- 09:44:45 +(@PATH,46,1623.34,1181.442,9.245241,0,0,0,0,100,0), -- 09:44:49 +(@PATH,47,1629.774,1192.288,9.232269,0,0,0,0,100,0), -- 09:44:54 +(@PATH,48,1637.901,1204.049,9.117538,0,0,0,0,100,0), -- 09:44:59 +(@PATH,49,1652.142,1213.244,9.560089,0,0,0,0,100,0), -- 09:45:05 +(@PATH,50,1664.489,1222.979,8.98844,0,0,0,0,100,0); -- 09:45:11 +-- 0x1C16F41A2007E7C00020100000370E6A .go 1675.997 1232.113 8.987229 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=81587; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(81587, 81587, 0, 0, 1), +(81587, 81601, 2, 310, 2), +(81587, 81588, 2, 40, 2); + +-- Pathing for Sul'lithuz Sandcrawler Entry: 8095 'TDB FORMAT' +SET @NPC := 81587; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=1600.69,`position_y`=1126.462,`position_z`=12.41756 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1600.69,1126.462,12.41756,0,0,0,0,100,0), -- 09:39:21 +(@PATH,2,1598.398,1122.63,11.59186,0,0,0,0,100,0), -- 09:39:26 +(@PATH,3,1593.572,1109.275,10.02831,0,0,0,0,100,0), -- 09:39:30 +(@PATH,4,1592.7,1107.054,9.462294,0,0,0,0,100,0), -- 09:39:33 +(@PATH,5,1588.454,1097.563,9.271156,0,0,0,0,100,0), -- 09:39:38 +(@PATH,6,1583.779,1087.09,9.251778,0,0,0,0,100,0), -- 09:39:42 +(@PATH,7,1577.599,1072.18,9.251631,0,0,0,0,100,0), -- 09:39:48 +(@PATH,8,1572.181,1059.509,9.217859,0,0,0,0,100,0), -- 09:39:53 +(@PATH,9,1566.106,1048.195,9.189631,0,0,0,0,100,0), -- 09:39:58 +(@PATH,10,1561.209,1038.885,9.217978,0,0,0,0,100,0), -- 09:40:01 +(@PATH,11,1554.598,1029.24,9.240252,0,0,0,0,100,0), -- 09:40:05 +(@PATH,12,1551.634,1018.51,9.219183,0,0,0,0,100,0), -- 09:40:10 +(@PATH,13,1564.537,989.8197,10.66319,0,0,0,0,100,0), -- 09:40:17 +(@PATH,14,1573.23,992.3699,9.814154,0,0,0,0,100,0), -- 09:40:23 +(@PATH,15,1585.951,1004.943,9.409527,0,0,0,0,100,0), -- 09:40:32 +(@PATH,16,1583.934,1017.611,9.291721,0,0,0,0,100,0), -- 09:40:36 +(@PATH,17,1570.175,1035.014,9.251503,0,0,0,0,100,0), -- 09:40:45 +(@PATH,18,1572.35,1046.109,9.251484,0,0,0,0,100,0), -- 09:40:48 +(@PATH,19,1579.434,1059.837,9.251631,0,0,0,0,100,0), -- 09:40:55 +(@PATH,20,1580.449,1072.369,9.251754,0,0,0,0,100,0), -- 09:40:59 +(@PATH,21,1584.936,1085.009,9.251778,0,0,0,0,100,0), -- 09:41:04 +(@PATH,22,1588.972,1094.886,9.251778,0,0,0,0,100,0), -- 09:41:08 +(@PATH,23,1596.379,1107.74,9.251778,0,0,0,0,100,0), -- 09:41:13 +(@PATH,24,1603.914,1114.008,9.251778,0,0,0,0,100,0), -- 09:41:16 +(@PATH,25,1613.207,1117.757,9.251778,0,0,0,0,100,0), -- 09:41:20 +(@PATH,26,1622.645,1121.169,9.251778,0,0,0,0,100,0), -- 09:41:24 +(@PATH,27,1626.143,1131.002,9.106209,0,0,0,0,100,0), -- 09:41:27 +(@PATH,28,1613.163,1134.797,10.02532,0,0,0,0,100,0); -- 09:41:31 +-- 0x1C16F41A2007E7C00020100000B70E69 .go 1600.69 1126.462 12.41756 + +-- Pathing for Sandfury Blood Drinker Entry: 5649 'TDB FORMAT' +SET @NPC := 45709; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=1617.601,`position_y`=983.7964,`position_z`=9.916536 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1617.601,983.7964,9.916536,0,0,0,0,100,0), -- 09:32:38 +(@PATH,2,1633.528,955.7834,9.235924,0,0,0,0,100,0), -- 09:32:59 +(@PATH,3,1648.17,936.5194,9.250045,0,0,0,0,100,0), -- 09:33:09 +(@PATH,4,1676.1,915.9411,9.25178,0,0,0,0,100,0), -- 09:33:22 +(@PATH,5,1688.716,903.3527,9.251783,0,0,0,0,100,0), -- 09:33:29 +(@PATH,6,1688.836,903.3895,9.001781,0,0,0,0,100,0), -- 09:33:39 +(@PATH,7,1688.783,903.5739,9.251781,0,0,0,0,100,0), -- 09:33:45 +(@PATH,8,1675.767,916.0085,9.251778,0,0,0,0,100,0), -- 09:33:52 +(@PATH,9,1647.774,936.6549,9.231987,0,0,0,0,100,0), -- 09:34:05 +(@PATH,10,1633.304,956.1119,9.007839,0,0,0,0,100,0); -- 09:34:15 +-- 0x1C16F41A200584400020100000B70E69 .go 1617.601 983.7964 9.916536 + +DELETE FROM `creature_formations` WHERE `leaderGUID`=44170; +INSERT INTO `creature_formations` (`leaderGUID`, `memberGUID`, `dist`, `angle`, `groupAI`) VALUES +(44170, 44170, 0, 0, 1), +(44170, 44177, 4, 0, 2); + +-- Pathing for Sandfury Shadowhunter Entry: 7246 'TDB FORMAT' +SET @NPC := 44170; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=1655.273,`position_y`=905.2343,`position_z`=9.25178 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1655.273,905.2343,9.25178,0,0,0,0,100,0), -- 09:33:10 +(@PATH,2,1655.911,899.7297,9.251781,0,0,0,0,100,0), -- 09:33:13 +(@PATH,3,1659.89,895.1904,9.251783,0,0,0,0,100,0), -- 09:33:15 +(@PATH,4,1666.527,892.6587,9.251785,0,0,0,0,100,0), -- 09:33:19 +(@PATH,5,1671.451,893.4264,9.251785,0,0,0,0,100,0), -- 09:33:20 +(@PATH,6,1677.89,896.6896,9.251787,0,0,0,0,100,0), -- 09:33:24 +(@PATH,7,1682.431,897.1668,9.251787,0,0,0,0,100,0), -- 09:33:25 +(@PATH,8,1687.213,895.057,9.251787,0,0,0,0,100,0), -- 09:33:27 +(@PATH,9,1691.418,891.8385,9.251787,0,0,0,0,100,0), -- 09:33:30 +(@PATH,10,1707.106,892.9658,9.001792,0,0,0,0,100,0), -- 09:33:35 +(@PATH,11,1707.17,893.1018,9.251791,0,0,0,0,100,0), -- 09:33:37 +(@PATH,12,1707.188,899.764,9.251793,0,0,0,0,100,0), -- 09:33:41 +(@PATH,13,1705.826,907.7333,9.051537,0,0,0,0,100,0), -- 09:33:43 +(@PATH,14,1696.466,915.4108,10.69149,0,0,0,0,100,0), -- 09:33:45 +(@PATH,15,1695.094,916.186,11.46166,0,0,0,0,100,0), -- 09:33:49 +(@PATH,16,1684.856,919.5836,10.99732,0,0,0,0,100,0), -- 09:33:51 +(@PATH,17,1683.066,920.494,10.5781,0,0,0,0,100,0), -- 09:33:54 +(@PATH,18,1674.156,923.7375,10.20567,0,0,0,0,100,0), -- 09:33:57 +(@PATH,19,1664.302,928.6282,9.453308,0,0,0,0,100,0), -- 09:34:00 +(@PATH,20,1661.029,929.8394,9.146419,0,0,0,0,100,0), -- 09:34:04 +(@PATH,21,1655.01,926.2007,9.26087,0,0,0,0,100,0), -- 09:34:07 +(@PATH,22,1652.682,919.4923,9.257462,0,0,0,0,100,0), -- 09:34:10 +(@PATH,23,1651.4,910.429,9.254412,0,0,0,0,100,0), -- 09:34:13 +(@PATH,24,1647.536,904.8036,9.126776,0,0,0,0,100,0), -- 09:34:16 +(@PATH,25,1644.714,900.452,9.315964,0,0,0,0,100,0), -- 09:34:18 +(@PATH,26,1643.629,893.2144,9.066956,0,0,0,0,100,0), -- 09:34:21 +(@PATH,27,1647.002,888.5004,9.251783,0,0,0,0,100,0), -- 09:34:23 +(@PATH,28,1653.137,885.6685,9.281507,0,0,0,0,100,0), -- 09:34:26 +(@PATH,29,1662.074,885.7325,10.57716,0,0,0,0,100,0), -- 09:34:29 +(@PATH,30,1671.613,886.2659,10.16994,0,0,0,0,100,0), -- 09:34:32 +(@PATH,31,1674.008,886.346,9.495081,0,0,0,0,100,0), -- 09:34:35 +(@PATH,32,1681.862,881.2953,9.280839,0,0,0,0,100,0), -- 09:34:39 +(@PATH,33,1685.906,877.4709,9.251787,0,0,0,0,100,0), -- 09:34:41 +(@PATH,34,1691.133,874.519,9.251787,0,0,0,0,100,0), -- 09:34:44 +(@PATH,35,1698.035,875.4692,9.251789,0,0,0,0,100,0), -- 09:34:46 +(@PATH,36,1701.057,884.8716,9.251791,0,0,0,0,100,0), -- 09:34:50 +(@PATH,37,1700.372,888.9851,9.251789,0,0,0,0,100,0), -- 09:34:52 +(@PATH,38,1697.707,894.2527,9.251787,0,0,0,0,100,0), -- 09:34:55 +(@PATH,39,1695.577,900.1669,9.251783,0,0,0,0,100,0), -- 09:34:57 +(@PATH,40,1691.47,905.3853,9.251781,0,0,0,0,100,0), -- 09:34:59 +(@PATH,41,1685.541,907.8835,9.251781,0,0,0,0,100,0), -- 09:35:02 +(@PATH,42,1677.038,912.5565,9.251781,0,0,0,0,100,0), -- 09:35:06 +(@PATH,43,1673.069,915.2619,9.251778,0,0,0,0,100,0), -- 09:35:08 +(@PATH,44,1663.253,918.3373,9.251777,0,0,0,0,100,0), -- 09:35:12 +(@PATH,45,1657.931,912.8817,9.251776,0,0,0,0,100,0); -- 09:35:15 +-- 0x1C16F41A200713800020100003B70E69 .go 1655.273 905.2343 9.25178 + +UPDATE `creature` SET `id`=7246 WHERE `guid`=81449; + +-- Pathing for Sandfury Shadowhunter Entry: 7246 'TDB FORMAT' +SET @NPC := 81449; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=1714.547,`position_y`=751.6357,`position_z`=31.01397 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1714.547,751.6357,31.01397,0,0,0,0,100,0), -- 09:33:36 +(@PATH,2,1706.419,767.5251,20.53269,0,0,0,0,100,0), -- 09:33:47 +(@PATH,3,1713.905,783.2459,18.27732,0,0,0,0,100,0), -- 09:33:56 +(@PATH,4,1736.666,804.5889,19.37791,0,0,0,0,100,0), -- 09:34:06 +(@PATH,5,1756.694,816.8251,17.76507,0,0,0,0,100,0), -- 09:34:16 +(@PATH,6,1777.771,811.2102,24.82411,0,0,0,0,100,0), -- 09:34:28 +(@PATH,7,1798.088,809.4211,17.09367,0,0,0,0,100,0), -- 09:34:38 +(@PATH,8,1799.94,798.6746,14.59042,0,0,0,0,100,0), -- 09:34:46 +(@PATH,9,1796.858,772.2805,14.40658,0,0,0,0,100,0), -- 09:34:55 +(@PATH,10,1795.703,767.491,14.4094,0,0,0,0,100,0), -- 09:35:03 +(@PATH,11,1783.244,740.9023,16.0862,0,0,0,0,100,0), -- 09:35:12 +(@PATH,12,1753.258,723.8399,20.43831,0,0,0,0,100,0), -- 09:35:20 +(@PATH,13,1739.673,704.8474,24.96986,0,0,0,0,100,0), -- 09:35:30 +(@PATH,14,1732.086,695.3857,29.82811,0,0,0,0,100,0), -- 09:35:41 +(@PATH,15,1730.985,682.3048,37.22635,0,0,0,0,100,0), -- 09:35:46 +(@PATH,16,1730.52,664.7642,46.17672,0,0,0,0,100,0), -- 09:35:52 +(@PATH,17,1730.83,680.5409,37.68767,0,0,0,0,100,0), -- 09:36:01 +(@PATH,18,1730.119,692.5168,32.08631,0,0,0,0,100,0), -- 09:36:09 +(@PATH,19,1737.599,702.1305,26.13027,0,0,0,0,100,0), -- 09:36:14 +(@PATH,20,1749.973,719.9585,21.75875,0,0,0,0,100,0), -- 09:36:18 +(@PATH,21,1770.449,731.5471,16.75012,0,0,0,0,100,0), -- 09:36:29 +(@PATH,22,1787.836,744.8066,15.48635,0,0,0,0,100,0), -- 09:36:39 +(@PATH,23,1790.129,746.8105,14.82397,0,0,0,0,100,0), -- 09:36:48 +(@PATH,24,1800.35,786.1299,15.01233,0,0,0,0,100,0), -- 09:36:56 +(@PATH,25,1799.381,808.5591,16.25235,0,0,0,0,100,0), -- 09:37:05 +(@PATH,26,1784.557,809.4543,26.70631,0,0,0,0,100,0), -- 09:37:13 +(@PATH,27,1768.491,817.0541,16.94501,0,0,0,0,100,0), -- 09:37:22 +(@PATH,28,1740.522,807.2539,18.77644,0,0,0,0,100,0), -- 09:37:32 +(@PATH,29,1719.27,792.5435,17.62323,0,0,0,0,100,0), -- 09:37:44 +(@PATH,30,1707.021,770.4479,18.85983,0,0,0,0,100,0); -- 09:37:53 +-- 0x1C16F41A200713800020100003B70E6B .go 1714.547 751.6357 31.01397 + +-- Pathing for Hydromancer Velratha Entry: 7795 'TDB FORMAT' +SET @NPC := 81570; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=1680.114,`position_y`=1177.732,`position_z`=8.987229 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1680.114,1177.732,8.987229,2.303835,0,0,0,100,0), -- 09:34:01 +(@PATH,2,1700.927,1195.028,9.603146,0,0,0,0,100,0), -- 09:34:01 +(@PATH,3,1707.2,1200.687,9.403647,0,0,0,0,100,0), -- 09:34:14 +(@PATH,4,1692.938,1213.952,8.987229,3.909538,0,0,0,100,0), -- 09:34:23 +(@PATH,5,1680.51,1225.099,8.987229,0,0,0,0,100,0), -- 09:34:42 +(@PATH,6,1680.468,1225.099,9.265305,0,0,0,0,100,0), -- 09:34:48 +(@PATH,7,1660.3,1205.108,9.04338,5.5676,0,0,0,100,0), -- 09:35:00 +(@PATH,8,1681.249,1229.22,8.987229,0,0,0,0,100,0), -- 09:35:00 +(@PATH,9,1701.589,1207.354,9.564609,0,0,0,0,100,0), -- 09:35:12 +(@PATH,10,1694.085,1190.304,9.394554,0,0,0,0,100,0); -- 09:35:27 +-- 0x1C16F41A20079CC00020100000370E68 .go 1680.114 1177.732 8.987229 + +UPDATE `creature` SET `id`=5650 WHERE `guid`=81575; +UPDATE `creature` SET `id`=5649 WHERE `guid`=81623; + +-- Pathing for Sandfury Blood Drinker Entry: 5649 'TDB FORMAT' +SET @NPC := 81623; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=1467.867,`position_y`=814.7855,`position_z`=9.265823 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1467.867,814.7855,9.265823,0,0,0,0,100,0), -- 09:33:47 +(@PATH,2,1487.211,800.545,9.218481,0,0,0,0,100,0), -- 09:33:56 +(@PATH,3,1511.808,811.0946,9.178488,0,0,0,0,100,0), -- 09:34:07 +(@PATH,4,1515.796,829.2292,9.161482,0,0,0,0,100,0), -- 09:34:16 +(@PATH,5,1536.178,831.7927,8.960844,0,0,0,0,100,0), -- 09:34:23 +(@PATH,6,1571.074,854.2294,9.261095,0,0,0,0,100,0), -- 09:34:40 +(@PATH,7,1591.516,871.9385,9.265827,0,0,0,0,100,0), -- 09:34:51 +(@PATH,8,1607.848,876.8568,9.265826,0,0,0,0,100,0), -- 09:34:58 +(@PATH,9,1607.711,876.7318,9.015826,0,0,0,0,100,0), -- 09:35:10 +(@PATH,10,1607.748,876.855,9.265827,0,0,0,0,100,0), -- 09:35:19 +(@PATH,11,1591.351,871.8887,9.265827,0,0,0,0,100,0), -- 09:35:26 +(@PATH,12,1570.754,854.1002,9.208826,0,0,0,0,100,0), -- 09:35:37 +(@PATH,13,1535.719,831.4611,9.164757,0,0,0,0,100,0), -- 09:35:54 +(@PATH,14,1515.512,828.9963,9.170406,0,0,0,0,100,0), -- 09:36:03 +(@PATH,15,1511.881,810.6445,8.968481,0,0,0,0,100,0), -- 09:36:10 +(@PATH,16,1486.829,800.4541,9.261948,0,0,0,0,100,0); -- 09:36:21 +-- 0x1C16F41A200584400020100004370E69 .go 1467.867 814.7855 9.265823 + +-- Update spawn distance & movementype so they move around randomly +UPDATE `creature` SET `spawndist`=10, `MovementType`=1 WHERE `guid` IN (81566, 81569, 81580, 81568, 81597, 81598, 81539, 81538, 81542, 81548, 81551, 45710, 81482, 81517, 81515, 81518, 81468, 81452, 81579, 81460, 81461, 81512, 81516); + +UPDATE `creature` SET `id`=5650 WHERE `guid`=81578; + +-- Pathing for Sandfury Witch Doctor Entry: 5650 'TDB FORMAT' +SET @NPC := 81578; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=1676.368,`position_y`=1157.151,`position_z`=9.249697 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1676.368,1157.151,9.249697,0,0,0,0,100,0), -- 13:40:40 +(@PATH,2,1653.736,1135.86,9.245178,0,0,0,0,100,0), -- 13:40:52 +(@PATH,3,1626.023,1177.506,9.271156,0,0,0,0,100,0), -- 13:41:05 +(@PATH,4,1625.849,1178.628,9.327552,0,0,0,0,100,0), -- 13:41:14 +(@PATH,5,1641.739,1209.753,9.657928,0,0,0,0,100,0), -- 13:41:25 +(@PATH,6,1681.225,1250.528,10.47596,0,0,0,0,100,0), -- 13:41:38 +(@PATH,7,1696.953,1250.462,10.17584,0,0,0,0,100,0), -- 13:41:54 +(@PATH,8,1714.498,1240.271,9.738787,0,0,0,0,100,0), -- 13:42:06 +(@PATH,9,1717.624,1219.73,9.457044,0,0,0,0,100,0), -- 13:42:15 +(@PATH,10,1704.706,1187.339,9.265233,0,0,0,0,100,0); -- 13:42:29 +-- 0x1C16F41A2005848000491D0001B743F7 .go 1676.368 1157.151 9.249697 + +-- Pathing for Sandfury Witch Doctor Entry: 5650 'TDB FORMAT' +SET @NPC := 81526; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=1879.829,`position_y`=1016.147,`position_z`=9.251789 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1879.829,1016.147,9.251789,0,0,0,0,100,0), -- 13:59:01 +(@PATH,2,1866.291,1028.589,9.251736,0,0,0,0,100,0), -- 13:59:23 +(@PATH,3,1853.719,1035.176,9.251698,0,0,0,0,100,0), -- 13:59:28 +(@PATH,4,1847.862,1044.768,9.251684,0,0,0,0,100,0), -- 13:59:33 +(@PATH,5,1853.86,1062.672,9.252108,0,0,0,0,100,0), -- 13:59:40 +(@PATH,6,1870.639,1091.271,9.252114,0,0,0,0,100,0), -- 13:59:53 +(@PATH,7,1875.563,1107.849,9.25185,0,0,0,0,100,0), -- 14:00:00 +(@PATH,8,1890.563,1129.902,9.251789,0,0,0,0,100,0), -- 14:00:11 +(@PATH,9,1888.277,1155.863,9.251789,0,0,0,0,100,0), -- 14:00:21 +(@PATH,10,1895.958,1173.92,9.251789,0,0,0,0,100,0), -- 14:00:30 +(@PATH,11,1903.501,1197.795,9.251789,0,0,0,0,100,0), -- 14:00:39 +(@PATH,12,1899.594,1215.067,9.227224,0,0,0,0,100,0), -- 14:00:47 +(@PATH,13,1899.237,1214.72,9.001789,0,0,0,0,100,0), -- 14:00:57 +(@PATH,14,1899.508,1214.759,9.285032,0,0,0,0,100,0), -- 14:01:05 +(@PATH,15,1903.433,1197.489,9.251789,0,0,0,0,100,0), -- 14:01:12 +(@PATH,16,1895.648,1173.515,9.251789,0,0,0,0,100,0), -- 14:01:22 +(@PATH,17,1888.245,1155.736,9.251789,0,0,0,0,100,0), -- 14:01:30 +(@PATH,18,1890.73,1129.828,9.25179,0,0,0,0,100,0), -- 14:01:40 +(@PATH,19,1875.201,1107.714,9.25216,0,0,0,0,100,0), -- 14:01:51 +(@PATH,20,1870.43,1091.029,9.252037,0,0,0,0,100,0), -- 14:01:58 +(@PATH,21,1853.549,1062.582,9.251722,0,0,0,0,100,0), -- 14:02:12 +(@PATH,22,1847.7,1044.523,9.251684,0,0,0,0,100,0), -- 14:02:19 +(@PATH,23,1853.871,1034.924,9.251736,0,0,0,0,100,0), -- 14:02:24 +(@PATH,24,1866.429,1028.186,9.251782,0,0,0,0,100,0); -- 14:02:30 +-- 0x1C16F41A2005848000491D0001B743F4 .go 1879.829 1016.147 9.251789 + +UPDATE `creature` SET `id`=5649 WHERE `guid`=81505; + +-- Pathing for Sandfury Blood Drinker Entry: 5649 'TDB FORMAT' +SET @NPC := 81505; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=1822.724,`position_y`=914.1884,`position_z`=9.001788 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,1822.724,914.1884,9.001788,0,0,0,0,100,0), -- 13:59:35 +(@PATH,2,1829.56,924.1556,9.251788,0,0,0,0,100,0), -- 13:59:41 +(@PATH,3,1837.984,936.5698,9.251788,0,0,0,0,100,0), -- 13:59:47 +(@PATH,4,1844.23,947.9322,9.251788,0,0,0,0,100,0), -- 13:59:53 +(@PATH,5,1853.508,963.5331,9.251788,0,0,0,0,100,0), -- 14:00:00 +(@PATH,6,1858.897,971.714,9.251788,0,0,0,0,100,0), -- 14:00:04 +(@PATH,7,1862.767,977.868,9.251788,0,0,0,0,100,0), -- 14:00:06 +(@PATH,8,1862.533,977.6647,9.001788,0,0,0,0,100,0), -- 14:00:13 +(@PATH,9,1862.49,977.5964,9.251788,0,0,0,0,100,0), -- 14:00:17 +(@PATH,10,1858.673,971.532,9.251788,0,0,0,0,100,0), -- 14:00:19 +(@PATH,11,1853.258,963.3405,9.251788,0,0,0,0,100,0), -- 14:00:24 +(@PATH,12,1844.16,947.6928,9.251788,0,0,0,0,100,0), -- 14:00:32 +(@PATH,13,1837.749,936.4601,9.251788,0,0,0,0,100,0), -- 14:00:36 +(@PATH,14,1829.292,923.94,9.251788,0,0,0,0,100,0); -- 14:00:43 +-- 0x1C16F41A2005844000491D00033743F5 .go 1822.724 914.1884 9.001788 diff --git a/sql/updates/world/2016_02_07_14_world.sql b/sql/updates/world/2016_02_07_14_world.sql new file mode 100644 index 00000000000..6550e53f9c9 --- /dev/null +++ b/sql/updates/world/2016_02_07_14_world.sql @@ -0,0 +1,55 @@ +-- An end to the suffering +UPDATE `creature_template` SET `unit_flags`=33536 WHERE `entry`=28416; +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry` =28416; +DELETE FROM `smart_scripts` WHERE `entryorguid`=28416 AND `source_type`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid`=2841600 AND `source_type`=9; + +DELETE FROM `smart_scripts` WHERE `entryorguid` IN(-113558,-113482,-113483,-113481) AND `source_type`=0; + +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(-113558, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 11, 51607, 0, 0, 0, 0, 0, 10, 95460, 28416, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Data Set - Cast \'Rhunok\'s Chains\''), +(-113558, 0, 1, 0, 38, 0, 100, 0, 2, 2, 0, 0, 92, 0, 51607, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Data Set - Remove Aura \'Rhunok\'s Chains\''), +(-113558, 0, 2, 0, 1, 0, 100, 1, 5000, 5000, 0, 0, 11, 51607, 0, 0, 0, 0, 0, 10, 95460, 28416, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Spawn - Cast \'Rhunok\'s Chains\''), +(-113482, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 11, 51607, 0, 0, 0, 0, 0, 10, 95460, 28416, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Data Set - Cast \'Rhunok\'s Chains\''), +(-113482, 0, 1, 0, 38, 0, 100, 0, 2, 2, 0, 0, 92, 0, 51607, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Data Set - Remove Aura \'Rhunok\'s Chains\''), +(-113482, 0, 2, 0, 1, 0, 100, 1, 5000, 5000, 0, 0, 11, 51607, 0, 0, 0, 0, 0, 10, 95460, 28416, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Spawn - Cast \'Rhunok\'s Chains\''), +(-113483, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 11, 51607, 0, 0, 0, 0, 0, 10, 95460, 28416, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Data Set - Cast \'Rhunok\'s Chains\''), +(-113483, 0, 1, 0, 38, 0, 100, 0, 2, 2, 0, 0, 92, 0, 51607, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Data Set - Remove Aura \'Rhunok\'s Chains\''), +(-113483, 0, 2, 0, 1, 0, 100, 1, 5000, 5000, 0, 0, 11, 51607, 0, 0, 0, 0, 0, 10, 95460, 28416, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Spawn - Cast \'Rhunok\'s Chains\''), +(-113481, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 11, 51607, 0, 0, 0, 0, 0, 10, 95460, 28416, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Data Set - Cast \'Rhunok\'s Chains\''), +(-113481, 0, 1, 0, 38, 0, 100, 0, 2, 2, 0, 0, 92, 0, 51607, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Data Set - Remove Aura \'Rhunok\'s Chains\''), +(-113481, 0, 2, 0, 1, 0, 100, 1, 5000, 5000, 0, 0, 11, 51607, 0, 0, 0, 0, 0, 10, 95460, 28416, 0, 0, 0, 0, 0, 'ELM General Purpose Bunny (scale x0.01) Large - On Spawn - Cast \'Rhunok\'s Chains\''), +(28416, 0, 0, 1, 25, 0, 100, 0, 0, 0, 0, 0, 18, 768, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Rhunok - On Reset - Set Unit Flags'), +(28416, 0, 1, 2, 61, 0, 100, 0, 0, 0, 0, 0, 90, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Rhunok - On Reset - Set Bytes 1'), +(28416, 0, 2, 3, 61, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 113558, 26298, 0, 0, 0, 0, 0, 'Rhunok - On Reset - Set Data on ELM General Purpose Bunny (scale x0.01) Large'), +(28416, 0, 3, 4, 61, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 113482, 26298, 0, 0, 0, 0, 0, 'Rhunok - On Reset - Set Data on ELM General Purpose Bunny (scale x0.01) Large'), +(28416, 0, 4, 5, 61, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 113481, 26298, 0, 0, 0, 0, 0, 'Rhunok - On Reset - Set Data on ELM General Purpose Bunny (scale x0.01) Large'), +(28416, 0, 5, 0, 61, 0, 100, 0, 0, 0, 0, 0, 45, 1, 1, 0, 0, 0, 0, 10, 113483, 26298, 0, 0, 0, 0, 0, 'Rhunok - On Reset - Set Data on ELM General Purpose Bunny (scale x0.01) Large'), +(28416, 0, 6, 7, 8, 0, 100, 0, 51964, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, 113558, 26298, 0, 0, 0, 0, 0, 'Rhunok - Spellhit - Set Data on ELM General Purpose Bunny (scale x0.01) Large'), -- 17:16:47.641 +(28416, 0, 7, 8, 61, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, 113481, 26298, 0, 0, 0, 0, 0, 'Rhunok - Spellhit - Set Data on ELM General Purpose Bunny (scale x0.01) Large'), +(28416, 0, 8, 9, 61, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, 113482, 26298, 0, 0, 0, 0, 0, 'Rhunok - Spellhit - Set Data on ELM General Purpose Bunny (scale x0.01) Large'), +(28416, 0, 9, 10, 61, 0, 100, 0, 0, 0, 0, 0, 45, 2, 2, 0, 0, 0, 0, 10, 113483, 26298, 0, 0, 0, 0, 0, 'Rhunok - Spellhit - Set Data on ELM General Purpose Bunny (scale x0.01) Large'), +(28416, 0, 10, 0, 61, 0, 100, 0, 0, 0, 0, 0, 80, 2841600, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Rhunok - Spellhit - Run Script'), +(28416, 0, 11, 0, 9, 0, 100, 0, 0, 5, 1000, 5000, 11, 34298, 2, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Rhunok - On Range - Cast Maul'), +(28416, 0, 12, 0, 2, 0, 100, 1, 0, 25, 0, 0, 11, 57861, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Rhunok - On 25% HP - Cast Roar of Rhunok'), +(28416, 0, 13, 0, 8, 0, 100, 0, 51603, 0, 0, 0, 4, 477, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Rhunok - On Spellhit - Play Sound'), +(2841600, 9, 0, 0, 0, 0, 100, 0, 1000, 1000, 0, 0, 91, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Rhunok - Script - Remove Bytes 1'), +(2841600, 9, 1, 0, 0, 0, 100, 0, 3000, 3000, 0, 0, 66, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Rhunok - Script - Face Invoker'), +(2841600, 9, 2, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 45111, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Rhunok - Script - Cast Enrage'), +(2841600, 9, 3, 0, 0, 0, 100, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Rhunok - Script - Say'), +(2841600, 9, 4, 0, 0, 0, 100, 0, 4000, 4000, 0, 0, 19, 768, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Rhunok - Script - Remove Unit Flags'), +(2841600, 9, 5, 0, 0, 0, 100, 0, 0, 0, 0, 0, 49, 0, 0, 0, 0, 0, 0, 21, 50, 0, 0, 0, 0, 0, 0, 'Rhunok - Script - Start Attack'); + +DELETE FROM `creature_text` WHERE `entry`=28416; +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `BroadcastTextID`, `comment`) VALUES +(28416, 0, 0, 'I will not simply lay here and allow you to slay me! You will have to earn your right to draw another breath if you want to kill me, mortal!', 14, 0, 100, 0, 0, 478, 28544, 'Rhunok to Player'); + +DELETE FROM `disables` WHERE `sourceType`=0 AND `entry`=51964; +INSERT INTO `disables` (`sourceType`, `entry`, `flags`, `params_0`, `params_1`, `comment`) VALUES +(0, 51964, 64, '', '', 'Ignore LOS on Tormentor''s Incense'); +-- Catching up with Brann linking +UPDATE quest_template_addon SET PrevQuestID = 12917 WHERE ID = 12920; +-- Valkyrion Must Burn +DELETE FROM `smart_scripts` WHERE `entryorguid` IN (30066) AND `source_type`=0 AND `id`=1 ; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(30066,0,1,0,28,0,100,0,0,0,0,0,81,16777216,0,0,0,0,0,1,0,0,0,0,0,0,0, 'Valkyrion Harpoon Gun - On Passenger Dismounted - Set NPC Flags'); diff --git a/sql/updates/world/2016_02_07_15_world.sql b/sql/updates/world/2016_02_07_15_world.sql new file mode 100644 index 00000000000..ceec02f881b --- /dev/null +++ b/sql/updates/world/2016_02_07_15_world.sql @@ -0,0 +1,175 @@ +SET @Guid := 52030; + +DELETE FROM `creature` WHERE `id` IN(37964,37981,36817); +INSERT INTO `creature` (`guid`, `id`, `map`, `zoneId`, `areaId`, `spawnMask`, `phaseMask`, `modelid`, `equipment_id`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `currentwaypoint`, `curhealth`, `curmana`, `MovementType`, `npcflag`, `unit_flags`, `dynamicflags`, `VerifiedBuild`) VALUES +(@Guid, 37964, 0, 0, 0, 1, 1, 0, 0, 1484.662, 348.019, -64.54687, 0.8377581, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@Guid+1, 37981, 1, 0, 0, 1, 1, 0, 0, 9843.134, 2430.733, 1313.6, 5.5676, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0), +(@Guid+2, 36817, 0, 0, 0, 1, 1, 0, 0, -8796.021, 775.0364, 95.22309, 0.01745329, 120, 0, 0, 1, 0, 0, 0, 0, 0, 0); + +DELETE FROM `game_event_creature` WHERE `eventEntry`=8 AND `guid` BETWEEN @Guid AND @Guid+2; +INSERT INTO `game_event_creature` (`eventEntry`, `guid`) VALUES +(8, @Guid), +(8, @Guid+1), +(8, @Guid+2); + +UPDATE `creature_template` SET `InhabitType`=4,`npcflag`=16777216,`VehicleId`=616,`IconName`='vehichleCursor' WHERE `entry` =37966; +UPDATE `creature_template` SET `InhabitType`=4,`npcflag`=16777216,`VehicleId`=615,`IconName`='vehichleCursor' WHERE `entry` =37980; +UPDATE `creature_template` SET `InhabitType`=4,`npcflag`=16777216,`VehicleId`=548,`IconName`='vehichleCursor' WHERE `entry`=36812; + +UPDATE `creature_template` SET `ainame`='SmartAI', `scriptname`='' WHERE `entry` IN(37966,37964,37981,37980,36817,36812); + +DELETE FROM `smart_scripts` WHERE `entryorguid` IN(37966,37964,37980,37981,36817,36812) AND `source_type`=0; + +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(37964, 0, 0, 0, 1, 0, 100, 0, 0, 0, 20000, 20000, 11, 70846, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, '[DND] Love Boat Summoner 02 - OOC - Cast Love Boat Summon'), +(37981, 0, 0, 0, 1, 0, 100, 0, 0, 0, 20000, 20000, 11, 70863, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, '[DND] Love Boat Summoner 03 - OOC - Cast Love Boat Summon'), +(36817, 0, 0, 0, 1, 0, 100, 0, 0, 0, 20000, 20000, 11, 69371, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, '[DND] Love Boat Summoner - OOC - Cast Love Boat Summon'), +(37964, 0, 1, 0, 11, 0, 100, 0, 0, 0, 0, 0, 48, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, '[DND] Love Boat Summoner 02 - On Spawn - Set Active'), +(37981, 0, 1, 0, 11, 0, 100, 0, 0, 0, 0, 0, 48, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, '[DND] Love Boat Summoner 03 - On Spawn - Set Active'), +(36817, 0, 1, 0, 11, 0, 100, 0, 0, 0, 0, 0, 48, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, '[DND] Love Boat Summoner - On Spawn - Set Active'), +(37966, 0, 0, 0, 1, 0, 100, 1, 5000, 5000, 0, 0, 53, 0, 37966, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undercity Love Boat - OOC - Start WP'), +(37966, 0, 1, 2, 40, 0, 100, 0, 31, 37966, 0, 0, 11, 50630, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undercity Love Boat - On Reached WP31 - Cast Eject All Passengers'), +(37966, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 2000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undercity Love Boat - On Reached WP31 - Despawn'), +(37966, 0, 3, 4, 54, 0, 100, 0, 0, 0, 0, 0, 11, 70143, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undercity Love Boat - On Just Summoned - Cast Vehicle Test'), +(37966, 0, 4, 0, 61, 0, 100, 0, 0, 0, 0, 0, 48, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undercity Love Boat - On Just Summoned - Set Active'), +(37966, 0, 5, 0, 1, 0, 100, 0, 0, 0, 3000, 3000, 75, 69341, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undercity Love Boat - OOC - Cast Love Boat'), +(37966, 0, 6, 0, 23, 0, 100, 0, 69342, 2, 1000, 1000, 75, 62011, 0, 0, 0, 0, 0, 17, 0, 20, 0, 0, 0, 0, 0, 'Undercity Love Boat - On Has Aura (2) - Add Aura'), +(37966, 0, 7, 0, 28, 0, 100, 0, 0, 0, 0, 0, 28, 62011, 0, 0, 0, 0, 0, 17, 0, 20, 0, 0, 0, 0, 0, 'Undercity Love Boat - On Passenger Dismounted - Remove Aura'), +(37980, 0, 0, 0, 1, 0, 100, 1, 5000, 5000, 0, 0, 53, 0, 37980, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Darnassus Love Boat - OOC - Start WP'), +(37980, 0, 1, 2, 40, 0, 100, 0, 60, 37980, 0, 0, 11, 50630, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Darnassus Love Boat - On Reached WP60 - Cast Eject All Passengers'), +(37980, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 2000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Darnassus Love Boat - On Reached WP31 - Despawn'), +(37980, 0, 3, 4, 54, 0, 100, 0, 0, 0, 0, 0, 11, 70143, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Darnassus Love Boat - On Just Summoned - Cast Vehicle Test'), +(37980, 0, 4, 0, 61, 0, 100, 0, 0, 0, 0, 0, 48, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Darnassus Love Boat - On Just Summoned - Set Active'), +(37980, 0, 5, 0, 1, 0, 100, 0, 0, 0, 3000, 3000, 75, 69341, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Darnassus Love Boat - On Passenger Boarded - Cast Love Boat'), +(37980, 0, 6, 0, 23, 0, 100, 0, 69342, 2, 1000, 1000, 75, 62011, 0, 0, 0, 0, 0, 17, 0, 20, 0, 0, 0, 0, 0, 'Darnassus Love Boat - On Has Aura (2) - Add Aura'), +(37980, 0, 7, 0, 28, 0, 100, 0, 0, 0, 0, 0, 28, 62011, 0, 0, 0, 0, 0, 17, 0, 20, 0, 0, 0, 0, 0, 'Darnassus Love Boat - On Passenger Removed - Remove Aura'), +(36812, 0, 0, 0, 1, 0, 100, 1, 5000, 5000, 0, 0, 53, 0, 36812, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Stormwind Love Boat - OOC - Start WP'), +(36812, 0, 1, 2, 40, 0, 100, 0, 21, 36812, 0, 0, 11, 50630, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Stormwind Love Boat - On Reached WP21 - Cast Eject All Passengers'), +(36812, 0, 2, 0, 61, 0, 100, 0, 0, 0, 0, 0, 41, 2000, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Stormwind Love Boat - On Reached 19 - Despawn'), +(36812, 0, 3, 4, 54, 0, 100, 0, 0, 0, 0, 0, 11, 70143, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Stormwind Love Boat - On Just Summoned - Cast Vehicle Test'), +(36812, 0, 4, 0, 61, 0, 100, 0, 0, 0, 0, 0, 48, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Stormwind - Love Boat - On Just Summoned - Set Active'), +(36812, 0, 5, 0, 1, 0, 100, 0, 0, 0, 3000, 3000, 75, 69341, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Stormwind Love Boat - OOC - Cast Love Boat'), +(36812, 0, 6, 0, 23, 0, 100, 0, 69342, 2, 1000, 1000, 75, 62011, 0, 0, 0, 0, 0, 17, 0, 20, 0, 0, 0, 0, 0, 'Stormwind Love Boat - On Has Aura (2) - Add Aura'), +(36812, 0, 7, 0, 28, 0, 100, 0, 0, 0, 0, 0, 28, 62011, 0, 0, 0, 0, 0, 17, 0, 20, 0, 0, 0, 0, 0, 'Stormwind Love Boat - On Pasenger Removed - Remove Aura'); + +DELETE FROM `npc_spellclick_spells` WHERE `npc_entry`IN(37966,37980,36812); +INSERT INTO `npc_spellclick_spells` (`npc_entry`, `spell_id`, `cast_flags`, `user_type`) VALUES +(37966, 69342, 1, 0), +(37980, 69342, 1, 0), +(36812, 69342, 1, 0); + + +DELETE FROM `waypoints` WHERE `entry` IN(37966,37980,36812); +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES +(37966, 1, 1485.332, 348.7621, -64.54687, 'Undercity Love Boat'), +(37966, 2, 1487.063, 350.9445, -64.86743, 'Undercity Love Boat'), +(37966, 3, 1494.434, 360.592, -64.86742, 'Undercity Love Boat'), +(37966, 4, 1505.792, 368.026, -64.81186, 'Undercity Love Boat'), +(37966, 5, 1520.413, 376.7361, -64.81187, 'Undercity Love Boat'), +(37966, 6, 1542.724, 389.7309, -64.81187, 'Undercity Love Boat'), +(37966, 7, 1555.352, 393.1875, -64.81187, 'Undercity Love Boat'), +(37966, 8, 1577.076, 397.1563, -64.81187, 'Undercity Love Boat'), +(37966, 9, 1618.071, 395.9705, -64.81187, 'Undercity Love Boat'), +(37966, 10, 1642.727, 391.0139, -64.81187, 'Undercity Love Boat'), +(37966, 11, 1685.007, 370.4167, -64.81187, 'Undercity Love Boat'), +(37966, 12, 1711.104, 350.4514, -64.81187, 'Undercity Love Boat'), +(37966, 13, 1738.417, 310.0278, -64.81187, 'Undercity Love Boat'), +(37966, 14, 1746.345, 286.441, -64.81187, 'Undercity Love Boat'), +(37966, 15, 1752.087, 240.5399, -64.81187, 'Undercity Love Boat'), +(37966, 16, 1750.016, 206.7309, -64.81187, 'Undercity Love Boat'), +(37966, 17, 1737.47, 167.8559, -64.81187, 'Undercity Love Boat'), +(37966, 18, 1707.885, 128.5122, -64.81187, 'Undercity Love Boat'), +(37966, 19, 1667.977, 99.80035, -64.81187, 'Undercity Love Boat'), +(37966, 20, 1624.948, 85.43229, -64.81187, 'Undercity Love Boat'), +(37966, 21, 1583.814, 83.33507, -64.81187, 'Undercity Love Boat'), +(37966, 22, 1539.444, 94.43403, -64.81187, 'Undercity Love Boat'), +(37966, 23, 1502.849, 114.3142, -64.81187, 'Undercity Love Boat'), +(37966, 24, 1482.955, 132.6806, -64.81187, 'Undercity Love Boat'), +(37966, 25, 1456.214, 170.0521, -64.81187, 'Undercity Love Boat'), +(37966, 26, 1441.738, 207.8819, -64.81187, 'Undercity Love Boat'), +(37966, 27, 1438.825, 244.4427, -64.81187, 'Undercity Love Boat'), +(37966, 28, 1450.882, 299.3177, -64.81187, 'Undercity Love Boat'), +(37966, 29, 1462.38, 320.4583, -64.81187, 'Undercity Love Boat'), +(37966, 30, 1467.97, 333.1337, -64.81187, 'Undercity Love Boat'), +(37966, 31, 1471.193, 337.8559, -64.81187, 'Undercity Love Boat'), +(37980, 1, 9843.134, 2430.733, 1313.6, 'Darnassus Love Boat'), +(37980, 2, 9847.023, 2427.627, 1313.516, 'Darnassus Love Boat'), +(37980, 3, 9856.224, 2423.156, 1313.516, 'Darnassus Love Boat'), +(37980, 4, 9871.393, 2416.719, 1313.516, 'Darnassus Love Boat'), +(37980, 5, 9888.688, 2408.337, 1313.516, 'Darnassus Love Boat'), +(37980, 6, 9901.832, 2399.545, 1313.516, 'Darnassus Love Boat'), +(37980, 7, 9915.912, 2390.616, 1313.516, 'Darnassus Love Boat'), +(37980, 8, 9930.722, 2381.382, 1313.516, 'Darnassus Love Boat'), +(37980, 9, 9946.339, 2377.861, 1313.516, 'Darnassus Love Boat'), +(37980, 10, 9964.972, 2377.967, 1313.516, 'Darnassus Love Boat'), +(37980, 11, 9977.46, 2379.141, 1313.516, 'Darnassus Love Boat'), +(37980, 12, 9989.397, 2375.556, 1313.516, 'Darnassus Love Boat'), +(37980, 13, 10006.68, 2364.491, 1313.516, 'Darnassus Love Boat'), +(37980, 14, 10022.01, 2353.608, 1313.516, 'Darnassus Love Boat'), +(37980, 15, 10031.78, 2353.427, 1313.516, 'Darnassus Love Boat'), +(37980, 16, 10041.6, 2366.207, 1313.516, 'Darnassus Love Boat'), +(37980, 17, 10043.1, 2373.267, 1313.516, 'Darnassus Love Boat'), +(37980, 18, 10040.94, 2384.248, 1313.516, 'Darnassus Love Boat'), +(37980, 19, 10040.11, 2396.392, 1313.516, 'Darnassus Love Boat'), +(37980, 20, 10043.54, 2406.759, 1313.516, 'Darnassus Love Boat'), +(37980, 21, 10051.08, 2414.868, 1313.516, 'Darnassus Love Boat'), +(37980, 22, 10059.58, 2421.014, 1313.516, 'Darnassus Love Boat'), +(37980, 23, 10061.45, 2433.856, 1313.516, 'Darnassus Love Boat'), +(37980, 24, 10056.65, 2445.88, 1313.516, 'Darnassus Love Boat'), +(37980, 25, 10049.1, 2453.844, 1313.516, 'Darnassus Love Boat'), +(37980, 26, 10039.64, 2458.193, 1313.516, 'Darnassus Love Boat'), +(37980, 27, 10030.21, 2461.353, 1313.516, 'Darnassus Love Boat'), +(37980, 28, 10013.85, 2465.007, 1313.516, 'Darnassus Love Boat'), +(37980, 29, 10007.3, 2472.648, 1313.516, 'Darnassus Love Boat'), +(37980, 30, 10001.77, 2490.97, 1313.516, 'Darnassus Love Boat'), +(37980, 31, 10007.02, 2503.859, 1313.516, 'Darnassus Love Boat'), +(37980, 32, 10014.66, 2519.925, 1313.516, 'Darnassus Love Boat'), +(37980, 33, 10022.5, 2532.248, 1313.516, 'Darnassus Love Boat'), +(37980, 34, 10032.06, 2559.106, 1313.516, 'Darnassus Love Boat'), +(37980, 35, 10032.88, 2579.188, 1313.516, 'Darnassus Love Boat'), +(37980, 36, 10032.36, 2598.909, 1313.516, 'Darnassus Love Boat'), +(37980, 37, 10029.7, 2612.815, 1313.516, 'Darnassus Love Boat'), +(37980, 38, 10022.64, 2648.693, 1313.516, 'Darnassus Love Boat'), +(37980, 39, 9999.638, 2667.306, 1313.516, 'Darnassus Love Boat'), +(37980, 40, 9985.304, 2673.353, 1313.516, 'Darnassus Love Boat'), +(37980, 41, 9967.442, 2671.7, 1313.516, 'Darnassus Love Boat'), +(37980, 42, 9938.718, 2668.114, 1313.516, 'Darnassus Love Boat'), +(37980, 43, 9898.393, 2665.895, 1313.516, 'Darnassus Love Boat'), +(37980, 44, 9874.026, 2660.383, 1313.516, 'Darnassus Love Boat'), +(37980, 45, 9848.894, 2657.903, 1313.516, 'Darnassus Love Boat'), +(37980, 46, 9834.57, 2658.452, 1313.516, 'Darnassus Love Boat'), +(37980, 47, 9820.689, 2652.576, 1313.516, 'Darnassus Love Boat'), +(37980, 48, 9802.497, 2636.835, 1313.516, 'Darnassus Love Boat'), +(37980, 49, 9795.239, 2622.99, 1313.516, 'Darnassus Love Boat'), +(37980, 50, 9785.92, 2605.789, 1313.516, 'Darnassus Love Boat'), +(37980, 51, 9784.899, 2593.911, 1313.516, 'Darnassus Love Boat'), +(37980, 52, 9793.405, 2574.175, 1313.516, 'Darnassus Love Boat'), +(37980, 53, 9812.471, 2555.666, 1313.516, 'Darnassus Love Boat'), +(37980, 54, 9829.779, 2539.537, 1313.516, 'Darnassus Love Boat'), +(37980, 55, 9841.714, 2520.574, 1313.516, 'Darnassus Love Boat'), +(37980, 56, 9847.395, 2499.439, 1313.516, 'Darnassus Love Boat'), +(37980, 57, 9850.591, 2481.936, 1313.516, 'Darnassus Love Boat'), +(37980, 58, 9846.033, 2466.465, 1313.516, 'Darnassus Love Boat'), +(37980, 59, 9838.938, 2451.995, 1313.516, 'Darnassus Love Boat'), +(37980, 60, 9833.917, 2446.236, 1313.516, 'Darnassus Love Boat'), +(36812, 1, -8795.021, 775.0364, 95.22309, 'Stormwind Love Boat'), +(36812, 2, -8791.573, 776.316, 95.0583, 'Stormwind Love Boat'), +(36812, 3, -8783.189, 778.1111, 95.0583, 'Stormwind Love Boat'), +(36812, 4, -8769.04, 777.9063, 95.0583, 'Stormwind Love Boat'), +(36812, 5, -8757.161, 764.092, 95.0583, 'Stormwind Love Boat'), +(36812, 6, -8750.976, 741.6354, 95.08608, 'Stormwind Love Boat'), +(36812, 7, -8733.618, 717.3299, 95.08608, 'Stormwind Love Boat'), +(36812, 8, -8717.854, 698.5886, 95.0583, 'Stormwind Love Boat'), +(36812, 9, -8698.192, 662.2465, 95.0583, 'Stormwind Love Boat'), +(36812, 10, -8688.56, 630.1719, 95.11386, 'Stormwind Love Boat'), +(36812, 11, -8696.212, 596.9983, 95.08608, 'Stormwind Love Boat'), +(36812, 12, -8702.024, 577.2761, 95.0583, 'Stormwind Love Boat'), +(36812, 13, -8691.561, 565.0538, 95.0583, 'Stormwind Love Boat'), +(36812, 14, -8671.857, 565.382, 95.0583, 'Stormwind Love Boat'), +(36812, 15, -8646.634, 563.7743, 95.0583, 'Stormwind Love Boat'), +(36812, 16, -8631.895, 554.441, 95.0583, 'Stormwind Love Boat'), +(36812, 17, -8618.281, 557.4114, 95.0583, 'Stormwind Love Boat'), +(36812, 18, -8608.049, 577.191, 95.0583, 'Stormwind Love Boat'), +(36812, 19, -8602.768, 595.4983, 95.0583, 'Stormwind Love Boat'), +(36812, 20, -8594.357, 623.566, 95.0583, 'Stormwind Love Boat'), +(36812, 21, -8581.717, 629.7882, 95.08608, 'Stormwind Love Boat'); diff --git a/sql/updates/world/2016_02_08_00_world_335.sql b/sql/updates/world/2016_02_08_00_world_335.sql new file mode 100644 index 00000000000..83091035e3c --- /dev/null +++ b/sql/updates/world/2016_02_08_00_world_335.sql @@ -0,0 +1,2 @@ +-- http://wowwiki.wikia.com/wiki/Love_Rocket?oldid=2190122 +UPDATE `item_template` SET `BuyCount`=5 WHERE `entry`=34258; diff --git a/sql/updates/world/2016_02_08_01_world.sql b/sql/updates/world/2016_02_08_01_world.sql new file mode 100644 index 00000000000..9f8fa3dc4ed --- /dev/null +++ b/sql/updates/world/2016_02_08_01_world.sql @@ -0,0 +1,25 @@ +SET @JOVAAN := 21633; -- Deathbringer Jovaan +SET @TRIGGER := 4548; -- Smart Trigger +SET @DEVICE := 184833;-- Legion Communication Device +SET @GO_INFERNAL := 184834;-- Gobject that needs to be despawned during the script +SET @GO_INFERNAL2 := 184835;-- Gobject that needs to be despawned during the script +SET @EVENTID := 13852; -- From spell_dbc id 37492 + +DELETE FROM event_scripts WHERE id =@EVENTID; +INSERT INTO event_scripts (id, command, datalong, datalong2, x, y, z, o) VALUES +(@EVENTID, 10, @JOVAAN, 57000, -3310.995, 2951.892, 171.2171, 5.5355); + +DELETE FROM areatrigger_scripts WHERE entry=@TRIGGER; +DELETE FROM smart_scripts WHERE entryorguid=@TRIGGER AND source_type=2; + +UPDATE gameobject_template SET AIName ='' WHERE entry =@DEVICE; +DELETE FROM smart_scripts WHERE source_type=1 AND entryorguid =@DEVICE; + +DELETE FROM smart_scripts WHERE entryorguid=@JOVAAN AND source_type=0; +INSERT INTO smart_scripts (entryorguid, source_type, id, link, event_type, event_phase_mask, event_chance, event_flags, event_param1, event_param2, event_param3, event_param4, action_type, action_param1, action_param2, action_param3, action_param4, action_param5, action_param6, target_type, target_param1, target_param2, target_param3, target_x, target_y, target_z, target_o, comment) VALUES +(@JOVAAN,0,0,1,11,0,100,0,0,0,0,0,11,34427,0,0,0,0,0,1,0,0,0,0,0,0,0,'Deathbringer Jovaan - Just summoned - Spellcast Etheral Teleport'), +(@JOVAAN,0,1,2,61,0,100,0,0,0,0,0,45,0,1,0,0,0,0,14,25737,@GO_INFERNAL,0,0,0,0,0,'Deathbringer Jovaan - Just summoned - Set Data GO'), +(@JOVAAN,0,2,3,61,0,100,0,0,0,0,0,45,0,2,0,0,0,0,14,25738,@GO_INFERNAL2,0,0,0,0,0,'Deathbringer Jovaan - Just summoned Set Data GO'), +(@JOVAAN,0,3,0,61,0,100,0,0,0,0,0,53,0,@JOVAAN,0,0,0,0,1,0,0,0,0,0,0,0,'Deathbringer Jovaan - Just summoned - Start WP movement'), +(@JOVAAN,0,4,5,40,0,100,0,4,@JOVAAN,0,0,54,45000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Deathbringer Jovaan - On WP 4 reached - Pause 45 seconds'), +(@JOVAAN,0,5,0,61,0,100,0,0,0,0,0,80,@JOVAAN*100,2,0,0,0,0,1,0,0,0,0,0,0,0,'Deathbringer Jovaan - On WP 4 reached - Run Script'); diff --git a/sql/updates/world/2016_02_08_02_world.sql b/sql/updates/world/2016_02_08_02_world.sql new file mode 100644 index 00000000000..0f22abafe8e --- /dev/null +++ b/sql/updates/world/2016_02_08_02_world.sql @@ -0,0 +1,10 @@ +-- +UPDATE `creature_template` SET `mechanic_immune_mask`=`mechanic_immune_mask`|1|2|4|8|16|32|64|256|512|1024|2048|4096|8192|65536|131072|524288|4194304|8388608|33554432|67108864|536870912 WHERE `entry` IN ( +37697, -- 10N Volatile Ooze +38604, -- 10H Volatile Ooze +38758, -- 25N Volatize Ooze +38759, -- 25H Volatile Ooze +37562, -- 10N Gas Cloud +38602, -- 10H Gas Cloud +38760, -- 25N Gas Cloud +38761); -- 25H Gas Cloud diff --git a/sql/updates/world/2016_02_08_03_world.sql b/sql/updates/world/2016_02_08_03_world.sql new file mode 100644 index 00000000000..fe429cf42c8 --- /dev/null +++ b/sql/updates/world/2016_02_08_03_world.sql @@ -0,0 +1,5 @@ +-- +-- DB/Creature: Frost Freeze Trap - Spellcast +DELETE FROM `disables` WHERE `sourceType`=0 AND `entry`=70460; +INSERT INTO `disables` (`sourceType`, `entry`, `flags`, `params_0`, `params_1`, `comment`) VALUES +(0, 70460, 64, '', '', 'Ignore LOS for Coldflame Jets'); diff --git a/sql/updates/world/2016_02_08_04_world.sql b/sql/updates/world/2016_02_08_04_world.sql new file mode 100644 index 00000000000..f8a9e2c776a --- /dev/null +++ b/sql/updates/world/2016_02_08_04_world.sql @@ -0,0 +1,2 @@ +-- Lock and Load - Procc +UPDATE `spell_proc_event` SET `SchoolMask`=0, `SpellFamilyName`=9, `SpellFamilyMask0`=0, `SpellFamilyMask1`=0, `SpellFamilyMask2`=0, `procFlags`=2430272, `procEx`=0, `ppmRate`=0, `CustomChance`=0, `Cooldown`=22 WHERE (`entry`=-56342); diff --git a/sql/updates/world/2016_02_08_05_world.sql b/sql/updates/world/2016_02_08_05_world.sql new file mode 100644 index 00000000000..d2cc597a6ac --- /dev/null +++ b/sql/updates/world/2016_02_08_05_world.sql @@ -0,0 +1,2 @@ +-- diseases immunity tbc +UPDATE `creature_template` SET `mechanic_immune_mask` = `mechanic_immune_mask` &~ 2097152 WHERE `exp` = 1; diff --git a/sql/updates/world/2016_02_08_06_world.sql b/sql/updates/world/2016_02_08_06_world.sql new file mode 100644 index 00000000000..c9e93889790 --- /dev/null +++ b/sql/updates/world/2016_02_08_06_world.sql @@ -0,0 +1,2 @@ +-- fix quest reward text for "The Key to the Focusing Iris" and "The Key to the Heroic Focusing Iris" +UPDATE `quest_offer_reward` SET `RewardText`="These keys are held by the most ancient members of the blue dragonflight. Only they are entrusted with them by their master, Malygos.$b$bThis is the break that we've been waiting for to strike at the Aspect of Magic!$b$b<The queen of dragons studies you for a brief moment.>$b$bYou are not able to use the key as-is to access the Focusing Iris, but I can imbue you with a portion of my power; enough to enable you to use it to open the iris a fraction.$b$bIt will be enough to draw Malygos's ire!" WHERE `ID` in (13372,13375); diff --git a/sql/updates/world/2016_02_08_07_world.sql b/sql/updates/world/2016_02_08_07_world.sql new file mode 100644 index 00000000000..1d90630d829 --- /dev/null +++ b/sql/updates/world/2016_02_08_07_world.sql @@ -0,0 +1,82 @@ +-- +-- DB/Quest: King of the Foulweald +DELETE FROM `spell_script_names` WHERE `spell_id`=20783; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(20783, 'spell_destroy_karangs_banner'); + +-- remove this stuff - eventscripts will be running even without gameobject +DELETE FROM `event_scripts` where id=6721; + +-- Karang's Banner SAI +SET @ENTRY := 178205; +UPDATE `gameobject_template` SET `AIName`="SmartGameObjectAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=1; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,1,0,0,1,0,100,1,5000,5000,0,0,80,@ENTRY*100+00,2,0,0,0,0,1,0,0,0,0,0,0,0,"Karang's Banner - Out of Combat - Run Script (No Repeat)"); + +-- Actionlist SAI +SET @ENTRY := 17820500; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,9,0,0,0,0,100,0,0,0,0,0,12,3749,3,180000,0,0,0,8,0,0,0,2237.48,-1524.45,89.7827,0,"On Script - Summon Creature 'Foulweald Ursa'"), +(@ENTRY,9,1,0,0,0,100,0,0,0,0,0,12,3743,3,180000,0,0,0,8,0,0,0,2202.16,-1544.48,87.796,0,"On Script - Summon Creature 'Foulweald Warrior'"), +(@ENTRY,9,2,0,0,0,100,0,20000,20000,0,0,12,3750,3,180000,0,0,0,8,0,0,0,2208.93,-1567.59,87.2283,0,"On Script - Summon Creature 'Foulweald Totemic'"), +(@ENTRY,9,3,0,0,0,100,0,0,0,0,0,12,3749,3,180000,0,0,0,8,0,0,0,2235.44,-1578.43,86.4944,0,"On Script - Summon Creature 'Foulweald Ursa'"), +(@ENTRY,9,4,0,0,0,100,0,0,0,0,0,12,3743,3,180000,0,0,0,8,0,0,0,2260.9,-1547.91,89.1733,0,"On Script - Summon Creature 'Foulweald Warrior'"), +(@ENTRY,9,5,0,0,0,100,0,30000,30000,0,0,12,3750,3,180000,0,0,0,8,0,0,0,2237.48,-1524.45,89.7827,0,"On Script - Summon Creature 'Foulweald Totemic'"), +(@ENTRY,9,6,0,0,0,100,0,0,0,0,0,12,3749,3,180000,0,0,0,8,0,0,0,2202.16,-1544.48,87.796,0,"On Script - Summon Creature 'Foulweald Ursa'"), +(@ENTRY,9,7,0,0,0,100,0,20000,20000,0,0,12,3743,3,180000,0,0,0,8,0,0,0,2208.93,-1567.59,87.2283,0,"On Script - Summon Creature 'Foulweald Warrior'"), +(@ENTRY,9,8,0,0,0,100,0,0,0,0,0,12,3750,3,180000,0,0,0,8,0,0,0,2235.44,-1578.43,86.4944,0,"On Script - Summon Creature 'Foulweald Totemic'"), +(@ENTRY,9,9,0,0,0,100,0,0,0,0,0,12,3749,3,180000,0,0,0,8,0,0,0,2260.9,-1547.91,89.1733,0,"On Script - Summon Creature 'Foulweald Ursa'"), +(@ENTRY,9,10,0,0,0,100,0,30000,30000,0,0,12,3743,3,180000,0,0,0,8,0,0,0,2237.48,-1524.45,89.7827,0,"On Script - Summon Creature 'Foulweald Warrior'"), +(@ENTRY,9,11,0,0,0,100,0,0,0,0,0,12,3750,3,180000,0,0,0,8,0,0,0,2202.16,-1544.48,87.796,0,"On Script - Summon Creature 'Foulweald Totemic'"), +(@ENTRY,9,12,0,0,0,100,0,20000,20000,0,0,12,3749,3,180000,0,0,0,8,0,0,0,2208.93,-1567.59,87.2283,0,"On Script - Summon Creature 'Foulweald Ursa'"), +(@ENTRY,9,13,0,0,0,100,0,0,0,0,0,12,3743,3,180000,0,0,0,8,0,0,0,2235.44,-1578.43,86.4944,0,"On Script - Summon Creature 'Foulweald Warrior'"), +(@ENTRY,9,14,0,0,0,100,0,0,0,0,0,12,3750,3,180000,0,0,0,8,0,0,0,2260.9,-1547.91,89.1733,0,"On Script - Summon Creature 'Foulweald Totemic'"), +(@ENTRY,9,15,0,0,0,100,0,30000,30000,0,0,12,3749,3,180000,0,0,0,8,0,0,0,2237.48,-1524.45,89.7827,0,"On Script - Summon Creature 'Foulweald Ursa'"), +(@ENTRY,9,16,0,0,0,100,0,0,0,0,0,12,3743,3,180000,0,0,0,8,0,0,0,2202.16,-1544.48,87.796,0,"On Script - Summon Creature 'Foulweald Warrior'"), +(@ENTRY,9,17,0,0,0,100,0,25000,25000,0,0,12,12918,3,180000,0,0,0,8,0,0,0,2208.93,-1567.59,87.2283,0,"On Script - Summon Creature 'Chief Murgut'"); + +-- Foulweald Ursa SAI +SET @ENTRY := 3749; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`>=4; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,4,0,1,0,100,0,2000,2000,20000,20000,69,1,0,0,0,0,0,20,178205,100,0,0,0,0,0,"Foulweald Ursa - Out of Combat - Move To Position"), +(@ENTRY,0,5,0,34,0,100,0,8,1,0,0,11,20786,0,0,0,0,0,1,0,0,0,0,0,0,0,"Foulweald Ursa - On Reached Point 1 - Cast 'Destroy Karang's Banner'"); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=22 AND `SourceGroup`=5 AND `SourceEntry`=3749; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(22,5,3749,0,0,30,1,178205,35,0,0,"","Foulweald SAI - ONLY near Banner"); + +-- Foulweald Warrior SAI +SET @ENTRY := 3743; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`>=2; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,2,0,1,0,100,0,2000,2000,20000,20000,69,1,0,0,0,0,0,20,178205,100,0,0,0,0,0,"Foulweald Warrior - Out of Combat - Move To Closest Gameobject 'Karang's Banner' (Phase 1)"), +(@ENTRY,0,3,0,34,0,100,0,8,1,0,0,11,20786,0,0,0,0,0,1,0,0,0,0,0,0,0,"Foulweald Warrior - On Reached Point 1 - Cast 'Destroy Karang's Banner'"); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=22 AND `SourceGroup`=3 AND `SourceEntry`=3743; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(22,3,3743,0,0,30,1,178205,35,0,0,"","Foulweald SAI - ONLY near Banner"); + +-- Foulweald Totemic SAI +SET @ENTRY := 3750; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`>=4; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,4,0,1,0,100,0,2000,2000,20000,20000,69,1,0,0,0,0,0,20,178205,100,0,0,0,0,0,"Foulweald Totemic - Out of Combat - Move To Closest Gameobject 'Karang's Banner' (Phase 1)"), +(@ENTRY,0,5,0,34,0,100,0,8,1,0,0,11,20786,0,0,0,0,0,1,0,0,0,0,0,0,0,"Foulweald Totemic - On Reached Point 1 - Cast 'Destroy Karang's Banner'"); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=22 AND `SourceGroup`=5 AND `SourceEntry`=3750; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(22,5,3750,0,0,30,1,178205,35,0,0,"","Foulweald SAI - ONLY near Banner"); + +-- Chief Murgut SAI +SET @ENTRY := 12918; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`>=4; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,4,0,1,0,100,0,2000,2000,20000,20000,69,1,0,0,0,0,0,20,178205,100,0,0,0,0,0,"Chief Murgut - Out of Combat - Move To Closest Gameobject 'Karang's Banner' (Phase 1)"), +(@ENTRY,0,5,0,34,0,100,0,8,1,0,0,11,20786,0,0,0,0,0,1,0,0,0,0,0,0,0,"Chief Murgut - On Reached Point 1 - Cast 'Destroy Karang's Banner'"); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=22 AND `SourceGroup`=5 AND `SourceEntry`=12918; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`SourceId`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionTarget`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(22,5,12918,0,0,30,1,178205,35,0,0,"","Foulweald SAI - ONLY near Banner"); diff --git a/sql/updates/world/2016_02_08_08_world.sql b/sql/updates/world/2016_02_08_08_world.sql new file mode 100644 index 00000000000..ae4f454bc91 --- /dev/null +++ b/sql/updates/world/2016_02_08_08_world.sql @@ -0,0 +1,3 @@ +DELETE FROM `spell_script_names` WHERE `ScriptName` = 'spell_sha_totemic_mastery'; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(38443, 'spell_sha_totemic_mastery'); diff --git a/sql/updates/world/2016_02_09_00_world.sql b/sql/updates/world/2016_02_09_00_world.sql new file mode 100644 index 00000000000..c93a1d8fed1 --- /dev/null +++ b/sql/updates/world/2016_02_09_00_world.sql @@ -0,0 +1,3 @@ +-- Garhal (Examples To Be Made quest target): Add CREATURE_FLAG_EXTRA_NO_PLAYER_DAMAGE_REQ, spawn time = 60 seconds; closes #16084 +UPDATE `creature_template` SET `flags_extra`=`flags_extra`|2097152 WHERE `entry`=30147; +UPDATE `creature` SET `spawntimesecs`=60 WHERE `guid`=114369; diff --git a/sql/updates/world/2016_02_09_01_world.sql b/sql/updates/world/2016_02_09_01_world.sql new file mode 100644 index 00000000000..7878ea7faa2 --- /dev/null +++ b/sql/updates/world/2016_02_09_01_world.sql @@ -0,0 +1,211 @@ +-- Razorfen Kraul (Update SAI) +-- Razorfen Handler + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4530; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4530; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4530, 0, 0, 0, 9, 0, 100, 0, 0, 30, 2300, 3900, 11, 6660, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Handler - Within 0-30 Range - Cast \'Shoot\''); + +-- Razorfen Quilguard + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4436; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4436 AND `id` IN (1, 2); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4436, 0, 1, 0, 4, 0, 100, 1, 0, 0, 0, 0, 11, 8258, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Quilguard - On Aggro - Cast \'Devotion Aura\''), +(4436, 0, 2, 0, 0, 0, 100, 0, 4000, 8000, 12000, 16000, 11, 15548, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Quilguard - In Combat - Cast \'Thunderclap\''); + +-- Razorfen Geomancer + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4520; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4520 AND `id` IN (0, 1); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4520, 0, 0, 0, 0, 0, 100, 0, 0, 0, 3400, 4800, 11, 9532, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Geomancer - In Combat CMC - Cast \'Lightning Bolt\''), +(4520, 0, 1, 0, 25, 0, 100, 0, 0, 0, 0, 0, 11, 8270, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Geomancer - On Reset - Cast to summon Earth Rumbler'); + +-- Razorfen Defender + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4442; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4442 AND `id` IN (0, 1, 2); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4442, 0, 0, 0, 0, 0, 100, 1, 1000, 1000, 180000, 180000, 11, 7164, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Defender - In Combat - Cast \'Defensive Stance\''), +(4442, 0, 1, 0, 0, 0, 100, 0, 6000, 11000, 19000, 25000, 11, 11972, 1, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Defender - In Combat - Cast \'Shield Bash\''), +(4442, 0, 2, 0, 0, 0, 100, 0, 2000, 5000, 12000, 15000, 11, 3248, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Defender - In Combat - Cast \'Improved Blocking\''); + +-- Death's Head Adept + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4516; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4516; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4516, 0, 0, 0, 0, 0, 100, 2, 0, 0, 2400, 3800, 11, 9672, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Death\'s Head Adept - In Combat CMC - Cast \'Frostbolt\''), +(4516, 0, 1, 0, 0, 0, 100, 2, 3000, 6000, 10000, 15000, 11, 113, 1, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, 'Death\'s Head Adept - In Combat - Cast \'Chains of Ice\' '), +(4516, 0, 2, 0, 2, 0, 100, 3, 0, 15, 0, 0, 25, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Death\'s Head Adept - Between 0-15% Health - Flee For Assist (No Repeat)'); + +-- Razorfen Groundshaker + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4523; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4523; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4523, 0, 0, 0, 0, 0, 100, 0, 7700, 14500, 11000, 26300, 11, 6524, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Groundshaker - In Combat - Cast \'Ground Tremor\''), +(4523, 0, 1, 0, 0, 0, 100, 0, 3000, 6000, 10000, 15000, 11, 8046, 1, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Groundshaker - In Combat - Cast \'Earth Shock\''); + +-- Razorfen Beastmaster + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4532; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4532; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4532, 0, 0, 0, 9, 0, 100, 0, 0, 30, 2300, 3900, 11, 6660, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Beastmaster - Within 0-30 Range - Cast \'Shoot\''), +(4532, 0, 1, 0, 25, 0, 100, 0, 0, 0, 0, 0, 11, 8276, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Beastmaster - On Reset - Cast to summon Tamed Hyena'), +(4532, 0, 2, 0, 9, 0, 100, 1, 0, 30, 4000, 6000, 11, 8275, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Beastmaster - Within 0-30 Range - Cast \'Poisoned Shot\'(No Repeat)'); + + -- Razorfen Dustweaver + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4522; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4522; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4522, 0, 0, 0, 0, 0, 100, 0, 12000, 12000, 28000, 28000, 11, 6728, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Dustweaver - In Combat - Cast \'Enveloping Winds\''); + +-- Razorfen Beast Trainer + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4531; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4531; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4531, 0, 0, 0, 0, 0, 100, 0, 0, 30, 2300, 3900, 11, 6660, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Beast Trainer - Within 0-30 Range - Cast \'Shoot\''), +(4531, 0, 1, 0, 0, 0, 100, 0, 0, 30, 4000, 6000, 11, 6984, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Beast Trainer - Within 0-30 Range - Cast \'Frost Shot\''); + +-- Aggem Thorncurse <Death's Head Prophet> + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4424; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4424; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4424, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 9128, 32, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Aggem Thorncurse - In Combat - Cast \'Battle Shout\''), +(4424, 0, 1, 0, 0, 0, 100, 0, 10000, 10000, 26000, 26000, 11, 8286, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Aggem Thorncurse - In Combat - Cast \'Summon Boar Spirit\''); + +-- Razorfen Totemic + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4440; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4440; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4440, 0, 0, 0, 0, 0, 100, 0, 6000, 6000, 30000, 30000, 11, 4971, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Totemic - In Combat - Cast \'Healing Ward\' (No Repeat)'), +(4440, 0, 1, 0, 0, 0, 100, 0, 4000, 4000, 32000, 32000, 11, 8376, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Totemic - In Combat - Cast \'Earthgrab Totem\''); + +-- Death Speaker Jargba + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4428; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4428; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4428, 0, 0, 0, 0, 0, 100, 2, 0, 0, 2400, 3800, 11, 9613, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Death Speaker Jargba - In Combat CMC - Cast \'Shadow Bolt\''), +(4428, 0, 1, 0, 0, 0, 100, 2, 7000, 10000, 10000, 15000, 11, 14515, 1, 0, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, 'Death Speaker Jargba - In Combat - Cast \'Dominate Mind\''); + +-- Quilguard Champion + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4623; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4623; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4623, 0, 0, 0, 4, 0, 100, 1, 0, 0, 0, 0, 11, 8258, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Quilguard Champion - On Aggro - Cast \'Devotion Aura\''), +(4623, 0, 1, 0, 0, 0, 100, 1, 1000, 1000, 180000, 180000, 11, 7164, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Quilguard Champion - In Combat - Cast \'Defensive Stance\''), +(4623, 0, 2, 0, 0, 0, 100, 0, 2000, 10000, 6000, 15000, 11, 15572, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Quilguard Champion - In Combat - Cast \'Sunder Armor\'(No Repeat)'); + +-- Overlord Ramtusk + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4420; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4420 AND `id` IN (1, 2); +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES (4420, 0, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 9128, 32, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Ramtusk - In Combat - Cast \'Battle Shout\''), +(4420, 0, 2, 0, 0, 0, 100, 0, 4000, 8000, 12000, 16000, 11, 15548, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Overlord Ramtusk - In Combat - Cast \'Thunderclap\''); + +-- Razorfen Earthbreaker + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4525; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4525; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES (4525, 0, 0, 0, 0, 0, 100, 0, 7700, 14500, 11000, 26300, 11, 8272, 32, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Groundshaker - In Combat - Cast \'Mind Tremor\''), +(4525, 0, 1, 0, 0, 0, 100, 0, 3000, 6000, 10000, 15000, 11, 8046, 1, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Groundshaker - In Combat - Cast \'Earth Shock\''); + +-- Kraul Bat + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4538; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4538; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4538, 0, 0, 0, 0, 0, 100, 0, 5000, 8000, 10000, 12000, 11, 12553, 2, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Kraul Bat - In Combat - Cast \'Shock\''); + +-- Ward Guardian + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4427; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4427; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4427, 0, 0, 0, 14, 0, 100, 0, 500, 40, 10000, 12000, 11, 959, 1, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Ward Guardian - Friendly At 500 Health - Cast \'Healing Wave\''), +(4427, 0, 1, 0, 9, 0, 100, 0, 0, 35, 3400, 4800, 11, 8400, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Ward Guardian - Within 0-35 Range - Cast \'Fireball\''); + +-- Agathelos the Raging + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4422; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4422; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4422, 0, 0, 0, 0, 0, 100, 0, 5000, 8000, 12000, 14000, 11, 8285, 2, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Agathelos the Raging - In Combat - Cast \'Rampage\''); + +-- Death's Head Priest + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4517; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4517; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4517, 0, 0, 0, 1, 0, 100, 2, 1000, 1000, 1800000, 1800000, 11, 1245, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Death\'s Head Priest - Out of Combat - Cast \'Power Word: Fortitude\''), +(4517, 0, 1, 0, 0, 0, 100, 2, 0, 0, 2400, 3800, 11, 9613, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Death\'s Head Priest - In Combat CMC - Cast \'Shadow Bolt\' (No Repeat)'), +(4517, 0, 2, 0, 2, 0, 100, 2, 0, 40, 14000, 20000, 11, 6063, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Death\'s Head Priest - Between 0-40% Health - Cast \'Heal\' (Normal Dungeon)'), +(4517, 0, 3, 0, 2, 0, 100, 3, 0, 15, 0, 0, 25, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Death\'s Head Priest - Between 0-15% Health - Flee For Assist (No Repeat)'); + +-- Razorfen Warden + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4437; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4437; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4437, 0, 0, 0, 0, 0, 100, 0, 3500, 7500, 20100, 33400, 11, 6533, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Razorfen Warden - In Combat - Cast \'Net\' (No Repeat)'); + +-- Raging Agam'ar + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4514; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4514; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4514, 0, 0, 0, 2, 0, 100, 1, 0, 50, 0, 0, 11, 8269, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Raging Agam\'ar - Between 0-50% Health - Cast \'Frenzy\''); + +-- Agam'ar + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4511; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4511; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4511, 0, 0, 0, 4, 0, 15, 1, 0, 0, 0, 0, 11, 6268, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Agam\'ar - On Aggro - Cast \'Rushing Charge\' (No Repeat)'); + +-- Blood of Agamaggan + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4541; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4541; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4541, 0, 0, 0, 0, 0, 100, 0, 5000, 9000, 15000, 25000, 11, 8282, 32, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Blood of Agamaggan - In Combat - Cast \'Curse of Blood\''); + +-- Roogug + +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=6168; +DELETE FROM `smart_scripts` WHERE `entryorguid`=6168; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(6168, 0, 0, 0, 0, 0, 100, 0, 0, 40, 3700, 7500, 11, 9532, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Roogug - In Combat CMC - Cast \'Lightning Bolt\''), +(6168, 0, 1, 0, 0, 0, 100, 0, 0, 30, 6000, 8000, 11, 943, 64, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Roogug - In Combat - Cast \'Lightning Bolt\''); + +-- Charlga Razorflank <The Crone> SAI +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry`=4421; +DELETE FROM `smart_scripts` WHERE `entryorguid`=4421 AND `source_type`=0; + +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(4421, 0, 0, 0, 4, 0, 100, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Charlga Razorflank - On Aggro - Yell Line 0'), +(4421, 0, 1, 0, 5, 0, 100, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Charlga Razorflank - On Killed Unit - Yell Line 1'), +(4421, 0, 2, 0, 2, 0, 100, 1, 0, 75, 0, 0, 1, 2, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Charlga Razorflank - Between 0-75% Health - Yell Line 2''(No Repeat)'), +(4421, 0, 3, 0, 2, 0, 100, 1, 0, 50, 0, 0, 1, 3, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Charlga Razorflank - Between 0-50% Health - Yell Line 3''(No Repeat)'), +(4421, 0, 4, 0, 2, 0, 100, 1, 0, 25, 0, 0, 1, 4, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Charlga Razorflank - Between 0-25% Health - Yell Line 4''(No Repeat)'), +(4421, 0, 5, 0, 0, 0, 100, 0, 0, 0, 78000, 78000, 11, 8361, 32, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Charlga Razorflank - In combat - Cast \'Purity\''), +(4421, 0, 6, 0, 2, 0, 100, 0, 0, 80, 15000, 18000, 11, 6077, 32, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Charlga Razorflank - Between 0-80% Health - Cast \'Renew\''), +(4421, 0, 7, 0, 0, 0, 100, 0, 6000, 6000, 8000, 8000, 11, 8292, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 'Charlga Razorflank - In Combat - Cast \'Chain Bolt\''), +(4421, 0, 8, 0, 3, 0, 100, 0, 0, 5, 0, 0, 11, 8358, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Charlga Razorflank - Between 0-5% Mana - Cast \'Mana Spike\''); + +DELETE FROM `creature_text` WHERE `entry`= 4421 AND `groupid` IN (0, 1, 2, 3, 4); +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`BroadcastTextId`,`TextRange`,`comment`) VALUES +(4421,0,0,"Troublesome whelps. I'll teach you to interfere!", 14,0,100,0,0,0,6179,3,'Charlga Razorflank - on initial aggro'), +(4421,1,0,"Who's next?", 14,0,100,0,0,0,6180,3,'Charlga Razorflank - killing a player'), +(4421,2,0,"You outsiders will pay for encroaching on our land!",14,0,100,0,0,0,6181,3,'Charlga Razorflank - on 75% hp reached'), +(4421,3,0,"Bah! My power rules here!", 14,0,100,0,0,0,6182,3,'Charlga Razorflank - on 50% hp reached'), +(4421,4,0,"Our new allies will avenge us!", 14,0,100,0,0,0,6183,3,'Charlga Razorflank - on 25% hp reached'); diff --git a/sql/updates/world/2016_02_09_02_world.sql b/sql/updates/world/2016_02_09_02_world.sql new file mode 100644 index 00000000000..891c8c2ff4b --- /dev/null +++ b/sql/updates/world/2016_02_09_02_world.sql @@ -0,0 +1,21 @@ +-- Sunblade Mage Guard SAI +SET @ENTRY := 24683; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,1,1,0,100,0,0,0,0,0,21,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Out of Combat - Disable Combat Movement"), +(@ENTRY,0,1,0,61,0,100,0,0,0,0,0,20,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Out of Combat - Stop Attacking"), +(@ENTRY,0,2,0,0,0,100,7,0,0,0,0,11,44475,1,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - In Combat - Cast 'Magic Dampening Field' (No Repeat) (Dungeon)"), +(@ENTRY,0,3,4,9,0,100,0,0,60,5000,5000,11,44478,0,0,0,0,0,2,0,0,0,0,0,0,0,"Sunblade Mage Guard - Within 0-60 Range - Cast 'Glaive Throw'"), +(@ENTRY,0,4,0,61,0,100,0,0,60,5000,5000,40,2,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Within 0-60 Range - Set Sheath Ranged"), +(@ENTRY,0,5,6,9,0,100,0,45,80,0,0,21,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Within 45-80 Range - Enable Combat Movement"), +(@ENTRY,0,6,0,61,0,100,0,45,80,0,0,20,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Within 45-80 Range - Start Attacking"), +(@ENTRY,0,7,0,9,0,100,0,0,5,0,0,21,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Within 0-5 Range - Enable Combat Movement"), +(@ENTRY,0,8,9,9,0,100,0,0,0,0,0,40,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Within 0-0 Range - Set Sheath Melee"), +(@ENTRY,0,9,0,61,0,100,0,0,0,0,0,20,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Within 0-0 Range - Start Attacking"), +(@ENTRY,0,10,11,9,0,100,0,5,20,0,0,21,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Within 5-20 Range - Disable Combat Movement"), +(@ENTRY,0,11,0,61,0,100,0,5,20,0,0,20,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Within 5-20 Range - Stop Attacking"), +(@ENTRY,0,12,0,2,0,100,7,0,15,0,0,23,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Between 0-15% Health - Increment Phase (No Repeat) (Dungeon)"), +(@ENTRY,0,13,14,2,0,100,1,0,15,0,0,21,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - Between 0-15% Health - Enable Combat Movement (No Repeat)"), +(@ENTRY,0,14,0,61,0,100,1,0,15,0,0,25,1,0,0,0,0,0,7,0,0,0,0,0,0,0,"Sunblade Mage Guard - Between 0-15% Health - Flee For Assist (No Repeat)"), +(@ENTRY,0,15,0,7,0,100,0,0,0,0,0,40,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Sunblade Mage Guard - On Evade - Set Sheath Melee"); diff --git a/sql/updates/world/2016_02_09_02_world_335.sql b/sql/updates/world/2016_02_09_02_world_335.sql new file mode 100644 index 00000000000..a8612c5d88d --- /dev/null +++ b/sql/updates/world/2016_02_09_02_world_335.sql @@ -0,0 +1,29 @@ +-- move script 'npc_myranda_the_hag' to SAI (PR #16438) +UPDATE `gossip_menu_option` SET `option_id`=1 WHERE `menu_id`=3801; +DELETE FROM `gossip_menu` WHERE `entry`=3801 AND `text_id`=4773; +INSERT INTO `gossip_menu` (`entry`, `text_id`) VALUES +(3801, 4773); + +UPDATE `creature_template` SET `AIName`='SmartAI', `ScriptName`='' WHERE `entry`=11872; +DELETE FROM `smart_scripts` WHERE `entryorguid`=11872 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(11872, 0, 0, 1, 62, 0, 100, 0, 3801, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Myranda the Hag - On Gossip Option 0 Selected - Close Gossip'), +(11872, 0, 1, 0, 61, 0, 100, 0, 3801, 0, 0, 0, 85, 17961, 2, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Myranda the Hag - On Gossip Option 0 Selected - Invoker Cast \'Scarlet Illusion\''); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=3801; +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=14 AND `SourceGroup`=3801; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(15, 3801, 0, 0, 0, 28, 0, 5862, 0, 0, 0, 0, 0, '', 'Only show gossip menu option if quest \'Scarlet Subterfuge\' is complete'), +(15, 3801, 0, 0, 0, 28, 0, 5944, 0, 0, 1, 0, 0, '', 'Only show gossip menu option if quest \'In Dreams\' is not complete'), +(15, 3801, 0, 0, 0, 8, 0, 5944, 0, 0, 1, 0, 0, '', 'Only show gossip menu option if quest \'In Dreams\' is not rewarded'), +(15, 3801, 0, 0, 0, 1, 0, 17961, 0, 0, 1, 0, 0, '', 'Only show gossip menu option if no \'Scarlet Illusion\' Aura'), +(15, 3801, 0, 0, 1, 8, 0, 5862, 0, 0, 0, 0, 0, '', 'Only show gossip menu option if quest \'Scarlet Subterfuge\' is rewarded'), +(15, 3801, 0, 0, 1, 28, 0, 5944, 0, 0, 1, 0, 0, '', 'Only show gossip menu option if quest \'In Dreams\' is not complete'), +(15, 3801, 0, 0, 1, 8, 0, 5944, 0, 0, 1, 0, 0, '', 'Only show gossip menu option if quest \'In Dreams\' is not rewarded'), +(15, 3801, 0, 0, 1, 1, 0, 17961, 0, 0, 1, 0, 0, '', 'Only show gossip menu option if no \'Scarlet Illusion\' Aura'), +(14, 3801, 4773, 0, 0, 28, 0, 5862, 0, 0, 0, 0, 0, '', 'Only show text if quest \'Scarlet Subterfuge\' is complete'), +(14, 3801, 4773, 0, 0, 28, 0, 5944, 0, 0, 1, 0, 0, '', 'Only show text if quest \'In Dreams\' is not complete'), +(14, 3801, 4773, 0, 0, 8, 0, 5944, 0, 0, 1, 0, 0, '', 'Only show text if quest \'In Dreams\' is not rewarded'), +(14, 3801, 4773, 0, 1, 8, 0, 5862, 0, 0, 0, 0, 0, '', 'Only show text if quest \'Scarlet Subterfuge\' is rewarded'), +(14, 3801, 4773, 0, 1, 28, 0, 5944, 0, 0, 1, 0, 0, '', 'Only show text if quest \'In Dreams\' is not complete'), +(14, 3801, 4773, 0, 1, 8, 0, 5944, 0, 0, 1, 0, 0, '', 'Only show text if quest \'In Dreams\' is not rewarded'); diff --git a/sql/updates/world/2016_02_09_03_world.sql b/sql/updates/world/2016_02_09_03_world.sql new file mode 100644 index 00000000000..bd012f0d172 --- /dev/null +++ b/sql/updates/world/2016_02_09_03_world.sql @@ -0,0 +1,124 @@ +-- +-- DB/Quest: Translation to Ello +DELETE FROM `waypoints` WHERE `entry`=412; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`) VALUES +(412, 1, -10290.1, 73.7148, 38.849), +(412, 2, -10290.4, 81.547, 38.7702), +(412, 3, -10283.2, 86.6661, 38.7694), +(412, 4, -10271.1, 83.5772, 39.1122), +(412, 5, -10266, 76.0585, 39.4047), +(412, 6, -10272.4, 65.7703, 39.524), +(412, 7, -10283.4, 59.1681, 40.6902), +(412, 8, -10300.2, 45.8306, 47.3053), +(412, 9, -10315.3, 45.1015, 48.0097), +(412, 10, -10324.4, 38.7441, 47.3935), +(412, 11, -10330.2, 27.0829, 50.5753), +(412, 12, -10335.3, 13.4164, 50.1259), +(412, 13, -10342.2, 3.3501, 51.1675), +(412, 14, -10354.6, -13.0266, 47.1154), +(412, 15, -10379.4, -27.1456, 49.2841), +(412, 16, -10401, -30.8108, 48.1353), +(412, 17, -10416.5, -28.4794, 48.4772), +(412, 18, -10436.4, -34.2376, 46.5064), +(412, 19, -10468.7, -38.8985, 48.7035), +(412, 20, -10500.2, -44.6662, 45.882), +(412, 21, -10539.1, -39.3422, 43.0622), +(412, 22, -10568, -35.1434, 37.2048), +(412, 23, -10585.6, -37.5056, 37.4296), +(412, 24, -10606.3, -51.7202, 36.0713), +(412, 25, -10629.2, -64.211, 32.6163), +(412, 26, -10645.9, -73.4561, 32.7337), +(412, 27, -10671, -81.8316, 35.6535), +(412, 28, -10687.6, -85.57, 34.1549), +(412, 29, -10702.8, -89.2772, 37.9242), +(412, 30, -10709.1, -97.5837, 37.892), +(412, 31, -10725.6, -101.348, 34.5892), +(412, 32, -10748, -99.1517, 38.2323), +(412, 33, -10759.9, -93.0657, 38.5876), +(412, 34, -10774.9, -89.8001, 34.8007), +(412, 35, -10788.6, -86.7376, 33.4988), +(412, 36, -10802.7, -88.6347, 29.0679), +(412, 37, -10811.5, -97.1736, 29.2451), +(412, 38, -10821.4, -121.335, 30.142), +(412, 39, -10826.2, -134.391, 31.7845), +(412, 40, -10830.6, -148.284, 31.7985), +(412, 41, -10835.3, -164.201, 33.8299), +(412, 42, -10840.4, -182.63, 34.0254), +(412, 43, -10843.3, -193.104, 35.8227), +(412, 44, -10848.7, -215.175, 37.7986), +(412, 45, -10851.7, -235.779, 38.6853), +(412, 46, -10857.4, -264.019, 38.0974), +(412, 47, -10866.6, -293.454, 37.9429), +(412, 48, -10882.9, -332.562, 37.9688), +(412, 49, -10900, -365.26, 39.4542), +(412, 50, -10904.1, -393.833, 41.0451), +(412, 51, -10905.7, -431.964, 42.7237), +(412, 52, -10908, -461.901, 46.7191), +(412, 53, -10911.2, -510.492, 52.0594), +(412, 54, -10915.1, -533.78, 53.8047), +(412, 55, -10927, -565.685, 54.042), +(412, 56, -10936.5, -581.62, 53.8887), +(412, 57, -10950.1, -597.371, 55.177), +(412, 58, -10957.9, -619.554, 55.0689), +(412, 59, -10958.8, -637.183, 55.2047), +(412, 60, -10954.3, -652.46, 55.4423), +(412, 61, -10931.8, -681.568, 55.3955), +(412, 62, -10916.9, -710.733, 55.6988), +(412, 63, -10902.9, -734.1, 55.1313), +(412, 64, -10878.3, -760.091, 55.5638), +(412, 65, -10851.1, -787.76, 56.1885), +(412, 66, -10831.9, -818.655, 56.2795), +(412, 67, -10825.2, -833.223, 55.5758), +(412, 68, -10808.3, -873.497, 55.9567), +(412, 69, -10796.7, -912.719, 55.8731), +(412, 70, -10796.1, -934.562, 56.2303), +(412, 71, -10800.5, -949.721, 56.5614), +(412, 72, -10807.1, -969.027, 56.2941), +(412, 73, -10806.8, -992.166, 53.8349), +(412, 74, -10804.6, -1030.41, 47.0768), +(412, 75, -10801.3, -1047.26, 44.0233), +(412, 76, -10787.8, -1074.49, 37.7652), +(412, 77, -10783.3, -1095.07, 33.6488), +(412, 78, -10781.2, -1112.66, 30.3863), +(412, 79, -10763.6, -1138.91, 27.0977), +(412, 80, -10738, -1158.02, 26.4475), +(412, 81, -10705.3, -1179.29, 26.3723), +(412, 82, -10682.3, -1190.45, 27.2793), +(412, 83, -10662.5, -1193.06, 28.2884), +(412, 84, -10641.6, -1189.92, 28.5594), +(412, 85, -10615.7, -1182.78, 28.5022), +(412, 86, -10586.8, -1177.32, 28.3931), +(412, 87, -10576.4, -1179.26, 28.1946), +(412, 88, -10566.7, -1189.27, 27.8756), +(412, 89, -10557, -1192.38, 28.0606), +(412, 90, -10550.4, -1185.71, 27.8428), +(412, 91, -10554.4, -1167.97, 27.5984); + +-- Lord Ello Ebonlocke SAI +SET @ENTRY := 263; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,1,0,100,0,20000,30000,120000,120000,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Lord Ello Ebonlocke - Out of Combat - Say Line 0"), +(@ENTRY,0,1,0,20,0,100,0,252,0,0,0,12,412,3,3600000,0,0,0,8,0,0,0,-10290.171875,72.781136,38.881119,4.801499,"Lord Ello Ebonlocke - On Quest 'Translation to Ello' Finished - Summon Creature 'Stitches'"); + +-- Stitches SAI +SET @ENTRY := 412; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,0,0,100,0,6900,12100,3500,11300,11,3106,0,0,0,0,0,2,0,0,0,0,0,0,0,"Stitches - In Combat - Cast 'Aura of Rot'"), +(@ENTRY,0,1,2,54,0,100,0,0,0,0,0,48,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stitches - On Just Summoned - Set Active On"), +(@ENTRY,0,2,0,61,0,100,0,0,0,0,0,53,1,412,0,0,0,2,0,0,0,0,0,0,0,0,"Stitches - On Just Summoned - Start Waypoint"), +(@ENTRY,0,3,0,40,0,100,0,47,412,0,0,1,0,0,0,0,0,0,19,468,200,0,0,0,0,0,"Stitches - On Waypoint 47 Reached - Say Line 0"), +(@ENTRY,0,5,6,40,0,100,0,50,412,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stitches - On Waypoint 50 Reached - Say Line 0"), +(@ENTRY,0,6,0,61,0,100,0,50,412,0,0,1,1,0,0,0,0,0,19,468,200,0,0,0,0,0,"Stitches - On Waypoint 50 Reached - Say Line 1"), +(@ENTRY,0,7,8,40,0,100,0,91,412,0,0,101,0,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stitches - On Waypoint 91 Reached - Set Home Position"), +(@ENTRY,0,8,0,61,0,100,0,91,412,0,0,89,20,0,0,0,0,0,1,0,0,0,0,0,0,0,"Stitches - On Waypoint 91 Reached - Start Random Movement"); + +DELETE FROM `creature_text` WHERE `entry` IN (468, 412); +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `comment`, `BroadcastTextId`) VALUES +(468, 0, 0, 'An abomination of the undead is approaching!', 14, 0, 100, 0, 0, 0, 'Guard', 89), +(468, 1, 0, 'The abomination has overrun the Night Watch camp! Quickly, we must intercept it before it reaches town!', 14, 0, 100, 0, 0, 0, 'Guard', 90), +(412, 0, 0, 'ROARRRRR!!', 14, 0, 100, 0, 0, 0, 'Stitches', 278), +(412, 0, 1, 'DARKSHIRE... I HUNGER!!', 14, 0, 100, 0, 0, 0, 'Stitches', 277); diff --git a/sql/updates/world/2016_02_09_04_world.sql b/sql/updates/world/2016_02_09_04_world.sql new file mode 100644 index 00000000000..015ab519557 --- /dev/null +++ b/sql/updates/world/2016_02_09_04_world.sql @@ -0,0 +1,5 @@ +-- +SET @SPELL_ATTR0_CU_ALLOW_INFLIGHT_TARGET := 262144; +DELETE FROM `spell_custom_attr` WHERE `entry`=43419; +INSERT INTO `spell_custom_attr` (`entry`, `attributes`) VALUES +(43419, @SPELL_ATTR0_CU_ALLOW_INFLIGHT_TARGET); diff --git a/sql/updates/world/2016_02_09_05_world.sql b/sql/updates/world/2016_02_09_05_world.sql new file mode 100644 index 00000000000..3612c270d02 --- /dev/null +++ b/sql/updates/world/2016_02_09_05_world.sql @@ -0,0 +1,62 @@ +-- +-- DB/Quest: Absholutely... Thish Will Work (11330) +SET @Prisoner :=24284; -- Dragonflayer Vrykul Prisoner +SET @PeppysMix :=43386; -- Spell Peppy's Special Mix +SET @WGDefender :=23842; -- Westguard Defender +SET @WGDguid1 :=99009; -- Westguard Defender Guid 1 +SET @WGDguid2 :=99010; -- Westguard Defender Guid 2 +SET @WGDguid3 :=99008; -- Westguard Defender Guid 3 +SET @WGDguid4 :=99013; -- Westguard Defender Guid 4 +SET @WGOfficer :=23844; -- Westguard Officer +SET @WGOguid :=99195; -- Westguard Officer Guid +SET @HumoVerde :=18951; -- Spirit Particles (green) / humo verde +SET @CuerpoVerde:=39168; -- Vertex Color Green / efecto verde +SET @MocoVerde :=28989; -- Plague Slime (Green) / Morph de Moco-Ooze +SET @Crazed :=48147; -- Crazed (enrage) - Only Defender +SET @Defensive :=7164; -- Defensive stance +SET @ImpBlocking:=3639; -- improved blocking +SET @ShieldBash :=11972; -- Shield Bash +SET @Shoot :=6660; -- Shoot +SET @DemorlShout:=16244; -- Demoralizing Shout - Only Officer + +UPDATE `creature_template` SET `ainame`='SmartAI' WHERE `entry` IN (@Prisoner,@WGDefender,@WGOfficer); +DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@Prisoner,@WGDefender,@WGOfficer) AND `source_type`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid` IN (@Prisoner*100) AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(@Prisoner,0,0,0,8,0,100,0,@PeppysMix,0,0,0,80,@Prisoner*100,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - On Spell Hit (Olakin''s Torch) - Run Script'), +(@Prisoner*100,9,0,0,0,0,100,0,0,0,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Say'), +(@Prisoner*100,9,1,0,0,0,100,0,3000,3000,0,0,11,@HumoVerde,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Cast Spirit Particles (green)'), +(@Prisoner*100,9,2,0,0,0,100,0,1000,1000,0,0,45,1,1,0,0,0,0,10,@WGDguid1,@WGDefender,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Set Data to Westguard Defender'), +(@Prisoner*100,9,3,0,0,0,100,0,3000,3000,0,0,45,1,1,0,0,0,0,10,@WGDguid3,@WGDefender,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Set Data to Westguard Defender'), +(@Prisoner*100,9,4,0,0,0,100,0,2000,2000,0,0,11,@CuerpoVerde,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Vertex Color Green'), +(@Prisoner*100,9,5,0,0,0,100,0,2000,2000,0,0,45,1,1,0,0,0,0,10,@WGDguid2,@WGDefender,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Set Data to Westguard Defender'), +(@Prisoner*100,9,6,0,0,0,100,0,3000,3000,0,0,45,1,1,0,0,0,0,10,@WGDguid4,@WGDefender,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Set Data to Westguard Defender'), +(@Prisoner*100,9,7,0,0,0,100,0,2000,2000,0,0,11,@MocoVerde,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Plague Slime (Green)'), +(@Prisoner*100,9,8,0,0,0,100,0,3000,3000,0,0,45,1,1,0,0,0,0,10,@WGOguid,@WGOfficer,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Set Data to Westguard Defender'), +(@Prisoner*100,9,9,0,0,0,100,0,2000,2000,0,0,33,@Prisoner,0,0,0,0,0,7,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Call Killedmonster'), +(@Prisoner*100,9,10,0,0,0,100,0,20000,20000,0,0,28,@HumoVerde,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Remove Spirit Particles'), +(@Prisoner*100,9,11,0,0,0,100,0,0,0,0,0,28,@CuerpoVerde,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Remove Vertex Color Green'), +(@Prisoner*100,9,12,0,0,0,100,0,0,0,0,0,28,@MocoVerde,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Remove Plage Slime'), +(@WGDefender,0,0,0,38,0,100,0,1,1,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - On Data set - Say'), +(@WGDefender,0,1,0,0,0,100,0,5000,15000,20000,40000,11,@Crazed,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - IC - Cast Crazed'), +(@WGDefender,0,2,0,0,0,100,1,500,500,0,0,11,@Defensive,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - IC - Cast Defensive'), +(@WGDefender,0,3,0,0,0,100,0,1000,3000,10400,10400,11,@ImpBlocking,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - IC - Cast Improved Blocking'), +(@WGDefender,0,4,0,0,0,100,0,2000,5000,10000,21000,11,@ShieldBash,0,0,0,0,0,2,0,0,0,0,0,0,0,'Westguard Defender - IC - Cast ShieldBash'), +(@WGDefender,0,5,0,0,0,100,0,0,5000,1000,6000,11,@Shoot,0,0,0,0,0,2,0,0,0,0,0,0,0,'Westguard Defender - IC - Cast Shoot'), +(@WGOfficer,0,0,0,38,0,100,0,1,1,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Officer - On Data set - Say'), +(@WGOfficer,0,1,0,0,0,100,0,10000,15000,20000,30000,11,@DemorlShout,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Officer - IC - Cast Demoralizing Shout'), +(@WGOfficer,0,2,0,0,0,100,1,500,500,0,0,11,@Defensive,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Officer - IC - Cast Defensive'), +(@WGOfficer,0,3,0,0,0,100,0,1000,3000,10400,10400,11,@ImpBlocking,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Officer - IC - Cast Improved Blocking'), +(@WGOfficer,0,4,0,0,0,100,0,2000,5000,8000,21000,11,@ShieldBash,0,0,0,0,0,2,0,0,0,0,0,0,0,'Westguard Officer - IC - Cast ShieldBash'), +(@WGOfficer,0,5,0,0,0,100,0,0,5000,1000,6000,11,@Shoot,0,0,0,0,0,2,0,0,0,0,0,0,0,'Westguard Officer - IC - Cast Shoot'); + +DELETE FROM `creature_text` WHERE `entry` IN (@Prisoner,@WGDefender,@WGOfficer); +INSERT INTO `creature_text` (`entry`,`groupid`,`id`,`text`,`type`,`language`,`probability`,`emote`,`duration`,`sound`,`comment`, `BroadcastTextId`) VALUES +(@Prisoner,0,0,'The vrykul clutches at his throat as he begins to gag and thrash about.',16,0,100,1,0,0,'Dragonflayer Vrykul Prisoner', 23087), +(@WGOfficer,0,0,'Is he okay?',12,0,100,1,0,0,'Westguard Officer - Say', 23105), +(@WGDefender,0,0,'Yikes.',12,0,100,1,0,0,'Westguard Defender - Say', 23104), +(@WGDefender,0,1,'Captain''s not gonna like this.',12,0,100,1,0,0,'Westguard Defender - Say', 23106), +(@WGDefender,0,2,'What kind of sicko are you?',12,0,100,1,0,0,'Westguard Defender - Say', 23095), +(@WGDefender,0,3,'Heh, cool!',12,0,100,1,0,0,'Westguard Defender - Say', 23094), +(@WGDefender,0,4,'That''s the new Forsaken plague?',12,0,100,1,0,0,'Westguard Defender - Say', 23098), +(@WGDefender,0,5,'Oh, sick!',12,0,100,1,0,0,'Westguard Defender - Say', 23091); diff --git a/sql/updates/world/2016_02_09_06_world.sql b/sql/updates/world/2016_02_09_06_world.sql new file mode 100644 index 00000000000..03fe998cca5 --- /dev/null +++ b/sql/updates/world/2016_02_09_06_world.sql @@ -0,0 +1,14 @@ +-- Karazhan Optional Boss spawn +-- Hyakiss the Lurker SAI +SET @ENTRY := 16179; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,0,0,100,0,5000,5000,35000,35000,11,29901,0,0,0,0,0,2,0,0,0,0,0,0,0,"Hyakiss the Lurker - In Combat - Cast 'Acidic Fang'"); + +-- Rokad the Ravager SAI +SET @ENTRY := 16181; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,0,0,100,0,2000,3000,12000,15000,11,29906,0,0,0,0,0,2,0,0,0,0,0,0,0,"Rokad the Ravager - In Combat - Cast 'Ravage'"); diff --git a/sql/updates/world/2016_02_09_07_world.sql b/sql/updates/world/2016_02_09_07_world.sql new file mode 100644 index 00000000000..84d65e2eda5 --- /dev/null +++ b/sql/updates/world/2016_02_09_07_world.sql @@ -0,0 +1,77 @@ +UPDATE `creature_template` SET `ainame`='SmartAI' WHERE `entry` IN(23842,24284); +DELETE FROM `smart_scripts` WHERE `entryorguid` IN(23842,24284) AND `source_type`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid` IN(23844) AND `source_type`=0 AND `id`=0; + +DELETE FROM `smart_scripts` WHERE `entryorguid` IN(2428400,2428401,2384200) AND `source_type`=9; + +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(23842,0,0,0,38,0,30,0,1,1,0,0,80,2384200,2,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - On Data Set - Run Script'), +(23842,0,1,0,0,0,100,0,5000,15000,20000,40000,11,48147,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - IC - Cast Crazed'), +(23842,0,2,0,0,0,100,1,500,500,0,0,11,7164,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - IC - Cast Defensive'), +(23842,0,3,0,0,0,100,0,1000,3000,10400,10400,11,3639,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - IC - Cast Improved Blocking'), +(23842,0,4,0,0,0,100,0,2000,5000,10000,21000,11,11972,0,0,0,0,0,2,0,0,0,0,0,0,0,'Westguard Defender - IC - Cast ShieldBash'), +(23842,0,5,0,0,0,100,0,0,5000,1000,6000,11,6660,0,0,0,0,0,2,0,0,0,0,0,0,0,'Westguard Defender - IC - Cast Shoot'), +(24284,0,0,0,8,0,100,0,43386,0,0,0,80,2428400,2,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - On Spell Hit (Peppys Special Mix) - Run Script'), +(24284,0,1,2,40,0,100,0,1,24284,0,0,1,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - On Reached WP1 - Say Line 0'), +(24284,0,2,0,61,0,100,0,0,0,0,0,54,1000,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - On Reached WP1 - Pause WP'), +(24284,0,3,4,40,0,100,0,9,24284,0,0,11,43401,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - On Reached WP9 - Cast Cosmetic - Blood Explosion Green - Large'), +(24284,0,4,5,61,0,100,0,0,0,0,0,3,0,1145,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - On Reached WP9 - Change displayid to 1145'), +(24284,0,5,0,61,0,100,0,0,0,0,0,22,2,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - On Reached WP9 - Set Phase 2'), +(24284,0,6,0,1,2,100,1,4000,4000,0,0,80,2428401,2,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - OOC (Phase 2) - Run Script'), +(2384200,9,0,0,0,0,100,0,0,0,0,0,66,0,0,0,0,0,0,19,24288,0,0,0,0,0,0,'Westguard Defender - Script - Face Target'), -- 19:36:43.046 +(2384200,9,1,0,0,0,100,0,0,0,0,0,90,8,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - Script - Set Bytes 1'), -- 19:36:43.046 +(2384200,9,2,0,0,0,100,0,1000,1000,0,0,11,43391,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - Script - Cast Vomit'), -- 19:36:44.231 +(2384200,9,3,0,0,0,100,0,9000,9000,0,0,91,8,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - Script - Set Bytes 1'), -- 19:36:53.872 +(2384200,9,4,0,0,0,100,0,0,0,0,0,24,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Westguard Defender - Script - Evade'), +(2428401,9,0,0,0,0,100,0,0,0,0,0,1,1,0,0,0,0,0,10,99027,23842,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script 2 - Say'), +(2428401,9,1,0,0,0,100,0,0,0,0,0,1,1,0,0,0,0,0,10,99023,23842,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script 2 - Say'), +(2428401,9,2,0,0,0,100,0,0,0,0,0,1,1,0,0,0,0,0,10,99012,23842,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script 2 - Say'), +(2428401,9,3,0,0,0,100,0,0,0,0,0,1,1,0,0,0,0,0,10,99010,23842,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script 2 - Say'), +(2428401,9,4,0,0,0,100,0,0,0,0,0,1,1,0,0,0,0,0,10,99024,23842,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script 2 - Say'), +(2428401,9,5,0,0,0,100,0,0,0,0,0,1,1,0,0,0,0,0,10,99026,23842,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script 2 - Say'), +(2428401,9,6,0,0,0,100,0,0,0,0,0,45,1,1,0,0,0,0,9,23842,0,80,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script 2 - Set Data'), +(2428401,9,7,0,0,0,100,0,1000,1000,0,0,37,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script 2 - Cast Suicide, No Blood, No Logging'), +(2428400,9,0,0,0,0,100,0,0,0,0,0,5,7,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Play Emote (OneShotEat)'), -- 19:36:18.195 +(2428400,9,1,0,0,0,100,0,0,0,0,0,71,0,0,2200,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Equip item 2200 to Slot 1'), -- 19:36:18.195 +(2428400,9,2,0,0,0,100,0,2800,2800,0,0,11,21862,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Cast Radiation'), -- 19:36:20.925 +(2428400,9,3,0,0,0,100,0,0,0,0,0,33,24284,0,0,0,0,0,7,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Give Quest Credit'), +(2428400,9,4,0,0,0,100,0,0,0,0,0,71,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - UnEquip item'), -- 19:36:20.925 +(2428400,9,5,0,0,0,100,0,0,0,0,0,91,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Remove Bytes 1'), -- 19:36:20.925 +(2428400,9,6,0,0,0,100,0,3200,3200,0,0,4,9110,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Play Sound 9110'), -- 19:36:23.421 +(2428400,9,7,0,0,0,100,0,0,0,0,0,5,53,0,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Play Emote OneShotBattleRoar'), -- 19:36:23.421 +(2428400,9,8,0,0,0,100,0,1200,1200,0,0,53,0,24284,0,0,0,0,1,0,0,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Start WP'), -- 19:36:24.622 +(2428400,9,9,0,0,0,100,0,0,0,0,0,1,0,0,0,0,0,0,10,99027,23842,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Say'), -- 19:36:24.622 +(2428400,9,10,0,0,0,100,0,0,0,0,0,1,0,0,0,0,0,0,10,99023,23842,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Say'), -- 19:36:24.622 +(2428400,9,11,0,0,0,100,0,0,0,0,0,1,0,0,0,0,0,0,10,99012,23842,0,0,0,0,0,'Dragonflayer Vrykul Prisoner - Script - Say'); -- 19:36:24.622 + + +DELETE FROM `waypoints` WHERE `entry`=24284; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES +(24284, 1, 1366.673, -3179.636, 153.576, 'Dragonflayer Vrykul Prisoner'), +(24284, 2, 1367.06, -3177.925, 153.576, 'Dragonflayer Vrykul Prisoner'), +(24284, 3, 1368.679, -3181.09, 153.576, 'Dragonflayer Vrykul Prisoner'), +(24284, 4, 1367.308, -3179.079, 153.576, 'Dragonflayer Vrykul Prisoner'), +(24284, 5, 1366.374, -3179.791, 153.576, 'Dragonflayer Vrykul Prisoner'), +(24284, 6, 1365.373, -3179.188, 153.576, 'Dragonflayer Vrykul Prisoner'), +(24284, 7, 1365.733, -3179.677, 153.576, 'Dragonflayer Vrykul Prisoner'), +(24284, 8, 1366.468, -3176.728, 153.576, 'Dragonflayer Vrykul Prisoner'), +(24284, 9, 1365.269, -3181.054, 153.576, 'Dragonflayer Vrykul Prisoner'); + +DELETE FROM `creature_text` WHERE `entry`IN(24284,23842); +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `BroadcastTextID`, `comment`) VALUES +(24284, 0, 0, 'The vrykul clutches at his throat as he begins to gag and thrash about.', 16, 0, 100, 53, 0, 0, 23087, 'Dragonflayer Vrykul Prisoner to Player'), +(23842, 0, 0, 'Uh...?', 12, 7, 100, 1, 0, 0, 23103, 'Westguard Defender to Player'), +(23842, 0, 1, 'Interesting.', 12, 7, 100, 1, 0, 0, 23107, 'Westguard Defender to Player'), +(23842, 0, 2, 'Yikes.', 12, 7, 100, 0, 0, 0, 23104, 'Westguard Defender to Player'), +(23842, 0, 3, 'Is he okay?', 12, 7, 100, 0, 0, 0, 23105, 'Westguard Defender to Player'), +(23842, 0, 4, 'Captain''s not gonna like this.', 12, 7, 100, 0, 0, 0, 23106, 'Westguard Defender to Player'), +(23842, 0, 5, 'Whoa.', 12, 7, 100, 0, 0, 0, 23108, 'Westguard Defender to Player'), +(23842, 1, 0, 'I didn''t know they could do that.', 12, 7, 100, 1, 0, 0, 23096, 'Westguard Defender to Player'), +(23842, 1, 1, 'That''s... special.', 12, 7, 100, 1, 0, 0, 23097, 'Westguard Defender to Player'), +(23842, 1, 2, 'Heh, cool!', 12, 7, 100, 1, 0, 0, 23094, 'Westguard Defender to Player'), +(23842, 1, 3, 'That''s the new Forsaken plague?', 12, 7, 100, 1, 0, 0, 23098, 'Westguard Defender to Player'), +(23842, 1, 4, 'What kind of sicko are you?', 12, 7, 100, 1, 0, 0, 23095, 'Westguard Defender to Player'), +(23842, 1, 5, 'Oh, sick!', 12, 7, 100, 1, 0, 0, 23091, 'Westguard Defender to Player'), +(23842, 1, 6, 'I feel ill.', 12, 7, 100, 1, 0, 0, 23093, 'Westguard Defender to Player'), +(23842, 1, 7, 'That did NOT just happen!', 12, 7, 100, 1, 0, 0, 23092, 'Westguard Defender to Player'); + diff --git a/sql/updates/world/2016_02_09_08_world.sql b/sql/updates/world/2016_02_09_08_world.sql new file mode 100644 index 00000000000..307a9f9a0b3 --- /dev/null +++ b/sql/updates/world/2016_02_09_08_world.sql @@ -0,0 +1 @@ +UPDATE `gameobject` SET `state`=1 WHERE `guid`=61216; diff --git a/sql/updates/world/2016_02_10_00_world.sql b/sql/updates/world/2016_02_10_00_world.sql new file mode 100644 index 00000000000..872861b08dc --- /dev/null +++ b/sql/updates/world/2016_02_10_00_world.sql @@ -0,0 +1,18 @@ +-- Pathing for Kalecgos Entry: 24844 'TDB FORMAT' +SET @NPC := 24844; +SET @PATH := @NPC * 10; +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,163.9735,-398.0906,2.083333,0,0,0,0,100,0), -- 16:16:43 +(@PATH,2,164.3802,-397.1771,2.083333,0,0,0,0,100,0), -- 16:16:43 +(@PATH,3,162.7923,-386.1964,15.67094,0,0,0,0,100,0), -- 16:16:43 +(@PATH,4,151.5555,-345.349,5.92646,0,0,0,0,100,0), -- 16:16:43 +(@PATH,5,162.2416,-299.8032,-5.436685,0,0,0,0,100,0), -- 16:16:43 +(@PATH,6,199.7482,-272.3315,-7.186677,0,0,0,0,100,0), -- 16:16:43 +(@PATH,7,199.7482,-272.3315,-7.186677,0,0,0,0,100,0), -- 16:16:43 +(@PATH,8,199.7482,-272.3315,-7.186677,0.06981317,0,0,0,100,0); -- 16:16:54 +-- 0x1C2F2C4920184300001F1D000038BF6E .go 163.9735 -398.0906 2.083333 + +DELETE FROM `creature_text` WHERE `entry` = 24844 AND `groupid` = 0; +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES +(24844, 0, 0, 'Be still, mortals, and hearken to my words.', 14, 0, 100, 0, 0, 0, 23936, 3, 'Kalecgos - SAY_KALECGOS_SPAWN'); diff --git a/sql/updates/world/2016_02_10_01_world.sql b/sql/updates/world/2016_02_10_01_world.sql new file mode 100644 index 00000000000..9ffe2e81c1c --- /dev/null +++ b/sql/updates/world/2016_02_10_01_world.sql @@ -0,0 +1,21 @@ +-- Nethurbian Crater KC Bunny SAI +SET @ENTRY := 28352; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,1,8,0,100,0,51381,0,180000,180000,33,28352,0,0,0,0,0,7,0,0,0,0,0,0,0,"Nethurbian Crater KC Bunny - On Spellhit 'Toss Grenade' - Quest Credit ''"), +(@ENTRY,0,1,0,61,0,100,0,51381,0,180000,180000,45,1,1,0,0,0,0,20,190555,2,0,0,0,0,0,"Nethurbian Crater KC Bunny - On Spellhit 'Toss Grenade' - Set Data 1 1"); + +-- Nerubian Crater SAI +SET @ENTRY := 190555; +UPDATE `gameobject_template` SET `AIName`="SmartGameObjectAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=1; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,1,0,0,38,0,100,0,1,1,0,0,80,@ENTRY*100+00,2,0,0,0,0,1,0,0,0,0,0,0,0,"Nerubian Crater - On Data Set 1 1 - Run Script"); + +-- Actionlist SAI +SET @ENTRY := 19055500; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,9,0,0,0,0,100,0,0,0,0,0,44,2,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Set Phase 2"), +(@ENTRY,9,1,0,0,0,100,0,180000,180000,0,0,44,1,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Set Phase 1"); diff --git a/sql/updates/world/2016_02_10_02_world.sql b/sql/updates/world/2016_02_10_02_world.sql new file mode 100644 index 00000000000..92ee165dd83 --- /dev/null +++ b/sql/updates/world/2016_02_10_02_world.sql @@ -0,0 +1,19 @@ +DELETE FROM `gossip_menu_option` WHERE `menu_id`=9546; +INSERT INTO `gossip_menu_option` (`menu_id`, `id`, `option_icon`, `option_text`, `OptionBroadcastTextID`, `option_id`, `npc_option_npcflag`, `action_menu_id`, `action_poi_id`, `box_coded`, `box_money`, `box_text`, `BoxBroadcastTextID`) VALUES +(9546, 0, 2, 'Where would you like to fly to?', 10753, 4, 8192, 0, 0, 0, 0, '', 0), +(9546, 1, 0, 'I need to get to Wintergarde Keep fast!', 26697, 1, 1, 0, 0, 0, 0, '', 0), +(9546, 2, 0, 'Greer, I need a gryphon to ride and some bombs to drop on New Agamand!', 23112, 1, 1, 0, 0, 0, 0, '', 0); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=9546; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(15, 9546, 1, 0, 0, 28, 0, 12298, 0, 0, 0, 0, 0, '', 'Greer Orehammer - Show gossip option only if player has taken quest 12298'), +(15, 9546, 2, 0, 0, 9, 0, 11332, 0, 0, 0, 0, 0, '', 'Greer Orehammer - Show gossip option only if player has taken quest 11332'); + +DELETE FROM `smart_scripts` WHERE `entryorguid`=23859 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(23859, 0, 0, 0, 4, 0, 100, 0, 0, 0, 0, 0, 80, 2385900, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Greer Orehammer - On Aggro - Run Script'), +(23859, 0, 1, 2, 62, 0, 100, 0, 9546, 2, 0, 0, 56, 33634, 10, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Greer Orehammer - On Gossip Option 1 Selected - Add Item \'Orehammer\'s Precision Bombs\' 10 Times'), +(23859, 0, 2, 3, 61, 0, 100, 0, 0, 0, 0, 0, 52, 745, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Greer Orehammer - On Gossip Option 1 Selected - Cast \'High Commander Halford Wyrmbane: Westguard Keep to Wintergarde Keep Taxi\''), +(23859, 0, 3, 0, 61, 0, 100, 0, 0, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Greer Orehammer - On Gossip Option 1 Selected - Close Gossip'), +(23859, 0, 4, 5, 62, 0, 100, 0, 9546, 1, 0, 0, 11, 48862, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Greer Orehammer - On gossip select - Invoker spellcast'), +(23859, 0, 5, 0, 61, 0, 100, 0, 0, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Greer Orehammer - On gossip select - Close gossip'); diff --git a/sql/updates/world/2016_02_10_03_world.sql b/sql/updates/world/2016_02_10_03_world.sql new file mode 100644 index 00000000000..f52872c3431 --- /dev/null +++ b/sql/updates/world/2016_02_10_03_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `gameobject` SET `spawnmask`=1 WHERE `map`=229; diff --git a/sql/updates/world/2016_02_10_04_world.sql b/sql/updates/world/2016_02_10_04_world.sql new file mode 100644 index 00000000000..1349b83f442 --- /dev/null +++ b/sql/updates/world/2016_02_10_04_world.sql @@ -0,0 +1,6 @@ +-- Honor among thieves +DELETE FROM `spell_script_names` WHERE `scriptname` = 'spell_rog_honor_among_thieves'; +DELETE FROM `spell_script_names` WHERE `scriptname` = 'spell_rog_honor_among_thieves_proc'; +INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES +(-51698, 'spell_rog_honor_among_thieves'), +(52916, 'spell_rog_honor_among_thieves_proc'); diff --git a/sql/updates/world/2016_02_10_05_world.sql b/sql/updates/world/2016_02_10_05_world.sql new file mode 100644 index 00000000000..c19dd8feb06 --- /dev/null +++ b/sql/updates/world/2016_02_10_05_world.sql @@ -0,0 +1,7 @@ +-- +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=17 AND `SourceEntry`=47482; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(17, 0, 47482, 0, 0, 21, 0, 1024, 0, 0, 1, 103, 0, '', 'Ghoul Leap - not using Ghoul Leap while rooted'); +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=17 AND `SourceEntry`=49376; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(17, 0, 49376, 0, 0, 21, 0, 1024, 0, 0, 1, 103, 0, '', 'Cat charge - not using Cat charge while rooted'); diff --git a/sql/updates/world/2016_02_10_06_world.sql b/sql/updates/world/2016_02_10_06_world.sql new file mode 100644 index 00000000000..9e24ab31ce1 --- /dev/null +++ b/sql/updates/world/2016_02_10_06_world.sql @@ -0,0 +1,26 @@ +UPDATE `creature_template` SET `ainame`='SmartAI' WHERE `entry` IN(24283); +DELETE FROM `smart_scripts` WHERE `entryorguid` IN(24283) AND `source_type`=0; + +DELETE FROM `smart_scripts` WHERE `entryorguid` IN(2428300) AND `source_type`=9; + +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(24283,0,0,0,20,1,100,0,11328,0,0,0,80,2428300,2,0,0,0,0,1,0,0,0,0,0,0,0,'Peppy Wrongnozzle - On Quest Reward (Mission: Forsaken Intel) - Run Script'), +(24283,0,1,0,25,0,100,0,0,0,0,0,22,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Peppy Wrongnozzle - On Spawn - Set Phase 1'), +(24283,0,2,0,1,1,100,0,8000,10000,8000,10000,5,92,0,0,0,0,0,1,0,0,0,0,0,0,0,'Peppy Wrongnozzle - OOC (Phase 1) - Play emote OneShotEatNoSheathe'), +(2428300,9,0,0,0,0,100,0,0,0,0,0,22,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Peppy Wrongnozzle - Script - Set Phase 2'), +(2428300,9,1,0,0,0,100,0,0,0,0,0,66,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Peppy Wrongnozzle - Script - Face Player '), -- 19:35:27.323 +(2428300,9,2,0,0,0,100,0,0,0,0,0,71,0,0,2200,3698,0,0,1,0,0,0,0,0,0,0,'Peppy Wrongnozzle - Script - Equip item 2200 to Slot 1 & 3698 to slot 2'), -- 19:35:27.573 +(2428300,9,3,0,0,0,100,0,700,700,0,0,17,133,0,0,0,0,0,1,0,0,0,0,0,0,0,'Peppy Wrongnozzle - Script - Set Emote state 133'), -- 19:35:29.226 +(2428300,9,4,0,0,0,100,0,5000,5000,0,0,17,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Peppy Wrongnozzle - Script - Set Emote state 0'), -- 19:35:34.405 +(2428300,9,5,0,0,0,100,0,1300,1300,0,0,71,0,0,2705,0,0,0,1,0,0,0,0,0,0,0,'Peppy Wrongnozzle - Script - Equip item 2705 to Slot 1 & Unequip slot 2'), -- 19:35:35.638 +(2428300,9,6,0,0,0,100,0,0,0,0,0,1,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Peppy Wrongnozzle - Script - Say Line 0'), -- 19:35:35.638 +(2428300,9,7,0,0,0,100,0,0,0,0,0,22,1,0,0,0,0,0,1,0,0,0,0,0,0,0,'Peppy Wrongnozzle - Script - Set Phase 1'), +(2428300,9,8,0,0,0,100,0,0,0,0,0,24,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Peppy Wrongnozzle - Script - Evade'); + +DELETE FROM `creature_template_addon` WHERE `entry`=24283; +INSERT INTO `creature_template_addon` (`entry`, `mount`, `bytes1`, `bytes2`, `auras`) VALUES +(24283, 0, 0x0, 0x101, '35777'); -- 24283 - 35777 + +DELETE FROM `creature_text` WHERE `entry`IN(24283); +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `BroadcastTextID`, `comment`) VALUES +(24283, 0, 0, 'Right, that should do it. I think ...hic.', 12, 7, 100, 396, 0, 0, 23086, 'Peppy Wrongnozzle to Player'); diff --git a/sql/updates/world/2016_02_10_07_world.sql b/sql/updates/world/2016_02_10_07_world.sql new file mode 100644 index 00000000000..5feb4f44163 --- /dev/null +++ b/sql/updates/world/2016_02_10_07_world.sql @@ -0,0 +1,6 @@ +-- +DELETE FROM `command` WHERE `name`="debug raidreset"; +INSERT INTO `command` (`name`,`permission`,`help`) VALUES ("debug raidreset",414,"Syntax: .debug raidreset mapid [difficulty] +Forces a global reset of the specified map on all difficulties (or only the specific difficulty if specified). Effectively the same as setting the specified map's reset timer to now."); + +UPDATE `trinity_string` SET `content_default`="Map: %d | ID: %d | perm: %s | extended: %s | diff: %d | canReset: %s | TTR: %s" WHERE `entry`=5045; diff --git a/sql/updates/world/2016_02_11_00_world.sql b/sql/updates/world/2016_02_11_00_world.sql new file mode 100644 index 00000000000..b130133a2ca --- /dev/null +++ b/sql/updates/world/2016_02_11_00_world.sql @@ -0,0 +1,6 @@ +-- Scarlet Insignia Ring - Questloot +DELETE FROM `creature_loot_template` WHERE `Entry` IN (1538,1539,1540) AND `Item`= 2875; +INSERT INTO `creature_loot_template` (`Entry`,`Item`,`Reference`,`Chance`,`QuestRequired`,`LootMode`,`GroupId`,`MinCount`,`MaxCount`,`Comment`) VALUES +(1538, 2875, 0, 40, 1, 1, 0, 1, 1, 'Scarlet Friar - Scarlet Insignia Ring'), +(1539, 2875, 0, 40, 1, 1, 0, 1, 1, 'Scarlet Neophyte - Scarlet Insignia Ring'), +(1540, 2875, 0, 40, 1, 1, 0, 1, 1, 'Scarlet Vanguard - Scarlet Insignia Ring'); diff --git a/sql/updates/world/2016_02_11_01_world.sql b/sql/updates/world/2016_02_11_01_world.sql new file mode 100644 index 00000000000..ec1c98659e1 --- /dev/null +++ b/sql/updates/world/2016_02_11_01_world.sql @@ -0,0 +1,5 @@ +-- Imperial Eagle SAI +SET @ENTRY := 26369; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`=1; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,1,0,8,0,100,0,49546,0,0,0,41,4000,0,0,0,0,0,1,0,0,0,0,0,0,0,"Imperial Eagle - On Spellhit 'Eagle Eyes' - Despawn In 4000 ms"); diff --git a/sql/updates/world/2016_02_11_02_world.sql b/sql/updates/world/2016_02_11_02_world.sql new file mode 100644 index 00000000000..9228e2d99d7 --- /dev/null +++ b/sql/updates/world/2016_02_11_02_world.sql @@ -0,0 +1,18 @@ +-- DB/Item: Sealed Tome +DELETE FROM `gameobject_loot_template` WHERE `Entry`=18509; +INSERT INTO `gameobject_loot_template` (`Entry`, `Item`, `Reference`, `Chance`, `QuestRequired`, `LootMode`, `GroupId`, `MinCount`, `MaxCount`, `Comment`) VALUES +(18509,1054,1054,100,0,1,1,1,1,NULL); + +DELETE FROM `reference_loot_template` WHERE `Entry`=1054; +INSERT INTO `reference_loot_template` (`Entry`, `Item`, `Reference`, `Chance`, `QuestRequired`, `LootMode`, `GroupId`, `MinCount`, `MaxCount`, `Comment`) VALUES +(1054,23864,0,0,0,1,1,1,1,NULL), -- Torment of the Worgen +(1054,23857,0,0,0,1,1,1,1,NULL), -- Legacy of the Mountain King +(1054,23862,0,0,0,1,1,1,1,NULL), -- Redemption of the Fallen +(1054,23865,0,0,0,1,1,1,1, NULL); -- Wrath of the Titans + +DELETE FROM `conditions` WHERE `SourceEntry` IN (30562, 30557, 30550, 30567) AND `SourceTypeOrReferenceId`=17; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `Comment`) VALUES +(17,0,30562,0,0,23,0,3457,0,0,0,0,0,'Legacy of the Mountain King needs area 3457'), +(17,0,30557,0,0,23,0,3457,0,0,0,0,0,'Wrath of the Titans needs area 3457'), +(17,0,30550,0,0,23,0,3457,0,0,0,0,0,'Redemption of the Fallen needs area 3457'), +(17,0,30567,0,0,23,0,3457,0,0,0,0,0,'Torment of the Worgen needs area 3457'); diff --git a/sql/updates/world/2016_02_11_03_world.sql b/sql/updates/world/2016_02_11_03_world.sql new file mode 100644 index 00000000000..4dfefb12281 --- /dev/null +++ b/sql/updates/world/2016_02_11_03_world.sql @@ -0,0 +1,11 @@ +-- DB/Quest: Souls at Unrest +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=17 AND `SourceGroup`=0 AND `SourceEntry`=48974; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(17, 0, 48974, 0, 0, 31, 1, 3, 26891, 0, 0, 0, 0, '', 'Burn Corpse - only targets Undead Miner'), +(17, 0, 48974, 0, 0, 36, 1, 0, 0, 0, 1, 0, 0, '', 'Burn Corpse - only targets dead Undead Miner'); + +-- Undead Miner SAI +SET @ENTRY := 26891; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0 AND `id`=2; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,2,0,8,0,100,0,48974,0,0,0,41,2000,0,0,0,0,0,1,0,0,0,0,0,0,0,"Undead Miner - On Spellhit 'Burn Corpse' - Despawn In 2000 ms"); diff --git a/sql/updates/world/2016_02_11_04_world.sql b/sql/updates/world/2016_02_11_04_world.sql new file mode 100644 index 00000000000..41f648b5f6e --- /dev/null +++ b/sql/updates/world/2016_02_11_04_world.sql @@ -0,0 +1,4 @@ +-- DB/Quest: The Exorcism ( Mage Quest 1955) +DELETE FROM `smart_scripts` WHERE `entryorguid`=6546 AND `id`=5; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(6546, 0, 5, 0, 19, 0, 100, 0, 1955, 0, 0, 0, 80, 654600, 2, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tabetha - On Quest \'The Exorcism\' Taken - Run Script (No Repeat)'); diff --git a/sql/updates/world/2016_02_11_05_world.sql b/sql/updates/world/2016_02_11_05_world.sql new file mode 100644 index 00000000000..76b59765d08 --- /dev/null +++ b/sql/updates/world/2016_02_11_05_world.sql @@ -0,0 +1,2 @@ +-- Iron Rune Avenger +UPDATE `creature_template` SET `flags_extra`=(`flags_extra`|2097152) WHERE `entry` IN (26786); diff --git a/sql/updates/world/2016_02_11_06_world.sql b/sql/updates/world/2016_02_11_06_world.sql new file mode 100644 index 00000000000..bbf9880dca9 --- /dev/null +++ b/sql/updates/world/2016_02_11_06_world.sql @@ -0,0 +1,206 @@ +SET @OGUID:=79584; +SET @CGUID:=61988; +SET @Event:=7; + +-- Add missing lunar objects +DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+182; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0 , 180766, 571, 1, 1, 5827.364, 638.9564, 647.2116, 1.082103, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 4613) +(@OGUID+1 , 180766, 571, 1, 1, 5827.502, 645.6351, 647.1417, 1.937312, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 4613) +(@OGUID+2 , 180766, 571, 1, 1, 5821.811, 633.4114, 647.1953, 0, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 4613) +(@OGUID+3 , 180766, 571, 1, 1, 5822.486, 652.9247, 647.212, 3.071766, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 4613) +(@OGUID+4 , 180766, 571, 1, 1, 5815.521, 643.1665, 647.1968, 4.642576, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 4613) +(@OGUID+5 , 180766, 571, 1, 1, 5818.29, 648.6586, 647.173, 4.118979, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 4613) +(@OGUID+6 , 180766, 571, 1, 1, 5818.406, 635.2549, 647.1855, 5.515242, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 4613) +(@OGUID+7 , 180766, 571, 1, 1, 5816.469, 638.8152, 647.1979, 5.113817, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 4613) +(@OGUID+8 , 180765, 571, 1, 1, 5862.578, 608.9785, 622.725, 3.525572, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 4613) +(@OGUID+9 , 180765, 571, 1, 1, 5818.557, 689.6754, 617.5377, 5.811947, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 4613) +(@OGUID+10 , 180765, 571, 1, 1, 5759.772, 714.2535, 653.2266, 1.867502, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 4620) +(@OGUID+11 , 180765, 571, 1, 1, 5760.561, 701.3275, 623.345, 4.520406, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 0) +(@OGUID+12 , 180765, 571, 1, 1, 5731.914, 677.9752, 653.3376, 3.071766, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 0) +(@OGUID+13 , 180765, 571, 1, 1, 5670.342, 779.5948, 669.5635, 5.550147, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 4569) +(@OGUID+14 , 180765, 571, 1, 1, 5753.294, 594.6252, 618.5057, 5.358162, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 4560) +(@OGUID+15 , 180765, 571, 1, 1, 5819.917, 557.6574, 655.4913, 5.742135, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 4570) +(@OGUID+16 , 180878, 571, 1, 1, 5831.143, 655.095, 647.124, 5.567601, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 4613) +(@OGUID+17 , 180878, 571, 1, 1, 5830.427, 655.5619, 647.1938, 2.687807, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 4613) +(@OGUID+18 , 180878, 571, 1, 1, 5829.478, 652.8141, 647.3889, 5.585054, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 4613) +(@OGUID+19 , 180878, 571, 1, 1, 5829.293, 656.304, 647.3473, 2.129301, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 4613) +(@OGUID+20 , 180878, 571, 1, 1, 5830.003, 656.1676, 647.2794, 3.543024, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 4613) +(@OGUID+21 , 180878, 571, 1, 1, 5829.671, 655.4982, 647.2844, 4.502952, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 4613) +(@OGUID+22 , 180878, 571, 1, 1, 5828.868, 653.2474, 647.4297, 4.869471, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 4613) +(@OGUID+23 , 180770, 571, 1, 1, 5948.266, 620.9393, 660.9077, 2.792518, 0, 0, 0, 1, 120, 255, 1), -- 180770 (Area: 4613) +(@OGUID+24 , 180770, 571, 1, 1, 5885.173, 625.6719, 667.6763, 5.637414, 0, 0, 0, 1, 120, 255, 1), -- 180770 (Area: 4613) +(@OGUID+25 , 180770, 571, 1, 1, 5834.693, 718.492, 659.2477, 4.06662, 0, 0, 0, 1, 120, 255, 1), -- 180770 (Area: 4613) +(@OGUID+26 , 180770, 571, 1, 1, 5728.38, 609.739, 668.472, 0.8901166, 0, 0, 0, 1, 120, 255, 1), -- 180770 (Area: 4560) +(@OGUID+27 , 180770, 571, 1, 1, 5671.689, 646.728, 664.1037, 0.2967052, 0, 0, 0, 1, 120, 255, 1), -- 180770 (Area: 4560) +(@OGUID+28 , 180770, 571, 1, 1, 5783.651, 561.3226, 663.734, 0.8901166, 0, 0, 0, 1, 120, 255, 1), -- 180770 (Area: 4560) +(@OGUID+29 , 180770, 571, 1, 1, 5659.569, 679.338, 662.2587, 5.864307, 0, 0, 0, 1, 120, 255, 1), -- 180770 (Area: 4560) +(@OGUID+30 , 180769, 571, 1, 1, 5909.365, 661.7691, 649.1791, 3.979355, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+31 , 180769, 571, 1, 1, 5886.387, 624.8147, 653.553, 2.460913, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+32 , 180769, 571, 1, 1, 5931.343, 575.7878, 615.0651, 3.857183, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+33 , 180769, 571, 1, 1, 5881.342, 611.066, 654.6136, 2.495818, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+34 , 180769, 571, 1, 1, 5901.177, 684.3577, 647.6432, 2.391098, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+35 , 180769, 571, 1, 1, 5929.563, 561.2188, 615.4888, 2.44346, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+36 , 180769, 571, 1, 1, 5913.596, 558.0538, 615.162, 1.274088, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+37 , 180769, 571, 1, 1, 5859.038, 634.4976, 653.8649, 5.585054, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+38 , 180769, 571, 1, 1, 5915.081, 710.2066, 646.7171, 3.071766, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+39 , 180769, 571, 1, 1, 5855.796, 664.7435, 653.7689, 0.9075702, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+40 , 180769, 571, 1, 1, 5858.535, 699.8768, 647.4109, 4.01426, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+41 , 180769, 571, 1, 1, 5852.463, 690.137, 614.8257, 4.031712, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+42 , 180769, 571, 1, 1, 5873.14, 725.0781, 647.2786, 1.780234, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+43 , 180769, 571, 1, 1, 5883.378, 741.8604, 644.6421, 4.921829, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+44 , 180769, 571, 1, 1, 5817.372, 694.9447, 653.3386, 0.8901166, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+45 , 180769, 571, 1, 1, 5901.752, 746.1671, 645.9257, 4.502952, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+46 , 180769, 571, 1, 1, 5864.876, 738.8313, 644.7396, 5.113817, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+47 , 180769, 571, 1, 1, 5835.081, 719.8969, 646.1445, 4.01426, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4613) +(@OGUID+48 , 180769, 571, 1, 1, 5786.942, 691.6105, 653.3179, 2.426008, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4620) +(@OGUID+49 , 180769, 571, 1, 1, 5768.04, 709.3449, 623.6602, 5.585054, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4620) +(@OGUID+50 , 180769, 571, 1, 1, 5768.866, 732.3944, 645.68, 5.777041, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4620) +(@OGUID+51 , 180769, 571, 1, 1, 5769.894, 668.6614, 650.4285, 2.460913, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 0) +(@OGUID+52 , 180769, 571, 1, 1, 5788.438, 653.5104, 654.6097, 5.602507, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 0) +(@OGUID+53 , 180769, 571, 1, 1, 5750.353, 646.9713, 656.329, 2.478367, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4560) +(@OGUID+54 , 180769, 571, 1, 1, 5753.372, 616.3696, 656.3885, 4.049168, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4560) +(@OGUID+55 , 180769, 571, 1, 1, 5730.582, 607.2877, 652.4621, 0.8901166, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4560) +(@OGUID+56 , 180769, 571, 1, 1, 5687.786, 619.9709, 652.2067, 0.5759573, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4560) +(@OGUID+57 , 180769, 571, 1, 1, 5675.173, 631.3223, 652.21, 0.5235979, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4560) +(@OGUID+58 , 180769, 571, 1, 1, 5671.983, 646.4656, 652.1304, 0.2967052, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4560) +(@OGUID+59 , 180769, 571, 1, 1, 5783.131, 561.6129, 655.8354, 0.8552105, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4560) +(@OGUID+60 , 180769, 571, 1, 1, 5809.257, 575.9974, 656.7222, 4.834563, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4560) +(@OGUID+61 , 180769, 571, 1, 1, 5844.062, 569.6259, 656.8289, 2.478367, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 4570) +(@OGUID+62 , 180763, 571, 1, 1, 5944.821, 630.5286, 652.4573, 2.967041, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4613) +(@OGUID+63 , 180763, 571, 1, 1, 5890.119, 630.0712, 650.7103, 2.391098, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4613) +(@OGUID+64 , 180763, 571, 1, 1, 5883.333, 613.3351, 651.5501, 2.33874, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4613) +(@OGUID+65 , 180763, 571, 1, 1, 5983.581, 603.4676, 653.0666, 2.862335, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4613) +(@OGUID+66 , 180763, 571, 1, 1, 5986.168, 610.6107, 653.0659, 2.967041, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 0) +(@OGUID+67 , 180763, 571, 1, 1, 5913.733, 726.7258, 645.9022, 3.298687, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4613) +(@OGUID+68 , 180763, 571, 1, 1, 5820.595, 692.2194, 647.6371, 0.9948372, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4613) +(@OGUID+69 , 180763, 571, 1, 1, 5867.973, 739.8099, 641.4172, 5.410522, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4613) +(@OGUID+70 , 180763, 571, 1, 1, 5903.759, 687.3698, 644.8055, 5.235988, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4620) +(@OGUID+71 , 180763, 571, 1, 1, 5871.152, 724.772, 643.811, 1.954769, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4620) +(@OGUID+72 , 180763, 571, 1, 1, 5752.106, 717.1315, 641.7864, 3.944446, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 0) +(@OGUID+73 , 180763, 571, 1, 1, 5746.831, 728.174, 641.7136, 4.031712, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 0) +(@OGUID+74 , 180763, 571, 1, 1, 5733.553, 726.9333, 642.7537, 2.548179, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 0) +(@OGUID+75 , 180763, 571, 1, 1, 5735.731, 678.2547, 647.2717, 5.532695, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 0) +(@OGUID+76 , 180763, 571, 1, 1, 5732.593, 674.2257, 647.2732, 2.932139, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+77 , 180763, 571, 1, 1, 5716.352, 722.8108, 643.5378, 0.9599299, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+78 , 180763, 571, 1, 1, 5709.845, 727.9358, 643.5585, 0.8726639, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+79 , 180763, 571, 1, 1, 5703.215, 733.3229, 643.576, 0.8203033, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+80 , 180763, 571, 1, 1, 5833.685, 645.7676, 610.1852, 4.118979, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+81 , 180763, 571, 1, 1, 5669.793, 808.6216, 655.2228, 4.171338, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4569) +(@OGUID+82 , 180763, 571, 1, 1, 5746.831, 728.174, 641.7136, 4.031712, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4569) +(@OGUID+83 , 180763, 571, 1, 1, 5657.733, 814.1997, 654.9894, 4.869471, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4569) +(@OGUID+84 , 180763, 571, 1, 1, 5640.182, 793.6152, 654.9894, 0.1919852, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4569) +(@OGUID+85 , 180763, 571, 1, 1, 5648.342, 782.4639, 654.989, 0.8203033, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4569) +(@OGUID+86 , 180763, 571, 1, 1, 5646.54, 805.8158, 654.9894, 5.707228, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4569) +(@OGUID+87 , 180763, 571, 1, 1, 5752.106, 717.1315, 641.7864, 3.944446, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4569) +(@OGUID+88 , 180763, 571, 1, 1, 5733.553, 726.9333, 642.7537, 2.548179, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+89 , 180763, 571, 1, 1, 5820.595, 692.2194, 647.6371, 0.9948372, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+90 , 180763, 571, 1, 1, 5703.215, 733.3229, 643.576, 0.8203033, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+91 , 180763, 571, 1, 1, 5689.638, 617.3722, 649.33, 0.802851, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+92 , 180763, 571, 1, 1, 5668.561, 683.9375, 653.5638, 5.951575, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+93 , 180763, 571, 1, 1, 5821.209, 557.6127, 652.8544, 1.815142, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4570) +(@OGUID+94 , 180763, 571, 1, 1, 5845.696, 572.116, 653.2255, 2.44346, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4570) +(@OGUID+95 , 180763, 571, 1, 1, 5828.66, 517.7811, 659.3014, 5.131269, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4570) +(@OGUID+96 , 180763, 571, 1, 1, 5735.731, 678.2547, 647.2717, 5.532695, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4570) +(@OGUID+97 , 180763, 571, 1, 1, 5732.593, 674.2257, 647.2732, 2.932139, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4570) +(@OGUID+98 , 180763, 571, 1, 1, 5883.333, 613.3351, 651.5501, 2.33874, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4570) +(@OGUID+99 , 180763, 571, 1, 1, 5890.119, 630.0712, 650.7103, 2.391098, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4570) +(@OGUID+100, 180763, 571, 1, 1, 5903.759, 687.3698, 644.8055, 5.235988, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 0) +(@OGUID+101, 180763, 571, 1, 1, 5944.821, 630.5286, 652.4573, 2.967041, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 0) +(@OGUID+102, 180763, 571, 1, 1, 5939.341, 616.0452, 652.3865, 2.740162, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 0) +(@OGUID+103, 180763, 571, 1, 1, 5871.152, 724.772, 643.811, 1.954769, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 0) +(@OGUID+104, 180763, 571, 1, 1, 5983.581, 603.4676, 653.0666, 2.862335, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+105, 180763, 571, 1, 1, 5828.66, 517.7811, 659.3014, 5.131269, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4560) +(@OGUID+106, 180763, 571, 1, 1, 5872.536, 687.5123, 647.7181, 4.136433, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4613) +(@OGUID+107, 180763, 571, 1, 1, 5812.34, 554.8807, 652.9316, 2.007128, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4616) +(@OGUID+108, 180763, 571, 1, 1, 5820.595, 692.2194, 647.6371, 0.9948372, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4739) +(@OGUID+109, 180763, 571, 1, 1, 5735.731, 678.2547, 647.2717, 5.532695, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4739) +(@OGUID+110, 180763, 571, 1, 1, 5733.001, 605.4604, 649.6217, 0.9948372, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 4739) +(@OGUID+111, 180764, 571, 1, 1, 5939.341, 616.0452, 652.3865, 2.740162, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+112, 180764, 571, 1, 1, 5930.153, 592.1089, 640.6768, 2.670348, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+113, 180764, 571, 1, 1, 5920.96, 592.6715, 640.6837, 1.937312, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+114, 180764, 571, 1, 1, 5938.111, 587.7853, 640.6421, 3.036838, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+115, 180764, 571, 1, 1, 5912.436, 589.316, 640.6563, 0.7330382, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+116, 180764, 571, 1, 1, 5943.503, 581.1985, 640.6602, 5.619962, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+117, 180764, 571, 1, 1, 5946.514, 572.8181, 640.6762, 3.42085, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+118, 180764, 571, 1, 1, 5986.168, 610.6107, 653.0659, 2.967041, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+119, 180764, 571, 1, 1, 5945.639, 564.164, 640.7072, 5.951575, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+120, 180764, 571, 1, 1, 5941.456, 556.3479, 640.7192, 1.658062, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+121, 180764, 571, 1, 1, 5934.847, 550.7705, 640.6883, 5.846854, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+122, 180764, 571, 1, 1, 5864.014, 600.7278, 652.6012, 2.373644, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+123, 180764, 571, 1, 1, 5903.759, 687.3698, 644.8055, 5.235988, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+124, 180764, 571, 1, 1, 5853.561, 587.517, 652.7214, 2.530723, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+125, 180764, 571, 1, 1, 5872.536, 687.5123, 647.7181, 4.136433, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+126, 180764, 571, 1, 1, 5914.998, 716.574, 643.6473, 3.194002, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+127, 180764, 571, 1, 1, 5893.063, 706.0598, 648.3202, 1.012289, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+128, 180764, 571, 1, 1, 5890.119, 630.0712, 650.7103, 2.391098, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 0) +(@OGUID+129, 180764, 571, 1, 1, 5938.111, 587.7853, 640.6421, 3.036838, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 0) +(@OGUID+130, 180764, 571, 1, 1, 5983.581, 603.4676, 653.0666, 2.862335, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 0) +(@OGUID+131, 180764, 571, 1, 1, 5912.436, 589.316, 640.6563, 0.7330382, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 0) +(@OGUID+132, 180764, 571, 1, 1, 5934.847, 550.7705, 640.6883, 5.846854, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 0) +(@OGUID+133, 180764, 571, 1, 1, 5872.536, 687.5123, 647.7181, 4.136433, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+134, 180764, 571, 1, 1, 5945.639, 564.164, 640.7072, 5.951575, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+135, 180764, 571, 1, 1, 5833.685, 645.7676, 610.1852, 4.118979, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+136, 180764, 571, 1, 1, 5827.226, 645.5917, 648.326, 3.316144, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+137, 180764, 571, 1, 1, 5845.696, 572.116, 653.2255, 2.44346, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+138, 180764, 571, 1, 1, 5871.152, 724.772, 643.811, 1.954769, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+139, 180764, 571, 1, 1, 5816.614, 639.0052, 648.413, 2.164206, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+140, 180764, 571, 1, 1, 5883.333, 613.3351, 651.5501, 2.33874, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+141, 180764, 571, 1, 1, 5898.784, 746.4573, 642.1553, 4.66003, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4613) +(@OGUID+142, 180764, 571, 1, 1, 5893.063, 706.0598, 648.3202, 1.012289, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4620) +(@OGUID+143, 180764, 571, 1, 1, 5763.81, 725.4814, 620.0308, 0.9424766, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4620) +(@OGUID+144, 180764, 571, 1, 1, 5763.81, 725.4814, 620.0308, 0.9424766, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4560) +(@OGUID+145, 180764, 571, 1, 1, 5867.973, 739.8099, 641.4172, 5.410522, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4560) +(@OGUID+146, 180764, 571, 1, 1, 5872.536, 687.5123, 647.7181, 4.136433, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4560) +(@OGUID+147, 180764, 571, 1, 1, 5733.001, 605.4604, 649.6217, 0.9948372, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4560) +(@OGUID+148, 180764, 571, 1, 1, 5674.231, 639.6476, 649.1661, 0.2792516, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4560) +(@OGUID+149, 180764, 571, 1, 1, 5785.611, 560.2617, 652.6686, 3.874631, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4560) +(@OGUID+150, 180764, 571, 1, 1, 5812.34, 554.8807, 652.9316, 2.007128, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4560) +(@OGUID+151, 180764, 571, 1, 1, 5662.389, 669.6667, 653.5421, 6.265733, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4560) +(@OGUID+152, 180764, 571, 1, 1, 5853.561, 587.517, 652.7214, 2.530723, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4570) +(@OGUID+153, 180764, 571, 1, 1, 5864.014, 600.7278, 652.6012, 2.373644, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4570) +(@OGUID+154, 180764, 571, 1, 1, 5920.96, 592.6715, 640.6837, 1.937312, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 0) +(@OGUID+155, 180764, 571, 1, 1, 5912.436, 589.316, 640.6563, 0.7330382, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 0) +(@OGUID+156, 180764, 571, 1, 1, 5930.153, 592.1089, 640.6768, 2.670348, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 0) +(@OGUID+157, 180764, 571, 1, 1, 5938.111, 587.7853, 640.6421, 3.036838, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 0) +(@OGUID+158, 180764, 571, 1, 1, 5943.503, 581.1985, 640.6602, 5.619962, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4560) +(@OGUID+159, 180764, 571, 1, 1, 5945.639, 564.164, 640.7072, 5.951575, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 4560) +(@OGUID+160, 180879, 571, 1, 1, 5829.639, 654.4427, 647.3204, 5.689774, 0, 0, 0, 1, 120, 255, 1), -- 180879 (Area: 4613) +(@OGUID+161, 180767, 571, 1, 1, 5867.941, 616.2357, 622.7247, 2.460913, 0, 0, 0, 1, 120, 255, 1), -- 180767 (Area: 4613) +(@OGUID+162, 180767, 571, 1, 1, 5897.854, 555.5522, 648.3434, 0.5061446, 0, 0, 0, 1, 120, 255, 1), -- 180767 (Area: 4613) +(@OGUID+163, 180767, 571, 1, 1, 5892.568, 549.7327, 648.2482, 2.740162, 0, 0, 0, 1, 120, 255, 1), -- 180767 (Area: 4613) +(@OGUID+164, 180767, 571, 1, 1, 5814.174, 684.2547, 617.5809, 4.450591, 0, 0, 0, 1, 120, 255, 1), -- 180767 (Area: 4613) +(@OGUID+165, 180767, 571, 1, 1, 5774.229, 717.9037, 623.3556, 2.199115, 0, 0, 0, 1, 120, 255, 1), -- 180767 (Area: 4620) +(@OGUID+166, 180767, 571, 1, 1, 5770.015, 581.1361, 618.5083, 2.495818, 0, 0, 0, 1, 120, 255, 1), -- 180767 (Area: 4560) +(@OGUID+167, 180767, 571, 1, 1, 5813.308, 555.64, 655.5086, 0.087266, 0, 0, 0, 1, 120, 255, 1), -- 180767 (Area: 4560) +(@OGUID+168, 188215, 571, 1, 1, 5927.629, 731.5903, 643.1697, 4.76475, 0, 0, 0, 1, 120, 255, 1), -- 188215 (Area: 4613) +(@OGUID+169, 180880, 571, 1, 1, 5828.156, 651.3569, 647.5219, 3.42085, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 4613) +(@OGUID+170, 180881, 571, 1, 1, 5829.097, 651.775, 647.4488, 4.799657, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 4613) +(@OGUID+171, 180882, 571, 1, 1, 5829.017, 651.1241, 647.4738, 3.769912, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 4613) +(@OGUID+172, 180883, 571, 1, 1, 5828.462, 652.3148, 647.4636, 5.445428, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 4613) +(@OGUID+173, 180883, 571, 1, 1, 5828.013, 651.9222, 647.5066, 5.811947, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 4613) +(@OGUID+174, 180868, 571, 1, 1, 5820.396, 633.1682, 647.392, 4.171338, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 4613) +(@OGUID+175, 180868, 571, 1, 1, 5818.986, 634.1285, 647.392, 4.118979, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 4613) +(@OGUID+176, 180868, 571, 1, 1, 5815.437, 644.6893, 647.392, 2.652894, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 4613) +(@OGUID+177, 180868, 571, 1, 1, 5818.691, 650.1199, 647.3958, 2.460913, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 4613) +(@OGUID+178, 180868, 571, 1, 1, 5817.034, 647.832, 647.392, 2.635444, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 4613) +(@OGUID+179, 180868, 571, 1, 1, 5819.984, 651.618, 647.4, 2.408554, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 4613) +(@OGUID+180, 180868, 571, 1, 1, 5816.064, 637.7977, 647.3924, 3.665196, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 4613) +(@OGUID+181, 180869, 571, 1, 1, 5816.274, 646.3437, 647.392, 2.652894, 0, 0, 0, 1, 120, 255, 1), -- 180869 (Area: 4613) +(@OGUID+182, 180869, 571, 1, 1, 5817.032, 636.2288, 647.392, 3.735006, 0, 0, 0, 1, 120, 255, 1); -- 180869 (Area: 4613) + +DELETE FROM `game_event_gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+182 AND `eventEntry`=@Event; +INSERT INTO `game_event_gameobject` SELECT @Event, gameobject.guid FROM `gameobject` WHERE gameobject.guid BETWEEN @OGUID+0 AND @OGUID+182; + +-- Add missing lunar spawns +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+5; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `curhealth`) VALUES +(@CGUID+0, 15892, 571, 5825.602, 642.9196, 647.8765, 3.106686, 120, 0), -- 15892 (Area: 4613) +(@CGUID+1, 15892, 571, 5820.262, 646.1699, 647.8525, 5.235988, 120, 0), -- 15892 (Area: 4613) +(@CGUID+2, 15892, 571, 5819.783, 639.3316, 647.9127, 1.029744, 120, 0), -- 15892 (Area: 4613) +(@CGUID+3, 15898, 571, 5827.147, 654.6258, 647.5777, 3.159046, 120, 0), -- 15898 (Area: 4613) (Auras: ) +(@CGUID+4, 15895, 571, 5824.651, 657.0713, 647.6139, 3.246312, 120, 0), -- 15895 (Area: 4613) (Auras: ) +(@CGUID+5, 15897, 571, 5821.922, 642.784, 648.11, 5.166174, 120, 0); -- 15897 (Area: 4613) (Auras: 25824 - 25824) + +DELETE FROM `game_event_creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+5 AND `eventEntry`=@Event; +INSERT INTO `game_event_creature` SELECT @Event, creature.guid FROM `creature` WHERE creature.guid BETWEEN @CGUID+0 AND @CGUID+5; diff --git a/sql/updates/world/2016_02_11_07_world.sql b/sql/updates/world/2016_02_11_07_world.sql new file mode 100644 index 00000000000..e34106cb44c --- /dev/null +++ b/sql/updates/world/2016_02_11_07_world.sql @@ -0,0 +1,145 @@ +SET @OGUID:=79767; +SET @CGUID:=97677; +SET @Event:=7; + +-- Add missing lunar objects +DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+109; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0 , 180768, 530, 1, 1, -1813.065, 5493.691, -12.42814, 4.433136, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3703) +(@OGUID+1 , 180768, 530, 1, 1, -1810.529, 5502.124, -12.42814, 3.560473, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3703) +(@OGUID+2 , 180768, 530, 1, 1, -1797.383, 5484.879, -12.42814, 0.8726639, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3703) +(@OGUID+3 , 180768, 530, 1, 1, -1802.372, 5503.944, -12.42814, 2.879789, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3703) +(@OGUID+4 , 180768, 530, 1, 1, -1804.87, 5483.975, -12.42814, 0.122173, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3703) +(@OGUID+5 , 180768, 530, 1, 1, -1796.439, 5505.653, -12.42814, 3.822273, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3703) +(@OGUID+6 , 180768, 530, 1, 1, -1791.092, 5498.224, -12.42814, 0.6283169, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3703) +(@OGUID+7 , 180768, 530, 1, 1, -1793.718, 5492.52, -12.42814, 1.274088, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3703) +(@OGUID+8 , 180768, 530, 1, 1, 9487.017, -7295.95, 14.34292, 1.274088, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3487) +(@OGUID+9 , 180768, 530, 1, 1, 9484.238, -7301.355, 14.38242, 0.8726639, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3487) +(@OGUID+10 , 180768, 530, 1, 1, 9489.608, -7291.334, 14.31547, 0.6283169, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3487) +(@OGUID+11 , 180768, 530, 1, 1, 9477.151, -7304.068, 14.36639, 0.122173, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3487) +(@OGUID+12 , 180768, 530, 1, 1, 9486.314, -7286.41, 14.28697, 3.822273, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3487) +(@OGUID+13 , 180768, 530, 1, 1, 9475.41, -7288.148, 14.25113, 3.560473, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3487) +(@OGUID+14 , 180768, 530, 1, 1, 9481.289, -7287.188, 14.267, 2.879789, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3487) +(@OGUID+15 , 180768, 530, 1, 1, 9470.736, -7293.924, 14.30253, 4.433136, 0, 0, 0, 1, 120, 255, 1), -- 180768 (Area: 3487) +(@OGUID+16 , 180766, 530, 1, 1, -1784.918, 5443.967, -12.42814, 4.084071, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 3703) +(@OGUID+17 , 180766, 530, 1, 1, -1782.34, 5432.168, -12.42814, 5.864307, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 3703) +(@OGUID+18 , 180766, 530, 1, 1, -1779.882, 5450.221, -12.42814, 3.438303, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 3703) +(@OGUID+19 , 180766, 530, 1, 1, -1771.785, 5447.635, -12.42814, 2.740162, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 3703) +(@OGUID+20 , 180766, 530, 1, 1, -1768.499, 5435.3, -12.42814, 0.7853968, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 3703) +(@OGUID+21 , 180766, 530, 1, 1, -1774.774, 5428.898, -12.42814, 0.2268925, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 3703) +(@OGUID+22 , 180766, 530, 1, 1, -1764.911, 5447.474, -12.42814, 3.42085, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 3703) +(@OGUID+23 , 180766, 530, 1, 1, -1762.984, 5438.721, -12.42814, 0.157079, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 3703) +(@OGUID+24 , 180778, 530, 1, 1, -1807.913, 5485.737, -12.42814, 0.7504908, 0, 0, 0, 1, 120, 255, 1), -- 180778 (Area: 3703) +(@OGUID+25 , 180778, 530, 1, 1, -1812.186, 5490.322, -12.42814, 3.874631, 0, 0, 0, 1, 120, 255, 1), -- 180778 (Area: 3703) +(@OGUID+26 , 180778, 530, 1, 1, 9471.936, -7298.056, 14.34922, 3.874631, 0, 0, 0, 1, 120, 255, 1), -- 180778 (Area: 3487) +(@OGUID+27 , 180778, 530, 1, 1, 9474.56, -7301.353, 14.37097, 0.7504908, 0, 0, 0, 1, 120, 255, 1), -- 180778 (Area: 3487) +(@OGUID+28 , 180878, 530, 1, 1, -1790.338, 5498.744, -12.42814, 3.857183, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+29 , 180878, 530, 1, 1, -1790.234, 5496.288, -12.42814, 4.01426, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+30 , 180878, 530, 1, 1, -1790.902, 5497.011, -12.42814, 5.777041, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+31 , 180878, 530, 1, 1, -1789.234, 5496.14, -12.42814, 6.003934, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+32 , 180878, 530, 1, 1, -1789.172, 5498.917, -12.42814, 0.1047193, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+33 , 180878, 530, 1, 1, -1788.415, 5496.598, -12.42814, 3.089183, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+34 , 180878, 530, 1, 1, -1788.392, 5498.381, -12.42814, 4.24115, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+35 , 180878, 530, 1, 1, -1788.111, 5497.561, -12.42814, 1.413715, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+36 , 180878, 530, 1, 1, -1765.722, 5449.934, -12.42814, 3.543024, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+37 , 180878, 530, 1, 1, -1764.807, 5450.181, -12.42814, 2.129301, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+38 , 180878, 530, 1, 1, -1766.226, 5448.125, -12.42814, 2.687807, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+39 , 180878, 530, 1, 1, -1766.088, 5449.026, -12.42814, 4.502952, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+40 , 180878, 530, 1, 1, -1765.541, 5447.308, -12.42814, 5.567601, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+41 , 180878, 530, 1, 1, -1763.994, 5449.78, -12.42814, 5.585054, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+42 , 180878, 530, 1, 1, -1763.402, 5449.152, -12.42814, 4.869471, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3703) +(@OGUID+43 , 180878, 530, 1, 1, 9491.685, -7292.46, 14.32974, 0.1047193, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3487) +(@OGUID+44 , 180878, 530, 1, 1, 9490.622, -7293.794, 14.33648, 1.413715, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3487) +(@OGUID+45 , 180878, 530, 1, 1, 9491.373, -7293.285, 14.3349, 4.24115, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3487) +(@OGUID+46 , 180878, 530, 1, 1, 9489.716, -7293.833, 14.33415, 3.089183, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3487) +(@OGUID+47 , 180878, 530, 1, 1, 9488.958, -7293.352, 14.32843, 6.003934, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3487) +(@OGUID+48 , 180878, 530, 1, 1, 9491.266, -7291.555, 14.32187, 3.857183, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3487) +(@OGUID+49 , 180878, 530, 1, 1, 9488.673, -7292.52, 14.32149, 4.01426, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3487) +(@OGUID+50 , 180878, 530, 1, 1, 9488.967, -7291.694, 14.31627, 5.777041, 0, 0, 0, 1, 120, 255, 1), -- 180878 (Area: 3487) +(@OGUID+51 , 180763, 530, 1, 1, -1804.848, 5484.874, -11.5462, 0.6981314, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 3703) +(@OGUID+52 , 180763, 530, 1, 1, -1795.721, 5504.963, -11.49064, 0.4537851, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 3703) +(@OGUID+53 , 180763, 530, 1, 1, -1779.698, 5450.049, -11.14342, 0.2967052, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 3703) +(@OGUID+54 , 180763, 530, 1, 1, -1784.666, 5443.933, -11.10175, 3.351047, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 3703) +(@OGUID+55 , 180763, 530, 1, 1, -1774.672, 5429.127, -11.12259, 3.281239, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 3703) +(@OGUID+56 , 180763, 530, 1, 1, -1762.88, 5438.89, -11.18509, 0.2792516, 0, 0, 0, 1, 120, 255, 1), -- 180763 (Area: 3703) +(@OGUID+57 , 180764, 530, 1, 1, 9489.186, -7290.492, 15.29506, 3.961899, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 3487) +(@OGUID+58 , 180764, 530, 1, 1, 9471.669, -7294.084, 15.2562, 0.6981314, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 3487) +(@OGUID+59 , 180879, 530, 1, 1, -1764.911, 5448.846, -12.42814, 1.204277, 0, 0, 0, 1, 120, 255, 1), -- 180879 (Area: 3703) +(@OGUID+60 , 180777, 530, 1, 1, -1784.936, 5439.937, -12.42814, 3.351047, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 3703) +(@OGUID+61 , 180777, 530, 1, 1, -1784.008, 5435.997, -12.42814, 0.2094394, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 3703) +(@OGUID+62 , 180880, 530, 1, 1, -1789.301, 5498.034, -11.72675, 2.740162, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 3703) +(@OGUID+63 , 180880, 530, 1, 1, -1789.678, 5498.17, -11.71286, 1.989672, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 3703) +(@OGUID+64 , 180880, 530, 1, 1, -1764.493, 5448.475, -10.58786, 3.42085, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 3703) +(@OGUID+65 , 180880, 530, 1, 1, 9490.517, -7292.749, 15.03819, 2.740162, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 3487) +(@OGUID+66 , 180880, 530, 1, 1, 9490.091, -7292.49, 15.04175, 1.989672, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 3487) +(@OGUID+67 , 180881, 530, 1, 1, -1789.489, 5497.099, -11.74759, 6.143561, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 3703) +(@OGUID+68 , 180881, 530, 1, 1, -1790.061, 5497.251, -11.74064, 4.572764, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 3703) +(@OGUID+69 , 180881, 530, 1, 1, -1764.79, 5449.202, -10.61564, 4.799657, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 3703) +(@OGUID+70 , 180881, 530, 1, 1, 9489.579, -7292.59, 15.02525, 4.572764, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 3487) +(@OGUID+71 , 180881, 530, 1, 1, 9489.869, -7292.061, 15.01508, 6.143561, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 3487) +(@OGUID+72 , 180882, 530, 1, 1, -1789.633, 5497.666, -11.7337, 3.647741, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 3703) +(@OGUID+73 , 180882, 530, 1, 1, -1790.078, 5497.862, -11.7337, 4.956738, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 3703) +(@OGUID+74 , 180882, 530, 1, 1, -1764.311, 5449.006, -10.6087, 3.769912, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 3703) +(@OGUID+75 , 180882, 530, 1, 1, 9490.705, -7292.344, 15.01931, 4.956738, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 3487) +(@OGUID+76 , 180882, 530, 1, 1, 9490.47, -7292.036, 15.02789, 3.647741, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 3487) +(@OGUID+77 , 180883, 530, 1, 1, -1789.06, 5497.521, -11.7337, 5.654869, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 3703) +(@OGUID+78 , 180883, 530, 1, 1, -1764.884, 5448.252, -10.58786, 5.445428, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 3703) +(@OGUID+79 , 180883, 530, 1, 1, -1765.275, 5448.697, -10.6087, 5.811947, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 3703) +(@OGUID+80 , 180883, 530, 1, 1, 9490.114, -7293.036, 15.03141, 5.654869, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 3487) +(@OGUID+81 , 180888, 530, 1, 1, -1789.768, 5497.439, -12.42814, 1.937312, 0, 0, 0, 1, 120, 255, 1), -- 180888 (Area: 3703) +(@OGUID+82 , 180888, 530, 1, 1, 9489.949, -7292.669, 14.32627, 1.937312, 0, 0, 0, 1, 120, 255, 1), -- 180888 (Area: 3487) +(@OGUID+83 , 180868, 530, 1, 1, -1809.283, 5488.518, -12.42814, 0.7330382, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+84 , 180868, 530, 1, 1, -1798.701, 5502.052, -12.42814, 0.7155849, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+85 , 180868, 530, 1, 1, -1801.822, 5499.706, -12.42814, 0.7155849, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+86 , 180868, 530, 1, 1, -1804.326, 5487.32, -12.42814, 0.7504908, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+87 , 180868, 530, 1, 1, -1796.721, 5493.617, -12.42814, 0.7504908, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+88 , 180868, 530, 1, 1, -1809.226, 5493.723, -12.42814, 0.7155849, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+89 , 180868, 530, 1, 1, -1794.08, 5495.903, -12.42814, 0.7504908, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+90 , 180868, 530, 1, 1, -1780.21, 5435.097, -12.42814, 0.2617982, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+91 , 180868, 530, 1, 1, -1781.543, 5442.225, -12.42814, 0.1919852, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+92 , 180868, 530, 1, 1, -1784.189, 5438.144, -12.42814, 0.2268925, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+93 , 180868, 530, 1, 1, -1770.829, 5437.18, -12.42814, 0.2617982, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+94 , 180868, 530, 1, 1, -1768.798, 5445.465, -12.42814, 0.1919852, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+95 , 180868, 530, 1, 1, -1772.664, 5444.496, -12.42814, 0.1919852, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+96 , 180868, 530, 1, 1, -1766.992, 5438.217, -12.42814, 0.2617982, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3703) +(@OGUID+97 , 180868, 530, 1, 1, 9487.395, -7292.862, 14.32032, 0.7504908, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3487) +(@OGUID+98 , 180868, 530, 1, 1, 9485.133, -7294.792, 14.32811, 0.7504908, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3487) +(@OGUID+99 , 180868, 530, 1, 1, 9483.845, -7288.145, 14.27744, 0.7155849, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3487) +(@OGUID+100, 180868, 530, 1, 1, 9478.389, -7299.729, 14.37478, 0.7504908, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3487) +(@OGUID+101, 180868, 530, 1, 1, 9474.005, -7299.41, 14.36638, 0.7330382, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3487) +(@OGUID+102, 180868, 530, 1, 1, 9481.45, -7289.982, 14.28201, 0.7155849, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3487) +(@OGUID+103, 180868, 530, 1, 1, 9474.831, -7294.813, 14.31686, 0.7155849, 0, 0, 0, 1, 120, 255, 1), -- 180868 (Area: 3487) +(@OGUID+104, 180869, 530, 1, 1, -1808.304, 5498.599, -12.42814, 5.148723, 0, 0, 0, 1, 120, 255, 1), -- 180869 (Area: 3703) +(@OGUID+105, 180869, 530, 1, 1, -1799.88, 5487.621, -12.42814, 2.44346, 0, 0, 0, 1, 120, 255, 1), -- 180869 (Area: 3703) +(@OGUID+106, 180869, 530, 1, 1, -1778.706, 5445.924, -12.42814, 4.677484, 0, 0, 0, 1, 120, 255, 1), -- 180869 (Area: 3703) +(@OGUID+107, 180869, 530, 1, 1, -1775.92, 5433.098, -12.42814, 0.2792516, 0, 0, 0, 1, 120, 255, 1), -- 180869 (Area: 3703) +(@OGUID+108, 180869, 530, 1, 1, 9482.434, -7299.702, 14.37898, 2.44346, 0, 0, 0, 1, 120, 255, 1), -- 180869 (Area: 3487) +(@OGUID+109, 180869, 530, 1, 1, 9476.028, -7289.976, 14.26634, 5.148723, 0, 0, 0, 1, 120, 255, 1); -- 180869 (Area: 3487) + +DELETE FROM `game_event_gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+109 AND `eventEntry`=@Event; +INSERT INTO `game_event_gameobject` SELECT @Event, gameobject.guid FROM `gameobject` WHERE gameobject.guid BETWEEN @OGUID+0 AND @OGUID+109; + +-- Add missing lunar spawns +DELETE FROM `creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+17; +INSERT INTO `creature` (`guid`, `id`, `map`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `curhealth`) VALUES +(@CGUID+0 , 15892, 530, -1781.75, 5438.715, -12.34481, 0.2617994, 120, 0), -- 15892 (Area: 3703) +(@CGUID+1 , 15892, 530, -1775.563, 5444.455, -12.34481, 4.223697, 120, 0), -- 15892 (Area: 3703) +(@CGUID+2 , 15892, 530, -1773.548, 5436.28, -12.3448, 2.495821, 120, 0), -- 15892 (Area: 3703) +(@CGUID+3 , 15898, 530, -1790.075, 5499.826, -12.34481, 0.6981317, 120, 0), -- 15898 (Area: 3703) +(@CGUID+4 , 15898, 530, -1763.572, 5447.717, -12.34481, 0.2268928, 120, 0), -- 15898 (Area: 3703) (Auras: ) +(@CGUID+5 , 15898, 530, 9490.617, -7290.235, 14.39641, 0.6981317, 120, 0), -- 15898 (Area: 3487) +(@CGUID+6 , 15895, 530, -1794.924, 5506.388, -12.34481, 0.6806784, 120, 0), -- 15895 (Area: 3703) +(@CGUID+7 , 15895, 530, -1762.115, 5439.025, -12.34481, 0.3316126, 120, 0), -- 15895 (Area: 3703) (Auras: ) +(@CGUID+8 , 15895, 530, 9487.328, -7285.737, 14.37371, 0.6806784, 120, 0), -- 15895 (Area: 3487) +(@CGUID+9 , 15891, 530, -1799.079, 5491.603, -12.34481, 2.879793, 120, 0), -- 15891 (Area: 3703) +(@CGUID+10, 15891, 530, -1804.241, 5498.248, -12.34481, 4.694936, 120, 0), -- 15891 (Area: 3703) +(@CGUID+11, 15891, 530, -1807.636, 5489.974, -12.34481, 0.7504916, 120, 0), -- 15891 (Area: 3703) +(@CGUID+12, 15891, 530, 9483.579, -7296.714, 14.43082, 2.879793, 120, 0), -- 15891 (Area: 3487) +(@CGUID+13, 15891, 530, 9479.115, -7290.209, 14.36029, 4.694936, 120, 0), -- 15891 (Area: 3487) +(@CGUID+14, 15891, 530, 9475.681, -7297.988, 14.43598, 0.7504916, 120, 0), -- 15891 (Area: 3487) +(@CGUID+15, 15897, 530, -1804.344, 5492.794, -12.34481, 5.375614, 120, 0), -- 15897 (Area: 3703) (Auras: 25824 - 25824) +(@CGUID+16, 15897, 530, -1778.063, 5439.687, -12.34481, 4.415683, 120, 0), -- 15897 (Area: 3703) (Auras: 25824 - 25824) +(@CGUID+17, 15897, 530, 9479.258, -7295.212, 14.4095, 4.39823, 120, 0); -- 15897 (Area: 3487) (Auras: 25824 - 25824) + +DELETE FROM `game_event_creature` WHERE `guid` BETWEEN @CGUID+0 AND @CGUID+17 AND `eventEntry`=@Event; +INSERT INTO `game_event_creature` SELECT @Event, creature.guid FROM `creature` WHERE creature.guid BETWEEN @CGUID+0 AND @CGUID+17; diff --git a/sql/updates/world/2016_02_12_00_world.sql b/sql/updates/world/2016_02_12_00_world.sql new file mode 100644 index 00000000000..af599148e04 --- /dev/null +++ b/sql/updates/world/2016_02_12_00_world.sql @@ -0,0 +1,7 @@ +-- +-- Spawn creature ID 16399 Bloodsail Traitor: +SET @CGUID := 1528; -- selected by TC team + +DELETE FROM `creature` WHERE `id` = 16399; +INSERT INTO `creature` (`guid`,`id`,`map`,`zoneId`,`areaId`,`spawnMask`,`phaseMask`,`modelid`,`equipment_id`,`position_x`,`position_y`,`position_z`,`orientation`,`spawntimesecs`,`spawndist`,`currentwaypoint`,`curhealth`,`curmana`,`MovementType`,`npcflag`,`unit_flags`,`dynamicflags`,`VerifiedBuild`) VALUES +(@CGUID, 16399, 0, 0, 0, 1, 1, 2557, 1, -14184.4, 192.764, 20.6905, 3.735, 300, 0, 0, 2059, 0, 0, 0, 0, 0, 0); diff --git a/sql/updates/world/2016_02_13_00_world.sql b/sql/updates/world/2016_02_13_00_world.sql new file mode 100644 index 00000000000..2341e33a8b5 --- /dev/null +++ b/sql/updates/world/2016_02_13_00_world.sql @@ -0,0 +1,4 @@ +SET @ENTRY:=23258; +SET @AURA:=40670; +DELETE FROM `creature_template_addon` WHERE `entry` = @ENTRY; +INSERT INTO `creature_template_addon` (`entry`, `auras`) VALUES (@ENTRY, @AURA); diff --git a/sql/updates/world/2016_02_13_01_world.sql b/sql/updates/world/2016_02_13_01_world.sql new file mode 100644 index 00000000000..29f94a9f41d --- /dev/null +++ b/sql/updates/world/2016_02_13_01_world.sql @@ -0,0 +1,206 @@ +SET @OGUID:=79877; +SET @Event:=7; + +-- Add missing lunar objects +DELETE FROM `gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+152; +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0 , 180879, 1, 1, 1, 7593.807, -2222.592, 469.1576, 3.804818, 0, 0, 0, 1, 120, 255, 1), -- 180879 (Area: 493) +(@OGUID+1 , 180879, 1, 1, 1, 7595.46, -2226.798, 468.3849, 4.76475, 0, 0, 0, 1, 120, 255, 1), -- 180879 (Area: 493) +(@OGUID+2 , 180879, 1, 1, 1, 7592.46, -2218.003, 469.6433, 2.199115, 0, 0, 0, 1, 120, 255, 1), -- 180879 (Area: 493) +(@OGUID+3 , 180880, 1, 1, 1, 7593.197, -2221.986, 470.9921, 2.321287, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 493) +(@OGUID+4 , 180880, 1, 1, 1, 7596.01, -2226.955, 470.215, 4.782203, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 493) +(@OGUID+5 , 180880, 1, 1, 1, 7591.976, -2217.98, 471.4845, 1.466076, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 493) +(@OGUID+6 , 180880, 1, 1, 1, 7593.209, -2218.238, 471.4679, 4.450591, 0, 0, 0, 1, 120, 255, 1), -- 180880 (Area: 493) +(@OGUID+7 , 180881, 1, 1, 1, 7595.163, -2227.192, 470.1959, 4.136433, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 493) +(@OGUID+8 , 180881, 1, 1, 1, 7594.063, -2222.041, 470.9863, 3.595379, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 493) +(@OGUID+9 , 180881, 1, 1, 1, 7595.476, -2226.666, 470.2082, 2.024579, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 493) +(@OGUID+10 , 180881, 1, 1, 1, 7592.764, -2218.324, 471.472, 5.393069, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 493) +(@OGUID+11 , 180881, 1, 1, 1, 7592.445, -2217.559, 471.4581, 0.7330382, 0, 0, 0, 1, 120, 255, 1), -- 180881 (Area: 493) +(@OGUID+12 , 180882, 1, 1, 1, 7593.618, -2221.826, 470.969, 6.108654, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 493) +(@OGUID+13 , 180882, 1, 1, 1, 7595.62, -2227.267, 470.2169, 3.961899, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 493) +(@OGUID+14 , 180882, 1, 1, 1, 7595.934, -2226.421, 470.1891, 1.710422, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 493) +(@OGUID+15 , 180882, 1, 1, 1, 7592.151, -2218.304, 471.4556, 2.18166, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 493) +(@OGUID+16 , 180882, 1, 1, 1, 7592.401, -2218.573, 471.4416, 2.91469, 0, 0, 0, 1, 120, 255, 1), -- 180882 (Area: 493) +(@OGUID+17 , 180883, 1, 1, 1, 7595.268, -2226.156, 470.2048, 3.246347, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 493) +(@OGUID+18 , 180883, 1, 1, 1, 7594.821, -2226.714, 470.1994, 0.2792516, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 493) +(@OGUID+19 , 180883, 1, 1, 1, 7593.012, -2217.75, 471.4669, 3.124123, 0, 0, 0, 1, 120, 255, 1), -- 180883 (Area: 493) +(@OGUID+20 , 180851, 1, 1, 1, 7564.366, -2224.284, 475.4654, 5.148725, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+21 , 180851, 1, 1, 1, 7600.833, -2219.168, 473.4156, 1.274088, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+22 , 180851, 1, 1, 1, 7588.353, -2200.221, 479.1006, 4.20625, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+23 , 180851, 1, 1, 1, 7592.721, -2256.181, 467.8657, 1.326448, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+24 , 180851, 1, 1, 1, 7600.807, -2205.065, 476.8404, 5.061459, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+25 , 180851, 1, 1, 1, 7588.353, -2200.221, 479.1006, 4.20625, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+26 , 180851, 1, 1, 1, 7612.306, -2222.548, 473.3903, 4.468043, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+27 , 180851, 1, 1, 1, 7577.153, -2226.377, 475.8007, 1.937312, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+28 , 180851, 1, 1, 1, 7573.452, -2244.367, 470.6506, 1.291542, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+29 , 180851, 1, 1, 1, 7588.164, -2211.207, 476.1555, 2.024579, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+30 , 180851, 1, 1, 1, 7581.566, -2236.441, 474.0557, 3.455756, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+31 , 180851, 1, 1, 1, 7607.799, -2215.778, 473.6258, 2.373644, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+32 , 180851, 1, 1, 1, 7592.721, -2256.181, 467.8657, 1.326448, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+33 , 180851, 1, 1, 1, 7579.257, -2243.993, 471.6541, 2.18166, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+34 , 180851, 1, 1, 1, 7612.306, -2222.548, 473.3903, 4.468043, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+35 , 180851, 1, 1, 1, 7600.601, -2238.859, 470.7188, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+36 , 180851, 1, 1, 1, 7588.164, -2211.207, 476.1555, 2.024579, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+37 , 180851, 1, 1, 1, 7617.579, -2233.563, 470.0322, 2.548179, 0, 0, 0, 1, 120, 255, 1), -- 180851 (Area: 493) +(@OGUID+38 , 180861, 1, 1, 1, 7575.579, -2210.406, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+39 , 180861, 1, 1, 1, 7575.579, -2213.406, 486.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+40 , 180861, 1, 1, 1, 7575.579, -2213.406, 477.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+41 , 180861, 1, 1, 1, 7575.579, -2210.406, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+42 , 180861, 1, 1, 1, 7575.579, -2213.406, 486.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+43 , 180861, 1, 1, 1, 7575.579, -2213.406, 477.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+44 , 180861, 1, 1, 1, 7575.579, -2213.406, 477.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+45 , 180861, 1, 1, 1, 7575.579, -2213.406, 486.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+46 , 180861, 1, 1, 1, 7575.579, -2210.406, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+47 , 180861, 1, 1, 1, 7575.579, -2210.406, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+48 , 180861, 1, 1, 1, 7575.579, -2213.406, 486.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+49 , 180861, 1, 1, 1, 7575.579, -2213.406, 477.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+50 , 180861, 1, 1, 1, 7575.579, -2213.406, 486.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+51 , 180861, 1, 1, 1, 7575.579, -2213.406, 477.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+52 , 180861, 1, 1, 1, 7575.579, -2210.406, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+53 , 180861, 1, 1, 1, 7575.579, -2213.406, 477.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+54 , 180861, 1, 1, 1, 7575.579, -2213.406, 486.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+55 , 180861, 1, 1, 1, 7575.579, -2210.406, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+56 , 180861, 1, 1, 1, 7575.579, -2210.406, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+57 , 180861, 1, 1, 1, 7575.579, -2213.406, 486.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+58 , 180861, 1, 1, 1, 7575.579, -2213.406, 477.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+59 , 180861, 1, 1, 1, 7575.579, -2210.406, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+60 , 180861, 1, 1, 1, 7575.579, -2213.406, 486.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+61 , 180861, 1, 1, 1, 7575.579, -2213.406, 477.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+62 , 180861, 1, 1, 1, 7575.579, -2213.406, 477.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+63 , 180861, 1, 1, 1, 7575.579, -2213.406, 486.1616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+64 , 180861, 1, 1, 1, 7575.579, -2210.406, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180861 (Area: 493) +(@OGUID+65 , 180864, 1, 1, 1, 7580.829, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+66 , 180864, 1, 1, 1, 7570.329, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+67 , 180864, 1, 1, 1, 7580.829, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+68 , 180864, 1, 1, 1, 7570.329, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+69 , 180864, 1, 1, 1, 7570.329, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+70 , 180864, 1, 1, 1, 7580.829, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+71 , 180864, 1, 1, 1, 7570.329, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+72 , 180864, 1, 1, 1, 7580.829, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+73 , 180864, 1, 1, 1, 7580.829, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+74 , 180864, 1, 1, 1, 7570.329, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+75 , 180864, 1, 1, 1, 7570.329, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+76 , 180864, 1, 1, 1, 7580.829, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+77 , 180864, 1, 1, 1, 7580.829, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+78 , 180864, 1, 1, 1, 7570.329, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+79 , 180864, 1, 1, 1, 7580.829, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+80 , 180864, 1, 1, 1, 7570.329, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+81 , 180864, 1, 1, 1, 7580.829, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+82 , 180864, 1, 1, 1, 7570.329, -2214.906, 481.6616, 4.084075, 0, 0, 0, 1, 120, 255, 1), -- 180864 (Area: 493) +(@OGUID+83 , 180769, 1, 1, 1, 7879.087, -2219.161, 479.2853, 5.689774, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 2362) +(@OGUID+84 , 180769, 1, 1, 1, 7837.341, -2197, 478.0439, 2.548179, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 2362) +(@OGUID+85 , 180769, 1, 1, 1, 7868.952, -2191.253, 486.3665, 0.9075702, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 2362) +(@OGUID+86 , 180879, 1, 1, 1, 7946.622, -2621.156, 492.3542, 1.850049, 0, 0, 0, 1, 120, 255, 1), -- 180879 (Area: 2361) +(@OGUID+87 , 180909, 1, 1, 1, 7946.665, -2621.123, 494.2065, 2.775069, 0, 0, 0, 1, 120, 255, 1), -- 180909 (Area: 2361) +(@OGUID+88 , 180909, 1, 1, 1, 7946.252, -2621.753, 494.1519, 6.161013, 0, 0, 0, 1, 120, 255, 1), -- 180909 (Area: 2361) +(@OGUID+89 , 180909, 1, 1, 1, 7946.777, -2621.559, 494.1994, 3.263772, 0, 0, 0, 1, 120, 255, 1), -- 180909 (Area: 2361) +(@OGUID+90 , 180909, 1, 1, 1, 7947.238, -2621.351, 494.1782, 3.822273, 0, 0, 0, 1, 120, 255, 1), -- 180909 (Area: 2361) +(@OGUID+91 , 180777, 1, 1, 1, 7951.528, -2615.867, 492.9226, 1.710422, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 2361) +(@OGUID+92 , 180777, 1, 1, 1, 7948.855, -2629.297, 493.1261, 1.361356, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 2361) +(@OGUID+93 , 180910, 1, 1, 1, 7946.681, -2621.326, 494.1927, 5.131269, 0, 0, 0, 1, 120, 255, 1), -- 180910 (Area: 2361) +(@OGUID+94 , 188215, 1, 1, 1, 7947.822, -2622.942, 492.8509, 2.809975, 0, 0, 0, 1, 120, 255, 1), -- 188215 (Area: 2361) - !!! might be temporary spawn !!! +(@OGUID+95 , 188215, 1, 1, 1, 7948.878, -2619.704, 492.7197, 2.303831, 0, 0, 0, 1, 120, 255, 1), -- 188215 (Area: 2361) - !!! might be temporary spawn !!! +(@OGUID+96 , 180764, 1, 1, 1, 7781.23, -2437.568, 494.049, 6.003934, 0, 0, 0, 1, 120, 255, 1), -- 180764 (Area: 2361) +(@OGUID+97 , 180769, 1, 1, 1, 7797.483, -2417.394, 497.058, 1.937312, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 2361) +(@OGUID+98 , 180769, 1, 1, 1, 7439.099, -2809.767, 473.9281, 3.508117, 0, 0, 0, 1, 120, 255, 1), -- 180769 (Area: 656) +(@OGUID+99 , 180777, 1, 1, 1, 7619.005, -2221.212, 469.807, 0.8377575, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0) +(@OGUID+100, 180777, 1, 1, 1, 7586.018, -2220.791, 471.5764, 2.408554, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0) +(@OGUID+101, 180777, 1, 1, 1, 7591.077, -2214.273, 471.4059, 5.689774, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0) +(@OGUID+102, 180777, 1, 1, 1, 7585.201, -2209.946, 473.8624, 5.532695, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0) +(@OGUID+103, 180777, 1, 1, 1, 7580.083, -2215.166, 473.3982, 2.391098, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0) +(@OGUID+104, 180777, 1, 1, 1, 7587.347, -2196.992, 476.204, 1.343901, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0) +(@OGUID+105, 180777, 1, 1, 1, 7562.486, -2227.179, 471.6295, 3.595379, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0) +(@OGUID+106, 180777, 1, 1, 1, 7571.573, -2207.698, 474.8347, 2.321287, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0) +(@OGUID+107, 180777, 1, 1, 1, 7577.507, -2201.813, 475.4521, 5.532695, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0) +(@OGUID+108, 180777, 1, 1, 1, 7497.841, -2203.225, 480.2202, 6.248279, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0) +(@OGUID+109, 180777, 1, 1, 1, 7499.098, -2191.63, 480.452, 3.054327, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 0) +(@OGUID+110, 180777, 1, 1, 1, 7937.66, -2362.064, 488.5504, 4.642576, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 2362) +(@OGUID+111, 180777, 1, 1, 1, 7971.51, -2352.85, 488.2709, 1.727875, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 2362) +(@OGUID+112, 180777, 1, 1, 1, 7993.134, -2468.059, 489.5084, 3.124123, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 2361) +(@OGUID+113, 180777, 1, 1, 1, 7960.454, -2515.816, 485.9554, 5.340709, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 2361) +(@OGUID+114, 180777, 1, 1, 1, 7925.333, -2550.147, 486.0686, 4.101525, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 2361) +(@OGUID+115, 180777, 1, 1, 1, 7951.528, -2615.867, 492.9226, 1.710422, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 2361) +(@OGUID+116, 180777, 1, 1, 1, 7948.855, -2629.297, 493.1261, 1.361356, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 2361) +(@OGUID+117, 180777, 1, 1, 1, 7530.31, -2850.198, 458.604, 2.513274, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 656) +(@OGUID+118, 180777, 1, 1, 1, 7532.818, -2852.513, 458.175, 2.321287, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 656) +(@OGUID+119, 180777, 1, 1, 1, 7562.452, -2873.018, 460.911, 2.530723, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 656) +(@OGUID+120, 180777, 1, 1, 1, 7559.907, -2871.458, 460.6194, 2.583081, 0, 0, 0, 1, 120, 255, 1), -- 180777 (Area: 656) +(@OGUID+121, 180875, 1, 1, 1, 7531.745, -2851.107, 457.8172, 2.408554, 0, 0, 0, 1, 120, 255, 1), -- 180875 (Area: 656) +(@OGUID+122, 180875, 1, 1, 1, 7561.202, -2872.201, 459.9906, 2.583081, 0, 0, 0, 1, 120, 255, 1), -- 180875 (Area: 656) +(@OGUID+123, 180773, 1, 1, 1, 7562.604, -2903.484, 462.9012, 1.413715, 0, 0, 0, 1, 120, 255, 1), -- 180773 (Area: 656) +(@OGUID+124, 180773, 1, 1, 1, 7570.199, -2903.755, 462.812, 1.640607, 0, 0, 0, 1, 120, 255, 1), -- 180773 (Area: 656) +(@OGUID+125, 180765, 1, 1, 1, 7478.559, -2652.309, 455.1449, 3.822273, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 656) +(@OGUID+126, 180765, 1, 1, 1, 7532.16, -2467.022, 455.5912, 0.8552105, 0, 0, 0, 1, 120, 255, 1), -- 180765 (Area: 0) +(@OGUID+127, 180766, 1, 1, 1, 7572.346, -2366.04, 454.7335, 4.01426, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0) +(@OGUID+128, 180766, 1, 1, 1, 7535.119, -2436.779, 453.7722, 1.291542, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0) +(@OGUID+129, 180766, 1, 1, 1, 7528.662, -2481.222, 454.3387, 4.32842, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0) +(@OGUID+130, 180766, 1, 1, 1, 7499.897, -2487.684, 457.2921, 3.106652, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0) +(@OGUID+131, 180766, 1, 1, 1, 7520.417, -2504.377, 454.1295, 4.276057, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0) +(@OGUID+132, 180766, 1, 1, 1, 7479.219, -2479.521, 461.8409, 0.1745321, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 0) +(@OGUID+133, 180766, 1, 1, 1, 7497.929, -2564.247, 454.2826, 4.258607, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+134, 180766, 1, 1, 1, 7496.524, -2532.186, 452.8313, 0.9424766, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+135, 180766, 1, 1, 1, 7464.938, -2691.611, 454.3436, 1.396262, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+136, 180766, 1, 1, 1, 7475.028, -2597.744, 452.8322, 1.239183, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+137, 180766, 1, 1, 1, 7483.91, -2632.364, 453.8647, 4.415683, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+138, 180766, 1, 1, 1, 7463.901, -2741.921, 459.2945, 1.396262, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+139, 180766, 1, 1, 1, 7494.413, -2822.02, 461.3461, 4.991644, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+140, 180766, 1, 1, 1, 7481.923, -2829.692, 461.2198, 1.745327, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+141, 180766, 1, 1, 1, 7461.356, -2813.827, 462.3748, 1.797689, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+142, 180766, 1, 1, 1, 7474.328, -2795.222, 462.4803, 4.625124, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+143, 180766, 1, 1, 1, 7461.583, -2802.854, 462.1353, 1.396262, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+144, 180766, 1, 1, 1, 7475.494, -2750.214, 460.2916, 4.625124, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+145, 180766, 1, 1, 1, 7533.194, -2849.556, 456.259, 5.585054, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+146, 180766, 1, 1, 1, 7560.079, -2900.277, 460.4167, 2.949595, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+147, 180766, 1, 1, 1, 7562.421, -2870.49, 458.3398, 5.742135, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+148, 180766, 1, 1, 1, 7572.878, -2900.665, 460.2018, 3.159062, 0, 0, 0, 1, 120, 255, 1), -- 180766 (Area: 656) +(@OGUID+149, 180767, 1, 1, 1, 7472.893, -2651.321, 455.1381, 5.480334, 0, 0, 0, 1, 120, 255, 1), -- 180767 (Area: 656) +(@OGUID+150, 180767, 1, 1, 1, 7526.87, -2464.803, 455.183, 0.087266, 0, 0, 0, 1, 120, 255, 1), -- 180767 (Area: 0) +(@OGUID+151, 180767, 1, 1, 1, 7553.503, -2401.662, 456.9937, 1.483528, 0, 0, 0, 1, 120, 255, 1), -- 180767 (Area: 0) +(@OGUID+152, 180767, 1, 1, 1, 7547.994, -2399.728, 456.7213, 0.8203033, 0, 0, 0, 1, 120, 255, 1); -- 180767 (Area: 0) + +DELETE FROM `game_event_gameobject` WHERE `guid` BETWEEN @OGUID+0 AND @OGUID+152 AND `eventEntry`=@Event; +INSERT INTO `game_event_gameobject` SELECT @Event, gameobject.guid FROM `gameobject` WHERE gameobject.guid BETWEEN @OGUID+0 AND @OGUID+152; + +UPDATE `creature_addon` SET `emote`=0 WHERE `guid` IN (91639, 91644, 91657, 91658, 91663, 91669, 91671, 91676); + +-- Darnassus Reveler SAI +SET @ENTRY := 15905; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,1,0,100,0,5000,5000,5000,10000,10,11,94,0,0,0,0,1,0,0,0,0,0,0,0,"Darnassus Reveler - Out of Combat - Play Random Emote (11, 94)"); + +-- Ironforge Reveler SAI +SET @ENTRY := 15906; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,1,0,100,0,5000,5000,5000,10000,10,11,94,0,0,0,0,1,0,0,0,0,0,0,0,"Ironforge Reveler - Out of Combat - Play Random Emote (11, 94)"); + +-- Stormwind Reveler SAI +SET @ENTRY := 15694; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,1,0,100,0,5000,5000,5000,10000,10,11,94,0,0,0,0,1,0,0,0,0,0,0,0,"Stormwind Reveler - Out of Combat - Play Random Emote (11, 94)"); + +-- Orgrimmar Reveler SAI +SET @ENTRY := 15908; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,1,0,100,0,5000,5000,5000,10000,10,11,94,0,0,0,0,1,0,0,0,0,0,0,0,"Orgrimmar Reveler - Out of Combat - Play Random Emote (11, 94)"); + +-- Thunder Bluff Reveler SAI +SET @ENTRY := 15719; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,1,0,100,0,5000,5000,5000,10000,10,11,94,0,0,0,0,1,0,0,0,0,0,0,0,"Thunder Bluff Reveler - Out of Combat - Play Random Emote (11, 94)"); + +-- Undercity Reveler SAI +SET @ENTRY := 15907; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,1,0,100,0,5000,5000,5000,10000,10,11,94,0,0,0,0,1,0,0,0,0,0,0,0,"Undercity Reveler - Out of Combat - Play Random Emote (11, 94)"); diff --git a/sql/updates/world/2016_02_13_02_world.sql b/sql/updates/world/2016_02_13_02_world.sql new file mode 100644 index 00000000000..5a4633fee41 --- /dev/null +++ b/sql/updates/world/2016_02_13_02_world.sql @@ -0,0 +1,74 @@ +-- Update aura for Manifest Nightmare +UPDATE `creature_template_addon` SET `auras`='39579 37509' WHERE `entry`=22889; +-- Update aura for Phantasmal Lash +UPDATE `creature_template_addon` SET `auras`='34427' WHERE `entry`=22902; + +-- Pathing for Moonglade Warden Entry: 11822 'TDB FORMAT' +SET @NPC := 42393; +SET @PATH := @NPC * 10; +UPDATE `creature` SET `spawndist`=0,`MovementType`=2,`position_x`=7546.649,`position_y`=-2901.733,`position_z`=462.5362 WHERE `guid`=@NPC; +DELETE FROM `creature_addon` WHERE `guid`=@NPC; +INSERT INTO `creature_addon` (`guid`,`path_id`,`mount`,`bytes1`,`bytes2`,`emote`,`auras`) VALUES (@NPC,@PATH,0,0,1,0, ''); +DELETE FROM `waypoint_data` WHERE `id`=@PATH; +INSERT INTO `waypoint_data` (`id`,`point`,`position_x`,`position_y`,`position_z`,`orientation`,`delay`,`move_type`,`action`,`action_chance`,`wpguid`) VALUES +(@PATH,1,7546.649,-2901.733,462.5362,0,0,0,0,100,0), -- 13:28:53 +(@PATH,2,7528.728,-2908.457,461.338,0,0,0,0,100,0), -- 13:28:57 +(@PATH,3,7517.918,-2920.282,461.923,0,0,0,0,100,0), -- 13:29:03 +(@PATH,4,7512.568,-2933.285,464.4847,0,0,0,0,100,0), -- 13:29:09 +(@PATH,5,7509.731,-2947.129,463.4818,0,0,0,0,100,0), -- 13:29:15 +(@PATH,6,7510.136,-2952.441,461.5912,0,0,0,0,100,0), -- 13:29:20 +(@PATH,7,7511.554,-2961.568,462.0287,0,0,0,0,100,0), -- 13:29:26 +(@PATH,8,7529.275,-2970.313,461.0047,0,0,0,0,100,0), -- 13:29:30 +(@PATH,9,7534.475,-2972.501,460.6516,0,0,0,0,100,0), -- 13:29:36 +(@PATH,10,7542.61,-2984.713,461.6914,0,0,0,0,100,0), -- 13:29:41 +(@PATH,11,7541.939,-2996.007,464.5852,0,0,0,0,100,0), -- 13:29:44 +(@PATH,12,7537.476,-3005.4,466.0187,0,0,0,0,100,0), -- 13:29:47 +(@PATH,13,7535.565,-3017.812,466.2273,0,0,0,0,100,0), -- 13:29:52 +(@PATH,14,7550.125,-3028.802,462.2839,0,0,0,0,100,0), -- 13:29:57 +(@PATH,15,7566.678,-3023.841,461.0449,0,0,0,0,100,0), -- 13:30:05 +(@PATH,16,7574.592,-3019.921,460.4108,0,0,0,0,100,0), -- 13:30:16 +(@PATH,17,7580.481,-3005.122,461.308,0,0,0,0,100,0), -- 13:30:19 +(@PATH,18,7581.311,-2996.924,462.5332,0,0,0,0,100,0), -- 13:30:23 +(@PATH,19,7589.289,-2980.43,460.9365,0,0,0,0,100,0), -- 13:30:28 +(@PATH,20,7589.837,-2979.668,460.4661,0,0,0,0,100,0), -- 13:30:33 +(@PATH,21,7606.989,-2972.392,461.5837,0,0,0,0,100,0), -- 13:30:37 +(@PATH,22,7617.824,-2965.905,461.3898,0,0,0,0,100,0), -- 13:30:43 +(@PATH,23,7620.032,-2963.793,461.5444,0,0,0,0,100,0), -- 13:30:47 +(@PATH,24,7653.39,-2955.129,463.8018,0,0,0,0,100,0), -- 13:30:51 +(@PATH,25,7668.529,-2958.117,464.894,0,0,0,0,100,0), -- 13:31:05 +(@PATH,26,7652.024,-2942.818,463.3503,0,0,0,0,100,0), -- 13:31:13 +(@PATH,27,7648.988,-2940.365,462.6953,0,0,0,0,100,0), -- 13:31:24 +(@PATH,28,7623.73,-2923.926,462.5015,0,0,0,0,100,0), -- 13:31:36 +(@PATH,29,7596.945,-2907.005,462.287,0,0,0,0,100,0), -- 13:31:43 +(@PATH,30,7589.421,-2904.872,461.6304,0,0,0,0,100,0), -- 13:31:51 +(@PATH,31,7591.465,-2904.978,461.9995,0,0,0,0,100,0), -- 13:31:58 +(@PATH,32,7600.53,-2909.323,462.908,0,0,0,0,100,0), -- 13:32:02 +(@PATH,33,7610.539,-2915.46,462.7303,0,0,0,0,100,0), -- 13:32:10 +(@PATH,34,7623.934,-2924.251,462.4937,0,0,0,0,100,0), -- 13:32:16 +(@PATH,35,7670.327,-2956.833,465.3539,0,0,0,0,100,0), -- 13:32:28 +(@PATH,36,7656.929,-2955.638,464.1862,0,0,0,0,100,0), -- 13:32:40 +(@PATH,37,7622.145,-2953.092,462.1255,0,0,0,0,100,0), -- 13:32:49 +(@PATH,38,7621.655,-2953.013,461.7986,0,0,0,0,100,0), -- 13:33:01 +(@PATH,39,7615.943,-2966.924,461.1361,0,0,0,0,100,0), -- 13:33:06 +(@PATH,40,7603.335,-2972.608,460.9927,0,0,0,0,100,0), -- 13:33:12 +(@PATH,41,7598.073,-2973.764,460.5677,0,0,0,0,100,0), -- 13:33:16 +(@PATH,42,7584.056,-2987.697,461.8174,0,0,0,0,100,0), -- 13:33:20 +(@PATH,43,7581.24,-2999.696,462.0973,0,0,0,0,100,0), -- 13:33:25 +(@PATH,44,7580.043,-3009.624,460.9475,0,0,0,0,100,0), -- 13:33:29 +(@PATH,45,7579.715,-3010.909,460.7065,0,0,0,0,100,0), -- 13:33:34 +(@PATH,46,7556.479,-3028.306,461.8019,0,0,0,0,100,0), -- 13:33:38 +(@PATH,47,7535.963,-3018.814,465.7519,0,0,0,0,100,0), -- 13:33:48 +(@PATH,48,7541.39,-2997.226,464.9632,0,0,0,0,100,0), -- 13:34:01 +(@PATH,49,7544.303,-2989.159,462.7299,0,0,0,0,100,0), -- 13:34:06 +(@PATH,50,7542.205,-2983.293,461.2471,0,0,0,0,100,0), -- 13:34:09 +(@PATH,51,7540.801,-2981.162,461.0032,0,0,0,0,100,0), -- 13:34:13 +(@PATH,52,7521.677,-2967.251,461.8644,0,0,0,0,100,0), -- 13:34:17 +(@PATH,53,7519.106,-2965.93,461.9445,0,0,0,0,100,0), -- 13:34:24 +(@PATH,54,7509.905,-2950.868,462.2672,0,0,0,0,100,0), -- 13:34:28 +(@PATH,55,7510.615,-2942.81,464.3668,0,0,0,0,100,0), -- 13:34:33 +(@PATH,56,7515.797,-2924.253,463.1058,0,0,0,0,100,0), -- 13:34:37 +(@PATH,57,7521.769,-2915.139,460.8744,0,0,0,0,100,0), -- 13:34:45 +(@PATH,58,7537.507,-2902.868,462.3076,0,0,0,0,100,0), -- 13:34:50 +(@PATH,59,7538.777,-2902.161,462.3616,0,0,0,0,100,0), -- 13:34:56 +(@PATH,60,7546.649,-2901.733,462.5362,0,0,0,0,100,0); -- 13:35:03 +-- 0x1C392000200B8B8000003800003F2E06 .go 7546.649 -2901.733 462.5362 diff --git a/sql/updates/world/2016_02_13_03_world.sql b/sql/updates/world/2016_02_13_03_world.sql new file mode 100644 index 00000000000..136a068bd9e --- /dev/null +++ b/sql/updates/world/2016_02_13_03_world.sql @@ -0,0 +1,166 @@ + +SET @CGUID := 145042; +SET @OGUID := 82917; + + +DELETE FROM `spell_area` WHERE `spell`=58139 AND `area`IN(4530,4531); +INSERT INTO `spell_area` (`spell`, `area`, `quest_start`, `quest_end`, `aura_spell`, `racemask`, `gender`, `autocast`, `quest_start_status`, `quest_end_status`) VALUES +(58139, 4531, 13144, 0, 0, 0, 2, 1, 64, 11), -- The Fleshweks after Killing two scourge with one skeleton +(58139, 4530, 13144, 0, 0, 0, 2, 1, 64, 11); -- Sanctumn on renaimation after Killing two scourge with one skeleton + +DELETE FROM `creature` WHERE `id` IN(30703,30704,31015,30697,30696,31432); +INSERT INTO `creature` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `spawntimesecs`, `spawndist`, `MovementType`) VALUES +(@CGUID+0, 31015, 571, 1, 64, 6661.146, 3261.688, 668.9714, 4.115243, 120, 5, 1), -- 31015 (Area: 4588) (possible waypoints or random movement) +(@CGUID+1, 31015, 571, 1, 64, 6627.71, 3189.896, 647.9885, 2.84596, 120, 5, 1), -- 31015 (Area: 4588) (possible waypoints or random movement) +(@CGUID+2, 31015, 571, 1, 64, 6659.174, 3212.105, 667.0215, 0.1042775, 120, 5, 1), -- 31015 (Area: 4588) (possible waypoints or random movement) +(@CGUID+3, 31015, 571, 1, 64, 6654.514, 3239.867, 670.2061, 5.907172, 120, 5, 1), -- 31015 (Area: 4588) (possible waypoints or random movement) +(@CGUID+4, 31015, 571, 1, 64, 6610.869, 3232.499, 668.5587, 2.604744, 120, 5, 1), -- 31015 (Area: 4588) (possible waypoints or random movement) +(@CGUID+5, 31015, 571, 1, 64, 6605.338, 3153.076, 665.3033, 5.409661, 120, 5, 1), -- 31015 (Area: 4588) (possible waypoints or random movement) +(@CGUID+6, 31015, 571, 1, 64, 6702.106, 3154.25, 654.8233, 5.986479, 120, 5, 1), -- 31015 (Area: 4588) (possible waypoints or random movement) +(@CGUID+7, 31015, 571, 1, 64, 6583.975, 3157.158, 665.6695, 2.269745, 120, 5, 1), -- 31015 (Area: 4588) (possible waypoints or random movement) +(@CGUID+8, 31015, 571, 1, 64, 6565.48, 3315.214, 667.1922, 3.576956, 120, 0, 0), -- 31015 (Area: 4588) +(@CGUID+9, 31015, 571, 1, 64, 6498.057, 3314.354, 664.8021, 0.5061455, 120, 5, 1), -- 31015 (Area: 4588) (possible waypoints or random movement) +(@CGUID+10, 31015, 571, 1, 64, 6518.352, 3309.556, 665.1537, 5.462881, 120, 5, 1), -- 31015 (Area: 4588) (possible waypoints or random movement) +(@CGUID+11, 31015, 571, 1, 64, 6571.921, 3315.821, 668.0949, 2.940412, 120, 0, 0), -- 31015 (Area: 4588) +(@CGUID+12, 31015, 571, 1, 64, 6572.489, 3319.39, 667.0414, -1.827478, 120, 0, 0), -- 31015 (Area: 4588) +(@CGUID+13, 31015, 571, 1, 64, 6530.034, 3256.114, 666.3459, 4.205114, 120, 0, 0), -- 31015 (Area: 4588) +(@CGUID+14, 31015, 571, 1, 64, 6493.935, 3292.664, 664.7191, 5.110613, 120, 5, 1), -- 31015 (Area: 4588) (possible waypoints or random movement) +(@CGUID+15, 31015, 571, 1, 64, 6569.369, 3316.948, 667.7736, -0.4594761, 120, 0, 0), -- 31015 (Area: 4588) (Auras: ) +(@CGUID+16, 31015, 571, 1, 64, 6530.081, 3256.11, 666.2975, 4.193476, 120, 0, 0), -- 31015 (Area: 4588) +(@CGUID+17, 31015, 571, 1, 64, 6464.674, 3252.994, 641.5389, 5.995564, 120, 0, 0), -- 31015 (Area: 4531) +(@CGUID+18, 31015, 571, 1, 64, 6489.055, 3385.385, 598.3196, -1.682238, 120, 0, 0), -- 31015 (Area: 4531) +(@CGUID+19, 31015, 571, 1, 64, 6456.603, 3166.644, 657.527, 1.598204, 120, 0, 0), -- 31015 (Area: 4531) +(@CGUID+20, 31015, 571, 1, 64, 6461.294, 3153.185, 657.5644, 4.921828, 120, 5, 1), -- 31015 (Area: 4531) (possible waypoints or random movement) +(@CGUID+21, 31015, 571, 1, 64, 6453.171, 3166.278, 657.5888, 0.3810751, 120, 0, 0), -- 31015 (Area: 4531) +(@CGUID+22, 31015, 571, 1, 64, 6455.606, 3164.106, 657.6061, 1.870695, 120, 0, 0), -- 31015 (Area: 4531) +(@CGUID+23, 31015, 571, 1, 64, 6412.766, 3231.688, 639.8654, 4.939847, 120, 5, 1), -- 31015 (Area: 4531) (possible waypoints or random movement) +(@CGUID+24, 31015, 571, 1, 64, 6667.497, 3354.504, 704.6642, -2.447248, 120, 0, 0), -- 31015 (Area: 4531) +(@CGUID+25, 30696, 571, 1, 64, 6638.812, 3160.733, 660.6064, 1.080401, 120, 5, 1), -- 30696 (Area: 4588) (possible waypoints or random movement) +(@CGUID+26, 30696, 571, 1, 64, 6686.414, 3147.764, 656.3453, 6.07866, 120, 5, 1), -- 30696 (Area: 4588) (possible waypoints or random movement) +(@CGUID+27, 30696, 571, 1, 64, 6526.674, 3303.937, 665.1752, 4.911891, 120, 5, 1), -- 30696 (Area: 4588) (possible waypoints or random movement) +(@CGUID+28, 30696, 571, 1, 64, 6548.213, 3310.022, 665.8172, 2.349988, 120, 0, 0), -- 30696 (Area: 4588) +(@CGUID+29, 30696, 571, 1, 64, 6532.149, 3256.876, 666.6301, -2.182277, 120, 0, 0), -- 30696 (Area: 4588) +(@CGUID+30, 30696, 571, 1, 64, 6521.981, 3320.334, 664.9473, 4.594295, 120, 0, 0), -- 30696 (Area: 4588) +(@CGUID+31, 30696, 571, 1, 64, 6470.161, 3250.802, 643.5604, 3.930473, 120, 0, 0), -- 30696 (Area: 4531) +(@CGUID+32, 30696, 571, 1, 64, 6487.702, 3380.006, 599.0916, 6.272988, 120, 0, 0), -- 30696 (Area: 4531) +(@CGUID+33, 30696, 571, 1, 64, 6488.242, 3194.719, 652.9039, 1.48353, 120, 0, 0), -- 30696 (Area: 4531) +(@CGUID+34, 30696, 571, 1, 64, 6435.536, 3141.343, 657.5279, 0.1379021, 120, 5, 1), -- 30696 (Area: 4531) (possible waypoints or random movement) +(@CGUID+35, 30696, 571, 1, 64, 6564.194, 3135.601, 666.2081, 0.4537856, 120, 0, 0), -- 30696 (Area: 4531) +(@CGUID+36, 30696, 571, 1, 64, 6410.666, 3233.757, 640.489, 4.667454, 120, 5, 1), -- 30696 (Area: 4531) (possible waypoints or random movement) +(@CGUID+37, 30696, 571, 1, 64, 6413.427, 3218.029, 638.4678, 0.122173, 120, 0, 0), -- 30696 (Area: 4531) +(@CGUID+38, 30696, 571, 1, 64, 6452.031, 3161.715, 657.5867, 0.9863433, 120, 0, 0), -- 30696 (Area: 4531) +(@CGUID+39, 30696, 571, 1, 64, 6459.535, 3110.506, 657.6054, 1.157361, 120, 5, 1), -- 30696 (Area: 4531) (possible waypoints or random movement) +(@CGUID+40, 30696, 571, 1, 64, 6679.659, 3345.589, 704.6539, 3.205272, 120, 5, 1), -- 30696 (Area: 4531) (possible waypoints or random movement) +(@CGUID+41, 30703, 571, 1, 64, 6571.963, 3314.406, 668.2784, 2.36651, 120, 0, 0), -- 30703 (Area: 4588) +(@CGUID+42, 30703, 571, 1, 64, 6517.844, 3323.566, 664.8954, -0.663258, 120, 0, 0), -- 30703 (Area: 4588) +(@CGUID+43, 30703, 571, 1, 64, 6528.306, 3259.301, 665.793, -1.073858, 120, 0, 0), -- 30703 (Area: 4588) +(@CGUID+44, 30703, 571, 1, 64, 6454.563, 3168.846, 657.5237, 5.535412, 120, 0, 0), -- 30703 (Area: 4531) +(@CGUID+45, 30703, 571, 1, 64, 6421.846, 3257.234, 640.0424, 2.456618, 120, 0, 0), -- 30703 (Area: 4531) (Auras: ) +(@CGUID+46, 30703, 571, 1, 64, 6669.027, 3354.094, 704.2711, 2.458861, 120, 0, 0), -- 30703 (Area: 4531) +(@CGUID+47, 30704, 571, 1, 64, 6572.606, 3315.346, 668.405, -2.30596, 120, 0, 0), -- 30704 (Area: 4588) +(@CGUID+48, 30704, 571, 1, 64, 6568.352, 3316.549, 667.683, 2.906086, 120, 0, 0), -- 30704 (Area: 4588) +(@CGUID+49, 30704, 571, 1, 64, 6571.605, 3316.023, 668.1923, -2.073231, 120, 0, 0), -- 30704 (Area: 4588) +(@CGUID+50, 30704, 571, 1, 64, 6530.246, 3252.483, 666.8104, 1.616269, 120, 0, 0), -- 30704 (Area: 4588) +(@CGUID+51, 30704, 571, 1, 64, 6543.361, 3308.063, 665.3945, 0.383608, 120, 0, 0), -- 30704 (Area: 4588) +(@CGUID+52, 30704, 571, 1, 64, 6529.136, 3252.577, 666.5628, 1.30948, 120, 0, 0), -- 30704 (Area: 4588) (Auras: ) +(@CGUID+53, 30704, 571, 1, 64, 6489.347, 3384.931, 598.3163, -1.893157, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+54, 30704, 571, 1, 64, 6492.296, 3382.427, 598.8416, 5.579057, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+55, 30704, 571, 1, 64, 6488.653, 3381.798, 598.9666, 1.330476, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+56, 30704, 571, 1, 64, 6492.833, 3385.416, 598.5916, -3.133257, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+57, 30704, 571, 1, 64, 6492.375, 3197.953, 653.0616, -2.477693, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+58, 30704, 571, 1, 64, 6571.54, 3281.336, 670.894, 5.986175, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+59, 30704, 571, 1, 64, 6463.915, 3257.741, 640.313, 0.01159616, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+60, 30704, 571, 1, 64, 6462.88, 3253.862, 641.1767, 0.2747464, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+61, 30704, 571, 1, 64, 6468.83, 3249.454, 643.105, 0.7893116, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+62, 30704, 571, 1, 64, 6509.02, 3212.699, 658.4735, 2.319517, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+63, 30704, 571, 1, 64, 6507.89, 3210.89, 658.0303, 1.634014, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+64, 30704, 571, 1, 64, 6456.575, 3167.642, 657.5801, -1.838321, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+65, 30704, 571, 1, 64, 6452.937, 3166.663, 657.6061, -0.005128502, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+66, 30704, 571, 1, 64, 6454.717, 3168.428, 657.5237, 2.709053, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+67, 30704, 571, 1, 64, 6455.861, 3167.833, 657.575, -1.598367, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+68, 30704, 571, 1, 64, 6416.846, 3214.117, 639.7312, 2.10443, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+69, 30704, 571, 1, 64, 6590.434, 3331.823, 667.183, 4.037075, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+70, 30704, 571, 1, 64, 6668.725, 3357.257, 704.2558, -3.137703, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+71, 30704, 571, 1, 64, 6664.69, 3352.166, 704.3459, 1.520238, 120, 0, 0), -- 30704 (Area: 4531) +(@CGUID+72, 30697, 571, 1, 64, 6559.192, 3333.02, 664.9217, 4.991642, 120, 0, 0), -- 30697 (Area: 4588) +(@CGUID+73, 30697, 571, 1, 64, 6512.84, 3320.273, 665.2345, 0.5819893, 120, 0, 0), -- 30697 (Area: 4588) +(@CGUID+74, 30697, 571, 1, 64, 6515.811, 3280.09, 665.0708, 0.1396263, 120, 0, 0), -- 30697 (Area: 4531) +(@CGUID+75, 30697, 571, 1, 64, 6476.128, 3146.229, 657.5644, 4.380776, 120, 0, 0), -- 30697 (Area: 4531) +(@CGUID+76, 30697, 571, 1, 64, 6417.988, 3260.385, 640.6262, -0.6849744, 120, 0, 0), -- 30697 (Area: 4531) +(@CGUID+77, 31432, 571, 1, 64, 6588.427, 3278.203, 818.2033, 5.044002, 120, 5, 1); -- 31432 (Area: 4588) (possible waypoints or random movement) + + +UPDATE `creature` SET `phaseMask`=64 WHERE `id` IN(31314,30698,31306,31428); +UPDATE `creature` SET `phaseMask`=65 WHERE `id` IN(30597,32467); +UPDATE `creature_template` SET `unit_flags`=768 WHERE `entry`=31432; +UPDATE `creature` SET `equipment_id`=1 WHERE `id` IN(30703,30704); + +DELETE FROM `vehicle_template_accessory` WHERE `entry`=31432; +INSERT INTO `vehicle_template_accessory` (`entry`, `accessory_entry`, `seat_id`, `minion`, `description`, `summontype`, `summontimer`) VALUES +(31432, 31428, 0, 0, '31432 - 31428', 6, 30000); -- 31432 - 31428 + + +DELETE FROM `gameobject` WHERE `id` IN(193203,193204); +INSERT INTO `gameobject` (`guid`, `id`, `map`, `spawnMask`, `phaseMask`, `position_x`, `position_y`, `position_z`, `orientation`, `rotation0`, `rotation1`, `rotation2`, `rotation3`, `spawntimesecs`, `animprogress`, `state`) VALUES +(@OGUID+0, 193203, 571, 1, 64, 6531.642, 3336.632, 666.5159, 2.565632, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+1, 193203, 571, 1, 64, 6541.198, 3337.612, 674.4935, 3.194002, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+2, 193203, 571, 1, 64, 6561.242, 3342.843, 667.0536, 3.106652, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+3, 193203, 571, 1, 64, 6575.444, 3336.632, 667.6539, 4.398232, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+4, 193203, 571, 1, 64, 6517.65, 3262.135, 668.0207, 0.3141584, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+5, 193204, 571, 1, 64, 6509.69, 3298.966, 670.1282, 3.892087, 0, 0, 0, 1, 120, 255, 1), -- 193204 (Area: 4531) +(@OGUID+6, 193203, 571, 1, 64, 6441.041, 3245.802, 643.5339, 4.433136, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+7, 193203, 571, 1, 64, 6523.465, 3403.516, 599.7352, 1.06465, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+8, 193204, 571, 1, 64, 6774.447, 3517.597, 670.3411, 3.106652, 0, 0, 0, 1, 120, 255, 1), -- 193204 (Area: 4531) +(@OGUID+9, 193204, 571, 1, 64, 6774.1, 3539.328, 670.2827, 3.961899, 0, 0, 0, 1, 120, 255, 1), -- 193204 (Area: 4531) +(@OGUID+10, 193203, 571, 1, 64, 6815.187, 3502.362, 691.7656, 2.234018, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+11, 193203, 571, 1, 64, 6836.54, 3514.926, 691.6472, 3.560473, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+12, 193204, 571, 1, 64, 6859.746, 3515.827, 696.0732, 4.747296, 0, 0, 0, 1, 120, 255, 1), -- 193204 (Area: 4531) +(@OGUID+13, 193203, 571, 1, 64, 6717.095, 3499.194, 656.2964, 1.308995, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+14, 193203, 571, 1, 64, 6716.513, 3544.395, 670.4061, 0.6632232, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+15, 193203, 571, 1, 64, 6671.143, 3539.871, 670.931, 3.560473, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+16, 193203, 571, 1, 64, 6656.081, 3455.363, 632.7549, 2.705255, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+17, 193203, 571, 1, 64, 6678.709, 3572.928, 671.7523, 4.06662, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+18, 193203, 571, 1, 64, 6665.039, 3553.045, 670.4769, 2.076939, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+19, 193203, 571, 1, 64, 6466.252, 3423.323, 598.091, 0.4537851, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+20, 193203, 571, 1, 64, 6522.733, 3429.231, 599.0632, 3.351047, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+21, 193203, 571, 1, 64, 6516.931, 3478.982, 597.8824, 4.729844, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+22, 193203, 571, 1, 64, 6498.917, 3480.367, 596.7786, 2.024579, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+23, 193203, 571, 1, 64, 6544.474, 3464.513, 597.8202, 0.1396245, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+24, 193203, 571, 1, 64, 6671.423, 3264.837, 669.0335, 5.724681, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+25, 193203, 571, 1, 64, 6669.524, 3338.208, 703.5842, 1.797689, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+26, 193204, 571, 1, 64, 6926.368, 3514.581, 713.6303, 4.031712, 0, 0, 0, 1, 120, 255, 1), -- 193204 (Area: 4531) +(@OGUID+27, 193203, 571, 1, 64, 6901.291, 3446.396, 704.4607, 2.583081, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+28, 193204, 571, 1, 64, 6885.061, 3495.637, 707.6733, 6.056293, 0, 0, 0, 1, 120, 255, 1), -- 193204 (Area: 4531) +(@OGUID+29, 193203, 571, 1, 64, 6907.985, 3453.707, 705.4143, 6.03884, 0, 0, 0, 1, 120, 255, 1), -- 193203 (Area: 4531) +(@OGUID+30, 193203, 571, 1, 64, 6680.36, 3371.357, 701.1601, 0.3141584, 0, 0, 0, 1, 120, 255, 1); -- 193203 (Area: 4531) + +DELETE FROM `creature_template_addon` WHERE `entry` IN(30703,30704,31432); +INSERT INTO `creature_template_addon` (`entry`, `mount`, `bytes1`, `bytes2`, `auras`) VALUES +(31432, 0, 0x3000000, 0x1, ''), -- 31432 +(30703, 25280, 0x0, 0x1, ''), -- 30703 +(30704, 28919, 0x0, 0x1, ''); -- 30704 + +DELETE FROM `creature_addon` WHERE `guid` IN(@CGUID+41,@CGUID+42,@CGUID+43,@CGUID+47,@CGUID+48,@CGUID+49,@CGUID+50,@CGUID+51,@CGUID+52); +INSERT INTO `creature_addon` (`guid`, `mount`, `bytes1`, `bytes2`, `auras`) VALUES +(@CGUID+41, 0, 0x0, 0x1, ''), +(@CGUID+42, 0, 0x0, 0x1, ''), +(@CGUID+43, 0, 0x0, 0x1, ''), +(@CGUID+47, 0, 0x0, 0x1, ''), +(@CGUID+48, 0, 0x0, 0x1, ''), +(@CGUID+49, 0, 0x0, 0x1, ''), +(@CGUID+50, 0, 0x0, 0x1, ''), +(@CGUID+51, 0, 0x0, 0x1, ''), +(@CGUID+52, 0, 0x0, 0x1, ''); + +UPDATE `creature_template` SET `ainame`='SmartAI' WHERE `entry` IN(30703,30704,31015); +DELETE FROM `smart_scripts` WHERE `entryorguid` IN(30703,30704,31015) AND `source_type`=0; + +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(30703,0,0,0,4,0,100,0,0,0,0,0,43,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Ebon Blade Champion - On Agro - Dismount'), +(30703,0,1,0,0,0,100,0,0,5000,25000,35000,11,58130,2,0,0,0,0,1,0,0,0,0,0,0,0,'Ebon Blade Champion - IC - Cast Icebound Fortitude'), +(30703,0,2,0,9,0,100,0,0,5,20000,30000,11,50688,2,0,0,0,0,2,0,0,0,0,0,0,0,'Ebon Blade Champion - On Range - Cast Plague Strike'), +(30704,0,0,0,4,0,100,0,0,0,0,0,43,0,0,0,0,0,0,1,0,0,0,0,0,0,0,'Argent Paladin - On Agro - Dismount'), +(30704,0,1,0,9,0,100,0,0,5,12000,15000,11,58127,2,0,0,0,0,2,0,0,0,0,0,0,0,'Argent Paladin - On Range - Cast Divine Storm'), +(31015,0,0,0,9,0,100,0,0,5,15000,25000,11,60873,2,0,0,0,0,2,0,0,0,0,0,0,0,'Intrepid Ghoul - On Range - Cast Festering Bite'), +(31015,0,1,0,9,0,100,0,0,5,9000,16000,11,60872,2,0,0,0,0,2,0,0,0,0,0,0,0,'Intrepid Ghoul - On Range - Cast Festering Bite'), +(31015,0,2,0,2,0,100,1,0,10,0,0,11,58137,2,0,0,0,0,2,0,0,0,0,0,0,0,'Intrepid Ghoul - On Less than 10% hp - Cast Ghoulplosion'); diff --git a/sql/updates/world/2016_02_13_04_world.sql b/sql/updates/world/2016_02_13_04_world.sql new file mode 100644 index 00000000000..83d95745052 --- /dev/null +++ b/sql/updates/world/2016_02_13_04_world.sql @@ -0,0 +1,51 @@ +-- +-- Arred +UPDATE `creature` SET `spawndist` = 0, `MovementType` = 0 WHERE `guid` = 63008; +UPDATE `creature_template` SET `MovementType` = 0 WHERE `Entry` = 17512; +-- Arred SAI +SET @ENTRY := 17512; +UPDATE `creature_template` SET `AIName`="SmartAI" WHERE `entry`=@ENTRY; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,0,0,0,25,0,100,0,0,0,0,0,53,0,17512,1,0,0,0,1,0,0,0,0,0,0,0,"Arred - On Reset - Start Waypoint"), +(@ENTRY,0,1,0,64,0,100,0,0,0,0,0,54,20000,0,0,0,0,0,1,0,0,0,0,0,0,0,"Arred - On Gossip Hello - Pause Waypoint"), +(@ENTRY,0,2,0,40,0,100,0,1,17512,0,0,54,90000,0,0,0,0,0,1,0,0,0,0,0,0,0,"Arred - On Waypoint 1 Reached - Pause Waypoint"), +(@ENTRY,0,3,0,40,0,100,0,3,17512,0,0,80,@ENTRY*100+00,2,0,0,0,0,1,0,0,0,0,0,0,0,"Arred - On Waypoint 3 Reached - Run Script"), +(@ENTRY,0,4,0,40,0,100,0,7,17512,0,0,80,@ENTRY*100+01,2,0,0,0,0,1,0,0,0,0,0,0,0,"Arred - On Waypoint 7 Reached - Run Script"), +(@ENTRY,0,5,0,40,0,100,0,8,17512,0,0,80,@ENTRY*100+02,2,0,0,0,0,1,0,0,0,0,0,0,0,"Arred - On Waypoint 8 Reached - Run Script"), +(@ENTRY,0,6,0,40,0,100,0,9,17512,0,0,54,210000,0,0,0,0,0,1,0,0,0,0,0,0,0,"Arred - On Waypoint 9 Reached - Pause Waypoint"); + +-- Actionlist SAI +SET @ENTRY := 1751200; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,9,0,0,0,0,100,0,0,0,0,0,54,90000,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Pause Waypoint"), +(@ENTRY,9,1,0,0,0,100,0,88000,88000,0,0,5,3,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Play Emote 3"); + +-- Actionlist SAI +SET @ENTRY := 1751201; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,9,0,0,0,0,100,0,0,0,0,0,54,120000,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Pause Waypoint"), +(@ENTRY,9,1,0,0,0,100,0,3000,3000,0,0,90,8,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Set Flag Standstate Kneel"), +(@ENTRY,9,2,0,0,0,100,0,115000,115000,0,0,91,8,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Remove Flag Standstate Kneel"); + +-- Actionlist SAI +SET @ENTRY := 1751202; +DELETE FROM `smart_scripts` WHERE `entryorguid`=@ENTRY AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(@ENTRY,9,0,0,0,0,100,0,0,0,0,0,54,30000,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Pause Waypoint"), +(@ENTRY,9,1,0,0,0,100,0,4000,4000,0,0,5,25,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Play Emote 25"), +(@ENTRY,9,2,0,0,0,100,0,12000,12000,0,0,5,273,0,0,0,0,0,1,0,0,0,0,0,0,0,"On Script - Play Emote 273"); + +DELETE FROM `waypoints` WHERE `entry`=17512; +INSERT INTO `waypoints` (`entry`, `pointid`, `position_x`, `position_y`, `position_z`, `point_comment`) VALUES +(17512,1,-3788.04,-11547.3,-134.842, 'Arred'), +(17512,2,-3789.79,-11543.9,-134.849, 'Arred'), +(17512,3,-3793.72,-11542.8,-134.892, 'Arred'), +(17512,4,-3789.94,-11543.8,-134.851, 'Arred'), +(17512,5,-3787.24,-11546.9,-134.831, 'Arred'), +(17512,6,-3786.81,-11549.6,-134.836, 'Arred'), +(17512,7,-3787.67,-11551.3,-134.853, 'Arred'), +(17512,8,-3784.96,-11550.9,-134.819, 'Arred'), +(17512,9,-3788.04,-11547.3,-134.842, 'Arred'); diff --git a/sql/updates/world/2016_02_14_00_world.sql b/sql/updates/world/2016_02_14_00_world.sql new file mode 100644 index 00000000000..961ecd74d4d --- /dev/null +++ b/sql/updates/world/2016_02_14_00_world.sql @@ -0,0 +1,3 @@ +-- Disallow flight form while affected by no-mount shapeshift +DELETE FROM `spell_script_names` WHERE `spell_id` IN (-33943, 33943, 40120); +INSERT INTO `spell_script_names` (`spell_id`,`ScriptName`) VALUES (-33943, "spell_dru_flight_form"); diff --git a/sql/updates/world/2016_02_14_01_world.sql b/sql/updates/world/2016_02_14_01_world.sql new file mode 100644 index 00000000000..2ce06020621 --- /dev/null +++ b/sql/updates/world/2016_02_14_01_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature` SET `modelid`=0 WHERE `id`=27452; diff --git a/sql/updates/world/2016_02_14_02_world.sql b/sql/updates/world/2016_02_14_02_world.sql new file mode 100644 index 00000000000..1459b702cf0 --- /dev/null +++ b/sql/updates/world/2016_02_14_02_world.sql @@ -0,0 +1,16 @@ +-- Free at Last + +UPDATE `smart_scripts` SET `action_type`=45, `action_param1`=1, `action_param2`=1, `target_type`=1, `comment`='Runed Giant - On Script - Set Data Self' WHERE `entryorguid`=2641700 AND `source_type`=9 AND `id`=2 AND `link`=0; + +DELETE FROM `smart_scripts` WHERE `entryorguid`=26417 AND `source_type`=0; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(26417, 0, 0, 0, 11, 0, 100, 0, 0, 0, 0, 0, 11, 47329, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Runed Giant - On Spellhit \'Gavrock\'s Runebreaker\' - Run Script (No Repeat)'), +(26417, 0, 1, 0, 38, 0, 100, 0, 1, 1, 0, 0, 33, 26783, 0, 0, 0, 0, 0, 12, 1, 0, 0, 0, 0, 0, 0, 'Runed Giant - On Script - Quest Credit \'Free at Last\''), +(26417, 0, 2, 3, 8, 0, 25, 0, 47604, 0, 10000, 10000, 64, 1, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Runed Giant - On Spell Hit - Store Target List'), +(26417, 0, 3, 0, 61, 0, 0, 0, 0, 0, 10000, 10000, 80, 2641700, 2, 2, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Runed Giant - On Spell Hit - Start Script for Free At Last'); + +-- Put on Your Best Face for Loken +UPDATE `creature_template` SET `unit_flags`=33555200 WHERE `entry`=27212; + +-- Send them Packing +UPDATE `smart_scripts` SET `event_flags`=1 WHERE `entryorguid`=23977 AND `source_type`=0 AND `id`=0 AND `link`=0; diff --git a/sql/updates/world/2016_02_14_03_world.sql b/sql/updates/world/2016_02_14_03_world.sql new file mode 100644 index 00000000000..9a0237725c0 --- /dev/null +++ b/sql/updates/world/2016_02_14_03_world.sql @@ -0,0 +1,3 @@ +-- +DELETE FROM `linked_respawn` WHERE `guid`=150211 AND `linkedGuid`=150211; +DELETE FROM `creature` WHERE `guid`=150212 AND `id`=38995; diff --git a/sql/updates/world/2016_02_14_04_world.sql b/sql/updates/world/2016_02_14_04_world.sql new file mode 100644 index 00000000000..58e0aaee311 --- /dev/null +++ b/sql/updates/world/2016_02_14_04_world.sql @@ -0,0 +1,2 @@ +-- +UPDATE `creature_template` SET `flags_extra`=(`flags_extra`|2097152) WHERE `entry` IN (31304); diff --git a/sql/updates/world/2016_02_15_00_world.sql b/sql/updates/world/2016_02_15_00_world.sql new file mode 100644 index 00000000000..43c2ae69382 --- /dev/null +++ b/sql/updates/world/2016_02_15_00_world.sql @@ -0,0 +1,73 @@ +-- +UPDATE `creature_template` SET `unit_flags`=512, `VehicleId`=240, `InhabitType`=4 WHERE `entry`=30477; +UPDATE `creature_template` SET `minlevel`=80, `maxlevel`=80, `exp`=2, `unit_flags`=512, `VehicleId`=240, `InhabitType`=4 WHERE `entry`=30487; +UPDATE `creature_template` SET `AIName`='SmartAI' WHERE `entry` IN (29428,30477,30487); +DELETE FROM `smart_scripts` WHERE `entryorguid` IN (29428,30477,30487) AND `source_type`=0; +DELETE FROM `smart_scripts` WHERE `entryorguid` IN (30477*100,30487*100) AND `source_type`=9; +INSERT INTO `smart_scripts` (`entryorguid`,`source_type`,`id`,`link`,`event_type`,`event_phase_mask`,`event_chance`,`event_flags`,`event_param1`,`event_param2`,`event_param3`,`event_param4`,`action_type`,`action_param1`,`action_param2`,`action_param3`,`action_param4`,`action_param5`,`action_param6`,`target_type`,`target_param1`,`target_param2`,`target_param3`,`target_x`,`target_y`,`target_z`,`target_o`,`comment`) VALUES +(29428,0,0,2,62,0,100,0,9917,0,0,0,11,58061,0,0,0,0,0,7,0,0,0,0,0,0,0,'Ricket - On gossip select - Spellcast Forcecast Summon Rocket (Alliance)'), +(29428,0,1,2,62,0,100,0,9917,1,0,0,11,58062,0,0,0,0,0,7,0,0,0,0,0,0,0,'Ricket - On gossip select - Spellcast Forcecast Summon Rocket (Horde)'), +(29428,0,2,0,61,0,100,0,0,0,0,0,72,0,0,0,0,0,0,7,0,0,0,0,0,0,0,'Ricket - On gossip select - Close gossip'), +(30477,0,0,0,54,0,100,0,0,0,0,0,80,30477*100,2,0,0,0,0,1,0,0,0,0,0,0,0,'D16 Propelled Delivery Device - Just summoned - Run script'), +(30477,0,1,2,40,0,100,0,18,30477,0,0,11,50630,0,0,0,0,0,1,0,0,0,0,0,0,0,'D16 Propelled Delivery Device - On WP 18 reached - Spellcast Eject All Passengers'), +(30477,0,2,0,61,0,100,0,0,0,0,0,11,42895,0,0,0,0,0,23,0,0,0,0,0,0,0,'D16 Propelled Delivery Device - On WP 18 reached - Spellcast Cosmetic - Combat Knockdown Foe'), +(30477,0,3,0,40,0,100,0,24,30477,0,0,41,100,0,0,0,0,0,1,0,0,0,0,0,0,0,'D16 Propelled Delivery Device - On WP 24 reached - Despawn'), +(30487,0,0,0,54,0,100,0,0,0,0,0,80,30487*100,2,0,0,0,0,1,0,0,0,0,0,0,0,'D16 Propelled Delivery Device - Just summoned - Run script'), +(30487,0,1,2,40,0,100,0,13,30487,0,0,11,50630,0,0,0,0,0,1,0,0,0,0,0,0,0,'D16 Propelled Delivery Device - On WP 13 reached - Spellcast Eject All Passengers'), +(30487,0,2,0,61,0,100,0,0,0,0,0,11,42895,0,0,0,0,0,23,0,0,0,0,0,0,0,'D16 Propelled Delivery Device - On WP 13 reached - Spellcast Cosmetic - Combat Knockdown Foe'), +(30487,0,3,0,40,0,100,0,17,30487,0,0,41,100,0,0,0,0,0,1,0,0,0,0,0,0,0,'D16 Propelled Delivery Device - On WP 17 reached - Despawn'), +(30477*100,9,0,0,0,0,100,0,3000,3000,0,0,53,1,30477,0,0,0,0,1,0,0,0,0,0,0,0,'D16 Propelled Delivery Device script - Start WP movement'), +(30487*100,9,0,0,0,0,100,0,3000,3000,0,0,53,1,30487,0,0,0,0,1,0,0,0,0,0,0,0,'D16 Propelled Delivery Device script - Start WP movement'); + +DELETE FROM `waypoints` WHERE `entry` IN (30477,30487); +INSERT INTO `waypoints` (`entry`,`pointid`,`position_x`,`position_y`,`position_z`,`point_comment`) VALUES +(30477,1,6164.999,-1064.512,422.1189,'D16 Propelled Delivery Device'), +(30477,2,6204.096,-998.4872,457.5628,'D16 Propelled Delivery Device'), +(30477,3,6289.573,-952.1809,504.6187,'D16 Propelled Delivery Device'), +(30477,4,6307.788,-872.7999,541.7296,'D16 Propelled Delivery Device'), +(30477,5,6370.582,-821.9507,653.868,'D16 Propelled Delivery Device'), +(30477,6,6413.268,-660.4708,808.3953,'D16 Propelled Delivery Device'), +(30477,7,6554.813,-550.3772,1018.112,'D16 Propelled Delivery Device'), +(30477,8,6633.265,-419.3159,1173.914,'D16 Propelled Delivery Device'), +(30477,9,6760.503,-364.4665,1277.719,'D16 Propelled Delivery Device'), +(30477,10,6807.88,-427.5194,1399.109,'D16 Propelled Delivery Device'), +(30477,11,6808.07,-471.4465,1419.247,'D16 Propelled Delivery Device'), +(30477,12,6775.634,-529.2309,1394.387,'D16 Propelled Delivery Device'), +(30477,13,6720.645,-535.5529,1328.054,'D16 Propelled Delivery Device'), +(30477,14,6660.31,-486.8651,1238.553,'D16 Propelled Delivery Device'), +(30477,15,6658.937,-417.8409,1186.11,'D16 Propelled Delivery Device'), +(30477,16,6680.49,-329.3087,1098.609,'D16 Propelled Delivery Device'), +(30477,17,6683.783,-220.3454,972.7203,'D16 Propelled Delivery Device'), +(30477,18,6663.772,-192.1261,962.2485,'D16 Propelled Delivery Device'), +(30477,19,6654.82,-180.1689,958.1317,'D16 Propelled Delivery Device'), +(30477,20,6631.467,-171.3305,966.4633,'D16 Propelled Delivery Device'), +(30477,21,6598.223,-162.3664,984.2227,'D16 Propelled Delivery Device'), +(30477,22,6566.67,-155.2077,992.0551,'D16 Propelled Delivery Device'), +(30477,23,6529.651,-154.9363,992.0551,'D16 Propelled Delivery Device'), +(30477,24,6454.417,-152.1311,962.305,'D16 Propelled Delivery Device'), +(30487,1,6169.229,-1069.619,420.6945,'D16 Propelled Delivery Device'), +(30487,2,6232.725,-1031.598,505.7779,'D16 Propelled Delivery Device'), +(30487,3,6339.224,-1035.08,575.3331,'D16 Propelled Delivery Device'), +(30487,4,6431.492,-987.6745,694.8887,'D16 Propelled Delivery Device'), +(30487,5,6632.437,-925.9739,896.1384,'D16 Propelled Delivery Device'), +(30487,6,6822.084,-755.521,1171.194,'D16 Propelled Delivery Device'), +(30487,7,7090.693,-619.4874,1455.639,'D16 Propelled Delivery Device'), +(30487,8,7260.75,-282.75,1513.362,'D16 Propelled Delivery Device'), +(30487,9,7552.502,-334.6509,1657.668,'D16 Propelled Delivery Device'), +(30487,10,7692.301,-509.425,1536.5,'D16 Propelled Delivery Device'), +(30487,11,7799.192,-636.3267,1252.278,'D16 Propelled Delivery Device'), +(30487,12,7841.555,-726.5501,1193.916,'D16 Propelled Delivery Device'), +(30487,13,7844.731,-775.3613,1185.833,'D16 Propelled Delivery Device'), +(30487,14,7842.449,-815.5735,1186.396,'D16 Propelled Delivery Device'), +(30487,15,7838.703,-859.9572,1173.173,'D16 Propelled Delivery Device'), +(30487,16,7865.014,-911.2181,1163.979,'D16 Propelled Delivery Device'), +(30487,17,7856.225,-951.6568,1151.563,'D16 Propelled Delivery Device'); + +DELETE FROM `gossip_menu_option` WHERE `menu_id`=9917 AND `id`=1; +INSERT INTO `gossip_menu_option` (`menu_id`,`id`,`option_icon`,`option_text`,`OptionBroadcastTextID`,`option_id`,`npc_option_npcflag`,`action_menu_id`,`action_poi_id`,`box_coded`,`box_money`,`box_text`) VALUES +(9917,1,0,'I am ready to head further into Storm Peaks.',32890,1,1,0,0,0,0,''); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=15 AND `SourceGroup`=9917; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`,`SourceGroup`,`SourceEntry`,`ElseGroup`,`ConditionTypeOrReference`,`ConditionValue1`,`ConditionValue2`,`ConditionValue3`,`ErrorTextId`,`ScriptName`,`Comment`) VALUES +(15,9917,0,0,28,12862,0,0,0,'','Ricket - Show gossip option only if player has completed but not rewarded quest When All Else Fails'), +(15,9917,1,0,28,13060,0,0,0,'','Ricket - Show gossip option only if player has completed but not rewarded quest When All Else Fails'); diff --git a/sql/updates/world/2016_02_17_00_world.sql b/sql/updates/world/2016_02_17_00_world.sql new file mode 100644 index 00000000000..8f22aaa3e4e --- /dev/null +++ b/sql/updates/world/2016_02_17_00_world.sql @@ -0,0 +1,343 @@ +-- +DELETE FROM `creature_addon` WHERE `guid` IN (SELECT `guid` FROM `creature` WHERE `id` IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175)); +DELETE FROM `game_event_creature` WHERE `guid` IN (SELECT `guid` FROM `creature` WHERE `id` IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175)) AND `eventEntry` !=2; +DELETE FROM `creature` WHERE `id` IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175) AND `guid` NOT IN (SELECT `guid` FROM `game_event_creature` WHERE `eventEntry` =2); +DELETE FROM `creature_template_addon` WHERE `entry` IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); +UPDATE `creature` SET `equipment_id`=0, `modelid`=0 WHERE `id` IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); +UPDATE `creature_template` SET `npcflag`=3, `unit_flags`=`unit_flags`|768 WHERE `entry` IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); + +INSERT INTO `game_event_creature` SELECT 12, creature.guid FROM `creature` WHERE creature.id IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); +INSERT INTO `game_event_creature` SELECT 24, creature.guid FROM `creature` WHERE creature.id IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); +INSERT INTO `game_event_creature` SELECT 7, creature.guid FROM `creature` WHERE creature.id IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); +INSERT INTO `game_event_creature` SELECT 1, creature.guid FROM `creature` WHERE creature.id IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); +INSERT INTO `game_event_creature` SELECT 26, creature.guid FROM `creature` WHERE creature.id IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); +INSERT INTO `game_event_creature` SELECT 51, creature.guid FROM `creature` WHERE creature.id IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); +INSERT INTO `game_event_creature` SELECT 50, creature.guid FROM `creature` WHERE creature.id IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); +INSERT INTO `game_event_creature` SELECT 9, creature.guid FROM `creature` WHERE creature.id IN (20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); + +SET @entry1:=20102; +SET @entry2:=19172; +SET @entry3:=19169; +SET @entry4:=19173; +SET @entry5:=19171; +SET @entry6:=19148; +SET @entry7:=19177; +SET @entry8:=19176; +SET @entry9:=19178; +SET @entry10:=18927; +SET @entry11:=19175; + +DELETE FROM smart_scripts WHERE `entryorguid` IN(@entry1,@entry2,@entry3,@entry4,@entry5,@entry6,@entry7,@entry8,@entry9,@entry10,@entry11) AND source_type=0 AND id>12; +DELETE FROM smart_scripts WHERE `entryorguid` IN (@entry1*100, @entry1*100+1, @entry2*100, @entry2*100+1, @entry3*100, @entry3*100+1, @entry4*100, @entry4*100+1, @entry5*100, @entry5*100+1, @entry6*100, @entry6*100+1, @entry7*100, @entry7*100+1, @entry8*100, @entry8*100+1, @entry9*100, @entry9*100+1, @entry10*100, @entry10*100+1, @entry11*100, @entry11*100+1) AND source_type=9; +DELETE FROM smart_scripts WHERE `entryorguid` IN (@entry1*100+2, @entry1*100+3, @entry2*100+2, @entry2*100+3, @entry3*100+2, @entry3*100+3, @entry4*100+2, @entry4*100+3, @entry5*100+2, @entry5*100+3, @entry6*100+2, @entry6*100+3, @entry7*100+2, @entry7*100+3, @entry8*100+2, @entry8*100+3, @entry9*100+2, @entry9*100+3, @entry10*100+2, @entry10*100+3, @entry11*100+2, @entry11*100+3) AND source_type=9; +DELETE FROM smart_scripts WHERE `entryorguid` IN (@entry1*100+4, @entry1*100+5, @entry2*100+4, @entry2*100+5, @entry3*100+4, @entry3*100+5, @entry4*100+5, @entry4*100+4, @entry5*100+4, @entry5*100+5, @entry6*100+4, @entry6*100+5, @entry7*100+4, @entry7*100+5, @entry8*100+4, @entry8*100+5, @entry9*100+4, @entry9*100+5, @entry10*100+4, @entry10*100+5, @entry11*100+4, @entry11*100+5) AND source_type=9; +DELETE FROM smart_scripts WHERE `entryorguid` IN (@entry1*100+6, @entry1*100+7, @entry2*100+6, @entry2*100+7, @entry3*100+6, @entry3*100+7, @entry4*100+6, @entry4*100+7, @entry5*100+6, @entry5*100+7, @entry6*100+6, @entry6*100+7, @entry7*100+6, @entry7*100+7, @entry8*100+6, @entry8*100+7, @entry9*100+6, @entry9*100+7, @entry10*100+6, @entry10*100+7, @entry11*100+6, @entry11*100+7) AND source_type=9; +DELETE FROM smart_scripts WHERE `entryorguid` IN (@entry1*100+8, @entry1*100+9, @entry2*100+8, @entry2*100+9, @entry3*100+8, @entry3*100+9, @entry4*100+8, @entry4*100+9, @entry5*100+8, @entry5*100+9, @entry6*100+8, @entry6*100+9, @entry7*100+8, @entry7*100+9, @entry8*100+8, @entry8*100+9, @entry9*100+8, @entry9*100+9, @entry10*100+8, @entry10*100+9, @entry11*100+8, @entry11*100+9) AND source_type=9; +DELETE FROM smart_scripts WHERE `entryorguid` IN (@entry1*100+10, @entry1*100+11, @entry2*100+10, @entry2*100+11, @entry3*100+10, @entry3*100+11, @entry4*100+10, @entry4*100+11, @entry5*100+10, @entry5*100+11, @entry6*100+10, @entry6*100+11, @entry7*100+10, @entry7*100+11, @entry8*100+10, @entry8*100+11, @entry9*100+10, @entry9*100+11, @entry10*100+10, @entry10*100+11, @entry11*100+10, @entry11*100+11) AND source_type=9; +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(@entry1, 0, 13, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry1*100, @entry1*100+1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - On respawn - random action list'), -- Goblin christmas +(@entry1*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 34845, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - cast '), +(@entry1*100+1, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 34849, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - cast'), +(@entry1, 0, 14, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry1*100+2, @entry1*100+3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - On respawn - random action list'), -- Goblin Halloween +(@entry1*100+2, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43631, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - cast '), +(@entry1*100+3, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43630, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - cast'), +(@entry1, 0, 15, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry1*100+4, @entry1*100+5, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - On respawn - random action list'), -- Goblin Lunar +(@entry1*100+4, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 34848, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - cast '), +(@entry1*100+5, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 34851, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - cast'), +(@entry1, 0, 16, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, @entry1*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - On respawn - random action list'), -- Goblin Brewfest +(@entry1*100+6, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43911, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - cast '), +(@entry1*100+6, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 71, 0, 0, 13861, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - Equip'), +(@entry1, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry1*100+7, @entry1*100+8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - On respawn - random action list'), -- Goblin DOTD +(@entry1*100+7, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29203, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - Morph '), +(@entry1*100+8, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - Morph'), +(@entry1, 0, 18, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry1*100+9, @entry1*100+10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - On respawn - random action list'), -- Goblin pirates +(@entry1*100+9, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25036, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - Morph '), +(@entry1*100+10, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25047, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - random action list - Morph'), +(@entry1, 0, 19, 0, 11, 0, 100, 0, 0, 0, 0, 0, 3, 25872, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Goblin commoner - On respawn - Morph'), -- Goblin midsummer +(@entry2, 0, 13, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry2*100, @entry2*100+1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - On respawn - random action list'), -- Gnome christmas +(@entry2*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33448, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - random action list - cast '), +(@entry2*100+1, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33445, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - random action list - cast'), +(@entry2, 0, 14, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry2*100+2, @entry2*100+3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - On respawn - random action list'), -- Gnome Halloween +(@entry2*100+2, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43629, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - random action list - cast '), +(@entry2*100+3, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43628, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - random action list - cast'), +(@entry2, 0, 15, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry2*100+4, @entry2*100+5, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome - On respawn - random action list'), -- Gnome Lunar +(@entry2*100+4, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33446, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome - random action list - cast '), +(@entry2*100+5, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33449, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome - random action list - cast'), +(@entry2, 0, 16, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, @entry2*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - On respawn - random action list'), -- Gnome Brewfest +(@entry2*100+6, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43910, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - random action list - cast '), +(@entry2*100+6, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 71, 0, 0, 13861, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - random action list - Equip'), +(@entry2, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry2*100+7, @entry2*100+8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - On respawn - random action list'), -- Gnome DOTD +(@entry2*100+7, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29203, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - random action list - Morph '), +(@entry2*100+8, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - random action list - Morph'), +(@entry2, 0, 18, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry2*100+9, @entry2*100+10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - On respawn - random action list'), -- Gnome pirates +(@entry2*100+9, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25035, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - random action list - Morph '), +(@entry2*100+10, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25046, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - random action list - Morph'), +(@entry2, 0, 19, 0, 11, 0, 100, 0, 0, 0, 0, 0, 3, 25871, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Gnome commoner - On respawn - Morph'), -- Gnome midsummer +(@entry3, 0, 13, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry3*100, @entry3*100+1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - On respawn - random action list'), -- blood elf christmas +(@entry3*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33412, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - random action list - cast '), +(@entry3*100+1, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33415, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - random action list - cast'), +(@entry3, 0, 14, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry3*100+2, @entry3*100+3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - On respawn - random action list'), -- blood elf Halloween +(@entry3*100+2, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43406, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - random action list - cast '), +(@entry3*100+3, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43405, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - random action list - cast'), +(@entry3, 0, 15, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry3*100+4, @entry3*100+5, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - On respawn - random action list'), -- blood elf Lunar +(@entry3*100+4, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33413, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - random action list - cast '), +(@entry3*100+5, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33416, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - random action list - cast'), +(@entry3, 0, 16, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, @entry3*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - On respawn - random action list'), -- blood elf Brewfest +(@entry3*100+6, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43907, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - random action list - cast '), +(@entry3*100+6, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 71, 0, 0, 2703, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Bloodelf commoner - random action list - Equip'), +(@entry3, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry3*100+7, @entry3*100+8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'blood elf commoner - On respawn - random action list'), -- blood elf DOTD +(@entry3*100+7, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29203, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'blood elf commoner - random action list - Morph '), +(@entry3*100+8, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'blood elf commoner - random action list - Morph'), +(@entry3, 0, 18, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry3*100+9, @entry3*100+10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'blood elf commoner - On respawn - random action list'), -- blood elf pirates +(@entry3*100+9, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25032, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'blood elf commoner - random action list - Morph '), +(@entry3*100+10, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25043, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'blood elf commoner - random action list - Morph'), +(@entry3, 0, 19, 0, 11, 0, 100, 0, 0, 0, 0, 0, 3, 25868, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'blood elf commoner - On respawn - Morph'), -- blood elf midsummer +(@entry4, 0, 13, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry4*100, @entry4*100+1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - On respawn - random action list'), -- night elf christmas +(@entry4*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33439, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - random action list - cast '), +(@entry4*100+1, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33442, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - random action list - cast'), +(@entry4, 0, 14, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry4*100+2, @entry4*100+3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - On respawn - random action list'), -- night elf Halloween +(@entry4*100+2, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43635, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - random action list - cast '), +(@entry4*100+3, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43634, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - random action list - cast'), +(@entry4, 0, 15, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry4*100+4, @entry4*100+5, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - On respawn - random action list'), -- night elf Lunar +(@entry4*100+4, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33443, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - random action list - cast '), +(@entry4*100+5, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33440, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - random action list - cast'), +(@entry4, 0, 16, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, @entry4*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - On respawn - random action list'), -- night elf Brewfest +(@entry4*100+6, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43913, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - random action list - cast '), +(@entry4*100+6, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 71, 0, 0, 2703, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - random action list - Equip'), +(@entry4, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry4*100+7, @entry4*100+8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - On respawn - random action list'), -- night commoner DOTD +(@entry4*100+7, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29203, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - random action list - Morph '), +(@entry4*100+8, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night commoner - random action list - Morph'), +(@entry4, 0, 18, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry4*100+9, @entry4*100+10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night elf commoner - On respawn - random action list'), -- night elf pirates +(@entry4*100+9, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25038, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night elf commoner - random action list - Morph '), +(@entry4*100+10, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25049, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night elf commoner - random action list - Morph'), +(@entry4, 0, 19, 0, 11, 0, 100, 0, 0, 0, 0, 0, 3, 25874, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'night elf commoner - On respawn - Morph'), -- night elf midsummer +(@entry5, 0, 13, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry5*100, @entry5*100+1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei - On respawn - random action list'), -- Draenei christmas +(@entry5*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33427, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei - random action list - cast '), +(@entry5*100+1, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33430, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei - random action list - cast'), +(@entry5, 0, 14, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry5*100+2, @entry5*100+3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei - On respawn - random action list'), -- Draenei Halloween +(@entry5*100+2, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43625, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei - random action list - cast '), +(@entry5*100+3, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43623, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei - random action list - cast'), +(@entry5, 0, 15, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry5*100+4, @entry5*100+5, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei - On respawn - random action list'), -- Draenei Lunar +(@entry5*100+4, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33428, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei - random action list - cast '), +(@entry5*100+5, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33431, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei - random action list - cast'), +(@entry5, 0, 16, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, @entry5*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei - On respawn - random action list'), -- Draenei Brewfest +(@entry5*100+6, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43908, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei - random action list - cast '), +(@entry5*100+6, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 71, 0, 0, 2703, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei commoner - random action list - Equip'), +(@entry5, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry5*100+7, @entry5*100+8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei commoner - On respawn - random action list'), -- Draenei DOTD +(@entry5*100+7, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29203, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei commoner - random action list - Morph '), +(@entry5*100+8, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei commoner - random action list - Morph'), +(@entry5, 0, 18, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry5*100+9, @entry5*100+10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei commoner - On respawn - random action list'), -- Draenei pirates +(@entry5*100+9, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25033, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei commoner - random action list - Morph '), +(@entry5*100+10, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25044, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei commoner - random action list - Morph'), +(@entry5, 0, 19, 0, 11, 0, 100, 0, 0, 0, 0, 0, 3, 25869, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Draenei commoner - On respawn - Morph'), -- Draenei midsummer +(@entry6, 0, 13, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry6*100, @entry6*100+1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - On respawn - random action list'), -- Dwarf christmas +(@entry6*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33433, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - cast '), +(@entry6*100+1, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33436, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - cast'), +(@entry6, 0, 14, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry6*100+2, @entry6*100+3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf - On respawn - random action list'), -- Dwarf Halloween +(@entry6*100+2, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43626, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - cast '), +(@entry6*100+3, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43627, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - cast'), +(@entry6, 0, 15, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry6*100+4, @entry6*100+5, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf - On respawn - random action list'), -- Dwarf Lunar +(@entry6*100+4, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33437, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - cast '), +(@entry6*100+5, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33434, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - cast'), +(@entry6, 0, 16, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, @entry6*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - On respawn - random action list'), -- Dwarf Brewfest +(@entry6*100+6, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43909, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - cast '), +(@entry6*100+6, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 71, 0, 0, 13861, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - Equip'), +(@entry6, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry6*100+7, @entry6*100+8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - On respawn - random action list'), -- Dwarf DOTD +(@entry6*100+7, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29203, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - Morph '), +(@entry6*100+8, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - Morph'), +(@entry6, 0, 18, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry6*100+9, @entry6*100+10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - On respawn - random action list'), -- Dwarf pirates +(@entry6*100+9, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25034, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - Morph '), +(@entry6*100+10, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25045, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - random action list - Morph'), +(@entry6, 0, 19, 0, 11, 0, 100, 0, 0, 0, 0, 0, 3, 25870, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Dwarf commoner - On respawn - Morph'), -- Dwarf midsummer +(@entry7, 0, 13, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry7*100, @entry7*100+1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll - On respawn - random action list'), -- Troll christmas +(@entry7*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33471, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll - random action list - cast '), +(@entry7*100+1, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33468, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll - random action list - cast'), +(@entry7, 0, 14, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry7*100+2, @entry7*100+3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll - On respawn - random action list'), -- Troll Halloween +(@entry7*100+2, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43641, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll - random action list - cast '), +(@entry7*100+3, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43640, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll - random action list - cast'), +(@entry7, 0, 15, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry7*100+4, @entry7*100+5, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll - On respawn - random action list'), -- Troll Lunar +(@entry7*100+4, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33472, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll - random action list - cast '), +(@entry7*100+5, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33469, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll - random action list - cast'), +(@entry7, 0, 16, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, @entry7*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll commoner - On respawn - random action list'), -- Troll Brewfest +(@entry7*100+6, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43916, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll commoner - random action list - cast '), +(@entry7*100+6, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 71, 0, 0, 2705, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll commoner - random action list - Equip'), +(@entry7, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry7*100+7, @entry7*100+8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll commoner - On respawn - random action list'), -- Troll DOTD +(@entry7*100+7, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29203, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll commoner - random action list - Morph '), +(@entry7*100+8, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll commoner - random action list - Morph'), +(@entry7, 0, 18, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry7*100+9, @entry7*100+10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll commoner - On respawn - random action list'), -- Troll pirates +(@entry7*100+9, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25041, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll commoner - random action list - Morph '), +(@entry7*100+10, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25052, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll commoner - random action list - Morph'), +(@entry7, 0, 19, 0, 11, 0, 100, 0, 0, 0, 0, 0, 3, 25877, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Troll commoner - On respawn - Morph'), -- Troll midsummer +(@entry8, 0, 13, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry8*100, @entry8*100+1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren - On respawn - random action list'), -- Tauren christmas +(@entry8*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33465, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren - random action list - cast '), +(@entry8*100+1, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33458, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren - random action list - cast'), +(@entry8, 0, 14, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry8*100+2, @entry8*100+3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren - On respawn - random action list'), -- Tauren Halloween +(@entry8*100+2, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43638, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren - random action list - cast '), +(@entry8*100+3, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43639, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren - random action list - cast'), +(@entry8, 0, 15, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry8*100+4, @entry8*100+5, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren - On respawn - random action list'), -- Tauren Lunar +(@entry8*100+4, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33459, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren - random action list - cast '), +(@entry8*100+5, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33466, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren - random action list - cast'), +(@entry8, 0, 16, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, @entry8*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren commoner - On respawn - random action list'), -- Tauren Brewfest +(@entry8*100+6, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43915, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren commoner - random action list - cast '), +(@entry8*100+6, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 71, 0, 0, 2705, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren commoner - random action list - Equip'), +(@entry8, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry8*100+7, @entry8*100+8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren commoner - On respawn - random action list'), -- Tauren DOTD +(@entry8*100+7, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29203, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren commoner - random action list - Morph '), +(@entry8*100+8, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren commoner - random action list - Morph'), +(@entry8, 0, 18, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry8*100+9, @entry8*100+10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren commoner - On respawn - random action list'), -- Tauren pirates +(@entry8*100+9, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25040, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren commoner - random action list - Morph '), +(@entry8*100+10, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25051, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren commoner - random action list - Morph'), +(@entry8, 0, 19, 0, 11, 0, 100, 0, 0, 0, 0, 0, 3, 25876, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Tauren commoner - On respawn - Morph'), -- Tauren midsummer +(@entry9, 0, 13, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry9*100, @entry9*100+1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead - On respawn - random action list'), -- Undead christmas +(@entry9*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33474, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead - random action list - cast '), +(@entry9*100+1, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33477, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead - random action list - cast'), +(@entry9, 0, 14, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry9*100+2, @entry9*100+3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead - On respawn - random action list'), -- Undead christmas +(@entry9*100+2, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43642, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead - random action list - cast '), +(@entry9*100+3, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43643, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead - random action list - cast'), +(@entry9, 0, 15, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry9*100+4, @entry9*100+5, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead - On respawn - random action list'), -- Undead Lunar +(@entry9*100+4, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33478, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead - random action list - cast '), +(@entry9*100+5, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33475, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead - random action list - cast'), +(@entry9, 0, 16, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, @entry9*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead commoner - On respawn - random action list'), -- Undead Brewfest +(@entry9*100+6, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43917, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead commoner - random action list - cast '), +(@entry9*100+6, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 71, 0, 0, 2705, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead commoner - random action list - Equip'), +(@entry9, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry9*100+7, @entry9*100+8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead commoner - On respawn - random action list'), -- Undead DOTD +(@entry9*100+7, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29203, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead commoner - random action list - Morph '), +(@entry9*100+8, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Undead commoner - random action list - Morph'), +(@entry9, 0, 18, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry9*100+9, @entry9*100+10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'undead commoner - On respawn - random action list'), -- undead pirates +(@entry9*100+9, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25042, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'undead commoner - random action list - Morph '), +(@entry9*100+10, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25053, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'undead commoner - random action list - Morph'), +(@entry9, 0, 19, 0, 11, 0, 100, 0, 0, 0, 0, 0, 3, 25878, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'undead commoner - On respawn - Morph'), -- undead midsummer +(@entry10, 0, 13, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry10*100, @entry10*100+1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human - On respawn - random action list'), -- Human christmas +(@entry10*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33402, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human - random action list - cast '), +(@entry10*100+1, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33403, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human - random action list - cast'), +(@entry10, 0, 14, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry10*100+2, @entry10*100+3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human - On respawn - random action list'), -- Human Halloween +(@entry10*100+2, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43633, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human - random action list - cast '), +(@entry10*100+3, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43632, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human - random action list - cast'), +(@entry10, 0, 15, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry10*100+4, @entry10*100+5, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human - On respawn - random action list'), -- Human Lunar +(@entry10*100+4, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33397, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human - random action list - cast '), +(@entry10*100+5, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33398, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human - random action list - cast'), +(@entry10, 0, 16, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, @entry10*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human commoner - On respawn - random action list'), -- Human Brewfest +(@entry10*100+6, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43912, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human commoner - random action list - cast '), +(@entry10*100+6, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 71, 0, 0, 2705, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human commoner - random action list - Equip'), +(@entry10, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry10*100+7, @entry10*100+8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human commoner - On respawn - random action list'), -- Human DOTD +(@entry10*100+7, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29203, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human commoner - random action list - Morph '), +(@entry10*100+8, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human commoner - random action list - Morph'), +(@entry10, 0, 18, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry10*100+9, @entry10*100+10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human commoner - On respawn - random action list'), -- Human pirates +(@entry10*100+9, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25037, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human commoner - random action list - Morph '), +(@entry10*100+10, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25048, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human commoner - random action list - Morph'), +(@entry10, 0, 19, 0, 11, 0, 100, 0, 0, 0, 0, 0, 3, 25873, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Human commoner - On respawn - Morph'), -- Human midsummer +(@entry11, 0, 13, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry11*100, @entry11*100+1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc - On respawn - random action list'), -- Orc christmas +(@entry11*100, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33451, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc - random action list - cast '), +(@entry11*100+1, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33455, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc - random action list - cast'), +(@entry11, 0, 14, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry11*100+2, @entry11*100+3, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc - On respawn - random action list'), -- Orc Halloween +(@entry11*100+2, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43637, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc - random action list - cast '), +(@entry11*100+3, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43636, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc - random action list - cast'), +(@entry11, 0, 15, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry11*100+4, @entry11*100+5, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc - On respawn - random action list'), -- Orc Lunar +(@entry11*100+4, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33456, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc - random action list - cast '), +(@entry11*100+5, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 33453, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc - random action list - cast'), +(@entry11, 0, 16, 0, 11, 0, 100, 0, 0, 0, 0, 0, 80, @entry11*100+6, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc commoner - On respawn - random action list'), -- Orc Brewfest +(@entry11*100+6, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 11, 43914, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc commoner - random action list - cast '), +(@entry11*100+6, 9, 1, 0, 0, 0, 100, 0, 0, 0, 0, 0, 71, 0, 0, 2705, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc commoner - random action list - Equip'), +(@entry11, 0, 17, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry11*100+7, @entry11*100+8, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc commoner - On respawn - random action list'), -- Orc DOTD +(@entry11*100+7, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29203, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc commoner - random action list - Morph '), +(@entry11*100+8, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 29204, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc commoner - random action list - Morph'), +(@entry11, 0, 18, 0, 11, 0, 100, 0, 0, 0, 0, 0, 87, @entry11*100+9, @entry11*100+10, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc commoner - On respawn - random action list'), -- Orc pirates +(@entry11*100+9, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25039, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc commoner - random action list - Morph '), +(@entry11*100+10, 9, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 3, 0, 25050, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc commoner - random action list - Morph'), +(@entry11, 0, 19, 0, 11, 0, 100, 0, 0, 0, 0, 0, 3, 25875, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 'Orc commoner - On respawn - Morph'); -- Orc midsummer + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=22 AND `SourceEntry` IN (20102,18927,19177,19169,19175,19171,19172,19176,19178,19173,19148) AND `SourceGroup` >13; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(22, 14, 19148, 0, 0, 12, 1, 2, 0, 0, 0, 0, 0, '', 'Commoner - Winter Veil must be active'), +(22, 14, 20102, 0, 0, 12, 1, 2, 0, 0, 0, 0, 0, '', 'Commoner - Winter Veil must be active'), +(22, 14, 18927, 0, 0, 12, 1, 2, 0, 0, 0, 0, 0, '', 'Commoner - Winter Veil must be active'), +(22, 14, 19171, 0, 0, 12, 1, 2, 0, 0, 0, 0, 0, '', 'Commoner - Winter Veil must be active'), +(22, 14, 19172, 0, 0, 12, 1, 2, 0, 0, 0, 0, 0, '', 'Commoner - Winter Veil must be active'), +(22, 14, 19173, 0, 0, 12, 1, 2, 0, 0, 0, 0, 0, '', 'Commoner - Winter Veil must be active'), +(22, 14, 19175, 0, 0, 12, 1, 2, 0, 0, 0, 0, 0, '', 'Commoner - Winter Veil must be active'), +(22, 14, 19176, 0, 0, 12, 1, 2, 0, 0, 0, 0, 0, '', 'Commoner - Winter Veil must be active'), +(22, 14, 19177, 0, 0, 12, 1, 2, 0, 0, 0, 0, 0, '', 'Commoner - Winter Veil must be active'), +(22, 14, 19178, 0, 0, 12, 1, 2, 0, 0, 0, 0, 0, '', 'Commoner - Winter Veil must be active'), +(22, 14, 19169, 0, 0, 12, 1, 2, 0, 0, 0, 0, 0, '', 'Commoner - Winter Veil must be active'), +(22, 15, 19148, 0, 0, 12, 1, 12, 0, 0, 0, 0, 0, '', 'Commoner - Hallow''s End must be active'), +(22, 15, 20102, 0, 0, 12, 1, 12, 0, 0, 0, 0, 0, '', 'Commoner - Hallow''s End must be active'), +(22, 15, 18927, 0, 0, 12, 1, 12, 0, 0, 0, 0, 0, '', 'Commoner - Hallow''s End must be active'), +(22, 15, 19171, 0, 0, 12, 1, 12, 0, 0, 0, 0, 0, '', 'Commoner - Hallow''s End must be active'), +(22, 15, 19172, 0, 0, 12, 1, 12, 0, 0, 0, 0, 0, '', 'Commoner - Hallow''s End must be active'), +(22, 15, 19173, 0, 0, 12, 1, 12, 0, 0, 0, 0, 0, '', 'Commoner - Hallow''s End must be active'), +(22, 15, 19175, 0, 0, 12, 1, 12, 0, 0, 0, 0, 0, '', 'Commoner - Hallow''s End must be active'), +(22, 15, 19176, 0, 0, 12, 1, 12, 0, 0, 0, 0, 0, '', 'Commoner - Hallow''s End must be active'), +(22, 15, 19177, 0, 0, 12, 1, 12, 0, 0, 0, 0, 0, '', 'Commoner - Hallow''s End must be active'), +(22, 15, 19178, 0, 0, 12, 1, 12, 0, 0, 0, 0, 0, '', 'Commoner - Hallow''s End must be active'), +(22, 15, 19169, 0, 0, 12, 1, 12, 0, 0, 0, 0, 0, '', 'Commoner - Hallow''s End must be active'), +(22, 16, 19148, 0, 0, 12, 1, 7, 0, 0, 0, 0, 0, '', 'Commoner - Lunar Festival must be active'), +(22, 16, 20102, 0, 0, 12, 1, 7, 0, 0, 0, 0, 0, '', 'Commoner - Lunar Festival must be active'), +(22, 16, 18927, 0, 0, 12, 1, 7, 0, 0, 0, 0, 0, '', 'Commoner - Lunar Festival must be active'), +(22, 16, 19171, 0, 0, 12, 1, 7, 0, 0, 0, 0, 0, '', 'Commoner - Lunar Festival must be active'), +(22, 16, 19172, 0, 0, 12, 1, 7, 0, 0, 0, 0, 0, '', 'Commoner - Lunar Festival must be active'), +(22, 16, 19173, 0, 0, 12, 1, 7, 0, 0, 0, 0, 0, '', 'Commoner - Lunar Festival must be active'), +(22, 16, 19175, 0, 0, 12, 1, 7, 0, 0, 0, 0, 0, '', 'Commoner - Lunar Festival must be active'), +(22, 16, 19176, 0, 0, 12, 1, 7, 0, 0, 0, 0, 0, '', 'Commoner - Lunar Festival must be active'), +(22, 16, 19177, 0, 0, 12, 1, 7, 0, 0, 0, 0, 0, '', 'Commoner - Lunar Festival must be active'), +(22, 16, 19178, 0, 0, 12, 1, 7, 0, 0, 0, 0, 0, '', 'Commoner - Lunar Festival must be active'), +(22, 16, 19169, 0, 0, 12, 1, 7, 0, 0, 0, 0, 0, '', 'Commoner - Lunar Festival must be active'), +(22, 17, 19148, 0, 0, 12, 1, 24, 0, 0, 0, 0, 0, '', 'Commoner - Brew Fest must be active'), +(22, 17, 20102, 0, 0, 12, 1, 24, 0, 0, 0, 0, 0, '', 'Commoner - Brew Fest must be active'), +(22, 17, 18927, 0, 0, 12, 1, 24, 0, 0, 0, 0, 0, '', 'Commoner - Brew Fest must be active'), +(22, 17, 19171, 0, 0, 12, 1, 24, 0, 0, 0, 0, 0, '', 'Commoner - Brew Fest must be active'), +(22, 17, 19172, 0, 0, 12, 1, 24, 0, 0, 0, 0, 0, '', 'Commoner - Brew Fest must be active'), +(22, 17, 19173, 0, 0, 12, 1, 24, 0, 0, 0, 0, 0, '', 'Commoner - Brew Fest must be active'), +(22, 17, 19175, 0, 0, 12, 1, 24, 0, 0, 0, 0, 0, '', 'Commoner - Brew Fest must be active'), +(22, 17, 19176, 0, 0, 12, 1, 24, 0, 0, 0, 0, 0, '', 'Commoner - Brew Fest must be active'), +(22, 17, 19177, 0, 0, 12, 1, 24, 0, 0, 0, 0, 0, '', 'Commoner - Brew Fest must be active'), +(22, 17, 19178, 0, 0, 12, 1, 24, 0, 0, 0, 0, 0, '', 'Commoner - Brew Fest must be active'), +(22, 17, 19169, 0, 0, 12, 1, 24, 0, 0, 0, 0, 0, '', 'Commoner - Brew Fest must be active'), +(22, 18, 19148, 0, 0, 12, 1, 51, 0, 0, 0, 0, 0, '', 'Commoner - DOTD must be active'), +(22, 18, 20102, 0, 0, 12, 1, 51, 0, 0, 0, 0, 0, '', 'Commoner - DOTD must be active'), +(22, 18, 18927, 0, 0, 12, 1, 51, 0, 0, 0, 0, 0, '', 'Commoner - DOTD must be active'), +(22, 18, 19171, 0, 0, 12, 1, 51, 0, 0, 0, 0, 0, '', 'Commoner - DOTD must be active'), +(22, 18, 19172, 0, 0, 12, 1, 51, 0, 0, 0, 0, 0, '', 'Commoner - DOTD must be active'), +(22, 18, 19173, 0, 0, 12, 1, 51, 0, 0, 0, 0, 0, '', 'Commoner - DOTD must be active'), +(22, 18, 19175, 0, 0, 12, 1, 51, 0, 0, 0, 0, 0, '', 'Commoner - DOTD must be active'), +(22, 18, 19176, 0, 0, 12, 1, 51, 0, 0, 0, 0, 0, '', 'Commoner - DOTD must be active'), +(22, 18, 19177, 0, 0, 12, 1, 51, 0, 0, 0, 0, 0, '', 'Commoner - DOTD must be active'), +(22, 18, 19178, 0, 0, 12, 1, 51, 0, 0, 0, 0, 0, '', 'Commoner - DOTD must be active'), +(22, 18, 19169, 0, 0, 12, 1, 51, 0, 0, 0, 0, 0, '', 'Commoner - DOTD must be active'), +(22, 19, 19148, 0, 0, 12, 1, 50, 0, 0, 0, 0, 0, '', 'Commoner - Pirates Day must be active'), +(22, 19, 20102, 0, 0, 12, 1, 50, 0, 0, 0, 0, 0, '', 'Commoner - Pirates Day must be active'), +(22, 19, 18927, 0, 0, 12, 1, 50, 0, 0, 0, 0, 0, '', 'Commoner - Pirates Day must be active'), +(22, 19, 19171, 0, 0, 12, 1, 50, 0, 0, 0, 0, 0, '', 'Commoner - Pirates Day must be active'), +(22, 19, 19172, 0, 0, 12, 1, 50, 0, 0, 0, 0, 0, '', 'Commoner - Pirates Day must be active'), +(22, 19, 19173, 0, 0, 12, 1, 50, 0, 0, 0, 0, 0, '', 'Commoner - Pirates Day must be active'), +(22, 19, 19175, 0, 0, 12, 1, 50, 0, 0, 0, 0, 0, '', 'Commoner - Pirates Day must be active'), +(22, 19, 19176, 0, 0, 12, 1, 50, 0, 0, 0, 0, 0, '', 'Commoner - Pirates Day must be active'), +(22, 19, 19177, 0, 0, 12, 1, 50, 0, 0, 0, 0, 0, '', 'Commoner - Pirates Day must be active'), +(22, 19, 19178, 0, 0, 12, 1, 50, 0, 0, 0, 0, 0, '', 'Commoner - Pirates Day must be active'), +(22, 19, 19169, 0, 0, 12, 1, 50, 0, 0, 0, 0, 0, '', 'Commoner - Pirates Day must be active'), +(22, 20, 19148, 0, 0, 12, 1, 1, 0, 0, 0, 0, 0, '', 'Commoner - Midsummer Fire Festival must be active'), +(22, 20, 20102, 0, 0, 12, 1, 1, 0, 0, 0, 0, 0, '', 'Commoner - Midsummer Fire Festival must be active'), +(22, 20, 18927, 0, 0, 12, 1, 1, 0, 0, 0, 0, 0, '', 'Commoner - Midsummer Fire Festival must be active'), +(22, 20, 19171, 0, 0, 12, 1, 1, 0, 0, 0, 0, 0, '', 'Commoner - Midsummer Fire Festival must be active'), +(22, 20, 19172, 0, 0, 12, 1, 1, 0, 0, 0, 0, 0, '', 'Commoner - Midsummer Fire Festival must be active'), +(22, 20, 19173, 0, 0, 12, 1, 1, 0, 0, 0, 0, 0, '', 'Commoner - Midsummer Fire Festival must be active'), +(22, 20, 19175, 0, 0, 12, 1, 1, 0, 0, 0, 0, 0, '', 'Commoner - Midsummer Fire Festival must be active'), +(22, 20, 19176, 0, 0, 12, 1, 1, 0, 0, 0, 0, 0, '', 'Commoner - Midsummer Fire Festival must be active'), +(22, 20, 19177, 0, 0, 12, 1, 1, 0, 0, 0, 0, 0, '', 'Commoner - Midsummer Fire Festival must be active'), +(22, 20, 19178, 0, 0, 12, 1, 1, 0, 0, 0, 0, 0, '', 'Commoner - Midsummer Fire Festival must be active'), +(22, 20, 19169, 0, 0, 12, 1, 1, 0, 0, 0, 0, 0, '', 'Commoner - Midsummer Fire Festival must be active'); + +DELETE FROM `game_event_creature_quest` WHERE `quest` IN (13483, 13484); +INSERT INTO `game_event_creature_quest` (`eventEntry`, `id`, `quest`) VALUES +(9, 19148, 13484), +(9, 18927, 13484), +(9, 19178, 13483), +(9, 19177, 13483), +(9, 19176, 13483), +(9, 19175, 13483), +(9, 19169, 13483), +(9, 19171, 13484), +(9, 19172, 13484), +(9, 19173, 13484), +(9, 20102, 13484), +(9, 20102, 13483); + +DELETE FROM `creature_queststarter` WHERE `id` IN(20102, 19172, 19169, 19173, 19171, 19148, 19177, 19176, 19178, 18927, 19175); diff --git a/sql/updates/world/2016_02_17_01_world.sql b/sql/updates/world/2016_02_17_01_world.sql new file mode 100644 index 00000000000..20f3605b197 --- /dev/null +++ b/sql/updates/world/2016_02_17_01_world.sql @@ -0,0 +1,40 @@ +UPDATE `creature_template` SET `AIName`='SmartAI',`npcflag`=1,`gossip_menu_id`=10990 WHERE `entry`IN(37671,38065); +UPDATE `creature` SET `npcflag`=3 WHERE `id`=38293; + +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid` IN(37172,38066) AND `id`>2; +DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid` IN(37671,38065); + +DELETE FROM `smart_scripts` WHERE `source_type`=2 AND `entryorguid` IN(5703,5705) AND `id`=1; + +INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES +(37671, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 21, 100, 0, 0, 0, 0, 0, 0, 'Crown Supply Guard - On Data Set - Say'), +(38065, 0, 0, 0, 38, 0, 100, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 21, 100, 0, 0, 0, 0, 0, 0, 'Crown Supply Guard - On Data Set - Say'), +(37172, 0, 3, 0, 8, 0, 100, 0, 69445, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Detective Snap Snagglebolt - On Spellhit - say'), +(37172, 0, 4, 0, 8, 0, 100, 0, 69563, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Detective Snap Snagglebolt - On Spellhit - say'), +(37172, 0, 5, 0, 8, 0, 100, 0, 69489, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Detective Snap Snagglebolt - On Spellhit - say'), +(38066, 0, 3, 0, 8, 0, 100, 0, 69445, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Inspector Snip Snagglebolt - On Spellhit - say'), +(38066, 0, 4, 0, 8, 0, 100, 0, 69563, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Inspector Snip Snagglebolt - On Spellhit - say'), +(38066, 0, 5, 0, 8, 0, 100, 0, 69489, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Inspector Snip Snagglebolt - On Spellhit - say'), +(5703,2,1,0,61,0,100,0,0,0,0,0,45,1,1,0,0,0,0,10,208843,38065,0,0,0,0,0,"On Trigger - Set Data"), +(5705,2,1,0,61,0,100,0,0,0,0,0,45,1,1,0,0,0,0,10,48573,37671,0,0,0,0,0,"On Trigger - Set Data"); + +UPDATE `smart_scripts` SET `link`=1 WHERE `entryorguid`IN(5703,5705) AND `source_type`=2 AND `id`=0 AND `link`=0; + +DELETE FROM `creature_text` WHERE `entry` IN(37172,38066,37671,38065); +INSERT INTO `creature_text` (`entry`, `groupid`, `id`, `text`, `type`, `language`, `probability`, `emote`, `duration`, `sound`, `BroadcastTextId`, `TextRange`, `comment`) VALUES +(37671, 0, 0, 'That crate won''t deliver itself, friend. Get a move on!', 12, 0, 100, 1, 0, 0, 38024, 0, 'Crown Supply Guard'), +(38065, 0, 0, 'That crate won''t deliver itself, friend. Get a move on!', 12, 0, 100, 1, 0, 0, 38024, 0, 'Crown Supply Guard'), +(37172, 0, 0, 'You know, that does smell pretty... Hey! Stop spraying that thing at me!', 12, 0, 100, 1, 0, 0, 38296, 0, 'Detective Snap Snagglebolt'), +(37172, 1, 0, 'Don''t tempt me! Do you even know what''s in those things?', 12, 0, 100, 1, 0, 0, 38382, 0, 'Detective Snap Snagglebolt'), +(38066, 0, 0, 'You know, that does smell pretty... Hey! Stop spraying that thing at me!', 12, 0, 100, 1, 0, 0, 38296, 0, 'Inspector Snip Snagglebolt'), +(38066, 1, 0, 'Don''t tempt me! Do you even know what''s in those things?', 12, 0, 100, 1, 0, 0, 38382, 0, 'Inspector Snip Snagglebolt'); + +DELETE FROM `gossip_menu` WHERE `entry`=10990; +INSERT INTO `gossip_menu` (`entry`, `text_id`) VALUES +(10990, 15282), +(10990, 15280); + +DELETE FROM `conditions` WHERE `SourceTypeOrReferenceId`=14 AND `SourceGroup`=10990; +INSERT INTO `conditions` (`SourceTypeOrReferenceId`, `SourceGroup`, `SourceEntry`, `SourceId`, `ElseGroup`, `ConditionTypeOrReference`, `ConditionTarget`, `ConditionValue1`, `ConditionValue2`, `ConditionValue3`, `NegativeCondition`, `ErrorType`, `ErrorTextId`, `ScriptName`, `Comment`) VALUES +(14, 10990, 15280, 0, 0, 1, 0, 71450, 0, 0, 1, 0, 0, '', 'Crown Guard has different gossip if player has no aura Crown Parcel Service Uniform'), +(14, 10990, 15282, 0, 0, 1, 0, 71450, 0, 0, 0, 0, 0, '', 'Crown Guard has different gossip if player has aura Crown Parcel Service Uniform'); diff --git a/sql/updates/world/2016_02_17_02_world.sql b/sql/updates/world/2016_02_17_02_world.sql new file mode 100644 index 00000000000..6590396b7d9 --- /dev/null +++ b/sql/updates/world/2016_02_17_02_world.sql @@ -0,0 +1,21 @@ + UPDATE `creature_template` SET `gossip_menu_id`=10948, `npcflag`=3, `AIName`='SmartAI' WHERE `entry` IN(38045,38044,38043,38042,38041,38040,38039,37887); + + DELETE FROM `smart_scripts` WHERE `source_type`=0 AND `entryorguid` IN (38045,38044,38043,38042,38041,38040,38039,37887); + + INSERT INTO `smart_scripts` (`entryorguid`, `source_type`, `id`, `link`, `event_type`, `event_phase_mask`, `event_chance`, `event_flags`, `event_param1`, `event_param2`, `event_param3`, `event_param4`, `action_type`, `action_param1`, `action_param2`, `action_param3`, `action_param4`, `action_param5`, `action_param6`, `target_type`, `target_param1`, `target_param2`, `target_param3`, `target_x`, `target_y`, `target_z`, `target_o`, `comment`) VALUES + (38045, 0, 0, 1, 62, 0, 100, 0, 10948, 0, 0, 0, 11, 70648, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Cast Create Lovely Charm Collectors Kit'), + (38045, 0, 1, 0, 61, 0, 100, 0, 10948, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Close Gossip'), + (38044, 0, 0, 1, 62, 0, 100, 0, 10948, 0, 0, 0, 11, 70648, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Cast Create Lovely Charm Collectors Kit'), + (38044, 0, 1, 0, 61, 0, 100, 0, 10948, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Close Gossip'), + (38043, 0, 0, 1, 62, 0, 100, 0, 10948, 0, 0, 0, 11, 70648, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Cast Create Lovely Charm Collectors Kit'), + (38043, 0, 1, 0, 61, 0, 100, 0, 10948, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Close Gossip'), + (38042, 0, 0, 1, 62, 0, 100, 0, 10948, 0, 0, 0, 11, 70648, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Cast Create Lovely Charm Collectors Kit'), + (38042, 0, 1, 0, 61, 0, 100, 0, 10948, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Close Gossip'), + (38041, 0, 0, 1, 62, 0, 100, 0, 10948, 0, 0, 0, 11, 70648, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Cast Create Lovely Charm Collectors Kit'), + (38041, 0, 1, 0, 61, 0, 100, 0, 10948, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Close Gossip'), + (38040, 0, 0, 1, 62, 0, 100, 0, 10948, 0, 0, 0, 11, 70648, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Cast Create Lovely Charm Collectors Kit'), + (38040, 0, 1, 0, 61, 0, 100, 0, 10948, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Close Gossip'), + (38039, 0, 0, 1, 62, 0, 100, 0, 10948, 0, 0, 0, 11, 70648, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Cast Create Lovely Charm Collectors Kit'), + (38039, 0, 1, 0, 61, 0, 100, 0, 10948, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Close Gossip'), + (37887, 0, 0, 1, 62, 0, 100, 0, 10948, 0, 0, 0, 11, 70648, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Cast Create Lovely Charm Collectors Kit'), + (37887, 0, 1, 0, 61, 0, 100, 0, 10948, 0, 0, 0, 72, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 0, 0, 0, 0, 'Kwee Q. Peddlefeet - On Gossip Option Select - Close Gossip'); diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 914ad31ad06..619ab3300c0 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/common/CMakeLists.txt b/src/common/CMakeLists.txt index 7f20fe36ab6..8dee99c65e7 100644 --- a/src/common/CMakeLists.txt +++ b/src/common/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/common/Collision/BoundingIntervalHierarchy.cpp b/src/common/Collision/BoundingIntervalHierarchy.cpp index 12af680712e..bd3bebdec0a 100644 --- a/src/common/Collision/BoundingIntervalHierarchy.cpp +++ b/src/common/Collision/BoundingIntervalHierarchy.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/BoundingIntervalHierarchy.h b/src/common/Collision/BoundingIntervalHierarchy.h index 3a09772c41f..0b15bd2d92f 100644 --- a/src/common/Collision/BoundingIntervalHierarchy.h +++ b/src/common/Collision/BoundingIntervalHierarchy.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/BoundingIntervalHierarchyWrapper.h b/src/common/Collision/BoundingIntervalHierarchyWrapper.h index 60bb6a569df..222ae8b93a5 100644 --- a/src/common/Collision/BoundingIntervalHierarchyWrapper.h +++ b/src/common/Collision/BoundingIntervalHierarchyWrapper.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/DynamicTree.cpp b/src/common/Collision/DynamicTree.cpp index 1de2543543d..5d2e18b1a2e 100644 --- a/src/common/Collision/DynamicTree.cpp +++ b/src/common/Collision/DynamicTree.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/DynamicTree.h b/src/common/Collision/DynamicTree.h index 5e905323640..0f18bb265f8 100644 --- a/src/common/Collision/DynamicTree.h +++ b/src/common/Collision/DynamicTree.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Management/IVMapManager.h b/src/common/Collision/Management/IVMapManager.h index b890554257c..1e64551956c 100644 --- a/src/common/Collision/Management/IVMapManager.h +++ b/src/common/Collision/Management/IVMapManager.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Management/MMapFactory.cpp b/src/common/Collision/Management/MMapFactory.cpp index 667b8378c56..c7012d1fb68 100644 --- a/src/common/Collision/Management/MMapFactory.cpp +++ b/src/common/Collision/Management/MMapFactory.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Management/MMapFactory.h b/src/common/Collision/Management/MMapFactory.h index 773983f81eb..edd074fc93d 100644 --- a/src/common/Collision/Management/MMapFactory.h +++ b/src/common/Collision/Management/MMapFactory.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Management/MMapManager.cpp b/src/common/Collision/Management/MMapManager.cpp index 00985e4fa1d..04b1e62399b 100644 --- a/src/common/Collision/Management/MMapManager.cpp +++ b/src/common/Collision/Management/MMapManager.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Management/MMapManager.h b/src/common/Collision/Management/MMapManager.h index 42292b76942..1a502a916dd 100644 --- a/src/common/Collision/Management/MMapManager.h +++ b/src/common/Collision/Management/MMapManager.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Management/VMapFactory.cpp b/src/common/Collision/Management/VMapFactory.cpp index 4c2750a9e5c..9c693d5d3d5 100644 --- a/src/common/Collision/Management/VMapFactory.cpp +++ b/src/common/Collision/Management/VMapFactory.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Management/VMapFactory.h b/src/common/Collision/Management/VMapFactory.h index 3067c2919d5..1a45bd5094b 100644 --- a/src/common/Collision/Management/VMapFactory.h +++ b/src/common/Collision/Management/VMapFactory.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Management/VMapManager2.cpp b/src/common/Collision/Management/VMapManager2.cpp index a63eac1b935..22a6abfa28b 100644 --- a/src/common/Collision/Management/VMapManager2.cpp +++ b/src/common/Collision/Management/VMapManager2.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Management/VMapManager2.h b/src/common/Collision/Management/VMapManager2.h index c2e1aee1ff7..722ac4935c6 100644 --- a/src/common/Collision/Management/VMapManager2.h +++ b/src/common/Collision/Management/VMapManager2.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Maps/MapTree.cpp b/src/common/Collision/Maps/MapTree.cpp index e374da4f1b9..4d0996e1961 100644 --- a/src/common/Collision/Maps/MapTree.cpp +++ b/src/common/Collision/Maps/MapTree.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Maps/MapTree.h b/src/common/Collision/Maps/MapTree.h index 08bd5c3d3a1..63d542754c1 100644 --- a/src/common/Collision/Maps/MapTree.h +++ b/src/common/Collision/Maps/MapTree.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Maps/TileAssembler.cpp b/src/common/Collision/Maps/TileAssembler.cpp index ec7b759f975..3f58b8f3516 100644 --- a/src/common/Collision/Maps/TileAssembler.cpp +++ b/src/common/Collision/Maps/TileAssembler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Maps/TileAssembler.h b/src/common/Collision/Maps/TileAssembler.h index 581622c6b73..1e2dc1924f1 100644 --- a/src/common/Collision/Maps/TileAssembler.h +++ b/src/common/Collision/Maps/TileAssembler.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Models/GameObjectModel.cpp b/src/common/Collision/Models/GameObjectModel.cpp index dbdc0554e06..39e81985731 100644 --- a/src/common/Collision/Models/GameObjectModel.cpp +++ b/src/common/Collision/Models/GameObjectModel.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Models/GameObjectModel.h b/src/common/Collision/Models/GameObjectModel.h index 17669189af5..9d8687233c1 100644 --- a/src/common/Collision/Models/GameObjectModel.h +++ b/src/common/Collision/Models/GameObjectModel.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Models/ModelInstance.cpp b/src/common/Collision/Models/ModelInstance.cpp index 45440a99666..54e5fe5c295 100644 --- a/src/common/Collision/Models/ModelInstance.cpp +++ b/src/common/Collision/Models/ModelInstance.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Models/ModelInstance.h b/src/common/Collision/Models/ModelInstance.h index f8bbfa4fa73..d101630d1e9 100644 --- a/src/common/Collision/Models/ModelInstance.h +++ b/src/common/Collision/Models/ModelInstance.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Models/WorldModel.cpp b/src/common/Collision/Models/WorldModel.cpp index 7f4d76b244a..96ee6d2d55c 100644 --- a/src/common/Collision/Models/WorldModel.cpp +++ b/src/common/Collision/Models/WorldModel.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/Models/WorldModel.h b/src/common/Collision/Models/WorldModel.h index afa9d15b264..39787f6c664 100644 --- a/src/common/Collision/Models/WorldModel.h +++ b/src/common/Collision/Models/WorldModel.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/VMapDefinitions.h b/src/common/Collision/VMapDefinitions.h index 1035d5307cc..0b0e15368e5 100644 --- a/src/common/Collision/VMapDefinitions.h +++ b/src/common/Collision/VMapDefinitions.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Collision/VMapTools.h b/src/common/Collision/VMapTools.h index 662dc43e9e7..a7e4149b516 100644 --- a/src/common/Collision/VMapTools.h +++ b/src/common/Collision/VMapTools.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Common.cpp b/src/common/Common.cpp index 56e3c4faaf5..308da602579 100644 --- a/src/common/Common.cpp +++ b/src/common/Common.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Common.h b/src/common/Common.h index 7a1ea247a94..e8adc55d20d 100644 --- a/src/common/Common.h +++ b/src/common/Common.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/CompilerDefs.h b/src/common/CompilerDefs.h index c7867be517b..3a436c9a0fe 100644 --- a/src/common/CompilerDefs.h +++ b/src/common/CompilerDefs.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Configuration/Config.cpp b/src/common/Configuration/Config.cpp index ea426a5d33e..6ac04615315 100644 --- a/src/common/Configuration/Config.cpp +++ b/src/common/Configuration/Config.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Configuration/Config.h b/src/common/Configuration/Config.h index 5fb7cef9241..5b04212ed7c 100644 --- a/src/common/Configuration/Config.h +++ b/src/common/Configuration/Config.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Cryptography/ARC4.cpp b/src/common/Cryptography/ARC4.cpp index d1082b39347..eea523a2090 100644 --- a/src/common/Cryptography/ARC4.cpp +++ b/src/common/Cryptography/ARC4.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Cryptography/ARC4.h b/src/common/Cryptography/ARC4.h index 16a0cb92eb9..f39e662e295 100644 --- a/src/common/Cryptography/ARC4.h +++ b/src/common/Cryptography/ARC4.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Cryptography/Authentication/AuthCrypt.cpp b/src/common/Cryptography/Authentication/AuthCrypt.cpp index 153726e6950..a6d00002071 100644 --- a/src/common/Cryptography/Authentication/AuthCrypt.cpp +++ b/src/common/Cryptography/Authentication/AuthCrypt.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Cryptography/Authentication/AuthCrypt.h b/src/common/Cryptography/Authentication/AuthCrypt.h index b8913c95a2c..878391e3ce8 100644 --- a/src/common/Cryptography/Authentication/AuthCrypt.h +++ b/src/common/Cryptography/Authentication/AuthCrypt.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Cryptography/BigNumber.cpp b/src/common/Cryptography/BigNumber.cpp index 720e8e30441..3b85122ebab 100644 --- a/src/common/Cryptography/BigNumber.cpp +++ b/src/common/Cryptography/BigNumber.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Cryptography/BigNumber.h b/src/common/Cryptography/BigNumber.h index e6a056b5baa..a5bda50dc72 100644 --- a/src/common/Cryptography/BigNumber.h +++ b/src/common/Cryptography/BigNumber.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Cryptography/HMACSHA1.cpp b/src/common/Cryptography/HMACSHA1.cpp index 304633cbc03..6109afe3f87 100644 --- a/src/common/Cryptography/HMACSHA1.cpp +++ b/src/common/Cryptography/HMACSHA1.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Cryptography/HMACSHA1.h b/src/common/Cryptography/HMACSHA1.h index 66cf214d9b1..29a926d5b16 100644 --- a/src/common/Cryptography/HMACSHA1.h +++ b/src/common/Cryptography/HMACSHA1.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Cryptography/OpenSSLCrypto.cpp b/src/common/Cryptography/OpenSSLCrypto.cpp index f122888292f..9ab03d1c61a 100644 --- a/src/common/Cryptography/OpenSSLCrypto.cpp +++ b/src/common/Cryptography/OpenSSLCrypto.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Cryptography/OpenSSLCrypto.h b/src/common/Cryptography/OpenSSLCrypto.h index 0daa20c4780..df1b14b5eda 100644 --- a/src/common/Cryptography/OpenSSLCrypto.h +++ b/src/common/Cryptography/OpenSSLCrypto.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Cryptography/SHA1.cpp b/src/common/Cryptography/SHA1.cpp index bd7101075de..a01bd7844ee 100644 --- a/src/common/Cryptography/SHA1.cpp +++ b/src/common/Cryptography/SHA1.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Cryptography/SHA1.h b/src/common/Cryptography/SHA1.h index f59bdc25556..ffa02176a2d 100644 --- a/src/common/Cryptography/SHA1.h +++ b/src/common/Cryptography/SHA1.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Cryptography/WardenKeyGeneration.h b/src/common/Cryptography/WardenKeyGeneration.h index bfa0337d347..18118ece649 100644 --- a/src/common/Cryptography/WardenKeyGeneration.h +++ b/src/common/Cryptography/WardenKeyGeneration.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Debugging/Errors.cpp b/src/common/Debugging/Errors.cpp index 4c7e91a8219..1ec66ff6d59 100644 --- a/src/common/Debugging/Errors.cpp +++ b/src/common/Debugging/Errors.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Debugging/Errors.h b/src/common/Debugging/Errors.h index 9e526933acc..38e311a6b13 100644 --- a/src/common/Debugging/Errors.h +++ b/src/common/Debugging/Errors.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Define.h b/src/common/Define.h index 7332bdc4cff..b34edb6a549 100644 --- a/src/common/Define.h +++ b/src/common/Define.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -83,10 +83,16 @@ # define ATTR_NORETURN __attribute__((__noreturn__)) # define ATTR_PRINTF(F, V) __attribute__ ((__format__ (__printf__, F, V))) # define ATTR_DEPRECATED __attribute__((__deprecated__)) +# define TRINITY_CONSTEXPR constexpr #else //COMPILER != COMPILER_GNU # define ATTR_NORETURN # define ATTR_PRINTF(F, V) # define ATTR_DEPRECATED +#if _MSC_VER >= 1900 +# define TRINITY_CONSTEXPR constexpr +#else +# define TRINITY_CONSTEXPR +#endif #endif //COMPILER == COMPILER_GNU #define UI64FMTD "%" PRIu64 diff --git a/src/common/GitRevision.h b/src/common/GitRevision.h index d9b292031f6..8d2764ba861 100644 --- a/src/common/GitRevision.h +++ b/src/common/GitRevision.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Logging/Appender.cpp b/src/common/Logging/Appender.cpp index d19ef8cf96f..e72ea92a871 100644 --- a/src/common/Logging/Appender.cpp +++ b/src/common/Logging/Appender.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Logging/Appender.h b/src/common/Logging/Appender.h index 6382399a0b4..f0bfe423a66 100644 --- a/src/common/Logging/Appender.h +++ b/src/common/Logging/Appender.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Logging/AppenderConsole.cpp b/src/common/Logging/AppenderConsole.cpp index 531df266aa1..d856c57074d 100644 --- a/src/common/Logging/AppenderConsole.cpp +++ b/src/common/Logging/AppenderConsole.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Logging/AppenderConsole.h b/src/common/Logging/AppenderConsole.h index 6b30505c6bd..5d7eae36b40 100644 --- a/src/common/Logging/AppenderConsole.h +++ b/src/common/Logging/AppenderConsole.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Logging/AppenderFile.cpp b/src/common/Logging/AppenderFile.cpp index c90c8f6ccea..20fa3dc720b 100644 --- a/src/common/Logging/AppenderFile.cpp +++ b/src/common/Logging/AppenderFile.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Logging/AppenderFile.h b/src/common/Logging/AppenderFile.h index c2781eb1ee9..9ba5d59259c 100644 --- a/src/common/Logging/AppenderFile.h +++ b/src/common/Logging/AppenderFile.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Logging/Log.cpp b/src/common/Logging/Log.cpp index 57d399a9d96..4bd0487343d 100644 --- a/src/common/Logging/Log.cpp +++ b/src/common/Logging/Log.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2008 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Logging/Log.h b/src/common/Logging/Log.h index a15bb4ad485..a90481ad5d2 100644 --- a/src/common/Logging/Log.h +++ b/src/common/Logging/Log.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Logging/LogOperation.cpp b/src/common/Logging/LogOperation.cpp index bcd923c705e..83288716efd 100644 --- a/src/common/Logging/LogOperation.cpp +++ b/src/common/Logging/LogOperation.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Logging/LogOperation.h b/src/common/Logging/LogOperation.h index ffdd35c3c09..618629b5423 100644 --- a/src/common/Logging/LogOperation.h +++ b/src/common/Logging/LogOperation.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Logging/Logger.cpp b/src/common/Logging/Logger.cpp index 3b02eb47575..75dfdcc4183 100644 --- a/src/common/Logging/Logger.cpp +++ b/src/common/Logging/Logger.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Logging/Logger.h b/src/common/Logging/Logger.h index 1aee75c5d72..67eab4295a4 100644 --- a/src/common/Logging/Logger.h +++ b/src/common/Logging/Logger.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Threading/Callback.h b/src/common/Threading/Callback.h index 1f4ffc97cfc..f7eab57ddda 100644 --- a/src/common/Threading/Callback.h +++ b/src/common/Threading/Callback.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Threading/LockedQueue.h b/src/common/Threading/LockedQueue.h index 3abb0f4b8bc..c6faaaf81ca 100644 --- a/src/common/Threading/LockedQueue.h +++ b/src/common/Threading/LockedQueue.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2008 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Threading/ProcessPriority.h b/src/common/Threading/ProcessPriority.h index 2a8501a0249..7119daa5030 100644 --- a/src/common/Threading/ProcessPriority.h +++ b/src/common/Threading/ProcessPriority.h @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Threading/ProducerConsumerQueue.h b/src/common/Threading/ProducerConsumerQueue.h index 96546960393..bd4c8efd32c 100644 --- a/src/common/Threading/ProducerConsumerQueue.h +++ b/src/common/Threading/ProducerConsumerQueue.h @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Utilities/ByteConverter.h b/src/common/Utilities/ByteConverter.h index a077de3eb0b..3325a34f58b 100644 --- a/src/common/Utilities/ByteConverter.h +++ b/src/common/Utilities/ByteConverter.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Containers.h b/src/common/Utilities/Containers.h index 0e5752ccd68..f3e9432ca4c 100644 --- a/src/server/shared/Containers.h +++ b/src/common/Utilities/Containers.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -19,10 +19,11 @@ #define TRINITY_CONTAINERS_H #include "Define.h" +#include "Random.h" +#include <algorithm> +#include <functional> #include <list> - -//! Because circular includes are bad -extern uint32 urand(uint32 min, uint32 max); +#include <vector> namespace Trinity { @@ -57,14 +58,64 @@ namespace Trinity list = listCopy; } - /* Select a random element from a container. Note: make sure you explicitly empty check the container */ - template <class C> typename C::value_type const& SelectRandomContainerElement(C const& container) + /* + * Select a random element from a container. + * + * Note: container cannot be empty + */ + template <class C> + typename C::value_type const& SelectRandomContainerElement(C const& container) { typename C::const_iterator it = container.begin(); std::advance(it, urand(0, container.size() - 1)); return *it; } + /* + * Select a random element from a container where each element has a different chance to be selected. + * + * @param container Container to select an element from + * @param weights Chances of each element to be selected, must be in the same order as elements in container. + * Caller is responsible for checking that sum of all weights is greater than 0. + * + * Note: container cannot be empty + */ + template <class C> + typename C::const_iterator SelectRandomWeightedContainerElement(C const& container, std::vector<double> weights) + { + Trinity::discrete_distribution_param<uint32> ddParam(weights.begin(), weights.end()); + std::discrete_distribution<uint32> dd(ddParam); + typename C::const_iterator it = container.begin(); + std::advance(it, dd(SFMTEngine::Instance())); + return it; + } + + /* + * Select a random element from a container where each element has a different chance to be selected. + * + * @param container Container to select an element from + * @param weightExtractor Function retrieving chance of each element in container, expected to take an element of the container and returning a double + * + * Note: container cannot be empty + */ + template <class C, class Fn> + typename C::const_iterator SelectRandomWeightedContainerElement(C const& container, Fn weightExtractor) + { + std::vector<double> weights; + weights.reserve(container.size()); + double weightSum = 0.0; + for (auto itr = container.begin(); itr != container.end(); ++itr) + { + double weight = weightExtractor(*itr); + weights.push_back(weight); + weightSum += weight; + } + if (weightSum <= 0.0) + weights.assign(container.size(), 1.0); + + return SelectRandomWeightedContainerElement(container, weights); + } + /** * @fn bool Trinity::Containers::Intersects(Iterator first1, Iterator last1, Iterator first2, Iterator last2) * diff --git a/src/common/Utilities/Duration.h b/src/common/Utilities/Duration.h index 58a08e5842f..3de142ebcb2 100644 --- a/src/common/Utilities/Duration.h +++ b/src/common/Utilities/Duration.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Utilities/EventMap.cpp b/src/common/Utilities/EventMap.cpp index 8c3f60afe82..b87a3f8f001 100644 --- a/src/common/Utilities/EventMap.cpp +++ b/src/common/Utilities/EventMap.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Utilities/EventMap.h b/src/common/Utilities/EventMap.h index 021dffc4940..a1aaa9af269 100644 --- a/src/common/Utilities/EventMap.h +++ b/src/common/Utilities/EventMap.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Utilities/EventProcessor.cpp b/src/common/Utilities/EventProcessor.cpp index 34695665443..be74d58b790 100644 --- a/src/common/Utilities/EventProcessor.cpp +++ b/src/common/Utilities/EventProcessor.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Utilities/EventProcessor.h b/src/common/Utilities/EventProcessor.h index 3d54bd6f9f2..e5eafed79b9 100644 --- a/src/common/Utilities/EventProcessor.h +++ b/src/common/Utilities/EventProcessor.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Utilities/Random.cpp b/src/common/Utilities/Random.cpp new file mode 100644 index 00000000000..cc013110b01 --- /dev/null +++ b/src/common/Utilities/Random.cpp @@ -0,0 +1,83 @@ +/* + * Copyright (C) 2008-2015 TrinityCore <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, see <http://www.gnu.org/licenses/>. + */ + +#include "Random.h" +#include "Common.h" +#include "Errors.h" +#include "SFMT.h" +#include <boost/thread/tss.hpp> + +static boost::thread_specific_ptr<SFMTRand> sfmtRand; + +static SFMTRand* GetRng() +{ + SFMTRand* rand = sfmtRand.get(); + + if (!rand) + { + rand = new SFMTRand(); + sfmtRand.reset(rand); + } + + return rand; +} + +int32 irand(int32 min, int32 max) +{ + ASSERT(max >= min); + return int32(GetRng()->IRandom(min, max)); +} + +uint32 urand(uint32 min, uint32 max) +{ + ASSERT(max >= min); + return GetRng()->URandom(min, max); +} + +uint32 urandms(uint32 min, uint32 max) +{ + ASSERT(max >= min); + ASSERT(INT_MAX / IN_MILLISECONDS >= max); + return GetRng()->URandom(min * IN_MILLISECONDS, max * IN_MILLISECONDS); +} + +float frand(float min, float max) +{ + ASSERT(max >= min); + return float(GetRng()->Random() * (max - min) + min); +} + +uint32 rand32() +{ + return GetRng()->BRandom(); +} + +double rand_norm() +{ + return GetRng()->Random(); +} + +double rand_chance() +{ + return GetRng()->Random() * 100.0; +} + +SFMTEngine& SFMTEngine::Instance() +{ + static SFMTEngine engine; + return engine; +} diff --git a/src/common/Utilities/Random.h b/src/common/Utilities/Random.h new file mode 100644 index 00000000000..5610651a83b --- /dev/null +++ b/src/common/Utilities/Random.h @@ -0,0 +1,95 @@ +/* + * Copyright (C) 2008-2015 TrinityCore <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, see <http://www.gnu.org/licenses/>. + */ + +#ifndef Random_h__ +#define Random_h__ + +#include "Define.h" +#include <limits> +#include <random> + +/* Return a random number in the range min..max. */ +int32 irand(int32 min, int32 max); + +/* Return a random number in the range min..max (inclusive). */ +uint32 urand(uint32 min, uint32 max); + +/* Return a random millisecond value between min and max seconds. Functionally equivalent to urand(min*IN_MILLISECONDS, max*IN_MILLISECONDS). */ +uint32 urandms(uint32 min, uint32 max); + +/* Return a random number in the range 0 .. UINT32_MAX. */ +uint32 rand32(); + +/* Return a random number in the range min..max */ +float frand(float min, float max); + +/* Return a random double from 0.0 to 1.0 (exclusive). */ +double rand_norm(); + +/* Return a random double from 0.0 to 100.0 (exclusive). */ +double rand_chance(); + +/* Return true if a random roll fits in the specified chance (range 0-100). */ +inline bool roll_chance_f(float chance) +{ + return chance > rand_chance(); +} + +/* Return true if a random roll fits in the specified chance (range 0-100). */ +inline bool roll_chance_i(int chance) +{ + return chance > irand(0, 99); +} + +/* +* SFMT wrapper satisfying UniformRandomNumberGenerator concept for use in <random> algorithms +*/ +class SFMTEngine +{ +public: + typedef uint32 result_type; + + static TRINITY_CONSTEXPR result_type min() { return std::numeric_limits<result_type>::min(); } + static TRINITY_CONSTEXPR result_type max() { return std::numeric_limits<result_type>::max(); } + result_type operator()() const { return rand32(); } + + static SFMTEngine& Instance(); +}; + +// Ugly, horrible, i don't even..., hack for VS2013 to work around missing discrete_distribution(iterator, iterator) constructor +namespace Trinity +{ +#if COMPILER == COMPILER_MICROSOFT && _MSC_VER <= 1800 + template<typename T> + struct discrete_distribution_param : public std::discrete_distribution<T>::param_type + { + typedef typename std::discrete_distribution<T>::param_type base; + + template<typename InIt> + discrete_distribution_param(InIt begin, InIt end) : base(_Noinit()) + { + this->_Pvec.assign(begin, end); + this->_Init(); + } + }; +#else + template<typename T> + using discrete_distribution_param = typename std::discrete_distribution<T>::param_type; +#endif +} + +#endif // Random_h__ diff --git a/src/common/Utilities/StringFormat.h b/src/common/Utilities/StringFormat.h index 67e0100e7c8..d85523bc11f 100644 --- a/src/common/Utilities/StringFormat.h +++ b/src/common/Utilities/StringFormat.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Utilities/TaskScheduler.cpp b/src/common/Utilities/TaskScheduler.cpp index 801cc96cf77..1a7d65ae969 100644 --- a/src/common/Utilities/TaskScheduler.cpp +++ b/src/common/Utilities/TaskScheduler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Utilities/TaskScheduler.h b/src/common/Utilities/TaskScheduler.h index f1fe7ea0a21..8cf5d914128 100644 --- a/src/common/Utilities/TaskScheduler.h +++ b/src/common/Utilities/TaskScheduler.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/common/Utilities/Timer.h b/src/common/Utilities/Timer.h index c54903d7be2..cdce08caaf0 100644 --- a/src/common/Utilities/Timer.h +++ b/src/common/Utilities/Timer.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/common/Utilities/Util.cpp b/src/common/Utilities/Util.cpp index 9f61dd12e4c..1360253294f 100644 --- a/src/common/Utilities/Util.cpp +++ b/src/common/Utilities/Util.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -20,10 +20,8 @@ #include "Common.h" #include "CompilerDefs.h" #include "utf8.h" -#include "SFMT.h" #include "Errors.h" // for ASSERT #include <stdarg.h> -#include <boost/thread/tss.hpp> #if COMPILER == COMPILER_GNU #include <sys/socket.h> @@ -31,61 +29,6 @@ #include <arpa/inet.h> #endif -static boost::thread_specific_ptr<SFMTRand> sfmtRand; - -static SFMTRand* GetRng() -{ - SFMTRand* rand = sfmtRand.get(); - - if (!rand) - { - rand = new SFMTRand(); - sfmtRand.reset(rand); - } - - return rand; -} - -int32 irand(int32 min, int32 max) -{ - ASSERT(max >= min); - return int32(GetRng()->IRandom(min, max)); -} - -uint32 urand(uint32 min, uint32 max) -{ - ASSERT(max >= min); - return GetRng()->URandom(min, max); -} - -uint32 urandms(uint32 min, uint32 max) -{ - ASSERT(max >= min); - ASSERT(INT_MAX/IN_MILLISECONDS >= max); - return GetRng()->URandom(min * IN_MILLISECONDS, max * IN_MILLISECONDS); -} - -float frand(float min, float max) -{ - ASSERT(max >= min); - return float(GetRng()->Random() * (max - min) + min); -} - -uint32 rand32() -{ - return GetRng()->BRandom(); -} - -double rand_norm() -{ - return GetRng()->Random(); -} - -double rand_chance() -{ - return GetRng()->Random() * 100.0; -} - Tokenizer::Tokenizer(const std::string &src, const char sep, uint32 vectorReserve) { m_str = new char[src.length() + 1]; diff --git a/src/common/Utilities/Util.h b/src/common/Utilities/Util.h index b748e83408b..ab5cabca8d2 100644 --- a/src/common/Utilities/Util.h +++ b/src/common/Utilities/Util.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -21,12 +21,14 @@ #include "Define.h" #include "Errors.h" +#include "Random.h" #include <algorithm> #include <string> #include <vector> #include <list> #include <map> +#include <ctime> // Searcher for map of structs template<typename T, class S> struct Finder @@ -76,39 +78,6 @@ std::string secsToTimeString(uint64 timeInSecs, bool shortText = false, bool hou uint32 TimeStringToSecs(const std::string& timestring); std::string TimeToTimestampStr(time_t t); -/* Return a random number in the range min..max. */ -int32 irand(int32 min, int32 max); - -/* Return a random number in the range min..max (inclusive). */ -uint32 urand(uint32 min, uint32 max); - -/* Return a random millisecond value between min and max seconds. Functionally equivalent to urand(min*IN_MILLISECONDS, max*IN_MILLISECONDS). */ -uint32 urandms(uint32 min, uint32 max); - -/* Return a random number in the range 0 .. UINT32_MAX. */ -uint32 rand32(); - -/* Return a random number in the range min..max */ -float frand(float min, float max); - -/* Return a random double from 0.0 to 1.0 (exclusive). */ -double rand_norm(); - -/* Return a random double from 0.0 to 100.0 (exclusive). */ -double rand_chance(); - -/* Return true if a random roll fits in the specified chance (range 0-100). */ -inline bool roll_chance_f(float chance) -{ - return chance > rand_chance(); -} - -/* Return true if a random roll fits in the specified chance (range 0-100). */ -inline bool roll_chance_i(int chance) -{ - return chance > irand(0, 99); -} - inline void ApplyPercentModFloatVar(float& var, float val, bool apply) { if (val == -100.0f) // prevent set var to zero diff --git a/src/genrev/CMakeLists.txt b/src/genrev/CMakeLists.txt index 05db165fe00..91a13609037 100644 --- a/src/genrev/CMakeLists.txt +++ b/src/genrev/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/CMakeLists.txt b/src/server/CMakeLists.txt index e89a33c4376..9a454696ca8 100644 --- a/src/server/CMakeLists.txt +++ b/src/server/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/authserver/Authentication/AuthCodes.cpp b/src/server/authserver/Authentication/AuthCodes.cpp index 08f091d1a36..30ceaa49458 100644 --- a/src/server/authserver/Authentication/AuthCodes.cpp +++ b/src/server/authserver/Authentication/AuthCodes.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/authserver/Authentication/AuthCodes.h b/src/server/authserver/Authentication/AuthCodes.h index 7a5df6d1561..cd3dbe0e1ed 100644 --- a/src/server/authserver/Authentication/AuthCodes.h +++ b/src/server/authserver/Authentication/AuthCodes.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/authserver/Authentication/TOTP.cpp b/src/server/authserver/Authentication/TOTP.cpp index 6f9135c53ad..a7f70970695 100644 --- a/src/server/authserver/Authentication/TOTP.cpp +++ b/src/server/authserver/Authentication/TOTP.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/authserver/Authentication/TOTP.h b/src/server/authserver/Authentication/TOTP.h index 7548dff99bb..92b850014ff 100644 --- a/src/server/authserver/Authentication/TOTP.h +++ b/src/server/authserver/Authentication/TOTP.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/authserver/CMakeLists.txt b/src/server/authserver/CMakeLists.txt index a8e35a8d9ef..c11deec39bb 100644 --- a/src/server/authserver/CMakeLists.txt +++ b/src/server/authserver/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/authserver/Main.cpp b/src/server/authserver/Main.cpp index 205053c47ee..0618ec437b6 100644 --- a/src/server/authserver/Main.cpp +++ b/src/server/authserver/Main.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -68,11 +68,14 @@ bool StartDB(); void StopDB(); void SignalHandler(const boost::system::error_code& error, int signalNumber); void KeepDatabaseAliveHandler(const boost::system::error_code& error); +void BanExpiryHandler(boost::system::error_code const& error); variables_map GetConsoleArguments(int argc, char** argv, std::string& configFile, std::string& configService); boost::asio::io_service* _ioService; boost::asio::deadline_timer* _dbPingTimer; uint32 _dbPingInterval; +boost::asio::deadline_timer* _banExpiryCheckTimer; +uint32 _banExpiryCheckInterval; LoginDatabaseWorkerPool LoginDatabase; int main(int argc, char** argv) @@ -169,6 +172,11 @@ int main(int argc, char** argv) _dbPingTimer->expires_from_now(boost::posix_time::minutes(_dbPingInterval)); _dbPingTimer->async_wait(KeepDatabaseAliveHandler); + _banExpiryCheckInterval = sConfigMgr->GetIntDefault("BanExpiryCheckInterval", 60); + _banExpiryCheckTimer = new boost::asio::deadline_timer(*_ioService); + _banExpiryCheckTimer->expires_from_now(boost::posix_time::seconds(_banExpiryCheckInterval)); + _banExpiryCheckTimer->async_wait(BanExpiryHandler); + #if PLATFORM == PLATFORM_WINDOWS if (m_ServiceStatus != -1) { @@ -181,6 +189,7 @@ int main(int argc, char** argv) // Start the io service worker loop _ioService->run(); + _banExpiryCheckTimer->cancel(); _dbPingTimer->cancel(); sAuthSocketMgr.StopNetwork(); @@ -192,6 +201,7 @@ int main(int argc, char** argv) signals.cancel(); + delete _banExpiryCheckTimer; delete _dbPingTimer; delete _ioService; return 0; @@ -242,6 +252,18 @@ void KeepDatabaseAliveHandler(const boost::system::error_code& error) } } +void BanExpiryHandler(boost::system::error_code const& error) +{ + if (!error) + { + LoginDatabase.Execute(LoginDatabase.GetPreparedStatement(LOGIN_DEL_EXPIRED_IP_BANS)); + LoginDatabase.Execute(LoginDatabase.GetPreparedStatement(LOGIN_UPD_EXPIRED_ACCOUNT_BANS)); + + _banExpiryCheckTimer->expires_from_now(boost::posix_time::seconds(_banExpiryCheckInterval)); + _banExpiryCheckTimer->async_wait(BanExpiryHandler); + } +} + #if PLATFORM == PLATFORM_WINDOWS void ServiceStatusWatcher(boost::system::error_code const& error) { diff --git a/src/server/authserver/Realms/RealmList.cpp b/src/server/authserver/Realms/RealmList.cpp index f5461d5f42e..53aeff6133b 100644 --- a/src/server/authserver/Realms/RealmList.cpp +++ b/src/server/authserver/Realms/RealmList.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/authserver/Realms/RealmList.h b/src/server/authserver/Realms/RealmList.h index 355b92d5725..cc5c88c01f2 100644 --- a/src/server/authserver/Realms/RealmList.h +++ b/src/server/authserver/Realms/RealmList.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/authserver/Server/AuthSession.cpp b/src/server/authserver/Server/AuthSession.cpp index 8b0d86603a6..519cd1f19f7 100644 --- a/src/server/authserver/Server/AuthSession.cpp +++ b/src/server/authserver/Server/AuthSession.cpp @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -43,12 +43,6 @@ enum eAuthCmd XFER_CANCEL = 0x34 }; -enum eStatus -{ - STATUS_CONNECTED = 0, - STATUS_AUTHED -}; - #pragma pack(push, 1) typedef struct AUTH_LOGON_CHALLENGE_C @@ -115,11 +109,10 @@ enum class BufferSizes : uint32 SRP_6_S = 0x20, }; +#define MAX_ACCEPTED_CHALLENGE_SIZE (sizeof(AUTH_LOGON_CHALLENGE_C) + 16) + #define AUTH_LOGON_CHALLENGE_INITIAL_SIZE 4 #define REALM_LIST_PACKET_SIZE 5 -#define XFER_ACCEPT_SIZE 1 -#define XFER_RESUME_SIZE 9 -#define XFER_CANCEL_SIZE 1 std::unordered_map<uint8, AuthHandler> AuthSession::InitHandlers() { @@ -130,15 +123,98 @@ std::unordered_map<uint8, AuthHandler> AuthSession::InitHandlers() handlers[AUTH_RECONNECT_CHALLENGE] = { STATUS_CONNECTED, AUTH_LOGON_CHALLENGE_INITIAL_SIZE, &AuthSession::HandleReconnectChallenge }; handlers[AUTH_RECONNECT_PROOF] = { STATUS_CONNECTED, sizeof(AUTH_RECONNECT_PROOF_C), &AuthSession::HandleReconnectProof }; handlers[REALM_LIST] = { STATUS_AUTHED, REALM_LIST_PACKET_SIZE, &AuthSession::HandleRealmList }; - handlers[XFER_ACCEPT] = { STATUS_AUTHED, XFER_ACCEPT_SIZE, &AuthSession::HandleXferAccept }; - handlers[XFER_RESUME] = { STATUS_AUTHED, XFER_RESUME_SIZE, &AuthSession::HandleXferResume }; - handlers[XFER_CANCEL] = { STATUS_AUTHED, XFER_CANCEL_SIZE, &AuthSession::HandleXferCancel }; return handlers; } std::unordered_map<uint8, AuthHandler> const Handlers = AuthSession::InitHandlers(); +void AccountInfo::LoadResult(Field* fields) +{ + // 0 1 2 3 4 5 6 + //SELECT a.id, a.username, a.locked, a.lock_country, a.last_ip, a.failed_logins, ab.unbandate > UNIX_TIMESTAMP() OR ab.unbandate = ab.bandate, + // 7 8 9 10 11 12 + // ab.unbandate = ab.bandate, aa.gmlevel, a.token_key, a.sha_pass_hash, a.v, a.s + //FROM account a LEFT JOIN account_access aa ON a.id = aa.id LEFT JOIN account_banned ab ON ab.id = a.id AND ab.active = 1 WHERE a.username = ? + + Id = fields[0].GetUInt32(); + Login = fields[1].GetString(); + IsLockedToIP = fields[2].GetBool(); + LockCountry = fields[3].GetString(); + LastIP = fields[4].GetString(); + FailedLogins = fields[5].GetUInt32(); + IsBanned = fields[6].GetUInt64() != 0; + IsPermanenetlyBanned = fields[7].GetUInt64() != 0; + SecurityLevel = AccountTypes(fields[8].GetUInt8()); +} + +AuthSession::AuthSession(tcp::socket&& socket) : Socket(std::move(socket)), +_sentChallenge(false), _sentProof(false), +_status(STATUS_CONNECTED), _build(0), _expversion(0) +{ + N.SetHexStr("894B645E89E1535BBDAD5B8B290650530801B18EBFBF5E8FAB3C82872A3E9BB7"); + g.SetDword(7); +} + +void AuthSession::Start() +{ + std::string ip_address = GetRemoteIpAddress().to_string(); + TC_LOG_TRACE("session", "Accepted connection from %s", ip_address.c_str()); + + PreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_IP_INFO); + stmt->setString(0, ip_address); + stmt->setUInt32(1, inet_addr(ip_address.c_str())); + + _queryCallback = std::bind(&AuthSession::CheckIpCallback, this, std::placeholders::_1); + _queryFuture = LoginDatabase.AsyncQuery(stmt); +} + +bool AuthSession::Update() +{ + if (!AuthSocket::Update()) + return false; + + if (_queryFuture.valid() && _queryFuture.wait_for(std::chrono::seconds(0)) == std::future_status::ready) + { + auto callback = _queryCallback; + _queryCallback = nullptr; + callback(_queryFuture.get()); + } + + return true; +} + +void AuthSession::CheckIpCallback(PreparedQueryResult result) +{ + if (result) + { + bool banned = false; + do + { + Field* fields = result->Fetch(); + if (fields[0].GetUInt64() != 0) + banned = true; + + if (!fields[1].GetString().empty()) + _ipCountry = fields[1].GetString(); + + } while (result->NextRow()); + + if (banned) + { + ByteBuffer pkt; + pkt << uint8(AUTH_LOGON_CHALLENGE); + pkt << uint8(0x00); + pkt << uint8(WOW_FAIL_BANNED); + SendPacket(pkt); + TC_LOG_DEBUG("session", "[AuthSession::CheckIpCallback] Banned ip '%s:%d' tries to login!", GetRemoteIpAddress().to_string().c_str(), GetRemotePort()); + return; + } + } + + AsyncRead(); +} + void AuthSession::ReadHandler() { MessageBuffer& packet = GetReadBuffer(); @@ -153,6 +229,12 @@ void AuthSession::ReadHandler() break; } + if (_status != itr->second.status) + { + CloseSocket(); + return; + } + uint16 size = uint16(itr->second.packetSize); if (packet.GetActiveSize() < size) break; @@ -161,12 +243,17 @@ void AuthSession::ReadHandler() { sAuthLogonChallenge_C* challenge = reinterpret_cast<sAuthLogonChallenge_C*>(packet.GetReadPointer()); size += challenge->size; + if (size > MAX_ACCEPTED_CHALLENGE_SIZE) + { + CloseSocket(); + return; + } } if (packet.GetActiveSize() < size) break; - if (!(*this.*Handlers.at(cmd).handler)()) + if (!(*this.*itr->second.handler)()) { CloseSocket(); return; @@ -196,224 +283,203 @@ void AuthSession::SendPacket(ByteBuffer& packet) bool AuthSession::HandleLogonChallenge() { + if (_sentChallenge) + return false; + + _sentChallenge = true; + sAuthLogonChallenge_C* challenge = reinterpret_cast<sAuthLogonChallenge_C*>(GetReadBuffer().GetReadPointer()); + if (challenge->size - (sizeof(sAuthLogonChallenge_C) - AUTH_LOGON_CHALLENGE_INITIAL_SIZE - 1) != challenge->I_len) + return false; - //TC_LOG_DEBUG("server.authserver", "[AuthChallenge] got full packet, %#04x bytes", challenge->size); - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] name(%d): '%s'", challenge->I_len, challenge->I); + std::string login((const char*)challenge->I, challenge->I_len); + TC_LOG_DEBUG("server.authserver", "[AuthChallenge] '%s'", login.c_str()); - ByteBuffer pkt; + if (_queryCallback) + { + ByteBuffer pkt; + pkt << uint8(AUTH_LOGON_CHALLENGE); + pkt << uint8(0x00); + pkt << uint8(WOW_FAIL_DB_BUSY); + SendPacket(pkt); + + TC_LOG_DEBUG("server.authserver", "[AuthChallenge] %s attempted to log too quick after previous attempt!", login.c_str()); + return true; + } - _login.assign((const char*)challenge->I, challenge->I_len); _build = challenge->build; _expversion = uint8(AuthHelper::IsPostBCAcceptedClientBuild(_build) ? POST_BC_EXP_FLAG : (AuthHelper::IsPreBCAcceptedClientBuild(_build) ? PRE_BC_EXP_FLAG : NO_VALID_EXP_FLAG)); - _os = (const char*)challenge->os; - - if (_os.size() > 4) - return false; + std::array<char, 5> os; + os.fill('\0'); + memcpy(os.data(), challenge->os, sizeof(challenge->os)); + _os = os.data(); // Restore string order as its byte order is reversed std::reverse(_os.begin(), _os.end()); + _localizationName.resize(4); + for (int i = 0; i < 4; ++i) + _localizationName[i] = challenge->country[4 - i - 1]; + + // Get the account details from the account table + PreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_LOGONCHALLENGE); + stmt->setString(0, login); + + _queryCallback = std::bind(&AuthSession::LogonChallengeCallback, this, std::placeholders::_1); + _queryFuture = LoginDatabase.AsyncQuery(stmt); + return true; +} + +void AuthSession::LogonChallengeCallback(PreparedQueryResult result) +{ + ByteBuffer pkt; pkt << uint8(AUTH_LOGON_CHALLENGE); pkt << uint8(0x00); - // Verify that this IP is not in the ip_banned table - LoginDatabase.Execute(LoginDatabase.GetPreparedStatement(LOGIN_DEL_EXPIRED_IP_BANS)); + if (!result) + { + pkt << uint8(WOW_FAIL_UNKNOWN_ACCOUNT); + SendPacket(pkt); + return; + } + + Field* fields = result->Fetch(); + + _accountInfo.LoadResult(fields); std::string ipAddress = GetRemoteIpAddress().to_string(); uint16 port = GetRemotePort(); - PreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_IP_BANNED); - stmt->setString(0, ipAddress); - PreparedQueryResult result = LoginDatabase.Query(stmt); - if (result) + // If the IP is 'locked', check that the player comes indeed from the correct IP address + if (_accountInfo.IsLockedToIP) { - pkt << uint8(WOW_FAIL_BANNED); - TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] Banned ip tries to login!", ipAddress.c_str(), port); + TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account '%s' is locked to IP - '%s' is logging in from '%s'", _accountInfo.Login.c_str(), _accountInfo.LastIP.c_str(), ipAddress.c_str()); + if (_accountInfo.LastIP != ipAddress) + { + pkt << uint8(WOW_FAIL_LOCKED_ENFORCED); + SendPacket(pkt); + return; + } } else { - // Get the account details from the account table - // No SQL injection (prepared statement) - stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_LOGONCHALLENGE); - stmt->setString(0, _login); - - PreparedQueryResult res2 = LoginDatabase.Query(stmt); - if (res2) + TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account '%s' is not locked to ip", _accountInfo.Login.c_str()); + if (_accountInfo.LockCountry.empty() || _accountInfo.LockCountry == "00") + TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account '%s' is not locked to country", _accountInfo.Login.c_str()); + else if (!_accountInfo.LockCountry.empty() && !_ipCountry.empty()) { - Field* fields = res2->Fetch(); - - // If the IP is 'locked', check that the player comes indeed from the correct IP address - bool locked = false; - if (fields[2].GetUInt8() == 1) // if ip is locked - { - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account '%s' is locked to IP - '%s'", _login.c_str(), fields[4].GetCString()); - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Player address is '%s'", ipAddress.c_str()); - - if (strcmp(fields[4].GetCString(), ipAddress.c_str()) != 0) - { - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account IP differs"); - pkt << uint8(WOW_FAIL_LOCKED_ENFORCED); - locked = true; - } - else - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account IP matches"); - } - else + TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account '%s' is locked to country: '%s' Player country is '%s'", _accountInfo.Login.c_str(), _accountInfo.LockCountry.c_str(), _ipCountry.c_str()); + if (_ipCountry != _accountInfo.LockCountry) { - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account '%s' is not locked to ip", _login.c_str()); - std::string accountCountry = fields[3].GetString(); - if (accountCountry.empty() || accountCountry == "00") - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account '%s' is not locked to country", _login.c_str()); - else if (!accountCountry.empty()) - { - uint32 ip = inet_addr(ipAddress.c_str()); - EndianConvertReverse(ip); - - stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_LOGON_COUNTRY); - stmt->setUInt32(0, ip); - if (PreparedQueryResult sessionCountryQuery = LoginDatabase.Query(stmt)) - { - std::string loginCountry = (*sessionCountryQuery)[0].GetString(); - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account '%s' is locked to country: '%s' Player country is '%s'", _login.c_str(), - accountCountry.c_str(), loginCountry.c_str()); - - if (loginCountry != accountCountry) - { - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account country differs."); - pkt << uint8(WOW_FAIL_UNLOCKABLE_LOCK); - locked = true; - } - else - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] Account country matches"); - } - else - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] IP2NATION Table empty"); - } + pkt << uint8(WOW_FAIL_UNLOCKABLE_LOCK); + SendPacket(pkt); + return; } + } + } - if (!locked) - { - //set expired bans to inactive - LoginDatabase.DirectExecute(LoginDatabase.GetPreparedStatement(LOGIN_UPD_EXPIRED_ACCOUNT_BANS)); - - // If the account is banned, reject the logon attempt - stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_ACCOUNT_BANNED); - stmt->setUInt32(0, fields[1].GetUInt32()); - PreparedQueryResult banresult = LoginDatabase.Query(stmt); - if (banresult) - { - if ((*banresult)[0].GetUInt32() == (*banresult)[1].GetUInt32()) - { - pkt << uint8(WOW_FAIL_BANNED); - TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] Banned account %s tried to login!", ipAddress.c_str(), - port, _login.c_str()); - } - else - { - pkt << uint8(WOW_FAIL_SUSPENDED); - TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] Temporarily banned account %s tried to login!", - ipAddress.c_str(), port, _login.c_str()); - } - } - else - { - // Get the password from the account table, upper it, and make the SRP6 calculation - std::string rI = fields[0].GetString(); - - // Don't calculate (v, s) if there are already some in the database - std::string databaseV = fields[6].GetString(); - std::string databaseS = fields[7].GetString(); - - TC_LOG_DEBUG("network", "database authentication values: v='%s' s='%s'", databaseV.c_str(), databaseS.c_str()); - - // multiply with 2 since bytes are stored as hexstring - if (databaseV.size() != size_t(BufferSizes::SRP_6_V) * 2 || databaseS.size() != size_t(BufferSizes::SRP_6_S) * 2) - SetVSFields(rI); - else - { - s.SetHexStr(databaseS.c_str()); - v.SetHexStr(databaseV.c_str()); - } - - b.SetRand(19 * 8); - BigNumber gmod = g.ModExp(b, N); - B = ((v * 3) + gmod) % N; - - ASSERT(gmod.GetNumBytes() <= 32); - - BigNumber unk3; - unk3.SetRand(16 * 8); - - // Fill the response packet with the result - if (AuthHelper::IsAcceptedClientBuild(_build)) - pkt << uint8(WOW_SUCCESS); - else - pkt << uint8(WOW_FAIL_VERSION_INVALID); - - // B may be calculated < 32B so we force minimal length to 32B - pkt.append(B.AsByteArray(32).get(), 32); // 32 bytes - pkt << uint8(1); - pkt.append(g.AsByteArray(1).get(), 1); - pkt << uint8(32); - pkt.append(N.AsByteArray(32).get(), 32); - pkt.append(s.AsByteArray(int32(BufferSizes::SRP_6_S)).get(), size_t(BufferSizes::SRP_6_S)); // 32 bytes - pkt.append(unk3.AsByteArray(16).get(), 16); - uint8 securityFlags = 0; - - // Check if token is used - _tokenKey = fields[8].GetString(); - if (!_tokenKey.empty()) - securityFlags = 4; - - pkt << uint8(securityFlags); // security flags (0x0...0x04) - - if (securityFlags & 0x01) // PIN input - { - pkt << uint32(0); - pkt << uint64(0) << uint64(0); // 16 bytes hash? - } - - if (securityFlags & 0x02) // Matrix input - { - pkt << uint8(0); - pkt << uint8(0); - pkt << uint8(0); - pkt << uint8(0); - pkt << uint64(0); - } - - if (securityFlags & 0x04) // Security token input - pkt << uint8(1); - - uint8 secLevel = fields[5].GetUInt8(); - _accountSecurityLevel = secLevel <= SEC_ADMINISTRATOR ? AccountTypes(secLevel) : SEC_ADMINISTRATOR; - - _localizationName.resize(4); - for (int i = 0; i < 4; ++i) - _localizationName[i] = challenge->country[4 - i - 1]; - - TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] account %s is using '%c%c%c%c' locale (%u)", - ipAddress.c_str(), port, _login.c_str(), - challenge->country[3], challenge->country[2], challenge->country[1], challenge->country[0], - GetLocaleByName(_localizationName) - ); - } - } + // If the account is banned, reject the logon attempt + if (_accountInfo.IsBanned) + { + if (_accountInfo.IsPermanenetlyBanned) + { + pkt << uint8(WOW_FAIL_BANNED); + SendPacket(pkt); + TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] Banned account %s tried to login!", ipAddress.c_str(), port, _accountInfo.Login.c_str()); + return; + } + else + { + pkt << uint8(WOW_FAIL_SUSPENDED); + SendPacket(pkt); + TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] Temporarily banned account %s tried to login!", ipAddress.c_str(), port, _accountInfo.Login.c_str()); + return; } - else //no account - pkt << uint8(WOW_FAIL_UNKNOWN_ACCOUNT); } + // Get the password from the account table, upper it, and make the SRP6 calculation + std::string rI = fields[10].GetString(); + + // Don't calculate (v, s) if there are already some in the database + std::string databaseV = fields[11].GetString(); + std::string databaseS = fields[12].GetString(); + + TC_LOG_DEBUG("network", "database authentication values: v='%s' s='%s'", databaseV.c_str(), databaseS.c_str()); + + // multiply with 2 since bytes are stored as hexstring + if (databaseV.size() != size_t(BufferSizes::SRP_6_V) * 2 || databaseS.size() != size_t(BufferSizes::SRP_6_S) * 2) + SetVSFields(rI); + else + { + s.SetHexStr(databaseS.c_str()); + v.SetHexStr(databaseV.c_str()); + } + + b.SetRand(19 * 8); + BigNumber gmod = g.ModExp(b, N); + B = ((v * 3) + gmod) % N; + + ASSERT(gmod.GetNumBytes() <= 32); + + BigNumber unk3; + unk3.SetRand(16 * 8); + + // Fill the response packet with the result + if (AuthHelper::IsAcceptedClientBuild(_build)) + pkt << uint8(WOW_SUCCESS); + else + pkt << uint8(WOW_FAIL_VERSION_INVALID); + + // B may be calculated < 32B so we force minimal length to 32B + pkt.append(B.AsByteArray(32).get(), 32); // 32 bytes + pkt << uint8(1); + pkt.append(g.AsByteArray(1).get(), 1); + pkt << uint8(32); + pkt.append(N.AsByteArray(32).get(), 32); + pkt.append(s.AsByteArray(int32(BufferSizes::SRP_6_S)).get(), size_t(BufferSizes::SRP_6_S)); // 32 bytes + pkt.append(unk3.AsByteArray(16).get(), 16); + uint8 securityFlags = 0; + + // Check if token is used + _tokenKey = fields[9].GetString(); + if (!_tokenKey.empty()) + securityFlags = 4; + + pkt << uint8(securityFlags); // security flags (0x0...0x04) + + if (securityFlags & 0x01) // PIN input + { + pkt << uint32(0); + pkt << uint64(0) << uint64(0); // 16 bytes hash? + } + + if (securityFlags & 0x02) // Matrix input + { + pkt << uint8(0); + pkt << uint8(0); + pkt << uint8(0); + pkt << uint8(0); + pkt << uint64(0); + } + + if (securityFlags & 0x04) // Security token input + pkt << uint8(1); + + TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] account %s is using '%s' locale (%u)", + ipAddress.c_str(), port, _accountInfo.Login.c_str(), _localizationName.c_str(), GetLocaleByName(_localizationName)); + SendPacket(pkt); - return true; } // Logon Proof command handler bool AuthSession::HandleLogonProof() { - TC_LOG_DEBUG("server.authserver", "Entering _HandleLogonProof"); + if (_sentProof) + return false; + + _sentProof = true; + // Read the packet sAuthLogonProof_C *logonProof = reinterpret_cast<sAuthLogonProof_C*>(GetReadBuffer().GetReadPointer()); @@ -487,7 +553,7 @@ bool AuthSession::HandleLogonProof() t3.SetBinary(hash, 20); sha.Initialize(); - sha.UpdateData(_login); + sha.UpdateData(_accountInfo.Login); sha.Finalize(); uint8 t4[SHA_DIGEST_LENGTH]; memcpy(t4, sha.GetDigest(), SHA_DIGEST_LENGTH); @@ -503,7 +569,7 @@ bool AuthSession::HandleLogonProof() // Check if SRP6 results match (password is correct), else send an error if (!memcmp(M.AsByteArray(sha.GetLength()).get(), logonProof->M1, 20)) { - TC_LOG_DEBUG("server.authserver", "'%s:%d' User '%s' successfully authenticated", GetRemoteIpAddress().to_string().c_str(), GetRemotePort(), _login.c_str()); + TC_LOG_DEBUG("server.authserver", "'%s:%d' User '%s' successfully authenticated", GetRemoteIpAddress().to_string().c_str(), GetRemotePort(), _accountInfo.Login.c_str()); // Update the sessionkey, last_ip, last login time and reset number of failed logins in the account table for this account // No SQL injection (escaped user name) and IP address as received by socket @@ -514,7 +580,7 @@ bool AuthSession::HandleLogonProof() stmt->setString(1, GetRemoteIpAddress().to_string().c_str()); stmt->setUInt32(2, GetLocaleByName(_localizationName)); stmt->setString(3, _os); - stmt->setString(4, _login); + stmt->setString(4, _accountInfo.Login); LoginDatabase.DirectExecute(stmt); OPENSSL_free((void*)K_hex); @@ -531,6 +597,7 @@ bool AuthSession::HandleLogonProof() std::string token(reinterpret_cast<char*>(GetReadBuffer().GetReadPointer() + sizeof(sAuthLogonProof_C) + sizeof(size)), size); GetReadBuffer().ReadCompleted(sizeof(size) + size); uint32 validToken = TOTP::GenerateToken(_tokenKey.c_str()); + _tokenKey.clear(); uint32 incomingToken = atoi(token.c_str()); if (validToken != incomingToken) { @@ -540,7 +607,7 @@ bool AuthSession::HandleLogonProof() packet << uint8(3); packet << uint8(0); SendPacket(packet); - return false; + return true; } } @@ -571,7 +638,7 @@ bool AuthSession::HandleLogonProof() } SendPacket(packet); - _isAuthenticated = true; + _status = STATUS_AUTHED; } else { @@ -583,7 +650,7 @@ bool AuthSession::HandleLogonProof() SendPacket(packet); TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] account %s tried to login with invalid password!", - GetRemoteIpAddress().to_string().c_str(), GetRemotePort(), _login.c_str()); + GetRemoteIpAddress().to_string().c_str(), GetRemotePort(), _accountInfo.Login.c_str()); uint32 MaxWrongPassCount = sConfigMgr->GetIntDefault("WrongPass.MaxCount", 0); @@ -591,7 +658,7 @@ bool AuthSession::HandleLogonProof() if (sConfigMgr->GetBoolDefault("WrongPass.Logging", false)) { PreparedStatement* logstmt = LoginDatabase.GetPreparedStatement(LOGIN_INS_FALP_IP_LOGGING); - logstmt->setString(0, _login); + logstmt->setString(0, _accountInfo.Login); logstmt->setString(1, GetRemoteIpAddress().to_string()); logstmt->setString(2, "Logged on failed AccountLogin due wrong password"); @@ -602,42 +669,33 @@ bool AuthSession::HandleLogonProof() { //Increment number of failed logins by one and if it reaches the limit temporarily ban that account or IP PreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_UPD_FAILEDLOGINS); - stmt->setString(0, _login); + stmt->setString(0, _accountInfo.Login); LoginDatabase.Execute(stmt); - stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_FAILEDLOGINS); - stmt->setString(0, _login); - - if (PreparedQueryResult loginfail = LoginDatabase.Query(stmt)) + if (_accountInfo.FailedLogins >= MaxWrongPassCount) { - uint32 failed_logins = (*loginfail)[1].GetUInt32(); + uint32 WrongPassBanTime = sConfigMgr->GetIntDefault("WrongPass.BanTime", 600); + bool WrongPassBanType = sConfigMgr->GetBoolDefault("WrongPass.BanType", false); - if (failed_logins >= MaxWrongPassCount) + if (WrongPassBanType) + { + stmt = LoginDatabase.GetPreparedStatement(LOGIN_INS_ACCOUNT_AUTO_BANNED); + stmt->setUInt32(0, _accountInfo.Id); + stmt->setUInt32(1, WrongPassBanTime); + LoginDatabase.Execute(stmt); + + TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] account %s got banned for '%u' seconds because it failed to authenticate '%u' times", + GetRemoteIpAddress().to_string().c_str(), GetRemotePort(), _accountInfo.Login.c_str(), WrongPassBanTime, _accountInfo.FailedLogins); + } + else { - uint32 WrongPassBanTime = sConfigMgr->GetIntDefault("WrongPass.BanTime", 600); - bool WrongPassBanType = sConfigMgr->GetBoolDefault("WrongPass.BanType", false); - - if (WrongPassBanType) - { - uint32 acc_id = (*loginfail)[0].GetUInt32(); - stmt = LoginDatabase.GetPreparedStatement(LOGIN_INS_ACCOUNT_AUTO_BANNED); - stmt->setUInt32(0, acc_id); - stmt->setUInt32(1, WrongPassBanTime); - LoginDatabase.Execute(stmt); - - TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] account %s got banned for '%u' seconds because it failed to authenticate '%u' times", - GetRemoteIpAddress().to_string().c_str(), GetRemotePort(), _login.c_str(), WrongPassBanTime, failed_logins); - } - else - { - stmt = LoginDatabase.GetPreparedStatement(LOGIN_INS_IP_AUTO_BANNED); - stmt->setString(0, GetRemoteIpAddress().to_string()); - stmt->setUInt32(1, WrongPassBanTime); - LoginDatabase.Execute(stmt); - - TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] IP got banned for '%u' seconds because account %s failed to authenticate '%u' times", - GetRemoteIpAddress().to_string().c_str(), GetRemotePort(), WrongPassBanTime, _login.c_str(), failed_logins); - } + stmt = LoginDatabase.GetPreparedStatement(LOGIN_INS_IP_AUTO_BANNED); + stmt->setString(0, GetRemoteIpAddress().to_string()); + stmt->setUInt32(1, WrongPassBanTime); + LoginDatabase.Execute(stmt); + + TC_LOG_DEBUG("server.authserver", "'%s:%d' [AuthChallenge] IP got banned for '%u' seconds because account %s failed to authenticate '%u' times", + GetRemoteIpAddress().to_string().c_str(), GetRemotePort(), WrongPassBanTime, _accountInfo.Login.c_str(), _accountInfo.FailedLogins); } } } @@ -648,61 +706,88 @@ bool AuthSession::HandleLogonProof() bool AuthSession::HandleReconnectChallenge() { - TC_LOG_DEBUG("server.authserver", "Entering _HandleReconnectChallenge"); - sAuthLogonChallenge_C* challenge = reinterpret_cast<sAuthLogonChallenge_C*>(GetReadBuffer().GetReadPointer()); + if (_sentChallenge) + return false; - //TC_LOG_DEBUG("server.authserver", "[AuthChallenge] got full packet, %#04x bytes", challenge->size); - TC_LOG_DEBUG("server.authserver", "[AuthChallenge] name(%d): '%s'", challenge->I_len, challenge->I); + _sentChallenge = true; - _login.assign((const char*)challenge->I, challenge->I_len); + sAuthLogonChallenge_C* challenge = reinterpret_cast<sAuthLogonChallenge_C*>(GetReadBuffer().GetReadPointer()); + if (challenge->size - (sizeof(sAuthLogonChallenge_C) - AUTH_LOGON_CHALLENGE_INITIAL_SIZE - 1) != challenge->I_len) + return false; - PreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_SESSIONKEY); - stmt->setString(0, _login); - PreparedQueryResult result = LoginDatabase.Query(stmt); + std::string login((const char*)challenge->I, challenge->I_len); + TC_LOG_DEBUG("server.authserver", "[ReconnectChallenge] '%s'", login.c_str()); - // Stop if the account is not found - if (!result) + if (_queryCallback) { - TC_LOG_ERROR("server.authserver", "'%s:%d' [ERROR] user %s tried to login and we cannot find his session key in the database.", - GetRemoteIpAddress().to_string().c_str(), GetRemotePort(), _login.c_str()); - return false; + ByteBuffer pkt; + pkt << uint8(AUTH_RECONNECT_CHALLENGE); + pkt << uint8(WOW_FAIL_DB_BUSY); + SendPacket(pkt); + + TC_LOG_DEBUG("server.authserver", "[ReconnectChallenge] %s attempted to log too quick after previous attempt!", login.c_str()); + return true; } - // Reinitialize build, expansion and the account securitylevel _build = challenge->build; _expversion = uint8(AuthHelper::IsPostBCAcceptedClientBuild(_build) ? POST_BC_EXP_FLAG : (AuthHelper::IsPreBCAcceptedClientBuild(_build) ? PRE_BC_EXP_FLAG : NO_VALID_EXP_FLAG)); - _os = (const char*)challenge->os; - - if (_os.size() > 4) - return false; + std::array<char, 5> os; + os.fill('\0'); + memcpy(os.data(), challenge->os, sizeof(challenge->os)); + _os = os.data(); // Restore string order as its byte order is reversed std::reverse(_os.begin(), _os.end()); - Field* fields = result->Fetch(); - uint8 secLevel = fields[2].GetUInt8(); - _accountSecurityLevel = secLevel <= SEC_ADMINISTRATOR ? AccountTypes(secLevel) : SEC_ADMINISTRATOR; + _localizationName.resize(4); + for (int i = 0; i < 4; ++i) + _localizationName[i] = challenge->country[4 - i - 1]; - K.SetHexStr((*result)[0].GetCString()); + // Get the account details from the account table + PreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_RECONNECTCHALLENGE); + stmt->setString(0, login); + + _queryCallback = std::bind(&AuthSession::ReconnectChallengeCallback, this, std::placeholders::_1); + _queryFuture = LoginDatabase.AsyncQuery(stmt); + return true; +} - // Sending response +void AuthSession::ReconnectChallengeCallback(PreparedQueryResult result) +{ ByteBuffer pkt; pkt << uint8(AUTH_RECONNECT_CHALLENGE); - pkt << uint8(0x00); + + if (!result) + { + pkt << uint8(WOW_FAIL_UNKNOWN_ACCOUNT); + SendPacket(pkt); + return; + } + + Field* fields = result->Fetch(); + + _accountInfo.LoadResult(fields); + K.SetHexStr(fields[9].GetCString()); _reconnectProof.SetRand(16 * 8); - pkt.append(_reconnectProof.AsByteArray(16).get(), 16); // 16 bytes random + + pkt << uint8(WOW_SUCCESS); + pkt.append(_reconnectProof.AsByteArray(16).get(), 16); // 16 bytes random pkt << uint64(0x00) << uint64(0x00); // 16 bytes zeros SendPacket(pkt); - - return true; } + bool AuthSession::HandleReconnectProof() { TC_LOG_DEBUG("server.authserver", "Entering _HandleReconnectProof"); + if (_sentProof) + return false; + + _sentProof = true; + sAuthReconnectProof_C *reconnectProof = reinterpret_cast<sAuthReconnectProof_C*>(GetReadBuffer().GetReadPointer()); - if (_login.empty() || !_reconnectProof.GetNumBytes() || !K.GetNumBytes()) + if (_accountInfo.Login.empty() || !_reconnectProof.GetNumBytes() || !K.GetNumBytes()) return false; BigNumber t1; @@ -710,7 +795,7 @@ bool AuthSession::HandleReconnectProof() SHA1Hash sha; sha.Initialize(); - sha.UpdateData(_login); + sha.UpdateData(_accountInfo.Login); sha.UpdateBigNumbers(&t1, &_reconnectProof, &K, NULL); sha.Finalize(); @@ -722,13 +807,13 @@ bool AuthSession::HandleReconnectProof() pkt << uint8(0x00); pkt << uint16(0x00); // 2 bytes zeros SendPacket(pkt); - _isAuthenticated = true; + _status = STATUS_AUTHED; return true; } else { TC_LOG_ERROR("server.authserver", "'%s:%d' [ERROR] user %s tried to login, but session is invalid.", GetRemoteIpAddress().to_string().c_str(), - GetRemotePort(), _login.c_str()); + GetRemotePort(), _accountInfo.Login.c_str()); return false; } } @@ -772,20 +857,31 @@ bool AuthSession::HandleRealmList() { TC_LOG_DEBUG("server.authserver", "Entering _HandleRealmList"); - // Get the user id (else close the connection) - // No SQL injection (prepared statement) - PreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_ACCOUNT_ID_BY_NAME); - stmt->setString(0, _login); - PreparedQueryResult result = LoginDatabase.Query(stmt); - if (!result) + if (_queryCallback) { - TC_LOG_ERROR("server.authserver", "'%s:%d' [ERROR] user %s tried to login but we cannot find him in the database.", GetRemoteIpAddress().to_string().c_str(), - GetRemotePort(), _login.c_str()); + TC_LOG_DEBUG("server.authserver", "[RealmList] %s attempted to get realmlist too quick after previous attempt!", _accountInfo.Login.c_str()); return false; } - Field* fields = result->Fetch(); - uint32 id = fields[0].GetUInt32(); + PreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_REALM_CHARACTER_COUNTS); + stmt->setUInt32(0, _accountInfo.Id); + + _queryCallback = std::bind(&AuthSession::RealmListCallback, this, std::placeholders::_1); + _queryFuture = LoginDatabase.AsyncQuery(stmt); + return true; +} + +void AuthSession::RealmListCallback(PreparedQueryResult result) +{ + std::map<uint32, uint8> characterCounts; + if (result) + { + do + { + Field* fields = result->Fetch(); + characterCounts[fields[0].GetUInt32()] = fields[1].GetUInt8(); + } while (result->NextRow()); + } // Update realm list if need sRealmList->UpdateIfNeed(); @@ -822,25 +918,17 @@ bool AuthSession::HandleRealmList() name = ss.str(); } - uint8 lock = (realm.allowedSecurityLevel > _accountSecurityLevel) ? 1 : 0; - - uint8 AmountOfCharacters = 0; - stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_NUM_CHARS_ON_REALM); - stmt->setUInt32(0, realm.m_ID); - stmt->setUInt32(1, id); - result = LoginDatabase.Query(stmt); - if (result) - AmountOfCharacters = (*result)[0].GetUInt8(); + uint8 lock = (realm.allowedSecurityLevel > _accountInfo.SecurityLevel) ? 1 : 0; - pkt << realm.icon; // realm type + pkt << uint8(realm.icon); // realm type if (_expversion & POST_BC_EXP_FLAG) // only 2.x and 3.x clients - pkt << lock; // if 1, then realm locked + pkt << uint8(lock); // if 1, then realm locked pkt << uint8(flag); // RealmFlags pkt << name; pkt << boost::lexical_cast<std::string>(GetAddressForClient(realm, GetRemoteIpAddress())); - pkt << realm.populationLevel; - pkt << AmountOfCharacters; - pkt << realm.timezone; // realm category + pkt << float(realm.populationLevel); + pkt << uint8(characterCounts[realm.m_ID]); + pkt << uint8(realm.timezone); // realm category if (_expversion & POST_BC_EXP_FLAG) // 2.x and 3.x clients pkt << uint8(realm.m_ID); else @@ -882,32 +970,6 @@ bool AuthSession::HandleRealmList() hdr.append(RealmListSizeBuffer); // append RealmList's size buffer hdr.append(pkt); // append realms in the realmlist SendPacket(hdr); - return true; -} - -// Resume patch transfer -bool AuthSession::HandleXferResume() -{ - TC_LOG_DEBUG("server.authserver", "Entering _HandleXferResume"); - //uint8 - //uint64 - return true; -} - -// Cancel patch transfer -bool AuthSession::HandleXferCancel() -{ - TC_LOG_DEBUG("server.authserver", "Entering _HandleXferCancel"); - //uint8 - return false; -} - -// Accept patch transfer -bool AuthSession::HandleXferAccept() -{ - TC_LOG_DEBUG("server.authserver", "Entering _HandleXferAccept"); - //uint8 - return true; } // Make the SRP6 calculation from hash in dB @@ -940,7 +1002,7 @@ void AuthSession::SetVSFields(const std::string& rI) PreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_UPD_VS); stmt->setString(0, v_hex); stmt->setString(1, s_hex); - stmt->setString(2, _login); + stmt->setString(2, _accountInfo.Login); LoginDatabase.Execute(stmt); OPENSSL_free(v_hex); diff --git a/src/server/authserver/Server/AuthSession.h b/src/server/authserver/Server/AuthSession.h index 1151df7c2cb..1babb7407a9 100644 --- a/src/server/authserver/Server/AuthSession.h +++ b/src/server/authserver/Server/AuthSession.h @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -23,29 +23,48 @@ #include "ByteBuffer.h" #include "Socket.h" #include "BigNumber.h" +#include "Callback.h" #include <memory> #include <boost/asio/ip/tcp.hpp> using boost::asio::ip::tcp; +class Field; struct AuthHandler; +enum AuthStatus +{ + STATUS_CONNECTED = 0, + STATUS_AUTHED +}; + +struct AccountInfo +{ + void LoadResult(Field* fields); + + uint32 Id = 0; + std::string Login; + bool IsLockedToIP = false; + std::string LockCountry; + std::string LastIP; + uint32 FailedLogins = 0; + bool IsBanned = false; + bool IsPermanenetlyBanned = false; + AccountTypes SecurityLevel = SEC_PLAYER; + std::string TokenKey; +}; + class AuthSession : public Socket<AuthSession> { + typedef Socket<AuthSession> AuthSocket; + public: static std::unordered_map<uint8, AuthHandler> InitHandlers(); - AuthSession(tcp::socket&& socket) : Socket(std::move(socket)), - _isAuthenticated(false), _build(0), _expversion(0), _accountSecurityLevel(SEC_PLAYER) - { - N.SetHexStr("894B645E89E1535BBDAD5B8B290650530801B18EBFBF5E8FAB3C82872A3E9BB7"); - g.SetDword(7); - } + AuthSession(tcp::socket&& socket); - void Start() override - { - AsyncRead(); - } + void Start() override; + bool Update() override; void SendPacket(ByteBuffer& packet); @@ -59,10 +78,10 @@ private: bool HandleReconnectProof(); bool HandleRealmList(); - //data transfer handle for patch - bool HandleXferResume(); - bool HandleXferCancel(); - bool HandleXferAccept(); + void CheckIpCallback(PreparedQueryResult result); + void LogonChallengeCallback(PreparedQueryResult result); + void ReconnectChallengeCallback(PreparedQueryResult result); + void RealmListCallback(PreparedQueryResult result); void SetVSFields(const std::string& rI); @@ -71,22 +90,27 @@ private: BigNumber K; BigNumber _reconnectProof; - bool _isAuthenticated; + bool _sentChallenge; + bool _sentProof; + + AuthStatus _status; + AccountInfo _accountInfo; std::string _tokenKey; - std::string _login; std::string _localizationName; std::string _os; + std::string _ipCountry; uint16 _build; uint8 _expversion; - AccountTypes _accountSecurityLevel; + PreparedQueryResultFuture _queryFuture; + std::function<void(PreparedQueryResult)> _queryCallback; }; #pragma pack(push, 1) struct AuthHandler { - uint32 status; + AuthStatus status; size_t packetSize; bool (AuthSession::*handler)(); }; diff --git a/src/server/authserver/Server/AuthSocketMgr.h b/src/server/authserver/Server/AuthSocketMgr.h index 1c93bedf1ef..fa96502663f 100644 --- a/src/server/authserver/Server/AuthSocketMgr.h +++ b/src/server/authserver/Server/AuthSocketMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/authserver/authserver.conf.dist b/src/server/authserver/authserver.conf.dist index 604988d62e5..82c3cd47148 100644 --- a/src/server/authserver/authserver.conf.dist +++ b/src/server/authserver/authserver.conf.dist @@ -131,6 +131,13 @@ WrongPass.BanType = 0 WrongPass.Logging = 0 # +# BanExpiryCheckInterval +# Description: Time (in seconds) between checks for expired bans +# Default: 60 + +BanExpiryCheckInterval = 60 + +# ################################################################################################### ################################################################################################### diff --git a/src/server/authserver/authserver.rc b/src/server/authserver/authserver.rc index ca8fc9f031f..b8504d9228a 100644 --- a/src/server/authserver/authserver.rc +++ b/src/server/authserver/authserver.rc @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/database/CMakeLists.txt b/src/server/database/CMakeLists.txt index 19fa0ee0acf..5a53899f4cb 100644 --- a/src/server/database/CMakeLists.txt +++ b/src/server/database/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/database/Database/AdhocStatement.cpp b/src/server/database/Database/AdhocStatement.cpp index 547ff967efe..0d34b4dcfb3 100644 --- a/src/server/database/Database/AdhocStatement.cpp +++ b/src/server/database/Database/AdhocStatement.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/AdhocStatement.h b/src/server/database/Database/AdhocStatement.h index c449e0f6e59..ab85493a14e 100644 --- a/src/server/database/Database/AdhocStatement.h +++ b/src/server/database/Database/AdhocStatement.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/DatabaseEnv.h b/src/server/database/Database/DatabaseEnv.h index c3e11c5b98e..cc8355a1302 100644 --- a/src/server/database/Database/DatabaseEnv.h +++ b/src/server/database/Database/DatabaseEnv.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/database/Database/DatabaseLoader.cpp b/src/server/database/Database/DatabaseLoader.cpp index 39719e4c6a1..92d8730cd12 100644 --- a/src/server/database/Database/DatabaseLoader.cpp +++ b/src/server/database/Database/DatabaseLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/DatabaseLoader.h b/src/server/database/Database/DatabaseLoader.h index d35597ba807..da92cf85a9f 100644 --- a/src/server/database/Database/DatabaseLoader.h +++ b/src/server/database/Database/DatabaseLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/DatabaseWorker.cpp b/src/server/database/Database/DatabaseWorker.cpp index 56757ce12a0..cebd6d79a19 100644 --- a/src/server/database/Database/DatabaseWorker.cpp +++ b/src/server/database/Database/DatabaseWorker.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/DatabaseWorker.h b/src/server/database/Database/DatabaseWorker.h index 0ca476b1e66..c21a3d2a343 100644 --- a/src/server/database/Database/DatabaseWorker.h +++ b/src/server/database/Database/DatabaseWorker.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/DatabaseWorkerPool.h b/src/server/database/Database/DatabaseWorkerPool.h index c7b5d8c8fea..d5a254647eb 100644 --- a/src/server/database/Database/DatabaseWorkerPool.h +++ b/src/server/database/Database/DatabaseWorkerPool.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/Field.cpp b/src/server/database/Database/Field.cpp index f7794bd8975..20a42871b91 100644 --- a/src/server/database/Database/Field.cpp +++ b/src/server/database/Database/Field.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/Field.h b/src/server/database/Database/Field.h index 72364f2c034..ec9e626ee1b 100644 --- a/src/server/database/Database/Field.h +++ b/src/server/database/Database/Field.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/Implementation/CharacterDatabase.cpp b/src/server/database/Database/Implementation/CharacterDatabase.cpp index 45bfee5d596..ab68aca2a8c 100644 --- a/src/server/database/Database/Implementation/CharacterDatabase.cpp +++ b/src/server/database/Database/Implementation/CharacterDatabase.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -72,7 +72,7 @@ void CharacterDatabaseConnection::DoPrepareStatements() "FROM characters WHERE guid = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_SEL_GROUP_MEMBER, "SELECT guid FROM group_member WHERE memberGuid = ?", CONNECTION_BOTH); - PrepareStatement(CHAR_SEL_CHARACTER_INSTANCE, "SELECT id, permanent, map, difficulty, resettime FROM character_instance LEFT JOIN instance ON instance = id WHERE guid = ?", CONNECTION_ASYNC); + PrepareStatement(CHAR_SEL_CHARACTER_INSTANCE, "SELECT id, permanent, map, difficulty, extendState, resettime FROM character_instance LEFT JOIN instance ON instance = id WHERE guid = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_SEL_CHARACTER_AURAS, "SELECT casterGuid, spell, effectMask, recalculateMask, stackCount, amount0, amount1, amount2, " "base_amount0, base_amount1, base_amount2, maxDuration, remainTime, remainCharges FROM character_aura WHERE guid = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_SEL_CHARACTER_SPELL, "SELECT spell, active, disabled FROM character_spell WHERE guid = ?", CONNECTION_ASYNC); @@ -405,8 +405,8 @@ void CharacterDatabaseConnection::DoPrepareStatements() PrepareStatement(CHAR_UPD_WORLDSTATE, "UPDATE worldstates SET value = ? WHERE entry = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_INS_WORLDSTATE, "INSERT INTO worldstates (entry, value) VALUES (?, ?)", CONNECTION_ASYNC); PrepareStatement(CHAR_DEL_CHAR_INSTANCE_BY_INSTANCE_GUID, "DELETE FROM character_instance WHERE guid = ? AND instance = ?", CONNECTION_ASYNC); - PrepareStatement(CHAR_UPD_CHAR_INSTANCE, "UPDATE character_instance SET instance = ?, permanent = ? WHERE guid = ? AND instance = ?", CONNECTION_ASYNC); - PrepareStatement(CHAR_INS_CHAR_INSTANCE, "INSERT INTO character_instance (guid, instance, permanent) VALUES (?, ?, ?)", CONNECTION_ASYNC); + PrepareStatement(CHAR_UPD_CHAR_INSTANCE, "UPDATE character_instance SET instance = ?, permanent = ?, extendState = ? WHERE guid = ? AND instance = ?", CONNECTION_ASYNC); + PrepareStatement(CHAR_INS_CHAR_INSTANCE, "INSERT INTO character_instance (guid, instance, permanent, extendState) VALUES (?, ?, ?, ?)", CONNECTION_ASYNC); PrepareStatement(CHAR_UPD_GENDER_PLAYERBYTES, "UPDATE characters SET gender = ?, playerBytes = ?, playerBytes2 = ? WHERE guid = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_DEL_CHARACTER_SKILL, "DELETE FROM character_skills WHERE guid = ? AND skill = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_UPD_ADD_CHARACTER_SOCIAL_FLAGS, "UPDATE character_social SET flags = flags | ? WHERE guid = ? AND friend = ?", CONNECTION_ASYNC); @@ -434,6 +434,7 @@ void CharacterDatabaseConnection::DoPrepareStatements() PrepareStatement(CHAR_SEL_CHAR_CLASS_LVL_AT_LOGIN, "SELECT class, level, at_login, knownTitles FROM characters WHERE guid = ?", CONNECTION_SYNCH); PrepareStatement(CHAR_SEL_CHAR_AT_LOGIN_TITLES, "SELECT at_login, knownTitles FROM characters WHERE guid = ?", CONNECTION_SYNCH); PrepareStatement(CHAR_SEL_INSTANCE, "SELECT data, completedEncounters FROM instance WHERE map = ? AND id = ?", CONNECTION_SYNCH); + PrepareStatement(CHAR_SEL_PERM_BIND_BY_INSTANCE, "SELECT guid FROM character_instance WHERE instance = ? and permanent = 1", CONNECTION_SYNCH); PrepareStatement(CHAR_SEL_CHAR_COD_ITEM_MAIL, "SELECT id, messageType, mailTemplateId, sender, subject, body, money, has_items FROM mail WHERE receiver = ? AND has_items <> 0 AND cod <> 0", CONNECTION_SYNCH); PrepareStatement(CHAR_SEL_CHAR_SOCIAL, "SELECT DISTINCT guid FROM character_social WHERE friend = ?", CONNECTION_SYNCH); PrepareStatement(CHAR_SEL_CHAR_OLD_CHARS, "SELECT guid, deleteInfos_Account FROM characters WHERE deleteDate IS NOT NULL AND deleteDate < ?", CONNECTION_SYNCH); @@ -470,9 +471,10 @@ void CharacterDatabaseConnection::DoPrepareStatements() PrepareStatement(CHAR_INS_CHAR_GIFT, "INSERT INTO character_gifts (guid, item_guid, entry, flags) VALUES (?, ?, ?, ?)", CONNECTION_ASYNC); PrepareStatement(CHAR_DEL_INSTANCE_BY_INSTANCE, "DELETE FROM instance WHERE id = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_DEL_CHAR_INSTANCE_BY_INSTANCE, "DELETE FROM character_instance WHERE instance = ?", CONNECTION_ASYNC); - PrepareStatement(CHAR_DEL_CHAR_INSTANCE_BY_MAP_DIFF, "DELETE FROM character_instance USING character_instance LEFT JOIN instance ON character_instance.instance = id WHERE map = ? and difficulty = ?", CONNECTION_ASYNC); + PrepareStatement(CHAR_DEL_EXPIRED_CHAR_INSTANCE_BY_MAP_DIFF, "DELETE FROM character_instance USING character_instance LEFT JOIN instance ON character_instance.instance = id WHERE (extendState = 0 or permanent = 0) and map = ? and difficulty = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_DEL_GROUP_INSTANCE_BY_MAP_DIFF, "DELETE FROM group_instance USING group_instance LEFT JOIN instance ON group_instance.instance = id WHERE map = ? and difficulty = ?", CONNECTION_ASYNC); - PrepareStatement(CHAR_DEL_INSTANCE_BY_MAP_DIFF, "DELETE FROM instance WHERE map = ? and difficulty = ?", CONNECTION_ASYNC); + PrepareStatement(CHAR_DEL_EXPIRED_INSTANCE_BY_MAP_DIFF, "DELETE FROM instance WHERE map = ? and difficulty = ? and (SELECT guid FROM character_instance WHERE extendState != 0 AND instance = id LIMIT 1) IS NULL", CONNECTION_ASYNC); + PrepareStatement(CHAR_UPD_EXPIRE_CHAR_INSTANCE_BY_MAP_DIFF, "UPDATE character_instance LEFT JOIN instance ON character_instance.instance = id SET extendState = extendState-1 WHERE map = ? and difficulty = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_DEL_MAIL_ITEM_BY_ID, "DELETE FROM mail_items WHERE mail_id = ?", CONNECTION_ASYNC); PrepareStatement(CHAR_INS_PETITION, "INSERT INTO petition (ownerguid, petitionguid, name, type) VALUES (?, ?, ?, ?)", CONNECTION_ASYNC); PrepareStatement(CHAR_DEL_PETITION_BY_GUID, "DELETE FROM petition WHERE petitionguid = ?", CONNECTION_ASYNC); diff --git a/src/server/database/Database/Implementation/CharacterDatabase.h b/src/server/database/Database/Implementation/CharacterDatabase.h index 7a463c73df2..19d4a609e77 100644 --- a/src/server/database/Database/Implementation/CharacterDatabase.h +++ b/src/server/database/Database/Implementation/CharacterDatabase.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -365,6 +365,7 @@ enum CharacterDatabaseStatements CHAR_SEL_CHAR_CLASS_LVL_AT_LOGIN, CHAR_SEL_CHAR_AT_LOGIN_TITLES, CHAR_SEL_INSTANCE, + CHAR_SEL_PERM_BIND_BY_INSTANCE, CHAR_SEL_CHAR_COD_ITEM_MAIL, CHAR_SEL_CHAR_SOCIAL, CHAR_SEL_CHAR_OLD_CHARS, @@ -396,9 +397,10 @@ enum CharacterDatabaseStatements CHAR_INS_CHAR_GIFT, CHAR_DEL_INSTANCE_BY_INSTANCE, CHAR_DEL_CHAR_INSTANCE_BY_INSTANCE, - CHAR_DEL_CHAR_INSTANCE_BY_MAP_DIFF, + CHAR_DEL_EXPIRED_CHAR_INSTANCE_BY_MAP_DIFF, CHAR_DEL_GROUP_INSTANCE_BY_MAP_DIFF, - CHAR_DEL_INSTANCE_BY_MAP_DIFF, + CHAR_DEL_EXPIRED_INSTANCE_BY_MAP_DIFF, + CHAR_UPD_EXPIRE_CHAR_INSTANCE_BY_MAP_DIFF, CHAR_DEL_MAIL_ITEM_BY_ID, CHAR_INS_PETITION, CHAR_DEL_PETITION_BY_GUID, diff --git a/src/server/database/Database/Implementation/LoginDatabase.cpp b/src/server/database/Database/Implementation/LoginDatabase.cpp index de003c2092b..2749c08594f 100644 --- a/src/server/database/Database/Implementation/LoginDatabase.cpp +++ b/src/server/database/Database/Implementation/LoginDatabase.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -24,33 +24,34 @@ void LoginDatabaseConnection::DoPrepareStatements() PrepareStatement(LOGIN_SEL_REALMLIST, "SELECT id, name, address, localAddress, localSubnetMask, port, icon, flag, timezone, allowedSecurityLevel, population, gamebuild FROM realmlist WHERE flag <> 3 ORDER BY name", CONNECTION_SYNCH); PrepareStatement(LOGIN_DEL_EXPIRED_IP_BANS, "DELETE FROM ip_banned WHERE unbandate<>bandate AND unbandate<=UNIX_TIMESTAMP()", CONNECTION_ASYNC); - PrepareStatement(LOGIN_UPD_EXPIRED_ACCOUNT_BANS, "UPDATE account_banned SET active = 0 WHERE active = 1 AND unbandate<>bandate AND unbandate<=UNIX_TIMESTAMP()", CONNECTION_SYNCH); + PrepareStatement(LOGIN_UPD_EXPIRED_ACCOUNT_BANS, "UPDATE account_banned SET active = 0 WHERE active = 1 AND unbandate<>bandate AND unbandate<=UNIX_TIMESTAMP()", CONNECTION_ASYNC); PrepareStatement(LOGIN_SEL_IP_INFO, "(SELECT unbandate > UNIX_TIMESTAMP() OR unbandate = bandate AS banned, NULL as country FROM ip_banned WHERE ip = ?) " "UNION " "(SELECT NULL AS banned, country FROM ip2nation WHERE INET_NTOA(ip) = ?)", CONNECTION_ASYNC); - PrepareStatement(LOGIN_SEL_IP_BANNED, "SELECT * FROM ip_banned WHERE ip = ?", CONNECTION_SYNCH); PrepareStatement(LOGIN_INS_IP_AUTO_BANNED, "INSERT INTO ip_banned (ip, bandate, unbandate, bannedby, banreason) VALUES (?, UNIX_TIMESTAMP(), UNIX_TIMESTAMP()+?, 'Trinity Auth', 'Failed login autoban')", CONNECTION_ASYNC); PrepareStatement(LOGIN_SEL_IP_BANNED_ALL, "SELECT ip, bandate, unbandate, bannedby, banreason FROM ip_banned WHERE (bandate = unbandate OR unbandate > UNIX_TIMESTAMP()) ORDER BY unbandate", CONNECTION_SYNCH); PrepareStatement(LOGIN_SEL_IP_BANNED_BY_IP, "SELECT ip, bandate, unbandate, bannedby, banreason FROM ip_banned WHERE (bandate = unbandate OR unbandate > UNIX_TIMESTAMP()) AND ip LIKE CONCAT('%%', ?, '%%') ORDER BY unbandate", CONNECTION_SYNCH); - PrepareStatement(LOGIN_SEL_ACCOUNT_BANNED, "SELECT bandate, unbandate FROM account_banned WHERE id = ? AND active = 1", CONNECTION_SYNCH); PrepareStatement(LOGIN_SEL_ACCOUNT_BANNED_ALL, "SELECT account.id, username FROM account, account_banned WHERE account.id = account_banned.id AND active = 1 GROUP BY account.id", CONNECTION_SYNCH); PrepareStatement(LOGIN_SEL_ACCOUNT_BANNED_BY_USERNAME, "SELECT account.id, username FROM account, account_banned WHERE account.id = account_banned.id AND active = 1 AND username LIKE CONCAT('%%', ?, '%%') GROUP BY account.id", CONNECTION_SYNCH); PrepareStatement(LOGIN_INS_ACCOUNT_AUTO_BANNED, "INSERT INTO account_banned VALUES (?, UNIX_TIMESTAMP(), UNIX_TIMESTAMP()+?, 'Trinity Auth', 'Failed login autoban', 1)", CONNECTION_ASYNC); PrepareStatement(LOGIN_DEL_ACCOUNT_BANNED, "DELETE FROM account_banned WHERE id = ?", CONNECTION_ASYNC); - PrepareStatement(LOGIN_SEL_SESSIONKEY, "SELECT a.sessionkey, a.id, aa.gmlevel FROM account a LEFT JOIN account_access aa ON (a.id = aa.id) WHERE username = ?", CONNECTION_SYNCH); PrepareStatement(LOGIN_UPD_VS, "UPDATE account SET v = ?, s = ? WHERE username = ?", CONNECTION_ASYNC); PrepareStatement(LOGIN_UPD_LOGONPROOF, "UPDATE account SET sessionkey = ?, last_ip = ?, last_login = NOW(), locale = ?, failed_logins = 0, os = ? WHERE username = ?", CONNECTION_SYNCH); - PrepareStatement(LOGIN_SEL_LOGONCHALLENGE, "SELECT a.sha_pass_hash, a.id, a.locked, a.lock_country, a.last_ip, aa.gmlevel, a.v, a.s, a.token_key FROM account a LEFT JOIN account_access aa ON (a.id = aa.id) WHERE a.username = ?", CONNECTION_SYNCH); + PrepareStatement(LOGIN_SEL_LOGONCHALLENGE, "SELECT a.id, UPPER(a.username), a.locked, a.lock_country, a.last_ip, a.failed_logins, ab.unbandate > UNIX_TIMESTAMP() OR ab.unbandate = ab.bandate, " + "ab.unbandate = ab.bandate, aa.gmlevel, a.token_key, a.sha_pass_hash, a.v, a.s " + "FROM account a LEFT JOIN account_access aa ON a.id = aa.id LEFT JOIN account_banned ab ON ab.id = a.id AND ab.active = 1 WHERE a.username = ?", CONNECTION_ASYNC); + PrepareStatement(LOGIN_SEL_RECONNECTCHALLENGE, "SELECT a.id, UPPER(a.username), a.locked, a.lock_country, a.last_ip, a.failed_logins, ab.unbandate > UNIX_TIMESTAMP() OR ab.unbandate = ab.bandate, " + "ab.unbandate = ab.bandate, aa.gmlevel, a.sessionKey " + "FROM account a LEFT JOIN account_access aa ON a.id = aa.id LEFT JOIN account_banned ab ON ab.id = a.id AND ab.active = 1 WHERE a.username = ?", CONNECTION_ASYNC); PrepareStatement(LOGIN_SEL_LOGON_COUNTRY, "SELECT country FROM ip2nation WHERE ip < ? ORDER BY ip DESC LIMIT 0,1", CONNECTION_SYNCH); PrepareStatement(LOGIN_UPD_FAILEDLOGINS, "UPDATE account SET failed_logins = failed_logins + 1 WHERE username = ?", CONNECTION_ASYNC); - PrepareStatement(LOGIN_SEL_FAILEDLOGINS, "SELECT id, failed_logins FROM account WHERE username = ?", CONNECTION_SYNCH); PrepareStatement(LOGIN_SEL_ACCOUNT_ID_BY_NAME, "SELECT id FROM account WHERE username = ?", CONNECTION_SYNCH); PrepareStatement(LOGIN_SEL_ACCOUNT_LIST_BY_NAME, "SELECT id, username FROM account WHERE username = ?", CONNECTION_SYNCH); PrepareStatement(LOGIN_SEL_ACCOUNT_INFO_BY_NAME, "SELECT a.id, a.sessionkey, a.last_ip, a.locked, a.lock_country, a.expansion, a.mutetime, a.locale, a.recruiter, a.os, aa.gmLevel, " "ab.unbandate > UNIX_TIMESTAMP() OR ab.unbandate = ab.bandate, r.id FROM account a LEFT JOIN account_access aa ON a.id = aa.id AND aa.RealmID IN (-1, ?) " "LEFT JOIN account_banned ab ON a.id = ab.id AND ab.active = 1 LEFT JOIN account r ON a.id = r.recruiter WHERE a.username = ? ORDER BY aa.RealmID DESC LIMIT 1", CONNECTION_ASYNC); PrepareStatement(LOGIN_SEL_ACCOUNT_LIST_BY_EMAIL, "SELECT id, username FROM account WHERE email = ?", CONNECTION_SYNCH); - PrepareStatement(LOGIN_SEL_NUM_CHARS_ON_REALM, "SELECT numchars FROM realmcharacters WHERE realmid = ? AND acctid= ?", CONNECTION_SYNCH); + PrepareStatement(LOGIN_SEL_REALM_CHARACTER_COUNTS, "SELECT realmid, numchars FROM realmcharacters WHERE acctid = ?", CONNECTION_ASYNC); PrepareStatement(LOGIN_SEL_ACCOUNT_BY_IP, "SELECT id, username FROM account WHERE last_ip = ?", CONNECTION_SYNCH); PrepareStatement(LOGIN_SEL_ACCOUNT_BY_ID, "SELECT 1 FROM account WHERE id = ?", CONNECTION_SYNCH); PrepareStatement(LOGIN_INS_IP_BANNED, "INSERT INTO ip_banned (ip, bandate, unbandate, bannedby, banreason) VALUES (?, UNIX_TIMESTAMP(), UNIX_TIMESTAMP()+?, ?, ?)", CONNECTION_ASYNC); diff --git a/src/server/database/Database/Implementation/LoginDatabase.h b/src/server/database/Database/Implementation/LoginDatabase.h index 3b30105e670..a3789fa2557 100644 --- a/src/server/database/Database/Implementation/LoginDatabase.h +++ b/src/server/database/Database/Implementation/LoginDatabase.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -33,25 +33,22 @@ enum LoginDatabaseStatements LOGIN_DEL_EXPIRED_IP_BANS, LOGIN_UPD_EXPIRED_ACCOUNT_BANS, LOGIN_SEL_IP_INFO, - LOGIN_SEL_IP_BANNED, LOGIN_INS_IP_AUTO_BANNED, - LOGIN_SEL_ACCOUNT_BANNED, LOGIN_SEL_ACCOUNT_BANNED_ALL, LOGIN_SEL_ACCOUNT_BANNED_BY_USERNAME, LOGIN_INS_ACCOUNT_AUTO_BANNED, LOGIN_DEL_ACCOUNT_BANNED, - LOGIN_SEL_SESSIONKEY, LOGIN_UPD_VS, LOGIN_UPD_LOGONPROOF, LOGIN_SEL_LOGONCHALLENGE, + LOGIN_SEL_RECONNECTCHALLENGE, LOGIN_SEL_LOGON_COUNTRY, LOGIN_UPD_FAILEDLOGINS, - LOGIN_SEL_FAILEDLOGINS, LOGIN_SEL_ACCOUNT_ID_BY_NAME, LOGIN_SEL_ACCOUNT_LIST_BY_NAME, LOGIN_SEL_ACCOUNT_INFO_BY_NAME, LOGIN_SEL_ACCOUNT_LIST_BY_EMAIL, - LOGIN_SEL_NUM_CHARS_ON_REALM, + LOGIN_SEL_REALM_CHARACTER_COUNTS, LOGIN_SEL_ACCOUNT_BY_IP, LOGIN_INS_IP_BANNED, LOGIN_DEL_IP_NOT_BANNED, diff --git a/src/server/database/Database/Implementation/WorldDatabase.cpp b/src/server/database/Database/Implementation/WorldDatabase.cpp index d9aad94293e..7a183d5bf78 100644 --- a/src/server/database/Database/Implementation/WorldDatabase.cpp +++ b/src/server/database/Database/Implementation/WorldDatabase.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/Implementation/WorldDatabase.h b/src/server/database/Database/Implementation/WorldDatabase.h index c5475835fbd..6ac4ce589e3 100644 --- a/src/server/database/Database/Implementation/WorldDatabase.h +++ b/src/server/database/Database/Implementation/WorldDatabase.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/MySQLConnection.cpp b/src/server/database/Database/MySQLConnection.cpp index 10f4a7baa18..41dd61d3c3a 100644 --- a/src/server/database/Database/MySQLConnection.cpp +++ b/src/server/database/Database/MySQLConnection.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/MySQLConnection.h b/src/server/database/Database/MySQLConnection.h index 78d8d2fb5dd..a981caa607e 100644 --- a/src/server/database/Database/MySQLConnection.h +++ b/src/server/database/Database/MySQLConnection.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/MySQLThreading.h b/src/server/database/Database/MySQLThreading.h index 441f30cb6ec..1cfa11d7e5b 100644 --- a/src/server/database/Database/MySQLThreading.h +++ b/src/server/database/Database/MySQLThreading.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/PreparedStatement.cpp b/src/server/database/Database/PreparedStatement.cpp index 1938005c712..848a923c75d 100644 --- a/src/server/database/Database/PreparedStatement.cpp +++ b/src/server/database/Database/PreparedStatement.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/PreparedStatement.h b/src/server/database/Database/PreparedStatement.h index 2b8ce8aac2d..7d6c98463d0 100644 --- a/src/server/database/Database/PreparedStatement.h +++ b/src/server/database/Database/PreparedStatement.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/QueryHolder.cpp b/src/server/database/Database/QueryHolder.cpp index 2fdb3825526..b59352c72b3 100644 --- a/src/server/database/Database/QueryHolder.cpp +++ b/src/server/database/Database/QueryHolder.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/QueryHolder.h b/src/server/database/Database/QueryHolder.h index b64da948a16..9a5a03fda42 100644 --- a/src/server/database/Database/QueryHolder.h +++ b/src/server/database/Database/QueryHolder.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/QueryResult.cpp b/src/server/database/Database/QueryResult.cpp index 983ffee24c4..f02457f67ca 100644 --- a/src/server/database/Database/QueryResult.cpp +++ b/src/server/database/Database/QueryResult.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/database/Database/QueryResult.h b/src/server/database/Database/QueryResult.h index 0447ecaae5a..d4d63b5ec85 100644 --- a/src/server/database/Database/QueryResult.h +++ b/src/server/database/Database/QueryResult.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/database/Database/SQLOperation.h b/src/server/database/Database/SQLOperation.h index c5667288ec0..f0500d1f232 100644 --- a/src/server/database/Database/SQLOperation.h +++ b/src/server/database/Database/SQLOperation.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/Transaction.cpp b/src/server/database/Database/Transaction.cpp index f657411f716..b4dcd212e0f 100644 --- a/src/server/database/Database/Transaction.cpp +++ b/src/server/database/Database/Transaction.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Database/Transaction.h b/src/server/database/Database/Transaction.h index 4fbbe1ed45b..5780c0363d9 100644 --- a/src/server/database/Database/Transaction.h +++ b/src/server/database/Database/Transaction.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Logging/AppenderDB.cpp b/src/server/database/Logging/AppenderDB.cpp index 9e6ab1a057c..5c0138e928b 100644 --- a/src/server/database/Logging/AppenderDB.cpp +++ b/src/server/database/Logging/AppenderDB.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Logging/AppenderDB.h b/src/server/database/Logging/AppenderDB.h index 50607fd8136..a6acc66b48c 100644 --- a/src/server/database/Logging/AppenderDB.h +++ b/src/server/database/Logging/AppenderDB.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Updater/DBUpdater.cpp b/src/server/database/Updater/DBUpdater.cpp index d90d71c5594..170954a86f4 100644 --- a/src/server/database/Updater/DBUpdater.cpp +++ b/src/server/database/Updater/DBUpdater.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -311,7 +311,7 @@ bool DBUpdater<T>::Populate(DatabaseWorkerPool<T>& pool) } case LOCATION_DOWNLOAD: { - TC_LOG_ERROR("sql.updates", ">> File \"%s\" is missing, download it from \"http://www.trinitycore.org/f/files/category/1-database/\"" \ + TC_LOG_ERROR("sql.updates", ">> File \"%s\" is missing, download it from \"https://github.com/TrinityCore/TrinityCore/releases\"" \ " and place it in your server directory.", base.filename().generic_string().c_str()); break; } diff --git a/src/server/database/Updater/DBUpdater.h b/src/server/database/Updater/DBUpdater.h index c8aa5d69fbc..c9792ffe060 100644 --- a/src/server/database/Updater/DBUpdater.h +++ b/src/server/database/Updater/DBUpdater.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Updater/UpdateFetcher.cpp b/src/server/database/Updater/UpdateFetcher.cpp index ec023928b99..fd0dbdd4b5a 100644 --- a/src/server/database/Updater/UpdateFetcher.cpp +++ b/src/server/database/Updater/UpdateFetcher.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/database/Updater/UpdateFetcher.h b/src/server/database/Updater/UpdateFetcher.h index 4ff8c93bc76..22a0d08c7f8 100644 --- a/src/server/database/Updater/UpdateFetcher.h +++ b/src/server/database/Updater/UpdateFetcher.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/AI/CoreAI/CombatAI.cpp b/src/server/game/AI/CoreAI/CombatAI.cpp index 9d76ee5573d..716ac13c666 100644 --- a/src/server/game/AI/CoreAI/CombatAI.cpp +++ b/src/server/game/AI/CoreAI/CombatAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CoreAI/CombatAI.h b/src/server/game/AI/CoreAI/CombatAI.h index 26b5db3e7c8..55b91b6969e 100644 --- a/src/server/game/AI/CoreAI/CombatAI.h +++ b/src/server/game/AI/CoreAI/CombatAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CoreAI/GameObjectAI.cpp b/src/server/game/AI/CoreAI/GameObjectAI.cpp index 5ff53e4819c..8d2de7bc92e 100644 --- a/src/server/game/AI/CoreAI/GameObjectAI.cpp +++ b/src/server/game/AI/CoreAI/GameObjectAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CoreAI/GameObjectAI.h b/src/server/game/AI/CoreAI/GameObjectAI.h index bd588cd4571..4f256a5de31 100644 --- a/src/server/game/AI/CoreAI/GameObjectAI.h +++ b/src/server/game/AI/CoreAI/GameObjectAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CoreAI/GuardAI.cpp b/src/server/game/AI/CoreAI/GuardAI.cpp index 7fd1493cbde..c7d618a9918 100644 --- a/src/server/game/AI/CoreAI/GuardAI.cpp +++ b/src/server/game/AI/CoreAI/GuardAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -43,7 +43,7 @@ bool GuardAI::CanSeeAlways(WorldObject const* obj) return false; } -void GuardAI::EnterEvadeMode() +void GuardAI::EnterEvadeMode(EvadeReason /*why*/) { if (!me->IsAlive()) { diff --git a/src/server/game/AI/CoreAI/GuardAI.h b/src/server/game/AI/CoreAI/GuardAI.h index f7820640068..63f2750a5d4 100644 --- a/src/server/game/AI/CoreAI/GuardAI.h +++ b/src/server/game/AI/CoreAI/GuardAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -31,7 +31,7 @@ class GuardAI : public ScriptedAI static int Permissible(Creature const* creature); bool CanSeeAlways(WorldObject const* obj) override; - void EnterEvadeMode() override; + void EnterEvadeMode(EvadeReason /*why*/) override; void JustDied(Unit* killer) override; }; #endif diff --git a/src/server/game/AI/CoreAI/PassiveAI.cpp b/src/server/game/AI/CoreAI/PassiveAI.cpp index 5c482120b21..aafde3c1d9a 100644 --- a/src/server/game/AI/CoreAI/PassiveAI.cpp +++ b/src/server/game/AI/CoreAI/PassiveAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -26,7 +26,7 @@ NullCreatureAI::NullCreatureAI(Creature* c) : CreatureAI(c) { me->SetReactState( void PassiveAI::UpdateAI(uint32) { if (me->IsInCombat() && me->getAttackers().empty()) - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_NO_HOSTILES); } void PossessedAI::AttackStart(Unit* target) @@ -64,11 +64,11 @@ void CritterAI::DamageTaken(Unit* /*done_by*/, uint32&) me->SetControlled(true, UNIT_STATE_FLEEING); } -void CritterAI::EnterEvadeMode() +void CritterAI::EnterEvadeMode(EvadeReason why) { if (me->HasUnitState(UNIT_STATE_FLEEING)) me->SetControlled(false, UNIT_STATE_FLEEING); - CreatureAI::EnterEvadeMode(); + CreatureAI::EnterEvadeMode(why); } void TriggerAI::IsSummonedBy(Unit* summoner) diff --git a/src/server/game/AI/CoreAI/PassiveAI.h b/src/server/game/AI/CoreAI/PassiveAI.h index 40046323964..bd72cd7fbe7 100644 --- a/src/server/game/AI/CoreAI/PassiveAI.h +++ b/src/server/game/AI/CoreAI/PassiveAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -41,7 +41,7 @@ class PossessedAI : public CreatureAI void MoveInLineOfSight(Unit*) override { } void AttackStart(Unit* target) override; void UpdateAI(uint32) override; - void EnterEvadeMode() override { } + void EnterEvadeMode(EvadeReason /*why*/) override { } void JustDied(Unit*) override; void KilledUnit(Unit* victim) override; @@ -57,7 +57,7 @@ class NullCreatureAI : public CreatureAI void MoveInLineOfSight(Unit*) override { } void AttackStart(Unit*) override { } void UpdateAI(uint32) override { } - void EnterEvadeMode() override { } + void EnterEvadeMode(EvadeReason /*why*/) override { } void OnCharmed(bool /*apply*/) override { } static int Permissible(const Creature*) { return PERMIT_BASE_IDLE; } @@ -69,7 +69,7 @@ class CritterAI : public PassiveAI explicit CritterAI(Creature* c) : PassiveAI(c) { } void DamageTaken(Unit* done_by, uint32& /*damage*/) override; - void EnterEvadeMode() override; + void EnterEvadeMode(EvadeReason why) override; }; class TriggerAI : public NullCreatureAI diff --git a/src/server/game/AI/CoreAI/PetAI.cpp b/src/server/game/AI/CoreAI/PetAI.cpp index c870f786af3..8acf6b9c9dc 100644 --- a/src/server/game/AI/CoreAI/PetAI.cpp +++ b/src/server/game/AI/CoreAI/PetAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CoreAI/PetAI.h b/src/server/game/AI/CoreAI/PetAI.h index 89db5945c80..9c33baa9a9f 100644 --- a/src/server/game/AI/CoreAI/PetAI.h +++ b/src/server/game/AI/CoreAI/PetAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -47,7 +47,7 @@ class PetAI : public CreatureAI // void MoveInLineOfSight(Unit* /*who*/) override { } // CreatureAI interferes with returning pets void MoveInLineOfSight_Safe(Unit* /*who*/) { } // CreatureAI interferes with returning pets - void EnterEvadeMode() override { } // For fleeing, pets don't use this type of Evade mechanic + void EnterEvadeMode(EvadeReason /*why*/) override { } // For fleeing, pets don't use this type of Evade mechanic private: bool _isVisible(Unit*) const; diff --git a/src/server/game/AI/CoreAI/ReactorAI.cpp b/src/server/game/AI/CoreAI/ReactorAI.cpp index 9ab86047dc8..722be994995 100644 --- a/src/server/game/AI/CoreAI/ReactorAI.cpp +++ b/src/server/game/AI/CoreAI/ReactorAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CoreAI/ReactorAI.h b/src/server/game/AI/CoreAI/ReactorAI.h index 6791e147a15..e5abaac2f00 100644 --- a/src/server/game/AI/CoreAI/ReactorAI.h +++ b/src/server/game/AI/CoreAI/ReactorAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CoreAI/TotemAI.cpp b/src/server/game/AI/CoreAI/TotemAI.cpp index 57e926744e2..10fbb00bf9d 100644 --- a/src/server/game/AI/CoreAI/TotemAI.cpp +++ b/src/server/game/AI/CoreAI/TotemAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -40,7 +40,7 @@ TotemAI::TotemAI(Creature* c) : CreatureAI(c), i_victimGuid() void TotemAI::MoveInLineOfSight(Unit* /*who*/) { } -void TotemAI::EnterEvadeMode() +void TotemAI::EnterEvadeMode(EvadeReason /*why*/) { me->CombatStop(true); } diff --git a/src/server/game/AI/CoreAI/TotemAI.h b/src/server/game/AI/CoreAI/TotemAI.h index 7776db37097..e1d1618037f 100644 --- a/src/server/game/AI/CoreAI/TotemAI.h +++ b/src/server/game/AI/CoreAI/TotemAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -33,7 +33,7 @@ class TotemAI : public CreatureAI void MoveInLineOfSight(Unit* who) override; void AttackStart(Unit* victim) override; - void EnterEvadeMode() override; + void EnterEvadeMode(EvadeReason /*why*/) override; void UpdateAI(uint32 diff) override; static int Permissible(Creature const* creature); diff --git a/src/server/game/AI/CoreAI/UnitAI.cpp b/src/server/game/AI/CoreAI/UnitAI.cpp index f0d9d34db69..a3a5e7f7663 100644 --- a/src/server/game/AI/CoreAI/UnitAI.cpp +++ b/src/server/game/AI/CoreAI/UnitAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CoreAI/UnitAI.h b/src/server/game/AI/CoreAI/UnitAI.h index c93ed0db008..5dc5946b226 100644 --- a/src/server/game/AI/CoreAI/UnitAI.h +++ b/src/server/game/AI/CoreAI/UnitAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CreatureAI.cpp b/src/server/game/AI/CreatureAI.cpp index d76d106e81a..352ae635878 100644 --- a/src/server/game/AI/CreatureAI.cpp +++ b/src/server/game/AI/CreatureAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -26,6 +26,7 @@ #include "MapReference.h" #include "Player.h" #include "CreatureTextMgr.h" +#include "Language.h" //Disable CreatureAI when charmed void CreatureAI::OnCharmed(bool /*apply*/) @@ -132,7 +133,7 @@ void CreatureAI::MoveInLineOfSight(Unit* who) if (me->GetCreatureType() == CREATURE_TYPE_NON_COMBAT_PET) // non-combat pets should just stand there and look good;) return; - if (me->CanStartAttack(who, false)) + if (me->HasReactState(REACT_AGGRESSIVE) && me->CanStartAttack(who, false)) AttackStart(who); //else if (who->GetVictim() && me->IsFriendlyTo(who) // && me->IsWithinDistInMap(who, sWorld->getIntConfig(CONFIG_CREATURE_FAMILY_ASSISTANCE_RADIUS)) @@ -164,9 +165,9 @@ void CreatureAI::TriggerAlert(Unit const* who) const me->GetMotionMaster()->MoveDistract(5 * IN_MILLISECONDS); } -void CreatureAI::EnterEvadeMode() +void CreatureAI::EnterEvadeMode(EvadeReason why) { - if (!_EnterEvadeMode()) + if (!_EnterEvadeMode(why)) return; TC_LOG_DEBUG("entities.unit", "Creature %u enters evade mode.", me->GetEntry()); @@ -203,7 +204,8 @@ void CreatureAI::SetGazeOn(Unit* target) { if (me->IsValidAttackTarget(target)) { - AttackStart(target); + if (!me->IsFocusing(nullptr, true)) + AttackStart(target); me->SetReactState(REACT_PASSIVE); } } @@ -222,7 +224,8 @@ bool CreatureAI::UpdateVictimWithGaze() } if (Unit* victim = me->SelectVictim()) - AttackStart(victim); + if (!me->IsFocusing(nullptr, true)) + AttackStart(victim); return me->GetVictim() != nullptr; } @@ -235,20 +238,21 @@ bool CreatureAI::UpdateVictim() if (!me->HasReactState(REACT_PASSIVE)) { if (Unit* victim = me->SelectVictim()) - AttackStart(victim); + if (!me->IsFocusing(nullptr, true)) + AttackStart(victim); return me->GetVictim() != nullptr; } else if (me->getThreatManager().isThreatListEmpty()) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_NO_HOSTILES); return false; } return true; } -bool CreatureAI::_EnterEvadeMode() +bool CreatureAI::_EnterEvadeMode(EvadeReason /*why*/) { if (!me->IsAlive()) return false; @@ -271,6 +275,105 @@ bool CreatureAI::_EnterEvadeMode() return true; } +#define BOUNDARY_VISUALIZE_CREATURE 15425 +#define BOUNDARY_VISUALIZE_CREATURE_SCALE 0.25f +#define BOUNDARY_VISUALIZE_STEP_SIZE 1 +#define BOUNDARY_VISUALIZE_FAILSAFE_LIMIT 750 +#define BOUNDARY_VISUALIZE_SPAWN_HEIGHT 5 +int32 CreatureAI::VisualizeBoundary(uint32 duration, Unit* owner, bool fill) const +{ + typedef std::pair<int32, int32> coordinate; + + if (!owner) + return -1; + + if (!_boundary || _boundary->empty()) + return LANG_CREATURE_MOVEMENT_NOT_BOUNDED; + + std::queue<coordinate> Q; + std::unordered_set<coordinate> alreadyChecked; + std::unordered_set<coordinate> outOfBounds; + + Position startPosition = owner->GetPosition(); + if (!CheckBoundary(&startPosition)) // fall back to creature position + { + startPosition = me->GetPosition(); + if (!CheckBoundary(&startPosition)) + { + startPosition = me->GetHomePosition(); + if (!CheckBoundary(&startPosition)) // fall back to creature home position + return LANG_CREATURE_NO_INTERIOR_POINT_FOUND; + } + } + float spawnZ = startPosition.GetPositionZ() + BOUNDARY_VISUALIZE_SPAWN_HEIGHT; + + bool boundsWarning = false; + Q.push({ 0,0 }); + while (!Q.empty()) + { + coordinate front = Q.front(); + bool hasOutOfBoundsNeighbor = false; + for (coordinate off : std::initializer_list<coordinate>{{1,0}, {0,1}, {-1,0}, {0,-1}}) + { + coordinate next(front.first + off.first, front.second + off.second); + if (next.first > BOUNDARY_VISUALIZE_FAILSAFE_LIMIT || next.first < -BOUNDARY_VISUALIZE_FAILSAFE_LIMIT || next.second > BOUNDARY_VISUALIZE_FAILSAFE_LIMIT || next.second < -BOUNDARY_VISUALIZE_FAILSAFE_LIMIT) + { + boundsWarning = true; + continue; + } + if (alreadyChecked.find(next) == alreadyChecked.end()) // never check a coordinate twice + { + Position nextPos(startPosition.GetPositionX() + next.first*BOUNDARY_VISUALIZE_STEP_SIZE, startPosition.GetPositionY() + next.second*BOUNDARY_VISUALIZE_STEP_SIZE, startPosition.GetPositionZ()); + if (CheckBoundary(&nextPos)) + Q.push(next); + else + { + outOfBounds.insert(next); + hasOutOfBoundsNeighbor = true; + } + alreadyChecked.insert(next); + } + else + if (outOfBounds.find(next) != outOfBounds.end()) + hasOutOfBoundsNeighbor = true; + } + if (fill || hasOutOfBoundsNeighbor) + if (TempSummon* point = owner->SummonCreature(BOUNDARY_VISUALIZE_CREATURE, Position(startPosition.GetPositionX() + front.first*BOUNDARY_VISUALIZE_STEP_SIZE, startPosition.GetPositionY() + front.second*BOUNDARY_VISUALIZE_STEP_SIZE, spawnZ), TEMPSUMMON_TIMED_DESPAWN, duration * IN_MILLISECONDS)) + { + point->SetObjectScale(BOUNDARY_VISUALIZE_CREATURE_SCALE); + point->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_IMMUNE_TO_PC | UNIT_FLAG_STUNNED | UNIT_FLAG_IMMUNE_TO_NPC); + if (!hasOutOfBoundsNeighbor) + point->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE); + } + Q.pop(); + } + return boundsWarning ? LANG_CREATURE_MOVEMENT_MAYBE_UNBOUNDED : 0; +} + +bool CreatureAI::CheckBoundary(Position const* who) const +{ + if (!who) + who = me; + + if (_boundary) + for (CreatureBoundary::const_iterator it = _boundary->begin(); it != _boundary->end(); ++it) + if (!(*it)->IsWithinBoundary(who)) + return false; + + return true; +} + +bool CreatureAI::CheckInRoom() +{ + if (CheckBoundary()) + return true; + else + { + EnterEvadeMode(EVADE_REASON_BOUNDARY); + return false; + } +} + Creature* CreatureAI::DoSummon(uint32 entry, const Position& pos, uint32 despawnTime, TempSummonType summonType) { return me->SummonCreature(entry, pos, summonType, despawnTime); diff --git a/src/server/game/AI/CreatureAI.h b/src/server/game/AI/CreatureAI.h index a205ef16833..239fda577a7 100644 --- a/src/server/game/AI/CreatureAI.h +++ b/src/server/game/AI/CreatureAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -21,6 +21,7 @@ #include "Creature.h" #include "UnitAI.h" +#include "AreaBoundary.h" #include "Common.h" class WorldObject; @@ -63,6 +64,7 @@ enum SCEquip EQUIP_UNEQUIP = 0 }; +typedef std::set<AreaBoundary const*> CreatureBoundary; class CreatureAI : public UnitAI { protected: @@ -77,10 +79,20 @@ class CreatureAI : public UnitAI Creature* DoSummon(uint32 entry, WorldObject* obj, float radius = 5.0f, uint32 despawnTime = 30000, TempSummonType summonType = TEMPSUMMON_CORPSE_TIMED_DESPAWN); Creature* DoSummonFlyer(uint32 entry, WorldObject* obj, float flightZ, float radius = 5.0f, uint32 despawnTime = 30000, TempSummonType summonType = TEMPSUMMON_CORPSE_TIMED_DESPAWN); + bool CheckBoundary(Position const* who = nullptr) const; + void SetBoundary(CreatureBoundary const* boundary) { _boundary = boundary; me->DoImmediateBoundaryCheck(); } public: + enum EvadeReason + { + EVADE_REASON_NO_HOSTILES, // the creature's threat list is empty + EVADE_REASON_BOUNDARY, // the creature has moved outside its evade boundary + EVADE_REASON_SEQUENCE_BREAK, // this is a boss and the pre-requisite encounters for engaging it are not defeated yet + EVADE_REASON_OTHER + }; + void Talk(uint8 id, WorldObject const* whisperTarget = nullptr); - explicit CreatureAI(Creature* creature) : UnitAI(creature), me(creature), m_MoveInLineOfSight_locked(false) { } + explicit CreatureAI(Creature* creature) : UnitAI(creature), me(creature), _boundary(nullptr), m_MoveInLineOfSight_locked(false) { } virtual ~CreatureAI() { } @@ -96,7 +108,7 @@ class CreatureAI : public UnitAI virtual bool CanRespawn() { return true; } // Called for reaction at stopping attack at no attackers or targets - virtual void EnterEvadeMode(); + virtual void EnterEvadeMode(EvadeReason why = EVADE_REASON_OTHER); // Called for reaction at enter to combat if not in combat yet (enemy can be NULL) virtual void EnterCombat(Unit* /*victim*/) { } @@ -174,10 +186,17 @@ class CreatureAI : public UnitAI virtual bool CanSeeAlways(WorldObject const* /*obj*/) { return false; } + // intended for encounter design/debugging. do not use for other purposes. expensive. + int32 VisualizeBoundary(uint32 duration, Unit* owner=nullptr, bool fill=false) const; + virtual bool CheckInRoom(); + CreatureBoundary const* GetBoundary() const { return _boundary; } + protected: virtual void MoveInLineOfSight(Unit* /*who*/); - bool _EnterEvadeMode(); + bool _EnterEvadeMode(EvadeReason why = EVADE_REASON_OTHER); + + CreatureBoundary const* _boundary; private: bool m_MoveInLineOfSight_locked; diff --git a/src/server/game/AI/CreatureAIFactory.h b/src/server/game/AI/CreatureAIFactory.h index 4e11630259b..f83bdc9a8b1 100644 --- a/src/server/game/AI/CreatureAIFactory.h +++ b/src/server/game/AI/CreatureAIFactory.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CreatureAIImpl.h b/src/server/game/AI/CreatureAIImpl.h index 529f7420021..a45283b3d37 100644 --- a/src/server/game/AI/CreatureAIImpl.h +++ b/src/server/game/AI/CreatureAIImpl.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/AI/CreatureAIRegistry.cpp b/src/server/game/AI/CreatureAIRegistry.cpp index 933c20c9ee6..3189cbb6d88 100644 --- a/src/server/game/AI/CreatureAIRegistry.cpp +++ b/src/server/game/AI/CreatureAIRegistry.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CreatureAIRegistry.h b/src/server/game/AI/CreatureAIRegistry.h index 461d4d7bcb3..e17c7501bc8 100644 --- a/src/server/game/AI/CreatureAIRegistry.h +++ b/src/server/game/AI/CreatureAIRegistry.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CreatureAISelector.cpp b/src/server/game/AI/CreatureAISelector.cpp index 4cab7d5c099..c8c7838beec 100644 --- a/src/server/game/AI/CreatureAISelector.cpp +++ b/src/server/game/AI/CreatureAISelector.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/CreatureAISelector.h b/src/server/game/AI/CreatureAISelector.h index 0a2cec77daa..7c7bc705ade 100644 --- a/src/server/game/AI/CreatureAISelector.h +++ b/src/server/game/AI/CreatureAISelector.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp b/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp index 9a6742b5ebc..2fc87347364 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp +++ b/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -23,6 +23,7 @@ #include "Cell.h" #include "CellImpl.h" #include "ObjectMgr.h" +#include "AreaBoundary.h" // Spell summary for ScriptedAI::SelectSpell struct TSpellSummary @@ -98,7 +99,6 @@ bool SummonList::HasEntry(uint32 entry) const ScriptedAI::ScriptedAI(Creature* creature) : CreatureAI(creature), IsFleeing(false), - _evadeCheckCooldown(2500), _isCombatMovementAllowed(true) { _isHeroic = me->GetMap()->IsHeroic(); @@ -405,7 +405,7 @@ enum NPCs // Hacklike storage used for misc creatures that are expected to evade of outside of a certain area. // It is assumed the information is found elswehere and can be handled by the core. So far no luck finding such information/way to extract it. -bool ScriptedAI::EnterEvadeIfOutOfCombatArea(uint32 const diff) +/*bool ScriptedAI::EnterEvadeIfOutOfCombatArea(uint32 const diff) { if (_evadeCheckCooldown <= diff) _evadeCheckCooldown = 2500; @@ -449,15 +449,16 @@ bool ScriptedAI::EnterEvadeIfOutOfCombatArea(uint32 const diff) EnterEvadeMode(); return true; -} +}*/ // BossAI - for instanced bosses BossAI::BossAI(Creature* creature, uint32 bossId) : ScriptedAI(creature), instance(creature->GetInstanceScript()), summons(creature), - _boundary(instance ? instance->GetBossBoundary(bossId) : NULL), _bossId(bossId) { + if (instance) + SetBoundary(instance->GetBossBoundary(bossId)); scheduler.SetValidator([this] { return !me->HasUnitState(UNIT_STATE_CASTING); @@ -494,7 +495,7 @@ void BossAI::_EnterCombat() // bosses do not respawn, check only on enter combat if (!instance->CheckRequiredBosses(_bossId)) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_SEQUENCE_BREAK); return; } instance->SetBossState(_bossId, IN_PROGRESS); @@ -518,55 +519,6 @@ void BossAI::TeleportCheaters() target->NearTeleportTo(x, y, z, 0); } -bool BossAI::CheckBoundary(Unit* who) -{ - if (!GetBoundary() || !who) - return true; - - for (BossBoundaryMap::const_iterator itr = GetBoundary()->begin(); itr != GetBoundary()->end(); ++itr) - { - switch (itr->first) - { - case BOUNDARY_N: - if (who->GetPositionX() > itr->second) - return false; - break; - case BOUNDARY_S: - if (who->GetPositionX() < itr->second) - return false; - break; - case BOUNDARY_E: - if (who->GetPositionY() < itr->second) - return false; - break; - case BOUNDARY_W: - if (who->GetPositionY() > itr->second) - return false; - break; - case BOUNDARY_NW: - if (who->GetPositionX() + who->GetPositionY() > itr->second) - return false; - break; - case BOUNDARY_SE: - if (who->GetPositionX() + who->GetPositionY() < itr->second) - return false; - break; - case BOUNDARY_NE: - if (who->GetPositionX() - who->GetPositionY() > itr->second) - return false; - break; - case BOUNDARY_SW: - if (who->GetPositionX() - who->GetPositionY() < itr->second) - return false; - break; - default: - break; - } - } - - return true; -} - void BossAI::JustSummoned(Creature* summon) { summons.Summon(summon); @@ -595,6 +547,29 @@ void BossAI::UpdateAI(uint32 diff) DoMeleeAttackIfReady(); } +void BossAI::_DespawnAtEvade(uint32 delayToRespawn) +{ + if (delayToRespawn < 2) + { + TC_LOG_ERROR("scripts", "_DespawnAtEvade called with delay of %u seconds, defaulting to 2.", delayToRespawn); + delayToRespawn = 2; + } + + uint32 corpseDelay = me->GetCorpseDelay(); + uint32 respawnDelay = me->GetRespawnDelay(); + + me->SetCorpseDelay(1); + me->SetRespawnDelay(delayToRespawn - 1); + + me->DespawnOrUnsummon(); + + me->SetCorpseDelay(corpseDelay); + me->SetRespawnDelay(respawnDelay); + + if(instance) + instance->SetBossState(_bossId, FAIL); +} + // WorldBossAI - for non-instanced bosses WorldBossAI::WorldBossAI(Creature* creature) : diff --git a/src/server/game/AI/ScriptedAI/ScriptedCreature.h b/src/server/game/AI/ScriptedAI/ScriptedCreature.h index 242acbcd44d..5452a033a17 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedCreature.h +++ b/src/server/game/AI/ScriptedAI/ScriptedCreature.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -263,8 +263,6 @@ struct ScriptedAI : public CreatureAI void SetCombatMovement(bool allowMovement); bool IsCombatMovementAllowed() const { return _isCombatMovementAllowed; } - bool EnterEvadeIfOutOfCombatArea(uint32 const diff); - // return true for heroic mode. i.e. // - for dungeon in mode 10-heroic, // - for raid in mode 10-Heroic @@ -332,7 +330,6 @@ struct ScriptedAI : public CreatureAI private: Difficulty _difficulty; - uint32 _evadeCheckCooldown; bool _isCombatMovementAllowed; bool _isHeroic; }; @@ -344,7 +341,6 @@ class BossAI : public ScriptedAI virtual ~BossAI() { } InstanceScript* const instance; - BossBoundaryMap const* GetBoundary() const { return _boundary; } void JustSummoned(Creature* summon) override; void SummonedCreatureDespawn(Creature* summon) override; @@ -364,22 +360,15 @@ class BossAI : public ScriptedAI void JustDied(Unit* /*killer*/) override { _JustDied(); } void JustReachedHome() override { _JustReachedHome(); } + bool CanAIAttack(Unit const* target) const override { return CheckBoundary(target); } + protected: void _Reset(); void _EnterCombat(); void _JustDied(); void _JustReachedHome() { me->setActive(false); } + void _DespawnAtEvade(uint32 delayToRespawn = 30); - virtual bool CheckInRoom() - { - if (CheckBoundary(me)) - return true; - - EnterEvadeMode(); - return false; - } - - bool CheckBoundary(Unit* who); void TeleportCheaters(); EventMap events; @@ -387,7 +376,6 @@ class BossAI : public ScriptedAI TaskScheduler scheduler; private: - BossBoundaryMap const* const _boundary; uint32 const _bossId; }; diff --git a/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp b/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp index f1c53e2f9eb..68cb8d346d0 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp +++ b/src/server/game/AI/ScriptedAI/ScriptedEscortAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -184,7 +184,7 @@ void npc_escortAI::ReturnToLastPoint() me->GetMotionMaster()->MovePoint(POINT_LAST_POINT, x, y, z); } -void npc_escortAI::EnterEvadeMode() +void npc_escortAI::EnterEvadeMode(EvadeReason /*why*/) { me->RemoveAllAuras(); me->DeleteThreatList(); diff --git a/src/server/game/AI/ScriptedAI/ScriptedEscortAI.h b/src/server/game/AI/ScriptedAI/ScriptedEscortAI.h index deabd1dc484..673f3e671a0 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedEscortAI.h +++ b/src/server/game/AI/ScriptedAI/ScriptedEscortAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -66,7 +66,7 @@ struct npc_escortAI : public ScriptedAI void ReturnToLastPoint(); - void EnterEvadeMode() override; + void EnterEvadeMode(EvadeReason /*why*/ = EVADE_REASON_OTHER) override; void UpdateAI(uint32 diff) override; // the "internal" update, calls UpdateEscortAI() virtual void UpdateEscortAI(uint32 diff); // used when it's needed to add code in update (abilities, scripted events, etc) diff --git a/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp b/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp index 8985f722cf2..dc9f6d2681e 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp +++ b/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -176,7 +176,7 @@ void FollowerAI::JustRespawned() Reset(); } -void FollowerAI::EnterEvadeMode() +void FollowerAI::EnterEvadeMode(EvadeReason /*why*/) { me->RemoveAllAuras(); me->DeleteThreatList(); diff --git a/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.h b/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.h index 4afe7622179..d1c976b45c8 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.h +++ b/src/server/game/AI/ScriptedAI/ScriptedFollowerAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -46,7 +46,7 @@ class FollowerAI : public ScriptedAI void MoveInLineOfSight(Unit*) override; - void EnterEvadeMode() override; + void EnterEvadeMode(EvadeReason /*why*/ = EVADE_REASON_OTHER) override; void JustDied(Unit*) override; diff --git a/src/server/game/AI/ScriptedAI/ScriptedGossip.h b/src/server/game/AI/ScriptedAI/ScriptedGossip.h index 5ef50380592..e5e69d97236 100644 --- a/src/server/game/AI/ScriptedAI/ScriptedGossip.h +++ b/src/server/game/AI/ScriptedAI/ScriptedGossip.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AI/SmartScripts/SmartAI.cpp b/src/server/game/AI/SmartScripts/SmartAI.cpp index 46cf934356d..eca327e770e 100644 --- a/src/server/game/AI/SmartScripts/SmartAI.cpp +++ b/src/server/game/AI/SmartScripts/SmartAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -408,7 +408,7 @@ void SmartAI::MovementInform(uint32 MovementType, uint32 Data) MovepointReached(Data); } -void SmartAI::EnterEvadeMode() +void SmartAI::EnterEvadeMode(EvadeReason /*why*/) { if (!me->IsAlive() || me->IsInEvadeMode()) return; diff --git a/src/server/game/AI/SmartScripts/SmartAI.h b/src/server/game/AI/SmartScripts/SmartAI.h index ea03a821846..02c057247f6 100644 --- a/src/server/game/AI/SmartScripts/SmartAI.h +++ b/src/server/game/AI/SmartScripts/SmartAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -79,7 +79,7 @@ class SmartAI : public CreatureAI void EnterCombat(Unit* enemy) override; // Called for reaction at stopping attack at no attackers or targets - void EnterEvadeMode() override; + void EnterEvadeMode(EvadeReason why = EVADE_REASON_OTHER) override; // Called when the creature is killed void JustDied(Unit* killer) override; diff --git a/src/server/game/AI/SmartScripts/SmartScript.cpp b/src/server/game/AI/SmartScripts/SmartScript.cpp index 7ca4274bc40..c08d1508774 100644 --- a/src/server/game/AI/SmartScripts/SmartScript.cpp +++ b/src/server/game/AI/SmartScripts/SmartScript.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -1998,7 +1998,7 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u if (Creature* creature = (*itr)->ToCreature()) { creature->GetMotionMaster()->Clear(); - creature->GetMotionMaster()->MoveJump(e.target.x, e.target.y, e.target.z, (float)e.action.jump.speedxy, (float)e.action.jump.speedz); + creature->GetMotionMaster()->MoveJump(e.target.x, e.target.y, e.target.z, 0.0f, (float)e.action.jump.speedxy, (float)e.action.jump.speedz); // @todo add optional jump orientation support? } } /// @todo Resume path when reached jump location @@ -2305,6 +2305,31 @@ void SmartScript::ProcessAction(SmartScriptHolder& e, Unit* unit, uint32 var0, u } break; } + case SMART_ACTION_RANDOM_SOUND: + { + std::vector<uint32> sounds; + std::copy_if(e.action.randomSound.sounds.begin(), e.action.randomSound.sounds.end(), + std::back_inserter(sounds), [](uint32 sound) { return sound != 0; }); + + bool onlySelf = e.action.randomSound.onlySelf != 0; + + if (ObjectList* targets = GetTargets(e, unit)) + { + for (WorldObject* const obj : *targets) + { + if (IsUnit(obj)) + { + uint32 sound = Trinity::Containers::SelectRandomContainerElement(sounds); + obj->PlayDirectSound(sound, onlySelf ? obj->ToPlayer() : nullptr); + TC_LOG_DEBUG("scripts.ai", "SmartScript::ProcessAction:: SMART_ACTION_RANDOM_SOUND: target: %s (%s), sound: %u, onlyself: %s", + obj->GetName().c_str(), obj->GetGUID().ToString().c_str(), sound, onlySelf ? "true" : "false"); + } + } + + delete targets; + break; + } + } default: TC_LOG_ERROR("sql.sql", "SmartScript::ProcessAction: Entry %d SourceType %u, Event %u, Unhandled Action type %u", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType()); break; diff --git a/src/server/game/AI/SmartScripts/SmartScript.h b/src/server/game/AI/SmartScripts/SmartScript.h index 1c4b9a51ece..e8b89a813b5 100644 --- a/src/server/game/AI/SmartScripts/SmartScript.h +++ b/src/server/game/AI/SmartScripts/SmartScript.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -209,7 +209,7 @@ class SmartScript if (lookupRoot) { - if (!meOrigGUID) + if (!meOrigGUID.IsEmpty()) { if (Creature* m = ObjectAccessor::GetCreature(*lookupRoot, meOrigGUID)) { @@ -217,7 +217,8 @@ class SmartScript go = NULL; } } - if (!goOrigGUID) + + if (!goOrigGUID.IsEmpty()) { if (GameObject* o = ObjectAccessor::GetGameObject(*lookupRoot, goOrigGUID)) { diff --git a/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp b/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp index f0e3c3caff6..ef3357fa6ed 100644 --- a/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp +++ b/src/server/game/AI/SmartScripts/SmartScriptMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -468,7 +468,7 @@ bool SmartAIMgr::IsEventValid(SmartScriptHolder& e) TC_LOG_ERROR("sql.sql", "SmartAIMgr: Entry %d SourceType %u Event %u Action %u uses non-existent Map entry %u, skipped.", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType(), e.event.respawn.map); return false; } - if (e.event.respawn.type == SMART_SCRIPT_RESPAWN_CONDITION_AREA && !GetAreaEntryByAreaID(e.event.respawn.area)) + if (e.event.respawn.type == SMART_SCRIPT_RESPAWN_CONDITION_AREA && !sAreaTableStore.LookupEntry(e.event.respawn.area)) { TC_LOG_ERROR("sql.sql", "SmartAIMgr: Entry %d SourceType %u Event %u Action %u uses non-existent Area entry %u, skipped.", e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType(), e.event.respawn.area); return false; @@ -827,6 +827,21 @@ bool SmartAIMgr::IsEventValid(SmartScriptHolder& e) if (e.action.randomEmote.emote6 && !IsEmoteValid(e, e.action.randomEmote.emote6)) return false; break; + case SMART_ACTION_RANDOM_SOUND: + { + if (std::all_of(e.action.randomSound.sounds.begin(), e.action.randomSound.sounds.end(), [](uint32 sound) { return sound == 0; })) + { + TC_LOG_ERROR("sql.sql", "SmartAIMgr: Entry %d SourceType %u Event %u Action %u does not have any non-zero sound", + e.entryOrGuid, e.GetScriptType(), e.event_id, e.GetActionType()); + return false; + } + + for (uint32 sound : e.action.randomSound.sounds) + if (sound && !IsSoundValid(e, sound)) + return false; + + break; + } case SMART_ACTION_CAST: { if (!IsSpellValid(e, e.action.cast.spell)) diff --git a/src/server/game/AI/SmartScripts/SmartScriptMgr.h b/src/server/game/AI/SmartScripts/SmartScriptMgr.h index 2f9b032c14c..c0ea648462d 100644 --- a/src/server/game/AI/SmartScripts/SmartScriptMgr.h +++ b/src/server/game/AI/SmartScripts/SmartScriptMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -43,6 +43,16 @@ struct WayPoint float z; }; +enum eSmartAI +{ + SMART_EVENT_PARAM_COUNT = 4, + SMART_ACTION_PARAM_COUNT = 6, + SMART_SUMMON_COUNTER = 0xFFFFFF, + SMART_ESCORT_LAST_OOC_POINT = 0xFFFFFF, + SMART_RANDOM_POINT = 0xFFFFFE, + SMART_ESCORT_TARGETS = 0xFFFFFF +}; + enum SMART_EVENT_PHASE { SMART_EVENT_PHASE_ALWAYS = 0, @@ -540,8 +550,9 @@ enum SMART_ACTION SMART_ACTION_GAME_EVENT_START = 112, // GameEventId SMART_ACTION_START_CLOSEST_WAYPOINT = 113, // wp1, wp2, wp3, wp4, wp5, wp6, wp7 SMART_ACTION_RISE_UP = 114, // distance + SMART_ACTION_RANDOM_SOUND = 115, // soundId1, soundId2, soundId3, soundId4, soundId5, onlySelf - SMART_ACTION_END = 115 + SMART_ACTION_END = 116 }; struct SmartAction @@ -1017,6 +1028,12 @@ struct SmartAction uint32 wp6; } closestWaypointFromList; + struct + { + std::array<uint32, SMART_ACTION_PARAM_COUNT - 1> sounds; + uint32 onlySelf; + } randomSound; + //! Note for any new future actions //! All parameters must have type uint32 @@ -1180,16 +1197,6 @@ struct SmartTarget }; }; -enum eSmartAI -{ - SMART_EVENT_PARAM_COUNT = 4, - SMART_ACTION_PARAM_COUNT = 6, - SMART_SUMMON_COUNTER = 0xFFFFFF, - SMART_ESCORT_LAST_OOC_POINT = 0xFFFFFF, - SMART_RANDOM_POINT = 0xFFFFFE, - SMART_ESCORT_TARGETS = 0xFFFFFF -}; - enum SmartScriptType { SMART_SCRIPT_TYPE_CREATURE = 0, //done diff --git a/src/server/game/Accounts/AccountMgr.cpp b/src/server/game/Accounts/AccountMgr.cpp index 7ec1665bffc..737e9f37195 100644 --- a/src/server/game/Accounts/AccountMgr.cpp +++ b/src/server/game/Accounts/AccountMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Accounts/AccountMgr.h b/src/server/game/Accounts/AccountMgr.h index 3b09e51107c..40ccba1f8e5 100644 --- a/src/server/game/Accounts/AccountMgr.h +++ b/src/server/game/Accounts/AccountMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Accounts/RBAC.cpp b/src/server/game/Accounts/RBAC.cpp index c520564f0fa..a8720b66df4 100644 --- a/src/server/game/Accounts/RBAC.cpp +++ b/src/server/game/Accounts/RBAC.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Accounts/RBAC.h b/src/server/game/Accounts/RBAC.h index 4acadd7f2b4..4ebd3ae7042 100644 --- a/src/server/game/Accounts/RBAC.h +++ b/src/server/game/Accounts/RBAC.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -696,6 +696,7 @@ enum RBACPermissions RBAC_PERM_COMMAND_MODIFY_XP = 798, // 799 - 834 6.x only RBAC_PERM_COMMAND_DEBUG_LOADCELLS = 835, + RBAC_PERM_COMMAND_DEBUG_BOUNDARY = 836, // custom permissions 1000+ RBAC_PERM_MAX diff --git a/src/server/game/Achievements/AchievementMgr.cpp b/src/server/game/Achievements/AchievementMgr.cpp index a6359a353eb..ac8e0298a44 100644 --- a/src/server/game/Achievements/AchievementMgr.cpp +++ b/src/server/game/Achievements/AchievementMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -156,7 +156,7 @@ bool AchievementCriteriaData::IsValid(AchievementCriteriaEntry const* criteria) return true; } case ACHIEVEMENT_CRITERIA_DATA_TYPE_S_AREA: - if (!GetAreaEntryByAreaID(area.id)) + if (!sAreaTableStore.LookupEntry(area.id)) { TC_LOG_ERROR("sql.sql", "Table `achievement_criteria_data` (Entry: %u Type: %u) for data type ACHIEVEMENT_CRITERIA_DATA_TYPE_S_AREA (%u) has wrong area id in value1 (%u), ignored.", criteria->ID, criteria->requiredType, dataType, area.id); @@ -1905,17 +1905,15 @@ bool AchievementMgr::RequirementsSatisfied(AchievementCriteriaEntry const* achie bool matchFound = false; for (int j = 0; j < MAX_WORLD_MAP_OVERLAY_AREA_IDX; ++j) { - uint32 area_id = worldOverlayEntry->areatableID[j]; - if (!area_id) // array have 0 only in empty tail + AreaTableEntry const* area = sAreaTableStore.LookupEntry(worldOverlayEntry->areatableID[j]); + if (!area) break; - int32 exploreFlag = GetAreaFlagByAreaID(area_id); - if (exploreFlag < 0) + uint32 playerIndexOffset = uint32(area->exploreFlag) / 32; + if (playerIndexOffset >= PLAYER_EXPLORED_ZONES_SIZE) continue; - uint32 playerIndexOffset = uint32(exploreFlag) / 32; - uint32 mask = 1 << (uint32(exploreFlag) % 32); - + uint32 mask = 1 << (uint32(area->exploreFlag) % 32); if (GetPlayer()->GetUInt32Value(PLAYER_EXPLORED_ZONES_1 + playerIndexOffset) & mask) { matchFound = true; diff --git a/src/server/game/Achievements/AchievementMgr.h b/src/server/game/Achievements/AchievementMgr.h index 078229ea4c8..cc3fd55bc3a 100644 --- a/src/server/game/Achievements/AchievementMgr.h +++ b/src/server/game/Achievements/AchievementMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Addons/AddonMgr.cpp b/src/server/game/Addons/AddonMgr.cpp index 460311061ac..0f8d4eb907e 100644 --- a/src/server/game/Addons/AddonMgr.cpp +++ b/src/server/game/Addons/AddonMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Addons/AddonMgr.h b/src/server/game/Addons/AddonMgr.h index 3727882ecd5..996ddf79f88 100644 --- a/src/server/game/Addons/AddonMgr.h +++ b/src/server/game/Addons/AddonMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/AuctionHouse/AuctionHouseMgr.cpp b/src/server/game/AuctionHouse/AuctionHouseMgr.cpp index 20d30704c13..035d9af4369 100644 --- a/src/server/game/AuctionHouse/AuctionHouseMgr.cpp +++ b/src/server/game/AuctionHouse/AuctionHouseMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -573,6 +573,14 @@ void AuctionHouseObject::Update() if (AuctionsMap.empty()) return; + // Clear expired throttled players + for (PlayerGetAllThrottleMap::const_iterator itr = GetAllThrottleMap.begin(); itr != GetAllThrottleMap.end();) + { + if (itr->second <= curTime) + itr = GetAllThrottleMap.erase(itr); + else + ++itr; + } SQLTransaction trans = CharacterDatabase.BeginTransaction(); @@ -648,13 +656,40 @@ void AuctionHouseObject::BuildListOwnerItems(WorldPacket& data, Player* player, void AuctionHouseObject::BuildListAuctionItems(WorldPacket& data, Player* player, std::wstring const& wsearchedname, uint32 listfrom, uint8 levelmin, uint8 levelmax, uint8 usable, uint32 inventoryType, uint32 itemClass, uint32 itemSubClass, uint32 quality, - uint32& count, uint32& totalcount) + uint32& count, uint32& totalcount, bool getall) { int loc_idx = player->GetSession()->GetSessionDbLocaleIndex(); int locdbc_idx = player->GetSession()->GetSessionDbcLocale(); time_t curTime = sWorld->GetGameTime(); + PlayerGetAllThrottleMap::const_iterator itr = GetAllThrottleMap.find(player->GetGUID()); + time_t throttleTime = itr != GetAllThrottleMap.end() ? itr->second : curTime; + + if (getall && throttleTime <= curTime) + { + for (AuctionEntryMap::const_iterator itr = AuctionsMap.begin(); itr != AuctionsMap.end(); ++itr) + { + AuctionEntry* Aentry = itr->second; + // Skip expired auctions + if (Aentry->expire_time < curTime) + continue; + + Item* item = sAuctionMgr->GetAItem(Aentry->itemGUIDLow); + if (!item) + continue; + + ++count; + ++totalcount; + Aentry->BuildAuctionInfo(data, item); + + if (count >= MAX_GETALL_RETURN) + break; + } + GetAllThrottleMap[player->GetGUID()] = curTime + sWorld->getIntConfig(CONFIG_AUCTION_GETALL_DELAY); + return; + } + for (AuctionEntryMap::const_iterator itr = AuctionsMap.begin(); itr != AuctionsMap.end(); ++itr) { AuctionEntry* Aentry = itr->second; @@ -744,16 +779,16 @@ void AuctionHouseObject::BuildListAuctionItems(WorldPacket& data, Player* player if (count < 50 && totalcount >= listfrom) { ++count; - Aentry->BuildAuctionInfo(data); + Aentry->BuildAuctionInfo(data, item); } ++totalcount; } } //this function inserts to WorldPacket auction's data -bool AuctionEntry::BuildAuctionInfo(WorldPacket& data) const +bool AuctionEntry::BuildAuctionInfo(WorldPacket& data, Item* sourceItem) const { - Item* item = sAuctionMgr->GetAItem(itemGUIDLow); + Item* item = (sourceItem) ? sourceItem : sAuctionMgr->GetAItem(itemGUIDLow); if (!item) { TC_LOG_ERROR("misc", "AuctionEntry::BuildAuctionInfo: Auction %u has a non-existent item: %u", Id, itemGUIDLow); diff --git a/src/server/game/AuctionHouse/AuctionHouseMgr.h b/src/server/game/AuctionHouse/AuctionHouseMgr.h index 1f885837a44..fe4b9ed07de 100644 --- a/src/server/game/AuctionHouse/AuctionHouseMgr.h +++ b/src/server/game/AuctionHouse/AuctionHouseMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -30,6 +30,7 @@ class WorldPacket; #define MIN_AUCTION_TIME (12*HOUR) #define MAX_AUCTION_ITEMS 160 +#define MAX_GETALL_RETURN 55000 enum AuctionError { @@ -90,7 +91,7 @@ struct AuctionEntry uint8 GetHouseId() const { return houseId; } uint32 GetAuctionCut() const; uint32 GetAuctionOutBid() const; - bool BuildAuctionInfo(WorldPacket & data) const; + bool BuildAuctionInfo(WorldPacket & data, Item* sourceItem = nullptr) const; void DeleteFromDB(SQLTransaction& trans) const; void SaveToDB(SQLTransaction& trans) const; bool LoadFromDB(Field* fields); @@ -110,6 +111,7 @@ class AuctionHouseObject } typedef std::map<uint32, AuctionEntry*> AuctionEntryMap; + typedef std::unordered_map<ObjectGuid, time_t> PlayerGetAllThrottleMap; uint32 Getcount() const { return AuctionsMap.size(); } @@ -133,10 +135,15 @@ class AuctionHouseObject void BuildListAuctionItems(WorldPacket& data, Player* player, std::wstring const& searchedname, uint32 listfrom, uint8 levelmin, uint8 levelmax, uint8 usable, uint32 inventoryType, uint32 itemClass, uint32 itemSubClass, uint32 quality, - uint32& count, uint32& totalcount); + uint32& count, uint32& totalcount, bool getall = false); private: AuctionEntryMap AuctionsMap; + + // Map of throttled players for GetAll, and throttle expiry time + // Stored here, rather than player object to maintain persistence after logout + PlayerGetAllThrottleMap GetAllThrottleMap; + }; class AuctionHouseMgr diff --git a/src/server/game/AuctionHouseBot/AuctionHouseBot.cpp b/src/server/game/AuctionHouseBot/AuctionHouseBot.cpp index c905ccedf2d..e1ba9a64191 100644 --- a/src/server/game/AuctionHouseBot/AuctionHouseBot.cpp +++ b/src/server/game/AuctionHouseBot/AuctionHouseBot.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -242,6 +242,22 @@ void AuctionBotConfig::GetConfigFromFile() SetConfig(CONFIG_AHBOT_CLASS_TRADEGOOD_MAX_ITEM_LEVEL, "AuctionHouseBot.Class.TradeGood.ItemLevel.Max", 0); SetConfig(CONFIG_AHBOT_CLASS_CONTAINER_MIN_ITEM_LEVEL, "AuctionHouseBot.Class.Container.ItemLevel.Min", 0); SetConfig(CONFIG_AHBOT_CLASS_CONTAINER_MAX_ITEM_LEVEL, "AuctionHouseBot.Class.Container.ItemLevel.Max", 0); + + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_CONSUMABLE, "AuctionHouseBot.Class.RandomStackRatio.Consumable", 20); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_CONTAINER, "AuctionHouseBot.Class.RandomStackRatio.Container", 0); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_WEAPON, "AuctionHouseBot.Class.RandomStackRatio.Weapon", 0); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_GEM, "AuctionHouseBot.Class.RandomStackRatio.Gem", 20); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_ARMOR, "AuctionHouseBot.Class.RandomStackRatio.Armor", 0); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_REAGENT, "AuctionHouseBot.Class.RandomStackRatio.Reagent", 100); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_PROJECTILE, "AuctionHouseBot.Class.RandomStackRatio.Projectile", 100); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_TRADEGOOD, "AuctionHouseBot.Class.RandomStackRatio.TradeGood", 50); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_GENERIC, "AuctionHouseBot.Class.RandomStackRatio.Generic", 100); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_RECIPE, "AuctionHouseBot.Class.RandomStackRatio.Recipe", 0); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_QUIVER, "AuctionHouseBot.Class.RandomStackRatio.Quiver", 0); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_QUEST, "AuctionHouseBot.Class.RandomStackRatio.Quest", 100); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_KEY, "AuctionHouseBot.Class.RandomStackRatio.Key", 100); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_MISC, "AuctionHouseBot.Class.RandomStackRatio.Misc", 100); + SetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_GLYPH, "AuctionHouseBot.Class.RandomStackRatio.Glyph", 0); } char const* AuctionBotConfig::GetHouseTypeName(AuctionHouseType houseType) diff --git a/src/server/game/AuctionHouseBot/AuctionHouseBot.h b/src/server/game/AuctionHouseBot/AuctionHouseBot.h index 225d3b7ee25..87f76a17dcc 100644 --- a/src/server/game/AuctionHouseBot/AuctionHouseBot.h +++ b/src/server/game/AuctionHouseBot/AuctionHouseBot.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -137,6 +137,21 @@ enum AuctionBotConfigUInt32Values CONFIG_AHBOT_CLASS_TRADEGOOD_MAX_ITEM_LEVEL, CONFIG_AHBOT_CLASS_CONTAINER_MIN_ITEM_LEVEL, CONFIG_AHBOT_CLASS_CONTAINER_MAX_ITEM_LEVEL, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_CONSUMABLE, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_CONTAINER, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_WEAPON, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_GEM, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_ARMOR, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_REAGENT, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_PROJECTILE, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_TRADEGOOD, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_GENERIC, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_RECIPE, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_QUIVER, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_QUEST, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_KEY, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_MISC, + CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_GLYPH, CONFIG_UINT32_AHBOT_UINT32_COUNT }; diff --git a/src/server/game/AuctionHouseBot/AuctionHouseBotBuyer.cpp b/src/server/game/AuctionHouseBot/AuctionHouseBotBuyer.cpp index 80c32cf66e7..7f05cd2efd7 100644 --- a/src/server/game/AuctionHouseBot/AuctionHouseBotBuyer.cpp +++ b/src/server/game/AuctionHouseBot/AuctionHouseBotBuyer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/AuctionHouseBot/AuctionHouseBotBuyer.h b/src/server/game/AuctionHouseBot/AuctionHouseBotBuyer.h index c030731cb40..e1b6b425c48 100644 --- a/src/server/game/AuctionHouseBot/AuctionHouseBotBuyer.h +++ b/src/server/game/AuctionHouseBot/AuctionHouseBotBuyer.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/AuctionHouseBot/AuctionHouseBotSeller.cpp b/src/server/game/AuctionHouseBot/AuctionHouseBotSeller.cpp index 22dc5bb0bd0..5acb56b5173 100644 --- a/src/server/game/AuctionHouseBot/AuctionHouseBotSeller.cpp +++ b/src/server/game/AuctionHouseBot/AuctionHouseBotSeller.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -533,6 +533,23 @@ void AuctionBotSeller::LoadItemsQuantity(SellerConfiguration& config) config.SetItemsQuantityPerClass(AUCTION_QUALITY_YELLOW, ITEM_CLASS_GLYPH, 0); // ============================================================================================ + // Set Stack Quantities + config.SetRandomStackRatioPerClass(ITEM_CLASS_CONSUMABLE, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_CONSUMABLE)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_CONTAINER, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_CONTAINER)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_WEAPON, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_WEAPON)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_GEM, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_GEM)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_ARMOR, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_ARMOR)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_REAGENT, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_REAGENT)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_PROJECTILE, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_PROJECTILE)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_TRADE_GOODS, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_TRADEGOOD)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_GENERIC, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_GENERIC)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_RECIPE, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_RECIPE)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_QUIVER, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_QUIVER)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_QUEST, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_QUEST)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_KEY, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_KEY)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_MISC, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_MISC)); + config.SetRandomStackRatioPerClass(ITEM_CLASS_GLYPH, sAuctionBotConfig->GetConfig(CONFIG_AHBOT_CLASS_RANDOMSTACKRATIO_GLYPH)); + // Set the best value to get nearest amount of items wanted for (uint32 j = 0; j < MAX_AUCTION_QUALITY; ++j) { @@ -719,6 +736,15 @@ void AuctionBotSeller::SetPricesOfItem(ItemTemplate const* itemProto, SellerConf bidp = urand(basePrice - range, basePrice + range) + 1; } +// Determines the stack size to use for the item +uint32 AuctionBotSeller::GetStackSizeForItem(ItemTemplate const* itemProto, SellerConfiguration& config) const +{ + if (config.GetRandomStackRatioPerClass(ItemClass(itemProto->Class)) > urand(0, 99)) + return urand(1, itemProto->GetMaxStackSize()); + else + return 1; +} + // Determine the multiplier for the sell price of any weapon without a buy price. uint32 AuctionBotSeller::GetSellModifier(ItemTemplate const* prototype) { @@ -952,7 +978,7 @@ void AuctionBotSeller::AddNewAuctions(SellerConfiguration& config) continue; } - uint32 stackCount = urand(1, prototype->GetMaxStackSize()); + uint32 stackCount = GetStackSizeForItem(prototype, config); Item* item = Item::CreateItem(itemId, stackCount); if (!item) diff --git a/src/server/game/AuctionHouseBot/AuctionHouseBotSeller.h b/src/server/game/AuctionHouseBot/AuctionHouseBotSeller.h index bccb4519382..dd82b0f3dda 100644 --- a/src/server/game/AuctionHouseBot/AuctionHouseBotSeller.h +++ b/src/server/game/AuctionHouseBot/AuctionHouseBotSeller.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -33,12 +33,13 @@ typedef std::vector<std::vector<uint32>> AllItemsArray; struct SellerItemClassInfo { - SellerItemClassInfo(): AmountOfItems(0), MissItems(0), Quantity(0), PriceRatio(0) {} + SellerItemClassInfo(): AmountOfItems(0), MissItems(0), Quantity(0), PriceRatio(0), RandomStackRatio(100) {} uint32 AmountOfItems; uint32 MissItems; uint32 Quantity; uint32 PriceRatio; + uint32 RandomStackRatio; }; struct SellerItemInfo @@ -102,6 +103,8 @@ public: uint32 GetPriceRatioPerQuality(AuctionQuality quality) const { return _ItemInfo[quality].PriceRatio; } void SetPriceRatioPerClass(ItemClass item, uint32 value) { _ItemInfo[0].ItemClassInfos[item].PriceRatio = value; } uint32 GetPriceRatioPerClass(ItemClass item) const { return _ItemInfo[0].ItemClassInfos[item].PriceRatio; } + void SetRandomStackRatioPerClass(ItemClass item, uint32 value) { _ItemInfo[0].ItemClassInfos[item].RandomStackRatio = value; } + uint32 GetRandomStackRatioPerClass(ItemClass item) const { return _ItemInfo[0].ItemClassInfos[item].RandomStackRatio; } private: AuctionHouseType _houseType; @@ -139,6 +142,7 @@ private: uint32 SetStat(SellerConfiguration& config); bool GetItemsToSell(SellerConfiguration& config, ItemsToSellArray& itemsToSellArray, AllItemsArray const& addedItem); void SetPricesOfItem(ItemTemplate const* itemProto, SellerConfiguration& config, uint32& buyp, uint32& bidp, uint32 stackcnt); + uint32 GetStackSizeForItem(ItemTemplate const* itemProto, SellerConfiguration& config) const; void LoadItemsQuantity(SellerConfiguration& config); static uint32 GetBuyModifier(ItemTemplate const* prototype); static uint32 GetSellModifier(ItemTemplate const* itemProto); diff --git a/src/server/game/Battlefield/Battlefield.cpp b/src/server/game/Battlefield/Battlefield.cpp index d22ac0ea5d5..34326d09e2f 100644 --- a/src/server/game/Battlefield/Battlefield.cpp +++ b/src/server/game/Battlefield/Battlefield.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlefield/Battlefield.h b/src/server/game/Battlefield/Battlefield.h index bb3ecb60838..ade3e8c9699 100644 --- a/src/server/game/Battlefield/Battlefield.h +++ b/src/server/game/Battlefield/Battlefield.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlefield/BattlefieldMgr.cpp b/src/server/game/Battlefield/BattlefieldMgr.cpp index 00da81fb992..e4c10d64682 100644 --- a/src/server/game/Battlefield/BattlefieldMgr.cpp +++ b/src/server/game/Battlefield/BattlefieldMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlefield/BattlefieldMgr.h b/src/server/game/Battlefield/BattlefieldMgr.h index fcc75234bc5..fabb33ae359 100644 --- a/src/server/game/Battlefield/BattlefieldMgr.h +++ b/src/server/game/Battlefield/BattlefieldMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlefield/Zones/BattlefieldWG.cpp b/src/server/game/Battlefield/Zones/BattlefieldWG.cpp index 6e670e4d5dc..3c9bf40f66c 100644 --- a/src/server/game/Battlefield/Zones/BattlefieldWG.cpp +++ b/src/server/game/Battlefield/Zones/BattlefieldWG.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlefield/Zones/BattlefieldWG.h b/src/server/game/Battlefield/Zones/BattlefieldWG.h index dcad65afa85..e5cc392cef3 100644 --- a/src/server/game/Battlefield/Zones/BattlefieldWG.h +++ b/src/server/game/Battlefield/Zones/BattlefieldWG.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlegrounds/Arena.cpp b/src/server/game/Battlegrounds/Arena.cpp index 60cc609a06a..1ccf3107a00 100644 --- a/src/server/game/Battlegrounds/Arena.cpp +++ b/src/server/game/Battlegrounds/Arena.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlegrounds/Arena.h b/src/server/game/Battlegrounds/Arena.h index af43da8162f..863f1fc8c6f 100644 --- a/src/server/game/Battlegrounds/Arena.h +++ b/src/server/game/Battlegrounds/Arena.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlegrounds/ArenaScore.h b/src/server/game/Battlegrounds/ArenaScore.h index 742c4d09498..c2d9d18c00b 100644 --- a/src/server/game/Battlegrounds/ArenaScore.h +++ b/src/server/game/Battlegrounds/ArenaScore.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlegrounds/ArenaTeam.cpp b/src/server/game/Battlegrounds/ArenaTeam.cpp index 423273c9904..ec007df6b6c 100644 --- a/src/server/game/Battlegrounds/ArenaTeam.cpp +++ b/src/server/game/Battlegrounds/ArenaTeam.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/ArenaTeam.h b/src/server/game/Battlegrounds/ArenaTeam.h index 2b08eaa667d..f27c3761bde 100644 --- a/src/server/game/Battlegrounds/ArenaTeam.h +++ b/src/server/game/Battlegrounds/ArenaTeam.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/ArenaTeamMgr.cpp b/src/server/game/Battlegrounds/ArenaTeamMgr.cpp index 4fdb34e8d2f..b838131fd03 100644 --- a/src/server/game/Battlegrounds/ArenaTeamMgr.cpp +++ b/src/server/game/Battlegrounds/ArenaTeamMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlegrounds/ArenaTeamMgr.h b/src/server/game/Battlegrounds/ArenaTeamMgr.h index 6e7709e0ce8..432a4ff598f 100644 --- a/src/server/game/Battlegrounds/ArenaTeamMgr.h +++ b/src/server/game/Battlegrounds/ArenaTeamMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlegrounds/Battleground.cpp b/src/server/game/Battlegrounds/Battleground.cpp index d368b347a0f..100e2e6c7cc 100644 --- a/src/server/game/Battlegrounds/Battleground.cpp +++ b/src/server/game/Battlegrounds/Battleground.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Battleground.h b/src/server/game/Battlegrounds/Battleground.h index 471da9846b2..03f138a5a8b 100644 --- a/src/server/game/Battlegrounds/Battleground.h +++ b/src/server/game/Battlegrounds/Battleground.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/BattlegroundMgr.cpp b/src/server/game/Battlegrounds/BattlegroundMgr.cpp index 3aac3f080f2..062d4702d43 100644 --- a/src/server/game/Battlegrounds/BattlegroundMgr.cpp +++ b/src/server/game/Battlegrounds/BattlegroundMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/BattlegroundMgr.h b/src/server/game/Battlegrounds/BattlegroundMgr.h index f732f430fc6..595745e53fb 100644 --- a/src/server/game/Battlegrounds/BattlegroundMgr.h +++ b/src/server/game/Battlegrounds/BattlegroundMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/BattlegroundQueue.cpp b/src/server/game/Battlegrounds/BattlegroundQueue.cpp index 223b71eb8c5..34588c7e380 100644 --- a/src/server/game/Battlegrounds/BattlegroundQueue.cpp +++ b/src/server/game/Battlegrounds/BattlegroundQueue.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/BattlegroundQueue.h b/src/server/game/Battlegrounds/BattlegroundQueue.h index 1509a60e15d..31f108053d9 100644 --- a/src/server/game/Battlegrounds/BattlegroundQueue.h +++ b/src/server/game/Battlegrounds/BattlegroundQueue.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/BattlegroundScore.h b/src/server/game/Battlegrounds/BattlegroundScore.h index 4348eef2c8c..428dece1c77 100644 --- a/src/server/game/Battlegrounds/BattlegroundScore.h +++ b/src/server/game/Battlegrounds/BattlegroundScore.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundAB.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundAB.cpp index f9d32e68e0e..834151108a4 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundAB.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundAB.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundAB.h b/src/server/game/Battlegrounds/Zones/BattlegroundAB.h index 61b35b92321..328eb79d210 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundAB.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundAB.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundAV.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundAV.cpp index 4ac02bab9ec..f7ee5c7f16b 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundAV.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundAV.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundAV.h b/src/server/game/Battlegrounds/Zones/BattlegroundAV.h index 164676151f5..7967ae06718 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundAV.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundAV.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundBE.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundBE.cpp index 2bf2f1d5e9e..6e85e5bcfdf 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundBE.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundBE.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundBE.h b/src/server/game/Battlegrounds/Zones/BattlegroundBE.h index 6dd10f11e1b..224d4277a4f 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundBE.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundBE.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundDS.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundDS.cpp index 02f9d6a32a6..22e229a1615 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundDS.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundDS.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundDS.h b/src/server/game/Battlegrounds/Zones/BattlegroundDS.h index f4c88ec00e5..af1c55fdf9b 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundDS.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundDS.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp index 7ab513c9201..626bcacbf27 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundEY.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundEY.h b/src/server/game/Battlegrounds/Zones/BattlegroundEY.h index 50888614aa5..ccd14a2f3bc 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundEY.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundEY.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp index bc2fc387e89..52e0deaf86f 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -365,7 +365,7 @@ bool BattlegroundIC::SetupBattleground() // setting correct factions for Keep Cannons for (uint8 i = BG_IC_NPC_KEEP_CANNON_1; i <= BG_IC_NPC_KEEP_CANNON_12; ++i) GetBGCreature(i)->setFaction(BG_IC_Factions[0]); - for (uint8 i = BG_IC_NPC_KEEP_CANNON_13; i <= BG_IC_NPC_KEEP_CANNON_25; ++i) + for (uint8 i = BG_IC_NPC_KEEP_CANNON_13; i <= BG_IC_NPC_KEEP_CANNON_24; ++i) GetBGCreature(i)->setFaction(BG_IC_Factions[1]); // correcting spawn time for keeps bombs diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundIC.h b/src/server/game/Battlegrounds/Zones/BattlegroundIC.h index e2d511e0f1f..44666819feb 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundIC.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundIC.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -390,7 +390,6 @@ enum BG_IC_NPCs BG_IC_NPC_KEEP_CANNON_22, BG_IC_NPC_KEEP_CANNON_23, BG_IC_NPC_KEEP_CANNON_24, - BG_IC_NPC_KEEP_CANNON_25, BG_IC_NPC_SIEGE_ENGINE_A, BG_IC_NPC_SIEGE_ENGINE_H, @@ -444,7 +443,7 @@ enum BannersTypes enum BG_IC_MaxSpawns { MAX_NORMAL_GAMEOBJECTS_SPAWNS = BG_IC_GO_DOODAD_ND_WINTERORC_WALL_GATEFX_DOOR03+1, - MAX_NORMAL_NPCS_SPAWNS = BG_IC_NPC_KEEP_CANNON_25+1, + MAX_NORMAL_NPCS_SPAWNS = BG_IC_NPC_KEEP_CANNON_24+1, MAX_WORKSHOP_SPAWNS = 10, MAX_DOCKS_SPAWNS = 12, MAX_SPIRIT_GUIDES_SPAWNS = 7, @@ -506,9 +505,8 @@ const ICNpc BG_IC_NpcSpawnlocs[MAX_NORMAL_NPCS_SPAWNS] = {BG_IC_NPC_KEEP_CANNON_20, NPC_KEEP_CANNON, TEAM_HORDE, 1137.72f, -688.517f, 88.4023f, 3.9619f}, // 30 {BG_IC_NPC_KEEP_CANNON_21, NPC_KEEP_CANNON, TEAM_HORDE, 1135.29f, -840.878f, 88.0252f, 2.30383f}, // 31 {BG_IC_NPC_KEEP_CANNON_22, NPC_KEEP_CANNON, TEAM_HORDE, 1144.33f, -833.309f, 87.9268f, 2.14675f}, // 32 - {BG_IC_NPC_KEEP_CANNON_23, NPC_KEEP_CANNON, TEAM_HORDE, 1135.29f, -840.878f, 88.0252f, 2.30383f}, // 33 - {BG_IC_NPC_KEEP_CANNON_24, NPC_KEEP_CANNON, TEAM_HORDE, 1142.59f, -691.946f, 87.9756f, 3.9619f}, // 34 - {BG_IC_NPC_KEEP_CANNON_25, NPC_KEEP_CANNON, TEAM_HORDE, 1166.13f, -858.391f, 87.9653f, 5.63741f} // 35 + {BG_IC_NPC_KEEP_CANNON_23, NPC_KEEP_CANNON, TEAM_HORDE, 1142.59f, -691.946f, 87.9756f, 3.9619f}, // 33 + {BG_IC_NPC_KEEP_CANNON_24, NPC_KEEP_CANNON, TEAM_HORDE, 1166.13f, -858.391f, 87.9653f, 5.63741f} // 34 }; const Position BG_IC_WorkshopVehicles[5] = diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundNA.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundNA.cpp index a89652a5d06..95fef007564 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundNA.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundNA.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundNA.h b/src/server/game/Battlegrounds/Zones/BattlegroundNA.h index 4b5551a7d15..c311967d8a8 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundNA.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundNA.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundRL.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundRL.cpp index 0c30b557459..a55f437ca6a 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundRL.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundRL.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundRL.h b/src/server/game/Battlegrounds/Zones/BattlegroundRL.h index 1d15991902c..0f6b79661f9 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundRL.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundRL.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundRV.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundRV.cpp index 316812243dd..f4a03e85cad 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundRV.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundRV.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundRV.h b/src/server/game/Battlegrounds/Zones/BattlegroundRV.h index 67635230633..57347ec0c75 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundRV.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundRV.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundSA.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundSA.cpp index bfae37c64e6..1942ac9d648 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundSA.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundSA.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -389,6 +389,8 @@ void BattlegroundSA::PostUpdateImpl(uint32 diff) { if (TotalTime >= BG_SA_ROUNDLENGTH) { + CastSpellOnTeam(SPELL_END_OF_ROUND, ALLIANCE); + CastSpellOnTeam(SPELL_END_OF_ROUND, HORDE); RoundScores[0].winner = Attackers; RoundScores[0].time = BG_SA_ROUNDLENGTH; TotalTime = 0; @@ -401,8 +403,6 @@ void BattlegroundSA::PostUpdateImpl(uint32 diff) ToggleTimer(); ResetObjs(); GetBgMap()->UpdateAreaDependentAuras(); - CastSpellOnTeam(SPELL_END_OF_ROUND, ALLIANCE); - CastSpellOnTeam(SPELL_END_OF_ROUND, HORDE); return; } } @@ -410,6 +410,8 @@ void BattlegroundSA::PostUpdateImpl(uint32 diff) { if (TotalTime >= EndRoundTimer) { + CastSpellOnTeam(SPELL_END_OF_ROUND, ALLIANCE); + CastSpellOnTeam(SPELL_END_OF_ROUND, HORDE); RoundScores[1].time = BG_SA_ROUNDLENGTH; RoundScores[1].winner = (Attackers == TEAM_ALLIANCE) ? TEAM_HORDE : TEAM_ALLIANCE; if (RoundScores[0].time == RoundScores[1].time) diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundSA.h b/src/server/game/Battlegrounds/Zones/BattlegroundSA.h index 118cea41a7b..b60e04e725e 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundSA.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundSA.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundWS.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundWS.cpp index 69f6b012c8b..bc1ee3d44ea 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundWS.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundWS.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundWS.h b/src/server/game/Battlegrounds/Zones/BattlegroundWS.h index 35985e27d0e..b7eb7025425 100644 --- a/src/server/game/Battlegrounds/Zones/BattlegroundWS.h +++ b/src/server/game/Battlegrounds/Zones/BattlegroundWS.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/CMakeLists.txt b/src/server/game/CMakeLists.txt index 6455e3a7e29..aae5b4874d8 100644 --- a/src/server/game/CMakeLists.txt +++ b/src/server/game/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/game/Calendar/CalendarMgr.cpp b/src/server/game/Calendar/CalendarMgr.cpp index 368ebecba84..9d50b290c5e 100644 --- a/src/server/game/Calendar/CalendarMgr.cpp +++ b/src/server/game/Calendar/CalendarMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Calendar/CalendarMgr.h b/src/server/game/Calendar/CalendarMgr.h index 9969c00e3af..59303a18324 100644 --- a/src/server/game/Calendar/CalendarMgr.h +++ b/src/server/game/Calendar/CalendarMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Chat/Channels/Channel.cpp b/src/server/game/Chat/Channels/Channel.cpp index 07ac0c49686..0875ceefff5 100644 --- a/src/server/game/Chat/Channels/Channel.cpp +++ b/src/server/game/Chat/Channels/Channel.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Chat/Channels/Channel.h b/src/server/game/Chat/Channels/Channel.h index 0f2a940e3b4..26bc6989d07 100644 --- a/src/server/game/Chat/Channels/Channel.h +++ b/src/server/game/Chat/Channels/Channel.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Chat/Channels/ChannelMgr.cpp b/src/server/game/Chat/Channels/ChannelMgr.cpp index 92832b860bf..3e9a633729a 100644 --- a/src/server/game/Chat/Channels/ChannelMgr.cpp +++ b/src/server/game/Chat/Channels/ChannelMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Chat/Channels/ChannelMgr.h b/src/server/game/Chat/Channels/ChannelMgr.h index 4d7f1354334..2cd4edc4fb1 100644 --- a/src/server/game/Chat/Channels/ChannelMgr.h +++ b/src/server/game/Chat/Channels/ChannelMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Chat/Chat.cpp b/src/server/game/Chat/Chat.cpp index c99fe62f11e..8fe0810f3b9 100644 --- a/src/server/game/Chat/Chat.cpp +++ b/src/server/game/Chat/Chat.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -296,11 +296,11 @@ bool ChatHandler::ExecuteCommandInTable(std::vector<ChatCommand> const& table, c uint32 areaId = player->GetAreaId(); std::string areaName = "Unknown"; std::string zoneName = "Unknown"; - if (AreaTableEntry const* area = GetAreaEntryByAreaID(areaId)) + if (AreaTableEntry const* area = sAreaTableStore.LookupEntry(areaId)) { int locale = GetSessionDbcLocale(); areaName = area->area_name[locale]; - if (AreaTableEntry const* zone = GetAreaEntryByAreaID(area->zone)) + if (AreaTableEntry const* zone = sAreaTableStore.LookupEntry(area->zone)) zoneName = zone->area_name[locale]; } diff --git a/src/server/game/Chat/Chat.h b/src/server/game/Chat/Chat.h index 2420331e363..7ce0792cdf9 100644 --- a/src/server/game/Chat/Chat.h +++ b/src/server/game/Chat/Chat.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Chat/ChatLink.cpp b/src/server/game/Chat/ChatLink.cpp index 732a770645b..3602b54bc44 100644 --- a/src/server/game/Chat/ChatLink.cpp +++ b/src/server/game/Chat/ChatLink.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Chat/ChatLink.h b/src/server/game/Chat/ChatLink.h index 498412b1dea..4adb61bbbf1 100644 --- a/src/server/game/Chat/ChatLink.h +++ b/src/server/game/Chat/ChatLink.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Combat/HostileRefManager.cpp b/src/server/game/Combat/HostileRefManager.cpp index 245cc77eec3..397fd59b7d1 100644 --- a/src/server/game/Combat/HostileRefManager.cpp +++ b/src/server/game/Combat/HostileRefManager.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Combat/HostileRefManager.h b/src/server/game/Combat/HostileRefManager.h index 005e1bf67b3..96152ed46f7 100644 --- a/src/server/game/Combat/HostileRefManager.h +++ b/src/server/game/Combat/HostileRefManager.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Combat/ThreatManager.cpp b/src/server/game/Combat/ThreatManager.cpp index 2ec84c946f6..588e7b1a93b 100644 --- a/src/server/game/Combat/ThreatManager.cpp +++ b/src/server/game/Combat/ThreatManager.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Combat/ThreatManager.h b/src/server/game/Combat/ThreatManager.h index 1926651e418..7d20e99c128 100644 --- a/src/server/game/Combat/ThreatManager.h +++ b/src/server/game/Combat/ThreatManager.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Combat/UnitEvents.h b/src/server/game/Combat/UnitEvents.h index 4127c8b55f6..e501cdaa4a2 100644 --- a/src/server/game/Combat/UnitEvents.h +++ b/src/server/game/Combat/UnitEvents.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Conditions/ConditionMgr.cpp b/src/server/game/Conditions/ConditionMgr.cpp index bae400adcc2..4215a3a5d02 100644 --- a/src/server/game/Conditions/ConditionMgr.cpp +++ b/src/server/game/Conditions/ConditionMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -1708,7 +1708,7 @@ bool ConditionMgr::isConditionTypeValid(Condition* cond) const } case CONDITION_ZONEID: { - AreaTableEntry const* areaEntry = GetAreaEntryByAreaID(cond->ConditionValue1); + AreaTableEntry const* areaEntry = sAreaTableStore.LookupEntry(cond->ConditionValue1); if (!areaEntry) { TC_LOG_ERROR("sql.sql", "%s Area (%u) does not exist, skipped.", cond->ToString(true).c_str(), cond->ConditionValue1); diff --git a/src/server/game/Conditions/ConditionMgr.h b/src/server/game/Conditions/ConditionMgr.h index 43454aba049..35096ae18ff 100644 --- a/src/server/game/Conditions/ConditionMgr.h +++ b/src/server/game/Conditions/ConditionMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Conditions/DisableMgr.cpp b/src/server/game/Conditions/DisableMgr.cpp index 6f77d2af66b..11c79e99b81 100644 --- a/src/server/game/Conditions/DisableMgr.cpp +++ b/src/server/game/Conditions/DisableMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Conditions/DisableMgr.h b/src/server/game/Conditions/DisableMgr.h index ee223aeb059..e74b7a9c319 100644 --- a/src/server/game/Conditions/DisableMgr.h +++ b/src/server/game/Conditions/DisableMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/DataStores/DBCEnums.h b/src/server/game/DataStores/DBCEnums.h index 104c3d3e064..f0ea5b4a5f1 100644 --- a/src/server/game/DataStores/DBCEnums.h +++ b/src/server/game/DataStores/DBCEnums.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/DataStores/DBCStores.cpp b/src/server/game/DataStores/DBCStores.cpp index 806d9d46763..6c51c71fe7b 100644 --- a/src/server/game/DataStores/DBCStores.cpp +++ b/src/server/game/DataStores/DBCStores.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -51,11 +51,9 @@ struct WMOAreaTableTripple typedef std::map<WMOAreaTableTripple, WMOAreaTableEntry const*> WMOAreaInfoByTripple; typedef std::multimap<uint32, CharSectionsEntry const*> CharSectionsMap; -DBCStorage <AreaTableEntry> sAreaStore(AreaTableEntryfmt); +DBCStorage <AreaTableEntry> sAreaTableStore(AreaTableEntryfmt); DBCStorage <AreaGroupEntry> sAreaGroupStore(AreaGroupEntryfmt); DBCStorage <AreaPOIEntry> sAreaPOIStore(AreaPOIEntryfmt); -static AreaFlagByAreaID sAreaFlagByAreaID; -static AreaFlagByMapID sAreaFlagByMapID; // for instances without generated *.map files static WMOAreaInfoByTripple sWMOAreaInfoByTripple; @@ -91,6 +89,9 @@ DBCStorage <DurabilityCostsEntry> sDurabilityCostsStore(DurabilityCostsfmt); DBCStorage <EmotesEntry> sEmotesStore(EmotesEntryfmt); DBCStorage <EmotesTextEntry> sEmotesTextStore(EmotesTextEntryfmt); +typedef std::tuple<uint32, uint32, uint32> EmotesTextSoundKey; +static std::map<EmotesTextSoundKey, EmotesTextSoundEntry const*> sEmotesTextSoundMap; +DBCStorage <EmotesTextSoundEntry> sEmotesTextSoundStore(EmotesTextSoundEntryfmt); typedef std::map<uint32, SimpleFactionsList> FactionTeamMap; static FactionTeamMap sFactionTeamMap; @@ -283,21 +284,7 @@ void LoadDBCStores(const std::string& dataPath) StoreProblemList bad_dbc_files; uint32 availableDbcLocales = 0xFFFFFFFF; - LoadDBC(availableDbcLocales, bad_dbc_files, sAreaStore, dbcPath, "AreaTable.dbc"); - - // must be after sAreaStore loading - for (uint32 i = 0; i < sAreaStore.GetNumRows(); ++i) // areaflag numbered from 0 - { - if (AreaTableEntry const* area = sAreaStore.LookupEntry(i)) - { - // fill AreaId->DBC records - sAreaFlagByAreaID.insert(AreaFlagByAreaID::value_type(uint16(area->ID), area->exploreFlag)); - - // fill MapId->DBC records (skip sub zones and continents) - if (area->zone == 0 && area->mapid != 0 && area->mapid != 1 && area->mapid != 530 && area->mapid != 571) - sAreaFlagByMapID.insert(AreaFlagByMapID::value_type(area->mapid, area->exploreFlag)); - } - } + LoadDBC(availableDbcLocales, bad_dbc_files, sAreaTableStore, dbcPath, "AreaTable.dbc"); LoadDBC(availableDbcLocales, bad_dbc_files, sAchievementStore, dbcPath, "Achievement.dbc", &CustomAchievementfmt, &CustomAchievementIndex); LoadDBC(availableDbcLocales, bad_dbc_files, sAchievementCriteriaStore, dbcPath, "Achievement_Criteria.dbc"); @@ -338,6 +325,10 @@ void LoadDBCStores(const std::string& dataPath) LoadDBC(availableDbcLocales, bad_dbc_files, sDurabilityQualityStore, dbcPath, "DurabilityQuality.dbc"); LoadDBC(availableDbcLocales, bad_dbc_files, sEmotesStore, dbcPath, "Emotes.dbc"); LoadDBC(availableDbcLocales, bad_dbc_files, sEmotesTextStore, dbcPath, "EmotesText.dbc"); + LoadDBC(availableDbcLocales, bad_dbc_files, sEmotesTextSoundStore, dbcPath, "EmotesTextSound.dbc"); + for (uint32 i = 0; i < sEmotesTextSoundStore.GetNumRows(); ++i) + if (EmotesTextSoundEntry const* entry = sEmotesTextSoundStore.LookupEntry(i)) + sEmotesTextSoundMap[EmotesTextSoundKey(entry->EmotesTextId, entry->RaceId, entry->SexId)] = entry; LoadDBC(availableDbcLocales, bad_dbc_files, sFactionStore, dbcPath, "Faction.dbc"); for (uint32 i=0; i<sFactionStore.GetNumRows(); ++i) { @@ -714,7 +705,7 @@ void LoadDBCStores(const std::string& dataPath) } // Check loaded DBC files proper version - if (!sAreaStore.LookupEntry(3617) || // last area (areaflag) added in 3.3.5a + if (!sAreaTableStore.LookupEntry(4987) || // last area added in 3.3.5a !sCharTitlesStore.LookupEntry(177) || // last char title added in 3.3.5a !sGemPropertiesStore.LookupEntry(1629) || // last added spell in 3.3.5a !sItemStore.LookupEntry(56806) || // last gem property added in 3.3.5a @@ -766,41 +757,13 @@ uint32 GetTalentSpellCost(uint32 spellId) return 0; } -int32 GetAreaFlagByAreaID(uint32 area_id) -{ - AreaFlagByAreaID::iterator i = sAreaFlagByAreaID.find(area_id); - if (i == sAreaFlagByAreaID.end()) - return -1; - - return i->second; -} WMOAreaTableEntry const* GetWMOAreaTableEntryByTripple(int32 rootid, int32 adtid, int32 groupid) { WMOAreaInfoByTripple::iterator i = sWMOAreaInfoByTripple.find(WMOAreaTableTripple(rootid, adtid, groupid)); - if (i == sWMOAreaInfoByTripple.end()) - return NULL; - return i->second; -} - -AreaTableEntry const* GetAreaEntryByAreaID(uint32 area_id) -{ - int32 areaflag = GetAreaFlagByAreaID(area_id); - if (areaflag < 0) + if (i == sWMOAreaInfoByTripple.end()) return NULL; - - return sAreaStore.LookupEntry(areaflag); -} - -AreaTableEntry const* GetAreaEntryByAreaFlagAndMap(uint32 area_flag, uint32 map_id) -{ - if (area_flag) - return sAreaStore.LookupEntry(area_flag); - - if (MapEntry const* mapEntry = sMapStore.LookupEntry(map_id)) - return GetAreaEntryByAreaID(mapEntry->linked_zone); - - return NULL; + return i->second; } char const* GetRaceName(uint8 race, uint8 locale) @@ -815,15 +778,6 @@ char const* GetClassName(uint8 class_, uint8 locale) return classEntry ? classEntry->name[locale] : NULL; } -uint32 GetAreaFlagByMapId(uint32 mapid) -{ - AreaFlagByMapID::iterator i = sAreaFlagByMapID.find(mapid); - if (i == sAreaFlagByMapID.end()) - return 0; - else - return i->second; -} - uint32 GetVirtualMapForMapAndZone(uint32 mapid, uint32 zoneId) { if (mapid != 530 && mapid != 571) // speed for most cases @@ -1060,3 +1014,8 @@ ResponseCodes ValidateName(std::string const& name, LocaleConstant locale) return CHAR_NAME_SUCCESS; } + +EmotesTextSoundEntry const* FindTextSoundEmoteFor(uint32 emote, uint32 race, uint32 gender) +{ + return sEmotesTextSoundMap[EmotesTextSoundKey(emote, race, gender)]; +} diff --git a/src/server/game/DataStores/DBCStores.h b/src/server/game/DataStores/DBCStores.h index 2def7901244..56ee1f618dd 100644 --- a/src/server/game/DataStores/DBCStores.h +++ b/src/server/game/DataStores/DBCStores.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -33,11 +33,6 @@ char* GetPetName(uint32 petfamily, uint32 dbclang); uint32 GetTalentSpellCost(uint32 spellId); TalentSpellPos const* GetTalentSpellPos(uint32 spellId); -int32 GetAreaFlagByAreaID(uint32 area_id); // -1 if not found -AreaTableEntry const* GetAreaEntryByAreaID(uint32 area_id); -AreaTableEntry const* GetAreaEntryByAreaFlagAndMap(uint32 area_flag, uint32 map_id); -uint32 GetAreaFlagByMapId(uint32 mapid); - char const* GetRaceName(uint8 race, uint8 locale); char const* GetClassName(uint8 class_, uint8 locale); @@ -82,9 +77,11 @@ SkillRaceClassInfoEntry const* GetSkillRaceClassInfo(uint32 skill, uint8 race, u ResponseCodes ValidateName(std::string const& name, LocaleConstant locale); +EmotesTextSoundEntry const* FindTextSoundEmoteFor(uint32 emote, uint32 race, uint32 gender); + extern DBCStorage <AchievementEntry> sAchievementStore; extern DBCStorage <AchievementCriteriaEntry> sAchievementCriteriaStore; -extern DBCStorage <AreaTableEntry> sAreaStore;// recommend access using functions +extern DBCStorage <AreaTableEntry> sAreaTableStore; extern DBCStorage <AreaGroupEntry> sAreaGroupStore; extern DBCStorage <AreaPOIEntry> sAreaPOIStore; extern DBCStorage <AreaTriggerEntry> sAreaTriggerStore; @@ -113,6 +110,7 @@ extern DBCStorage <DurabilityCostsEntry> sDurabilityCostsStore; extern DBCStorage <DurabilityQualityEntry> sDurabilityQualityStore; extern DBCStorage <EmotesEntry> sEmotesStore; extern DBCStorage <EmotesTextEntry> sEmotesTextStore; +extern DBCStorage <EmotesTextSoundEntry> sEmotesTextSoundStore; extern DBCStorage <FactionEntry> sFactionStore; extern DBCStorage <FactionTemplateEntry> sFactionTemplateStore; extern DBCStorage <GameObjectDisplayInfoEntry> sGameObjectDisplayInfoStore; diff --git a/src/server/game/DataStores/DBCStructure.h b/src/server/game/DataStores/DBCStructure.h index a419864a194..b5dc4489148 100644 --- a/src/server/game/DataStores/DBCStructure.h +++ b/src/server/game/DataStores/DBCStructure.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -509,7 +509,7 @@ struct AreaTableEntry uint32 ID; // 0 uint32 mapid; // 1 uint32 zone; // 2 if 0 then it's zone, else it's zone id of this area - uint32 exploreFlag; // 3, main index + uint32 exploreFlag; // 3 uint32 flags; // 4, unknown value but 312 for all cities // 5-9 unused int32 area_level; // 10 @@ -926,6 +926,15 @@ struct EmotesTextEntry uint32 textid; }; +struct EmotesTextSoundEntry +{ + uint32 Id; // 0 + uint32 EmotesTextId; // 1 + uint32 RaceId; // 2 + uint32 SexId; // 3, 0 male / 1 female + uint32 SoundId; // 4 +}; + struct FactionEntry { uint32 ID; // 0 m_ID diff --git a/src/server/game/DataStores/DBCfmt.h b/src/server/game/DataStores/DBCfmt.h index e81db5924f6..c61ec997bc2 100644 --- a/src/server/game/DataStores/DBCfmt.h +++ b/src/server/game/DataStores/DBCfmt.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -23,7 +23,7 @@ char const Achievementfmt[] = "niixssssssssssssssssxxxxxxxxxxxxxxxxxxiixixxxxxxx const std::string CustomAchievementfmt = "pppaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaapapaaaaaaaaaaaaaaaaaapp"; const std::string CustomAchievementIndex = "ID"; char const AchievementCriteriafmt[] = "niiiiiiiixxxxxxxxxxxxxxxxxiiiix"; -char const AreaTableEntryfmt[] = "iiinixxxxxissssssssssssssssxiiiiixxx"; +char const AreaTableEntryfmt[] = "niiiixxxxxissssssssssssssssxiiiiixxx"; char const AreaGroupEntryfmt[] = "niiiiiii"; char const AreaPOIEntryfmt[] = "niiiiiiiiiiifffixixxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxix"; char const AreaTriggerEntryfmt[] = "niffffffff"; @@ -52,6 +52,7 @@ char const DurabilityCostsfmt[] = "niiiiiiiiiiiiiiiiiiiiiiiiiiiii"; char const DurabilityQualityfmt[] = "nf"; char const EmotesEntryfmt[] = "nxxiiix"; char const EmotesTextEntryfmt[] = "nxixxxxxxxxxxxxxxxx"; +char const EmotesTextSoundEntryfmt[] = "niiii"; char const FactionEntryfmt[] = "niiiiiiiiiiiiiiiiiiffixssssssssssssssssxxxxxxxxxxxxxxxxxx"; char const FactionTemplateEntryfmt[] = "niiiiiiiiiiiii"; char const GameObjectDisplayInfofmt[] = "nsxxxxxxxxxxffffffx"; diff --git a/src/server/game/DungeonFinding/LFG.cpp b/src/server/game/DungeonFinding/LFG.cpp index 8ec638128d8..50343f3d91b 100644 --- a/src/server/game/DungeonFinding/LFG.cpp +++ b/src/server/game/DungeonFinding/LFG.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/DungeonFinding/LFG.h b/src/server/game/DungeonFinding/LFG.h index 84a25ee49ad..73c123723b1 100644 --- a/src/server/game/DungeonFinding/LFG.h +++ b/src/server/game/DungeonFinding/LFG.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/DungeonFinding/LFGGroupData.cpp b/src/server/game/DungeonFinding/LFGGroupData.cpp index aa6916a39a4..c5d75c1b83e 100644 --- a/src/server/game/DungeonFinding/LFGGroupData.cpp +++ b/src/server/game/DungeonFinding/LFGGroupData.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/DungeonFinding/LFGGroupData.h b/src/server/game/DungeonFinding/LFGGroupData.h index b573e7c309e..7ae4777cd4d 100644 --- a/src/server/game/DungeonFinding/LFGGroupData.h +++ b/src/server/game/DungeonFinding/LFGGroupData.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/DungeonFinding/LFGMgr.cpp b/src/server/game/DungeonFinding/LFGMgr.cpp index 250f6e07718..b0a1777f19a 100644 --- a/src/server/game/DungeonFinding/LFGMgr.cpp +++ b/src/server/game/DungeonFinding/LFGMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/DungeonFinding/LFGMgr.h b/src/server/game/DungeonFinding/LFGMgr.h index 90fbc36a114..90a8d802f9d 100644 --- a/src/server/game/DungeonFinding/LFGMgr.h +++ b/src/server/game/DungeonFinding/LFGMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/DungeonFinding/LFGPlayerData.cpp b/src/server/game/DungeonFinding/LFGPlayerData.cpp index d7f24e72320..c89bf6f135b 100644 --- a/src/server/game/DungeonFinding/LFGPlayerData.cpp +++ b/src/server/game/DungeonFinding/LFGPlayerData.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/DungeonFinding/LFGPlayerData.h b/src/server/game/DungeonFinding/LFGPlayerData.h index 51437f50b26..859317ca956 100644 --- a/src/server/game/DungeonFinding/LFGPlayerData.h +++ b/src/server/game/DungeonFinding/LFGPlayerData.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/DungeonFinding/LFGQueue.cpp b/src/server/game/DungeonFinding/LFGQueue.cpp index 86b010a9ace..314803d1602 100644 --- a/src/server/game/DungeonFinding/LFGQueue.cpp +++ b/src/server/game/DungeonFinding/LFGQueue.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/DungeonFinding/LFGQueue.h b/src/server/game/DungeonFinding/LFGQueue.h index f72e9b4fd6d..ed8193ab605 100644 --- a/src/server/game/DungeonFinding/LFGQueue.h +++ b/src/server/game/DungeonFinding/LFGQueue.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/DungeonFinding/LFGScripts.cpp b/src/server/game/DungeonFinding/LFGScripts.cpp index 2f0734ff4d0..79d36055870 100644 --- a/src/server/game/DungeonFinding/LFGScripts.cpp +++ b/src/server/game/DungeonFinding/LFGScripts.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/DungeonFinding/LFGScripts.h b/src/server/game/DungeonFinding/LFGScripts.h index 8860ddf83cc..377614bc55d 100644 --- a/src/server/game/DungeonFinding/LFGScripts.h +++ b/src/server/game/DungeonFinding/LFGScripts.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Entities/Corpse/Corpse.cpp b/src/server/game/Entities/Corpse/Corpse.cpp index ce4e94b8ea6..8f700cc636f 100644 --- a/src/server/game/Entities/Corpse/Corpse.cpp +++ b/src/server/game/Entities/Corpse/Corpse.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Corpse/Corpse.h b/src/server/game/Entities/Corpse/Corpse.h index 7f2608e4bf3..5062645eac8 100644 --- a/src/server/game/Entities/Corpse/Corpse.h +++ b/src/server/game/Entities/Corpse/Corpse.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Creature/Creature.cpp b/src/server/game/Entities/Creature/Creature.cpp index 6ba8fb44e09..5d62b740947 100644 --- a/src/server/game/Entities/Creature/Creature.cpp +++ b/src/server/game/Entities/Creature/Creature.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -180,7 +180,7 @@ bool ForcedDespawnDelayEvent::Execute(uint64 /*e_time*/, uint32 /*p_time*/) Creature::Creature(bool isWorldObject): Unit(isWorldObject), MapObject(), m_groupLootTimer(0), lootingGroupLowGUID(0), m_PlayerDamageReq(0), m_lootRecipient(), m_lootRecipientGroup(0), _skinner(), _pickpocketLootRestore(0), m_corpseRemoveTime(0), m_respawnTime(0), -m_respawnDelay(300), m_corpseDelay(60), m_respawnradius(0.0f), m_combatPulseTime(0), m_combatPulseDelay(0), m_reactState(REACT_AGGRESSIVE), +m_respawnDelay(300), m_corpseDelay(60), m_respawnradius(0.0f), m_boundaryCheckTime(2500), m_combatPulseTime(0), m_combatPulseDelay(0), m_reactState(REACT_AGGRESSIVE), m_defaultMovementType(IDLE_MOTION_TYPE), m_spawnId(0), m_equipmentId(0), m_originalEquipmentId(0), m_AlreadyCallAssistance(false), m_AlreadySearchedAssistance(false), m_regenHealth(true), m_AI_locked(false), m_meleeDamageSchoolMask(SPELL_SCHOOL_MASK_NORMAL), m_originalEntry(0), m_homePosition(), m_transportHomePosition(), m_creatureInfo(NULL), m_creatureData(NULL), m_waypointID(0), m_path_id(0), m_formation(NULL) @@ -200,6 +200,7 @@ m_originalEntry(0), m_homePosition(), m_transportHomePosition(), m_creatureInfo( TriggerJustRespawned = false; m_isTempWorldObject = false; _focusSpell = NULL; + _focusDelay = 0; } Creature::~Creature() @@ -368,13 +369,13 @@ bool Creature::InitEntry(uint32 entry, CreatureData const* data /*= nullptr*/) SetByteValue(UNIT_FIELD_BYTES_0, 2, minfo->gender); // Load creature equipment - if (!data || data->equipmentId == 0) - LoadEquipment(); // use default equipment (if available) - else if (data && data->equipmentId != 0) // override, 0 means no equipment + if (data && data->equipmentId != 0) { m_originalEquipmentId = data->equipmentId; LoadEquipment(data->equipmentId); } + else + LoadEquipment(0, true); SetName(normalInfo->Name); // at normal entry always @@ -582,6 +583,17 @@ void Creature::Update(uint32 diff) LastCharmerGUID.Clear(); } + // periodic check to see if the creature has passed an evade boundary + if (IsAIEnabled && !IsInEvadeMode() && IsInCombat()) + { + if (diff >= m_boundaryCheckTime) + { + AI()->CheckInRoom(); + m_boundaryCheckTime = 2500; + } else + m_boundaryCheckTime -= diff; + } + // if periodic combat pulse is enabled and we are both in combat and in a dungeon, do this now if (m_combatPulseDelay > 0 && IsInCombat() && GetMap()->IsDungeon()) { @@ -893,6 +905,12 @@ bool Creature::Create(ObjectGuid::LowType guidlow, Map* map, uint32 phaseMask, u if (GetCreatureTemplate()->flags_extra & CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING) AddUnitState(UNIT_STATE_IGNORE_PATHFINDING); + if (GetCreatureTemplate()->flags_extra & CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK) + { + ApplySpellImmune(0, IMMUNITY_EFFECT, SPELL_EFFECT_KNOCK_BACK, true); + ApplySpellImmune(0, IMMUNITY_EFFECT, SPELL_EFFECT_KNOCK_BACK_DEST, true); + } + return true; } @@ -1280,8 +1298,38 @@ bool Creature::CreateFromProto(ObjectGuid::LowType guidlow, uint32 entry, Creatu return true; } -bool Creature::LoadCreatureFromDB(ObjectGuid::LowType spawnId, Map* map, bool addToMap) +bool Creature::LoadCreatureFromDB(ObjectGuid::LowType spawnId, Map* map, bool addToMap, bool allowDuplicate) { + if (!allowDuplicate) + { + // If an alive instance of this spawnId is already found, skip creation + // If only dead instance(s) exist, despawn them and spawn a new (maybe also dead) version + const auto creatureBounds = map->GetCreatureBySpawnIdStore().equal_range(spawnId); + std::vector <Creature*> despawnList; + + if (creatureBounds.first != creatureBounds.second) + { + for (auto itr = creatureBounds.first; itr != creatureBounds.second; ++itr) + { + if (itr->second->IsAlive()) + { + TC_LOG_DEBUG("maps", "Would have spawned %u but %s already exists", spawnId, creatureBounds.first->second->GetGUID().ToString().c_str()); + return false; + } + else + { + despawnList.push_back(itr->second); + TC_LOG_DEBUG("maps", "Despawned dead instance of spawn %u (%s)", spawnId, itr->second->GetGUID().ToString().c_str()); + } + } + + for (Creature* despawnCreature : despawnList) + { + despawnCreature->AddObjectToRemoveList(); + } + } + } + CreatureData const* data = sObjectMgr->GetCreatureData(spawnId); if (!data) @@ -1361,6 +1409,7 @@ void Creature::LoadEquipment(int8 id, bool force /*= true*/) SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + i, 0); m_equipmentId = 0; } + return; } @@ -1369,7 +1418,7 @@ void Creature::LoadEquipment(int8 id, bool force /*= true*/) return; m_equipmentId = id; - for (uint8 i = 0; i < 3; ++i) + for (uint8 i = 0; i < MAX_EQUIPMENT_ITEMS; ++i) SetUInt32Value(UNIT_VIRTUAL_ITEM_SLOT_ID + i, einfo->ItemEntry[i]); } @@ -1558,7 +1607,9 @@ void Creature::setDeathState(DeathState s) if (sWorld->getBoolConfig(CONFIG_SAVE_RESPAWN_TIME_IMMEDIATELY) || isWorldBoss()) SaveRespawnTime(); - SetTarget(ObjectGuid::Empty); // remove target selection in any cases (can be set at aura remove in Unit::setDeathState) + ReleaseFocus(); // remove spellcast focus (this also clears unit target) + SetTarget(ObjectGuid::Empty); // drop target - dead mobs shouldn't ever target things + SetUInt32Value(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_NONE); SetUInt32Value(UNIT_FIELD_MOUNTDISPLAYID, 0); // if creature is mounted on a virtual mount, remove it at death @@ -1590,13 +1641,29 @@ void Creature::setDeathState(DeathState s) UpdateMovementFlags(); - CreatureTemplate const* cinfo = GetCreatureTemplate(); - SetUInt32Value(UNIT_NPC_FLAGS, cinfo->npcflag); ClearUnitState(uint32(UNIT_STATE_ALL_STATE & ~UNIT_STATE_IGNORE_PATHFINDING)); - SetMeleeDamageSchool(SpellSchools(cinfo->dmgschool)); + + if (!IsPet()) + { + CreatureData const* creatureData = GetCreatureData(); + CreatureTemplate const* cinfo = GetCreatureTemplate(); + + uint32 npcflag, unit_flags, dynamicflags; + ObjectMgr::ChooseCreatureFlags(cinfo, npcflag, unit_flags, dynamicflags, creatureData); + + SetUInt32Value(UNIT_NPC_FLAGS, npcflag); + SetUInt32Value(UNIT_FIELD_FLAGS, unit_flags); + SetUInt32Value(UNIT_DYNAMIC_FLAGS, dynamicflags); + + RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_IN_COMBAT); + + SetMeleeDamageSchool(SpellSchools(cinfo->dmgschool)); + + if (creatureData && GetPhaseMask() != creatureData->phaseMask) + SetPhaseMask(creatureData->phaseMask, false); + } + Motion_Initialize(); - if (GetCreatureData() && GetPhaseMask() != GetCreatureData()->phaseMask) - SetPhaseMask(GetCreatureData()->phaseMask, false); Unit::setDeathState(ALIVE); LoadCreaturesAddon(); } @@ -2082,6 +2149,11 @@ bool Creature::CanCreatureAttack(Unit const* victim, bool /*force*/) const if (GetMap()->IsDungeon()) return true; + // if the mob is actively being damaged, do not reset due to distance unless it's a world boss + if (!isWorldBoss()) + if (time(NULL) - GetLastDamagedTime() <= MAX_AGGRO_RESET_TIME) + return true; + //Use AttackDistance in distance check if threat radius is lower. This prevents creature bounce in and out of combat every update tick. float dist = std::max(GetAttackDistance(victim), sWorld->getFloatConfig(CONFIG_THREAT_RADIUS)) + m_CombatDistance; @@ -2677,39 +2749,117 @@ void Creature::SetDisplayId(uint32 modelId) void Creature::SetTarget(ObjectGuid guid) { - if (!_focusSpell) + if (!IsFocusing()) SetGuidValue(UNIT_FIELD_TARGET, guid); } -void Creature::FocusTarget(Spell const* focusSpell, WorldObject const* target) +bool Creature::FocusTarget(Spell const* focusSpell, WorldObject const* target) { // already focused if (_focusSpell) - return; + return false; + + if ((!target || target == this) && !focusSpell->GetCastTime()) // instant cast, untargeted (or self-targeted) spell doesn't need any facing updates + return false; _focusSpell = focusSpell; - SetGuidValue(UNIT_FIELD_TARGET, target->GetGUID()); - if (focusSpell->GetSpellInfo()->HasAttribute(SPELL_ATTR5_DONT_TURN_DURING_CAST)) - AddUnitState(UNIT_STATE_ROTATING); - // Set serverside orientation if needed (needs to be after attribute check) - SetInFront(target); + // "instant" creature casts that require re-targeting will be delayed by a short moment to prevent facing bugs + bool shouldDelay = false; + + // set target, then force send update packet to players if it changed to provide appropriate facing + ObjectGuid newTarget = target ? target->GetGUID() : ObjectGuid::Empty; + if (GetGuidValue(UNIT_FIELD_TARGET) != newTarget) + { + SetGuidValue(UNIT_FIELD_TARGET, newTarget); + if (target) + SetFacingToObject(target); + + if ( // here we determine if the (relatively expensive) forced update is worth it, or whether we can afford to wait until the scheduled update tick + ( // only require instant update for spells that actually have a visual + focusSpell->GetSpellInfo()->SpellVisual[0] || + focusSpell->GetSpellInfo()->SpellVisual[1] + ) && ( + !focusSpell->GetCastTime() || // if the spell is instant cast + focusSpell->GetSpellInfo()->HasAttribute(SPELL_ATTR5_DONT_TURN_DURING_CAST) // client gets confused if we attempt to turn at the regularly scheduled update packet + ) + ) + { + const MapRefManager& mapPlayers = GetMap()->GetPlayers(); + for (MapRefManager::const_iterator it = mapPlayers.begin(); it != mapPlayers.end(); ++it) + if (Player* player = (*it).GetSource()) + { + // only update players that can both see us, and are actually in combat with us (this is a performance tradeoff) + if (player->CanSeeOrDetect(this, false, true) && IsInCombatWith(player)) + { + SendUpdateToPlayer(player); + shouldDelay = true; + } + } + if (shouldDelay) + shouldDelay = !(focusSpell->IsTriggered() || focusSpell->GetCastTime() || focusSpell->GetSpellInfo()->IsChanneled()); + + } + } + + // tell the creature that it should reacquire its current target after the cast is done (this is handled in ::Attack) + MustReacquireTarget(); + + bool canTurnDuringCast = !focusSpell->GetSpellInfo()->HasAttribute(SPELL_ATTR5_DONT_TURN_DURING_CAST); + // Face the target - we need to do this before the unit state is modified for no-turn spells + if (target) + SetInFront(target); + else if (!canTurnDuringCast) + if(Unit* victim = GetVictim()) + SetInFront(victim); // ensure server-side orientation is correct at beginning of cast + + if (!canTurnDuringCast) + AddUnitState(UNIT_STATE_CANNOT_TURN); + + return shouldDelay; +} + +bool Creature::IsFocusing(Spell const* focusSpell, bool withDelay) +{ + if (!IsAlive()) // dead creatures cannot focus + { + ReleaseFocus(nullptr, false); + return false; + } + + if (focusSpell && (focusSpell != _focusSpell)) + return false; + + if (!_focusSpell) + { + if (!withDelay || !_focusDelay) + return false; + if (GetMSTimeDiffToNow(_focusDelay) > 1000) // @todo figure out if we can get rid of this magic number somehow + { + _focusDelay = 0; // save checks in the future + return false; + } + } + + return true; } -void Creature::ReleaseFocus(Spell const* focusSpell) +void Creature::ReleaseFocus(Spell const* focusSpell, bool withDelay) { + if (!_focusSpell) + return; + // focused to something else - if (focusSpell != _focusSpell) + if (focusSpell && focusSpell != _focusSpell) return; - _focusSpell = NULL; - if (Unit* victim = GetVictim()) - SetGuidValue(UNIT_FIELD_TARGET, victim->GetGUID()); - else - SetGuidValue(UNIT_FIELD_TARGET, ObjectGuid::Empty); + SetGuidValue(UNIT_FIELD_TARGET, ObjectGuid::Empty); + + if (_focusSpell->GetSpellInfo()->HasAttribute(SPELL_ATTR5_DONT_TURN_DURING_CAST)) + ClearUnitState(UNIT_STATE_CANNOT_TURN); - if (focusSpell->GetSpellInfo()->HasAttribute(SPELL_ATTR5_DONT_TURN_DURING_CAST)) - ClearUnitState(UNIT_STATE_ROTATING); + _focusSpell = nullptr; + _focusDelay = withDelay ? getMSTime() : 0; // don't allow re-target right away to prevent visual bugs } void Creature::StartPickPocketRefillTimer() diff --git a/src/server/game/Entities/Creature/Creature.h b/src/server/game/Entities/Creature/Creature.h index 966944e099f..49bd854ef2f 100644 --- a/src/server/game/Entities/Creature/Creature.h +++ b/src/server/game/Entities/Creature/Creature.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -39,23 +39,25 @@ class WorldSession; enum CreatureFlagsExtra { - CREATURE_FLAG_EXTRA_INSTANCE_BIND = 0x00000001, // creature kill bind instance with killer and killer's group - CREATURE_FLAG_EXTRA_CIVILIAN = 0x00000002, // not aggro (ignore faction/reputation hostility) - CREATURE_FLAG_EXTRA_NO_PARRY = 0x00000004, // creature can't parry - CREATURE_FLAG_EXTRA_NO_PARRY_HASTEN = 0x00000008, // creature can't counter-attack at parry - CREATURE_FLAG_EXTRA_NO_BLOCK = 0x00000010, // creature can't block - CREATURE_FLAG_EXTRA_NO_CRUSH = 0x00000020, // creature can't do crush attacks - CREATURE_FLAG_EXTRA_NO_XP_AT_KILL = 0x00000040, // creature kill not provide XP - CREATURE_FLAG_EXTRA_TRIGGER = 0x00000080, // trigger creature - CREATURE_FLAG_EXTRA_NO_TAUNT = 0x00000100, // creature is immune to taunt auras and effect attack me - CREATURE_FLAG_EXTRA_WORLDEVENT = 0x00004000, // custom flag for world event creatures (left room for merging) - CREATURE_FLAG_EXTRA_GUARD = 0x00008000, // Creature is guard - CREATURE_FLAG_EXTRA_NO_CRIT = 0x00020000, // creature can't do critical strikes - CREATURE_FLAG_EXTRA_NO_SKILLGAIN = 0x00040000, // creature won't increase weapon skills - CREATURE_FLAG_EXTRA_TAUNT_DIMINISH = 0x00080000, // Taunt is a subject to diminishing returns on this creautre - CREATURE_FLAG_EXTRA_ALL_DIMINISH = 0x00100000, // Creature is subject to all diminishing returns as player are - CREATURE_FLAG_EXTRA_DUNGEON_BOSS = 0x10000000, // creature is a dungeon boss (SET DYNAMICALLY, DO NOT ADD IN DB) - CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING = 0x20000000 // creature ignore pathfinding + CREATURE_FLAG_EXTRA_INSTANCE_BIND = 0x00000001, // creature kill bind instance with killer and killer's group + CREATURE_FLAG_EXTRA_CIVILIAN = 0x00000002, // not aggro (ignore faction/reputation hostility) + CREATURE_FLAG_EXTRA_NO_PARRY = 0x00000004, // creature can't parry + CREATURE_FLAG_EXTRA_NO_PARRY_HASTEN = 0x00000008, // creature can't counter-attack at parry + CREATURE_FLAG_EXTRA_NO_BLOCK = 0x00000010, // creature can't block + CREATURE_FLAG_EXTRA_NO_CRUSH = 0x00000020, // creature can't do crush attacks + CREATURE_FLAG_EXTRA_NO_XP_AT_KILL = 0x00000040, // creature kill not provide XP + CREATURE_FLAG_EXTRA_TRIGGER = 0x00000080, // trigger creature + CREATURE_FLAG_EXTRA_NO_TAUNT = 0x00000100, // creature is immune to taunt auras and effect attack me + CREATURE_FLAG_EXTRA_WORLDEVENT = 0x00004000, // custom flag for world event creatures (left room for merging) + CREATURE_FLAG_EXTRA_GUARD = 0x00008000, // Creature is guard + CREATURE_FLAG_EXTRA_NO_CRIT = 0x00020000, // creature can't do critical strikes + CREATURE_FLAG_EXTRA_NO_SKILLGAIN = 0x00040000, // creature won't increase weapon skills + CREATURE_FLAG_EXTRA_TAUNT_DIMINISH = 0x00080000, // Taunt is a subject to diminishing returns on this creautre + CREATURE_FLAG_EXTRA_ALL_DIMINISH = 0x00100000, // creature is subject to all diminishing returns as player are + CREATURE_FLAG_EXTRA_NO_PLAYER_DAMAGE_REQ = 0x00200000, // creature does not need to take player damage for kill credit + CREATURE_FLAG_EXTRA_DUNGEON_BOSS = 0x10000000, // creature is a dungeon boss (SET DYNAMICALLY, DO NOT ADD IN DB) + CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING = 0x20000000, // creature ignore pathfinding + CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK = 0x40000000 // creature is immune to knockback effects }; #define CREATURE_FLAG_EXTRA_DB_ALLOWED (CREATURE_FLAG_EXTRA_INSTANCE_BIND | CREATURE_FLAG_EXTRA_CIVILIAN | \ @@ -63,7 +65,7 @@ enum CreatureFlagsExtra CREATURE_FLAG_EXTRA_NO_CRUSH | CREATURE_FLAG_EXTRA_NO_XP_AT_KILL | CREATURE_FLAG_EXTRA_TRIGGER | \ CREATURE_FLAG_EXTRA_NO_TAUNT | CREATURE_FLAG_EXTRA_WORLDEVENT | CREATURE_FLAG_EXTRA_NO_CRIT | \ CREATURE_FLAG_EXTRA_NO_SKILLGAIN | CREATURE_FLAG_EXTRA_TAUNT_DIMINISH | CREATURE_FLAG_EXTRA_ALL_DIMINISH | \ - CREATURE_FLAG_EXTRA_GUARD | CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING) + CREATURE_FLAG_EXTRA_GUARD | CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING | CREATURE_FLAG_EXTRA_NO_PLAYER_DAMAGE_REQ | CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK) #define CREATURE_REGEN_INTERVAL 2 * IN_MILLISECONDS @@ -534,7 +536,7 @@ class Creature : public Unit, public GridObject<Creature>, public MapObject void setDeathState(DeathState s) override; // override virtual Unit::setDeathState bool LoadFromDB(ObjectGuid::LowType spawnId, Map* map) { return LoadCreatureFromDB(spawnId, map, false); } - bool LoadCreatureFromDB(ObjectGuid::LowType spawnId, Map* map, bool addToMap = true); + bool LoadCreatureFromDB(ObjectGuid::LowType spawnId, Map* map, bool addToMap = true, bool allowDuplicate = false); void SaveToDB(); // overriden in Pet virtual void SaveToDB(uint32 mapid, uint8 spawnMask, uint32 phaseMask); @@ -605,6 +607,7 @@ class Creature : public Unit, public GridObject<Creature>, public MapObject float GetRespawnRadius() const { return m_respawnradius; } void SetRespawnRadius(float dist) { m_respawnradius = dist; } + void DoImmediateBoundaryCheck() { m_boundaryCheckTime = 0; } uint32 GetCombatPulseDelay() const { return m_combatPulseDelay; } void SetCombatPulseDelay(uint32 delay) // (secs) interval at which the creature pulses the entire zone into combat (only works in dungeons) { @@ -655,7 +658,7 @@ class Creature : public Unit, public GridObject<Creature>, public MapObject void SetDisableReputationGain(bool disable) { DisableReputationGain = disable; } bool IsReputationGainDisabled() const { return DisableReputationGain; } - bool IsDamageEnoughForLootingAndReward() const { return m_PlayerDamageReq == 0; } + bool IsDamageEnoughForLootingAndReward() const { return (m_creatureInfo->flags_extra & CREATURE_FLAG_EXTRA_NO_PLAYER_DAMAGE_REQ) || (m_PlayerDamageReq == 0); } void LowerPlayerDamageReq(uint32 unDamage); void ResetPlayerDamageReq() { m_PlayerDamageReq = GetHealth() / 2; } uint32 m_PlayerDamageReq; @@ -671,8 +674,9 @@ class Creature : public Unit, public GridObject<Creature>, public MapObject // Handling caster facing during spellcast void SetTarget(ObjectGuid guid) override; - void FocusTarget(Spell const* focusSpell, WorldObject const* target); - void ReleaseFocus(Spell const* focusSpell); + bool FocusTarget(Spell const* focusSpell, WorldObject const* target); + bool IsFocusing(Spell const* focusSpell = nullptr, bool withDelay = false); + void ReleaseFocus(Spell const* focusSpell = nullptr, bool withDelay = true); CreatureTextRepeatIds GetTextRepeatGroup(uint8 textGroup); void SetTextRepeatId(uint8 textGroup, uint8 id); @@ -698,6 +702,7 @@ class Creature : public Unit, public GridObject<Creature>, public MapObject uint32 m_respawnDelay; // (secs) delay between corpse disappearance and respawning uint32 m_corpseDelay; // (secs) delay between death and corpse disappearance float m_respawnradius; + uint32 m_boundaryCheckTime; // (msecs) remaining time for next evade boundary check uint32 m_combatPulseTime; // (msecs) remaining time for next zone-in-combat pulse uint32 m_combatPulseDelay; // (secs) how often the creature puts the entire zone in combat (only works in dungeons) @@ -744,6 +749,7 @@ class Creature : public Unit, public GridObject<Creature>, public MapObject bool TriggerJustRespawned; Spell const* _focusSpell; ///> Locks the target during spell cast for proper facing + uint32 _focusDelay; CreatureTextRepeatGroup m_textRepeat; }; diff --git a/src/server/game/Entities/Creature/CreatureGroups.cpp b/src/server/game/Entities/Creature/CreatureGroups.cpp index e8ce0acdc86..9f26c927374 100644 --- a/src/server/game/Entities/Creature/CreatureGroups.cpp +++ b/src/server/game/Entities/Creature/CreatureGroups.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Creature/CreatureGroups.h b/src/server/game/Entities/Creature/CreatureGroups.h index 3de1370379b..7b16585a996 100644 --- a/src/server/game/Entities/Creature/CreatureGroups.h +++ b/src/server/game/Entities/Creature/CreatureGroups.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Creature/GossipDef.cpp b/src/server/game/Entities/Creature/GossipDef.cpp index db67f1f74f1..711196f6a2b 100644 --- a/src/server/game/Entities/Creature/GossipDef.cpp +++ b/src/server/game/Entities/Creature/GossipDef.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -408,10 +408,10 @@ void PlayerMenu::SendQuestGiverQuestDetails(Quest const* quest, ObjectGuid npcGU data << questTitle; data << questDetails; data << questObjectives; - data << uint8(activateAccept ? 1 : 0); // auto finish + data << uint8(activateAccept ? 1 : 0); // CGQuestInfo::m_autoLaunched data << uint32(quest->GetFlags()); // 3.3.3 questFlags data << uint32(quest->GetSuggestedPlayers()); - data << uint8(0); // IsFinished? value is sent back to server in quest accept packet + data << uint8(0); // CGQuestInfo::m_startQuestCheat if (quest->HasFlag(QUEST_FLAGS_HIDDEN_REWARDS)) { diff --git a/src/server/game/Entities/Creature/GossipDef.h b/src/server/game/Entities/Creature/GossipDef.h index 8e6ce9cd822..1e64e83c86a 100644 --- a/src/server/game/Entities/Creature/GossipDef.h +++ b/src/server/game/Entities/Creature/GossipDef.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Creature/TemporarySummon.cpp b/src/server/game/Entities/Creature/TemporarySummon.cpp index 46422444bbb..8bf3a1e2846 100644 --- a/src/server/game/Entities/Creature/TemporarySummon.cpp +++ b/src/server/game/Entities/Creature/TemporarySummon.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Creature/TemporarySummon.h b/src/server/game/Entities/Creature/TemporarySummon.h index 68c6cbb70e5..6d058f405a8 100644 --- a/src/server/game/Entities/Creature/TemporarySummon.h +++ b/src/server/game/Entities/Creature/TemporarySummon.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -72,9 +72,10 @@ class Minion : public TempSummon Unit* GetOwner() const { return m_owner; } float GetFollowAngle() const override { return m_followAngle; } void SetFollowAngle(float angle) { m_followAngle = angle; } - bool IsPetGhoul() const {return GetEntry() == 26125;} // Ghoul may be guardian or pet - bool IsSpiritWolf() const {return GetEntry() == 29264;} // Spirit wolf from feral spirits + bool IsPetGhoul() const { return GetEntry() == 26125; } // Ghoul may be guardian or pet + bool IsSpiritWolf() const { return GetEntry() == 29264; } // Spirit wolf from feral spirits bool IsGuardianPet() const; + bool IsRisenAlly() const { return GetEntry() == 30230; } protected: Unit* const m_owner; float m_followAngle; diff --git a/src/server/game/Entities/DynamicObject/DynamicObject.cpp b/src/server/game/Entities/DynamicObject/DynamicObject.cpp index 3d92f9e18cf..8ac0a24a08d 100644 --- a/src/server/game/Entities/DynamicObject/DynamicObject.cpp +++ b/src/server/game/Entities/DynamicObject/DynamicObject.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/DynamicObject/DynamicObject.h b/src/server/game/Entities/DynamicObject/DynamicObject.h index 44c771c77c4..9443a5b5b89 100644 --- a/src/server/game/Entities/DynamicObject/DynamicObject.h +++ b/src/server/game/Entities/DynamicObject/DynamicObject.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/GameObject/GameObject.cpp b/src/server/game/Entities/GameObject/GameObject.cpp index c1ec2294c3d..1acfeacbf83 100644 --- a/src/server/game/Entities/GameObject/GameObject.cpp +++ b/src/server/game/Entities/GameObject/GameObject.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -1353,7 +1353,15 @@ void GameObject::Use(Unit* user) break; } - player->KillCreditGO(info->entry, GetGUID()); + if (Group* group = player->GetGroup()) + { + for (GroupReference const* itr = group->GetFirstMember(); itr != nullptr; itr = itr->next()) + if (Player* member = itr->GetSource()) + if (member->IsAtGroupRewardDistance(this)) + member->KillCreditGO(info->entry, GetGUID()); + } + else + player->KillCreditGO(info->entry, GetGUID()); } if (uint32 trapEntry = info->goober.linkedTrapId) @@ -1391,7 +1399,10 @@ void GameObject::Use(Unit* user) player->SendCinematicStart(info->camera.cinematicId); if (info->camera.eventID) + { GetMap()->ScriptsStart(sEventScripts, info->camera.eventID, player, this); + EventInform(info->camera.eventID, user); + } return; } @@ -1803,6 +1814,8 @@ void GameObject::CastSpell(Unit* target, uint32 spellId, bool triggered /*= true if (Unit* owner = GetOwner()) { trigger->setFaction(owner->getFaction()); + if (owner->HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PVP_ATTACKABLE)) + trigger->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PVP_ATTACKABLE); // needed for GO casts for proper target validation checks trigger->SetOwnerGUID(owner->GetGUID()); trigger->CastSpell(target ? target : trigger, spellInfo, triggered, nullptr, nullptr, owner->GetGUID()); diff --git a/src/server/game/Entities/GameObject/GameObject.h b/src/server/game/Entities/GameObject/GameObject.h index a744efbe1e3..7be78556a50 100644 --- a/src/server/game/Entities/GameObject/GameObject.h +++ b/src/server/game/Entities/GameObject/GameObject.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Item/Container/Bag.cpp b/src/server/game/Entities/Item/Container/Bag.cpp index 1d2fd9b2804..c9702d6ccc6 100644 --- a/src/server/game/Entities/Item/Container/Bag.cpp +++ b/src/server/game/Entities/Item/Container/Bag.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Item/Container/Bag.h b/src/server/game/Entities/Item/Container/Bag.h index ead059030b6..5bfafa4238c 100644 --- a/src/server/game/Entities/Item/Container/Bag.h +++ b/src/server/game/Entities/Item/Container/Bag.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Item/Item.cpp b/src/server/game/Entities/Item/Item.cpp index 1b7914fd85f..70fa4714547 100644 --- a/src/server/game/Entities/Item/Item.cpp +++ b/src/server/game/Entities/Item/Item.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Item/Item.h b/src/server/game/Entities/Item/Item.h index 1eb6530a996..378d7f5e2e4 100644 --- a/src/server/game/Entities/Item/Item.h +++ b/src/server/game/Entities/Item/Item.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Item/ItemEnchantmentMgr.cpp b/src/server/game/Entities/Item/ItemEnchantmentMgr.cpp index 042d66d7f9e..a7b410bc04b 100644 --- a/src/server/game/Entities/Item/ItemEnchantmentMgr.cpp +++ b/src/server/game/Entities/Item/ItemEnchantmentMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Item/ItemEnchantmentMgr.h b/src/server/game/Entities/Item/ItemEnchantmentMgr.h index 253903b625e..2d5c27177b1 100644 --- a/src/server/game/Entities/Item/ItemEnchantmentMgr.h +++ b/src/server/game/Entities/Item/ItemEnchantmentMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Item/ItemPrototype.h b/src/server/game/Entities/Item/ItemPrototype.h index 8df0551dbe6..48ef9e81016 100644 --- a/src/server/game/Entities/Item/ItemPrototype.h +++ b/src/server/game/Entities/Item/ItemPrototype.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Object/Object.cpp b/src/server/game/Entities/Object/Object.cpp index afb987f1980..4877ff094e1 100644 --- a/src/server/game/Entities/Object/Object.cpp +++ b/src/server/game/Entities/Object/Object.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -2426,7 +2426,11 @@ void WorldObject::DestroyForNearbyPlayers() if (isType(TYPEMASK_UNIT) && ToUnit()->GetCharmerGUID() == player->GetGUID()) /// @todo this is for puppet continue; - DestroyForPlayer(player); + if (GetTypeId() == TYPEID_UNIT) + DestroyForPlayer(player, ToUnit()->IsDuringRemoveFromWorld() && ToCreature()->isDead()); // at remove from world (destroy) show kill animation + else + DestroyForPlayer(player); + player->m_clientGUIDs.erase(GetGUID()); } } diff --git a/src/server/game/Entities/Object/Object.h b/src/server/game/Entities/Object/Object.h index c9e3d069218..419044081e3 100644 --- a/src/server/game/Entities/Object/Object.h +++ b/src/server/game/Entities/Object/Object.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Object/ObjectDefines.h b/src/server/game/Entities/Object/ObjectDefines.h index 9bf7fb00352..1873d912dca 100644 --- a/src/server/game/Entities/Object/ObjectDefines.h +++ b/src/server/game/Entities/Object/ObjectDefines.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Object/ObjectGuid.cpp b/src/server/game/Entities/Object/ObjectGuid.cpp index 552705d8df8..3e2bd000b6e 100644 --- a/src/server/game/Entities/Object/ObjectGuid.cpp +++ b/src/server/game/Entities/Object/ObjectGuid.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Object/ObjectGuid.h b/src/server/game/Entities/Object/ObjectGuid.h index 74fffe09796..44644421567 100644 --- a/src/server/game/Entities/Object/ObjectGuid.h +++ b/src/server/game/Entities/Object/ObjectGuid.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Object/ObjectPosSelector.cpp b/src/server/game/Entities/Object/ObjectPosSelector.cpp index 300d1a0bf42..7f17c6e03e5 100644 --- a/src/server/game/Entities/Object/ObjectPosSelector.cpp +++ b/src/server/game/Entities/Object/ObjectPosSelector.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Object/ObjectPosSelector.h b/src/server/game/Entities/Object/ObjectPosSelector.h index 06174399a03..26a23678009 100644 --- a/src/server/game/Entities/Object/ObjectPosSelector.h +++ b/src/server/game/Entities/Object/ObjectPosSelector.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Object/Position.cpp b/src/server/game/Entities/Object/Position.cpp index ae559cbac3a..2412e67cf14 100644 --- a/src/server/game/Entities/Object/Position.cpp +++ b/src/server/game/Entities/Object/Position.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Entities/Object/Position.h b/src/server/game/Entities/Object/Position.h index b3e474fa96b..18d356c28d4 100644 --- a/src/server/game/Entities/Object/Position.h +++ b/src/server/game/Entities/Object/Position.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Entities/Object/Updates/UpdateData.cpp b/src/server/game/Entities/Object/Updates/UpdateData.cpp index ce27319de74..34e9923797d 100644 --- a/src/server/game/Entities/Object/Updates/UpdateData.cpp +++ b/src/server/game/Entities/Object/Updates/UpdateData.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Object/Updates/UpdateData.h b/src/server/game/Entities/Object/Updates/UpdateData.h index 236ee2a7de5..132fda9f1d9 100644 --- a/src/server/game/Entities/Object/Updates/UpdateData.h +++ b/src/server/game/Entities/Object/Updates/UpdateData.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Object/Updates/UpdateFieldFlags.cpp b/src/server/game/Entities/Object/Updates/UpdateFieldFlags.cpp index 96316397584..c4e45338dd3 100644 --- a/src/server/game/Entities/Object/Updates/UpdateFieldFlags.cpp +++ b/src/server/game/Entities/Object/Updates/UpdateFieldFlags.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Entities/Object/Updates/UpdateFieldFlags.h b/src/server/game/Entities/Object/Updates/UpdateFieldFlags.h index 1e20f9488e8..0b4e59f4f9b 100644 --- a/src/server/game/Entities/Object/Updates/UpdateFieldFlags.h +++ b/src/server/game/Entities/Object/Updates/UpdateFieldFlags.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Entities/Object/Updates/UpdateFields.h b/src/server/game/Entities/Object/Updates/UpdateFields.h index 39c88b282c4..8e7fc0d3d50 100644 --- a/src/server/game/Entities/Object/Updates/UpdateFields.h +++ b/src/server/game/Entities/Object/Updates/UpdateFields.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Object/Updates/UpdateMask.h b/src/server/game/Entities/Object/Updates/UpdateMask.h index de69816a6e2..7c39870cbd6 100644 --- a/src/server/game/Entities/Object/Updates/UpdateMask.h +++ b/src/server/game/Entities/Object/Updates/UpdateMask.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Pet/Pet.cpp b/src/server/game/Entities/Pet/Pet.cpp index a399600d2f2..0da63c5e500 100644 --- a/src/server/game/Entities/Pet/Pet.cpp +++ b/src/server/game/Entities/Pet/Pet.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Pet/Pet.h b/src/server/game/Entities/Pet/Pet.h index c8e95a06a2c..b0863a371e6 100644 --- a/src/server/game/Entities/Pet/Pet.h +++ b/src/server/game/Entities/Pet/Pet.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Pet/PetDefines.h b/src/server/game/Entities/Pet/PetDefines.h index 5ad0e7a2fef..9b0897f8268 100644 --- a/src/server/game/Entities/Pet/PetDefines.h +++ b/src/server/game/Entities/Pet/PetDefines.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Player/KillRewarder.cpp b/src/server/game/Entities/Player/KillRewarder.cpp index ad2f8f641ea..7ddb8f4e59d 100644 --- a/src/server/game/Entities/Player/KillRewarder.cpp +++ b/src/server/game/Entities/Player/KillRewarder.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Entities/Player/KillRewarder.h b/src/server/game/Entities/Player/KillRewarder.h index 577a8ffea20..08530de900c 100644 --- a/src/server/game/Entities/Player/KillRewarder.h +++ b/src/server/game/Entities/Player/KillRewarder.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index ceab7d06c96..c7f674ec72c 100644 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -1242,6 +1242,9 @@ void Player::Update(uint32 p_time) if (charmer->GetTypeId() == TYPEID_UNIT && charmer->IsAlive()) UpdateCharmedAI(); + if (GetAI() && IsAIEnabled) + GetAI()->UpdateAI(p_time); + // Update items that have just a limited lifetime if (now > m_Last_tick) UpdateItemDuration(uint32(now - m_Last_tick)); @@ -1476,8 +1479,8 @@ void Player::Update(uint32 p_time) _pendingBindTimer -= p_time; } - // not auto-free ghost from body in instances - if (m_deathTimer > 0 && !GetBaseMap()->Instanceable() && !HasAuraType(SPELL_AURA_PREVENT_RESURRECTION)) + // not auto-free ghost from body in instances or if its affected by risen ally + if (m_deathTimer > 0 && !GetBaseMap()->Instanceable() && !HasAuraType(SPELL_AURA_PREVENT_RESURRECTION) && !IsGhouled()) { if (p_time >= m_deathTimer) { @@ -1913,7 +1916,7 @@ bool Player::TeleportTo(uint32 mapid, float x, float y, float z, float orientati // Check enter rights before map getting to avoid creating instance copy for player // this check not dependent from map instance copy and same for all instance copies of selected map - if (!sMapMgr->CanPlayerEnter(mapid, this, false)) + if (sMapMgr->PlayerCannotEnter(mapid, this, false)) return false; //I think this always returns true. Correct me if I am wrong. @@ -2157,7 +2160,7 @@ bool Player::IsImmunedToSpellEffect(SpellInfo const* spellInfo, uint32 index) co return true; if (spellInfo->Effects[index].IsEffect(SPELL_EFFECT_ATTACK_ME)) return true; - + return Unit::IsImmunedToSpellEffect(spellInfo, index); } @@ -2403,7 +2406,7 @@ bool Player::CanInteractWithQuestGiver(Object* questGiver) return false; } -Creature* Player::GetNPCIfCanInteractWith(ObjectGuid guid, uint32 npcflagmask) +Creature* Player::GetNPCIfCanInteractWith(ObjectGuid const& guid, uint32 npcflagmask) { // unit checks if (!guid) @@ -2447,7 +2450,21 @@ Creature* Player::GetNPCIfCanInteractWith(ObjectGuid guid, uint32 npcflagmask) return creature; } -GameObject* Player::GetGameObjectIfCanInteractWith(ObjectGuid guid, GameobjectTypes type) const +GameObject* Player::GetGameObjectIfCanInteractWith(ObjectGuid const& guid) const +{ + if (GameObject* go = GetMap()->GetGameObject(guid)) + { + if (go->IsWithinDistInMap(this, go->GetInteractionDistance())) + return go; + + TC_LOG_DEBUG("maps", "GetGameObjectIfCanInteractWith: GameObject '%s' [GUID: %u] is too far away from player %s [GUID: %u] to be used by him (distance=%f, maximal %f is allowed)", go->GetGOInfo()->name.c_str(), + go->GetGUID().GetCounter(), GetName().c_str(), GetGUID().GetCounter(), go->GetDistance(this), go->GetInteractionDistance()); + } + + return nullptr; +} + +GameObject* Player::GetGameObjectIfCanInteractWith(ObjectGuid const& guid, GameobjectTypes type) const { if (GameObject* go = GetMap()->GetGameObject(guid)) { @@ -2456,12 +2473,12 @@ GameObject* Player::GetGameObjectIfCanInteractWith(ObjectGuid guid, GameobjectTy if (go->IsWithinDistInMap(this, go->GetInteractionDistance())) return go; - TC_LOG_DEBUG("maps", "GetGameObjectIfCanInteractWith: GameObject '%s' [GUID: %u] is too far away from player %s [GUID: %u] to be used by him (distance=%f, maximal 10 is allowed)", go->GetGOInfo()->name.c_str(), - go->GetGUID().GetCounter(), GetName().c_str(), GetGUID().GetCounter(), go->GetDistance(this)); + TC_LOG_DEBUG("maps", "GetGameObjectIfCanInteractWith: GameObject '%s' [GUID: %u] is too far away from player %s [GUID: %u] to be used by him (distance=%f, maximal %f is allowed)", go->GetGOInfo()->name.c_str(), + go->GetGUID().GetCounter(), GetName().c_str(), GetGUID().GetCounter(), go->GetDistance(this), go->GetInteractionDistance()); } } - return NULL; + return nullptr; } bool Player::IsUnderWater() const @@ -4665,6 +4682,7 @@ void Player::ResurrectPlayer(float restore_percent, bool applySickness) // remove death flag + set aura SetByteValue(UNIT_FIELD_BYTES_1, 3, 0x00); + RemoveFlag(PLAYER_FLAGS, PLAYER_FLAGS_IS_OUT_OF_BOUNDS); // This must be called always even on Players with race != RACE_NIGHTELF in case of faction change RemoveAurasDueToSpell(20584); // RACE_NIGHTELF speed bonuses @@ -4731,6 +4749,32 @@ void Player::ResurrectPlayer(float restore_percent, bool applySickness) } } +void Player::SendGhoulResurrectRequest(Player* target) +{ + target->m_ghoulResurrectPlayerGUID = GetGUID(); + + WorldPacket data(SMSG_RESURRECT_REQUEST, 8 + 4 + 1 + 1); + data << uint64(GetGUID()); + data << uint32(0); + data << uint8(0); + data << uint8(0); + target->GetSession()->SendPacket(&data); +} + +void Player::GhoulResurrect() +{ + CastSpell(this, 46619 /*SPELL_DK_RAISE_ALLY*/, true, nullptr, nullptr, m_ghoulResurrectPlayerGUID); + + m_ghoulResurrectPlayerGUID = ObjectGuid::Empty; +} + +void Player::RemoveGhoul() +{ + if (IsGhouled()) + if (Creature* ghoul = ObjectAccessor::GetCreature(*this, m_ghoulResurrectGhoulGUID)) + ghoul->DespawnOrUnsummon(); // Raise Ally aura will handle unauras +} + void Player::KillPlayer() { if (IsFlying() && !GetTransport()) @@ -5059,10 +5103,10 @@ void Player::RepopAtGraveyard() // note: this can be called also when the player is alive // for example from WorldSession::HandleMovementOpcodes - AreaTableEntry const* zone = GetAreaEntryByAreaID(GetAreaId()); + AreaTableEntry const* zone = sAreaTableStore.LookupEntry(GetAreaId()); // Such zones are considered unreachable as a ghost and the player must be automatically revived - if ((!IsAlive() && zone && zone->flags & AREA_FLAG_NEED_FLY) || GetTransport() || GetPositionZ() < -500.0f) + if ((!IsAlive() && zone && zone->flags & AREA_FLAG_NEED_FLY) || GetTransport() || GetPositionZ() < GetMap()->GetMinHeight(GetPositionX(), GetPositionY())) { ResurrectPlayer(0.5f); SpawnCorpseBones(); @@ -5099,8 +5143,10 @@ void Player::RepopAtGraveyard() GetSession()->SendPacket(&data); } } - else if (GetPositionZ() < -500.0f) + else if (GetPositionZ() < GetMap()->GetMinHeight(GetPositionX(), GetPositionY())) TeleportTo(m_homebindMapId, m_homebindX, m_homebindY, m_homebindZ, GetOrientation()); + + RemoveFlag(PLAYER_FLAGS, PLAYER_FLAGS_IS_OUT_OF_BOUNDS); } bool Player::CanJoinConstantChannelInZone(ChatChannelsEntry const* channel, AreaTableEntry const* zone) @@ -5145,7 +5191,7 @@ void Player::UpdateLocalChannels(uint32 newZone) if (GetSession()->PlayerLoading() && !IsBeingTeleportedFar()) return; // The client handles it automatically after loading, but not after teleporting - AreaTableEntry const* current_zone = GetAreaEntryByAreaID(newZone); + AreaTableEntry const* current_zone = sAreaTableStore.LookupEntry(newZone); if (!current_zone) return; @@ -6386,22 +6432,32 @@ void Player::CheckAreaExploreAndOutdoor() return; bool isOutdoor; - uint16 areaFlag = GetBaseMap()->GetAreaFlag(GetPositionX(), GetPositionY(), GetPositionZ(), &isOutdoor); + uint32 areaId = GetBaseMap()->GetAreaId(GetPositionX(), GetPositionY(), GetPositionZ(), &isOutdoor); + AreaTableEntry const* areaEntry = sAreaTableStore.LookupEntry(areaId); if (sWorld->getBoolConfig(CONFIG_VMAP_INDOOR_CHECK) && !isOutdoor) RemoveAurasWithAttribute(SPELL_ATTR0_OUTDOORS_ONLY); - if (areaFlag == 0xffff) + if (!areaId) return; - int offset = areaFlag / 32; + + if (!areaEntry) + { + TC_LOG_ERROR("entities.player", "Player '%s' (%s) discovered unknown area (x: %f y: %f z: %f map: %u)", + GetName().c_str(), GetGUID().ToString().c_str(), GetPositionX(), GetPositionY(), GetPositionZ(), GetMapId()); + return; + } + + uint32 offset = areaEntry->exploreFlag / 32; if (offset >= PLAYER_EXPLORED_ZONES_SIZE) { - TC_LOG_ERROR("entities.player", "Wrong area flag %u in map data for (X: %f Y: %f) point to field PLAYER_EXPLORED_ZONES_1 + %u ( %u must be < %u ).", areaFlag, GetPositionX(), GetPositionY(), offset, offset, PLAYER_EXPLORED_ZONES_SIZE); + TC_LOG_ERROR("entities.player", "Player::CheckAreaExploreAndOutdoor: Wrong area flag %u in map data for (X: %f Y: %f) point to field PLAYER_EXPLORED_ZONES_1 + %u ( %u must be < %u ).", + areaEntry->exploreFlag, GetPositionX(), GetPositionY(), offset, offset, PLAYER_EXPLORED_ZONES_SIZE); return; } - uint32 val = (uint32)(1 << (areaFlag % 32)); + uint32 val = (uint32)(1 << (areaEntry->exploreFlag % 32)); uint32 currFields = GetUInt32Value(PLAYER_EXPLORED_ZONES_1 + offset); if (!(currFields & val)) @@ -6410,19 +6466,11 @@ void Player::CheckAreaExploreAndOutdoor() UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_EXPLORE_AREA); - AreaTableEntry const* areaEntry = GetAreaEntryByAreaFlagAndMap(areaFlag, GetMapId()); - if (!areaEntry) - { - TC_LOG_ERROR("entities.player", "Player %u discovered unknown area (x: %f y: %f z: %f map: %u", GetGUID().GetCounter(), GetPositionX(), GetPositionY(), GetPositionZ(), GetMapId()); - return; - } - if (areaEntry->area_level > 0) { - uint32 area = areaEntry->ID; if (getLevel() >= sWorld->getIntConfig(CONFIG_MAX_PLAYER_LEVEL)) { - SendExplorationExperience(area, 0); + SendExplorationExperience(areaId, 0); } else { @@ -6446,9 +6494,9 @@ void Player::CheckAreaExploreAndOutdoor() } GiveXP(XP, NULL); - SendExplorationExperience(area, XP); + SendExplorationExperience(areaId, XP); } - TC_LOG_DEBUG("entities.player", "Player %u discovered a new area: %u", GetGUID().GetCounter(), area); + TC_LOG_DEBUG("entities.player", "Player '%s' (%s) discovered a new area: %u", GetName().c_str(),GetGUID().ToString().c_str(), areaId); } } } @@ -7018,7 +7066,7 @@ void Player::UpdateArea(uint32 newArea) // so apply them accordingly m_areaUpdateId = newArea; - AreaTableEntry const* area = GetAreaEntryByAreaID(newArea); + AreaTableEntry const* area = sAreaTableStore.LookupEntry(newArea); pvpInfo.IsInFFAPvPArea = area && (area->flags & AREA_FLAG_ARENA); UpdatePvPState(true); @@ -7066,7 +7114,7 @@ void Player::UpdateZone(uint32 newZone, uint32 newArea) // zone changed, so area changed as well, update it UpdateArea(newArea); - AreaTableEntry const* zone = GetAreaEntryByAreaID(newZone); + AreaTableEntry const* zone = sAreaTableStore.LookupEntry(newZone); if (!zone) return; @@ -15609,13 +15657,7 @@ QuestStatus Player::GetQuestStatus(uint32 quest_id) const bool Player::CanShareQuest(uint32 quest_id) const { Quest const* qInfo = sObjectMgr->GetQuestTemplate(quest_id); - if (qInfo && qInfo->HasFlag(QUEST_FLAGS_SHARABLE)) - { - QuestStatusMap::const_iterator itr = m_QuestStatus.find(quest_id); - if (itr != m_QuestStatus.end()) - return itr->second.Status == QUEST_STATUS_INCOMPLETE; - } - return false; + return qInfo && qInfo->HasFlag(QUEST_FLAGS_SHARABLE) && IsActiveQuest(quest_id); } void Player::SetQuestStatus(uint32 questId, QuestStatus status, bool update /*= true*/) @@ -17096,7 +17138,7 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder) // NOW player must have valid map // load the player's map here if it's not already loaded - Map* map = sMapMgr->CreateMap(mapId, this); + Map* map = sMapMgr->CreateMap(mapId, this, instanceId); AreaTrigger const* areaTrigger = NULL; bool check = false; @@ -17107,8 +17149,28 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder) } else if (map->IsDungeon()) // if map is dungeon... { - if (!((InstanceMap*)map)->CanEnter(this) || !CheckInstanceLoginValid(map)) // ... and can't enter map, then look for entry point. + if (Map::EnterState denyReason = ((InstanceMap*)map)->CannotEnter(this)) // ... and can't enter map, then look for entry point. { + switch (denyReason) + { + case Map::CANNOT_ENTER_DIFFICULTY_UNAVAILABLE: + SendTransferAborted(map->GetId(), TRANSFER_ABORT_DIFFICULTY, map->GetDifficulty()); + break; + case Map::CANNOT_ENTER_INSTANCE_BIND_MISMATCH: + ChatHandler(GetSession()).PSendSysMessage(GetSession()->GetTrinityString(LANG_INSTANCE_BIND_MISMATCH), map->GetMapName()); + break; + case Map::CANNOT_ENTER_TOO_MANY_INSTANCES: + SendTransferAborted(map->GetId(), TRANSFER_ABORT_TOO_MANY_INSTANCES); + break; + case Map::CANNOT_ENTER_MAX_PLAYERS: + SendTransferAborted(map->GetId(), TRANSFER_ABORT_MAX_PLAYERS); + break; + case Map::CANNOT_ENTER_ZONE_IN_COMBAT: + SendTransferAborted(map->GetId(), TRANSFER_ABORT_ZONE_IN_COMBAT); + break; + default: + break; + } areaTrigger = sObjectMgr->GetGoBackTrigger(mapId); check = true; } @@ -17155,6 +17217,10 @@ bool Player::LoadFromDB(ObjectGuid guid, SQLQueryHolder *holder) SetMap(map); StoreRaidMapDifficulty(); + // now that map position is determined, check instance validity + if (!CheckInstanceValidity(true) && !IsInstanceLoginGameMasterException()) + m_InstanceValid = false; + // randomize first save time in range [CONFIG_INTERVAL_SAVE] around [CONFIG_INTERVAL_SAVE] // this must help in case next save after mass player load after server startup m_nextSave = urand(m_nextSave/2, m_nextSave*3/2); @@ -18309,8 +18375,9 @@ void Player::_LoadBoundInstances(PreparedQueryResult result) uint32 mapId = fields[2].GetUInt16(); uint32 instanceId = fields[0].GetUInt32(); uint8 difficulty = fields[3].GetUInt8(); + BindExtensionState extendState = BindExtensionState(fields[4].GetUInt8()); - time_t resetTime = time_t(fields[4].GetUInt32()); + time_t resetTime = time_t(fields[5].GetUInt32()); // the resettime for normal instances is only saved when the InstanceSave is unloaded // so the value read from the DB may be wrong here but only if the InstanceSave is loaded // and in that case it is not used @@ -18359,13 +18426,13 @@ void Player::_LoadBoundInstances(PreparedQueryResult result) // since non permanent binds are always solo bind, they can always be reset if (InstanceSave* save = sInstanceSaveMgr->AddInstanceSave(mapId, instanceId, Difficulty(difficulty), resetTime, !perm, true)) - BindToInstance(save, perm, true); + BindToInstance(save, perm, extendState, true); } while (result->NextRow()); } } -InstancePlayerBind* Player::GetBoundInstance(uint32 mapid, Difficulty difficulty) +InstancePlayerBind* Player::GetBoundInstance(uint32 mapid, Difficulty difficulty, bool withExpired) { // some instances only have one difficulty MapDifficulty const* mapDiff = GetDownscaledMapDifficultyData(mapid, difficulty); @@ -18374,9 +18441,9 @@ InstancePlayerBind* Player::GetBoundInstance(uint32 mapid, Difficulty difficulty BoundInstancesMap::iterator itr = m_boundInstances[difficulty].find(mapid); if (itr != m_boundInstances[difficulty].end()) - return &itr->second; - else - return NULL; + if (itr->second.extendState || withExpired) + return &itr->second; + return nullptr; } InstanceSave* Player::GetInstanceSave(uint32 mapid, bool raid) @@ -18419,24 +18486,32 @@ void Player::UnbindInstance(BoundInstancesMap::iterator &itr, Difficulty difficu } } -InstancePlayerBind* Player::BindToInstance(InstanceSave* save, bool permanent, bool load) +InstancePlayerBind* Player::BindToInstance(InstanceSave* save, bool permanent, BindExtensionState extendState, bool load) { if (save) { InstancePlayerBind& bind = m_boundInstances[save->GetDifficulty()][save->GetMapId()]; + if (extendState == EXTEND_STATE_KEEP) // special flag, keep the player's current extend state when updating for new boss down + { + if (save == bind.save) + extendState = bind.extendState; + else + extendState = EXTEND_STATE_NORMAL; + } if (!load) { if (bind.save) { // update the save when the group kills a boss - if (permanent != bind.perm || save != bind.save) + if (permanent != bind.perm || save != bind.save || extendState != bind.extendState) { PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_UPD_CHAR_INSTANCE); stmt->setUInt32(0, save->GetInstanceId()); stmt->setBool(1, permanent); - stmt->setUInt32(2, GetGUID().GetCounter()); - stmt->setUInt32(3, bind.save->GetInstanceId()); + stmt->setUInt8(2, extendState); + stmt->setUInt32(3, GetGUID().GetCounter()); + stmt->setUInt32(4, bind.save->GetInstanceId()); CharacterDatabase.Execute(stmt); } @@ -18448,6 +18523,7 @@ InstancePlayerBind* Player::BindToInstance(InstanceSave* save, bool permanent, b stmt->setUInt32(0, GetGUID().GetCounter()); stmt->setUInt32(1, save->GetInstanceId()); stmt->setBool(2, permanent); + stmt->setUInt8(3, extendState); CharacterDatabase.Execute(stmt); } @@ -18465,9 +18541,10 @@ InstancePlayerBind* Player::BindToInstance(InstanceSave* save, bool permanent, b bind.save = save; bind.perm = permanent; + bind.extendState = extendState; if (!load) TC_LOG_DEBUG("maps", "Player::BindToInstance: %s(%d) is now bound to map %d, instance %d, difficulty %d", GetName().c_str(), GetGUID().GetCounter(), save->GetMapId(), save->GetInstanceId(), save->GetDifficulty()); - sScriptMgr->OnPlayerBindToInstance(this, save->GetDifficulty(), save->GetMapId(), permanent); + sScriptMgr->OnPlayerBindToInstance(this, save->GetDifficulty(), save->GetMapId(), permanent, uint8(extendState)); return &bind; } @@ -18485,7 +18562,7 @@ void Player::BindToInstance() GetSession()->SendPacket(&data); if (!IsGameMaster()) { - BindToInstance(mapSave, true); + BindToInstance(mapSave, true, EXTEND_STATE_KEEP); GetSession()->SendCalendarRaidLockout(mapSave, true); } } @@ -18511,15 +18588,19 @@ void Player::SendRaidInfo() { for (BoundInstancesMap::iterator itr = m_boundInstances[i].begin(); itr != m_boundInstances[i].end(); ++itr) { - if (itr->second.perm) - { - InstanceSave* save = itr->second.save; - data << uint32(save->GetMapId()); // map id - data << uint32(save->GetDifficulty()); // difficulty - data << uint64(save->GetInstanceId()); // instance id - data << uint8(1); // expired = 0 - data << uint8(0); // extended = 1 - data << uint32(save->GetResetTime() - now); // reset time + InstancePlayerBind const& bind = itr->second; + if (bind.perm) + { + InstanceSave* save = bind.save; + data << uint32(save->GetMapId()); // map id + data << uint32(save->GetDifficulty()); // difficulty + data << uint64(save->GetInstanceId()); // instance id + data << uint8(bind.extendState != EXTEND_STATE_EXPIRED); // expired = 0 + data << uint8(bind.extendState == EXTEND_STATE_EXTENDED); // extended = 1 + time_t nextReset = save->GetResetTime(); + if (bind.extendState == EXTEND_STATE_EXTENDED) + nextReset = sInstanceSaveMgr->GetSubsequentResetTime(save->GetMapId(), save->GetDifficulty(), save->GetResetTime()); + data << uint32(nextReset - now); // reset time ++counter; } } @@ -18570,31 +18651,6 @@ void Player::SendSavedInstances() } } -/// convert the player's binds to the group -void Player::ConvertInstancesToGroup(Player* player, Group* group, bool switchLeader) -{ - // copy all binds to the group, when changing leader it's assumed the character - // will not have any solo binds - - for (uint8 i = 0; i < MAX_DIFFICULTY; ++i) - { - for (BoundInstancesMap::iterator itr = player->m_boundInstances[i].begin(); itr != player->m_boundInstances[i].end();) - { - if (!switchLeader || !group->GetBoundInstance(itr->second.save->GetDifficulty(), itr->first)) - group->BindToInstance(itr->second.save, itr->second.perm, false); - - // permanent binds are not removed - if (switchLeader && !itr->second.perm) - { - // increments itr in call - player->UnbindInstance(itr, Difficulty(i), false); - } - else - ++itr; - } - } -} - bool Player::Satisfy(AccessRequirement const* ar, uint32 target_map, bool report) { if (!IsGameMaster() && ar) @@ -18667,37 +18723,68 @@ bool Player::Satisfy(AccessRequirement const* ar, uint32 target_map, bool report return true; } -bool Player::CheckInstanceLoginValid(Map* map) +bool Player::IsInstanceLoginGameMasterException() const { - if (!map->IsDungeon() || IsGameMaster()) - return true; - - if (map->IsRaid()) + if (CanBeGameMaster()) { - // cannot be in raid instance without a group - if (!GetGroup()) - return IsInstanceLoginGameMasterException(); + ChatHandler(GetSession()).SendSysMessage(LANG_INSTANCE_LOGIN_GAMEMASTER_EXCEPTION); + return true; } else - { - // cannot be in normal instance without a group and more players than 1 in instance - if (!GetGroup() && map->GetPlayersCountExceptGMs() > 1) - return IsInstanceLoginGameMasterException(); - } - - // do checks for satisfy accessreqs, instance full, encounter in progress (raid), perm bind group != perm bind player - return sMapMgr->CanPlayerEnter(map->GetId(), this, true) || IsInstanceLoginGameMasterException(); + return false; } -bool Player::IsInstanceLoginGameMasterException() const +bool Player::CheckInstanceValidity(bool /*isLogin*/) { - if (CanBeGameMaster()) - { - ChatHandler(GetSession()).SendSysMessage(LANG_INSTANCE_LOGIN_GAMEMASTER_EXCEPTION); + // game masters' instances are always valid + if (IsGameMaster()) + return true; + + // non-instances are always valid + Map* map = GetMap(); + if (!map || !map->IsDungeon()) return true; + + // raid instances require the player to be in a raid group to be valid + if (map->IsRaid() && !sWorld->getBoolConfig(CONFIG_INSTANCE_IGNORE_RAID)) + if (!GetGroup() || !GetGroup()->isRaidGroup()) + return false; + + if (Group* group = GetGroup()) + { + // check if player's group is bound to this instance + InstanceGroupBind* bind = group->GetBoundInstance(map->GetDifficulty(), map->GetId()); + if (!bind || !bind->save || bind->save->GetInstanceId() != map->GetInstanceId()) + return false; + + Map::PlayerList const& players = map->GetPlayers(); + if (!players.isEmpty()) + for (Map::PlayerList::const_iterator it = players.begin(); it != players.end(); ++it) + { + if (Player* otherPlayer = it->GetSource()) + { + if (otherPlayer->IsGameMaster()) + continue; + if (!otherPlayer->m_InstanceValid) // ignore players that currently have a homebind timer active + continue; + if (group != otherPlayer->GetGroup()) + return false; + } + } } else - return false; + { + // instance is invalid if we are not grouped and there are other players + if (map->GetPlayersCountExceptGMs() > 1) + return false; + + // check if the player is bound to this instance + InstancePlayerBind* bind = GetBoundInstance(map->GetId(), map->GetDifficulty()); + if (!bind || !bind->save || bind->save->GetInstanceId() != map->GetInstanceId()) + return false; + } + + return true; } bool Player::CheckInstanceCount(uint32 instanceId) const @@ -20126,6 +20213,12 @@ void Player::RemovePet(Pet* pet, PetSaveMode mode, bool returnreagent) void Player::StopCastingCharm() { + if (IsGhouled()) + { + RemoveGhoul(); + return; + } + Unit* charm = GetCharm(); if (!charm) return; @@ -21478,6 +21571,14 @@ void Player::setResurrectRequestData(ObjectGuid guid, uint32 mapId, float X, flo m_resurrectHealth = health; m_resurrectMana = mana; } + +void Player::clearResurrectRequestData() +{ + setResurrectRequestData(ObjectGuid::Empty, 0, 0.0f, 0.0f, 0.0f, 0, 0); + + m_ghoulResurrectPlayerGUID = ObjectGuid::Empty; + m_ghoulResurrectGhoulGUID = ObjectGuid::Empty; +} //slot to be excluded while counting bool Player::EnchantmentFitsRequirements(uint32 enchantmentcondition, int8 slot) { @@ -22572,46 +22673,16 @@ void Player::LearnQuestRewardedSpells(Quest const* quest) if (!found) return; - // prevent learn non first rank unknown profession and second specialization for same profession) uint32 learned_0 = spellInfo->Effects[0].TriggerSpell; - if (sSpellMgr->GetSpellRank(learned_0) > 1 && !HasSpell(learned_0)) + if (!HasSpell(learned_0)) { SpellInfo const* learnedInfo = sSpellMgr->GetSpellInfo(learned_0); if (!learnedInfo) return; - // not have first rank learned (unlearned prof?) - if (!HasSpell(learnedInfo->GetFirstRankSpell()->Id)) - return; - - SpellsRequiringSpellMapBounds spellsRequired = sSpellMgr->GetSpellsRequiredForSpellBounds(learned_0); - for (SpellsRequiringSpellMap::const_iterator itr2 = spellsRequired.first; itr2 != spellsRequired.second; ++itr2) - { - uint32 profSpell = itr2->second; - - // specialization - if (learnedInfo->Effects[0].Effect == SPELL_EFFECT_TRADE_SKILL && learnedInfo->Effects[1].Effect == 0 && profSpell) - { - // search other specialization for same prof - for (PlayerSpellMap::const_iterator itr = m_spells.begin(); itr != m_spells.end(); ++itr) - { - if (itr->second->state == PLAYERSPELL_REMOVED || itr->first == learned_0) - continue; - - SpellInfo const* itrInfo = sSpellMgr->GetSpellInfo(itr->first); - if (!itrInfo) - return; - - // compare only specializations - if (itrInfo->Effects[0].Effect != SPELL_EFFECT_TRADE_SKILL || itrInfo->Effects[1].Effect != 0) - continue; - - // compare same chain spells - if (sSpellMgr->IsSpellRequiringSpell(itr->first, profSpell)) - return; - } - } - } + // profession specialization can be re-learned from npc + if (learnedInfo->Effects[0].Effect == SPELL_EFFECT_TRADE_SKILL && learnedInfo->Effects[1].Effect == 0 && !learnedInfo->SpellLevel) + return; } CastSpell(this, spell_id, true); @@ -23410,6 +23481,8 @@ uint32 Player::GetBaseWeaponSkillValue(WeaponAttackType attType) const void Player::ResurrectUsingRequestData() { + RemoveGhoul(); + /// Teleport before resurrecting by player, otherwise the player might get attacked from creatures near his corpse TeleportTo(m_resurrectMap, m_resurrectX, m_resurrectY, m_resurrectZ, GetOrientation()); @@ -23854,6 +23927,31 @@ void Player::SetViewpoint(WorldObject* target, bool apply) //WorldPacket data(SMSG_CLEAR_FAR_SIGHT_IMMEDIATE, 0); //GetSession()->SendPacket(&data); } + + // HACK: Make sure update for PLAYER_FARSIGHT is received before SMSG_PET_SPELLS to properly hide "Release spirit" dialog + if (target->GetTypeId() == TYPEID_UNIT && static_cast<Unit*>(target)->HasUnitTypeMask(UNIT_MASK_MINION) && static_cast<Minion*>(target)->IsRisenAlly()) + { + if (apply) + { + UpdateDataMapType update_players; + BuildUpdate(update_players); + WorldPacket packet; + for (UpdateDataMapType::iterator iter = update_players.begin(); iter != update_players.end(); ++iter) + { + iter->second.BuildPacket(&packet); + iter->first->GetSession()->SendPacket(&packet); + packet.clear(); + } + } + else + { + m_deathTimer = 6 * MINUTE * IN_MILLISECONDS; + + // Reset "Release spirit" timer clientside + WorldPacket data(SMSG_FORCED_DEATH_UPDATE); + SendDirectMessage(&data); + } + } } WorldObject* Player::GetViewpoint() const @@ -26076,11 +26174,11 @@ std::string Player::GetMapAreaAndZoneString() uint32 areaId = GetAreaId(); std::string areaName = "Unknown"; std::string zoneName = "Unknown"; - if (AreaTableEntry const* area = GetAreaEntryByAreaID(areaId)) + if (AreaTableEntry const* area = sAreaTableStore.LookupEntry(areaId)) { int locale = GetSession()->GetSessionDbcLocale(); areaName = area->area_name[locale]; - if (AreaTableEntry const* zone = GetAreaEntryByAreaID(area->zone)) + if (AreaTableEntry const* zone = sAreaTableStore.LookupEntry(area->zone)) zoneName = zone->area_name[locale]; } diff --git a/src/server/game/Entities/Player/Player.h b/src/server/game/Entities/Player/Player.h index 26944de9770..2388cf9d0c7 100644 --- a/src/server/game/Entities/Player/Player.h +++ b/src/server/game/Entities/Player/Player.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -834,14 +834,27 @@ enum PlayerDelayedOperations // Maximum money amount : 2^31 - 1 extern uint32 const MAX_MONEY_AMOUNT; +enum BindExtensionState +{ + EXTEND_STATE_EXPIRED = 0, + EXTEND_STATE_NORMAL = 1, + EXTEND_STATE_EXTENDED = 2, + EXTEND_STATE_KEEP = 255 // special state: keep current save type +}; struct InstancePlayerBind { InstanceSave* save; - bool perm; /* permanent PlayerInstanceBinds are created in Raid/Heroic instances for players - that aren't already permanently bound when they are inside when a boss is killed - or when they enter an instance that the group leader is permanently bound to. */ - InstancePlayerBind() : save(NULL), perm(false) { } + that aren't already permanently bound when they are inside when a boss is killed + or when they enter an instance that the group leader is permanently bound to. */ + bool perm; + /* extend state listing: + EXPIRED - doesn't affect anything unless manually re-extended by player + NORMAL - standard state + EXTENDED - won't be promoted to EXPIRED at next reset period, will instead be promoted to NORMAL */ + BindExtensionState extendState; + + InstancePlayerBind() : save(NULL), perm(false), extendState(EXTEND_STATE_NORMAL) { } }; struct AccessRequirement @@ -1050,8 +1063,9 @@ class Player : public Unit, public GridObject<Player> void SendInstanceResetWarning(uint32 mapid, Difficulty difficulty, uint32 time, bool welcome); bool CanInteractWithQuestGiver(Object* questGiver); - Creature* GetNPCIfCanInteractWith(ObjectGuid guid, uint32 npcflagmask); - GameObject* GetGameObjectIfCanInteractWith(ObjectGuid guid, GameobjectTypes type) const; + Creature* GetNPCIfCanInteractWith(ObjectGuid const& guid, uint32 npcflagmask); + GameObject* GetGameObjectIfCanInteractWith(ObjectGuid const& guid) const; + GameObject* GetGameObjectIfCanInteractWith(ObjectGuid const& guid, GameobjectTypes type) const; void ToggleAFK(); void ToggleDND(); @@ -1576,7 +1590,7 @@ class Player : public Unit, public GridObject<Player> void UpdatePotionCooldown(Spell* spell = NULL); void setResurrectRequestData(ObjectGuid guid, uint32 mapId, float X, float Y, float Z, uint32 health, uint32 mana); - void clearResurrectRequestData() { setResurrectRequestData(ObjectGuid::Empty, 0, 0.0f, 0.0f, 0.0f, 0, 0); } + void clearResurrectRequestData(); bool isResurrectRequestedBy(ObjectGuid guid) const { return !m_resurrectGUID.IsEmpty() && m_resurrectGUID == guid; } bool isResurrectRequested() const { return !m_resurrectGUID.IsEmpty(); } void ResurrectUsingRequestData(); @@ -1770,6 +1784,15 @@ class Player : public Unit, public GridObject<Player> void ResurrectPlayer(float restore_percent, bool applySickness = false); void BuildPlayerRepop(); void RepopAtGraveyard(); + void SendGhoulResurrectRequest(Player* target); + bool IsValidGhoulResurrectRequest(ObjectGuid guid) + { + return !m_ghoulResurrectPlayerGUID.IsEmpty() && m_ghoulResurrectPlayerGUID == guid; + } + void GhoulResurrect(); + void SetGhoulResurrectGhoulGUID(ObjectGuid guid) { m_ghoulResurrectGhoulGUID = guid; } + ObjectGuid GetGhoulResurrectGhoulGUID() { return m_ghoulResurrectGhoulGUID; } + void RemoveGhoul(); void DurabilityLossAll(double percent, bool inventory); void DurabilityLoss(Item* item, double percent); @@ -2105,20 +2128,19 @@ class Player : public Unit, public GridObject<Player> bool m_InstanceValid; // permanent binds and solo binds by difficulty BoundInstancesMap m_boundInstances[MAX_DIFFICULTY]; - InstancePlayerBind* GetBoundInstance(uint32 mapid, Difficulty difficulty); + InstancePlayerBind* GetBoundInstance(uint32 mapid, Difficulty difficulty, bool withExpired = false); BoundInstancesMap& GetBoundInstances(Difficulty difficulty) { return m_boundInstances[difficulty]; } InstanceSave* GetInstanceSave(uint32 mapid, bool raid); void UnbindInstance(uint32 mapid, Difficulty difficulty, bool unload = false); void UnbindInstance(BoundInstancesMap::iterator &itr, Difficulty difficulty, bool unload = false); - InstancePlayerBind* BindToInstance(InstanceSave* save, bool permanent, bool load = false); + InstancePlayerBind* BindToInstance(InstanceSave* save, bool permanent, BindExtensionState extendState = EXTEND_STATE_NORMAL, bool load = false); void BindToInstance(); void SetPendingBind(uint32 instanceId, uint32 bindTimer); bool HasPendingBind() const { return _pendingBindId > 0; } void SendRaidInfo(); void SendSavedInstances(); - static void ConvertInstancesToGroup(Player* player, Group* group, bool switchLeader); bool Satisfy(AccessRequirement const* ar, uint32 target_map, bool report = false); - bool CheckInstanceLoginValid(Map* map); + bool CheckInstanceValidity(bool /*isLogin*/); bool CheckInstanceCount(uint32 instanceId) const; void AddInstanceEnterTime(uint32 instanceId, time_t enterTime); @@ -2404,6 +2426,9 @@ class Player : public Unit, public GridObject<Player> float m_resurrectX, m_resurrectY, m_resurrectZ; uint32 m_resurrectHealth, m_resurrectMana; + ObjectGuid m_ghoulResurrectPlayerGUID; + ObjectGuid m_ghoulResurrectGhoulGUID; + WorldSession* m_session; typedef std::list<Channel*> JoinedChannelsList; @@ -2503,7 +2528,7 @@ class Player : public Unit, public GridObject<Player> bool IsHasDelayedTeleport() const { return m_bHasDelayedTeleport; } void SetDelayedTeleportFlag(bool setting) { m_bHasDelayedTeleport = setting; } void ScheduleDelayedOperation(uint32 operation) { if (operation < DELAYED_END) m_DelayedOperations |= operation; } - + bool IsInstanceLoginGameMasterException() const; MapReference m_mapRef; diff --git a/src/server/game/Entities/Player/SocialMgr.cpp b/src/server/game/Entities/Player/SocialMgr.cpp index b65584a4357..ffb2d8a7dd8 100644 --- a/src/server/game/Entities/Player/SocialMgr.cpp +++ b/src/server/game/Entities/Player/SocialMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Player/SocialMgr.h b/src/server/game/Entities/Player/SocialMgr.h index 887b5de58df..8f8ed04b5fb 100644 --- a/src/server/game/Entities/Player/SocialMgr.h +++ b/src/server/game/Entities/Player/SocialMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Player/TradeData.cpp b/src/server/game/Entities/Player/TradeData.cpp index bbbd1c81773..ef425ef0259 100644 --- a/src/server/game/Entities/Player/TradeData.cpp +++ b/src/server/game/Entities/Player/TradeData.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Entities/Player/TradeData.h b/src/server/game/Entities/Player/TradeData.h index cfaf066bde0..276e6f3db1c 100644 --- a/src/server/game/Entities/Player/TradeData.h +++ b/src/server/game/Entities/Player/TradeData.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Entities/Totem/Totem.cpp b/src/server/game/Entities/Totem/Totem.cpp index 85ee51aebf5..5e8544246a6 100644 --- a/src/server/game/Entities/Totem/Totem.cpp +++ b/src/server/game/Entities/Totem/Totem.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -142,6 +142,10 @@ void Totem::UnSummon(uint32 msTime) } } + // any totem unsummon look like as totem kill, req. for proper animation + if (IsAlive()) + setDeathState(DEAD); + AddObjectToRemoveList(); } diff --git a/src/server/game/Entities/Totem/Totem.h b/src/server/game/Entities/Totem/Totem.h index 66fda485028..bbe7943f4b6 100644 --- a/src/server/game/Entities/Totem/Totem.h +++ b/src/server/game/Entities/Totem/Totem.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Transport/Transport.cpp b/src/server/game/Entities/Transport/Transport.cpp index 99459dce81e..5e5c6901471 100644 --- a/src/server/game/Entities/Transport/Transport.cpp +++ b/src/server/game/Entities/Transport/Transport.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Transport/Transport.h b/src/server/game/Entities/Transport/Transport.h index 3a2d0e4a7bd..987fbf70739 100644 --- a/src/server/game/Entities/Transport/Transport.h +++ b/src/server/game/Entities/Transport/Transport.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Unit/StatSystem.cpp b/src/server/game/Entities/Unit/StatSystem.cpp index fb27fea7060..a8e13a9f7db 100644 --- a/src/server/game/Entities/Unit/StatSystem.cpp +++ b/src/server/game/Entities/Unit/StatSystem.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -499,7 +499,7 @@ void Player::UpdateAttackPowerAndDamage(bool ranged) if (getClass() == CLASS_SHAMAN || getClass() == CLASS_PALADIN) // mental quickness UpdateSpellDamageAndHealingBonus(); - if (pet && pet->IsPetGhoul()) // At melee attack power change for DK pet + if (pet && (pet->IsPetGhoul() || pet->IsRisenAlly())) // At melee attack power change for DK pet pet->UpdateAttackPowerAndDamage(); if (guardian && guardian->IsSpiritWolf()) // At melee attack power change for Shaman feral spirit @@ -1113,7 +1113,7 @@ bool Guardian::UpdateStats(Stats stat) Unit* owner = GetOwner(); // Handle Death Knight Glyphs and Talents float mod = 0.75f; - if (IsPetGhoul() && (stat == STAT_STAMINA || stat == STAT_STRENGTH)) + if ((IsPetGhoul() || IsRisenAlly()) && (stat == STAT_STAMINA || stat == STAT_STRENGTH)) { if (stat == STAT_STAMINA) mod = 0.3f; // Default Owner's Stamina scale @@ -1329,7 +1329,7 @@ void Guardian::UpdateAttackPowerAndDamage(bool ranged) bonusAP = owner->GetTotalAttackPowerValue(RANGED_ATTACK) * 0.22f * mod; SetBonusDamage(int32(owner->GetTotalAttackPowerValue(RANGED_ATTACK) * 0.1287f * mod)); } - else if (IsPetGhoul()) //ghouls benefit from deathknight's attack power (may be summon pet or not) + else if (IsPetGhoul() || IsRisenAlly()) //ghouls benefit from deathknight's attack power (may be summon pet or not) { bonusAP = owner->GetTotalAttackPowerValue(BASE_ATTACK) * 0.22f; SetBonusDamage(int32(owner->GetTotalAttackPowerValue(BASE_ATTACK) * 0.1287f)); diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index 27f6d5f614d..c21301c27b2 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -157,6 +157,28 @@ ProcEventInfo::ProcEventInfo(Unit* actor, Unit* actionTarget, Unit* procTarget, _damageInfo(damageInfo), _healInfo(healInfo) { } +SpellInfo const* ProcEventInfo::GetSpellInfo() const +{ + if (_spell) + return _spell->GetSpellInfo(); + if (_damageInfo) + return _damageInfo->GetSpellInfo(); + if (_healInfo) + return _healInfo->GetSpellInfo(); + return nullptr; +} + +SpellSchoolMask ProcEventInfo::GetSchoolMask() const +{ + if (_spell) + return _spell->GetSpellInfo()->GetSchoolMask(); + if (_damageInfo) + return _damageInfo->GetSchoolMask(); + if (_healInfo) + return _healInfo->GetSchoolMask(); + return SPELL_SCHOOL_MASK_NONE; +} + Unit::Unit(bool isWorldObject) : WorldObject(isWorldObject), m_movedPlayer(NULL), m_lastSanctuaryTime(0), IsAIEnabled(false), NeedChangeAI(false), LastCharmerGUID(), @@ -223,7 +245,8 @@ Unit::Unit(bool isWorldObject) : for (uint8 i = 0; i < MAX_STATS; ++i) m_createStats[i] = 0.0f; - m_attacking = NULL; + m_attacking = nullptr; + m_shouldReacquireTarget = false; m_modMeleeHitChance = 0.0f; m_modRangedHitChance = 0.0f; m_modSpellHitChance = 0.0f; @@ -238,7 +261,7 @@ Unit::Unit(bool isWorldObject) : for (uint8 i = 0; i < MAX_MOVE_TYPE; ++i) m_speed_rate[i] = 1.0f; - m_charmInfo = NULL; + m_charmInfo = nullptr; _redirectThreadInfo = RedirectThreatInfo(); @@ -1669,6 +1692,9 @@ void Unit::CalcAbsorbResist(Unit* victim, SpellSchoolMask schoolMask, DamageEffe RoundToInterval(auraAbsorbMod, 0.0f, 100.0f); + int32 absorbIgnoringDamage = CalculatePct(dmgInfo.GetDamage(), auraAbsorbMod); + dmgInfo.ModifyDamage(-absorbIgnoringDamage); + // We're going to call functions which can modify content of the list during iteration over it's elements // Let's copy the list so we can prevent iterator invalidation AuraEffectList vSchoolAbsorbCopy(victim->GetAuraEffectsByType(SPELL_AURA_SCHOOL_ABSORB)); @@ -1701,9 +1727,6 @@ void Unit::CalcAbsorbResist(Unit* victim, SpellSchoolMask schoolMask, DamageEffe if (defaultPrevented) continue; - // Apply absorb mod auras - AddPct(currentAbsorb, -auraAbsorbMod); - // absorb must be smaller than the damage itself currentAbsorb = RoundToInterval(currentAbsorb, 0, int32(dmgInfo.GetDamage())); @@ -1752,8 +1775,6 @@ void Unit::CalcAbsorbResist(Unit* victim, SpellSchoolMask schoolMask, DamageEffe if (defaultPrevented) continue; - AddPct(currentAbsorb, -auraAbsorbMod); - // absorb must be smaller than the damage itself currentAbsorb = RoundToInterval(currentAbsorb, 0, int32(dmgInfo.GetDamage())); @@ -1782,6 +1803,8 @@ void Unit::CalcAbsorbResist(Unit* victim, SpellSchoolMask schoolMask, DamageEffe } } + dmgInfo.ModifyDamage(absorbIgnoringDamage); + // split damage auras - only when not damaging self if (victim != this) { @@ -1956,6 +1979,9 @@ void Unit::AttackerStateUpdate (Unit* victim, WeaponAttackType attType, bool ext if (attType != BASE_ATTACK && attType != OFF_ATTACK) return; // ignore ranged case + if (GetTypeId() == TYPEID_UNIT && !HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PLAYER_CONTROLLED)) + SetFacingToObject(victim); // update client side facing to face the target (prevents visual glitches when casting untargeted spells) + // melee attack spell cast at main hand attack only - no normal melee dmg dealt if (attType == BASE_ATTACK && m_currentSpells[CURRENT_MELEE_SPELL] && !extra) m_currentSpells[CURRENT_MELEE_SPELL]->cast(); @@ -4329,13 +4355,10 @@ void Unit::GetDispellableAuraList(Unit* caster, uint32 dispelMask, DispelCharges if (aura->GetSpellInfo()->GetDispelMask() & dispelMask) { - if (aura->GetSpellInfo()->Dispel == DISPEL_MAGIC) - { - // do not remove positive auras if friendly target - // negative auras if non-friendly target - if (aurApp->IsPositive() == IsFriendlyTo(caster)) - continue; - } + // do not remove positive auras if friendly target + // negative auras if non-friendly target + if (aurApp->IsPositive() == IsFriendlyTo(caster)) + continue; // The charges / stack amounts don't count towards the total number of auras that can be dispelled. // Ie: A dispel on a target with 5 stacks of Winters Chill and a Polymorph has 1 / (1 + 1) -> 50% chance to dispell @@ -6361,54 +6384,6 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere } case SPELLFAMILY_PALADIN: { - // Light's Beacon - Beacon of Light - if (dummySpell->Id == 53651) - { - if (!victim || !procSpell) - return false; - triggered_spell_id = 0; - Unit* beaconTarget = NULL; - if (GetTypeId() != TYPEID_PLAYER) - { - beaconTarget = triggeredByAura->GetBase()->GetCaster(); - if (!beaconTarget || beaconTarget == this || !(beaconTarget->GetAura(53563, victim->GetGUID()))) - return false; - basepoints0 = int32(damage); - triggered_spell_id = procSpell->IsRankOf(sSpellMgr->GetSpellInfo(635)) ? 53652 : 53654; - } - else - { // Check Party/Raid Group - if (Group* group = ToPlayer()->GetGroup()) - { - for (GroupReference* itr = group->GetFirstMember(); itr != NULL; itr = itr->next()) - { - if (Player* member = itr->GetSource()) - { - // check if it was heal by paladin which cast this beacon of light - if (member->GetAura(53563, victim->GetGUID())) - { - // do not proc when target of beacon of light is healed - if (member == this) - return false; - - beaconTarget = member; - basepoints0 = int32(damage); - triggered_spell_id = procSpell->IsRankOf(sSpellMgr->GetSpellInfo(635)) ? 53652 : 53654; - break; - } - } - } - } - } - - if (triggered_spell_id && beaconTarget) - { - victim->CastCustomSpell(beaconTarget, triggered_spell_id, &basepoints0, NULL, NULL, true); - return true; - } - - return false; - } // Judgements of the Wise if (dummySpell->SpellIconID == 3017) { @@ -7121,9 +7096,6 @@ bool Unit::HandleDummyAuraProc(Unit* victim, uint32 damage, AuraEffect* triggere float chance = 100.0f / procSpell->Effects[effIndex].ChainTarget; if (!roll_chance_f(chance)) return false; - - // Remove cooldown (Chain Lightning - has Category Recovery time) - GetSpellHistory()->ResetCooldown(spellId); } CastSpell(victim, spellId, true, castItem, triggeredByAura); @@ -8353,8 +8325,6 @@ bool Unit::HandleProcTriggerSpell(Unit* victim, uint32 damage, AuraEffect* trigg case 52914: case 52915: case 52910: - // Honor Among Thieves - case 52916: { target = triggeredByAura->GetBase()->GetCaster(); if (!target) @@ -8956,6 +8926,12 @@ bool Unit::Attack(Unit* victim, bool meleeAttack) if (HasAuraType(SPELL_AURA_MOD_UNATTACKABLE)) RemoveAurasByType(SPELL_AURA_MOD_UNATTACKABLE); + if (m_shouldReacquireTarget) + { + SetTarget(victim->GetGUID()); + m_shouldReacquireTarget = false; + } + if (m_attacking) { if (m_attacking == victim) @@ -9041,7 +9017,7 @@ bool Unit::AttackStop() Unit* victim = m_attacking; m_attacking->_removeAttacker(this); - m_attacking = NULL; + m_attacking = nullptr; // Clear our target SetTarget(ObjectGuid::Empty); @@ -9395,7 +9371,7 @@ void Unit::SetMinion(Minion *minion, bool apply) minion->SetSpeed(UnitMoveType(i), m_speed_rate[i], true); // Ghoul pets have energy instead of mana (is anywhere better place for this code?) - if (minion->IsPetGhoul()) + if (minion->IsPetGhoul() || minion->IsRisenAlly()) minion->setPowerType(POWER_ENERGY); // Send infinity cooldown - client does that automatically but after relog cooldown needs to be set again @@ -12683,7 +12659,7 @@ void Unit::TauntFadeOut(Unit* taunter) if (m_ThreatManager.isThreatListEmpty()) { if (creature->IsAIEnabled) - creature->AI()->EnterEvadeMode(); + creature->AI()->EnterEvadeMode(CreatureAI::EVADE_REASON_NO_HOSTILES); return; } @@ -12705,7 +12681,7 @@ Unit* Creature::SelectVictim() // next-victim-selection algorithm and evade mode are called // threat list sorting etc. - Unit* target = NULL; + Unit* target = nullptr; // First checking if we have some taunt on us AuraEffectList const& tauntAuras = GetAuraEffectsByType(SPELL_AURA_MOD_TAUNT); if (!tauntAuras.empty()) @@ -12769,22 +12745,15 @@ Unit* Creature::SelectVictim() } } else - return NULL; + return nullptr; if (target && _IsTargetAcceptable(target) && CanCreatureAttack(target)) { - SetInFront(target); + if(!IsFocusing()) + SetInFront(target); return target; } - // Case where mob is being kited. - // Mob may not be in range to attack or may have dropped target. In any case, - // don't evade if damage received within the last 10 seconds - // Does not apply to world bosses to prevent kiting to cities - if (!isWorldBoss() && !GetInstanceId()) - if (time(NULL) - GetLastDamagedTime() <= MAX_AGGRO_RESET_TIME) - return target; - // last case when creature must not go to evade mode: // it in combat but attacker not make any damage and not enter to aggro radius to have record in threat list // for example at owner command to pet attack some far away creature @@ -12793,12 +12762,12 @@ Unit* Creature::SelectVictim() { if ((*itr) && !CanCreatureAttack(*itr) && (*itr)->GetTypeId() != TYPEID_PLAYER && !(*itr)->ToCreature()->HasUnitTypeMask(UNIT_MASK_CONTROLABLE_GUARDIAN)) - return NULL; + return nullptr; } /// @todo a vehicle may eat some mob, so mob should not evade if (GetVehicle()) - return NULL; + return nullptr; // search nearby enemy before enter evade mode if (HasReactState(REACT_AGGRESSIVE)) @@ -12816,17 +12785,17 @@ Unit* Creature::SelectVictim() { if ((*itr)->GetBase()->IsPermanent()) { - AI()->EnterEvadeMode(); + AI()->EnterEvadeMode(CreatureAI::EVADE_REASON_OTHER); break; } } - return NULL; + return nullptr; } // enter in evade mode in other case - AI()->EnterEvadeMode(); + AI()->EnterEvadeMode(CreatureAI::EVADE_REASON_NO_HOSTILES); - return NULL; + return nullptr; } //====================================================================== @@ -13625,6 +13594,9 @@ void Unit::RemoveFromWorld() RemoveAreaAurasDueToLeaveWorld(); + if (IsCharmed()) + RemoveCharmedBy(nullptr); + if (GetCharmerGUID()) { TC_LOG_FATAL("entities.unit", "Unit %u has charmer guid when removed from world", GetEntry()); @@ -14173,8 +14145,8 @@ void Unit::ProcDamageAndSpellFor(bool isVictim, Unit* target, uint32 procFlag, u Unit* actionTarget = !isVictim ? target : this; DamageInfo damageInfo = DamageInfo(actor, actionTarget, damage, procSpell, procSpell ? SpellSchoolMask(procSpell->SchoolMask) : SPELL_SCHOOL_MASK_NORMAL, SPELL_DIRECT_DAMAGE); - HealInfo healInfo = HealInfo(damage); - ProcEventInfo eventInfo = ProcEventInfo(actor, actionTarget, target, procFlag, 0, 0, procExtra, NULL, &damageInfo, &healInfo); + HealInfo healInfo = HealInfo(actor, actionTarget, damage, procSpell, procSpell ? SpellSchoolMask(procSpell->SchoolMask) : SPELL_SCHOOL_MASK_NORMAL); + ProcEventInfo eventInfo = ProcEventInfo(actor, actionTarget, target, procFlag, 0, 0, procExtra, nullptr, &damageInfo, &healInfo); ProcTriggeredList procTriggered; // Fill procTriggered list @@ -16884,12 +16856,12 @@ void Unit::JumpTo(float speedXY, float speedZ, bool forward) } } -void Unit::JumpTo(WorldObject* obj, float speedZ) +void Unit::JumpTo(WorldObject* obj, float speedZ, bool withOrientation) { float x, y, z; obj->GetContactPoint(this, x, y, z); float speedXY = GetExactDist2d(x, y) * 10.0f / speedZ; - GetMotionMaster()->MoveJump(x, y, z, speedXY, speedZ); + GetMotionMaster()->MoveJump(x, y, z, GetAngle(obj), speedXY, speedZ, EVENT_JUMP, withOrientation); } bool Unit::HandleSpellClick(Unit* clicker, int8 seatId) @@ -17558,7 +17530,7 @@ void Unit::SetFacingTo(float ori) init.Launch(); } -void Unit::SetFacingToObject(WorldObject* object) +void Unit::SetFacingToObject(WorldObject const* object) { // never face when already moving if (!IsStopped()) diff --git a/src/server/game/Entities/Unit/Unit.h b/src/server/game/Entities/Unit/Unit.h index 2ddbe398f76..4565160dc93 100644 --- a/src/server/game/Entities/Unit/Unit.h +++ b/src/server/game/Entities/Unit/Unit.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -863,22 +863,30 @@ public: class HealInfo { private: - uint32 m_heal; - uint32 m_absorb; + Unit* const _healer; + Unit* const _target; + uint32 _heal; + uint32 _absorb; + SpellInfo const* const _spellInfo; + SpellSchoolMask const _schoolMask; + public: - explicit HealInfo(uint32 heal) - : m_heal(heal) - { - m_absorb = 0; - } + explicit HealInfo(Unit* healer, Unit* target, uint32 heal, SpellInfo const* spellInfo, SpellSchoolMask schoolMask) + : _healer(healer), _target(target), _heal(heal), _absorb(0), _spellInfo(spellInfo), _schoolMask(schoolMask) { } + void AbsorbHeal(uint32 amount) { amount = std::min(amount, GetHeal()); - m_absorb += amount; - m_heal -= amount; + _absorb += amount; + _heal -= amount; } - uint32 GetHeal() const { return m_heal; } + Unit* GetHealer() const { return _healer; } + Unit* GetTarget() const { return _target; } + uint32 GetHeal() const { return _heal; } + uint32 GetAbsorb() const { return _absorb; } + SpellInfo const* GetSpellInfo() const { return _spellInfo; }; + SpellSchoolMask GetSchoolMask() const { return _schoolMask; }; }; class ProcEventInfo @@ -897,14 +905,8 @@ public: uint32 GetSpellPhaseMask() const { return _spellPhaseMask; } uint32 GetHitMask() const { return _hitMask; } - SpellInfo const* GetSpellInfo() const { return NULL; } - SpellInfo const* EnsureSpellInfo() const - { - SpellInfo const* spellInfo = GetSpellInfo(); - ASSERT(spellInfo); - return spellInfo; - } - SpellSchoolMask GetSchoolMask() const { return SPELL_SCHOOL_MASK_NONE; } + SpellInfo const* GetSpellInfo() const; + SpellSchoolMask GetSchoolMask() const; DamageInfo* GetDamageInfo() const { return _damageInfo; } HealInfo* GetHealInfo() const { return _healInfo; } @@ -1274,6 +1276,7 @@ class Unit : public WorldObject void _removeAttacker(Unit* pAttacker); // must be called only from Unit::AttackStop() Unit* getAttackerForHelper() const; // If someone wants to help, who to give them bool Attack(Unit* victim, bool meleeAttack); + void MustReacquireTarget() { m_shouldReacquireTarget = true; } // flags the Unit for forced target reacquisition in the next ::Attack call void CastStop(uint32 except_spellid = 0); bool AttackStop(); void RemoveAllAttackers(); @@ -1564,7 +1567,7 @@ class Unit : public WorldObject void KnockbackFrom(float x, float y, float speedXY, float speedZ); void JumpTo(float speedXY, float speedZ, bool forward = true); - void JumpTo(WorldObject* obj, float speedZ); + void JumpTo(WorldObject* obj, float speedZ, bool withOrientation = false); void MonsterMoveWithSpeed(float x, float y, float z, float speed, bool generatePath = false, bool forceDestination = false); //void SetFacing(float ori, WorldObject* obj = NULL); @@ -1584,7 +1587,7 @@ class Unit : public WorldObject void SetInFront(WorldObject const* target); void SetFacingTo(float ori); - void SetFacingToObject(WorldObject* object); + void SetFacingToObject(WorldObject const* object); void SendChangeCurrentVictimOpcode(HostileReference* pHostileReference); void SendClearThreatListOpcode(); @@ -1598,6 +1601,7 @@ class Unit : public WorldObject bool IsAlive() const { return (m_deathState == ALIVE); } bool isDying() const { return (m_deathState == JUST_DIED); } bool isDead() const { return (m_deathState == DEAD || m_deathState == CORPSE); } + bool IsGhouled() const { return HasAura(46619 /*SPELL_DK_RAISE_ALLY*/); } DeathState getDeathState() const { return m_deathState; } virtual void setDeathState(DeathState s); // overwrited in Creature/Player/Pet @@ -2152,6 +2156,7 @@ class Unit : public WorldObject AttackerSet m_attackers; Unit* m_attacking; + bool m_shouldReacquireTarget; DeathState m_deathState; diff --git a/src/server/game/Entities/Vehicle/Vehicle.cpp b/src/server/game/Entities/Vehicle/Vehicle.cpp index 982b931fd4f..9cf485322f2 100755 --- a/src/server/game/Entities/Vehicle/Vehicle.cpp +++ b/src/server/game/Entities/Vehicle/Vehicle.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Vehicle/Vehicle.h b/src/server/game/Entities/Vehicle/Vehicle.h index edec4ea161c..cd28c4082d4 100644 --- a/src/server/game/Entities/Vehicle/Vehicle.h +++ b/src/server/game/Entities/Vehicle/Vehicle.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Entities/Vehicle/VehicleDefines.h b/src/server/game/Entities/Vehicle/VehicleDefines.h index 3726e9ddf8f..42d299ff9b2 100644 --- a/src/server/game/Entities/Vehicle/VehicleDefines.h +++ b/src/server/game/Entities/Vehicle/VehicleDefines.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Events/GameEventMgr.cpp b/src/server/game/Events/GameEventMgr.cpp index 9e5e7ff9990..b2871786034 100644 --- a/src/server/game/Events/GameEventMgr.cpp +++ b/src/server/game/Events/GameEventMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Events/GameEventMgr.h b/src/server/game/Events/GameEventMgr.h index 57f30eb4015..b8d281dfdd7 100644 --- a/src/server/game/Events/GameEventMgr.h +++ b/src/server/game/Events/GameEventMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Globals/ObjectAccessor.cpp b/src/server/game/Globals/ObjectAccessor.cpp index ca974ba9a37..762c9b9c28e 100644 --- a/src/server/game/Globals/ObjectAccessor.cpp +++ b/src/server/game/Globals/ObjectAccessor.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Globals/ObjectAccessor.h b/src/server/game/Globals/ObjectAccessor.h index d5fb8564b96..d8466dbb1bc 100644 --- a/src/server/game/Globals/ObjectAccessor.h +++ b/src/server/game/Globals/ObjectAccessor.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Globals/ObjectMgr.cpp b/src/server/game/Globals/ObjectMgr.cpp index 6f5368ed150..f45634e9684 100644 --- a/src/server/game/Globals/ObjectMgr.cpp +++ b/src/server/game/Globals/ObjectMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -1756,7 +1756,7 @@ void ObjectMgr::LoadCreatures() if (!ok) continue; - // -1 random, 0 no equipment, + // -1 random, 0 no equipment if (data.equipmentId != 0) { if (!GetEquipmentInfo(data.id, data.equipmentId)) @@ -2773,7 +2773,7 @@ void ObjectMgr::LoadItemTemplates() itemTemplate.ItemSet = 0; } - if (itemTemplate.Area && !GetAreaEntryByAreaID(itemTemplate.Area)) + if (itemTemplate.Area && !sAreaTableStore.LookupEntry(itemTemplate.Area)) TC_LOG_ERROR("sql.sql", "Item (Entry: %u) has wrong Area (%u)", entry, itemTemplate.Area); if (itemTemplate.Map && !sMapStore.LookupEntry(itemTemplate.Map)) @@ -4143,7 +4143,7 @@ void ObjectMgr::LoadQuests() // client quest log visual (area case) if (qinfo->ZoneOrSort > 0) { - if (!GetAreaEntryByAreaID(qinfo->ZoneOrSort)) + if (!sAreaTableStore.LookupEntry(qinfo->ZoneOrSort)) { TC_LOG_ERROR("sql.sql", "Quest %u has `ZoneOrSort` = %u (zone case) but zone with this id does not exist.", qinfo->GetQuestId(), qinfo->ZoneOrSort); @@ -5956,7 +5956,7 @@ void ObjectMgr::LoadGraveyardZones() continue; } - AreaTableEntry const* areaEntry = GetAreaEntryByAreaID(zoneId); + AreaTableEntry const* areaEntry = sAreaTableStore.LookupEntry(zoneId); if (!areaEntry) { TC_LOG_ERROR("sql.sql", "Table `game_graveyard_zone` has a record for not existing zone id (%u), skipped.", zoneId); @@ -7796,7 +7796,7 @@ void ObjectMgr::LoadFishingBaseSkillLevel() uint32 entry = fields[0].GetUInt32(); int32 skill = fields[1].GetInt16(); - AreaTableEntry const* fArea = GetAreaEntryByAreaID(entry); + AreaTableEntry const* fArea = sAreaTableStore.LookupEntry(entry); if (!fArea) { TC_LOG_ERROR("sql.sql", "AreaId %u defined in `skill_fishing_base_level` does not exist", entry); diff --git a/src/server/game/Globals/ObjectMgr.h b/src/server/game/Globals/ObjectMgr.h index f557c046eed..ae1258713f5 100644 --- a/src/server/game/Globals/ObjectMgr.h +++ b/src/server/game/Globals/ObjectMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/Cells/Cell.h b/src/server/game/Grids/Cells/Cell.h index eb889e328cb..e7f37ebeb67 100644 --- a/src/server/game/Grids/Cells/Cell.h +++ b/src/server/game/Grids/Cells/Cell.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/Cells/CellImpl.h b/src/server/game/Grids/Cells/CellImpl.h index ea5143375c1..26ef5529b53 100644 --- a/src/server/game/Grids/Cells/CellImpl.h +++ b/src/server/game/Grids/Cells/CellImpl.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/Grid.h b/src/server/game/Grids/Grid.h index 69b245e4326..7503fec7a80 100644 --- a/src/server/game/Grids/Grid.h +++ b/src/server/game/Grids/Grid.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/GridDefines.h b/src/server/game/Grids/GridDefines.h index 8eae906ba87..24c9100b222 100644 --- a/src/server/game/Grids/GridDefines.h +++ b/src/server/game/Grids/GridDefines.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -226,7 +226,7 @@ namespace Trinity inline bool IsValidMapCoord(float x, float y, float z) { - return IsValidMapCoord(x, y) && std::isfinite(z); + return IsValidMapCoord(x, y) && IsValidMapCoord(z); } inline bool IsValidMapCoord(float x, float y, float z, float o) diff --git a/src/server/game/Grids/GridLoader.h b/src/server/game/Grids/GridLoader.h index 153a45c8ccb..b063126fd3d 100644 --- a/src/server/game/Grids/GridLoader.h +++ b/src/server/game/Grids/GridLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/GridRefManager.h b/src/server/game/Grids/GridRefManager.h index b52f1052fad..755417d873d 100644 --- a/src/server/game/Grids/GridRefManager.h +++ b/src/server/game/Grids/GridRefManager.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/GridReference.h b/src/server/game/Grids/GridReference.h index 946e2f89278..b1f2e92a840 100644 --- a/src/server/game/Grids/GridReference.h +++ b/src/server/game/Grids/GridReference.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/GridStates.cpp b/src/server/game/Grids/GridStates.cpp index 7f12c7b2793..d0c01d9de6d 100644 --- a/src/server/game/Grids/GridStates.cpp +++ b/src/server/game/Grids/GridStates.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/GridStates.h b/src/server/game/Grids/GridStates.h index 6f20e720377..9420bef4b9d 100644 --- a/src/server/game/Grids/GridStates.h +++ b/src/server/game/Grids/GridStates.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/NGrid.h b/src/server/game/Grids/NGrid.h index b6189d22fe3..b3d59da226a 100644 --- a/src/server/game/Grids/NGrid.h +++ b/src/server/game/Grids/NGrid.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/Notifiers/GridNotifiers.cpp b/src/server/game/Grids/Notifiers/GridNotifiers.cpp index 15f3c7811cd..2cdbdca4e4f 100644 --- a/src/server/game/Grids/Notifiers/GridNotifiers.cpp +++ b/src/server/game/Grids/Notifiers/GridNotifiers.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -131,7 +131,7 @@ inline void CreatureUnitRelocationWorker(Creature* c, Unit* u) if (!u->IsAlive() || !c->IsAlive() || c == u || u->IsInFlight()) return; - if (c->HasReactState(REACT_AGGRESSIVE) && !c->HasUnitState(UNIT_STATE_SIGHTLESS)) + if (!c->HasUnitState(UNIT_STATE_SIGHTLESS)) { if (c->IsAIEnabled && c->CanSeeOrDetect(u, false, true)) c->AI()->MoveInLineOfSight_Safe(u); diff --git a/src/server/game/Grids/Notifiers/GridNotifiers.h b/src/server/game/Grids/Notifiers/GridNotifiers.h index c2f5f75f98e..6edeadf6b94 100644 --- a/src/server/game/Grids/Notifiers/GridNotifiers.h +++ b/src/server/game/Grids/Notifiers/GridNotifiers.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/Notifiers/GridNotifiersImpl.h b/src/server/game/Grids/Notifiers/GridNotifiersImpl.h index 995d330035f..04d68240ca1 100644 --- a/src/server/game/Grids/Notifiers/GridNotifiersImpl.h +++ b/src/server/game/Grids/Notifiers/GridNotifiersImpl.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/ObjectGridLoader.cpp b/src/server/game/Grids/ObjectGridLoader.cpp index 2c292c43785..111bfdb6f48 100644 --- a/src/server/game/Grids/ObjectGridLoader.cpp +++ b/src/server/game/Grids/ObjectGridLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Grids/ObjectGridLoader.h b/src/server/game/Grids/ObjectGridLoader.h index 126ebd0d0a3..9dc4c7e048b 100644 --- a/src/server/game/Grids/ObjectGridLoader.h +++ b/src/server/game/Grids/ObjectGridLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Groups/Group.cpp b/src/server/game/Groups/Group.cpp index 4f8accee69c..99c5d610e64 100644 --- a/src/server/game/Groups/Group.cpp +++ b/src/server/game/Groups/Group.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -148,10 +148,9 @@ bool Group::Create(Player* leader) CharacterDatabase.Execute(stmt); + Group::ConvertLeaderInstancesToGroup(leader, this, false); ASSERT(AddMember(leader)); // If the leader can't be added to a new group because it appears full, something is clearly wrong. - - Player::ConvertInstancesToGroup(leader, this, false); } else if (!AddMember(leader)) return false; @@ -375,9 +374,7 @@ bool Group::AddMember(Player* player) player->SetGroup(this, subGroup); // if the same group invites the player back, cancel the homebind timer - InstanceGroupBind* bind = GetBoundInstance(player); - if (bind && bind->save->GetInstanceId() == player->GetInstanceId()) - player->m_InstanceValid = true; + player->m_InstanceValid = player->CheckInstanceValidity(false); if (!isRaidGroup()) // reset targetIcons for non-raid-groups { @@ -654,7 +651,7 @@ void Group::ChangeLeader(ObjectGuid newLeaderGuid) } // Copy the permanent binds from the new leader to the group - Player::ConvertInstancesToGroup(newLeader, this, true); + Group::ConvertLeaderInstancesToGroup(newLeader, this, true); // Update the group leader PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_UPD_GROUP_LEADER); @@ -680,6 +677,43 @@ void Group::ChangeLeader(ObjectGuid newLeaderGuid) BroadcastPacket(&data, true); } +/// convert the player's binds to the group +void Group::ConvertLeaderInstancesToGroup(Player* player, Group* group, bool switchLeader) +{ + // copy all binds to the group, when changing leader it's assumed the character + // will not have any solo binds + for (uint8 i = 0; i < MAX_DIFFICULTY; ++i) + { + for (Player::BoundInstancesMap::iterator itr = player->m_boundInstances[i].begin(); itr != player->m_boundInstances[i].end();) + { + if (!switchLeader || !group->GetBoundInstance(itr->second.save->GetDifficulty(), itr->first)) + if (itr->second.extendState) // not expired + group->BindToInstance(itr->second.save, itr->second.perm, false); + + // permanent binds are not removed + if (switchLeader && !itr->second.perm) + { + // increments itr in call + player->UnbindInstance(itr, Difficulty(i), false); + } + else + ++itr; + } + } + + /* if group leader is in a non-raid dungeon map and nobody is actually bound to this map then the group can "take over" the instance * + * (example: two-player group disbanded by disconnect where the player reconnects within 60 seconds and the group is reformed) */ + if (Map* playerMap = player->GetMap()) + if (!switchLeader && playerMap->IsNonRaidDungeon()) + if (InstanceSave* save = sInstanceSaveMgr->GetInstanceSave(playerMap->GetInstanceId())) + if (save->GetGroupCount() == 0 && save->GetPlayerCount() == 0) + { + TC_LOG_DEBUG("maps", "Group::ConvertLeaderInstancesToGroup: Group for player %s is taking over unbound instance map %d with Id %d", player->GetName().c_str(), playerMap->GetId(), playerMap->GetInstanceId()); + // if nobody is saved to this, then the save wasn't permanent + group->BindToInstance(save, false, false); + } +} + void Group::Disband(bool hideDestroy /* = false */) { sScriptMgr->OnGroupDisband(this); @@ -2241,6 +2275,8 @@ LootMethod Group::GetLootMethod() const ObjectGuid Group::GetLooterGuid() const { + if (GetLootMethod() == FREE_FOR_ALL) + return ObjectGuid::Empty; return m_looterGuid; } diff --git a/src/server/game/Groups/Group.h b/src/server/game/Groups/Group.h index b814ab08026..42fd9b582e8 100644 --- a/src/server/game/Groups/Group.h +++ b/src/server/game/Groups/Group.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -194,6 +194,7 @@ class Group bool AddMember(Player* player); bool RemoveMember(ObjectGuid guid, const RemoveMethod &method = GROUP_REMOVEMETHOD_DEFAULT, ObjectGuid kicker = ObjectGuid::Empty, const char* reason = NULL); void ChangeLeader(ObjectGuid guid); + static void ConvertLeaderInstancesToGroup(Player* player, Group* group, bool switchLeader); void SetLootMethod(LootMethod method); void SetLooterGuid(ObjectGuid guid); void SetMasterLooterGuid(ObjectGuid guid); diff --git a/src/server/game/Groups/GroupMgr.cpp b/src/server/game/Groups/GroupMgr.cpp index b8c8157b6d9..0fd2e7c7095 100644 --- a/src/server/game/Groups/GroupMgr.cpp +++ b/src/server/game/Groups/GroupMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Groups/GroupMgr.h b/src/server/game/Groups/GroupMgr.h index ec02de16bc2..9afdddd0f18 100644 --- a/src/server/game/Groups/GroupMgr.h +++ b/src/server/game/Groups/GroupMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Groups/GroupRefManager.h b/src/server/game/Groups/GroupRefManager.h index afb32e1657f..4cb9e60a268 100644 --- a/src/server/game/Groups/GroupRefManager.h +++ b/src/server/game/Groups/GroupRefManager.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Groups/GroupReference.cpp b/src/server/game/Groups/GroupReference.cpp index 0567ab652fa..b1d9d415489 100644 --- a/src/server/game/Groups/GroupReference.cpp +++ b/src/server/game/Groups/GroupReference.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Groups/GroupReference.h b/src/server/game/Groups/GroupReference.h index 5eded9e0594..4718dda1832 100644 --- a/src/server/game/Groups/GroupReference.h +++ b/src/server/game/Groups/GroupReference.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Guilds/Guild.cpp b/src/server/game/Guilds/Guild.cpp index d2fcad512bb..87494e78a28 100644 --- a/src/server/game/Guilds/Guild.cpp +++ b/src/server/game/Guilds/Guild.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Guilds/Guild.h b/src/server/game/Guilds/Guild.h index ca5ea95ee2c..2bc57a70671 100644 --- a/src/server/game/Guilds/Guild.h +++ b/src/server/game/Guilds/Guild.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Guilds/GuildMgr.cpp b/src/server/game/Guilds/GuildMgr.cpp index 6a75761ded0..2d4fb849fb5 100644 --- a/src/server/game/Guilds/GuildMgr.cpp +++ b/src/server/game/Guilds/GuildMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Guilds/GuildMgr.h b/src/server/game/Guilds/GuildMgr.h index 1450769c578..a97a59cafe0 100644 --- a/src/server/game/Guilds/GuildMgr.h +++ b/src/server/game/Guilds/GuildMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Handlers/AddonHandler.cpp b/src/server/game/Handlers/AddonHandler.cpp index adb76846379..ad44e0993e4 100644 --- a/src/server/game/Handlers/AddonHandler.cpp +++ b/src/server/game/Handlers/AddonHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/AddonHandler.h b/src/server/game/Handlers/AddonHandler.h index 7458e00180b..1e8081e0913 100644 --- a/src/server/game/Handlers/AddonHandler.h +++ b/src/server/game/Handlers/AddonHandler.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/ArenaTeamHandler.cpp b/src/server/game/Handlers/ArenaTeamHandler.cpp index 5616eb89b07..55d949c245d 100644 --- a/src/server/game/Handlers/ArenaTeamHandler.cpp +++ b/src/server/game/Handlers/ArenaTeamHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/AuctionHouseHandler.cpp b/src/server/game/Handlers/AuctionHouseHandler.cpp index a9680ff69bb..efe0526baae 100644 --- a/src/server/game/Handlers/AuctionHouseHandler.cpp +++ b/src/server/game/Handlers/AuctionHouseHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -706,7 +706,7 @@ void WorldSession::HandleAuctionListItems(WorldPacket& recvData) TC_LOG_DEBUG("network", "WORLD: Received CMSG_AUCTION_LIST_ITEMS"); std::string searchedname; - uint8 levelmin, levelmax, usable; + uint8 levelmin, levelmax, usable, getAll; uint32 listfrom, auctionSlotID, auctionMainCategory, auctionSubCategory, quality; ObjectGuid guid; @@ -718,7 +718,7 @@ void WorldSession::HandleAuctionListItems(WorldPacket& recvData) recvData >> auctionSlotID >> auctionMainCategory >> auctionSubCategory; recvData >> quality >> usable; - recvData.read_skip<uint8>(); // unk + recvData >> getAll; // this block looks like it uses some lame byte packing or similar... uint8 unkCnt; @@ -760,11 +760,11 @@ void WorldSession::HandleAuctionListItems(WorldPacket& recvData) auctionHouse->BuildListAuctionItems(data, _player, wsearchedname, listfrom, levelmin, levelmax, usable, auctionSlotID, auctionMainCategory, auctionSubCategory, quality, - count, totalcount); + count, totalcount, (getAll != 0 && sWorld->getIntConfig(CONFIG_AUCTION_GETALL_DELAY) != 0)); data.put<uint32>(0, count); data << (uint32) totalcount; - data << (uint32) 300; // unk 2.3.0 const? + data << (uint32) sWorld->getIntConfig(CONFIG_AUCTION_SEARCH_DELAY); SendPacket(&data); } diff --git a/src/server/game/Handlers/AuthHandler.cpp b/src/server/game/Handlers/AuthHandler.cpp index 8e87fc32f27..ad7e3c0489c 100644 --- a/src/server/game/Handlers/AuthHandler.cpp +++ b/src/server/game/Handlers/AuthHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Handlers/BattleGroundHandler.cpp b/src/server/game/Handlers/BattleGroundHandler.cpp index d4291e34df6..e91da35c06b 100644 --- a/src/server/game/Handlers/BattleGroundHandler.cpp +++ b/src/server/game/Handlers/BattleGroundHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/BattlefieldHandler.cpp b/src/server/game/Handlers/BattlefieldHandler.cpp index 69e36e7328d..9d5653fc247 100644 --- a/src/server/game/Handlers/BattlefieldHandler.cpp +++ b/src/server/game/Handlers/BattlefieldHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Handlers/CalendarHandler.cpp b/src/server/game/Handlers/CalendarHandler.cpp index e9b3bea5991..540eeba0752 100644 --- a/src/server/game/Handlers/CalendarHandler.cpp +++ b/src/server/game/Handlers/CalendarHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -695,6 +695,21 @@ void WorldSession::HandleSetSavedInstanceExtend(WorldPacket& recvData) recvData >> mapId >> difficulty>> toggleExtend; TC_LOG_DEBUG("network", "CMSG_SET_SAVED_INSTANCE_EXTEND - MapId: %u, Difficulty: %u, ToggleExtend: %s", mapId, difficulty, toggleExtend ? "On" : "Off"); + if (Player* player = GetPlayer()) + { + InstancePlayerBind* instanceBind = player->GetBoundInstance(mapId, Difficulty(difficulty), toggleExtend == 1); // include expired instances if we are toggling extend on + if (!instanceBind || !instanceBind->save || !instanceBind->perm) + return; + + BindExtensionState newState; + if (!toggleExtend || instanceBind->extendState == EXTEND_STATE_EXPIRED) + newState = EXTEND_STATE_NORMAL; + else + newState = EXTEND_STATE_EXTENDED; + + player->BindToInstance(instanceBind->save, true, newState, false); + } + /* InstancePlayerBind* instanceBind = _player->GetBoundInstance(mapId, Difficulty(difficulty)); if (!instanceBind || !instanceBind->save) diff --git a/src/server/game/Handlers/ChannelHandler.cpp b/src/server/game/Handlers/ChannelHandler.cpp index ee1456fd4b7..9285f4247b2 100644 --- a/src/server/game/Handlers/ChannelHandler.cpp +++ b/src/server/game/Handlers/ChannelHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -39,7 +39,7 @@ void WorldSession::HandleJoinChannel(WorldPacket& recvPacket) if (!channel) return; - AreaTableEntry const* zone = GetAreaEntryByAreaID(GetPlayer()->GetZoneId()); + AreaTableEntry const* zone = sAreaTableStore.LookupEntry(GetPlayer()->GetZoneId()); if (!zone || !GetPlayer()->CanJoinConstantChannelInZone(channel, zone)) return; } diff --git a/src/server/game/Handlers/CharacterHandler.cpp b/src/server/game/Handlers/CharacterHandler.cpp index 60ec60443d6..e0d790312d2 100644 --- a/src/server/game/Handlers/CharacterHandler.cpp +++ b/src/server/game/Handlers/CharacterHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/ChatHandler.cpp b/src/server/game/Handlers/ChatHandler.cpp index e13b417215b..346adf6f091 100644 --- a/src/server/game/Handlers/ChatHandler.cpp +++ b/src/server/game/Handlers/ChatHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/CombatHandler.cpp b/src/server/game/Handlers/CombatHandler.cpp index 78aeaa1b41b..4302e6472b5 100644 --- a/src/server/game/Handlers/CombatHandler.cpp +++ b/src/server/game/Handlers/CombatHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/DuelHandler.cpp b/src/server/game/Handlers/DuelHandler.cpp index 2f39a91afbe..51a9f768d20 100644 --- a/src/server/game/Handlers/DuelHandler.cpp +++ b/src/server/game/Handlers/DuelHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/GroupHandler.cpp b/src/server/game/Handlers/GroupHandler.cpp index 9f225df8427..84cbb86345d 100644 --- a/src/server/game/Handlers/GroupHandler.cpp +++ b/src/server/game/Handlers/GroupHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/GuildHandler.cpp b/src/server/game/Handlers/GuildHandler.cpp index ca7b4a5f8cf..e8f8372d679 100644 --- a/src/server/game/Handlers/GuildHandler.cpp +++ b/src/server/game/Handlers/GuildHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/ItemHandler.cpp b/src/server/game/Handlers/ItemHandler.cpp index b1f46c381bf..7f5d882a912 100644 --- a/src/server/game/Handlers/ItemHandler.cpp +++ b/src/server/game/Handlers/ItemHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/LFGHandler.cpp b/src/server/game/Handlers/LFGHandler.cpp index e18e7830cfb..3c89ad9d540 100644 --- a/src/server/game/Handlers/LFGHandler.cpp +++ b/src/server/game/Handlers/LFGHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Handlers/LootHandler.cpp b/src/server/game/Handlers/LootHandler.cpp index 9876e939395..82fdc2e54c7 100644 --- a/src/server/game/Handlers/LootHandler.cpp +++ b/src/server/game/Handlers/LootHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/MailHandler.cpp b/src/server/game/Handlers/MailHandler.cpp index 5f25f57addd..aaf6ca39d09 100644 --- a/src/server/game/Handlers/MailHandler.cpp +++ b/src/server/game/Handlers/MailHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Handlers/MiscHandler.cpp b/src/server/game/Handlers/MiscHandler.cpp index 6dcd3242a6c..5f5a66e7b20 100644 --- a/src/server/game/Handlers/MiscHandler.cpp +++ b/src/server/game/Handlers/MiscHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -71,6 +71,7 @@ void WorldSession::HandleRepopRequestOpcode(WorldPacket& recvData) } //this is spirit release confirm? + GetPlayer()->RemoveGhoul(); GetPlayer()->RemovePet(NULL, PET_SAVE_NOT_IN_SLOT, true); GetPlayer()->BuildPlayerRepop(); GetPlayer()->RepopAtGraveyard(); @@ -104,7 +105,7 @@ void WorldSession::HandleGossipSelectOptionOpcode(WorldPacket& recvData) GameObject* go = NULL; if (guid.IsCreatureOrVehicle()) { - unit = GetPlayer()->GetNPCIfCanInteractWith(guid, UNIT_NPC_FLAG_NONE); + unit = GetPlayer()->GetNPCIfCanInteractWith(guid, UNIT_NPC_FLAG_GOSSIP); if (!unit) { TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - %s not found or you can't interact with him.", guid.ToString().c_str()); @@ -113,10 +114,10 @@ void WorldSession::HandleGossipSelectOptionOpcode(WorldPacket& recvData) } else if (guid.IsGameObject()) { - go = _player->GetMap()->GetGameObject(guid); + go = _player->GetGameObjectIfCanInteractWith(guid); if (!go) { - TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - %s not found.", guid.ToString().c_str()); + TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - %s not found or you can't interact with it.", guid.ToString().c_str()); return; } } @@ -318,7 +319,7 @@ void WorldSession::HandleWhoOpcode(WorldPacket& recvData) continue; std::string aname; - if (AreaTableEntry const* areaEntry = GetAreaEntryByAreaID(pzoneid)) + if (AreaTableEntry const* areaEntry = sAreaTableStore.LookupEntry(pzoneid)) aname = areaEntry->area_name[GetSessionDbcLocale()]; bool s_show = true; @@ -776,6 +777,12 @@ void WorldSession::HandleResurrectResponseOpcode(WorldPacket& recvData) return; } + if (GetPlayer()->IsValidGhoulResurrectRequest(guid)) + { + GetPlayer()->GhoulResurrect(); + return; + } + if (!GetPlayer()->isResurrectRequestedBy(guid)) return; @@ -866,8 +873,77 @@ void WorldSession::HandleAreaTriggerOpcode(WorldPacket& recvData) bool teleported = false; if (player->GetMapId() != at->target_mapId) { - if (!sMapMgr->CanPlayerEnter(at->target_mapId, player, false)) + if (Map::EnterState denyReason = sMapMgr->PlayerCannotEnter(at->target_mapId, player, false)) + { + bool reviveAtTrigger = false; // should we revive the player if he is trying to enter the correct instance? + switch (denyReason) + { + case Map::CANNOT_ENTER_NO_ENTRY: + TC_LOG_DEBUG("maps", "MAP: Player '%s' attempted to enter map with id %d which has no entry", player->GetName().c_str(), at->target_mapId); + break; + case Map::CANNOT_ENTER_UNINSTANCED_DUNGEON: + TC_LOG_DEBUG("maps", "MAP: Player '%s' attempted to enter dungeon map %d but no instance template was found", player->GetName().c_str(), at->target_mapId); + break; + case Map::CANNOT_ENTER_DIFFICULTY_UNAVAILABLE: + TC_LOG_DEBUG("maps", "MAP: Player '%s' attempted to enter instance map %d but the requested difficulty was not found", player->GetName().c_str(), at->target_mapId); + if (MapEntry const* entry = sMapStore.LookupEntry(at->target_mapId)) + player->SendTransferAborted(entry->MapID, TRANSFER_ABORT_DIFFICULTY, player->GetDifficulty(entry->IsRaid())); + break; + case Map::CANNOT_ENTER_NOT_IN_RAID: + if (MapEntry const* entry = sMapStore.LookupEntry(at->target_mapId)) + { + char const* mapName = entry->name[player->GetSession()->GetSessionDbcLocale()]; + TC_LOG_DEBUG("maps", "MAP: Player '%s' must be in a raid group to enter instance '%s'", player->GetName().c_str(), mapName); + // probably there must be special opcode, because client has this string constant in GlobalStrings.lua + player->GetSession()->SendAreaTriggerMessage(player->GetSession()->GetTrinityString(LANG_INSTANCE_RAID_GROUP_ONLY), mapName); + } + reviveAtTrigger = true; + break; + case Map::CANNOT_ENTER_CORPSE_IN_DIFFERENT_INSTANCE: + { + WorldPacket data(SMSG_CORPSE_NOT_IN_INSTANCE); + player->GetSession()->SendPacket(&data); + TC_LOG_DEBUG("maps", "MAP: Player '%s' does not have a corpse in instance map %d and cannot enter", player->GetName().c_str(), at->target_mapId); + break; + } + case Map::CANNOT_ENTER_INSTANCE_BIND_MISMATCH: + if (MapEntry const* entry = sMapStore.LookupEntry(at->target_mapId)) + { + char const* mapName = entry->name[player->GetSession()->GetSessionDbcLocale()]; + TC_LOG_DEBUG("maps", "MAP: Player '%s' cannot enter instance map '%s' because their permanent bind is incompatible with their group's", player->GetName().c_str(), mapName); + // is there a special opcode for this? + // @todo figure out how to get player localized difficulty string (e.g. "10 player", "Heroic" etc) + ChatHandler(player->GetSession()).PSendSysMessage(player->GetSession()->GetTrinityString(LANG_INSTANCE_BIND_MISMATCH), mapName); + } + reviveAtTrigger = true; + break; + case Map::CANNOT_ENTER_TOO_MANY_INSTANCES: + player->SendTransferAborted(at->target_mapId, TRANSFER_ABORT_TOO_MANY_INSTANCES); + TC_LOG_DEBUG("maps", "MAP: Player '%s' cannot enter instance map %d because he has exceeded the maximum number of instances per hour.", player->GetName().c_str(), at->target_mapId); + reviveAtTrigger = true; + break; + case Map::CANNOT_ENTER_MAX_PLAYERS: + player->SendTransferAborted(at->target_mapId, TRANSFER_ABORT_MAX_PLAYERS); + reviveAtTrigger = true; + break; + case Map::CANNOT_ENTER_ZONE_IN_COMBAT: + player->SendTransferAborted(at->target_mapId, TRANSFER_ABORT_ZONE_IN_COMBAT); + reviveAtTrigger = true; + break; + default: + break; + } + + if (reviveAtTrigger) // check if the player is touching the areatrigger leading to the map his corpse is on + if (!player->IsAlive() && player->HasCorpse()) + if (player->GetCorpseLocation().GetMapId() == at->target_mapId) + { + player->ResurrectPlayer(0.5f); + player->SpawnCorpseBones(); + } + return; + } if (Group* group = player->GetGroup()) if (group->isLFGGroup() && player->GetMap()->IsDungeon()) @@ -1677,7 +1753,7 @@ void WorldSession::HandleHearthAndResurrect(WorldPacket& /*recvData*/) return; } - AreaTableEntry const* atEntry = GetAreaEntryByAreaID(_player->GetAreaId()); + AreaTableEntry const* atEntry = sAreaTableStore.LookupEntry(_player->GetAreaId()); if (!atEntry || !(atEntry->flags & AREA_FLAG_WINTERGRASP_2)) return; diff --git a/src/server/game/Handlers/MovementHandler.cpp b/src/server/game/Handlers/MovementHandler.cpp index 84816bf3f33..02702fc5622 100644 --- a/src/server/game/Handlers/MovementHandler.cpp +++ b/src/server/game/Handlers/MovementHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -75,9 +75,9 @@ void WorldSession::HandleMoveWorldportAckOpcode() } // relocate the player to the teleport destination - // the CanEnter checks are done in TeleporTo but conditions may change + // the CannotEnter checks are done in TeleporTo but conditions may change // while the player is in transit, for example the map may get full - if (!newMap || !newMap->CanEnter(GetPlayer())) + if (!newMap || newMap->CannotEnter(GetPlayer())) { TC_LOG_ERROR("network", "Map %d (%s) could not be created for player %d (%s), porting player to homebind", loc.GetMapId(), newMap ? newMap->GetMapName() : "Unknown", GetPlayer()->GetGUID().GetCounter(), GetPlayer()->GetName().c_str()); GetPlayer()->TeleportTo(GetPlayer()->m_homebindMapId, GetPlayer()->m_homebindX, GetPlayer()->m_homebindY, GetPlayer()->m_homebindZ, GetPlayer()->GetOrientation()); @@ -142,19 +142,18 @@ void WorldSession::HandleMoveWorldportAckOpcode() } // resurrect character at enter into instance where his corpse exist after add to map - Corpse* corpse = GetPlayer()->GetMap()->GetCorpseByPlayer(GetPlayer()->GetGUID()); - if (corpse && corpse->GetType() != CORPSE_BONES) - { - if (mEntry->IsDungeon()) + + if (mEntry->IsDungeon() && !GetPlayer()->IsAlive()) + if (GetPlayer()->GetCorpseLocation().GetMapId() == mEntry->MapID) { GetPlayer()->ResurrectPlayer(0.5f, false); GetPlayer()->SpawnCorpseBones(); } - } bool allowMount = !mEntry->IsDungeon() || mEntry->IsBattlegroundOrArena(); if (mInstance) { + // check if this instance has a reset time and send it to player if so Difficulty diff = GetPlayer()->GetDifficulty(mEntry->IsRaid()); if (MapDifficulty const* mapDiff = GetMapDifficultyData(mEntry->MapID, diff)) { @@ -167,6 +166,12 @@ void WorldSession::HandleMoveWorldportAckOpcode() } } } + + // check if instance is valid + if (!GetPlayer()->CheckInstanceValidity(false)) + GetPlayer()->m_InstanceValid = false; + + // instance mounting is handled in InstanceTemplate allowMount = mInstance->AllowMount; } @@ -381,7 +386,7 @@ void WorldSession::HandleMovementOpcodes(WorldPacket& recvData) plrMover->UpdateFallInformationIfNeed(movementInfo, opcode); - if (movementInfo.pos.GetPositionZ() < -500.0f) + if (movementInfo.pos.GetPositionZ() < plrMover->GetMap()->GetMinHeight(movementInfo.pos.GetPositionX(), movementInfo.pos.GetPositionY())) { if (!(plrMover->GetBattleground() && plrMover->GetBattleground()->HandlePlayerUnderMap(_player))) { @@ -390,6 +395,7 @@ void WorldSession::HandleMovementOpcodes(WorldPacket& recvData) /// @todo discard movement packets after the player is rooted if (plrMover->IsAlive()) { + plrMover->SetFlag(PLAYER_FLAGS, PLAYER_FLAGS_IS_OUT_OF_BOUNDS); plrMover->EnvironmentalDamage(DAMAGE_FALL_TO_VOID, GetPlayer()->GetMaxHealth()); // player can be alive if GM/etc // change the death state to CORPSE to prevent the death timer from diff --git a/src/server/game/Handlers/NPCHandler.cpp b/src/server/game/Handlers/NPCHandler.cpp index f8d7f73e077..1e00c25a0c3 100644 --- a/src/server/game/Handlers/NPCHandler.cpp +++ b/src/server/game/Handlers/NPCHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -292,7 +292,7 @@ void WorldSession::HandleGossipHelloOpcode(WorldPacket& recvData) ObjectGuid guid; recvData >> guid; - Creature* unit = GetPlayer()->GetNPCIfCanInteractWith(guid, UNIT_NPC_FLAG_NONE); + Creature* unit = GetPlayer()->GetNPCIfCanInteractWith(guid, UNIT_NPC_FLAG_GOSSIP); if (!unit) { TC_LOG_DEBUG("network", "WORLD: HandleGossipHelloOpcode - %s not found or you can not interact with him.", guid.ToString().c_str()); @@ -334,47 +334,6 @@ void WorldSession::HandleGossipHelloOpcode(WorldPacket& recvData) unit->AI()->sGossipHello(_player); } -/*void WorldSession::HandleGossipSelectOptionOpcode(WorldPacket& recvData) -{ - TC_LOG_DEBUG("network", "WORLD: CMSG_GOSSIP_SELECT_OPTION"); - - uint32 option; - uint32 unk; - uint64 guid; - std::string code = ""; - - recvData >> guid >> unk >> option; - - if (_player->PlayerTalkClass->GossipOptionCoded(option)) - { - TC_LOG_DEBUG("network", "reading string"); - recvData >> code; - TC_LOG_DEBUG("network", "string read: %s", code.c_str()); - } - - Creature* unit = GetPlayer()->GetNPCIfCanInteractWith(guid, UNIT_NPC_FLAG_NONE); - if (!unit) - { - TC_LOG_DEBUG("network", "WORLD: HandleGossipSelectOptionOpcode - Unit (GUID: %u) not found or you can't interact with him.", uint32(GUID_LOPART(guid))); - return; - } - - // remove fake death - if (GetPlayer()->HasUnitState(UNIT_STATE_DIED)) - GetPlayer()->RemoveAurasByType(SPELL_AURA_FEIGN_DEATH); - - if (!code.empty()) - { - if (!Script->GossipSelectWithCode(_player, unit, _player->PlayerTalkClass->GossipOptionSender (option), _player->PlayerTalkClass->GossipOptionAction(option), code.c_str())) - unit->OnGossipSelect (_player, option); - } - else - { - if (!Script->OnGossipSelect (_player, unit, _player->PlayerTalkClass->GossipOptionSender (option), _player->PlayerTalkClass->GossipOptionAction (option))) - unit->OnGossipSelect (_player, option); - } -}*/ - void WorldSession::HandleSpiritHealerActivateOpcode(WorldPacket& recvData) { TC_LOG_DEBUG("network", "WORLD: CMSG_SPIRIT_HEALER_ACTIVATE"); diff --git a/src/server/game/Handlers/NPCHandler.h b/src/server/game/Handlers/NPCHandler.h index 3b96ae5f937..24c3e997bbd 100644 --- a/src/server/game/Handlers/NPCHandler.h +++ b/src/server/game/Handlers/NPCHandler.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/PetHandler.cpp b/src/server/game/Handlers/PetHandler.cpp index 8c3c3e9082b..8bfb0070605 100644 --- a/src/server/game/Handlers/PetHandler.cpp +++ b/src/server/game/Handlers/PetHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/PetitionsHandler.cpp b/src/server/game/Handlers/PetitionsHandler.cpp index 952659dcea5..781a478d751 100644 --- a/src/server/game/Handlers/PetitionsHandler.cpp +++ b/src/server/game/Handlers/PetitionsHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/QueryHandler.cpp b/src/server/game/Handlers/QueryHandler.cpp index 153ce736946..ebc9ebde994 100644 --- a/src/server/game/Handlers/QueryHandler.cpp +++ b/src/server/game/Handlers/QueryHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/QuestHandler.cpp b/src/server/game/Handlers/QuestHandler.cpp index fd7c4439c8f..a7db18deddb 100644 --- a/src/server/game/Handlers/QuestHandler.cpp +++ b/src/server/game/Handlers/QuestHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -75,7 +75,7 @@ void WorldSession::HandleQuestgiverHelloOpcode(WorldPacket& recvData) TC_LOG_DEBUG("network", "WORLD: Received CMSG_QUESTGIVER_HELLO %s", guid.ToString().c_str()); - Creature* creature = GetPlayer()->GetNPCIfCanInteractWith(guid, UNIT_NPC_FLAG_NONE); + Creature* creature = GetPlayer()->GetNPCIfCanInteractWith(guid, UNIT_NPC_FLAG_QUESTGIVER); if (!creature) { TC_LOG_DEBUG("network", "WORLD: HandleQuestgiverHelloOpcode - %s not found or you can't interact with him.", @@ -102,12 +102,16 @@ void WorldSession::HandleQuestgiverAcceptQuestOpcode(WorldPacket& recvData) { ObjectGuid guid; uint32 questId; - uint32 unk1; - recvData >> guid >> questId >> unk1; + uint32 startCheat; + recvData >> guid >> questId >> startCheat; - TC_LOG_DEBUG("network", "WORLD: Received CMSG_QUESTGIVER_ACCEPT_QUEST %s, quest = %u, unk1 = %u", guid.ToString().c_str(), questId, unk1); + TC_LOG_DEBUG("network", "WORLD: Received CMSG_QUESTGIVER_ACCEPT_QUEST %s, quest = %u, startCheat = %u", guid.ToString().c_str(), questId, startCheat); - Object* object = ObjectAccessor::GetObjectByTypeMask(*_player, guid, TYPEMASK_UNIT|TYPEMASK_GAMEOBJECT|TYPEMASK_ITEM|TYPEMASK_PLAYER); + Object* object; + if (!guid.IsPlayer()) + object = ObjectAccessor::GetObjectByTypeMask(*_player, guid, TYPEMASK_UNIT | TYPEMASK_GAMEOBJECT | TYPEMASK_ITEM); + else + object = ObjectAccessor::FindPlayer(guid); #define CLOSE_GOSSIP_CLEAR_DIVIDER() \ do { \ @@ -129,6 +133,11 @@ void WorldSession::HandleQuestgiverAcceptQuestOpcode(WorldPacket& recvData) CLOSE_GOSSIP_CLEAR_DIVIDER(); return; } + if (!_player->IsInSameRaidWith(playerQuestObject)) + { + CLOSE_GOSSIP_CLEAR_DIVIDER(); + return; + } } else { @@ -141,7 +150,10 @@ void WorldSession::HandleQuestgiverAcceptQuestOpcode(WorldPacket& recvData) // some kind of WPE protection if (!_player->CanInteractWithQuestGiver(object)) + { + CLOSE_GOSSIP_CLEAR_DIVIDER(); return; + } if (Quest const* quest = sObjectMgr->GetQuestTemplate(questId)) { @@ -199,7 +211,7 @@ void WorldSession::HandleQuestgiverAcceptQuestOpcode(WorldPacket& recvData) } } - _player->PlayerTalkClass->SendCloseGossip(); + CLOSE_GOSSIP_CLEAR_DIVIDER(); #undef CLOSE_GOSSIP_CLEAR_DIVIDER } @@ -456,17 +468,22 @@ void WorldSession::HandleQuestConfirmAccept(WorldPacket& recvData) if (!_player->IsInSameRaidWith(originalPlayer)) return; - if (!originalPlayer->CanShareQuest(questId)) + if (!originalPlayer->IsActiveQuest(questId)) return; if (!_player->CanTakeQuest(quest, true)) return; if (_player->CanAddQuest(quest, true)) + { _player->AddQuestAndCheckCompletion(quest, NULL); // NULL, this prevent DB script from duplicate running - _player->SetDivider(ObjectGuid::Empty); + if (quest->GetSrcSpell() > 0) + _player->CastSpell(_player, quest->GetSrcSpell(), true); + } } + + _player->SetDivider(ObjectGuid::Empty); } void WorldSession::HandleQuestgiverCompleteQuest(WorldPacket& recvData) @@ -588,7 +605,7 @@ void WorldSession::HandlePushQuestToParty(WorldPacket& recvPacket) else { receiver->SetDivider(sender->GetGUID()); - receiver->PlayerTalkClass->SendQuestGiverQuestDetails(quest, sender->GetGUID(), true); + receiver->PlayerTalkClass->SendQuestGiverQuestDetails(quest, receiver->GetGUID(), true); } } } @@ -602,17 +619,20 @@ void WorldSession::HandleQuestPushResult(WorldPacket& recvPacket) TC_LOG_DEBUG("network", "WORLD: Received MSG_QUEST_PUSH_RESULT"); - if (_player->GetDivider() && _player->GetDivider() == guid) + if (_player->GetDivider()) { - Player* player = ObjectAccessor::FindPlayer(_player->GetDivider()); - if (player) + if (_player->GetDivider() == guid) { - WorldPacket data(MSG_QUEST_PUSH_RESULT, 8 + 4 + 1); - data << uint64(_player->GetGUID()); - data << uint8(msg); // valid values: 0-8 - player->SendDirectMessage(&data); - _player->SetDivider(ObjectGuid::Empty); + Player* player = ObjectAccessor::FindPlayer(_player->GetDivider()); + if (player) + { + WorldPacket data(MSG_QUEST_PUSH_RESULT, 8 + 4 + 1); + data << uint64(_player->GetGUID()); + data << uint8(msg); // valid values: 0-8 + player->SendDirectMessage(&data); + } } + _player->SetDivider(ObjectGuid::Empty); } } diff --git a/src/server/game/Handlers/ReferAFriendHandler.cpp b/src/server/game/Handlers/ReferAFriendHandler.cpp index db5d0997eeb..3e602d1c342 100644 --- a/src/server/game/Handlers/ReferAFriendHandler.cpp +++ b/src/server/game/Handlers/ReferAFriendHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Handlers/SkillHandler.cpp b/src/server/game/Handlers/SkillHandler.cpp index 5f50a7305ee..0bc90c896ae 100644 --- a/src/server/game/Handlers/SkillHandler.cpp +++ b/src/server/game/Handlers/SkillHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/SpellHandler.cpp b/src/server/game/Handlers/SpellHandler.cpp index 0f0640e3a2e..6be1fd30ae3 100644 --- a/src/server/game/Handlers/SpellHandler.cpp +++ b/src/server/game/Handlers/SpellHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -268,11 +268,8 @@ void WorldSession::HandleGameObjectUseOpcode(WorldPacket& recvData) TC_LOG_DEBUG("network", "WORLD: Recvd CMSG_GAMEOBJ_USE Message [%s]", guid.ToString().c_str()); - if (GameObject* obj = GetPlayer()->GetMap()->GetGameObject(guid)) + if (GameObject* obj = GetPlayer()->GetGameObjectIfCanInteractWith(guid)) { - if (!obj->IsWithinDistInMap(GetPlayer(), obj->GetInteractionDistance())) - return; - // ignore for remote control state if (GetPlayer()->m_mover != GetPlayer()) if (!(GetPlayer()->IsOnVehicle(GetPlayer()->m_mover) || GetPlayer()->IsMounted()) && !obj->GetGOInfo()->IsUsableMounted()) @@ -293,17 +290,13 @@ void WorldSession::HandleGameobjectReportUse(WorldPacket& recvPacket) if (_player->m_mover != _player) return; - GameObject* go = GetPlayer()->GetMap()->GetGameObject(guid); - if (!go) - return; - - if (!go->IsWithinDistInMap(_player, INTERACTION_DISTANCE)) - return; - - if (go->AI()->GossipHello(_player)) - return; + if (GameObject* go = GetPlayer()->GetGameObjectIfCanInteractWith(guid)) + { + if (go->AI()->GossipHello(_player)) + return; - _player->UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_USE_GAMEOBJECT, go->GetEntry()); + _player->UpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_USE_GAMEOBJECT, go->GetEntry()); + } } void WorldSession::HandleCastSpellOpcode(WorldPacket& recvPacket) diff --git a/src/server/game/Handlers/TaxiHandler.cpp b/src/server/game/Handlers/TaxiHandler.cpp index a671250c17d..122534c1102 100644 --- a/src/server/game/Handlers/TaxiHandler.cpp +++ b/src/server/game/Handlers/TaxiHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/TicketHandler.cpp b/src/server/game/Handlers/TicketHandler.cpp index cf6181f02b4..a7f236890f8 100644 --- a/src/server/game/Handlers/TicketHandler.cpp +++ b/src/server/game/Handlers/TicketHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/TradeHandler.cpp b/src/server/game/Handlers/TradeHandler.cpp index 1bb21971935..e2743f8f456 100644 --- a/src/server/game/Handlers/TradeHandler.cpp +++ b/src/server/game/Handlers/TradeHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Handlers/VehicleHandler.cpp b/src/server/game/Handlers/VehicleHandler.cpp index 3bb2ca78931..b302b318528 100644 --- a/src/server/game/Handlers/VehicleHandler.cpp +++ b/src/server/game/Handlers/VehicleHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Handlers/VoiceChatHandler.cpp b/src/server/game/Handlers/VoiceChatHandler.cpp index e667eb4bfd9..efd664fd1f5 100644 --- a/src/server/game/Handlers/VoiceChatHandler.cpp +++ b/src/server/game/Handlers/VoiceChatHandler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Instances/InstanceSaveMgr.cpp b/src/server/game/Instances/InstanceSaveMgr.cpp index b3dd3e9f01f..3538262ed35 100644 --- a/src/server/game/Instances/InstanceSaveMgr.cpp +++ b/src/server/game/Instances/InstanceSaveMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -439,6 +439,23 @@ void InstanceSaveManager::LoadResetTimes() } } +time_t InstanceSaveManager::GetSubsequentResetTime(uint32 mapid, Difficulty difficulty, time_t resetTime) const +{ + MapDifficulty const* mapDiff = GetMapDifficultyData(mapid, difficulty); + if (!mapDiff || !mapDiff->resetTime) + { + TC_LOG_ERROR("misc", "InstanceSaveManager::GetSubsequentResetTime: not valid difficulty or no reset delay for map %u", mapid); + return 0; + } + + time_t diff = sWorld->getIntConfig(CONFIG_INSTANCE_RESET_TIME_HOUR) * HOUR; + time_t period = uint32(((mapDiff->resetTime * sWorld->getRate(RATE_INSTANCE_RESET_TIME)) / DAY) * DAY); + if (period < DAY) + period = DAY; + + return ((resetTime + MINUTE) / DAY * DAY) + period + diff; +} + void InstanceSaveManager::ScheduleReset(bool add, time_t time, InstResetEvent event) { if (!add) @@ -476,6 +493,17 @@ void InstanceSaveManager::ScheduleReset(bool add, time_t time, InstResetEvent ev m_resetTimeQueue.insert(std::pair<time_t, InstResetEvent>(time, event)); } +void InstanceSaveManager::ForceGlobalReset(uint32 mapId, Difficulty difficulty) +{ + if (!GetDownscaledMapDifficultyData(mapId, difficulty)) + return; + // remove currently scheduled reset times + ScheduleReset(false, 0, InstResetEvent(1, mapId, difficulty, 0)); + ScheduleReset(false, 0, InstResetEvent(4, mapId, difficulty, 0)); + // force global reset on the instance + _ResetOrWarnAll(mapId, difficulty, false, time(nullptr)); +} + void InstanceSaveManager::Update() { time_t now = time(NULL); @@ -516,10 +544,26 @@ void InstanceSaveManager::_ResetSave(InstanceSaveHashMap::iterator &itr) // do not allow UnbindInstance to automatically unload the InstanceSaves lock_instLists = true; + bool shouldDelete = true; InstanceSave::PlayerListType &pList = itr->second->m_playerList; - while (!pList.empty()) + std::vector<Player*> temp; // list of expired binds that should be unbound + for (Player* player : pList) + { + if (InstancePlayerBind* bind = player->GetBoundInstance(itr->second->GetMapId(), itr->second->GetDifficulty())) + { + ASSERT(bind->save == itr->second); + if (bind->perm && bind->extendState) // permanent and not already expired + { + // actual promotion in DB already happened in caller + bind->extendState = bind->extendState == EXTEND_STATE_EXTENDED ? EXTEND_STATE_NORMAL : EXTEND_STATE_EXPIRED; + shouldDelete = false; + continue; + } + } + temp.push_back(player); + } + for (Player* player : temp) { - Player* player = *(pList.begin()); player->UnbindInstance(itr->second->GetMapId(), itr->second->GetDifficulty(), true); } @@ -530,8 +574,13 @@ void InstanceSaveManager::_ResetSave(InstanceSaveHashMap::iterator &itr) group->UnbindInstance(itr->second->GetMapId(), itr->second->GetDifficulty(), true); } - delete itr->second; - m_instanceSaveById.erase(itr++); + if (shouldDelete) + { + delete itr->second; + itr = m_instanceSaveById.erase(itr); + } + else + ++itr; lock_instLists = false; } @@ -572,31 +621,21 @@ void InstanceSaveManager::_ResetOrWarnAll(uint32 mapid, Difficulty difficulty, b MapEntry const* mapEntry = sMapStore.LookupEntry(mapid); if (!mapEntry->Instanceable()) return; + TC_LOG_DEBUG("misc", "InstanceSaveManager::ResetOrWarnAll: Processing map %s (%u) on difficulty %u (warn? %u)", mapEntry->name[0], mapid, uint8(difficulty), warn); time_t now = time(NULL); if (!warn) { - MapDifficulty const* mapDiff = GetMapDifficultyData(mapid, difficulty); - if (!mapDiff || !mapDiff->resetTime) - { - TC_LOG_ERROR("misc", "InstanceSaveManager::ResetOrWarnAll: not valid difficulty or no reset delay for map %d", mapid); + // calculate the next reset time + time_t next_reset = GetSubsequentResetTime(mapid, difficulty, resetTime); + if (!next_reset) return; - } - // remove all binds to instances of the given map - for (InstanceSaveHashMap::iterator itr = m_instanceSaveById.begin(); itr != m_instanceSaveById.end();) - { - if (itr->second->GetMapId() == mapid && itr->second->GetDifficulty() == difficulty) - _ResetSave(itr); - else - ++itr; - } - - // delete them from the DB, even if not loaded + // delete/promote instance binds from the DB, even if not loaded SQLTransaction trans = CharacterDatabase.BeginTransaction(); - PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_CHAR_INSTANCE_BY_MAP_DIFF); + PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_EXPIRED_CHAR_INSTANCE_BY_MAP_DIFF); stmt->setUInt16(0, uint16(mapid)); stmt->setUInt8(1, uint8(difficulty)); trans->Append(stmt); @@ -606,21 +645,26 @@ void InstanceSaveManager::_ResetOrWarnAll(uint32 mapid, Difficulty difficulty, b stmt->setUInt8(1, uint8(difficulty)); trans->Append(stmt); - stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_INSTANCE_BY_MAP_DIFF); + stmt = CharacterDatabase.GetPreparedStatement(CHAR_DEL_EXPIRED_INSTANCE_BY_MAP_DIFF); stmt->setUInt16(0, uint16(mapid)); stmt->setUInt8(1, uint8(difficulty)); trans->Append(stmt); - CharacterDatabase.CommitTransaction(trans); - - // calculate the next reset time - uint32 diff = sWorld->getIntConfig(CONFIG_INSTANCE_RESET_TIME_HOUR) * HOUR; + stmt = CharacterDatabase.GetPreparedStatement(CHAR_UPD_EXPIRE_CHAR_INSTANCE_BY_MAP_DIFF); + stmt->setUInt16(0, uint16(mapid)); + stmt->setUInt8(1, uint8(difficulty)); + trans->Append(stmt); - uint32 period = uint32(((mapDiff->resetTime * sWorld->getRate(RATE_INSTANCE_RESET_TIME))/DAY) * DAY); - if (period < DAY) - period = DAY; + CharacterDatabase.CommitTransaction(trans); - uint32 next_reset = uint32(((resetTime + MINUTE) / DAY * DAY) + period + diff); + // promote loaded binds to instances of the given map + for (InstanceSaveHashMap::iterator itr = m_instanceSaveById.begin(); itr != m_instanceSaveById.end();) + { + if (itr->second->GetMapId() == mapid && itr->second->GetDifficulty() == difficulty) + _ResetSave(itr); + else + ++itr; + } SetResetTimeFor(mapid, difficulty, next_reset); ScheduleReset(true, time_t(next_reset-3600), InstResetEvent(1, mapid, difficulty, 0)); diff --git a/src/server/game/Instances/InstanceSaveMgr.h b/src/server/game/Instances/InstanceSaveMgr.h index 5e8292057a8..d2b3237b3cf 100644 --- a/src/server/game/Instances/InstanceSaveMgr.h +++ b/src/server/game/Instances/InstanceSaveMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -190,6 +190,7 @@ class InstanceSaveManager ResetTimeByMapDifficultyMap::const_iterator itr = m_resetTimeByMapDifficulty.find(MAKE_PAIR32(mapid, d)); return itr != m_resetTimeByMapDifficulty.end() ? itr->second : 0; } + time_t GetSubsequentResetTime(uint32 mapid, Difficulty difficulty, time_t resetTime) const; // Use this on startup when initializing reset times void InitializeResetTimeFor(uint32 mapid, Difficulty d, time_t t) @@ -210,6 +211,7 @@ class InstanceSaveManager return m_resetTimeByMapDifficulty; } void ScheduleReset(bool add, time_t time, InstResetEvent event); + void ForceGlobalReset(uint32 mapId, Difficulty difficulty); void Update(); diff --git a/src/server/game/Instances/InstanceScript.cpp b/src/server/game/Instances/InstanceScript.cpp index a8cf42ea49e..1575b50098f 100644 --- a/src/server/game/Instances/InstanceScript.cpp +++ b/src/server/game/Instances/InstanceScript.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -30,6 +30,12 @@ #include "WorldSession.h" #include "Opcodes.h" +BossBoundaryData::~BossBoundaryData() +{ + for (const_iterator it = begin(); it != end(); ++it) + delete it->Boundary; +} + void InstanceScript::SaveToDB() { std::string data = GetSaveData(); @@ -96,6 +102,13 @@ void InstanceScript::SetHeaders(std::string const& dataHeaders) headers.push_back(header); } +void InstanceScript::LoadBossBoundaries(const BossBoundaryData& data) +{ + for (BossBoundaryEntry const& entry : data) + if (entry.BossId < bosses.size()) + bosses[entry.BossId].boundary.insert(entry.Boundary); +} + void InstanceScript::LoadMinionData(const MinionData* data) { while (data->entry) @@ -113,7 +126,7 @@ void InstanceScript::LoadDoorData(const DoorData* data) while (data->entry) { if (data->bossId < bosses.size()) - doors.insert(std::make_pair(data->entry, DoorInfo(&bosses[data->bossId], data->type, BoundaryType(data->boundary)))); + doors.insert(std::make_pair(data->entry, DoorInfo(&bosses[data->bossId], data->type))); ++data; } @@ -236,28 +249,6 @@ void InstanceScript::AddDoor(GameObject* door, bool add) if (add) { data.bossInfo->door[data.type].insert(door->GetGUID()); - switch (data.boundary) - { - default: - case BOUNDARY_NONE: - break; - case BOUNDARY_N: - case BOUNDARY_S: - data.bossInfo->boundary[data.boundary] = door->GetPositionX(); - break; - case BOUNDARY_E: - case BOUNDARY_W: - data.bossInfo->boundary[data.boundary] = door->GetPositionY(); - break; - case BOUNDARY_NW: - case BOUNDARY_SE: - data.bossInfo->boundary[data.boundary] = door->GetPositionX() + door->GetPositionY(); - break; - case BOUNDARY_NE: - case BOUNDARY_SW: - data.bossInfo->boundary[data.boundary] = door->GetPositionX() - door->GetPositionY(); - break; - } } else data.bossInfo->door[data.type].erase(door->GetGUID()); diff --git a/src/server/game/Instances/InstanceScript.h b/src/server/game/Instances/InstanceScript.h index 93dafea0413..ce83061e162 100644 --- a/src/server/game/Instances/InstanceScript.h +++ b/src/server/game/Instances/InstanceScript.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -19,9 +19,11 @@ #ifndef TRINITY_INSTANCE_DATA_H #define TRINITY_INSTANCE_DATA_H +#include <set> #include "ZoneScript.h" #include "World.h" #include "ObjectMgr.h" +#include "CreatureAI.h" #define OUT_SAVE_INST_DATA TC_LOG_DEBUG("scripts", "Saving Instance Data for Instance %s (Map %d, Instance Id %d)", instance->GetMapName(), instance->GetId(), instance->GetInstanceId()) #define OUT_SAVE_INST_DATA_COMPLETE TC_LOG_DEBUG("scripts", "Saving Instance Data for Instance %s (Map %d, Instance Id %d) completed.", instance->GetMapName(), instance->GetId(), instance->GetInstanceId()) @@ -65,30 +67,30 @@ enum DoorType MAX_DOOR_TYPES }; -enum BoundaryType +struct DoorData { - BOUNDARY_NONE = 0, - BOUNDARY_N, - BOUNDARY_S, - BOUNDARY_E, - BOUNDARY_W, - BOUNDARY_NE, - BOUNDARY_NW, - BOUNDARY_SE, - BOUNDARY_SW, - BOUNDARY_MAX_X = BOUNDARY_N, - BOUNDARY_MIN_X = BOUNDARY_S, - BOUNDARY_MAX_Y = BOUNDARY_W, - BOUNDARY_MIN_Y = BOUNDARY_E + uint32 entry, bossId; + DoorType type; }; -typedef std::map<BoundaryType, float> BossBoundaryMap; +struct BossBoundaryEntry +{ + uint32 BossId; + AreaBoundary const* Boundary; +}; -struct DoorData +struct BossBoundaryData { - uint32 entry, bossId; - DoorType type; - uint32 boundary; + typedef std::vector<BossBoundaryEntry> StorageType; + typedef StorageType::const_iterator const_iterator; + + BossBoundaryData(std::initializer_list<BossBoundaryEntry> data) : _data(data) { } + ~BossBoundaryData(); + const_iterator begin() const { return _data.begin(); } + const_iterator end() const { return _data.end(); } + + private: + StorageType _data; }; struct MinionData @@ -108,16 +110,15 @@ struct BossInfo EncounterState state; GuidSet door[MAX_DOOR_TYPES]; GuidSet minion; - BossBoundaryMap boundary; + CreatureBoundary boundary; }; struct DoorInfo { - explicit DoorInfo(BossInfo* _bossInfo, DoorType _type, BoundaryType _boundary) - : bossInfo(_bossInfo), type(_type), boundary(_boundary) { } + explicit DoorInfo(BossInfo* _bossInfo, DoorType _type) + : bossInfo(_bossInfo), type(_type) { } BossInfo* bossInfo; DoorType type; - BoundaryType boundary; }; struct MinionInfo @@ -157,7 +158,7 @@ class InstanceScript : public ZoneScript virtual void Update(uint32 /*diff*/) { } - // Used by the map's CanEnter function. + // Used by the map's CannotEnter function. // This is to prevent players from entering during boss encounters. virtual bool IsEncounterInProgress() const; @@ -221,7 +222,7 @@ class InstanceScript : public ZoneScript virtual bool SetBossState(uint32 id, EncounterState state); EncounterState GetBossState(uint32 id) const { return id < bosses.size() ? bosses[id].state : TO_BE_DECIDED; } static std::string GetBossStateName(uint8 state); - BossBoundaryMap const* GetBossBoundary(uint32 id) const { return id < bosses.size() ? &bosses[id].boundary : NULL; } + CreatureBoundary const* GetBossBoundary(uint32 id) const { return id < bosses.size() ? &bosses[id].boundary : NULL; } // Achievement criteria additional requirements check // NOTE: not use this if same can be checked existed requirement types from AchievementCriteriaRequirementType @@ -248,6 +249,7 @@ class InstanceScript : public ZoneScript protected: void SetHeaders(std::string const& dataHeaders); void SetBossNumber(uint32 number) { bosses.resize(number); } + void LoadBossBoundaries(BossBoundaryData const& data); void LoadDoorData(DoorData const* data); void LoadMinionData(MinionData const* data); void LoadObjectData(ObjectData const* creatureData, ObjectData const* gameObjectData); diff --git a/src/server/game/Loot/LootMgr.cpp b/src/server/game/Loot/LootMgr.cpp index b7a19a72bf5..19dc210ea5b 100644 --- a/src/server/game/Loot/LootMgr.cpp +++ b/src/server/game/Loot/LootMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -1580,8 +1580,8 @@ void LoadLootTemplates_Fishing() uint32 count = LootTemplates_Fishing.LoadAndCollectLootIds(lootIdSet); // remove real entries and check existence loot - for (uint32 i = 1; i < sAreaStore.GetNumRows(); ++i) - if (AreaTableEntry const* areaEntry = sAreaStore.LookupEntry(i)) + for (uint32 i = 1; i < sAreaTableStore.GetNumRows(); ++i) + if (AreaTableEntry const* areaEntry = sAreaTableStore.LookupEntry(i)) if (lootIdSet.find(areaEntry->ID) != lootIdSet.end()) lootIdSet.erase(areaEntry->ID); diff --git a/src/server/game/Loot/LootMgr.h b/src/server/game/Loot/LootMgr.h index 08cd224cd0b..af6f3e56707 100644 --- a/src/server/game/Loot/LootMgr.h +++ b/src/server/game/Loot/LootMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Mails/Mail.cpp b/src/server/game/Mails/Mail.cpp index 78cd4d3692c..b0e8a1ebe02 100644 --- a/src/server/game/Mails/Mail.cpp +++ b/src/server/game/Mails/Mail.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Mails/Mail.h b/src/server/game/Mails/Mail.h index f044996bd0a..407edf2badb 100644 --- a/src/server/game/Mails/Mail.h +++ b/src/server/game/Mails/Mail.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Maps/AreaBoundary.cpp b/src/server/game/Maps/AreaBoundary.cpp new file mode 100644 index 00000000000..e09b252179e --- /dev/null +++ b/src/server/game/Maps/AreaBoundary.cpp @@ -0,0 +1,124 @@ +/* + * Copyright (C) 2008-2016 TrinityCore <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, see <http://www.gnu.org/licenses/>. + */ + +#include "AreaBoundary.h" +#include "Unit.h" +#include "TemporarySummon.h" + +// ---== RECTANGLE ==--- +RectangleBoundary::RectangleBoundary(float southX, float northX, float eastY, float westY, bool isInverted) : + AreaBoundary(BoundaryType::BOUNDARY_RECTANGLE, isInverted), _minX(southX), _maxX(northX), _minY(eastY), _maxY(westY) { } +bool RectangleBoundary::IsWithinBoundaryArea(const Position* pos) const +{ + if (!pos) + return false; + + return !( + pos->GetPositionX() < _minX || + pos->GetPositionX() > _maxX || + pos->GetPositionY() < _minY || + pos->GetPositionY() > _maxY + ); +} + + +// ---== CIRCLE ==--- +CircleBoundary::CircleBoundary(Position const& center, double radius, bool isInverted) : + CircleBoundary(DoublePosition(center), radius, isInverted) { } +CircleBoundary::CircleBoundary(DoublePosition const& center, double radius, bool isInverted) : + AreaBoundary(BoundaryType::BOUNDARY_CIRCLE, isInverted), _center(center), _radiusSq(radius*radius) { } +CircleBoundary::CircleBoundary(Position const& center, Position const& pointOnCircle, bool isInverted) : + CircleBoundary(DoublePosition(center), DoublePosition(pointOnCircle), isInverted) { } +CircleBoundary::CircleBoundary(DoublePosition const& center, DoublePosition const& pointOnCircle, bool isInverted) : + AreaBoundary(BoundaryType::BOUNDARY_CIRCLE, isInverted), _center(center), _radiusSq(center.GetDoubleExactDist2dSq(pointOnCircle)) { } +bool CircleBoundary::IsWithinBoundaryArea(const Position* pos) const +{ + if (!pos) + return false; + + double offX = _center.GetDoublePositionX() - pos->GetPositionX(); + double offY = _center.GetDoublePositionY() - pos->GetPositionY(); + return offX*offX+offY*offY <= _radiusSq; +} + + +// ---== ELLIPSE ==--- +EllipseBoundary::EllipseBoundary(Position const& center, double radiusX, double radiusY, bool isInverted) : + EllipseBoundary(DoublePosition(center), radiusX, radiusY, isInverted) { } +EllipseBoundary::EllipseBoundary(DoublePosition const& center, double radiusX, double radiusY, bool isInverted) : + AreaBoundary(BoundaryType::BOUNDARY_ELLIPSE, isInverted), _center(center), _radiusYSq(radiusY*radiusY), _scaleXSq(_radiusYSq / (radiusX*radiusX)) { } +bool EllipseBoundary::IsWithinBoundaryArea(const Position* pos) const +{ + if (!pos) + return false; + + double offX = _center.GetDoublePositionX()-pos->GetPositionX(), offY = _center.GetDoublePositionY()-pos->GetPositionY(); + return (offX*offX)*_scaleXSq + (offY*offY) <= _radiusYSq; +} + + +// ---== TRIANGLE ==--- +TriangleBoundary::TriangleBoundary(Position const& pointA, Position const& pointB, Position const& pointC, bool isInverted) : + TriangleBoundary(DoublePosition(pointA), DoublePosition(pointB), DoublePosition(pointC), isInverted) { } +TriangleBoundary::TriangleBoundary(DoublePosition const& pointA, DoublePosition const& pointB, DoublePosition const& pointC, bool isInverted) : + AreaBoundary(BoundaryType::BOUNDARY_TRIANGLE, isInverted), _a(pointA), _b(pointB), _c(pointC), _abx(_b.GetDoublePositionX()-_a.GetDoublePositionX()), _bcx(_c.GetDoublePositionX()-_b.GetDoublePositionX()), _cax(_a.GetDoublePositionX() - _c.GetDoublePositionX()), _aby(_b.GetDoublePositionY()-_a.GetDoublePositionY()), _bcy(_c.GetDoublePositionY()-_b.GetDoublePositionY()), _cay(_a.GetDoublePositionY() - _c.GetDoublePositionY()) { } +bool TriangleBoundary::IsWithinBoundaryArea(const Position* pos) const +{ + if (!pos) + return false; + + // half-plane signs + bool sign1 = ((-_b.GetDoublePositionX() + pos->GetPositionX()) * _aby - (-_b.GetDoublePositionY() + pos->GetPositionY()) * _abx) < 0; + bool sign2 = ((-_c.GetDoublePositionX() + pos->GetPositionX()) * _bcy - (-_c.GetDoublePositionY() + pos->GetPositionY()) * _bcx) < 0; + bool sign3 = ((-_a.GetDoublePositionX() + pos->GetPositionX()) * _cay - (-_a.GetDoublePositionY() + pos->GetPositionY()) * _cax) < 0; + + // if all signs are the same, the point is inside the triangle + return ((sign1 == sign2) && (sign2 == sign3)); +} + + +// ---== PARALLELOGRAM ==--- +ParallelogramBoundary::ParallelogramBoundary(Position const& cornerA, Position const& cornerB, Position const& cornerD, bool isInverted) : + ParallelogramBoundary(DoublePosition(cornerA), DoublePosition(cornerB), DoublePosition(cornerD), isInverted) { } +ParallelogramBoundary::ParallelogramBoundary(DoublePosition const& cornerA, DoublePosition const& cornerB, DoublePosition const& cornerD, bool isInverted) : + AreaBoundary(BoundaryType::BOUNDARY_PARALLELOGRAM, isInverted), _a(cornerA), _b(cornerB), _d(cornerD), _c(DoublePosition(_d.GetDoublePositionX() + (_b.GetDoublePositionX() - _a.GetDoublePositionX()), _d.GetDoublePositionY() + (_b.GetDoublePositionY() - _a.GetDoublePositionY()))), _abx(_b.GetDoublePositionX() - _a.GetDoublePositionX()), _dax(_a.GetDoublePositionX() - _d.GetDoublePositionX()), _aby(_b.GetDoublePositionY() - _a.GetDoublePositionY()), _day(_a.GetDoublePositionY() - _d.GetDoublePositionY()) { } +bool ParallelogramBoundary::IsWithinBoundaryArea(const Position* pos) const +{ + if (!pos) + return false; + + // half-plane signs + bool sign1 = ((-_b.GetDoublePositionX() + pos->GetPositionX()) * _aby - (-_b.GetDoublePositionY() + pos->GetPositionY()) * _abx) < 0; + bool sign2 = ((-_a.GetDoublePositionX() + pos->GetPositionX()) * _day - (-_a.GetDoublePositionY() + pos->GetPositionY()) * _dax) < 0; + bool sign3 = ((-_d.GetDoublePositionY() + pos->GetPositionY()) * _abx - (-_d.GetDoublePositionX() + pos->GetPositionX()) * _aby) < 0; // AB = -CD + bool sign4 = ((-_c.GetDoublePositionY() + pos->GetPositionY()) * _dax - (-_c.GetDoublePositionX() + pos->GetPositionX()) * _day) < 0; // DA = -BC + + // if all signs are equal, the point is inside + return ((sign1 == sign2) && (sign2 == sign3) && (sign3 == sign4)); +} + + +// ---== Z RANGE ==--- +ZRangeBoundary::ZRangeBoundary(float minZ, float maxZ, bool isInverted) : + AreaBoundary(BoundaryType::BOUNDARY_Z_RANGE, isInverted), _minZ(minZ), _maxZ(maxZ) { } +bool ZRangeBoundary::IsWithinBoundaryArea(const Position* pos) const +{ + if (!pos) + return false; + + return !(pos->GetPositionZ() < _minZ || pos->GetPositionZ() > _maxZ); +} diff --git a/src/server/game/Maps/AreaBoundary.h b/src/server/game/Maps/AreaBoundary.h new file mode 100644 index 00000000000..a134b783ca6 --- /dev/null +++ b/src/server/game/Maps/AreaBoundary.h @@ -0,0 +1,153 @@ +/* + * Copyright (C) 2008-2016 TrinityCore <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, see <http://www.gnu.org/licenses/>. + */ + +#ifndef TRINITY_AREA_BOUNDARY_H +#define TRINITY_AREA_BOUNDARY_H + +#include "Position.h" + +class AreaBoundary +{ + public: + enum BoundaryType + { + BOUNDARY_RECTANGLE, // Rectangle aligned with the coordinate axis + BOUNDARY_CIRCLE, + BOUNDARY_ELLIPSE, + BOUNDARY_TRIANGLE, + BOUNDARY_PARALLELOGRAM, + BOUNDARY_Z_RANGE, + }; + virtual ~AreaBoundary() { } + BoundaryType GetBoundaryType() const { return m_boundaryType; } + bool IsWithinBoundary(const Position* pos) const { return (IsWithinBoundaryArea(pos) != m_isInvertedBoundary); } + + struct DoublePosition : Position + { + double d_positionX, d_positionY, d_positionZ; + DoublePosition(double x = 0.0, double y = 0.0, double z = 0.0, float o = 0.0f) + : Position(x, y, z, o), d_positionX(x), d_positionY(y), d_positionZ(z) { } + DoublePosition(float x, float y = 0.0f, float z = 0.0f, float o = 0.0f) + : Position(x, y, z, o), d_positionX(x), d_positionY(y), d_positionZ(z) { } + DoublePosition(const Position& pos) + : DoublePosition(pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), pos.GetOrientation()) { } + + double GetDoublePositionX() const { return d_positionX; } + double GetDoublePositionY() const { return d_positionY; } + double GetDoublePositionZ() const { return d_positionZ; } + + double GetDoubleExactDist2dSq(DoublePosition const& pos) const { + double offX = GetDoublePositionX() - pos.GetDoublePositionX(); + double offY = GetDoublePositionY() - pos.GetDoublePositionY(); + return (offX*offX) + (offY*offY); + } + + Position* sync() { m_positionX = (float)d_positionX; m_positionY = (float)d_positionY; m_positionZ = (float)d_positionZ; return this; } + }; + + protected: + AreaBoundary(BoundaryType bType, bool isInverted) : m_boundaryType(bType), m_isInvertedBoundary(isInverted) { } + virtual bool IsWithinBoundaryArea(const Position* pos) const = 0; + const BoundaryType m_boundaryType; + bool m_isInvertedBoundary; +}; + +class RectangleBoundary : public AreaBoundary +{ + public: + // X axis is north/south, Y axis is east/west, larger values are northwest + RectangleBoundary(float southX, float northX, float eastY, float westY, bool isInverted = false); + + protected: + bool IsWithinBoundaryArea(const Position* pos) const override; + + private: + const float _minX, _maxX, _minY, _maxY; +}; + +class CircleBoundary : public AreaBoundary +{ + public: + CircleBoundary(Position const& center, double radius, bool isInverted = false); + CircleBoundary(DoublePosition const& center, double radius, bool isInverted = false); + CircleBoundary(Position const& center, Position const& pointOnCircle, bool isInverted = false); + CircleBoundary(DoublePosition const& center, DoublePosition const& pointOnCircle, bool isInverted = false); + + protected: + bool IsWithinBoundaryArea(const Position* pos) const override; + + private: + const DoublePosition _center; + const double _radiusSq; +}; + +class EllipseBoundary : public AreaBoundary +{ + public: + EllipseBoundary(Position const& center, double radiusX, double radiusY, bool isInverted = false); + EllipseBoundary(DoublePosition const& center, double radiusX, double radiusY, bool isInverted = false); + + protected: + bool IsWithinBoundaryArea(const Position* pos) const override; + + private: + const DoublePosition _center; + const double _radiusYSq, _scaleXSq; +}; + +class TriangleBoundary : public AreaBoundary +{ + public: + TriangleBoundary(Position const& pointA, Position const& pointB, Position const& pointC, bool isInverted = false); + TriangleBoundary(DoublePosition const& pointA, DoublePosition const& pointB, DoublePosition const& pointC, bool isInverted = false); + + protected: + bool IsWithinBoundaryArea(const Position* pos) const override; + + private: + const DoublePosition _a, _b, _c; + const double _abx, _bcx, _cax, _aby, _bcy, _cay; +}; + +class ParallelogramBoundary : public AreaBoundary +{ + public: + // Note: AB must be orthogonal to AD + ParallelogramBoundary(Position const& cornerA, Position const& cornerB, Position const& cornerD, bool isInverted = false); + ParallelogramBoundary(DoublePosition const& cornerA, DoublePosition const& cornerB, DoublePosition const& cornerD, bool isInverted = false); + + protected: + bool IsWithinBoundaryArea(const Position* pos) const override; + + private: + const DoublePosition _a, _b, _d, _c; + const double _abx, _dax, _aby, _day; +}; + +class ZRangeBoundary : public AreaBoundary +{ + public: + ZRangeBoundary(float minZ, float maxZ, bool isInverted = false); + + protected: + bool IsWithinBoundaryArea(const Position* pos) const override; + + private: + const float _minZ, _maxZ; +}; + +#endif //TRINITY_AREA_BOUNDARY_H diff --git a/src/server/game/Maps/Map.cpp b/src/server/game/Maps/Map.cpp index 6fbef752228..ccc599b6de8 100644 --- a/src/server/game/Maps/Map.cpp +++ b/src/server/game/Maps/Map.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -37,7 +37,7 @@ #include "VMapFactory.h" u_map_magic MapMagic = { {'M','A','P','S'} }; -u_map_magic MapVersionMagic = { {'v','1','.','3'} }; +u_map_magic MapVersionMagic = { {'v','1','.','8'} }; u_map_magic MapAreaMagic = { {'A','R','E','A'} }; u_map_magic MapHeightMagic = { {'M','H','G','T'} }; u_map_magic MapLiquidMagic = { {'M','L','I','Q'} }; @@ -1644,13 +1644,15 @@ GridMap::GridMap() _flags = 0; // Area data _gridArea = 0; - _areaMap = NULL; + _areaMap = nullptr; // Height level data _gridHeight = INVALID_HEIGHT; _gridGetHeight = &GridMap::getHeightFromFlat; _gridIntHeightMultiplier = 0; - m_V9 = NULL; - m_V8 = NULL; + m_V9 = nullptr; + m_V8 = nullptr; + _maxHeight = nullptr; + _minHeight = nullptr; // Liquid data _liquidType = 0; _liquidOffX = 0; @@ -1658,9 +1660,9 @@ GridMap::GridMap() _liquidWidth = 0; _liquidHeight = 0; _liquidLevel = INVALID_HEIGHT; - _liquidEntry = NULL; - _liquidFlags = NULL; - _liquidMap = NULL; + _liquidEntry = nullptr; + _liquidFlags = nullptr; + _liquidMap = nullptr; } GridMap::~GridMap() @@ -1723,15 +1725,19 @@ void GridMap::unloadData() delete[] _areaMap; delete[] m_V9; delete[] m_V8; + delete[] _maxHeight; + delete[] _minHeight; delete[] _liquidEntry; delete[] _liquidFlags; delete[] _liquidMap; - _areaMap = NULL; - m_V9 = NULL; - m_V8 = NULL; - _liquidEntry = NULL; - _liquidFlags = NULL; - _liquidMap = NULL; + _areaMap = nullptr; + m_V9 = nullptr; + m_V8 = nullptr; + _maxHeight = nullptr; + _minHeight = nullptr; + _liquidEntry = nullptr; + _liquidFlags = nullptr; + _liquidMap = nullptr; _gridGetHeight = &GridMap::getHeightFromFlat; } @@ -1746,7 +1752,7 @@ bool GridMap::loadAreaData(FILE* in, uint32 offset, uint32 /*size*/) _gridArea = header.gridArea; if (!(header.flags & MAP_AREA_NO_AREA)) { - _areaMap = new uint16 [16*16]; + _areaMap = new uint16[16 * 16]; if (fread(_areaMap, sizeof(uint16), 16*16, in) != 16*16) return false; } @@ -1796,6 +1802,16 @@ bool GridMap::loadHeightData(FILE* in, uint32 offset, uint32 /*size*/) } else _gridGetHeight = &GridMap::getHeightFromFlat; + + if (header.flags & MAP_HEIGHT_HAS_FLIGHT_BOUNDS) + { + _maxHeight = new int16[3 * 3]; + _minHeight = new int16[3 * 3]; + if (fread(_maxHeight, sizeof(int16), 3 * 3, in) != 3 * 3 || + fread(_minHeight, sizeof(int16), 3 * 3, in) != 3 * 3) + return false; + } + return true; } @@ -2066,6 +2082,66 @@ float GridMap::getHeightFromUint16(float x, float y) const return (float)((a * x) + (b * y) + c)*_gridIntHeightMultiplier + _gridHeight; } +float GridMap::getMinHeight(float x, float y) const +{ + if (!_minHeight) + return -500.0f; + + static uint32 const indices[] = + { + 3, 0, 4, + 0, 1, 4, + 1, 2, 4, + 2, 5, 4, + 5, 8, 4, + 8, 7, 4, + 7, 6, 4, + 6, 3, 4 + }; + + static float const boundGridCoords[] = + { + 0.0f, 0.0f, + 0.0f, -266.66666f, + 0.0f, -533.33331f, + -266.66666f, 0.0f, + -266.66666f, -266.66666f, + -266.66666f, -533.33331f, + -533.33331f, 0.0f, + -533.33331f, -266.66666f, + -533.33331f, -533.33331f + }; + + Cell cell(x, y); + float gx = x - (int32(cell.GridX()) - CENTER_GRID_ID + 1) * SIZE_OF_GRIDS; + float gy = y - (int32(cell.GridY()) - CENTER_GRID_ID + 1) * SIZE_OF_GRIDS; + + uint32 quarterIndex = 0; + if (cell.CellY() < MAX_NUMBER_OF_CELLS / 2) + { + if (cell.CellX() < MAX_NUMBER_OF_CELLS / 2) + { + quarterIndex = 4 + (gy > gx); + } + else + quarterIndex = 2 + ((-SIZE_OF_GRIDS - gx) > gy); + } + else if (cell.CellX() < MAX_NUMBER_OF_CELLS / 2) + { + quarterIndex = 6 + ((-SIZE_OF_GRIDS - gx) <= gy); + } + else + quarterIndex = gx > gy; + + quarterIndex *= 3; + + return G3D::Plane( + G3D::Vector3(boundGridCoords[indices[quarterIndex + 0] * 2 + 0], boundGridCoords[indices[quarterIndex + 0] * 2 + 1], _minHeight[indices[quarterIndex + 0]]), + G3D::Vector3(boundGridCoords[indices[quarterIndex + 1] * 2 + 0], boundGridCoords[indices[quarterIndex + 1] * 2 + 1], _minHeight[indices[quarterIndex + 1]]), + G3D::Vector3(boundGridCoords[indices[quarterIndex + 2] * 2 + 0], boundGridCoords[indices[quarterIndex + 2] * 2 + 1], _minHeight[indices[quarterIndex + 2]]) + ).distance(G3D::Vector3(gx, gy, 0.0f)); +} + float GridMap::getLiquidLevel(float x, float y) const { if (!_liquidMap) @@ -2125,12 +2201,12 @@ inline ZLiquidStatus GridMap::getLiquidStatus(float x, float y, float z, uint8 R uint32 liqTypeIdx = liquidEntry->Type; if (entry < 21) { - if (AreaTableEntry const* area = GetAreaEntryByAreaFlagAndMap(getArea(x, y), MAPID_INVALID)) + if (AreaTableEntry const* area = sAreaTableStore.LookupEntry(getArea(x, y))) { uint32 overrideLiquid = area->LiquidTypeOverride[liquidEntry->Type]; if (!overrideLiquid && area->zone) { - area = GetAreaEntryByAreaID(area->zone); + area = sAreaTableStore.LookupEntry(area->zone); if (area) overrideLiquid = area->LiquidTypeOverride[liquidEntry->Type]; } @@ -2266,6 +2342,14 @@ float Map::GetHeight(float x, float y, float z, bool checkVMap /*= true*/, float return mapHeight; // explicitly use map data } +float Map::GetMinHeight(float x, float y) const +{ + if (GridMap const* grid = const_cast<Map*>(this)->GetGrid(x, y)) + return grid->getMinHeight(x, y); + + return -500.0f; +} + inline bool IsOutdoorWMO(uint32 mogpFlags, int32 /*adtId*/, int32 /*rootId*/, int32 /*groupId*/, WMOAreaTableEntry const* wmoEntry, AreaTableEntry const* atEntry) { bool outdoor = true; @@ -2304,7 +2388,7 @@ bool Map::IsOutdoors(float x, float y, float z) const if (wmoEntry) { TC_LOG_DEBUG("maps", "Got WMOAreaTableEntry! flag %u, areaid %u", wmoEntry->Flags, wmoEntry->areaId); - atEntry = GetAreaEntryByAreaID(wmoEntry->areaId); + atEntry = sAreaTableStore.LookupEntry(wmoEntry->areaId); } return IsOutdoorWMO(mogpFlags, adtId, rootId, groupId, wmoEntry, atEntry); } @@ -2328,7 +2412,7 @@ bool Map::GetAreaInfo(float x, float y, float z, uint32 &flags, int32 &adtId, in return false; } -uint16 Map::GetAreaFlag(float x, float y, float z, bool *isOutdoors) const +uint32 Map::GetAreaId(float x, float y, float z, bool *isOutdoors) const { uint32 mogpFlags; int32 adtId, rootId, groupId; @@ -2341,20 +2425,21 @@ uint16 Map::GetAreaFlag(float x, float y, float z, bool *isOutdoors) const haveAreaInfo = true; wmoEntry = GetWMOAreaTableEntryByTripple(rootId, adtId, groupId); if (wmoEntry) - atEntry = GetAreaEntryByAreaID(wmoEntry->areaId); + atEntry = sAreaTableStore.LookupEntry(wmoEntry->areaId); } - uint16 areaflag; + uint32 areaId = 0; if (atEntry) - areaflag = atEntry->exploreFlag; + areaId = atEntry->ID; else { if (GridMap* gmap = const_cast<Map*>(this)->GetGrid(x, y)) - areaflag = gmap->getArea(x, y); + areaId = gmap->getArea(x, y); + // this used while not all *.map files generated (instances) - else - areaflag = GetAreaFlagByMapId(i_mapEntry->MapID); + if (!areaId) + areaId = i_mapEntry->linked_zone; } if (isOutdoors) @@ -2364,8 +2449,31 @@ uint16 Map::GetAreaFlag(float x, float y, float z, bool *isOutdoors) const else *isOutdoors = true; } - return areaflag; - } + return areaId; +} + +uint32 Map::GetAreaId(float x, float y, float z) const +{ + return GetAreaId(x, y, z, nullptr); +} + +uint32 Map::GetZoneId(float x, float y, float z) const +{ + uint32 areaId = GetAreaId(x, y, z); + if (AreaTableEntry const* area = sAreaTableStore.LookupEntry(areaId)) + if (area->zone) + return area->zone; + + return areaId; +} + +void Map::GetZoneAndAreaId(uint32& zoneid, uint32& areaid, float x, float y, float z) const +{ + areaid = zoneid = GetAreaId(x, y, z); + if (AreaTableEntry const* area = sAreaTableStore.LookupEntry(areaid)) + if (area->zone) + zoneid = area->zone; +} uint8 Map::GetTerrainType(float x, float y) const { @@ -2401,12 +2509,12 @@ ZLiquidStatus Map::getLiquidStatus(float x, float y, float z, uint8 ReqLiquidTyp if (liquid_type && liquid_type < 21) { - if (AreaTableEntry const* area = GetAreaEntryByAreaFlagAndMap(GetAreaFlag(x, y, z), GetId())) + if (AreaTableEntry const* area = sAreaTableStore.LookupEntry(GetAreaId(x, y, z))) { uint32 overrideLiquid = area->LiquidTypeOverride[liquidFlagType]; if (!overrideLiquid && area->zone) { - area = GetAreaEntryByAreaID(area->zone); + area = sAreaTableStore.LookupEntry(area->zone); if (area) overrideLiquid = area->LiquidTypeOverride[liquidFlagType]; } @@ -2468,34 +2576,6 @@ float Map::GetWaterLevel(float x, float y) const return 0; } -uint32 Map::GetAreaIdByAreaFlag(uint16 areaflag, uint32 map_id) -{ - AreaTableEntry const* entry = GetAreaEntryByAreaFlagAndMap(areaflag, map_id); - - if (entry) - return entry->ID; - else - return 0; -} - -uint32 Map::GetZoneIdByAreaFlag(uint16 areaflag, uint32 map_id) -{ - AreaTableEntry const* entry = GetAreaEntryByAreaFlagAndMap(areaflag, map_id); - - if (entry) - return (entry->zone != 0) ? entry->zone : entry->ID; - else - return 0; -} - -void Map::GetZoneAndAreaIdByAreaFlag(uint32& zoneid, uint32& areaid, uint16 areaflag, uint32 map_id) -{ - AreaTableEntry const* entry = GetAreaEntryByAreaFlagAndMap(areaflag, map_id); - - areaid = entry ? entry->ID : 0; - zoneid = entry ? ((entry->zone != 0) ? entry->zone : entry->ID) : 0; -} - bool Map::isInLineOfSight(float x1, float y1, float z1, float x2, float y2, float z2, uint32 phasemask) const { return VMAP::VMapFactory::createOrGetVMapManager()->isInLineOfSight(GetId(), x1, y1, z1, x2, y2, z2) @@ -2947,62 +3027,38 @@ void InstanceMap::InitVisibilityDistance() /* Do map specific checks to see if the player can enter */ -bool InstanceMap::CanEnter(Player* player) +Map::EnterState InstanceMap::CannotEnter(Player* player) { if (player->GetMapRef().getTarget() == this) { - TC_LOG_ERROR("maps", "InstanceMap::CanEnter - player %s(%u) already in map %d, %d, %d!", player->GetName().c_str(), player->GetGUID().GetCounter(), GetId(), GetInstanceId(), GetSpawnMode()); + TC_LOG_ERROR("maps", "InstanceMap::CannotEnter - player %s(%u) already in map %d, %d, %d!", player->GetName().c_str(), player->GetGUID().GetCounter(), GetId(), GetInstanceId(), GetSpawnMode()); ABORT(); - return false; + return CANNOT_ENTER_ALREADY_IN_MAP; } // allow GM's to enter if (player->IsGameMaster()) - return Map::CanEnter(player); + return Map::CannotEnter(player); // cannot enter if the instance is full (player cap), GMs don't count uint32 maxPlayers = GetMaxPlayers(); if (GetPlayersCountExceptGMs() >= maxPlayers) { TC_LOG_WARN("maps", "MAP: Instance '%u' of map '%s' cannot have more than '%u' players. Player '%s' rejected", GetInstanceId(), GetMapName(), maxPlayers, player->GetName().c_str()); - player->SendTransferAborted(GetId(), TRANSFER_ABORT_MAX_PLAYERS); - return false; + return CANNOT_ENTER_MAX_PLAYERS; } - // cannot enter while an encounter is in progress - // allow if just loading + // cannot enter while an encounter is in progress (unless this is a relog, in which case it is permitted) if (!player->IsLoading() && IsRaid() && GetInstanceScript() && GetInstanceScript()->IsEncounterInProgress()) - { - player->SendTransferAborted(GetId(), TRANSFER_ABORT_ZONE_IN_COMBAT); - return false; - } - - // cannot enter if instance is in use by another party/soloer that have a - // permanent save in the same instance id + return CANNOT_ENTER_ZONE_IN_COMBAT; - PlayerList const &playerList = GetPlayers(); + // cannot enter if player is permanent saved to a different instance id + if (InstancePlayerBind* playerBind = player->GetBoundInstance(GetId(), GetDifficulty())) + if (playerBind->perm && playerBind->save) + if (playerBind->save->GetInstanceId() != GetInstanceId()) + return CANNOT_ENTER_INSTANCE_BIND_MISMATCH; - if (!playerList.isEmpty()) - for (PlayerList::const_iterator i = playerList.begin(); i != playerList.end(); ++i) - if (Player* iPlayer = i->GetSource()) - { - if (iPlayer->IsGameMaster()) // bypass GMs - continue; - if (!player->GetGroup()) // player has not group and there is someone inside, deny entry - { - player->SendTransferAborted(GetId(), TRANSFER_ABORT_MAX_PLAYERS); - return false; - } - // player inside instance has no group or his groups is different to entering player's one, deny entry - if (!iPlayer->GetGroup() || iPlayer->GetGroup() != player->GetGroup()) - { - player->SendTransferAborted(GetId(), TRANSFER_ABORT_MAX_PLAYERS); - return false; - } - break; - } - - return Map::CanEnter(player); + return Map::CannotEnter(player); } /* @@ -3054,7 +3110,7 @@ bool InstanceMap::AddPlayerToMap(Player* player) { if (group) { - // solo saves should be reset when entering a group + // solo saves should have been reset when the map was loaded InstanceGroupBind* groupBind = group->GetBoundInstance(this); if (playerBind && playerBind->save != mapSave) { @@ -3202,22 +3258,37 @@ bool InstanceMap::Reset(uint8 method) } else { + bool doUnload = true; if (method == INSTANCE_RESET_GLOBAL) + { // set the homebind timer for players inside (1 minute) for (MapRefManager::iterator itr = m_mapRefManager.begin(); itr != m_mapRefManager.end(); ++itr) - itr->GetSource()->m_InstanceValid = false; + { + InstancePlayerBind* bind = itr->GetSource()->GetBoundInstance(GetId(), GetDifficulty()); + if (bind && bind->extendState && bind->save->GetInstanceId() == GetInstanceId()) + doUnload = false; + else + itr->GetSource()->m_InstanceValid = false; + } + + if (doUnload && HasPermBoundPlayers()) // check if any unloaded players have a nonexpired save to this + doUnload = false; + } - // the unload timer is not started - // instead the map will unload immediately after the players have left - m_unloadWhenEmpty = true; - m_resetAfterUnload = true; + if (doUnload) + { + // the unload timer is not started + // instead the map will unload immediately after the players have left + m_unloadWhenEmpty = true; + m_resetAfterUnload = true; + } } } else { // unloaded at next update m_unloadTimer = MIN_UNLOAD_DELAY; - m_resetAfterUnload = true; + m_resetAfterUnload = !(method == INSTANCE_RESET_GLOBAL && HasPermBoundPlayers()); } return m_mapRefManager.isEmpty(); @@ -3298,6 +3369,13 @@ MapDifficulty const* Map::GetMapDifficulty() const return GetMapDifficultyData(GetId(), GetDifficulty()); } +bool InstanceMap::HasPermBoundPlayers() const +{ + PreparedStatement* stmt = CharacterDatabase.GetPreparedStatement(CHAR_SEL_PERM_BIND_BY_INSTANCE); + stmt->setUInt16(0,GetInstanceId()); + return !!CharacterDatabase.Query(stmt); +} + uint32 InstanceMap::GetMaxPlayers() const { MapDifficulty const* mapDiff = GetMapDifficulty(); @@ -3339,21 +3417,21 @@ void BattlegroundMap::InitVisibilityDistance() m_VisibilityNotifyPeriod = World::GetVisibilityNotifyPeriodInBGArenas(); } -bool BattlegroundMap::CanEnter(Player* player) +Map::EnterState BattlegroundMap::CannotEnter(Player* player) { if (player->GetMapRef().getTarget() == this) { - TC_LOG_ERROR("maps", "BGMap::CanEnter - player %u is already in map!", player->GetGUID().GetCounter()); + TC_LOG_ERROR("maps", "BGMap::CannotEnter - player %u is already in map!", player->GetGUID().GetCounter()); ABORT(); - return false; + return CANNOT_ENTER_ALREADY_IN_MAP; } if (player->GetBattlegroundId() != GetInstanceId()) - return false; + return CANNOT_ENTER_INSTANCE_BIND_MISMATCH; // player number limit is checked in bgmgr, no need to do it here - return Map::CanEnter(player); + return Map::CannotEnter(player); } bool BattlegroundMap::AddPlayerToMap(Player* player) diff --git a/src/server/game/Maps/Map.h b/src/server/game/Maps/Map.h index 0962bcc9d6c..bc2bf72f271 100644 --- a/src/server/game/Maps/Map.h +++ b/src/server/game/Maps/Map.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -98,9 +98,10 @@ struct map_areaHeader uint16 gridArea; }; -#define MAP_HEIGHT_NO_HEIGHT 0x0001 -#define MAP_HEIGHT_AS_INT16 0x0002 -#define MAP_HEIGHT_AS_INT8 0x0004 +#define MAP_HEIGHT_NO_HEIGHT 0x0001 +#define MAP_HEIGHT_AS_INT16 0x0002 +#define MAP_HEIGHT_AS_INT8 0x0004 +#define MAP_HEIGHT_HAS_FLIGHT_BOUNDS 0x0008 struct map_heightHeader { @@ -166,6 +167,8 @@ class GridMap uint16* m_uint16_V8; uint8* m_uint8_V8; }; + int16* _maxHeight; + int16* _minHeight; // Height level data float _gridHeight; float _gridIntHeightMultiplier; @@ -206,6 +209,7 @@ public: uint16 getArea(float x, float y) const; inline float getHeight(float x, float y) const {return (this->*_gridGetHeight)(x, y);} + float getMinHeight(float x, float y) const; float getLiquidLevel(float x, float y) const; uint8 getTerrainType(float x, float y) const; ZLiquidStatus getLiquidStatus(float x, float y, float z, uint8 ReqLiquidType, LiquidData* data = 0); @@ -326,11 +330,15 @@ class Map : public GridRefManager<NGridType> // some calls like isInWater should not use vmaps due to processor power // can return INVALID_HEIGHT if under z+2 z coord not found height float GetHeight(float x, float y, float z, bool checkVMap = true, float maxSearchDist = DEFAULT_HEIGHT_SEARCH) const; + float GetMinHeight(float x, float y) const; ZLiquidStatus getLiquidStatus(float x, float y, float z, uint8 ReqLiquidType, LiquidData* data = nullptr) const; - uint16 GetAreaFlag(float x, float y, float z, bool *isOutdoors=nullptr) const; - bool GetAreaInfo(float x, float y, float z, uint32 &mogpflags, int32 &adtId, int32 &rootId, int32 &groupId) const; + uint32 GetAreaId(float x, float y, float z, bool *isOutdoors) const; + bool GetAreaInfo(float x, float y, float z, uint32& mogpflags, int32& adtId, int32& rootId, int32& groupId) const; + uint32 GetAreaId(float x, float y, float z) const; + uint32 GetZoneId(float x, float y, float z) const; + void GetZoneAndAreaId(uint32& zoneid, uint32& areaid, float x, float y, float z) const; bool IsOutdoors(float x, float y, float z) const; @@ -339,25 +347,6 @@ class Map : public GridRefManager<NGridType> bool IsInWater(float x, float y, float z, LiquidData* data = nullptr) const; bool IsUnderWater(float x, float y, float z) const; - static uint32 GetAreaIdByAreaFlag(uint16 areaflag, uint32 map_id); - static uint32 GetZoneIdByAreaFlag(uint16 areaflag, uint32 map_id); - static void GetZoneAndAreaIdByAreaFlag(uint32& zoneid, uint32& areaid, uint16 areaflag, uint32 map_id); - - uint32 GetAreaId(float x, float y, float z) const - { - return GetAreaIdByAreaFlag(GetAreaFlag(x, y, z), GetId()); - } - - uint32 GetZoneId(float x, float y, float z) const - { - return GetZoneIdByAreaFlag(GetAreaFlag(x, y, z), GetId()); - } - - void GetZoneAndAreaId(uint32& zoneid, uint32& areaid, float x, float y, float z) const - { - GetZoneAndAreaIdByAreaFlag(zoneid, areaid, GetAreaFlag(x, y, z), GetId()); - } - void MoveAllCreaturesInMoveList(); void MoveAllGameObjectsInMoveList(); void MoveAllDynamicObjectsInMoveList(); @@ -373,7 +362,23 @@ class Map : public GridRefManager<NGridType> uint32 GetInstanceId() const { return i_InstanceId; } uint8 GetSpawnMode() const { return (i_spawnMode); } - virtual bool CanEnter(Player* /*player*/) { return true; } + + enum EnterState + { + CAN_ENTER = 0, + CANNOT_ENTER_ALREADY_IN_MAP = 1, // Player is already in the map + CANNOT_ENTER_NO_ENTRY, // No map entry was found for the target map ID + CANNOT_ENTER_UNINSTANCED_DUNGEON, // No instance template was found for dungeon map + CANNOT_ENTER_DIFFICULTY_UNAVAILABLE, // Requested instance difficulty is not available for target map + CANNOT_ENTER_NOT_IN_RAID, // Target instance is a raid instance and the player is not in a raid group + CANNOT_ENTER_CORPSE_IN_DIFFERENT_INSTANCE, // Player is dead and their corpse is not in target instance + CANNOT_ENTER_INSTANCE_BIND_MISMATCH, // Player's permanent instance save is not compatible with their group's current instance bind + CANNOT_ENTER_TOO_MANY_INSTANCES, // Player has entered too many instances recently + CANNOT_ENTER_MAX_PLAYERS, // Target map already has the maximum number of players allowed + CANNOT_ENTER_ZONE_IN_COMBAT, // A boss encounter is currently in progress on the target map + CANNOT_ENTER_UNSPECIFIED_REASON + }; + virtual EnterState CannotEnter(Player* /*player*/) { return CAN_ENTER; } const char* GetMapName() const; // have meaning only for instanced map (that have set real difficulty) @@ -762,10 +767,13 @@ class InstanceMap : public Map InstanceScript* GetInstanceScript() { return i_data; } void PermBindAllPlayers(Player* source); void UnloadAll() override; - bool CanEnter(Player* player) override; + EnterState CannotEnter(Player* player) override; void SendResetWarnings(uint32 timeLeft) const; void SetResetSchedule(bool on); + /* this checks if any players have a permanent bind (included reactivatable expired binds) to the instance ID + it needs a DB query, so use sparingly */ + bool HasPermBoundPlayers() const; uint32 GetMaxPlayers() const; uint32 GetMaxResetDelay() const; @@ -785,7 +793,7 @@ class BattlegroundMap : public Map bool AddPlayerToMap(Player*) override; void RemovePlayerFromMap(Player*, bool) override; - bool CanEnter(Player* player) override; + EnterState CannotEnter(Player* player) override; void SetUnload(); //void UnloadAll(bool pForce); void RemoveAllPlayers() override; diff --git a/src/server/game/Maps/MapInstanced.cpp b/src/server/game/Maps/MapInstanced.cpp index d1b8bd66209..47b9b376b1e 100644 --- a/src/server/game/Maps/MapInstanced.cpp +++ b/src/server/game/Maps/MapInstanced.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -110,12 +110,12 @@ void MapInstanced::UnloadAll() - create the instance if it's not created already - the player is not actually added to the instance (only in InstanceMap::Add) */ -Map* MapInstanced::CreateInstanceForPlayer(const uint32 mapId, Player* player) +Map* MapInstanced::CreateInstanceForPlayer(const uint32 mapId, Player* player, uint32 loginInstanceId) { if (GetId() != mapId || !player) - return NULL; + return nullptr; - Map* map = NULL; + Map* map = nullptr; uint32 newInstanceId = 0; // instanceId of the resulting map if (IsBattlegroundOrArena()) @@ -124,7 +124,7 @@ Map* MapInstanced::CreateInstanceForPlayer(const uint32 mapId, Player* player) // the instance id is set in battlegroundid newInstanceId = player->GetBattlegroundId(); if (!newInstanceId) - return NULL; + return nullptr; map = sMapMgr->FindMap(mapId, newInstanceId); if (!map) @@ -134,27 +134,40 @@ Map* MapInstanced::CreateInstanceForPlayer(const uint32 mapId, Player* player) else { player->TeleportToBGEntryPoint(); - return NULL; + return nullptr; } } } else { InstancePlayerBind* pBind = player->GetBoundInstance(GetId(), player->GetDifficulty(IsRaid())); - InstanceSave* pSave = pBind ? pBind->save : NULL; + InstanceSave* pSave = pBind ? pBind->save : nullptr; - // the player's permanent player bind is taken into consideration first - // then the player's group bind and finally the solo bind. + // priority: + // 1. player's permanent bind + // 2. player's current instance id if this is at login + // 3. group's current bind + // 4. player's current bind if (!pBind || !pBind->perm) { - InstanceGroupBind* groupBind = NULL; + if (loginInstanceId) // if the player has a saved instance id on login, we either use this instance or relocate him out (return null) + { + map = FindInstanceMap(loginInstanceId); + return (map && map->GetId() == GetId()) ? map : nullptr; // is this check necessary? or does MapInstanced only find instances of itself? + } + + InstanceGroupBind* groupBind = nullptr; Group* group = player->GetGroup(); // use the player's difficulty setting (it may not be the same as the group's) if (group) { groupBind = group->GetBoundInstance(this); if (groupBind) + { + // solo saves should be reset when entering a group's instance + player->UnbindInstance(GetId(), player->GetDifficulty(IsRaid())); pSave = groupBind->save; + } } } if (pSave) @@ -278,8 +291,8 @@ bool MapInstanced::DestroyInstance(InstancedMaps::iterator &itr) return true; } -bool MapInstanced::CanEnter(Player* /*player*/) +Map::EnterState MapInstanced::CannotEnter(Player* /*player*/) { //ABORT(); - return true; + return CAN_ENTER; } diff --git a/src/server/game/Maps/MapInstanced.h b/src/server/game/Maps/MapInstanced.h index c385215ba76..7fa66bde06a 100644 --- a/src/server/game/Maps/MapInstanced.h +++ b/src/server/game/Maps/MapInstanced.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -37,13 +37,13 @@ class MapInstanced : public Map void DelayedUpdate(const uint32 diff) override; //void RelocationNotify(); void UnloadAll() override; - bool CanEnter(Player* player) override; + EnterState CannotEnter(Player* /*player*/) override; - Map* CreateInstanceForPlayer(const uint32 mapId, Player* player); + Map* CreateInstanceForPlayer(const uint32 mapId, Player* player, uint32 loginInstanceId=0); Map* FindInstanceMap(uint32 instanceId) const { InstancedMaps::const_iterator i = m_InstancedMaps.find(instanceId); - return(i == m_InstancedMaps.end() ? NULL : i->second); + return(i == m_InstancedMaps.end() ? nullptr : i->second); } bool DestroyInstance(InstancedMaps::iterator &itr); diff --git a/src/server/game/Maps/MapManager.cpp b/src/server/game/Maps/MapManager.cpp index 0e7f9dbb611..e5f364e39f4 100644 --- a/src/server/game/Maps/MapManager.cpp +++ b/src/server/game/Maps/MapManager.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -97,12 +97,12 @@ Map* MapManager::FindBaseNonInstanceMap(uint32 mapId) const return map; } -Map* MapManager::CreateMap(uint32 id, Player* player) +Map* MapManager::CreateMap(uint32 id, Player* player, uint32 loginInstanceId) { Map* m = CreateBaseMap(id); if (m && m->Instanceable()) - m = ((MapInstanced*)m)->CreateInstanceForPlayer(id, player); + m = ((MapInstanced*)m)->CreateInstanceForPlayer(id, player, loginInstanceId); return m; } @@ -119,48 +119,36 @@ Map* MapManager::FindMap(uint32 mapid, uint32 instanceId) const return ((MapInstanced*)map)->FindInstanceMap(instanceId); } -bool MapManager::CanPlayerEnter(uint32 mapid, Player* player, bool loginCheck) +Map::EnterState MapManager::PlayerCannotEnter(uint32 mapid, Player* player, bool loginCheck) { MapEntry const* entry = sMapStore.LookupEntry(mapid); if (!entry) - return false; + return Map::CANNOT_ENTER_NO_ENTRY; if (!entry->IsDungeon()) - return true; + return Map::CAN_ENTER; InstanceTemplate const* instance = sObjectMgr->GetInstanceTemplate(mapid); if (!instance) - return false; + return Map::CANNOT_ENTER_UNINSTANCED_DUNGEON; Difficulty targetDifficulty, requestedDifficulty; targetDifficulty = requestedDifficulty = player->GetDifficulty(entry->IsRaid()); // Get the highest available difficulty if current setting is higher than the instance allows MapDifficulty const* mapDiff = GetDownscaledMapDifficultyData(entry->MapID, targetDifficulty); if (!mapDiff) - { - player->SendTransferAborted(mapid, TRANSFER_ABORT_DIFFICULTY, requestedDifficulty); - return false; - } + return Map::CANNOT_ENTER_DIFFICULTY_UNAVAILABLE; //Bypass checks for GMs if (player->IsGameMaster()) - return true; + return Map::CAN_ENTER; char const* mapName = entry->name[player->GetSession()->GetSessionDbcLocale()]; Group* group = player->GetGroup(); - if (entry->IsRaid()) - { - // can only enter in a raid group + if (entry->IsRaid()) // can only enter in a raid group if ((!group || !group->isRaidGroup()) && !sWorld->getBoolConfig(CONFIG_INSTANCE_IGNORE_RAID)) - { - // probably there must be special opcode, because client has this string constant in GlobalStrings.lua - /// @todo this is not a good place to send the message - player->GetSession()->SendAreaTriggerMessage(player->GetSession()->GetTrinityString(LANG_INSTANCE_RAID_GROUP_ONLY), mapName); - TC_LOG_DEBUG("maps", "MAP: Player '%s' must be in a raid group to enter instance '%s'", player->GetName().c_str(), mapName); - return false; - } - } + return Map::CANNOT_ENTER_NOT_IN_RAID; if (!player->IsAlive()) { @@ -178,12 +166,7 @@ bool MapManager::CanPlayerEnter(uint32 mapid, Player* player, bool loginCheck) } while (corpseMap); if (!corpseMap) - { - WorldPacket data(SMSG_CORPSE_NOT_IN_INSTANCE); - player->GetSession()->SendPacket(&data); - TC_LOG_DEBUG("maps", "MAP: Player '%s' does not have a corpse in instance '%s' and cannot enter.", player->GetName().c_str(), mapName); - return false; - } + return Map::CANNOT_ENTER_CORPSE_IN_DIFFERENT_INSTANCE; TC_LOG_DEBUG("maps", "MAP: Player '%s' has corpse in instance '%s' and can enter.", player->GetName().c_str(), mapName); } @@ -192,23 +175,13 @@ bool MapManager::CanPlayerEnter(uint32 mapid, Player* player, bool loginCheck) } //Get instance where player's group is bound & its map - if (group) + if (!loginCheck && group) { InstanceGroupBind* boundInstance = group->GetBoundInstance(entry); if (boundInstance && boundInstance->save) if (Map* boundMap = sMapMgr->FindMap(mapid, boundInstance->save->GetInstanceId())) - if (!loginCheck && !boundMap->CanEnter(player)) - return false; - /* - This check has to be moved to InstanceMap::CanEnter() - // Player permanently bounded to different instance than groups one - InstancePlayerBind* playerBoundedInstance = player->GetBoundInstance(mapid, player->GetDifficulty(entry->IsRaid())); - if (playerBoundedInstance && playerBoundedInstance->perm && playerBoundedInstance->save && - boundedInstance->save->GetInstanceId() != playerBoundedInstance->save->GetInstanceId()) - { - /// @todo send some kind of error message to the player - return false; - }*/ + if (Map::EnterState denyReason = boundMap->CannotEnter(player)) + return denyReason; } // players are only allowed to enter 5 instances per hour @@ -220,14 +193,14 @@ bool MapManager::CanPlayerEnter(uint32 mapid, Player* player, bool loginCheck) // instanceId can never be 0 - will not be found if (!player->CheckInstanceCount(instanceIdToCheck) && !player->isDead()) - { - player->SendTransferAborted(mapid, TRANSFER_ABORT_TOO_MANY_INSTANCES); - return false; - } + return Map::CANNOT_ENTER_TOO_MANY_INSTANCES; } //Other requirements - return player->Satisfy(sObjectMgr->GetAccessRequirement(mapid, targetDifficulty), mapid, true); + if (player->Satisfy(sObjectMgr->GetAccessRequirement(mapid, targetDifficulty), mapid, true)) + return Map::CAN_ENTER; + else + return Map::CANNOT_ENTER_UNSPECIFIED_REASON; } void MapManager::Update(uint32 diff) diff --git a/src/server/game/Maps/MapManager.h b/src/server/game/Maps/MapManager.h index 5b957e00281..7f9621593d4 100644 --- a/src/server/game/Maps/MapManager.h +++ b/src/server/game/Maps/MapManager.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -39,25 +39,23 @@ class MapManager Map* CreateBaseMap(uint32 mapId); Map* FindBaseNonInstanceMap(uint32 mapId) const; - Map* CreateMap(uint32 mapId, Player* player); + Map* CreateMap(uint32 mapId, Player* player, uint32 loginInstanceId=0); Map* FindMap(uint32 mapId, uint32 instanceId) const; - uint16 GetAreaFlag(uint32 mapid, float x, float y, float z) const - { - Map const* m = const_cast<MapManager*>(this)->CreateBaseMap(mapid); - return m->GetAreaFlag(x, y, z); - } uint32 GetAreaId(uint32 mapid, float x, float y, float z) const { - return Map::GetAreaIdByAreaFlag(GetAreaFlag(mapid, x, y, z), mapid); + Map const* m = const_cast<MapManager*>(this)->CreateBaseMap(mapid); + return m->GetAreaId(x, y, z); } uint32 GetZoneId(uint32 mapid, float x, float y, float z) const { - return Map::GetZoneIdByAreaFlag(GetAreaFlag(mapid, x, y, z), mapid); + Map const* m = const_cast<MapManager*>(this)->CreateBaseMap(mapid); + return m->GetZoneId(x, y, z); } void GetZoneAndAreaId(uint32& zoneid, uint32& areaid, uint32 mapid, float x, float y, float z) { - Map::GetZoneAndAreaIdByAreaFlag(zoneid, areaid, GetAreaFlag(mapid, x, y, z), mapid); + Map const* m = const_cast<MapManager*>(this)->CreateBaseMap(mapid); + m->GetZoneAndAreaId(zoneid, areaid, x, y, z); } void Initialize(void); @@ -108,7 +106,7 @@ class MapManager void DoDelayedMovesAndRemoves(); - bool CanPlayerEnter(uint32 mapid, Player* player, bool loginCheck = false); + Map::EnterState PlayerCannotEnter(uint32 mapid, Player* player, bool loginCheck = false); void InitializeVisibilityDistanceInfo(); /* statistics */ diff --git a/src/server/game/Maps/MapRefManager.h b/src/server/game/Maps/MapRefManager.h index 5f1e14b3258..09aa67d43eb 100644 --- a/src/server/game/Maps/MapRefManager.h +++ b/src/server/game/Maps/MapRefManager.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Maps/MapReference.h b/src/server/game/Maps/MapReference.h index c479590de97..6f67bdfff93 100644 --- a/src/server/game/Maps/MapReference.h +++ b/src/server/game/Maps/MapReference.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Maps/MapUpdater.cpp b/src/server/game/Maps/MapUpdater.cpp index 20b8da796a5..b2e540bbbcf 100644 --- a/src/server/game/Maps/MapUpdater.cpp +++ b/src/server/game/Maps/MapUpdater.cpp @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Maps/MapUpdater.h b/src/server/game/Maps/MapUpdater.h index 16d11b2f453..3d0f0b9e7e8 100644 --- a/src/server/game/Maps/MapUpdater.h +++ b/src/server/game/Maps/MapUpdater.h @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Maps/TransportMgr.cpp b/src/server/game/Maps/TransportMgr.cpp index 84eba74c6dc..afbddc5e686 100644 --- a/src/server/game/Maps/TransportMgr.cpp +++ b/src/server/game/Maps/TransportMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Maps/TransportMgr.h b/src/server/game/Maps/TransportMgr.h index d100f60c604..0bfb5b7a410 100644 --- a/src/server/game/Maps/TransportMgr.h +++ b/src/server/game/Maps/TransportMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Maps/ZoneScript.h b/src/server/game/Maps/ZoneScript.h index fd52bdd4c14..e54c96dbb11 100644 --- a/src/server/game/Maps/ZoneScript.h +++ b/src/server/game/Maps/ZoneScript.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Miscellaneous/Formulas.h b/src/server/game/Miscellaneous/Formulas.h index 6edc3d74a5d..b5c6f37b14e 100644 --- a/src/server/game/Miscellaneous/Formulas.h +++ b/src/server/game/Miscellaneous/Formulas.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -185,6 +185,9 @@ namespace Trinity } xpMod *= isBattleGround ? sWorld->getRate(RATE_XP_BG_KILL) : sWorld->getRate(RATE_XP_KILL); + if (creature && creature->m_PlayerDamageReq) // if players dealt less than 50% of the damage and were credited anyway (due to CREATURE_FLAG_EXTRA_NO_PLAYER_DAMAGE_REQ), scale XP gained appropriately (linear scaling) + xpMod *= 1.0f - 2.0f*creature->m_PlayerDamageReq / creature->GetMaxHealth(); + gain = uint32(gain * xpMod); } diff --git a/src/server/game/Miscellaneous/Language.h b/src/server/game/Miscellaneous/Language.h index 85971396619..62c2a3a1981 100644 --- a/src/server/game/Miscellaneous/Language.h +++ b/src/server/game/Miscellaneous/Language.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -1203,7 +1203,11 @@ enum TrinityStrings LANG_NPCINFO_INHABIT_TYPE = 11008, LANG_NPCINFO_FLAGS_EXTRA = 11009, - LANG_INSTANCE_LOGIN_GAMEMASTER_EXCEPTION = 11010 + LANG_INSTANCE_LOGIN_GAMEMASTER_EXCEPTION = 11010, + LANG_CREATURE_NO_INTERIOR_POINT_FOUND = 11011, + LANG_CREATURE_MOVEMENT_NOT_BOUNDED = 11012, + LANG_CREATURE_MOVEMENT_MAYBE_UNBOUNDED = 11013, + LANG_INSTANCE_BIND_MISMATCH = 11014 }; #endif diff --git a/src/server/game/Miscellaneous/SharedDefines.h b/src/server/game/Miscellaneous/SharedDefines.h index ac16a83e6a7..77d6f739da6 100644 --- a/src/server/game/Miscellaneous/SharedDefines.h +++ b/src/server/game/Miscellaneous/SharedDefines.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/FollowerRefManager.h b/src/server/game/Movement/FollowerRefManager.h index a55bdfea4ba..ae7f942ca96 100644 --- a/src/server/game/Movement/FollowerRefManager.h +++ b/src/server/game/Movement/FollowerRefManager.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/FollowerReference.cpp b/src/server/game/Movement/FollowerReference.cpp index 29d1a2c35a6..81a1c8464da 100644 --- a/src/server/game/Movement/FollowerReference.cpp +++ b/src/server/game/Movement/FollowerReference.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/FollowerReference.h b/src/server/game/Movement/FollowerReference.h index 16e8da107c6..2922a09bde1 100644 --- a/src/server/game/Movement/FollowerReference.h +++ b/src/server/game/Movement/FollowerReference.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MotionMaster.cpp b/src/server/game/Movement/MotionMaster.cpp index cb8cab1849d..05948b987ad 100644 --- a/src/server/game/Movement/MotionMaster.cpp +++ b/src/server/game/Movement/MotionMaster.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -366,10 +366,10 @@ void MotionMaster::MoveJumpTo(float angle, float speedXY, float speedZ) float moveTimeHalf = speedZ / Movement::gravity; float dist = 2 * moveTimeHalf * speedXY; _owner->GetClosePoint(x, y, z, _owner->GetObjectSize(), dist, angle); - MoveJump(x, y, z, speedXY, speedZ); + MoveJump(x, y, z, 0.0f, speedXY, speedZ); } -void MotionMaster::MoveJump(float x, float y, float z, float speedXY, float speedZ, uint32 id) +void MotionMaster::MoveJump(float x, float y, float z, float o, float speedXY, float speedZ, uint32 id, bool hasOrientation /* = false*/) { TC_LOG_DEBUG("misc", "Unit (GUID: %u) jump to point (X: %f Y: %f Z: %f)", _owner->GetGUID().GetCounter(), x, y, z); if (speedXY <= 0.1f) @@ -382,6 +382,8 @@ void MotionMaster::MoveJump(float x, float y, float z, float speedXY, float spee init.MoveTo(x, y, z, false); init.SetParabolic(max_height, 0); init.SetVelocity(speedXY); + if (hasOrientation) + init.SetFacing(o); init.Launch(); Mutate(new EffectMovementGenerator(id), MOTION_SLOT_CONTROLLED); } diff --git a/src/server/game/Movement/MotionMaster.h b/src/server/game/Movement/MotionMaster.h index 9a8950de9f7..76ae12986d5 100644 --- a/src/server/game/Movement/MotionMaster.h +++ b/src/server/game/Movement/MotionMaster.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -181,9 +181,11 @@ class MotionMaster //: private std::stack<MovementGenerator *> void MoveCharge(PathGenerator const& path, float speed = SPEED_CHARGE); void MoveKnockbackFrom(float srcX, float srcY, float speedXY, float speedZ); void MoveJumpTo(float angle, float speedXY, float speedZ); - void MoveJump(Position const& pos, float speedXY, float speedZ, uint32 id = EVENT_JUMP) - { MoveJump(pos.m_positionX, pos.m_positionY, pos.m_positionZ, speedXY, speedZ, id); } - void MoveJump(float x, float y, float z, float speedXY, float speedZ, uint32 id = EVENT_JUMP); + void MoveJump(Position const& pos, float speedXY, float speedZ, uint32 id = EVENT_JUMP, bool hasOrientation = false) + { + MoveJump(pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), pos.GetOrientation(), speedXY, speedZ, id, hasOrientation); + } + void MoveJump(float x, float y, float z, float o, float speedXY, float speedZ, uint32 id = EVENT_JUMP, bool hasOrientation = false); void MoveCirclePath(float x, float y, float z, float radius, bool clockwise, uint8 stepCount); void MoveSmoothPath(uint32 pointId, G3D::Vector3 const* pathPoints, size_t pathSize, bool walk); void MoveFall(uint32 id = 0); diff --git a/src/server/game/Movement/MovementGenerator.cpp b/src/server/game/Movement/MovementGenerator.cpp index 8098b05f03a..b0eb34d54cd 100644 --- a/src/server/game/Movement/MovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerator.h b/src/server/game/Movement/MovementGenerator.h index 45fd252ddb9..56e5dc7058a 100755 --- a/src/server/game/Movement/MovementGenerator.h +++ b/src/server/game/Movement/MovementGenerator.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGeneratorImpl.h b/src/server/game/Movement/MovementGeneratorImpl.h index 1fc8c73b477..341cac5ed3b 100644 --- a/src/server/game/Movement/MovementGeneratorImpl.h +++ b/src/server/game/Movement/MovementGeneratorImpl.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/ConfusedMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/ConfusedMovementGenerator.cpp index f0c0311280f..108276c951a 100755 --- a/src/server/game/Movement/MovementGenerators/ConfusedMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/ConfusedMovementGenerator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/ConfusedMovementGenerator.h b/src/server/game/Movement/MovementGenerators/ConfusedMovementGenerator.h index 5b6d6c96482..4f8d7cbe1f2 100755 --- a/src/server/game/Movement/MovementGenerators/ConfusedMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/ConfusedMovementGenerator.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.cpp index fa17846a1ff..6cdd29986bb 100644 --- a/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.h b/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.h index dc42dc74991..b3e14887e22 100755 --- a/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/FleeingMovementGenerator.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.cpp index 7ab7534199a..77185f4f25e 100644 --- a/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.h b/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.h index cbb6f279c6d..9e43d9a0dc3 100644 --- a/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/HomeMovementGenerator.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/IdleMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/IdleMovementGenerator.cpp index 2aaaa719e94..9595777ddfe 100755 --- a/src/server/game/Movement/MovementGenerators/IdleMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/IdleMovementGenerator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/IdleMovementGenerator.h b/src/server/game/Movement/MovementGenerators/IdleMovementGenerator.h index 30a8b9b868e..9aa778c5651 100755 --- a/src/server/game/Movement/MovementGenerators/IdleMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/IdleMovementGenerator.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/PointMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/PointMovementGenerator.cpp index e233d52ecf5..38295f83859 100755 --- a/src/server/game/Movement/MovementGenerators/PointMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/PointMovementGenerator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/PointMovementGenerator.h b/src/server/game/Movement/MovementGenerators/PointMovementGenerator.h index 5b1155507aa..f73d51db962 100644 --- a/src/server/game/Movement/MovementGenerators/PointMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/PointMovementGenerator.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.cpp index 86f0e6e20eb..2e013c44ae8 100644 --- a/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.h b/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.h index 763e3294613..0e667ad4c8f 100644 --- a/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/RandomMovementGenerator.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/TargetedMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/TargetedMovementGenerator.cpp index 40bf3af5194..b595059557a 100644 --- a/src/server/game/Movement/MovementGenerators/TargetedMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/TargetedMovementGenerator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -39,6 +39,9 @@ void TargetedMovementGeneratorMedium<T, D>::_setTargetLocation(T* owner, bool up if (owner->GetTypeId() == TYPEID_UNIT && !i_target->isInAccessiblePlaceFor(owner->ToCreature())) return; + if (owner->GetTypeId() == TYPEID_UNIT && owner->ToCreature()->IsFocusing(nullptr, true)) + return; + float x, y, z; if (updateDestination || !i_path) diff --git a/src/server/game/Movement/MovementGenerators/TargetedMovementGenerator.h b/src/server/game/Movement/MovementGenerators/TargetedMovementGenerator.h index 77a669e0738..7103eaace55 100755 --- a/src/server/game/Movement/MovementGenerators/TargetedMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/TargetedMovementGenerator.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.cpp b/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.cpp index fe618e6ece7..48d29b3259b 100755 --- a/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.cpp +++ b/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.h b/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.h index caf76b5ea19..1dd4611d53b 100755 --- a/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.h +++ b/src/server/game/Movement/MovementGenerators/WaypointMovementGenerator.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/Spline/MovementPacketBuilder.cpp b/src/server/game/Movement/Spline/MovementPacketBuilder.cpp index c4fe8791362..40def87f6dd 100644 --- a/src/server/game/Movement/Spline/MovementPacketBuilder.cpp +++ b/src/server/game/Movement/Spline/MovementPacketBuilder.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify diff --git a/src/server/game/Movement/Spline/MovementPacketBuilder.h b/src/server/game/Movement/Spline/MovementPacketBuilder.h index 059d160a519..986cda6075d 100644 --- a/src/server/game/Movement/Spline/MovementPacketBuilder.h +++ b/src/server/game/Movement/Spline/MovementPacketBuilder.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify diff --git a/src/server/game/Movement/Waypoints/WaypointManager.cpp b/src/server/game/Movement/Waypoints/WaypointManager.cpp index cf319321c7c..e0639e38e77 100644 --- a/src/server/game/Movement/Waypoints/WaypointManager.cpp +++ b/src/server/game/Movement/Waypoints/WaypointManager.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Movement/Waypoints/WaypointManager.h b/src/server/game/Movement/Waypoints/WaypointManager.h index 17842484bf8..d519eee4793 100644 --- a/src/server/game/Movement/Waypoints/WaypointManager.h +++ b/src/server/game/Movement/Waypoints/WaypointManager.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/OutdoorPvP/OutdoorPvP.cpp b/src/server/game/OutdoorPvP/OutdoorPvP.cpp index 9046d9e6991..d329ab27de9 100644 --- a/src/server/game/OutdoorPvP/OutdoorPvP.cpp +++ b/src/server/game/OutdoorPvP/OutdoorPvP.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -687,7 +687,7 @@ void OutdoorPvP::BroadcastWorker(Worker& _worker, uint32 zoneId) void OutdoorPvP::SetMapFromZone(uint32 zone) { - AreaTableEntry const* areaTable = GetAreaEntryByAreaID(zone); + AreaTableEntry const* areaTable = sAreaTableStore.LookupEntry(zone); ASSERT(areaTable); Map* map = sMapMgr->CreateBaseMap(areaTable->mapid); ASSERT(!map->Instanceable()); diff --git a/src/server/game/OutdoorPvP/OutdoorPvP.h b/src/server/game/OutdoorPvP/OutdoorPvP.h index 4a423a8da5b..79f34ff10ea 100644 --- a/src/server/game/OutdoorPvP/OutdoorPvP.h +++ b/src/server/game/OutdoorPvP/OutdoorPvP.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/OutdoorPvP/OutdoorPvPMgr.cpp b/src/server/game/OutdoorPvP/OutdoorPvPMgr.cpp index 37a380bf576..8296cdfb7ea 100644 --- a/src/server/game/OutdoorPvP/OutdoorPvPMgr.cpp +++ b/src/server/game/OutdoorPvP/OutdoorPvPMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/OutdoorPvP/OutdoorPvPMgr.h b/src/server/game/OutdoorPvP/OutdoorPvPMgr.h index 542aad0ef0d..8a113987882 100644 --- a/src/server/game/OutdoorPvP/OutdoorPvPMgr.h +++ b/src/server/game/OutdoorPvP/OutdoorPvPMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Pools/PoolMgr.cpp b/src/server/game/Pools/PoolMgr.cpp index 1e7826f280b..12fb8a06b62 100644 --- a/src/server/game/Pools/PoolMgr.cpp +++ b/src/server/game/Pools/PoolMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Pools/PoolMgr.h b/src/server/game/Pools/PoolMgr.h index e165f9bd397..51e0bcb4cac 100644 --- a/src/server/game/Pools/PoolMgr.h +++ b/src/server/game/Pools/PoolMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://www.mangosproject.org/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Quests/QuestDef.cpp b/src/server/game/Quests/QuestDef.cpp index 1e4bb96303e..4a4ee9bff9c 100644 --- a/src/server/game/Quests/QuestDef.cpp +++ b/src/server/game/Quests/QuestDef.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Quests/QuestDef.h b/src/server/game/Quests/QuestDef.h index 91b4a3181f5..a502fef6140 100644 --- a/src/server/game/Quests/QuestDef.h +++ b/src/server/game/Quests/QuestDef.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Reputation/ReputationMgr.cpp b/src/server/game/Reputation/ReputationMgr.cpp index a4065fa6f82..fb2873f80bb 100644 --- a/src/server/game/Reputation/ReputationMgr.cpp +++ b/src/server/game/Reputation/ReputationMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Reputation/ReputationMgr.h b/src/server/game/Reputation/ReputationMgr.h index 7d7650b858e..6f319a39b0c 100644 --- a/src/server/game/Reputation/ReputationMgr.h +++ b/src/server/game/Reputation/ReputationMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Scripting/MapScripts.cpp b/src/server/game/Scripting/MapScripts.cpp index 63006bc6ed6..a01c109b9ca 100644 --- a/src/server/game/Scripting/MapScripts.cpp +++ b/src/server/game/Scripting/MapScripts.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Scripting/ScriptLoader.cpp b/src/server/game/Scripting/ScriptLoader.cpp index 47a23dedf0c..2922e4ef58d 100644 --- a/src/server/game/Scripting/ScriptLoader.cpp +++ b/src/server/game/Scripting/ScriptLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -89,7 +89,6 @@ void AddSC_item_scripts(); void AddSC_npc_professions(); void AddSC_npc_innkeeper(); void AddSC_npcs_special(); -void AddSC_npc_taxi(); void AddSC_achievement_scripts(); void AddSC_action_ip_logger(); void AddSC_duel_reset(); @@ -781,7 +780,6 @@ void AddWorldScripts() AddSC_npc_professions(); AddSC_npc_innkeeper(); AddSC_npcs_special(); - AddSC_npc_taxi(); AddSC_achievement_scripts(); AddSC_chat_log(); // location: scripts\World\chat_log.cpp // To avoid duplicate code, we check once /*ONLY*/ if logging is permitted or not. diff --git a/src/server/game/Scripting/ScriptLoader.h b/src/server/game/Scripting/ScriptLoader.h index 652ef994c7a..4adb215e130 100644 --- a/src/server/game/Scripting/ScriptLoader.h +++ b/src/server/game/Scripting/ScriptLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Scripting/ScriptMgr.cpp b/src/server/game/Scripting/ScriptMgr.cpp index 3cbdf93ca54..4b26ba96c9b 100644 --- a/src/server/game/Scripting/ScriptMgr.cpp +++ b/src/server/game/Scripting/ScriptMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -37,7 +37,6 @@ // namespace // { - UnusedScriptContainer UnusedScripts; UnusedScriptNamesContainer UnusedScriptNames; // } @@ -107,8 +106,9 @@ class ScriptRegistry // The actual list of scripts. This will be accessed concurrently, so it must not be modified // after server startup. static ScriptMap ScriptPointerList; + static std::vector<TScript*> Scripts; - static void AddScript(TScript* const script) + static void AddScript(TScript* const script, bool addToDeleteContainer = true) { ASSERT(script); @@ -126,6 +126,8 @@ class ScriptRegistry } AddScript(is_script_database_bound<TScript>{}, script); + if (addToDeleteContainer) + Scripts.push_back(script); } // Gets a script by its ID (assigned by ObjectMgr). @@ -186,11 +188,6 @@ class ScriptRegistry { // The script uses a script name from database, but isn't assigned to anything. TC_LOG_ERROR("sql.sql", "Script named '%s' does not have a script name assigned in database.", script->GetName().c_str()); - - // Avoid calling "delete script;" because we are currently in the script constructor - // In a valid scenario this will not happen because every script has a name assigned in the database - UnusedScripts.push_back(script); - return; } } @@ -210,6 +207,7 @@ class ScriptRegistry #define SCR_REG_MAP(T) ScriptRegistry<T>::ScriptMap #define SCR_REG_ITR(T) ScriptRegistry<T>::ScriptMapIterator #define SCR_REG_LST(T) ScriptRegistry<T>::ScriptPointerList +#define SCR_REG_VEC(T) ScriptRegistry<T>::Scripts // Utility macros for looping over scripts. #define FOR_SCRIPTS(T, C, E) \ @@ -266,17 +264,15 @@ void ScriptMgr::Initialize() } #endif - UnloadUnusedScripts(); - TC_LOG_INFO("server.loading", ">> Loaded %u C++ scripts in %u ms", GetScriptCount(), GetMSTimeDiffToNow(oldMSTime)); } void ScriptMgr::Unload() { #define SCR_CLEAR(T) \ - for (SCR_REG_ITR(T) itr = SCR_REG_LST(T).begin(); itr != SCR_REG_LST(T).end(); ++itr) \ - delete itr->second; \ - SCR_REG_LST(T).clear(); + for (T* scr : SCR_REG_VEC(T)) \ + delete scr; \ + SCR_REG_VEC(T).clear(); // Clear scripts for every script type. SCR_CLEAR(SpellScriptLoader); @@ -308,19 +304,10 @@ void ScriptMgr::Unload() #undef SCR_CLEAR - UnloadUnusedScripts(); - delete[] SpellSummary; delete[] UnitAI::AISpellInfo; } -void ScriptMgr::UnloadUnusedScripts() -{ - for (size_t i = 0; i < UnusedScripts.size(); ++i) - delete UnusedScripts[i]; - UnusedScripts.clear(); -} - void ScriptMgr::LoadDatabase() { sScriptSystemMgr->LoadScriptWaypoints(); @@ -1042,6 +1029,12 @@ std::vector<ChatCommand> ScriptMgr::GetChatCommands() table.insert(table.end(), cmds.begin(), cmds.end()); } + // Sort commands in alphabetical order + std::sort(table.begin(), table.end(), [](const ChatCommand& a, const ChatCommand&b) + { + return strcmp(a.Name, b.Name) < 0; + }); + return table; } @@ -1362,9 +1355,9 @@ void ScriptMgr::OnPlayerSave(Player* player) FOREACH_SCRIPT(PlayerScript)->OnSave(player); } -void ScriptMgr::OnPlayerBindToInstance(Player* player, Difficulty difficulty, uint32 mapid, bool permanent) +void ScriptMgr::OnPlayerBindToInstance(Player* player, Difficulty difficulty, uint32 mapid, bool permanent, uint8 extendState) { - FOREACH_SCRIPT(PlayerScript)->OnBindToInstance(player, difficulty, mapid, permanent); + FOREACH_SCRIPT(PlayerScript)->OnBindToInstance(player, difficulty, mapid, permanent, extendState); } void ScriptMgr::OnPlayerUpdateZone(Player* player, uint32 newZone, uint32 newArea) @@ -1549,8 +1542,7 @@ FormulaScript::FormulaScript(const char* name) UnitScript::UnitScript(const char* name, bool addToScripts) : ScriptObject(name) { - if (addToScripts) - ScriptRegistry<UnitScript>::AddScript(this); + ScriptRegistry<UnitScript>::AddScript(this, addToScripts); } WorldMapScript::WorldMapScript(const char* name, uint32 mapId) @@ -1690,6 +1682,7 @@ GroupScript::GroupScript(const char* name) // Instantiate static members of ScriptRegistry. template<class TScript> std::map<uint32, TScript*> ScriptRegistry<TScript>::ScriptPointerList; +template<class TScript> std::vector<TScript*> ScriptRegistry<TScript>::Scripts; template<class TScript> uint32 ScriptRegistry<TScript>::_scriptIdCounter = 0; // Specialize for each script type class like so: diff --git a/src/server/game/Scripting/ScriptMgr.h b/src/server/game/Scripting/ScriptMgr.h index 046c6c1a009..8a00305b4da 100644 --- a/src/server/game/Scripting/ScriptMgr.h +++ b/src/server/game/Scripting/ScriptMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -734,7 +734,7 @@ class PlayerScript : public UnitScript virtual void OnSave(Player* /*player*/) { } // Called when a player is bound to an instance - virtual void OnBindToInstance(Player* /*player*/, Difficulty /*difficulty*/, uint32 /*mapId*/, bool /*permanent*/) { } + virtual void OnBindToInstance(Player* /*player*/, Difficulty /*difficulty*/, uint32 /*mapId*/, bool /*permanent*/, uint8 /*extendState*/) { } // Called when a player switches to a new zone virtual void OnUpdateZone(Player* /*player*/, uint32 /*newZone*/, uint32 /*newArea*/) { } @@ -843,10 +843,7 @@ class GroupScript : public ScriptObject // namespace // { - typedef std::vector<ScriptObject*> UnusedScriptContainer; typedef std::list<std::string> UnusedScriptNamesContainer; - - extern UnusedScriptContainer UnusedScripts; extern UnusedScriptNamesContainer UnusedScriptNames; // } @@ -878,7 +875,6 @@ class ScriptMgr public: /* Unloading */ void Unload(); - void UnloadUnusedScripts(); public: /* SpellScriptLoader */ @@ -1054,7 +1050,7 @@ class ScriptMgr void OnPlayerDelete(ObjectGuid guid, uint32 accountId); void OnPlayerFailedDelete(ObjectGuid guid, uint32 accountId); void OnPlayerSave(Player* player); - void OnPlayerBindToInstance(Player* player, Difficulty difficulty, uint32 mapid, bool permanent); + void OnPlayerBindToInstance(Player* player, Difficulty difficulty, uint32 mapid, bool permanent, uint8 extendState); void OnPlayerUpdateZone(Player* player, uint32 newZone, uint32 newArea); void OnQuestStatusChange(Player* player, uint32 questId, QuestStatus status); diff --git a/src/server/game/Scripting/ScriptSystem.cpp b/src/server/game/Scripting/ScriptSystem.cpp index 742e2a1e77c..e828830ec0f 100644 --- a/src/server/game/Scripting/ScriptSystem.cpp +++ b/src/server/game/Scripting/ScriptSystem.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Server/Protocol/Opcodes.cpp b/src/server/game/Server/Protocol/Opcodes.cpp index 4f7b8f510b0..6c9fce26803 100644 --- a/src/server/game/Server/Protocol/Opcodes.cpp +++ b/src/server/game/Server/Protocol/Opcodes.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Server/Protocol/Opcodes.h b/src/server/game/Server/Protocol/Opcodes.h index 4b47e51fde6..0d30134aa9f 100644 --- a/src/server/game/Server/Protocol/Opcodes.h +++ b/src/server/game/Server/Protocol/Opcodes.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Server/Protocol/PacketLog.cpp b/src/server/game/Server/Protocol/PacketLog.cpp index 717192b42fd..57b76304a77 100644 --- a/src/server/game/Server/Protocol/PacketLog.cpp +++ b/src/server/game/Server/Protocol/PacketLog.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Server/Protocol/PacketLog.h b/src/server/game/Server/Protocol/PacketLog.h index e23a22fe8c0..45a3f0a4655 100644 --- a/src/server/game/Server/Protocol/PacketLog.h +++ b/src/server/game/Server/Protocol/PacketLog.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Server/Protocol/ServerPktHeader.h b/src/server/game/Server/Protocol/ServerPktHeader.h index 0fd1f85f969..3f21a51e0fc 100644 --- a/src/server/game/Server/Protocol/ServerPktHeader.h +++ b/src/server/game/Server/Protocol/ServerPktHeader.h @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Server/WorldSession.cpp b/src/server/game/Server/WorldSession.cpp index 6ae63f2efa3..c380c1a5627 100644 --- a/src/server/game/Server/WorldSession.cpp +++ b/src/server/game/Server/WorldSession.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Server/WorldSession.h b/src/server/game/Server/WorldSession.h index af2d2d22c57..2253b6bc684 100644 --- a/src/server/game/Server/WorldSession.h +++ b/src/server/game/Server/WorldSession.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Server/WorldSocket.cpp b/src/server/game/Server/WorldSocket.cpp index 1dc470744a1..a2d357cbc4d 100644 --- a/src/server/game/Server/WorldSocket.cpp +++ b/src/server/game/Server/WorldSocket.cpp @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Server/WorldSocket.h b/src/server/game/Server/WorldSocket.h index f0da520cf4c..9e5b35992a6 100644 --- a/src/server/game/Server/WorldSocket.h +++ b/src/server/game/Server/WorldSocket.h @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Server/WorldSocketMgr.cpp b/src/server/game/Server/WorldSocketMgr.cpp index da35017cc2b..529396b3966 100644 --- a/src/server/game/Server/WorldSocketMgr.cpp +++ b/src/server/game/Server/WorldSocketMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2008 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Skills/SkillDiscovery.cpp b/src/server/game/Skills/SkillDiscovery.cpp index 2cb556a82ac..36a7d147192 100644 --- a/src/server/game/Skills/SkillDiscovery.cpp +++ b/src/server/game/Skills/SkillDiscovery.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Skills/SkillDiscovery.h b/src/server/game/Skills/SkillDiscovery.h index 2126445a1c4..b7fe1cdc8b2 100644 --- a/src/server/game/Skills/SkillDiscovery.h +++ b/src/server/game/Skills/SkillDiscovery.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Skills/SkillExtraItems.cpp b/src/server/game/Skills/SkillExtraItems.cpp index 50e00b24133..5213944cc90 100644 --- a/src/server/game/Skills/SkillExtraItems.cpp +++ b/src/server/game/Skills/SkillExtraItems.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Skills/SkillExtraItems.h b/src/server/game/Skills/SkillExtraItems.h index 118c49ed00f..2889b221600 100644 --- a/src/server/game/Skills/SkillExtraItems.h +++ b/src/server/game/Skills/SkillExtraItems.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Spells/Auras/SpellAuraDefines.h b/src/server/game/Spells/Auras/SpellAuraDefines.h index 9cbd280f9d1..e0daf59fcc2 100644 --- a/src/server/game/Spells/Auras/SpellAuraDefines.h +++ b/src/server/game/Spells/Auras/SpellAuraDefines.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Spells/Auras/SpellAuraEffects.cpp b/src/server/game/Spells/Auras/SpellAuraEffects.cpp index 01f27a38e9c..207908c6d51 100644 --- a/src/server/game/Spells/Auras/SpellAuraEffects.cpp +++ b/src/server/game/Spells/Auras/SpellAuraEffects.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -1103,18 +1103,11 @@ void AuraEffect::HandleShapeshiftBoosts(Unit* target, bool apply) const if (apply) { - // Remove cooldown of spells triggered on stance change - they may share cooldown with stance spell if (spellId) - { - target->GetSpellHistory()->ResetCooldown(spellId); target->CastSpell(target, spellId, true, NULL, this); - } if (spellId2) - { - target->GetSpellHistory()->ResetCooldown(spellId2); target->CastSpell(target, spellId2, true, NULL, this); - } if (target->GetTypeId() == TYPEID_PLAYER) { @@ -4690,11 +4683,6 @@ void AuraEffect::HandleAuraDummy(AuraApplication const* aurApp, uint8 mode, bool if (target->GetTypeId() == TYPEID_PLAYER) target->ToPlayer()->RemoveAmmo(); // not use ammo and not allow use break; - case 52916: // Honor Among Thieves - if (target->GetTypeId() == TYPEID_PLAYER) - if (Unit* spellTarget = ObjectAccessor::GetUnit(*target, target->ToPlayer()->GetComboTarget())) - target->CastSpell(spellTarget, 51699, true); - break; case 71563: if (Aura* newAura = target->AddAura(71564, target)) newAura->SetStackAmount(newAura->GetSpellInfo()->StackAmount); @@ -5626,25 +5614,6 @@ void AuraEffect::HandlePeriodicTriggerSpellAuraTick(Unit* target, Unit* caster) target->RemoveAurasDueToSpell(28820); return; } - // Totemic Mastery (Skyshatter Regalia (Shaman Tier 6) - bonus) - case 38443: - { - bool all = true; - for (int i = SUMMON_SLOT_TOTEM; i < MAX_TOTEM_SLOT; ++i) - { - if (!target->m_SummonSlot[i]) - { - all = false; - break; - } - } - - if (all) - target->CastSpell(target, 38437, true, NULL, this); - else - target->RemoveAurasDueToSpell(38437); - return; - } } break; } diff --git a/src/server/game/Spells/Auras/SpellAuraEffects.h b/src/server/game/Spells/Auras/SpellAuraEffects.h index 753d16a97e1..b400520a08a 100644 --- a/src/server/game/Spells/Auras/SpellAuraEffects.h +++ b/src/server/game/Spells/Auras/SpellAuraEffects.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Spells/Auras/SpellAuras.cpp b/src/server/game/Spells/Auras/SpellAuras.cpp index 93b8c3eb368..1ca5df6b327 100644 --- a/src/server/game/Spells/Auras/SpellAuras.cpp +++ b/src/server/game/Spells/Auras/SpellAuras.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -1487,7 +1487,7 @@ void Aura::HandleAuraSpecificMods(AuraApplication const* aurApp, Unit* caster, b { // This additional check is needed to add a minimal delay before cooldown in in effect // to allow all bubbles broken by a single damage source proc mana return - if (caster->GetSpellHistory()->GetRemainingCooldown(aura->GetSpellInfo()) <= 11) + if (caster->GetSpellHistory()->GetRemainingCooldown(aura->GetSpellInfo()) <= 11 * IN_MILLISECONDS) break; } else // and add if needed @@ -1596,16 +1596,6 @@ void Aura::HandleAuraSpecificMods(AuraApplication const* aurApp, Unit* caster, b // mods at aura apply or remove switch (GetSpellInfo()->SpellFamilyName) { - case SPELLFAMILY_DRUID: - // Enrage - if ((GetSpellInfo()->SpellFamilyFlags[0] & 0x80000) && GetSpellInfo()->SpellIconID == 961) - { - if (target->HasAura(70726)) // Item - Druid T10 Feral 4P Bonus - if (apply) - target->CastSpell(target, 70725, true); - break; - } - break; case SPELLFAMILY_ROGUE: // Stealth if (GetSpellInfo()->SpellFamilyFlags[0] & 0x00400000) diff --git a/src/server/game/Spells/Auras/SpellAuras.h b/src/server/game/Spells/Auras/SpellAuras.h index 6abcd578411..2180f524194 100644 --- a/src/server/game/Spells/Auras/SpellAuras.h +++ b/src/server/game/Spells/Auras/SpellAuras.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Spells/Spell.cpp b/src/server/game/Spells/Spell.cpp index 4f3b60d6f37..23e2f144ff2 100644 --- a/src/server/game/Spells/Spell.cpp +++ b/src/server/game/Spells/Spell.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -602,6 +602,8 @@ m_caster((info->HasAttribute(SPELL_ATTR6_CAST_BY_CHARMER) && caster->GetCharmerO //Auto Shot & Shoot (wand) m_autoRepeat = m_spellInfo->IsAutoRepeatRangedSpell(); + + m_isDelayedInstantCast = false; m_runesState = 0; m_powerCost = 0; // setup to correct value in Spell::prepare, must not be used before. @@ -2359,7 +2361,7 @@ void Spell::DoAllEffectOnTarget(TargetInfo* target) // Do healing and triggers if (m_healing > 0) { - bool crit = caster->IsSpellCrit(unitTarget, m_spellInfo, m_spellSchoolMask); + bool crit = target->crit; uint32 addhealth = m_healing; if (crit) { @@ -2384,7 +2386,7 @@ void Spell::DoAllEffectOnTarget(TargetInfo* target) SpellNonMeleeDamage damageInfo(caster, unitTarget, m_spellInfo->Id, m_spellSchoolMask); // Add bonuses and fill damageInfo struct - caster->CalculateSpellDamageTaken(&damageInfo, m_damage, m_spellInfo, m_attackType, target->crit); + caster->CalculateSpellDamageTaken(&damageInfo, m_damage, m_spellInfo, m_attackType, target->crit); caster->DealDamageMods(damageInfo.target, damageInfo.damage, &damageInfo.absorb); // Send log damage message to client @@ -2427,7 +2429,7 @@ void Spell::DoAllEffectOnTarget(TargetInfo* target) if (missInfo != SPELL_MISS_EVADE && !m_caster->IsFriendlyTo(unit) && (!m_spellInfo->IsPositive() || m_spellInfo->HasEffect(SPELL_EFFECT_DISPEL))) { - m_caster->CombatStart(unit, !m_spellInfo->HasAttribute(SPELL_ATTR3_NO_INITIAL_AGGRO)); + m_caster->CombatStart(unit, m_spellInfo->HasInitialAggro()); if (!unit->IsStandState()) unit->SetStandState(UNIT_STAND_STATE_STAND); @@ -2533,7 +2535,7 @@ SpellMissInfo Spell::DoSpellHitOnUnit(Unit* unit, uint32 effectMask, bool scaleA if (m_caster->GetTypeId() == TYPEID_PLAYER) m_caster->ToPlayer()->UpdatePvP(true); } - if (unit->IsInCombat() && !m_spellInfo->HasAttribute(SPELL_ATTR3_NO_INITIAL_AGGRO)) + if (unit->IsInCombat() && m_spellInfo->HasInitialAggro()) { m_caster->SetInCombatState(unit->GetCombatTimer() > 0, unit); unit->getHostileRefManager().threatAssist(m_caster, 0.0f); @@ -2936,6 +2938,27 @@ void Spell::prepare(SpellCastTargets const* targets, AuraEffect const* triggered else m_casttime = m_spellInfo->CalcCastTime(this); + if (m_caster->GetTypeId() == TYPEID_UNIT && !m_caster->HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PLAYER_CONTROLLED)) // _UNIT actually means creature. for some reason. + if (!(IsNextMeleeSwingSpell() || IsAutoRepeat() || _triggeredCastFlags & TRIGGERED_IGNORE_SET_FACING)) + { + if (m_targets.GetObjectTarget() && m_caster != m_targets.GetObjectTarget()) + { + if (m_caster->ToCreature()->FocusTarget(this, m_targets.GetObjectTarget())) + { + m_isDelayedInstantCast = true; + m_timer = 100; // 100ms delay ensures client has updated creature orientation when cast goes off + } + } + else if (m_spellInfo->HasAttribute(SPELL_ATTR5_DONT_TURN_DURING_CAST)) + { + if (m_caster->ToCreature()->FocusTarget(this, nullptr)) + { + m_isDelayedInstantCast = true; + m_timer = 100; + } + } + } + // don't allow channeled spells / spells with cast time to be cast while moving // (even if they are interrupted on moving, spells with almost immediate effect get to have their effect processed before movement interrupter kicks in) if ((m_spellInfo->IsChanneled() || m_casttime) && m_caster->GetTypeId() == TYPEID_PLAYER && m_caster->isMoving() && m_spellInfo->InterruptFlags & SPELL_INTERRUPT_FLAG_MOVEMENT) @@ -2971,18 +2994,14 @@ void Spell::prepare(SpellCastTargets const* targets, AuraEffect const* triggered } m_caster->SetCurrentCastSpell(this); - SendSpellStart(); - - // set target for proper facing - if ((m_casttime || m_spellInfo->IsChanneled()) && !(_triggeredCastFlags & TRIGGERED_IGNORE_SET_FACING)) - if (m_caster->GetTypeId() == TYPEID_UNIT && m_targets.GetObjectTarget() && m_caster != m_targets.GetObjectTarget()) - m_caster->ToCreature()->FocusTarget(this, m_targets.GetObjectTarget()); + if (!m_isDelayedInstantCast) + SendSpellStart(); if (!(_triggeredCastFlags & TRIGGERED_IGNORE_GCD)) TriggerGlobalCooldown(); //item: first cast may destroy item and second cast causes crash - if (!m_casttime && !m_spellInfo->StartRecoveryTime && !m_castItemGUID && GetCurrentContainer() == CURRENT_GENERIC_SPELL) + if (!m_casttime && !m_isDelayedInstantCast && !m_spellInfo->StartRecoveryTime && !m_castItemGUID && GetCurrentContainer() == CURRENT_GENERIC_SPELL) cast(true); } } @@ -2991,6 +3010,9 @@ void Spell::cancel() { if (m_spellState == SPELL_STATE_FINISHED) return; + // delayed instant casts are used for client-side visual orientation; they are treated as instant for all intents and purposes server-side, and thus cannot be interrupted by another cast + if (m_isDelayedInstantCast) + return; uint32 oldState = m_spellState; m_spellState = SPELL_STATE_FINISHED; @@ -3060,6 +3082,9 @@ void Spell::cast(bool skipCheck) return; } + if (m_isDelayedInstantCast) + SendSpellStart(); + if (Player* playerCaster = m_caster->ToPlayer()) { // now that we've done the basic check, now run the scripts @@ -3139,6 +3164,16 @@ void Spell::cast(bool skipCheck) } } + // if the spell allows the creature to turn while casting, then adjust server-side orientation to face the target now + // client-side orientation is handled by the client itself, as the cast target is targeted due to Creature::FocusTarget + if (m_caster->GetTypeId() == TYPEID_UNIT && !m_caster->HasFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_PLAYER_CONTROLLED)) + if (!m_spellInfo->HasAttribute(SPELL_ATTR5_DONT_TURN_DURING_CAST)) + if (WorldObject* objTarget = m_targets.GetObjectTarget()) + { + m_caster->SetInFront(objTarget); + m_caster->SetFacingToObject(objTarget); + } + SelectSpellTargets(); // Spell may be finished after target map check @@ -3242,6 +3277,9 @@ void Spell::cast(bool skipCheck) } SetExecutedCurrently(false); + + if (Creature* creatureCaster = m_caster->ToCreature()) + creatureCaster->ReleaseFocus(this); } void Spell::handle_immediate() @@ -4207,21 +4245,16 @@ void Spell::SendResurrectRequest(Player* target) { // get resurrector name for creature resurrections, otherwise packet will be not accepted // for player resurrections the name is looked up by guid - std::string const sentName(m_caster->GetTypeId() == TYPEID_PLAYER - ? "" - : m_caster->GetNameForLocaleIdx(target->GetSession()->GetSessionDbLocaleIndex())); + std::string const sentName(m_caster->GetTypeId() == TYPEID_PLAYER ? + "" : m_caster->GetNameForLocaleIdx(target->GetSession()->GetSessionDbLocaleIndex())); - WorldPacket data(SMSG_RESURRECT_REQUEST, (8+4+sentName.size()+1+1+1+4)); + WorldPacket data(SMSG_RESURRECT_REQUEST, 8 + 4 + sentName.size() + 1 + 1 + 1); data << uint64(m_caster->GetGUID()); data << uint32(sentName.size() + 1); - data << sentName; - data << uint8(0); // null terminator - - data << uint8(m_caster->GetTypeId() == TYPEID_PLAYER ? 0 : 1); // "you'll be afflicted with resurrection sickness" + data << uint8(m_caster->IsSpiritHealer()); // "you'll be afflicted with resurrection sickness" // override delay sent with SMSG_CORPSE_RECLAIM_DELAY, set instant resurrection for spells with this attribute - if (m_spellInfo->HasAttribute(SPELL_ATTR3_IGNORE_RESURRECTION_TIMER)) - data << uint32(0); + data << uint8(!m_spellInfo->HasAttribute(SPELL_ATTR3_IGNORE_RESURRECTION_TIMER)); target->GetSession()->SendPacket(&data); } @@ -4578,8 +4611,7 @@ void Spell::HandleThreatSpells() if (m_UniqueTargetInfo.empty()) return; - if (m_spellInfo->HasAttribute(SPELL_ATTR1_NO_THREAT) || - m_spellInfo->HasAttribute(SPELL_ATTR3_NO_INITIAL_AGGRO)) + if (!m_spellInfo->HasInitialAggro()) return; float threat = 0.0f; @@ -4590,7 +4622,7 @@ void Spell::HandleThreatSpells() threat += threatEntry->flatMod; } - else if (m_spellInfo->HasAttribute(SPELL_ATTR0_CU_NO_INITIAL_THREAT) == 0) + else if (!m_spellInfo->HasAttribute(SPELL_ATTR0_CU_NO_INITIAL_THREAT)) threat += m_spellInfo->SpellLevel; // past this point only multiplicative effects occur @@ -4668,7 +4700,7 @@ SpellCastResult Spell::CheckCast(bool strict) return SPELL_FAILED_NOT_READY; } - if (!m_caster->GetSpellHistory()->IsReady(m_spellInfo, m_castItemEntry)) + if (!m_caster->GetSpellHistory()->IsReady(m_spellInfo, m_castItemEntry, IsIgnoringCooldowns())) { if (m_triggeredByAuraSpell) return SPELL_FAILED_DONT_REPORT; @@ -5444,7 +5476,7 @@ SpellCastResult Spell::CheckCast(bool strict) if (m_originalCaster && m_originalCaster->GetTypeId() == TYPEID_PLAYER && m_originalCaster->IsAlive()) { Battlefield* Bf = sBattlefieldMgr->GetBattlefieldToZoneId(m_originalCaster->GetZoneId()); - if (AreaTableEntry const* area = GetAreaEntryByAreaID(m_originalCaster->GetAreaId())) + if (AreaTableEntry const* area = sAreaTableStore.LookupEntry(m_originalCaster->GetAreaId())) if (area->flags & AREA_FLAG_NO_FLY_ZONE || (Bf && !Bf->CanFlyIn())) return (_triggeredCastFlags & TRIGGERED_DONT_REPORT_CAST_ERROR) ? SPELL_FAILED_DONT_REPORT : SPELL_FAILED_NOT_HERE; } @@ -5512,7 +5544,7 @@ SpellCastResult Spell::CheckPetCast(Unit* target) // dead owner (pets still alive when owners ressed?) if (Unit* owner = m_caster->GetCharmerOrOwner()) - if (!owner->IsAlive()) + if (!owner->IsAlive() && !owner->IsGhouled()) return SPELL_FAILED_CASTER_DEAD; if (!target && m_targets.GetUnitTarget()) diff --git a/src/server/game/Spells/Spell.h b/src/server/game/Spells/Spell.h index 6b96f56c538..696d2801645 100644 --- a/src/server/game/Spells/Spell.h +++ b/src/server/game/Spells/Spell.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -524,6 +524,7 @@ class Spell int32 m_channeledDuration; // Calculated channeled spell duration in order to calculate correct pushback. bool m_canReflect; // can reflect this spell? bool m_autoRepeat; + bool m_isDelayedInstantCast; // whether this is a creature's delayed instant cast uint8 m_runesState; uint8 m_delayAtDamageCount; diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp index b3ab72dcbff..9535ca291eb 100644 --- a/src/server/game/Spells/SpellEffects.cpp +++ b/src/server/game/Spells/SpellEffects.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -877,11 +877,6 @@ void Spell::EffectTriggerSpell(SpellEffIndex effIndex) values.AddSpellMod(SPELLVALUE_BASE_POINT2, damage); } - // Remove spell cooldown (not category) if spell triggering spell with cooldown and same category - if (m_caster->GetTypeId() == TYPEID_PLAYER && m_spellInfo->CategoryRecoveryTime && spellInfo->CategoryRecoveryTime - && m_spellInfo->GetCategory() == spellInfo->GetCategory()) - m_caster->GetSpellHistory()->ResetCooldown(spellInfo->Id); - // original caster guid only for GO cast m_caster->CastSpell(targets, spellInfo, &values, TRIGGERED_FULL_MASK, NULL, NULL, m_originalCasterGUID); } @@ -930,11 +925,6 @@ void Spell::EffectTriggerMissileSpell(SpellEffIndex effIndex) values.AddSpellMod(SPELLVALUE_BASE_POINT2, damage); } - // Remove spell cooldown (not category) if spell triggering spell with cooldown and same category - if (m_caster->GetTypeId() == TYPEID_PLAYER && m_spellInfo->CategoryRecoveryTime && spellInfo->CategoryRecoveryTime - && m_spellInfo->GetCategory() == spellInfo->GetCategory()) - m_caster->GetSpellHistory()->ResetCooldown(spellInfo->Id); - // original caster guid only for GO cast m_caster->CastSpell(targets, spellInfo, &values, TRIGGERED_FULL_MASK, NULL, NULL, m_originalCasterGUID); } @@ -1031,7 +1021,7 @@ void Spell::EffectJump(SpellEffIndex effIndex) float speedXY, speedZ; CalculateJumpSpeeds(effIndex, m_caster->GetExactDist2d(x, y), speedXY, speedZ); - m_caster->GetMotionMaster()->MoveJump(x, y, z, speedXY, speedZ); + m_caster->GetMotionMaster()->MoveJump(x, y, z, 0.0f, speedXY, speedZ, EVENT_JUMP, false); } void Spell::EffectJumpDest(SpellEffIndex effIndex) @@ -1045,13 +1035,9 @@ void Spell::EffectJumpDest(SpellEffIndex effIndex) if (!m_targets.HasDst()) return; - // Init dest coordinates - float x, y, z; - destTarget->GetPosition(x, y, z); - float speedXY, speedZ; - CalculateJumpSpeeds(effIndex, m_caster->GetExactDist2d(x, y), speedXY, speedZ); - m_caster->GetMotionMaster()->MoveJump(x, y, z, speedXY, speedZ); + CalculateJumpSpeeds(effIndex, m_caster->GetExactDist2d(destTarget), speedXY, speedZ); + m_caster->GetMotionMaster()->MoveJump(*destTarget, speedXY, speedZ, EVENT_JUMP, true); } void Spell::CalculateJumpSpeeds(uint8 i, float dist, float & speedXY, float & speedZ) @@ -4147,14 +4133,14 @@ void Spell::EffectDuel(SpellEffIndex effIndex) return; // Players can only fight a duel in zones with this flag - AreaTableEntry const* casterAreaEntry = GetAreaEntryByAreaID(caster->GetAreaId()); + AreaTableEntry const* casterAreaEntry = sAreaTableStore.LookupEntry(caster->GetAreaId()); if (casterAreaEntry && !(casterAreaEntry->flags & AREA_FLAG_ALLOW_DUELS)) { SendCastResult(SPELL_FAILED_NO_DUELING); // Dueling isn't allowed here return; } - AreaTableEntry const* targetAreaEntry = GetAreaEntryByAreaID(target->GetAreaId()); + AreaTableEntry const* targetAreaEntry = sAreaTableStore.LookupEntry(target->GetAreaId()); if (targetAreaEntry && !(targetAreaEntry->flags & AREA_FLAG_ALLOW_DUELS)) { SendCastResult(SPELL_FAILED_NO_DUELING); // Dueling isn't allowed here @@ -4913,7 +4899,7 @@ void Spell::EffectPullTowards(SpellEffIndex effIndex) float speedXY = float(m_spellInfo->Effects[effIndex].MiscValue) * 0.1f; float speedZ = unitTarget->GetDistance(pos) / speedXY * 0.5f * Movement::gravity; - unitTarget->GetMotionMaster()->MoveJump(pos.GetPositionX(), pos.GetPositionY(), pos.GetPositionZ(), speedXY, speedZ); + unitTarget->GetMotionMaster()->MoveJump(pos, speedXY, speedZ); } void Spell::EffectDispelMechanic(SpellEffIndex effIndex) diff --git a/src/server/game/Spells/SpellHistory.cpp b/src/server/game/Spells/SpellHistory.cpp index faad54d0af7..adf5fc47c77 100644 --- a/src/server/game/Spells/SpellHistory.cpp +++ b/src/server/game/Spells/SpellHistory.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -182,13 +182,13 @@ void SpellHistory::HandleCooldowns(SpellInfo const* spellInfo, uint32 itemID, Sp StartCooldown(spellInfo, itemID, spell); } -bool SpellHistory::IsReady(SpellInfo const* spellInfo, uint32 itemId /*= 0*/) const +bool SpellHistory::IsReady(SpellInfo const* spellInfo, uint32 itemId /*= 0*/, bool ignoreCategoryCooldown /*= false*/) const { if (spellInfo->PreventionType == SPELL_PREVENTION_TYPE_SILENCE) if (IsSchoolLocked(spellInfo->GetSchoolMask())) return false; - if (HasCooldown(spellInfo->Id, itemId)) + if (HasCooldown(spellInfo->Id, itemId, ignoreCategoryCooldown)) return false; return true; @@ -465,11 +465,14 @@ void SpellHistory::ResetAllCooldowns() _spellCooldowns.clear(); } -bool SpellHistory::HasCooldown(SpellInfo const* spellInfo, uint32 itemId /*= 0*/) const +bool SpellHistory::HasCooldown(SpellInfo const* spellInfo, uint32 itemId /*= 0*/, bool ignoreCategoryCooldown /*= false*/) const { if (_spellCooldowns.count(spellInfo->Id) != 0) return true; + if (ignoreCategoryCooldown) + return false; + uint32 category = 0; GetCooldownDurations(spellInfo, itemId, nullptr, &category, nullptr); if (!category) @@ -478,9 +481,9 @@ bool SpellHistory::HasCooldown(SpellInfo const* spellInfo, uint32 itemId /*= 0*/ return _categoryCooldowns.count(category) != 0; } -bool SpellHistory::HasCooldown(uint32 spellId, uint32 itemId /*= 0*/) const +bool SpellHistory::HasCooldown(uint32 spellId, uint32 itemId /*= 0*/, bool ignoreCategoryCooldown /*= false*/) const { - return HasCooldown(sSpellMgr->EnsureSpellInfo(spellId), itemId); + return HasCooldown(sSpellMgr->EnsureSpellInfo(spellId), itemId, ignoreCategoryCooldown); } uint32 SpellHistory::GetRemainingCooldown(SpellInfo const* spellInfo) const diff --git a/src/server/game/Spells/SpellHistory.h b/src/server/game/Spells/SpellHistory.h index db65cd50c3e..f0a53fe130d 100644 --- a/src/server/game/Spells/SpellHistory.h +++ b/src/server/game/Spells/SpellHistory.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -62,7 +62,7 @@ public: void HandleCooldowns(SpellInfo const* spellInfo, Item const* item, Spell* spell = nullptr); void HandleCooldowns(SpellInfo const* spellInfo, uint32 itemID, Spell* spell = nullptr); - bool IsReady(SpellInfo const* spellInfo, uint32 itemId = 0) const; + bool IsReady(SpellInfo const* spellInfo, uint32 itemId = 0, bool ignoreCategoryCooldown = false) const; template<class OwnerType> void WritePacket(WorldPacket& packet) const; @@ -105,8 +105,8 @@ public: } void ResetAllCooldowns(); - bool HasCooldown(SpellInfo const* spellInfo, uint32 itemId = 0) const; - bool HasCooldown(uint32 spellId, uint32 itemId = 0) const; + bool HasCooldown(SpellInfo const* spellInfo, uint32 itemId = 0, bool ignoreCategoryCooldown = false) const; + bool HasCooldown(uint32 spellId, uint32 itemId = 0, bool ignoreCategoryCooldown = false) const; uint32 GetRemainingCooldown(SpellInfo const* spellInfo) const; // School lockouts diff --git a/src/server/game/Spells/SpellInfo.cpp b/src/server/game/Spells/SpellInfo.cpp index 6486a7eada7..069c794ca8b 100644 --- a/src/server/game/Spells/SpellInfo.cpp +++ b/src/server/game/Spells/SpellInfo.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -1180,6 +1180,11 @@ bool SpellInfo::IsAutoRepeatRangedSpell() const return HasAttribute(SPELL_ATTR2_AUTOREPEAT_FLAG); } +bool SpellInfo::HasInitialAggro() const +{ + return !(HasAttribute(SPELL_ATTR1_NO_THREAT) || HasAttribute(SPELL_ATTR3_NO_INITIAL_AGGRO)); +} + bool SpellInfo::IsAffectedBySpellMods() const { return !HasAttribute(SPELL_ATTR3_NO_DONE_BONUS); diff --git a/src/server/game/Spells/SpellInfo.h b/src/server/game/Spells/SpellInfo.h index d042f926d02..ba658c885fa 100644 --- a/src/server/game/Spells/SpellInfo.h +++ b/src/server/game/Spells/SpellInfo.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -420,6 +420,7 @@ public: bool IsBreakingStealth() const; bool IsRangedWeaponSpell() const; bool IsAutoRepeatRangedSpell() const; + bool HasInitialAggro() const; bool IsAffectedBySpellMods() const; bool IsAffectedBySpellMod(SpellModifier const* mod) const; diff --git a/src/server/game/Spells/SpellMgr.cpp b/src/server/game/Spells/SpellMgr.cpp index debe4ac3cbf..f5bb1c920fe 100644 --- a/src/server/game/Spells/SpellMgr.cpp +++ b/src/server/game/Spells/SpellMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -969,10 +969,12 @@ bool SpellMgr::CanSpellTriggerProcOnEvent(SpellProcEntry const& procEntry, ProcE // check spell family name/flags (if set) for spells if (eventInfo.GetTypeMask() & (PERIODIC_PROC_FLAG_MASK | SPELL_PROC_FLAG_MASK | PROC_FLAG_DONE_TRAP_ACTIVATION)) { - if (procEntry.spellFamilyName && eventInfo.GetSpellInfo() && (procEntry.spellFamilyName != eventInfo.EnsureSpellInfo()->SpellFamilyName)) + SpellInfo const* eventSpellInfo = eventInfo.GetSpellInfo(); + + if (procEntry.spellFamilyName && eventSpellInfo && (procEntry.spellFamilyName != eventSpellInfo->SpellFamilyName)) return false; - if (procEntry.spellFamilyMask && eventInfo.GetSpellInfo() && !(procEntry.spellFamilyMask & eventInfo.EnsureSpellInfo()->SpellFamilyFlags)) + if (procEntry.spellFamilyMask && eventSpellInfo && !(procEntry.spellFamilyMask & eventSpellInfo->SpellFamilyFlags)) return false; } @@ -1157,7 +1159,7 @@ bool SpellArea::IsFitToRequirements(Player const* player, uint32 newZone, uint32 if (!player) return false; - AreaTableEntry const* pArea = GetAreaEntryByAreaID(player->GetAreaId()); + AreaTableEntry const* pArea = sAreaTableStore.LookupEntry(player->GetAreaId()); if (!(pArea && pArea->flags & AREA_FLAG_NO_FLY_ZONE)) return false; if (!player->HasAuraType(SPELL_AURA_MOD_INCREASE_MOUNTED_FLIGHT_SPEED) && !player->HasAuraType(SPELL_AURA_FLY)) @@ -2616,7 +2618,7 @@ void SpellMgr::LoadSpellAreas() } } - if (spellArea.areaId && !GetAreaEntryByAreaID(spellArea.areaId)) + if (spellArea.areaId && !sAreaTableStore.LookupEntry(spellArea.areaId)) { TC_LOG_ERROR("sql.sql", "Spell %u listed in `spell_area` have wrong area (%u) requirement", spell, spellArea.areaId); continue; @@ -2942,6 +2944,7 @@ void SpellMgr::LoadSpellInfoCorrections() case 53096: // Quetz'lun's Judgment case 70743: // AoD Special case 70614: // AoD Special - Vegard + case 4020: // Safirdrang's Chill spellInfo->MaxAffectedTargets = 1; break; case 42436: // Drink! (Brewfest) @@ -2984,13 +2987,6 @@ void SpellMgr::LoadSpellInfoCorrections() case 36350: // They Must Burn Bomb Aura (self) spellInfo->Effects[EFFECT_0].TriggerSpell = 36325; // They Must Burn Bomb Drop (DND) break; - case 49838: // Stop Time - case 69438: // Sample Satisfaction - case 69445: // Perfume Spritz - case 69489: // Chocolate Sample - case 69563: // Cologne Spritz - spellInfo->AttributesEx3 |= SPELL_ATTR3_NO_INITIAL_AGGRO; - break; case 61407: // Energize Cores case 62136: // Energize Cores case 54069: // Energize Cores @@ -3332,6 +3328,8 @@ void SpellMgr::LoadSpellInfoCorrections() spellInfo->Attributes |= SPELL_ATTR0_PASSIVE; break; case 17364: // Stormstrike + case 48278: // Paralyze + case 53651: // Light's Beacon spellInfo->AttributesEx3 |= SPELL_ATTR3_STACK_FOR_DIFF_CASTERS; break; case 51798: // Brewfest - Relay Race - Intro - Quest Complete @@ -3565,7 +3563,6 @@ void SpellMgr::LoadSpellInfoCorrections() spellInfo->AreaGroupId = 0; // originally, these require area 4522, which is... outside of Icecrown Citadel break; case 70602: // Corruption - case 48278: // Paralyze spellInfo->AttributesEx3 |= SPELL_ATTR3_STACK_FOR_DIFF_CASTERS; break; case 70715: // Column of Frost (visual marker) diff --git a/src/server/game/Spells/SpellMgr.h b/src/server/game/Spells/SpellMgr.h index ee732033ebd..651a8cde938 100644 --- a/src/server/game/Spells/SpellMgr.h +++ b/src/server/game/Spells/SpellMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Spells/SpellScript.cpp b/src/server/game/Spells/SpellScript.cpp index 95857be27dc..6876f8fa7ef 100644 --- a/src/server/game/Spells/SpellScript.cpp +++ b/src/server/game/Spells/SpellScript.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Spells/SpellScript.h b/src/server/game/Spells/SpellScript.h index 0916a43498a..77a993fffae 100644 --- a/src/server/game/Spells/SpellScript.h +++ b/src/server/game/Spells/SpellScript.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Texts/ChatTextBuilder.h b/src/server/game/Texts/ChatTextBuilder.h index c61b283500a..8ea5563fd1e 100644 --- a/src/server/game/Texts/ChatTextBuilder.h +++ b/src/server/game/Texts/ChatTextBuilder.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Texts/CreatureTextMgr.cpp b/src/server/game/Texts/CreatureTextMgr.cpp index 034fe96306e..499f0c9cbf0 100644 --- a/src/server/game/Texts/CreatureTextMgr.cpp +++ b/src/server/game/Texts/CreatureTextMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -191,7 +191,6 @@ void CreatureTextMgr::LoadCreatureTextLocales() } while (result->NextRow()); TC_LOG_INFO("server.loading", ">> Loaded %u creature localized texts in %u ms", textCount, GetMSTimeDiffToNow(oldMSTime)); - } uint32 CreatureTextMgr::SendChat(Creature* source, uint8 textGroup, WorldObject const* whisperTarget /*= nullptr*/, ChatMsg msgType /*= CHAT_MSG_ADDON*/, Language language /*= LANG_ADDON*/, CreatureTextRange range /*= TEXT_RANGE_NORMAL*/, uint32 sound /*= 0*/, Team team /*= TEAM_OTHER*/, bool gmOnly /*= false*/, Player* srcPlr /*= nullptr*/) @@ -228,42 +227,10 @@ uint32 CreatureTextMgr::SendChat(Creature* source, uint8 textGroup, WorldObject tempGroup = textGroupContainer; } - uint8 count = 0; - float lastChance = -1; - bool isEqualChanced = true; - - float totalChance = 0; - - for (CreatureTextGroup::const_iterator iter = tempGroup.begin(); iter != tempGroup.end(); ++iter) + auto iter = Trinity::Containers::SelectRandomWeightedContainerElement(tempGroup, [](CreatureTextEntry const& t) -> double { - if (lastChance >= 0 && lastChance != iter->probability) - isEqualChanced = false; - - lastChance = iter->probability; - totalChance += iter->probability; - ++count; - } - - int32 offset = -1; - if (!isEqualChanced) - { - for (CreatureTextGroup::const_iterator iter = tempGroup.begin(); iter != tempGroup.end(); ++iter) - { - uint32 chance = uint32(iter->probability); - uint32 r = urand(0, 100); - ++offset; - if (r <= chance) - break; - } - } - - uint32 pos = 0; - if (isEqualChanced || offset < 0) - pos = urand(0, count - 1); - else if (offset >= 0) - pos = offset; - - CreatureTextGroup::const_iterator iter = tempGroup.begin() + pos; + return t.probability; + }); ChatMsg finalType = (msgType == CHAT_MSG_ADDON) ? iter->type : msgType; Language finalLang = (language == LANG_ADDON) ? iter->lang : language; @@ -293,9 +260,7 @@ uint32 CreatureTextMgr::SendChat(Creature* source, uint8 textGroup, WorldObject SendChatPacket(finalSource, builder, finalType, whisperTarget, range, team, gmOnly); } - if (isEqualChanced || totalChance == 100.0f) - SetRepeatId(source, textGroup, iter->id); - + SetRepeatId(source, textGroup, iter->id); return iter->duration; } diff --git a/src/server/game/Texts/CreatureTextMgr.h b/src/server/game/Texts/CreatureTextMgr.h index 237aedd49d0..28fd98f21a8 100644 --- a/src/server/game/Texts/CreatureTextMgr.h +++ b/src/server/game/Texts/CreatureTextMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Tickets/TicketMgr.cpp b/src/server/game/Tickets/TicketMgr.cpp index b4b3b8267c6..1cf68eec9c7 100644 --- a/src/server/game/Tickets/TicketMgr.cpp +++ b/src/server/game/Tickets/TicketMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Tickets/TicketMgr.h b/src/server/game/Tickets/TicketMgr.h index a90a1ec0206..9cc1d20b122 100644 --- a/src/server/game/Tickets/TicketMgr.h +++ b/src/server/game/Tickets/TicketMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/game/Tools/CharacterDatabaseCleaner.cpp b/src/server/game/Tools/CharacterDatabaseCleaner.cpp index 815212aa53d..5c35e78278f 100644 --- a/src/server/game/Tools/CharacterDatabaseCleaner.cpp +++ b/src/server/game/Tools/CharacterDatabaseCleaner.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Tools/CharacterDatabaseCleaner.h b/src/server/game/Tools/CharacterDatabaseCleaner.h index f5be291c10b..ecbd6d0a790 100644 --- a/src/server/game/Tools/CharacterDatabaseCleaner.h +++ b/src/server/game/Tools/CharacterDatabaseCleaner.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2010 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Tools/PlayerDump.cpp b/src/server/game/Tools/PlayerDump.cpp index 0a47da1c788..113fea2ea35 100644 --- a/src/server/game/Tools/PlayerDump.cpp +++ b/src/server/game/Tools/PlayerDump.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Tools/PlayerDump.h b/src/server/game/Tools/PlayerDump.h index 5cdcc4b6bb8..95d6ed2d04b 100644 --- a/src/server/game/Tools/PlayerDump.h +++ b/src/server/game/Tools/PlayerDump.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Warden/Modules/WardenModuleMac.h b/src/server/game/Warden/Modules/WardenModuleMac.h index 145d61fd6f3..bbe93e17656 100644 --- a/src/server/game/Warden/Modules/WardenModuleMac.h +++ b/src/server/game/Warden/Modules/WardenModuleMac.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Warden/Modules/WardenModuleWin.h b/src/server/game/Warden/Modules/WardenModuleWin.h index 6b27fbfa7e1..26cae431179 100644 --- a/src/server/game/Warden/Modules/WardenModuleWin.h +++ b/src/server/game/Warden/Modules/WardenModuleWin.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Warden/Warden.cpp b/src/server/game/Warden/Warden.cpp index 69facc6895b..73d6a9ca5dd 100644 --- a/src/server/game/Warden/Warden.cpp +++ b/src/server/game/Warden/Warden.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Warden/Warden.h b/src/server/game/Warden/Warden.h index 695c6730b27..35ee18d4c02 100644 --- a/src/server/game/Warden/Warden.h +++ b/src/server/game/Warden/Warden.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Warden/WardenCheckMgr.cpp b/src/server/game/Warden/WardenCheckMgr.cpp index df9cd4786ad..5c4b0fc05b7 100644 --- a/src/server/game/Warden/WardenCheckMgr.cpp +++ b/src/server/game/Warden/WardenCheckMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Warden/WardenCheckMgr.h b/src/server/game/Warden/WardenCheckMgr.h index d01fc80a1f9..4107ccc3aff 100644 --- a/src/server/game/Warden/WardenCheckMgr.h +++ b/src/server/game/Warden/WardenCheckMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Warden/WardenMac.cpp b/src/server/game/Warden/WardenMac.cpp index 8abd48bd3f7..6df1dc7561c 100644 --- a/src/server/game/Warden/WardenMac.cpp +++ b/src/server/game/Warden/WardenMac.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Warden/WardenMac.h b/src/server/game/Warden/WardenMac.h index 83f98a9e6e1..26a2d86524e 100644 --- a/src/server/game/Warden/WardenMac.h +++ b/src/server/game/Warden/WardenMac.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Warden/WardenWin.cpp b/src/server/game/Warden/WardenWin.cpp index 2fe11a7eeed..cd008a7da08 100644 --- a/src/server/game/Warden/WardenWin.cpp +++ b/src/server/game/Warden/WardenWin.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Warden/WardenWin.h b/src/server/game/Warden/WardenWin.h index ab6ef7c8c65..4bf1af77c47 100644 --- a/src/server/game/Warden/WardenWin.h +++ b/src/server/game/Warden/WardenWin.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Weather/Weather.cpp b/src/server/game/Weather/Weather.cpp index 2a94cd26183..f774916f4a5 100644 --- a/src/server/game/Weather/Weather.cpp +++ b/src/server/game/Weather/Weather.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Weather/Weather.h b/src/server/game/Weather/Weather.h index a1adb6b8537..c1f029d6264 100644 --- a/src/server/game/Weather/Weather.h +++ b/src/server/game/Weather/Weather.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Weather/WeatherMgr.cpp b/src/server/game/Weather/WeatherMgr.cpp index ff55d2d9a27..25adb4d3615 100644 --- a/src/server/game/Weather/WeatherMgr.cpp +++ b/src/server/game/Weather/WeatherMgr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/Weather/WeatherMgr.h b/src/server/game/Weather/WeatherMgr.h index 61eddc0c60a..97c541fd3c0 100644 --- a/src/server/game/Weather/WeatherMgr.h +++ b/src/server/game/Weather/WeatherMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/game/World/World.cpp b/src/server/game/World/World.cpp index 2aa65324a3a..289a4d47666 100644 --- a/src/server/game/World/World.cpp +++ b/src/server/game/World/World.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -575,6 +575,13 @@ void World::LoadConfigSettings(bool reload) m_bool_configs[CONFIG_ADDON_CHANNEL] = sConfigMgr->GetBoolDefault("AddonChannel", true); m_bool_configs[CONFIG_CLEAN_CHARACTER_DB] = sConfigMgr->GetBoolDefault("CleanCharacterDB", false); m_int_configs[CONFIG_PERSISTENT_CHARACTER_CLEAN_FLAGS] = sConfigMgr->GetIntDefault("PersistentCharacterCleanFlags", 0); + m_int_configs[CONFIG_AUCTION_GETALL_DELAY] = sConfigMgr->GetIntDefault("Auction.GetAllScanDelay", 900); + m_int_configs[CONFIG_AUCTION_SEARCH_DELAY] = sConfigMgr->GetIntDefault("Auction.SearchDelay", 300); + if (m_int_configs[CONFIG_AUCTION_SEARCH_DELAY] < 100 || m_int_configs[CONFIG_AUCTION_SEARCH_DELAY] > 10000) + { + TC_LOG_ERROR("server.loading", "Auction.SearchDelay (%i) must be between 100 and 10000. Using default of 300ms", m_int_configs[CONFIG_AUCTION_SEARCH_DELAY]); + m_int_configs[CONFIG_AUCTION_SEARCH_DELAY] = 300; + } m_int_configs[CONFIG_CHAT_CHANNEL_LEVEL_REQ] = sConfigMgr->GetIntDefault("ChatLevelReq.Channel", 1); m_int_configs[CONFIG_CHAT_WHISPER_LEVEL_REQ] = sConfigMgr->GetIntDefault("ChatLevelReq.Whisper", 1); m_int_configs[CONFIG_CHAT_SAY_LEVEL_REQ] = sConfigMgr->GetIntDefault("ChatLevelReq.Say", 1); diff --git a/src/server/game/World/World.h b/src/server/game/World/World.h index 64ebafbd6e8..00b244c9efb 100644 --- a/src/server/game/World/World.h +++ b/src/server/game/World/World.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -356,6 +356,8 @@ enum WorldIntConfigs CONFIG_CHARTER_COST_ARENA_5v5, CONFIG_NO_GRAY_AGGRO_ABOVE, CONFIG_NO_GRAY_AGGRO_BELOW, + CONFIG_AUCTION_GETALL_DELAY, + CONFIG_AUCTION_SEARCH_DELAY, INT_CONFIG_VALUE_COUNT }; diff --git a/src/server/scripts/CMakeLists.txt b/src/server/scripts/CMakeLists.txt index 3668a2b0dac..a15b6f8ad07 100644 --- a/src/server/scripts/CMakeLists.txt +++ b/src/server/scripts/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without @@ -25,6 +25,7 @@ set(scripts_STAT_SRCS ../game/AI/ScriptedAI/ScriptedEscortAI.cpp ../game/AI/ScriptedAI/ScriptedCreature.cpp ../game/AI/ScriptedAI/ScriptedFollowerAI.cpp + ../game/Maps/AreaBoundary.cpp ) if(SCRIPTS) diff --git a/src/server/scripts/Commands/CMakeLists.txt b/src/server/scripts/Commands/CMakeLists.txt index 49d71129f90..d4d75cd175f 100644 --- a/src/server/scripts/Commands/CMakeLists.txt +++ b/src/server/scripts/Commands/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/scripts/Commands/cs_account.cpp b/src/server/scripts/Commands/cs_account.cpp index 8d9a40d9d1f..f25e91ee3e6 100644 --- a/src/server/scripts/Commands/cs_account.cpp +++ b/src/server/scripts/Commands/cs_account.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_achievement.cpp b/src/server/scripts/Commands/cs_achievement.cpp index ea77bc1f189..ef14ca66519 100644 --- a/src/server/scripts/Commands/cs_achievement.cpp +++ b/src/server/scripts/Commands/cs_achievement.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_ahbot.cpp b/src/server/scripts/Commands/cs_ahbot.cpp index 44889fccd37..65e90394261 100644 --- a/src/server/scripts/Commands/cs_ahbot.cpp +++ b/src/server/scripts/Commands/cs_ahbot.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_arena.cpp b/src/server/scripts/Commands/cs_arena.cpp index 71657d51e7b..07bbe6cfa5b 100644 --- a/src/server/scripts/Commands/cs_arena.cpp +++ b/src/server/scripts/Commands/cs_arena.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_ban.cpp b/src/server/scripts/Commands/cs_ban.cpp index 67015cd7d9c..4a1bf71e1d8 100644 --- a/src/server/scripts/Commands/cs_ban.cpp +++ b/src/server/scripts/Commands/cs_ban.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_bf.cpp b/src/server/scripts/Commands/cs_bf.cpp index 7101b89b5fa..8b0af7bddb4 100644 --- a/src/server/scripts/Commands/cs_bf.cpp +++ b/src/server/scripts/Commands/cs_bf.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_cast.cpp b/src/server/scripts/Commands/cs_cast.cpp index 5252d5e368a..44c606a360f 100644 --- a/src/server/scripts/Commands/cs_cast.cpp +++ b/src/server/scripts/Commands/cs_cast.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_character.cpp b/src/server/scripts/Commands/cs_character.cpp index 65dd44f8563..e048aabd4d7 100644 --- a/src/server/scripts/Commands/cs_character.cpp +++ b/src/server/scripts/Commands/cs_character.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_cheat.cpp b/src/server/scripts/Commands/cs_cheat.cpp index 2dc2c17bdc2..0adff61c9ec 100644 --- a/src/server/scripts/Commands/cs_cheat.cpp +++ b/src/server/scripts/Commands/cs_cheat.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_debug.cpp b/src/server/scripts/Commands/cs_debug.cpp index 7f517d09e90..b937fc4e0a4 100644 --- a/src/server/scripts/Commands/cs_debug.cpp +++ b/src/server/scripts/Commands/cs_debug.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -93,6 +93,8 @@ public: { "moveflags", rbac::RBAC_PERM_COMMAND_DEBUG_MOVEFLAGS, false, &HandleDebugMoveflagsCommand, "" }, { "transport", rbac::RBAC_PERM_COMMAND_DEBUG_TRANSPORT, false, &HandleDebugTransportCommand, "" }, { "loadcells", rbac::RBAC_PERM_COMMAND_DEBUG_LOADCELLS, false, &HandleDebugLoadCellsCommand, "" }, + { "boundary", rbac::RBAC_PERM_COMMAND_DEBUG_BOUNDARY, false, &HandleDebugBoundaryCommand, "" }, + { "raidreset", rbac::RBAC_PERM_COMMAND_INSTANCE_UNBIND, false, &HandleDebugRaidResetCommand, "" } }; static std::vector<ChatCommand> commandTable = { @@ -1414,6 +1416,59 @@ public: handler->PSendSysMessage("Cells loaded (mapId: %u) After load - Next GameObject %u, Creature %u", map->GetId(), map->GetMaxLowGuid<HighGuid::GameObject>(), map->GetMaxLowGuid<HighGuid::Unit>()); return true; } + + static bool HandleDebugBoundaryCommand(ChatHandler* handler, char const* args) + { + Player* player = handler->GetSession()->GetPlayer(); + if (!player) + return false; + Creature* target = handler->getSelectedCreature(); + if (!target || !target->IsAIEnabled || !target->AI()) + { + return false; + } + + char* fill_str = args ? strtok((char*)args, " ") : nullptr; + char* duration_str = args ? strtok(nullptr, " ") : nullptr; + + int duration = duration_str ? atoi(duration_str) : -1; + if (duration <= 0 || duration >= 30 * MINUTE) // arbitary upper limit + duration = 3 * MINUTE; + + bool doFill = fill_str ? (stricmp(fill_str, "FILL") == 0) : false; + + int32 errMsg = target->AI()->VisualizeBoundary(duration, player, doFill); + if (errMsg > 0) + handler->PSendSysMessage(errMsg); + + return true; + } + + static bool HandleDebugRaidResetCommand(ChatHandler* /*handler*/, char const* args) + { + char* map_str = args ? strtok((char*)args, " ") : nullptr; + char* difficulty_str = args ? strtok(nullptr, " ") : nullptr; + + int32 map = map_str ? atoi(map_str) : -1; + if (map <= 0) + return false; + MapEntry const* mEntry = sMapStore.LookupEntry(map); + if (!mEntry || !mEntry->IsRaid()) + return false; + int32 difficulty = difficulty_str ? atoi(difficulty_str) : -1; + if (difficulty >= MAX_RAID_DIFFICULTY || difficulty < -1) + return false; + + if (difficulty == -1) + for (uint8 diff = 0; diff < MAX_RAID_DIFFICULTY; ++diff) + { + if (GetMapDifficultyData(mEntry->MapID, Difficulty(diff))) + sInstanceSaveMgr->ForceGlobalReset(mEntry->MapID, Difficulty(diff)); + } + else + sInstanceSaveMgr->ForceGlobalReset(mEntry->MapID, Difficulty(difficulty)); + return true; + } }; void AddSC_debug_commandscript() diff --git a/src/server/scripts/Commands/cs_deserter.cpp b/src/server/scripts/Commands/cs_deserter.cpp index 9f461207707..56102c99c56 100644 --- a/src/server/scripts/Commands/cs_deserter.cpp +++ b/src/server/scripts/Commands/cs_deserter.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_disable.cpp b/src/server/scripts/Commands/cs_disable.cpp index 8c73f3f41de..54932228372 100644 --- a/src/server/scripts/Commands/cs_disable.cpp +++ b/src/server/scripts/Commands/cs_disable.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_event.cpp b/src/server/scripts/Commands/cs_event.cpp index 352bce4e7f0..c3fca441eb4 100644 --- a/src/server/scripts/Commands/cs_event.cpp +++ b/src/server/scripts/Commands/cs_event.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_gm.cpp b/src/server/scripts/Commands/cs_gm.cpp index 81b70603680..e03942bc247 100644 --- a/src/server/scripts/Commands/cs_gm.cpp +++ b/src/server/scripts/Commands/cs_gm.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_go.cpp b/src/server/scripts/Commands/cs_go.cpp index a810106269e..039af61c010 100644 --- a/src/server/scripts/Commands/cs_go.cpp +++ b/src/server/scripts/Commands/cs_go.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -424,7 +424,7 @@ public: uint32 areaId = id ? (uint32)atoi(id) : player->GetZoneId(); - AreaTableEntry const* areaEntry = GetAreaEntryByAreaID(areaId); + AreaTableEntry const* areaEntry = sAreaTableStore.LookupEntry(areaId); if (x < 0 || x > 100 || y < 0 || y > 100 || !areaEntry) { @@ -434,7 +434,7 @@ public: } // update to parent zone if exist (client map show only zones without parents) - AreaTableEntry const* zoneEntry = areaEntry->zone ? GetAreaEntryByAreaID(areaEntry->zone) : areaEntry; + AreaTableEntry const* zoneEntry = areaEntry->zone ? sAreaTableStore.LookupEntry(areaEntry->zone) : areaEntry; ASSERT(zoneEntry); Map const* map = sMapMgr->CreateBaseMap(zoneEntry->mapid); diff --git a/src/server/scripts/Commands/cs_gobject.cpp b/src/server/scripts/Commands/cs_gobject.cpp index fda9101fc3f..729dac0ad6f 100644 --- a/src/server/scripts/Commands/cs_gobject.cpp +++ b/src/server/scripts/Commands/cs_gobject.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_group.cpp b/src/server/scripts/Commands/cs_group.cpp index 054cff996f9..9f2bc86f9c0 100644 --- a/src/server/scripts/Commands/cs_group.cpp +++ b/src/server/scripts/Commands/cs_group.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -348,10 +348,10 @@ public: phase = (!p->IsGameMaster() ? p->GetPhaseMask() : -1); uint32 locale = handler->GetSessionDbcLocale(); - AreaTableEntry const* area = GetAreaEntryByAreaID(p->GetAreaId()); + AreaTableEntry const* area = sAreaTableStore.LookupEntry(p->GetAreaId()); if (area) { - AreaTableEntry const* zone = GetAreaEntryByAreaID(area->zone); + AreaTableEntry const* zone = sAreaTableStore.LookupEntry(area->zone); if (zone) zoneName = zone->area_name[locale]; } diff --git a/src/server/scripts/Commands/cs_guild.cpp b/src/server/scripts/Commands/cs_guild.cpp index 04b633f6f40..98fc852b573 100644 --- a/src/server/scripts/Commands/cs_guild.cpp +++ b/src/server/scripts/Commands/cs_guild.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_honor.cpp b/src/server/scripts/Commands/cs_honor.cpp index e8b41309d47..da285ee4e30 100644 --- a/src/server/scripts/Commands/cs_honor.cpp +++ b/src/server/scripts/Commands/cs_honor.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_instance.cpp b/src/server/scripts/Commands/cs_instance.cpp index 5651aaa12ee..d0325a317db 100644 --- a/src/server/scripts/Commands/cs_instance.cpp +++ b/src/server/scripts/Commands/cs_instance.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -82,7 +82,7 @@ public: { InstanceSave* save = itr->second.save; std::string timeleft = GetTimeString(save->GetResetTime() - time(NULL)); - handler->PSendSysMessage(LANG_COMMAND_LIST_BIND_INFO, itr->first, save->GetInstanceId(), itr->second.perm ? "yes" : "no", save->GetDifficulty(), save->CanReset() ? "yes" : "no", timeleft.c_str()); + handler->PSendSysMessage(LANG_COMMAND_LIST_BIND_INFO, itr->first, save->GetInstanceId(), itr->second.perm ? "yes" : "no", itr->second.extendState == EXTEND_STATE_EXPIRED ? "expired" : itr->second.extendState == EXTEND_STATE_EXTENDED ? "yes" : "no", save->GetDifficulty(), save->CanReset() ? "yes" : "no", timeleft.c_str()); counter++; } } @@ -98,7 +98,7 @@ public: { InstanceSave* save = itr->second.save; std::string timeleft = GetTimeString(save->GetResetTime() - time(NULL)); - handler->PSendSysMessage(LANG_COMMAND_LIST_BIND_INFO, itr->first, save->GetInstanceId(), itr->second.perm ? "yes" : "no", save->GetDifficulty(), save->CanReset() ? "yes" : "no", timeleft.c_str()); + handler->PSendSysMessage(LANG_COMMAND_LIST_BIND_INFO, itr->first, save->GetInstanceId(), itr->second.perm ? "yes" : "no", "-", save->GetDifficulty(), save->CanReset() ? "yes" : "no", timeleft.c_str()); counter++; } } diff --git a/src/server/scripts/Commands/cs_learn.cpp b/src/server/scripts/Commands/cs_learn.cpp index d7fd4e6664c..9b553ca4791 100644 --- a/src/server/scripts/Commands/cs_learn.cpp +++ b/src/server/scripts/Commands/cs_learn.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -72,7 +72,7 @@ public: static bool HandleLearnCommand(ChatHandler* handler, char const* args) { - Player* targetPlayer = handler->getSelectedPlayer(); + Player* targetPlayer = handler->getSelectedPlayerOrSelf(); if (!targetPlayer) { diff --git a/src/server/scripts/Commands/cs_lfg.cpp b/src/server/scripts/Commands/cs_lfg.cpp index 9287d5553e3..8c06377bbfb 100644 --- a/src/server/scripts/Commands/cs_lfg.cpp +++ b/src/server/scripts/Commands/cs_lfg.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_list.cpp b/src/server/scripts/Commands/cs_list.cpp index a1b79a69605..abb8af24435 100644 --- a/src/server/scripts/Commands/cs_list.cpp +++ b/src/server/scripts/Commands/cs_list.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_lookup.cpp b/src/server/scripts/Commands/cs_lookup.cpp index ec35c5a7b62..61e6acfb4d8 100644 --- a/src/server/scripts/Commands/cs_lookup.cpp +++ b/src/server/scripts/Commands/cs_lookup.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -97,9 +97,9 @@ public: wstrToLower(wNamePart); // Search in AreaTable.dbc - for (uint32 areaflag = 0; areaflag < sAreaStore.GetNumRows(); ++areaflag) + for (uint32 i = 0; i < sAreaTableStore.GetNumRows(); ++i) { - AreaTableEntry const* areaEntry = sAreaStore.LookupEntry(areaflag); + AreaTableEntry const* areaEntry = sAreaTableStore.LookupEntry(i); if (areaEntry) { int locale = handler->GetSessionDbcLocale(); diff --git a/src/server/scripts/Commands/cs_message.cpp b/src/server/scripts/Commands/cs_message.cpp index f3c1f4d7df8..69ff04ffb46 100644 --- a/src/server/scripts/Commands/cs_message.cpp +++ b/src/server/scripts/Commands/cs_message.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_misc.cpp b/src/server/scripts/Commands/cs_misc.cpp index b81d6152c03..c70246f7fb5 100644 --- a/src/server/scripts/Commands/cs_misc.cpp +++ b/src/server/scripts/Commands/cs_misc.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -198,8 +198,8 @@ public: uint32 mapId = object->GetMapId(); MapEntry const* mapEntry = sMapStore.LookupEntry(mapId); - AreaTableEntry const* zoneEntry = GetAreaEntryByAreaID(zoneId); - AreaTableEntry const* areaEntry = GetAreaEntryByAreaID(areaId); + AreaTableEntry const* zoneEntry = sAreaTableStore.LookupEntry(zoneId); + AreaTableEntry const* areaEntry = sAreaTableStore.LookupEntry(areaId); float zoneX = object->GetPositionX(); float zoneY = object->GetPositionY(); @@ -961,7 +961,7 @@ public: uint32 zoneId = player->GetZoneId(); - AreaTableEntry const* areaEntry = GetAreaEntryByAreaID(zoneId); + AreaTableEntry const* areaEntry = sAreaTableStore.LookupEntry(zoneId); if (!areaEntry || areaEntry->zone !=0) { handler->PSendSysMessage(LANG_COMMAND_GRAVEYARDWRONGZONE, graveyardId, zoneId); @@ -1052,17 +1052,23 @@ public: return false; } - int32 area = GetAreaFlagByAreaID(atoi((char*)args)); - int32 offset = area / 32; + AreaTableEntry const* area = sAreaTableStore.LookupEntry(atoi(args)); + if (!area) + { + handler->SendSysMessage(LANG_BAD_VALUE); + handler->SetSentErrorMessage(true); + return false; + } - if (area<0 || offset >= PLAYER_EXPLORED_ZONES_SIZE) + int32 offset = area->exploreFlag / 32; + if (offset >= PLAYER_EXPLORED_ZONES_SIZE) { handler->SendSysMessage(LANG_BAD_VALUE); handler->SetSentErrorMessage(true); return false; } - uint32 val = uint32((1 << (area % 32))); + uint32 val = uint32((1 << (area->exploreFlag % 32))); uint32 currFields = playerTarget->GetUInt32Value(PLAYER_EXPLORED_ZONES_1 + offset); playerTarget->SetUInt32Value(PLAYER_EXPLORED_ZONES_1 + offset, uint32((currFields | val))); @@ -1083,17 +1089,23 @@ public: return false; } - int32 area = GetAreaFlagByAreaID(atoi((char*)args)); - int32 offset = area / 32; + AreaTableEntry const* area = sAreaTableStore.LookupEntry(atoi(args)); + if (!area) + { + handler->SendSysMessage(LANG_BAD_VALUE); + handler->SetSentErrorMessage(true); + return false; + } - if (area < 0 || offset >= PLAYER_EXPLORED_ZONES_SIZE) + int32 offset = area->exploreFlag / 32; + if (offset >= PLAYER_EXPLORED_ZONES_SIZE) { handler->SendSysMessage(LANG_BAD_VALUE); handler->SetSentErrorMessage(true); return false; } - uint32 val = uint32((1 << (area % 32))); + uint32 val = uint32((1 << (area->exploreFlag % 32))); uint32 currFields = playerTarget->GetUInt32Value(PLAYER_EXPLORED_ZONES_1 + offset); playerTarget->SetUInt32Value(PLAYER_EXPLORED_ZONES_1 + offset, uint32((currFields ^ val))); @@ -1362,7 +1374,7 @@ public: int32 level = atol(levelStr); - Player* target = handler->getSelectedPlayer(); + Player* target = handler->getSelectedPlayerOrSelf(); if (!target) { handler->SendSysMessage(LANG_NO_CHAR_SELECTED); @@ -1737,12 +1749,12 @@ public: // Position data MapEntry const* map = sMapStore.LookupEntry(mapId); - AreaTableEntry const* area = GetAreaEntryByAreaID(areaId); + AreaTableEntry const* area = sAreaTableStore.LookupEntry(areaId); if (area) { areaName = area->area_name[locale]; - AreaTableEntry const* zone = GetAreaEntryByAreaID(area->zone); + AreaTableEntry const* zone = sAreaTableStore.LookupEntry(area->zone); if (zone) zoneName = zone->area_name[locale]; } diff --git a/src/server/scripts/Commands/cs_mmaps.cpp b/src/server/scripts/Commands/cs_mmaps.cpp index 479c34dd90c..83f89b92182 100644 --- a/src/server/scripts/Commands/cs_mmaps.cpp +++ b/src/server/scripts/Commands/cs_mmaps.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_modify.cpp b/src/server/scripts/Commands/cs_modify.cpp index a3eed4dfd5d..761b4c9e0e6 100644 --- a/src/server/scripts/Commands/cs_modify.cpp +++ b/src/server/scripts/Commands/cs_modify.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_npc.cpp b/src/server/scripts/Commands/cs_npc.cpp index 99c10b074a0..fbd199b99db 100644 --- a/src/server/scripts/Commands/cs_npc.cpp +++ b/src/server/scripts/Commands/cs_npc.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -43,7 +43,7 @@ struct EnumName #define CREATE_NAMED_ENUM(VALUE) { VALUE, STRINGIZE(VALUE) } #define NPCFLAG_COUNT 24 -#define FLAGS_EXTRA_COUNT 16 +#define FLAGS_EXTRA_COUNT 19 EnumName<NPCFlags, int32> const npcFlagTexts[NPCFLAG_COUNT] = { @@ -162,7 +162,10 @@ EnumName<CreatureFlagsExtra> const flagsExtra[FLAGS_EXTRA_COUNT] = CREATE_NAMED_ENUM(CREATURE_FLAG_EXTRA_NO_SKILLGAIN), CREATE_NAMED_ENUM(CREATURE_FLAG_EXTRA_TAUNT_DIMINISH), CREATE_NAMED_ENUM(CREATURE_FLAG_EXTRA_ALL_DIMINISH), - CREATE_NAMED_ENUM(CREATURE_FLAG_EXTRA_DUNGEON_BOSS) + CREATE_NAMED_ENUM(CREATURE_FLAG_EXTRA_NO_PLAYER_DAMAGE_REQ), + CREATE_NAMED_ENUM(CREATURE_FLAG_EXTRA_DUNGEON_BOSS), + CREATE_NAMED_ENUM(CREATURE_FLAG_EXTRA_IGNORE_PATHFINDING), + CREATE_NAMED_ENUM(CREATURE_FLAG_EXTRA_IMMUNITY_KNOCKBACK) }; class npc_commandscript : public CommandScript diff --git a/src/server/scripts/Commands/cs_pet.cpp b/src/server/scripts/Commands/cs_pet.cpp index e3046817821..4f0a179142d 100644 --- a/src/server/scripts/Commands/cs_pet.cpp +++ b/src/server/scripts/Commands/cs_pet.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_quest.cpp b/src/server/scripts/Commands/cs_quest.cpp index 442950bca96..be53304b8f8 100644 --- a/src/server/scripts/Commands/cs_quest.cpp +++ b/src/server/scripts/Commands/cs_quest.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_rbac.cpp b/src/server/scripts/Commands/cs_rbac.cpp index c28aa04175f..f7c2d21c12d 100644 --- a/src/server/scripts/Commands/cs_rbac.cpp +++ b/src/server/scripts/Commands/cs_rbac.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_reload.cpp b/src/server/scripts/Commands/cs_reload.cpp index 44e34b8e2a9..56b0dbf43d0 100644 --- a/src/server/scripts/Commands/cs_reload.cpp +++ b/src/server/scripts/Commands/cs_reload.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_reset.cpp b/src/server/scripts/Commands/cs_reset.cpp index d1c7421b761..05941120423 100644 --- a/src/server/scripts/Commands/cs_reset.cpp +++ b/src/server/scripts/Commands/cs_reset.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_send.cpp b/src/server/scripts/Commands/cs_send.cpp index b7165ed339c..672db3a3ab0 100644 --- a/src/server/scripts/Commands/cs_send.cpp +++ b/src/server/scripts/Commands/cs_send.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_server.cpp b/src/server/scripts/Commands/cs_server.cpp index e41a7d161d2..83bc2e47674 100644 --- a/src/server/scripts/Commands/cs_server.cpp +++ b/src/server/scripts/Commands/cs_server.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_tele.cpp b/src/server/scripts/Commands/cs_tele.cpp index 9ea516f0972..15dbde894fc 100644 --- a/src/server/scripts/Commands/cs_tele.cpp +++ b/src/server/scripts/Commands/cs_tele.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_ticket.cpp b/src/server/scripts/Commands/cs_ticket.cpp index a9baa45f344..c5c85f5f3cc 100644 --- a/src/server/scripts/Commands/cs_ticket.cpp +++ b/src/server/scripts/Commands/cs_ticket.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_titles.cpp b/src/server/scripts/Commands/cs_titles.cpp index bc6027ce3c3..2f5d7b8364c 100644 --- a/src/server/scripts/Commands/cs_titles.cpp +++ b/src/server/scripts/Commands/cs_titles.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Commands/cs_wp.cpp b/src/server/scripts/Commands/cs_wp.cpp index 30ee8254f72..ef61c231104 100644 --- a/src/server/scripts/Commands/cs_wp.cpp +++ b/src/server/scripts/Commands/cs_wp.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Custom/CMakeLists.txt b/src/server/scripts/Custom/CMakeLists.txt index 5218f76ee66..595ff801813 100644 --- a/src/server/scripts/Custom/CMakeLists.txt +++ b/src/server/scripts/Custom/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/scripts/EasternKingdoms/AlteracValley/alterac_valley.cpp b/src/server/scripts/EasternKingdoms/AlteracValley/alterac_valley.cpp index 451384d18d9..5864e6beb7e 100644 --- a/src/server/scripts/EasternKingdoms/AlteracValley/alterac_valley.cpp +++ b/src/server/scripts/EasternKingdoms/AlteracValley/alterac_valley.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/AlteracValley/boss_balinda.cpp b/src/server/scripts/EasternKingdoms/AlteracValley/boss_balinda.cpp index 09c0a465c17..eb9b6587b6e 100644 --- a/src/server/scripts/EasternKingdoms/AlteracValley/boss_balinda.cpp +++ b/src/server/scripts/EasternKingdoms/AlteracValley/boss_balinda.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/AlteracValley/boss_drekthar.cpp b/src/server/scripts/EasternKingdoms/AlteracValley/boss_drekthar.cpp index 59d5250bf1d..d5ed2421efc 100644 --- a/src/server/scripts/EasternKingdoms/AlteracValley/boss_drekthar.cpp +++ b/src/server/scripts/EasternKingdoms/AlteracValley/boss_drekthar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -77,7 +77,7 @@ public: Talk(SAY_RESPAWN); } - bool CheckInRoom() + bool CheckInRoom() override { if (me->GetDistance2d(me->GetHomePosition().GetPositionX(), me->GetHomePosition().GetPositionY()) > 50) { diff --git a/src/server/scripts/EasternKingdoms/AlteracValley/boss_galvangar.cpp b/src/server/scripts/EasternKingdoms/AlteracValley/boss_galvangar.cpp index 3b038a12b54..238942c15f6 100644 --- a/src/server/scripts/EasternKingdoms/AlteracValley/boss_galvangar.cpp +++ b/src/server/scripts/EasternKingdoms/AlteracValley/boss_galvangar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -78,7 +78,7 @@ public: Talk(SAY_BUFF); } - bool CheckInRoom() + bool CheckInRoom() override { if (me->GetDistance2d(me->GetHomePosition().GetPositionX(), me->GetHomePosition().GetPositionY()) > 50) { diff --git a/src/server/scripts/EasternKingdoms/AlteracValley/boss_vanndar.cpp b/src/server/scripts/EasternKingdoms/AlteracValley/boss_vanndar.cpp index 99d6b7c1c73..16f2c004f6f 100644 --- a/src/server/scripts/EasternKingdoms/AlteracValley/boss_vanndar.cpp +++ b/src/server/scripts/EasternKingdoms/AlteracValley/boss_vanndar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.cpp index 9c9dfe38349..9cd724e5596 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.h b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.h index 3deb2b153ec..0cb25d3a2a3 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.h +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/blackrock_depths.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_ambassador_flamelash.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_ambassador_flamelash.cpp index 53d490c4b64..ff949ee6d00 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_ambassador_flamelash.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_ambassador_flamelash.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_emperor_dagran_thaurissan.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_emperor_dagran_thaurissan.cpp index ca9c6b27ef7..964c15673ad 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_emperor_dagran_thaurissan.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_emperor_dagran_thaurissan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_general_angerforge.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_general_angerforge.cpp index 114be945bde..166ccbc6dc5 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_general_angerforge.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_general_angerforge.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_high_interrogator_gerstahn.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_high_interrogator_gerstahn.cpp index 99f46b4225c..16f2cec2076 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_high_interrogator_gerstahn.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_high_interrogator_gerstahn.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_magmus.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_magmus.cpp index 2d70aacf2ea..c154c0bd5f5 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_magmus.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_magmus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_moira_bronzebeard.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_moira_bronzebeard.cpp index 35f3a6d9835..ced7cc203f2 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_moira_bronzebeard.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_moira_bronzebeard.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_tomb_of_seven.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_tomb_of_seven.cpp index a9109c73d94..5e1aad82fa5 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_tomb_of_seven.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/boss_tomb_of_seven.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -198,9 +198,9 @@ class boss_doomrel : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); _instance->SetGuidData(DATA_EVENSTARTER, ObjectGuid::Empty); } diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/instance_blackrock_depths.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/instance_blackrock_depths.cpp index b46dbb13f77..fa646d1d4ee 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/instance_blackrock_depths.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockDepths/instance_blackrock_depths.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/blackrock_spire.h b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/blackrock_spire.h index a2efad28fd3..446cc48d2f7 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/blackrock_spire.h +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/blackrock_spire.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_drakkisath.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_drakkisath.cpp index bfa4298db30..8031c2ffda2 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_drakkisath.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_drakkisath.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gizrul_the_slavener.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gizrul_the_slavener.cpp index ea4e4a77faa..45093ed1012 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gizrul_the_slavener.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gizrul_the_slavener.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gyth.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gyth.cpp index d8e6b838d81..244bd6e37e5 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gyth.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_gyth.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_halycon.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_halycon.cpp index 2199a2d4642..66369b28b76 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_halycon.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_halycon.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_highlord_omokk.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_highlord_omokk.cpp index c11914f006e..bcf6911bf59 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_highlord_omokk.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_highlord_omokk.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_lord_valthalak.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_lord_valthalak.cpp index 7e51c96805f..b2a3ac13423 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_lord_valthalak.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_lord_valthalak.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_mother_smolderweb.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_mother_smolderweb.cpp index 86c13ef10dc..71837ef12f1 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_mother_smolderweb.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_mother_smolderweb.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_overlord_wyrmthalak.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_overlord_wyrmthalak.cpp index 7d64310fb7f..8d06a98dd35 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_overlord_wyrmthalak.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_overlord_wyrmthalak.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_pyroguard_emberseer.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_pyroguard_emberseer.cpp index e3c2b7a67ec..33f1039424e 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_pyroguard_emberseer.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_pyroguard_emberseer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_quartermaster_zigris.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_quartermaster_zigris.cpp index 215e8125a41..7b70e383866 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_quartermaster_zigris.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_quartermaster_zigris.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_rend_blackhand.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_rend_blackhand.cpp index d5265def9e1..817aaf0a253 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_rend_blackhand.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_rend_blackhand.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_shadow_hunter_voshgajin.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_shadow_hunter_voshgajin.cpp index c3788b31b0b..ace95b99146 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_shadow_hunter_voshgajin.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_shadow_hunter_voshgajin.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_the_beast.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_the_beast.cpp index 439c5053cff..7e131a88d36 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_the_beast.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_the_beast.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_urok_doomhowl.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_urok_doomhowl.cpp index 20a3f34ea28..a38ff824b6c 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_urok_doomhowl.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_urok_doomhowl.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_warmaster_voone.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_warmaster_voone.cpp index 1ebee9a9327..1280caaa99b 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_warmaster_voone.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/boss_warmaster_voone.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/instance_blackrock_spire.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/instance_blackrock_spire.cpp index 635333a5886..bbe8fda37eb 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/instance_blackrock_spire.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackrockSpire/instance_blackrock_spire.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/blackwing_lair.h b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/blackwing_lair.h index 12798833a3f..9fce132ea7e 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/blackwing_lair.h +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/blackwing_lair.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -59,7 +59,7 @@ enum CreatureIds enum GameObjectIds { GO_BLACK_DRAGON_EGG = 177807, - GO_BOSSGATE01 = 175946, + GO_PORTCULLIS = 176965, GO_DRAKE_RIDER_PORTCULLIS = 175185, GO_ALTERAC_VALLEY_GATE = 180424, GO_GATE = 185483, diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_broodlord_lashlayer.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_broodlord_lashlayer.cpp index 5ba933005ec..27b3ec22322 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_broodlord_lashlayer.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_broodlord_lashlayer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_chromaggus.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_chromaggus.cpp index 9a49b96e68e..ced6ad19d19 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_chromaggus.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_chromaggus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_ebonroc.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_ebonroc.cpp index 7a7e30f7913..1e318ed9227 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_ebonroc.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_ebonroc.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_firemaw.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_firemaw.cpp index 3dcdbfe01df..28d6dd62256 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_firemaw.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_firemaw.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_flamegor.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_flamegor.cpp index 20e69211da2..d6982e98f44 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_flamegor.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_flamegor.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_nefarian.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_nefarian.cpp index a89571e8197..4a6fee12098 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_nefarian.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_nefarian.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_razorgore.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_razorgore.cpp index 1d66964ce6b..e58bded801b 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_razorgore.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_razorgore.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_vaelastrasz.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_vaelastrasz.cpp index 76ab4736275..9088e059ef3 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_vaelastrasz.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/boss_vaelastrasz.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp index 97646b774eb..a4241b16f8d 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/BlackwingLair/instance_blackwing_lair.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -22,14 +22,14 @@ DoorData const doorData[] = { - { GO_BOSSGATE01, DATA_RAZORGORE_THE_UNTAMED, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_DRAKE_RIDER_PORTCULLIS, DATA_VAELASTRAZ_THE_CORRUPT, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_ALTERAC_VALLEY_GATE, DATA_BROODLORD_LASHLAYER, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_GATE, DATA_FIREMAW, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_GATE, DATA_EBONROC, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_GATE, DATA_FLAMEGOR, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_VACCUUM_EXIT_GATE, DATA_CHROMAGGUS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_PORTCULLIS, DATA_RAZORGORE_THE_UNTAMED, DOOR_TYPE_PASSAGE }, + { GO_DRAKE_RIDER_PORTCULLIS, DATA_VAELASTRAZ_THE_CORRUPT, DOOR_TYPE_PASSAGE }, + { GO_ALTERAC_VALLEY_GATE, DATA_BROODLORD_LASHLAYER, DOOR_TYPE_PASSAGE }, + { GO_GATE, DATA_FIREMAW, DOOR_TYPE_PASSAGE }, + { GO_GATE, DATA_EBONROC, DOOR_TYPE_PASSAGE }, + { GO_GATE, DATA_FLAMEGOR, DOOR_TYPE_PASSAGE }, + { GO_VACCUUM_EXIT_GATE, DATA_CHROMAGGUS, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; ObjectData const creatureData[] = diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_baron_geddon.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_baron_geddon.cpp index 6a3c85f1f98..51bb314968d 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_baron_geddon.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_baron_geddon.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_garr.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_garr.cpp index 77e9b9962f9..96f92ac103b 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_garr.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_garr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_gehennas.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_gehennas.cpp index 5b5456f1b40..886ccaf8362 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_gehennas.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_gehennas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_golemagg.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_golemagg.cpp index 04532b54543..7dc4922790e 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_golemagg.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_golemagg.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_lucifron.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_lucifron.cpp index 779418a7f73..0c4e28d1742 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_lucifron.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_lucifron.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_magmadar.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_magmadar.cpp index 532ef043d68..4d1ad7e61dc 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_magmadar.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_magmadar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_majordomo_executus.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_majordomo_executus.cpp index 3c2836e1597..9b487f7b5f9 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_majordomo_executus.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_majordomo_executus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_ragnaros.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_ragnaros.cpp index e2202a7e526..e0cae87051f 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_ragnaros.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_ragnaros.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_shazzrah.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_shazzrah.cpp index 77927b339cb..99ec1a2dc6c 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_shazzrah.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_shazzrah.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_sulfuron_harbinger.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_sulfuron_harbinger.cpp index d066fe980f9..cea783cedc9 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_sulfuron_harbinger.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/boss_sulfuron_harbinger.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/instance_molten_core.cpp b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/instance_molten_core.cpp index 135065e5865..98112519714 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/instance_molten_core.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/instance_molten_core.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/molten_core.h b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/molten_core.h index e4756bc7a81..de890ee3b39 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/molten_core.h +++ b/src/server/scripts/EasternKingdoms/BlackrockMountain/MoltenCore/molten_core.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/CMakeLists.txt b/src/server/scripts/EasternKingdoms/CMakeLists.txt index 76e4d36e0a9..8e6616347f9 100644 --- a/src/server/scripts/EasternKingdoms/CMakeLists.txt +++ b/src/server/scripts/EasternKingdoms/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/scripts/EasternKingdoms/Deadmines/boss_mr_smite.cpp b/src/server/scripts/EasternKingdoms/Deadmines/boss_mr_smite.cpp index 6ce417d72b9..8f246ab9bf0 100644 --- a/src/server/scripts/EasternKingdoms/Deadmines/boss_mr_smite.cpp +++ b/src/server/scripts/EasternKingdoms/Deadmines/boss_mr_smite.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Deadmines/deadmines.cpp b/src/server/scripts/EasternKingdoms/Deadmines/deadmines.cpp index c9020e46aef..45eb7d08adc 100644 --- a/src/server/scripts/EasternKingdoms/Deadmines/deadmines.cpp +++ b/src/server/scripts/EasternKingdoms/Deadmines/deadmines.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Deadmines/deadmines.h b/src/server/scripts/EasternKingdoms/Deadmines/deadmines.h index b73b6de4e54..01ebabb160e 100644 --- a/src/server/scripts/EasternKingdoms/Deadmines/deadmines.h +++ b/src/server/scripts/EasternKingdoms/Deadmines/deadmines.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Deadmines/instance_deadmines.cpp b/src/server/scripts/EasternKingdoms/Deadmines/instance_deadmines.cpp index 471c144581d..b827fdf7e8b 100644 --- a/src/server/scripts/EasternKingdoms/Deadmines/instance_deadmines.cpp +++ b/src/server/scripts/EasternKingdoms/Deadmines/instance_deadmines.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -57,6 +57,8 @@ class instance_deadmines : public InstanceMapScript SetHeaders(DataHeader); State = CANNON_NOT_USED; + CannonBlast_Timer = 0; + PiratesDelay_Timer = 0; } ObjectGuid FactoryDoorGUID; diff --git a/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.cpp b/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.cpp index c1470d3bc47..05d964124b1 100644 --- a/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.cpp +++ b/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.h b/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.h index 760f84a69e9..bbfea6a2567 100644 --- a/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.h +++ b/src/server/scripts/EasternKingdoms/Gnomeregan/gnomeregan.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Gnomeregan/instance_gnomeregan.cpp b/src/server/scripts/EasternKingdoms/Gnomeregan/instance_gnomeregan.cpp index 843b28ce430..2c418692d03 100644 --- a/src/server/scripts/EasternKingdoms/Gnomeregan/instance_gnomeregan.cpp +++ b/src/server/scripts/EasternKingdoms/Gnomeregan/instance_gnomeregan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Karazhan/boss_curator.cpp b/src/server/scripts/EasternKingdoms/Karazhan/boss_curator.cpp index e3efd804f44..55c9cf2baa2 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/boss_curator.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/boss_curator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Karazhan/boss_maiden_of_virtue.cpp b/src/server/scripts/EasternKingdoms/Karazhan/boss_maiden_of_virtue.cpp index 7af7f27ec0c..9f4a31fdbbc 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/boss_maiden_of_virtue.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/boss_maiden_of_virtue.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Karazhan/boss_midnight.cpp b/src/server/scripts/EasternKingdoms/Karazhan/boss_midnight.cpp index 96c7c5d8102..ced8dd8f37e 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/boss_midnight.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/boss_midnight.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -91,9 +91,9 @@ public: Initialize(); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); ResetTimer = 2000; } diff --git a/src/server/scripts/EasternKingdoms/Karazhan/boss_moroes.cpp b/src/server/scripts/EasternKingdoms/Karazhan/boss_moroes.cpp index ba45b41f929..79e36442f4b 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/boss_moroes.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/boss_moroes.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2008 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Karazhan/boss_netherspite.cpp b/src/server/scripts/EasternKingdoms/Karazhan/boss_netherspite.cpp index 0a287173ada..a460477d385 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/boss_netherspite.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/boss_netherspite.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Karazhan/boss_nightbane.cpp b/src/server/scripts/EasternKingdoms/Karazhan/boss_nightbane.cpp index d8f1e2d15d7..6f5f2b8f65f 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/boss_nightbane.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/boss_nightbane.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp b/src/server/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp index d11c4a6e584..2920f0787a4 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/boss_prince_malchezaar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Karazhan/boss_shade_of_aran.cpp b/src/server/scripts/EasternKingdoms/Karazhan/boss_shade_of_aran.cpp index c5440848e9a..450678a0f86 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/boss_shade_of_aran.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/boss_shade_of_aran.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Karazhan/boss_terestian_illhoof.cpp b/src/server/scripts/EasternKingdoms/Karazhan/boss_terestian_illhoof.cpp index 67f8144c6c6..7bc835dcced 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/boss_terestian_illhoof.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/boss_terestian_illhoof.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp b/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp index 5b9442a628a..d4d0e6fa70d 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/bosses_opera.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp b/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp index e3ab206ac21..b725f421c8f 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/instance_karazhan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -44,6 +44,13 @@ EndScriptData */ 11 - Nightbane */ +const Position OptionalSpawn[] = +{ + { -10960.981445f, -1940.138428f, 46.178097f, 4.12f }, // Hyakiss the Lurker + { -10899.903320f, -2085.573730f, 49.474449f, 1.38f }, // Rokad the Ravager + { -10945.769531f, -2040.153320f, 49.474438f, 0.077f } // Shadikith the Glider +}; + class instance_karazhan : public InstanceMapScript { public: @@ -64,6 +71,7 @@ public: // 1 - OZ, 2 - HOOD, 3 - RAJ, this never gets altered. m_uiOperaEvent = urand(1, 3); m_uiOzDeathCount = 0; + OptionalBossCount = 0; } uint32 m_auiEncounter[MAX_ENCOUNTER]; @@ -71,6 +79,7 @@ public: uint32 m_uiOperaEvent; uint32 m_uiOzDeathCount; + uint32 OptionalBossCount; ObjectGuid m_uiCurtainGUID; ObjectGuid m_uiStageDoorLeftGUID; @@ -107,6 +116,29 @@ public: } } + void OnUnitDeath(Unit* unit) override + { + Creature* creature = unit->ToCreature(); + if (!creature) + return; + + switch (creature->GetEntry()) + { + case NPC_COLDMIST_WIDOW: + case NPC_COLDMIST_STALKER: + case NPC_SHADOWBAT: + case NPC_VAMPIRIC_SHADOWBAT: + case NPC_GREATER_SHADOWBAT: + case NPC_PHASE_HOUND: + case NPC_DREADBEAST: + case NPC_SHADOWBEAST: + SetData(TYPE_OPTIONAL_BOSS, NOT_STARTED); + break; + default: + break; + } + } + void SetData(uint32 type, uint32 uiData) override { switch (type) @@ -118,7 +150,28 @@ public: m_auiEncounter[1] = uiData; break; case TYPE_MAIDEN: m_auiEncounter[2] = uiData; break; - case TYPE_OPTIONAL_BOSS: m_auiEncounter[3] = uiData; break; + case TYPE_OPTIONAL_BOSS: + m_auiEncounter[3] = uiData; + if (uiData == NOT_STARTED) + { + ++OptionalBossCount; + if (OptionalBossCount == 50) + { + switch (urand(0, 2)) + { + case 0: + instance->SummonCreature(NPC_HYAKISS_THE_LURKER, OptionalSpawn[0]); + break; + case 1: + instance->SummonCreature(NPC_ROKAD_THE_RAVAGER, OptionalSpawn[1]); + break; + case 2: + instance->SummonCreature(NPC_SHADIKITH_THE_GLIDER, OptionalSpawn[2]); + break; + } + } + } + break; case TYPE_OPERA: m_auiEncounter[4] = uiData; if (uiData == DONE) diff --git a/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp b/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp index 8aba0a15462..aa2da8cc391 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp +++ b/src/server/scripts/EasternKingdoms/Karazhan/karazhan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Karazhan/karazhan.h b/src/server/scripts/EasternKingdoms/Karazhan/karazhan.h index 83f3f38aaea..4d86492257c 100644 --- a/src/server/scripts/EasternKingdoms/Karazhan/karazhan.h +++ b/src/server/scripts/EasternKingdoms/Karazhan/karazhan.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -64,4 +64,20 @@ enum OperaEvents EVENT_RAJ = 3 }; +enum MiscCreatures +{ + NPC_HYAKISS_THE_LURKER = 16179, + NPC_ROKAD_THE_RAVAGER = 16181, + NPC_SHADIKITH_THE_GLIDER = 16180, + + // Trash + NPC_COLDMIST_WIDOW = 16171, + NPC_COLDMIST_STALKER = 16170, + NPC_SHADOWBAT = 16173, + NPC_VAMPIRIC_SHADOWBAT = 16175, + NPC_GREATER_SHADOWBAT = 16174, + NPC_PHASE_HOUND = 16178, + NPC_DREADBEAST = 16177, + NPC_SHADOWBEAST = 16176 +}; #endif diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp index e4cc7c0e84a..b809128e731 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_felblood_kaelthas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp index 2f2647f42a6..6bba0d250ff 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_priestess_delrissa.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp index 480fd8848f5..05829128c5c 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_selin_fireheart.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp index 7d91a68e7ca..4be1246405c 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/boss_vexallus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp index 665213314b4..6386bb50e1a 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/instance_magisters_terrace.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -16,8 +16,10 @@ */ #include "ScriptMgr.h" +#include "ScriptedCreature.h" #include "InstanceScript.h" #include "magisters_terrace.h" +#include "EventMap.h" /* 0 - Selin Fireheart @@ -28,14 +30,16 @@ DoorData const doorData[] = { - { GO_SELIN_DOOR, DATA_SELIN, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_SELIN_ENCOUNTER_DOOR, DATA_SELIN, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_VEXALLUS_DOOR, DATA_VEXALLUS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_DELRISSA_DOOR, DATA_DELRISSA, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_KAEL_DOOR, DATA_KAELTHAS, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_SELIN_DOOR, DATA_SELIN, DOOR_TYPE_PASSAGE }, + { GO_SELIN_ENCOUNTER_DOOR, DATA_SELIN, DOOR_TYPE_ROOM }, + { GO_VEXALLUS_DOOR, DATA_VEXALLUS, DOOR_TYPE_PASSAGE }, + { GO_DELRISSA_DOOR, DATA_DELRISSA, DOOR_TYPE_PASSAGE }, + { GO_KAEL_DOOR, DATA_KAELTHAS, DOOR_TYPE_ROOM }, + { 0, 0, DOOR_TYPE_ROOM } // END }; +Position const KalecgosSpawnPos = { 164.3747f, -397.1197f, 2.151798f, 1.66219f }; + class instance_magisters_terrace : public InstanceMapScript { public: @@ -93,6 +97,10 @@ class instance_magisters_terrace : public InstanceMapScript case NPC_DELRISSA: DelrissaGUID = creature->GetGUID(); break; + case NPC_KALECGOS: + case NPC_HUMAN_KALECGOS: + KalecgosGUID = creature->GetGUID(); + break; default: break; } @@ -139,6 +147,25 @@ class instance_magisters_terrace : public InstanceMapScript } } + void ProcessEvent(WorldObject* obj, uint32 eventId) override + { + if (eventId == EVENT_SPAWN_KALECGOS) + if (!ObjectAccessor::GetCreature(*obj, KalecgosGUID) && Events.Empty()) + Events.ScheduleEvent(EVENT_SPAWN_KALECGOS, Minutes(1)); + } + + void Update(uint32 diff) override + { + Events.Update(diff); + + if (Events.ExecuteEvent() == EVENT_SPAWN_KALECGOS) + if (Creature* kalecgos = instance->SummonCreature(NPC_KALECGOS, KalecgosSpawnPos)) + { + kalecgos->GetMotionMaster()->MovePath(PATH_KALECGOS_FLIGHT, false); + kalecgos->AI()->Talk(SAY_KALECGOS_SPAWN); + } + } + bool SetBossState(uint32 type, EncounterState state) override { if (!InstanceScript::SetBossState(type, state)) @@ -177,10 +204,12 @@ class instance_magisters_terrace : public InstanceMapScript } protected: + EventMap Events; ObjectGuid SelinGUID; ObjectGuid DelrissaGUID; ObjectGuid KaelStatue[2]; ObjectGuid EscapeOrbGUID; + ObjectGuid KalecgosGUID; uint32 DelrissaDeathCount; }; diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.cpp b/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.cpp index 9c904dcada9..5b90ac8ccf4 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.cpp +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -31,7 +31,8 @@ EndContentData */ #include "ScriptedCreature.h" #include "ScriptedGossip.h" #include "Player.h" -#include "SpellInfo.h" +#include "magisters_terrace.h" +#include "EventMap.h" /*###### ## npc_kalecgos @@ -39,30 +40,29 @@ EndContentData */ enum Spells { - SPELL_TRANSFORM_TO_KAEL = 44670, + SPELL_KALECGOS_TRANSFORM = 44670, + SPELL_TRANSFORM_VISUAL = 24085, + SPELL_CAMERA_SHAKE = 44762, SPELL_ORB_KILL_CREDIT = 46307 }; -enum Creatures +enum MovementPoints { - NPC_KAEL = 24848 //human form entry + POINT_ID_PREPARE_LANDING = 6 }; -enum Misc +enum EventIds { - POINT_ID_LAND = 1 + EVENT_KALECGOS_TRANSFORM = 1, + EVENT_KALECGOS_LANDING = 2 }; -const float afKaelLandPoint[] = {225.045f, -276.236f, -5.434f}; - #define GOSSIP_ITEM_KAEL_1 "Who are you?" #define GOSSIP_ITEM_KAEL_2 "What can we do to assist you?" #define GOSSIP_ITEM_KAEL_3 "What brings you to the Sunwell?" #define GOSSIP_ITEM_KAEL_4 "You're not alone here?" #define GOSSIP_ITEM_KAEL_5 "What would Kil'jaeden want with a mortal woman?" -// This is friendly keal that appear after used Orb. -// If we assume DB handle summon, summon appear somewhere outside the platform where Orb is class npc_kalecgos : public CreatureScript { public: @@ -115,52 +115,46 @@ public: struct npc_kalecgosAI : public ScriptedAI { - npc_kalecgosAI(Creature* creature) : ScriptedAI(creature) - { - Initialize(); - } + npc_kalecgosAI(Creature* creature) : ScriptedAI(creature) { } - void Initialize() + void MovementInform(uint32 type, uint32 pointId) override { - m_uiTransformTimer = 0; - } - - uint32 m_uiTransformTimer; - - void Reset() override - { - Initialize(); - - // we must assume he appear as dragon somewhere outside the platform of orb, and then move directly to here - if (me->GetEntry() != NPC_KAEL) - me->GetMotionMaster()->MovePoint(POINT_ID_LAND, afKaelLandPoint[0], afKaelLandPoint[1], afKaelLandPoint[2]); - } - - void MovementInform(uint32 uiType, uint32 uiPointId) override - { - if (uiType != POINT_MOTION_TYPE) + if (type != WAYPOINT_MOTION_TYPE) return; - if (uiPointId == POINT_ID_LAND) - m_uiTransformTimer = MINUTE*IN_MILLISECONDS; + if (pointId == POINT_ID_PREPARE_LANDING) + { + me->HandleEmoteCommand(EMOTE_ONESHOT_LAND); + me->SetDisableGravity(false); + me->SetHover(false); + events.ScheduleEvent(EVENT_KALECGOS_LANDING, Seconds(2)); + } } - void UpdateAI(uint32 uiDiff) override + void UpdateAI(uint32 diff) override { - if (m_uiTransformTimer) + events.Update(diff); + + switch (events.ExecuteEvent()) { - if (m_uiTransformTimer <= uiDiff) - { + case EVENT_KALECGOS_LANDING: + DoCastAOE(SPELL_CAMERA_SHAKE); + me->SetObjectScale(0.6f); + events.ScheduleEvent(EVENT_KALECGOS_TRANSFORM, Seconds(1)); + break; + case EVENT_KALECGOS_TRANSFORM: DoCast(me, SPELL_ORB_KILL_CREDIT, true); - - // Transform and update entry, now ready for quest/read gossip - DoCast(me, SPELL_TRANSFORM_TO_KAEL, false); - me->UpdateEntry(NPC_KAEL); - - m_uiTransformTimer = 0; - } else m_uiTransformTimer -= uiDiff; + DoCast(me, SPELL_TRANSFORM_VISUAL, false); + DoCast(me, SPELL_KALECGOS_TRANSFORM, false); + me->UpdateEntry(NPC_HUMAN_KALECGOS); + break; + default: + break; } } + + private: + EventMap events; }; }; diff --git a/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h b/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h index 2b1ed8fee4d..05718dfc1dd 100644 --- a/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h +++ b/src/server/scripts/EasternKingdoms/MagistersTerrace/magisters_terrace.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -42,7 +42,9 @@ enum CreatureIds { NPC_SELIN = 24723, NPC_DELRISSA = 24560, - NPC_FEL_CRYSTAL = 24722 + NPC_FEL_CRYSTAL = 24722, + NPC_KALECGOS = 24844, + NPC_HUMAN_KALECGOS = 24848 }; enum GameObjectIds @@ -57,4 +59,19 @@ enum GameObjectIds GO_ESCAPE_ORB = 188173 }; +enum InstanceEventIds +{ + EVENT_SPAWN_KALECGOS = 16547 +}; + +enum InstanceText +{ + SAY_KALECGOS_SPAWN = 0 +}; + +enum MovementData +{ + PATH_KALECGOS_FLIGHT = 248440 +}; + #endif diff --git a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter1.cpp b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter1.cpp index f2d7f23bdc7..81044a0dbb1 100644 --- a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter1.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter1.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -449,8 +449,6 @@ class npc_eye_of_acherus : public CreatureScript ## npc_death_knight_initiate ######*/ -#define GOSSIP_ACCEPT_DUEL "I challenge you, death knight!" - enum Spells_DKI { SPELL_DUEL = 52996, @@ -511,7 +509,7 @@ public: if (player->IsInCombat() || creature->IsInCombat()) return true; - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ACCEPT_DUEL, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF); + player->ADD_GOSSIP_ITEM_DB(Player::GetDefaultGossipMenuForSource(creature), 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF); player->SEND_GOSSIP_MENU(player->GetGossipTextId(creature), creature->GetGUID()); } return true; diff --git a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter2.cpp b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter2.cpp index f72180f6948..cdecb65d8f3 100644 --- a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter2.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter2.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter5.cpp b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter5.cpp index ce8b094bb83..e336ff24382 100644 --- a/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter5.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletEnclave/chapter5.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -596,10 +596,10 @@ public: } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { if (!bIsBattle)//do not reset self if we are in battle - npc_escortAI::EnterEvadeMode(); + npc_escortAI::EnterEvadeMode(why); } void UpdateAI(uint32 diff) override diff --git a/src/server/scripts/EasternKingdoms/ScarletEnclave/zone_the_scarlet_enclave.cpp b/src/server/scripts/EasternKingdoms/ScarletEnclave/zone_the_scarlet_enclave.cpp index bde379b1b88..53b6d2be8dd 100644 --- a/src/server/scripts/EasternKingdoms/ScarletEnclave/zone_the_scarlet_enclave.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletEnclave/zone_the_scarlet_enclave.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_arcanist_doan.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_arcanist_doan.cpp index 59b1b553a07..e3462242dc8 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_arcanist_doan.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_arcanist_doan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp index c2dbd0c7245..0ffb555eb59 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_azshir_the_sleepless.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_bloodmage_thalnos.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_bloodmage_thalnos.cpp index 8f80344b247..4697e40702a 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_bloodmage_thalnos.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_bloodmage_thalnos.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_headless_horseman.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_headless_horseman.cpp index bac4e450a03..dff0a66cec0 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_headless_horseman.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_headless_horseman.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_herod.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_herod.cpp index 911cdf90d18..c511f1cabb7 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_herod.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_herod.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_high_inquisitor_fairbanks.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_high_inquisitor_fairbanks.cpp index 7bf70c4d7f1..c063204a50a 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_high_inquisitor_fairbanks.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_high_inquisitor_fairbanks.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_houndmaster_loksey.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_houndmaster_loksey.cpp index 4098701be76..2a96478cfad 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_houndmaster_loksey.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_houndmaster_loksey.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_interrogator_vishas.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_interrogator_vishas.cpp index e9a7dd0ce18..aeb7592cbdc 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_interrogator_vishas.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_interrogator_vishas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_mograine_and_whitemane.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_mograine_and_whitemane.cpp index 2848b19cd04..bab5a02cc90 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_mograine_and_whitemane.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_mograine_and_whitemane.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_scorn.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_scorn.cpp index 86d2c170f29..a68d7a67ac5 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_scorn.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/boss_scorn.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp b/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp index c41b1d87d61..7096e60fb15 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/instance_scarlet_monastery.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -21,8 +21,8 @@ DoorData const doorData[] = { - { GO_HIGH_INQUISITORS_DOOR, DATA_MOGRAINE_AND_WHITE_EVENT, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_HIGH_INQUISITORS_DOOR, DATA_MOGRAINE_AND_WHITE_EVENT, DOOR_TYPE_ROOM }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_scarlet_monastery : public InstanceMapScript diff --git a/src/server/scripts/EasternKingdoms/ScarletMonastery/scarlet_monastery.h b/src/server/scripts/EasternKingdoms/ScarletMonastery/scarlet_monastery.h index cbff8d50dae..aa1bcebacfc 100644 --- a/src/server/scripts/EasternKingdoms/ScarletMonastery/scarlet_monastery.h +++ b/src/server/scripts/EasternKingdoms/ScarletMonastery/scarlet_monastery.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_darkmaster_gandling.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_darkmaster_gandling.cpp index 65acc2d052e..7ba86d619d2 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_darkmaster_gandling.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_darkmaster_gandling.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_death_knight_darkreaver.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_death_knight_darkreaver.cpp index 85e1e33c22a..49eff958d36 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_death_knight_darkreaver.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_death_knight_darkreaver.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_doctor_theolen_krastinov.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_doctor_theolen_krastinov.cpp index e0da7b9a440..7cbe58ecaea 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_doctor_theolen_krastinov.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_doctor_theolen_krastinov.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_illucia_barov.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_illucia_barov.cpp index b073f5ade73..27da16518b7 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_illucia_barov.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_illucia_barov.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_instructor_malicia.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_instructor_malicia.cpp index 3d7b96a9abd..6a81132eb28 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_instructor_malicia.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_instructor_malicia.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_jandice_barov.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_jandice_barov.cpp index f09c896e0be..8e2d7253efb 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_jandice_barov.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_jandice_barov.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_kirtonos_the_herald.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_kirtonos_the_herald.cpp index 8f780d1e2c3..7db477ca7e1 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_kirtonos_the_herald.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_kirtonos_the_herald.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -108,7 +108,7 @@ class boss_kirtonos_the_herald : public CreatureScript _JustDied(); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { if (GameObject* gate = me->GetMap()->GetGameObject(instance->GetGuidData(GO_GATE_KIRTONOS))) gate->SetGoState(GO_STATE_ACTIVE); diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_kormok.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_kormok.cpp index 00b3beeabf0..c3dda79f728 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_kormok.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_kormok.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_lord_alexei_barov.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_lord_alexei_barov.cpp index 72fd1a18b9d..e3aa2cecaa3 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_lord_alexei_barov.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_lord_alexei_barov.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_lorekeeper_polkelt.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_lorekeeper_polkelt.cpp index 679fa0dc58e..3af0fd7a2bd 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_lorekeeper_polkelt.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_lorekeeper_polkelt.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_ras_frostwhisper.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_ras_frostwhisper.cpp index b6a3f186268..7a0e6f5fb5d 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_ras_frostwhisper.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_ras_frostwhisper.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_the_ravenian.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_the_ravenian.cpp index 47e0bd80068..ffe50c5dae3 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_the_ravenian.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_the_ravenian.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/boss_vectus.cpp b/src/server/scripts/EasternKingdoms/Scholomance/boss_vectus.cpp index f555554e6c4..9a34c2194cf 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/boss_vectus.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/boss_vectus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/instance_scholomance.cpp b/src/server/scripts/EasternKingdoms/Scholomance/instance_scholomance.cpp index 49c3c3ba1c7..854f77e1d0d 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/instance_scholomance.cpp +++ b/src/server/scripts/EasternKingdoms/Scholomance/instance_scholomance.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Scholomance/scholomance.h b/src/server/scripts/EasternKingdoms/Scholomance/scholomance.h index 0ec53105f1f..1ada609a1ce 100644 --- a/src/server/scripts/EasternKingdoms/Scholomance/scholomance.h +++ b/src/server/scripts/EasternKingdoms/Scholomance/scholomance.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/ShadowfangKeep/instance_shadowfang_keep.cpp b/src/server/scripts/EasternKingdoms/ShadowfangKeep/instance_shadowfang_keep.cpp index a085463f7ce..3bd5220a8e0 100644 --- a/src/server/scripts/EasternKingdoms/ShadowfangKeep/instance_shadowfang_keep.cpp +++ b/src/server/scripts/EasternKingdoms/ShadowfangKeep/instance_shadowfang_keep.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.cpp b/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.cpp index f2d3a21a280..94cf2825e60 100644 --- a/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.cpp +++ b/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -63,8 +63,6 @@ enum Creatures NPC_ASH = 3850 }; -#define GOSSIP_ITEM_DOOR "Thanks, I'll follow you to the door." - class npc_shadowfang_prisoner : public CreatureScript { public: @@ -93,7 +91,7 @@ public: InstanceScript* instance = creature->GetInstanceScript(); if (instance && instance->GetData(TYPE_FREE_NPC) != DONE && instance->GetData(TYPE_RETHILGORE) == DONE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_DOOR, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); + player->ADD_GOSSIP_ITEM_DB(Player::GetDefaultGossipMenuForSource(creature), 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); player->SEND_GOSSIP_MENU(player->GetGossipTextId(creature), creature->GetGUID()); diff --git a/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.h b/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.h index 2f0de6de5e6..88edc3f1ee1 100644 --- a/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.h +++ b/src/server/scripts/EasternKingdoms/ShadowfangKeep/shadowfang_keep.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/boss_baron_rivendare.cpp b/src/server/scripts/EasternKingdoms/Stratholme/boss_baron_rivendare.cpp index f6f6dab866d..f81c77838f4 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/boss_baron_rivendare.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/boss_baron_rivendare.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/boss_baroness_anastari.cpp b/src/server/scripts/EasternKingdoms/Stratholme/boss_baroness_anastari.cpp index d8f4383f614..a454be8a2dd 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/boss_baroness_anastari.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/boss_baroness_anastari.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/boss_cannon_master_willey.cpp b/src/server/scripts/EasternKingdoms/Stratholme/boss_cannon_master_willey.cpp index 2e33865fe28..cfa830ee99b 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/boss_cannon_master_willey.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/boss_cannon_master_willey.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/boss_dathrohan_balnazzar.cpp b/src/server/scripts/EasternKingdoms/Stratholme/boss_dathrohan_balnazzar.cpp index 3f207ef680d..161e1160b8b 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/boss_dathrohan_balnazzar.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/boss_dathrohan_balnazzar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/boss_magistrate_barthilas.cpp b/src/server/scripts/EasternKingdoms/Stratholme/boss_magistrate_barthilas.cpp index e42662bbe0b..393747072f3 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/boss_magistrate_barthilas.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/boss_magistrate_barthilas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/boss_maleki_the_pallid.cpp b/src/server/scripts/EasternKingdoms/Stratholme/boss_maleki_the_pallid.cpp index b094eb45dca..2c7026fd0ac 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/boss_maleki_the_pallid.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/boss_maleki_the_pallid.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/boss_nerubenkan.cpp b/src/server/scripts/EasternKingdoms/Stratholme/boss_nerubenkan.cpp index 2dc00edac16..dbafc91d3dc 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/boss_nerubenkan.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/boss_nerubenkan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/boss_order_of_silver_hand.cpp b/src/server/scripts/EasternKingdoms/Stratholme/boss_order_of_silver_hand.cpp index 9ac8d9b40f9..1dca56c6439 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/boss_order_of_silver_hand.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/boss_order_of_silver_hand.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/boss_postmaster_malown.cpp b/src/server/scripts/EasternKingdoms/Stratholme/boss_postmaster_malown.cpp index 0b3fa2e7caa..ffbc597ab9f 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/boss_postmaster_malown.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/boss_postmaster_malown.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/boss_ramstein_the_gorger.cpp b/src/server/scripts/EasternKingdoms/Stratholme/boss_ramstein_the_gorger.cpp index e3ea85a1d1f..b9cc7e4edd8 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/boss_ramstein_the_gorger.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/boss_ramstein_the_gorger.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/boss_timmy_the_cruel.cpp b/src/server/scripts/EasternKingdoms/Stratholme/boss_timmy_the_cruel.cpp index cbc9e3c375d..decbf53241b 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/boss_timmy_the_cruel.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/boss_timmy_the_cruel.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/instance_stratholme.cpp b/src/server/scripts/EasternKingdoms/Stratholme/instance_stratholme.cpp index 1257808756e..d2a5328af8b 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/instance_stratholme.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/instance_stratholme.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/stratholme.cpp b/src/server/scripts/EasternKingdoms/Stratholme/stratholme.cpp index 60dd27eed90..4ebefcf7122 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/stratholme.cpp +++ b/src/server/scripts/EasternKingdoms/Stratholme/stratholme.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Stratholme/stratholme.h b/src/server/scripts/EasternKingdoms/Stratholme/stratholme.h index 28b0a67fa75..9237149c184 100644 --- a/src/server/scripts/EasternKingdoms/Stratholme/stratholme.h +++ b/src/server/scripts/EasternKingdoms/Stratholme/stratholme.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/SunkenTemple/instance_sunken_temple.cpp b/src/server/scripts/EasternKingdoms/SunkenTemple/instance_sunken_temple.cpp index ca944f7037b..118d28e2142 100644 --- a/src/server/scripts/EasternKingdoms/SunkenTemple/instance_sunken_temple.cpp +++ b/src/server/scripts/EasternKingdoms/SunkenTemple/instance_sunken_temple.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.cpp b/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.cpp index 97be139cefe..64ccdd11ccd 100644 --- a/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.cpp +++ b/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.h b/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.h index cf7924f80b0..3a6d867ebea 100644 --- a/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.h +++ b/src/server/scripts/EasternKingdoms/SunkenTemple/sunken_temple.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp index 6ca768b2de7..2534c099169 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_brutallus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -136,10 +136,10 @@ public: me->SummonCreature(NPC_FELMYST, x, y, z + 30, me->GetOrientation(), TEMPSUMMON_MANUAL_DESPAWN, 0); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { if (!Intro) - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); } void StartIntro() diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp index 77e0e680f4a..e70d7834c75 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_eredar_twins.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_felmyst.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_felmyst.cpp index c4598dda915..d9b481d7b6d 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_felmyst.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_felmyst.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp index c8964b2ff31..8707c7eca27 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kalecgos.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -169,12 +169,12 @@ public: me->SetFullHealth(); //dunno why it does not resets health at evade.. } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { bJustReset = true; me->SetVisible(false); me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE + UNIT_FLAG_NOT_SELECTABLE); - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); } void DoAction(int32 param) override @@ -237,7 +237,7 @@ public: { if (me->GetDistance(CENTER_X, CENTER_Y, DRAGON_REALM_Z) >= 75) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_BOUNDARY); return; } if (HealthBelowPct(10) && !isEnraged) @@ -261,7 +261,7 @@ public: else { TC_LOG_ERROR("scripts", "Didn't find Shathrowar. Kalecgos event reseted."); - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); return; } } @@ -423,7 +423,7 @@ public: TalkTimer = 15000; break; case 3: - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); break; default: break; diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp index e3deac506b0..d86b3707606 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_kiljaeden.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -624,9 +624,9 @@ public: Talk(SAY_KJ_SLAY); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); summons.DespawnAll(); diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp index 421f3d771a0..04d23cd7d4e 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/boss_muru.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -151,7 +151,7 @@ public: } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { if (Creature* muru = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_MURU))) muru->AI()->Reset(); // Reset encounter. diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp index 9b1585ba58b..bb9d3065f64 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/instance_sunwell_plateau.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -31,13 +31,13 @@ DoorData const doorData[] = { - { GO_FIRE_BARRIER, DATA_FELMYST, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_MURUS_GATE_1, DATA_MURU, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_MURUS_GATE_2, DATA_MURU, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_BOSS_COLLISION_1, DATA_KALECGOS, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_BOSS_COLLISION_2, DATA_KALECGOS, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_FORCE_FIELD, DATA_KALECGOS, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_FIRE_BARRIER, DATA_FELMYST, DOOR_TYPE_PASSAGE }, + { GO_MURUS_GATE_1, DATA_MURU, DOOR_TYPE_ROOM }, + { GO_MURUS_GATE_2, DATA_MURU, DOOR_TYPE_PASSAGE }, + { GO_BOSS_COLLISION_1, DATA_KALECGOS, DOOR_TYPE_ROOM }, + { GO_BOSS_COLLISION_2, DATA_KALECGOS, DOOR_TYPE_ROOM }, + { GO_FORCE_FIELD, DATA_KALECGOS, DOOR_TYPE_ROOM }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_sunwell_plateau : public InstanceMapScript diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.cpp b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.cpp index 5be8cfab555..849710c5539 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.cpp +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h index 92d0dc9f6cc..c6b4ae753a5 100644 --- a/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h +++ b/src/server/scripts/EasternKingdoms/SunwellPlateau/sunwell_plateau.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/TheStockade/instance_the_stockade.cpp b/src/server/scripts/EasternKingdoms/TheStockade/instance_the_stockade.cpp index 6df7679a403..b8c9734d961 100644 --- a/src/server/scripts/EasternKingdoms/TheStockade/instance_the_stockade.cpp +++ b/src/server/scripts/EasternKingdoms/TheStockade/instance_the_stockade.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/Uldaman/boss_archaedas.cpp b/src/server/scripts/EasternKingdoms/Uldaman/boss_archaedas.cpp index 29002460b2a..a5fed30a6c6 100644 --- a/src/server/scripts/EasternKingdoms/Uldaman/boss_archaedas.cpp +++ b/src/server/scripts/EasternKingdoms/Uldaman/boss_archaedas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2007 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Uldaman/boss_ironaya.cpp b/src/server/scripts/EasternKingdoms/Uldaman/boss_ironaya.cpp index 7f0faa138ec..dce92a16cfe 100644 --- a/src/server/scripts/EasternKingdoms/Uldaman/boss_ironaya.cpp +++ b/src/server/scripts/EasternKingdoms/Uldaman/boss_ironaya.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Uldaman/instance_uldaman.cpp b/src/server/scripts/EasternKingdoms/Uldaman/instance_uldaman.cpp index 11699d4ec43..8c78fb7ff1b 100644 --- a/src/server/scripts/EasternKingdoms/Uldaman/instance_uldaman.cpp +++ b/src/server/scripts/EasternKingdoms/Uldaman/instance_uldaman.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2007 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/Uldaman/uldaman.cpp b/src/server/scripts/EasternKingdoms/Uldaman/uldaman.cpp index 7cd7da771d1..447dbcd67f9 100644 --- a/src/server/scripts/EasternKingdoms/Uldaman/uldaman.cpp +++ b/src/server/scripts/EasternKingdoms/Uldaman/uldaman.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -132,7 +132,10 @@ public: ## at_map_chamber ######*/ -#define QUEST_HIDDEN_CHAMBER 2240 +enum MapChamber +{ + QUEST_HIDDEN_CHAMBER = 2240 +}; class AreaTrigger_at_map_chamber : public AreaTriggerScript { diff --git a/src/server/scripts/EasternKingdoms/Uldaman/uldaman.h b/src/server/scripts/EasternKingdoms/Uldaman/uldaman.h index 03d638ff5c2..24fba425e48 100644 --- a/src/server/scripts/EasternKingdoms/Uldaman/uldaman.h +++ b/src/server/scripts/EasternKingdoms/Uldaman/uldaman.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp index 30e1f5ced22..791f68bae31 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_akilzon.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_halazzi.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_halazzi.cpp index 2317582af99..2842e64ca9b 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_halazzi.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_halazzi.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_hexlord.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_hexlord.cpp index a9abb2c045d..cc55f758a22 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_hexlord.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_hexlord.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2007 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp index 3228fbfde1b..0cae909558e 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_janalai.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -424,8 +424,6 @@ class boss_janalai : public CreatureScript } else HatcherTimer -= diff; } - EnterEvadeIfOutOfCombatArea(diff); - DoMeleeAttackIfReady(); if (FireBreathTimer <= diff) diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_nalorakk.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_nalorakk.cpp index a0e4d037f8a..37505a8b74d 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_nalorakk.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_nalorakk.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulAman/boss_zuljin.cpp b/src/server/scripts/EasternKingdoms/ZulAman/boss_zuljin.cpp index b89c825fdbb..96c0798ae05 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/boss_zuljin.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/boss_zuljin.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp index f6622ffe1f4..ab182cf0848 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/instance_zulaman.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp index 1927b0f9829..972acdc3f9f 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h index 74162f0859d..0cd22b5a304 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_arlokk.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_arlokk.cpp index 0046bc8fcd7..4eac8556dbb 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_arlokk.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_arlokk.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -157,9 +157,9 @@ class boss_arlokk : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - BossAI::EnterEvadeMode(); + BossAI::EnterEvadeMode(why); if (GameObject* object = ObjectAccessor::GetGameObject(*me, instance->GetGuidData(GO_GONG_OF_BETHEKK))) object->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_NOT_SELECTABLE); me->DespawnOrUnsummon(4000); diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_gahzranka.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_gahzranka.cpp index 8ef05c3409d..53d3b8e4555 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_gahzranka.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_gahzranka.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_grilek.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_grilek.cpp index 2469779d175..76b12dcf24d 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_grilek.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_grilek.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_hakkar.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_hakkar.cpp index 4642b0af46f..58ae281a8a2 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_hakkar.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_hakkar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_hazzarah.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_hazzarah.cpp index 500bf24f3be..12ffec3ce87 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_hazzarah.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_hazzarah.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_jeklik.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_jeklik.cpp index 81460e14695..7c0f9645406 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_jeklik.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_jeklik.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_jindo.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_jindo.cpp index 154de685b04..364e84bce66 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_jindo.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_jindo.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_mandokir.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_mandokir.cpp index 8746a024ab3..8c179af2adf 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_mandokir.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_mandokir.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_marli.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_marli.cpp index 6b68d9e5fa0..f00d133e4fc 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_marli.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_marli.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_renataki.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_renataki.cpp index 6219b62dcc5..71dfafa339e 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_renataki.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_renataki.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_thekal.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_thekal.cpp index 654bfd54109..def7c7562c0 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_thekal.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_thekal.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_venoxis.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_venoxis.cpp index 95367fc55ff..f9cbbeddb91 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_venoxis.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_venoxis.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/boss_wushoolay.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/boss_wushoolay.cpp index 54cd1d7c606..1c4f6e298b3 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/boss_wushoolay.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/boss_wushoolay.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/instance_zulgurub.cpp b/src/server/scripts/EasternKingdoms/ZulGurub/instance_zulgurub.cpp index c96fbd15b33..60cb976f17c 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/instance_zulgurub.cpp +++ b/src/server/scripts/EasternKingdoms/ZulGurub/instance_zulgurub.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -29,8 +29,8 @@ EndScriptData */ DoorData const doorData[] = { - { GO_FORCEFIELD, DATA_ARLOKK, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_FORCEFIELD, DATA_ARLOKK, DOOR_TYPE_ROOM }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_zulgurub : public InstanceMapScript diff --git a/src/server/scripts/EasternKingdoms/ZulGurub/zulgurub.h b/src/server/scripts/EasternKingdoms/ZulGurub/zulgurub.h index a0e579ce4c3..89151441330 100644 --- a/src/server/scripts/EasternKingdoms/ZulGurub/zulgurub.h +++ b/src/server/scripts/EasternKingdoms/ZulGurub/zulgurub.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/zone_arathi_highlands.cpp b/src/server/scripts/EasternKingdoms/zone_arathi_highlands.cpp index ac261f29287..4d8396aeba4 100644 --- a/src/server/scripts/EasternKingdoms/zone_arathi_highlands.cpp +++ b/src/server/scripts/EasternKingdoms/zone_arathi_highlands.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_blasted_lands.cpp b/src/server/scripts/EasternKingdoms/zone_blasted_lands.cpp index c0010991d31..9fb019d3b9e 100644 --- a/src/server/scripts/EasternKingdoms/zone_blasted_lands.cpp +++ b/src/server/scripts/EasternKingdoms/zone_blasted_lands.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/zone_burning_steppes.cpp b/src/server/scripts/EasternKingdoms/zone_burning_steppes.cpp index f67ce07af82..df61a010f84 100644 --- a/src/server/scripts/EasternKingdoms/zone_burning_steppes.cpp +++ b/src/server/scripts/EasternKingdoms/zone_burning_steppes.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_duskwood.cpp b/src/server/scripts/EasternKingdoms/zone_duskwood.cpp index 9bbaf616a6c..667faba7544 100644 --- a/src/server/scripts/EasternKingdoms/zone_duskwood.cpp +++ b/src/server/scripts/EasternKingdoms/zone_duskwood.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_eastern_plaguelands.cpp b/src/server/scripts/EasternKingdoms/zone_eastern_plaguelands.cpp index 2f10aa858f9..ce0ebf4d129 100644 --- a/src/server/scripts/EasternKingdoms/zone_eastern_plaguelands.cpp +++ b/src/server/scripts/EasternKingdoms/zone_eastern_plaguelands.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_ghostlands.cpp b/src/server/scripts/EasternKingdoms/zone_ghostlands.cpp index 3ce8d078cbc..b24c355d41f 100644 --- a/src/server/scripts/EasternKingdoms/zone_ghostlands.cpp +++ b/src/server/scripts/EasternKingdoms/zone_ghostlands.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_hinterlands.cpp b/src/server/scripts/EasternKingdoms/zone_hinterlands.cpp index e0612a5ec78..f9b7e9b0d7b 100644 --- a/src/server/scripts/EasternKingdoms/zone_hinterlands.cpp +++ b/src/server/scripts/EasternKingdoms/zone_hinterlands.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_isle_of_queldanas.cpp b/src/server/scripts/EasternKingdoms/zone_isle_of_queldanas.cpp index 3f72b7353d6..f7d014ea7a7 100644 --- a/src/server/scripts/EasternKingdoms/zone_isle_of_queldanas.cpp +++ b/src/server/scripts/EasternKingdoms/zone_isle_of_queldanas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_loch_modan.cpp b/src/server/scripts/EasternKingdoms/zone_loch_modan.cpp index 56c0d99097e..151f8270c47 100644 --- a/src/server/scripts/EasternKingdoms/zone_loch_modan.cpp +++ b/src/server/scripts/EasternKingdoms/zone_loch_modan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_redridge_mountains.cpp b/src/server/scripts/EasternKingdoms/zone_redridge_mountains.cpp index 607b449552f..a30d795a48e 100644 --- a/src/server/scripts/EasternKingdoms/zone_redridge_mountains.cpp +++ b/src/server/scripts/EasternKingdoms/zone_redridge_mountains.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/EasternKingdoms/zone_silverpine_forest.cpp b/src/server/scripts/EasternKingdoms/zone_silverpine_forest.cpp index c77bf8110f0..49dfda48a69 100644 --- a/src/server/scripts/EasternKingdoms/zone_silverpine_forest.cpp +++ b/src/server/scripts/EasternKingdoms/zone_silverpine_forest.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_stormwind_city.cpp b/src/server/scripts/EasternKingdoms/zone_stormwind_city.cpp index d6e8e344930..2d6d4da5aef 100644 --- a/src/server/scripts/EasternKingdoms/zone_stormwind_city.cpp +++ b/src/server/scripts/EasternKingdoms/zone_stormwind_city.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -256,7 +256,7 @@ public: Initialize(); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { me->DisappearAndDie(); @@ -417,7 +417,7 @@ public: } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { me->DisappearAndDie(); diff --git a/src/server/scripts/EasternKingdoms/zone_stranglethorn_vale.cpp b/src/server/scripts/EasternKingdoms/zone_stranglethorn_vale.cpp index 0c13aac2864..ca7b656a910 100644 --- a/src/server/scripts/EasternKingdoms/zone_stranglethorn_vale.cpp +++ b/src/server/scripts/EasternKingdoms/zone_stranglethorn_vale.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_swamp_of_sorrows.cpp b/src/server/scripts/EasternKingdoms/zone_swamp_of_sorrows.cpp index b162b4f4d75..3cf09b66611 100644 --- a/src/server/scripts/EasternKingdoms/zone_swamp_of_sorrows.cpp +++ b/src/server/scripts/EasternKingdoms/zone_swamp_of_sorrows.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_tirisfal_glades.cpp b/src/server/scripts/EasternKingdoms/zone_tirisfal_glades.cpp index 028eb5e8f7d..438bed21b3f 100644 --- a/src/server/scripts/EasternKingdoms/zone_tirisfal_glades.cpp +++ b/src/server/scripts/EasternKingdoms/zone_tirisfal_glades.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/EasternKingdoms/zone_undercity.cpp b/src/server/scripts/EasternKingdoms/zone_undercity.cpp index d7d06a2e3ab..99556587e65 100644 --- a/src/server/scripts/EasternKingdoms/zone_undercity.cpp +++ b/src/server/scripts/EasternKingdoms/zone_undercity.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -157,7 +157,7 @@ public: { if (Creature* target = ObjectAccessor::GetCreature(*summoned, targetGUID)) { - target->GetMotionMaster()->MoveJump(target->GetPositionX(), target->GetPositionY(), me->GetPositionZ() + 15.0f, 0); + target->GetMotionMaster()->MoveJump(target->GetPositionX(), target->GetPositionY(), me->GetPositionZ() + 15.0f, me->GetOrientation(), 0); target->SetPosition(target->GetPositionX(), target->GetPositionY(), me->GetPositionZ()+15.0f, 0.0f); summoned->CastSpell(target, SPELL_RIBBON_OF_SOULS, false); } @@ -317,59 +317,6 @@ public: }; /*###### -## npc_parqual_fintallas -######*/ - -enum ParqualFintallas -{ - SPELL_MARK_OF_SHAME = 6767 -}; - -#define GOSSIP_HPF1 "Gul'dan" -#define GOSSIP_HPF2 "Kel'Thuzad" -#define GOSSIP_HPF3 "Ner'zhul" - -class npc_parqual_fintallas : public CreatureScript -{ -public: - npc_parqual_fintallas() : CreatureScript("npc_parqual_fintallas") { } - - bool OnGossipSelect(Player* player, Creature* creature, uint32 /*sender*/, uint32 action) override - { - player->PlayerTalkClass->ClearMenus(); - if (action == GOSSIP_ACTION_INFO_DEF+1) - { - player->CLOSE_GOSSIP_MENU(); - creature->CastSpell(player, SPELL_MARK_OF_SHAME, false); - } - if (action == GOSSIP_ACTION_INFO_DEF+2) - { - player->CLOSE_GOSSIP_MENU(); - player->AreaExploredOrEventHappens(6628); - } - return true; - } - - bool OnGossipHello(Player* player, Creature* creature) override - { - if (creature->IsQuestGiver()) - player->PrepareQuestMenu(creature->GetGUID()); - - if (player->GetQuestStatus(6628) == QUEST_STATUS_INCOMPLETE && !player->HasAura(SPELL_MARK_OF_SHAME)) - { - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_HPF1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1); - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_HPF2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1); - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_HPF3, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2); - player->SEND_GOSSIP_MENU(5822, creature->GetGUID()); - } - else - player->SEND_GOSSIP_MENU(5821, creature->GetGUID()); - - return true; - } -}; - -/*###### ## AddSC ######*/ @@ -377,5 +324,4 @@ void AddSC_undercity() { new npc_lady_sylvanas_windrunner(); new npc_highborne_lamenter(); - new npc_parqual_fintallas(); } diff --git a/src/server/scripts/EasternKingdoms/zone_western_plaguelands.cpp b/src/server/scripts/EasternKingdoms/zone_western_plaguelands.cpp index 9af23f17dca..a01b93a140b 100644 --- a/src/server/scripts/EasternKingdoms/zone_western_plaguelands.cpp +++ b/src/server/scripts/EasternKingdoms/zone_western_plaguelands.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -25,7 +25,6 @@ EndScriptData */ /* ContentData npcs_dithers_and_arbington -npc_myranda_the_hag npc_the_scourge_cauldron npc_andorhal_tower EndContentData */ @@ -33,7 +32,6 @@ EndContentData */ #include "ScriptMgr.h" #include "ScriptedCreature.h" #include "ScriptedGossip.h" -#include "ScriptedEscortAI.h" #include "Player.h" #include "WorldSession.h" @@ -41,12 +39,23 @@ EndContentData */ ## npcs_dithers_and_arbington ######*/ -#define GOSSIP_HDA1 "What does the Felstone Field Cauldron need?" -#define GOSSIP_HDA2 "What does the Dalson's Tears Cauldron need?" -#define GOSSIP_HDA3 "What does the Writhing Haunt Cauldron need?" -#define GOSSIP_HDA4 "What does the Gahrron's Withering Cauldron need?" - -#define GOSSIP_SDA1 "Thanks, i need a Vitreous Focuser" +enum DithersAndArbington +{ + GOSSIP_ITEM_ID_FELSTONE_FIELD = 0, + GOSSIP_ITEM_ID_DALSON_S_TEARS = 1, + GOSSIP_ITEM_ID_WRITHING_HAUNT = 2, + GOSSIP_ITEM_ID_GAHRRON_S_WITH = 3, + GOSSIP_MENU_ID_LETS_GET_TO_WORK = 3223, + GOSSIP_MENU_ID_VITREOUS_FOCUSER = 3229, + NPC_TEXT_OSSEOUS_AGITATORS = 3980, + NPC_TEXT_SOMATIC_INTENSIFIERS_1 = 3981, + NPC_TEXT_SOMATIC_INTENSIFIERS_2 = 3982, + NPC_TEXT_ECTOPLASMIC_RESONATORS = 3983, + NPC_TEXT_LET_S_GET_TO_WORK = 3985, + QUEST_MISSION_ACCOMPLISHED_H = 5237, + QUEST_MISSION_ACCOMPLISHED_A = 5238, + CREATE_ITEM_VITREOUS_FOCUSER = 17529 +}; class npcs_dithers_and_arbington : public CreatureScript { @@ -62,24 +71,24 @@ public: player->GetSession()->SendListInventory(creature->GetGUID()); break; case GOSSIP_ACTION_INFO_DEF+1: - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SDA1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+5); - player->SEND_GOSSIP_MENU(3980, creature->GetGUID()); + player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_ID_VITREOUS_FOCUSER, 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+5); + player->SEND_GOSSIP_MENU(NPC_TEXT_OSSEOUS_AGITATORS, creature->GetGUID()); break; case GOSSIP_ACTION_INFO_DEF+2: - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SDA1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+5); - player->SEND_GOSSIP_MENU(3981, creature->GetGUID()); + player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_ID_VITREOUS_FOCUSER, 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+5); + player->SEND_GOSSIP_MENU(NPC_TEXT_SOMATIC_INTENSIFIERS_1, creature->GetGUID()); break; case GOSSIP_ACTION_INFO_DEF+3: - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SDA1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+5); - player->SEND_GOSSIP_MENU(3982, creature->GetGUID()); + player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_ID_VITREOUS_FOCUSER, 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+5); + player->SEND_GOSSIP_MENU(NPC_TEXT_SOMATIC_INTENSIFIERS_2, creature->GetGUID()); break; case GOSSIP_ACTION_INFO_DEF+4: - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SDA1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+5); - player->SEND_GOSSIP_MENU(3983, creature->GetGUID()); + player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_ID_VITREOUS_FOCUSER, 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+5); + player->SEND_GOSSIP_MENU(NPC_TEXT_ECTOPLASMIC_RESONATORS, creature->GetGUID()); break; case GOSSIP_ACTION_INFO_DEF+5: player->CLOSE_GOSSIP_MENU(); - creature->CastSpell(player, 17529, false); + creature->CastSpell(player, CREATE_ITEM_VITREOUS_FOCUSER, false); break; } return true; @@ -93,62 +102,13 @@ public: if (creature->IsVendor()) player->ADD_GOSSIP_ITEM(GOSSIP_ICON_VENDOR, GOSSIP_TEXT_BROWSE_GOODS, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_TRADE); - if (player->GetQuestRewardStatus(5237) || player->GetQuestRewardStatus(5238)) - { - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_HDA1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1); - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_HDA2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2); - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_HDA3, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+3); - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_HDA4, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+4); - player->SEND_GOSSIP_MENU(3985, creature->GetGUID()); - } - else - player->SEND_GOSSIP_MENU(player->GetGossipTextId(creature), creature->GetGUID()); - - return true; - } -}; - -/*###### -## npc_myranda_the_hag -######*/ - -enum Myranda -{ - QUEST_SUBTERFUGE = 5862, - QUEST_IN_DREAMS = 5944, - SPELL_SCARLET_ILLUSION = 17961 -}; - -#define GOSSIP_ITEM_ILLUSION "I am ready for the illusion, Myranda." - -class npc_myranda_the_hag : public CreatureScript -{ -public: - npc_myranda_the_hag() : CreatureScript("npc_myranda_the_hag") { } - - bool OnGossipSelect(Player* player, Creature* /*creature*/, uint32 /*sender*/, uint32 action) override - { - player->PlayerTalkClass->ClearMenus(); - if (action == GOSSIP_ACTION_INFO_DEF + 1) + if (player->GetQuestRewardStatus(QUEST_MISSION_ACCOMPLISHED_H) || player->GetQuestRewardStatus(QUEST_MISSION_ACCOMPLISHED_A)) { - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, SPELL_SCARLET_ILLUSION, false); - } - return true; - } - - bool OnGossipHello(Player* player, Creature* creature) override - { - if (creature->IsQuestGiver()) - player->PrepareQuestMenu(creature->GetGUID()); - - if (player->GetQuestStatus(QUEST_SUBTERFUGE) == QUEST_STATUS_COMPLETE && - player->GetQuestStatus(QUEST_IN_DREAMS) != QUEST_STATUS_COMPLETE && - !player->HasAura(SPELL_SCARLET_ILLUSION)) - { - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_ILLUSION, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); - player->SEND_GOSSIP_MENU(4773, creature->GetGUID()); - return true; + player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_ID_LETS_GET_TO_WORK, GOSSIP_ITEM_ID_FELSTONE_FIELD, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+1); + player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_ID_LETS_GET_TO_WORK, GOSSIP_ITEM_ID_DALSON_S_TEARS, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+2); + player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_ID_LETS_GET_TO_WORK, GOSSIP_ITEM_ID_WRITHING_HAUNT, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+3); + player->ADD_GOSSIP_ITEM_DB(GOSSIP_MENU_ID_LETS_GET_TO_WORK, GOSSIP_ITEM_ID_GAHRRON_S_WITH, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+4); + player->SEND_GOSSIP_MENU(NPC_TEXT_LET_S_GET_TO_WORK, creature->GetGUID()); } else player->SEND_GOSSIP_MENU(player->GetGossipTextId(creature), creature->GetGUID()); @@ -185,7 +145,7 @@ public: me->DealDamage(me, me->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false); //override any database `spawntimesecs` to prevent duplicated summons uint32 rTime = me->GetRespawnDelay(); - if (rTime<600) + if (rTime < 600) me->SetRespawnDelay(600); } @@ -264,7 +224,6 @@ public: } void MoveInLineOfSight(Unit* who) override - { if (!who || who->GetTypeId() != TYPEID_PLAYER) return; @@ -276,14 +235,9 @@ public: }; }; -/*###### -## -######*/ - void AddSC_western_plaguelands() { new npcs_dithers_and_arbington(); - new npc_myranda_the_hag(); new npc_the_scourge_cauldron(); new npc_andorhal_tower(); } diff --git a/src/server/scripts/EasternKingdoms/zone_wetlands.cpp b/src/server/scripts/EasternKingdoms/zone_wetlands.cpp index d41ab5776aa..d97dbdb37a8 100644 --- a/src/server/scripts/EasternKingdoms/zone_wetlands.cpp +++ b/src/server/scripts/EasternKingdoms/zone_wetlands.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Events/CMakeLists.txt b/src/server/scripts/Events/CMakeLists.txt index 0fad0276a81..1c9e5cfe8e1 100644 --- a/src/server/scripts/Events/CMakeLists.txt +++ b/src/server/scripts/Events/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/scripts/Events/childrens_week.cpp b/src/server/scripts/Events/childrens_week.cpp index 9333508276d..4b93f5b4fbb 100644 --- a/src/server/scripts/Events/childrens_week.cpp +++ b/src/server/scripts/Events/childrens_week.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.cpp b/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.cpp index ab7509c7a2b..2b670b467e2 100644 --- a/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.cpp +++ b/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.h b/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.h index be2f526892a..ac20a305f14 100644 --- a/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.h +++ b/src/server/scripts/Kalimdor/BlackfathomDeeps/blackfathom_deeps.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_aku_mai.cpp b/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_aku_mai.cpp index 46008244aa6..40798868ad7 100644 --- a/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_aku_mai.cpp +++ b/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_aku_mai.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_gelihast.cpp b/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_gelihast.cpp index a68558b9c2f..02eed1354b7 100644 --- a/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_gelihast.cpp +++ b/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_gelihast.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_kelris.cpp b/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_kelris.cpp index 4bff75d8efc..2b0e8ccc451 100644 --- a/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_kelris.cpp +++ b/src/server/scripts/Kalimdor/BlackfathomDeeps/boss_kelris.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/BlackfathomDeeps/instance_blackfathom_deeps.cpp b/src/server/scripts/Kalimdor/BlackfathomDeeps/instance_blackfathom_deeps.cpp index 458539f1daa..b0d6e782052 100644 --- a/src/server/scripts/Kalimdor/BlackfathomDeeps/instance_blackfathom_deeps.cpp +++ b/src/server/scripts/Kalimdor/BlackfathomDeeps/instance_blackfathom_deeps.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CMakeLists.txt b/src/server/scripts/Kalimdor/CMakeLists.txt index f74b809c814..2d1b4b49649 100644 --- a/src/server/scripts/Kalimdor/CMakeLists.txt +++ b/src/server/scripts/Kalimdor/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_anetheron.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_anetheron.cpp index d0a9b233454..5009cce48f4 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_anetheron.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_anetheron.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_archimonde.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_archimonde.cpp index e82cadeccb5..b690a0ed019 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_archimonde.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_archimonde.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_azgalor.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_azgalor.cpp index 8bfdee067b2..5616d5fd589 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_azgalor.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_azgalor.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_kazrogal.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_kazrogal.cpp index 12e0ae8d194..04e24d0cbcd 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_kazrogal.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_kazrogal.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_rage_winterchill.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_rage_winterchill.cpp index 18b4dfcc400..3fb4dc554c3 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_rage_winterchill.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/boss_rage_winterchill.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.cpp index 9ad10bdb0f5..011101ec69c 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.h b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.h index 123a2bec400..95ec1341d02 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.h +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjalAI.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjalAI.cpp index 28989a39c2b..6b2142a8095 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjalAI.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjalAI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -417,7 +417,7 @@ void hyjalAI::Reset() } } -void hyjalAI::EnterEvadeMode() +void hyjalAI::EnterEvadeMode(EvadeReason /*why*/) { if (me->GetEntry() != JAINA) me->RemoveAllAuras(); diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjalAI.h b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjalAI.h index c044f55b306..55b85801652 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjalAI.h +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjalAI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -123,7 +123,7 @@ struct hyjalAI : public npc_escortAI void Reset(); // Generically used to reset our variables. Do *not* call in EnterEvadeMode as this may make problems if the raid is still in combat - void EnterEvadeMode(); // Send creature back to spawn location and evade. + void EnterEvadeMode(EvadeReason /*why*/ = EVADE_REASON_OTHER); // Send creature back to spawn location and evade. void EnterCombat(Unit* /*who*/); // Used to reset cooldowns for our spells and to inform the raid that we're under attack diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal_trash.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal_trash.cpp index a92142467e6..56894b769f7 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal_trash.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal_trash.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal_trash.h b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal_trash.h index 963948a0430..5275c07f63a 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal_trash.h +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/hyjal_trash.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp index 3c90add442f..603808c4c0e 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/BattleForMountHyjal/instance_hyjal.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_chrono_lord_epoch.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_chrono_lord_epoch.cpp index ecda065fda9..ab824a1e3e5 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_chrono_lord_epoch.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_chrono_lord_epoch.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_infinite_corruptor.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_infinite_corruptor.cpp index 82eed1d0b94..ae448a154fa 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_infinite_corruptor.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_infinite_corruptor.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_mal_ganis.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_mal_ganis.cpp index c39fbc90795..a902642ac19 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_mal_ganis.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_mal_ganis.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_meathook.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_meathook.cpp index 29e2af1be93..6407640c1af 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_meathook.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_meathook.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_salramm_the_fleshcrafter.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_salramm_the_fleshcrafter.cpp index 9501197fa37..d891987f7c6 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_salramm_the_fleshcrafter.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/boss_salramm_the_fleshcrafter.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.cpp index a73a6b8d998..074ea781838 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.h b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.h index 44d8691bafa..1e10dec1ff5 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.h +++ b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/culling_of_stratholme.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/instance_culling_of_stratholme.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/instance_culling_of_stratholme.cpp index 23259ea2508..17f15cf7f32 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/instance_culling_of_stratholme.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/CullingOfStratholme/instance_culling_of_stratholme.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -43,9 +43,9 @@ Position const GuardianOfTimePos = { 2321.489f, 1268.383f, 132.8507f, 0.418879f DoorData const doorData[] = { - { GO_MALGANIS_GATE_2, DATA_MAL_GANIS, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_EXIT_GATE, DATA_MAL_GANIS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_MALGANIS_GATE_2, DATA_MAL_GANIS, DOOR_TYPE_ROOM }, + { GO_EXIT_GATE, DATA_MAL_GANIS, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_culling_of_stratholme : public InstanceMapScript diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_captain_skarloc.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_captain_skarloc.cpp index b162f332e05..ff184ccf884 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_captain_skarloc.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_captain_skarloc.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_epoch_hunter.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_epoch_hunter.cpp index edc19641242..d1868442662 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_epoch_hunter.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_epoch_hunter.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_leutenant_drake.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_leutenant_drake.cpp index 8f3c5812f72..3a041c7be49 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_leutenant_drake.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/boss_leutenant_drake.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp index 295d6f7f93b..a21fa08c63f 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/instance_old_hillsbrad.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.cpp index 33b8516657a..44cbdec2cb5 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.h b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.h index a6e8fc896c6..f35e223045a 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.h +++ b/src/server/scripts/Kalimdor/CavernsOfTime/EscapeFromDurnholdeKeep/old_hillsbrad.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_aeonus.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_aeonus.cpp index 9418e209bba..8715f3ca0f6 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_aeonus.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_aeonus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_chrono_lord_deja.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_chrono_lord_deja.cpp index 0cc1f371695..f270fd260c4 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_chrono_lord_deja.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_chrono_lord_deja.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_temporus.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_temporus.cpp index 2e067604441..2befdabe550 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_temporus.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/boss_temporus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp index b8d2cbbaa81..2a22de15652 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/instance_the_black_morass.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp index abccbf476e0..193ee55322f 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h index 1d85bf37f2a..cd648e34417 100644 --- a/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h +++ b/src/server/scripts/Kalimdor/CavernsOfTime/TheBlackMorass/the_black_morass.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/DireMaul/instance_dire_maul.cpp b/src/server/scripts/Kalimdor/DireMaul/instance_dire_maul.cpp index 4ba22f391cf..00a622f1319 100644 --- a/src/server/scripts/Kalimdor/DireMaul/instance_dire_maul.cpp +++ b/src/server/scripts/Kalimdor/DireMaul/instance_dire_maul.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/Maraudon/boss_celebras_the_cursed.cpp b/src/server/scripts/Kalimdor/Maraudon/boss_celebras_the_cursed.cpp index 167f823607f..7569946016d 100644 --- a/src/server/scripts/Kalimdor/Maraudon/boss_celebras_the_cursed.cpp +++ b/src/server/scripts/Kalimdor/Maraudon/boss_celebras_the_cursed.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/Maraudon/boss_landslide.cpp b/src/server/scripts/Kalimdor/Maraudon/boss_landslide.cpp index 45d1d00bc70..15388e47135 100644 --- a/src/server/scripts/Kalimdor/Maraudon/boss_landslide.cpp +++ b/src/server/scripts/Kalimdor/Maraudon/boss_landslide.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/Maraudon/boss_noxxion.cpp b/src/server/scripts/Kalimdor/Maraudon/boss_noxxion.cpp index 00a2c40fd31..150458aec6d 100644 --- a/src/server/scripts/Kalimdor/Maraudon/boss_noxxion.cpp +++ b/src/server/scripts/Kalimdor/Maraudon/boss_noxxion.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/Maraudon/boss_princess_theradras.cpp b/src/server/scripts/Kalimdor/Maraudon/boss_princess_theradras.cpp index be610b0f20b..9d2fc27f7a0 100644 --- a/src/server/scripts/Kalimdor/Maraudon/boss_princess_theradras.cpp +++ b/src/server/scripts/Kalimdor/Maraudon/boss_princess_theradras.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/Maraudon/instance_maraudon.cpp b/src/server/scripts/Kalimdor/Maraudon/instance_maraudon.cpp index f5739901a81..8b3c2857ad8 100644 --- a/src/server/scripts/Kalimdor/Maraudon/instance_maraudon.cpp +++ b/src/server/scripts/Kalimdor/Maraudon/instance_maraudon.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/OnyxiasLair/boss_onyxia.cpp b/src/server/scripts/Kalimdor/OnyxiasLair/boss_onyxia.cpp index 65d6565ad9a..7da15b1fdce 100644 --- a/src/server/scripts/Kalimdor/OnyxiasLair/boss_onyxia.cpp +++ b/src/server/scripts/Kalimdor/OnyxiasLair/boss_onyxia.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -316,20 +316,9 @@ public: MovePoint = iTemp; } - bool CheckInRoom() override - { - if (me->GetDistance2d(me->GetHomePosition().GetPositionX(), me->GetHomePosition().GetPositionY()) > 95.0f) - { - EnterEvadeMode(); - return false; - } - - return true; - } - void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; //Common to PHASE_START && PHASE_END diff --git a/src/server/scripts/Kalimdor/OnyxiasLair/instance_onyxias_lair.cpp b/src/server/scripts/Kalimdor/OnyxiasLair/instance_onyxias_lair.cpp index eb7de8c43ff..1f4bfb1c413 100644 --- a/src/server/scripts/Kalimdor/OnyxiasLair/instance_onyxias_lair.cpp +++ b/src/server/scripts/Kalimdor/OnyxiasLair/instance_onyxias_lair.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -31,6 +31,11 @@ EndScriptData */ #include "onyxias_lair.h" #include "TemporarySummon.h" +BossBoundaryData const boundaries = +{ + { DATA_ONYXIA, new CircleBoundary(Position(-34.3697f, -212.3296f), 100.0) } +}; + class instance_onyxias_lair : public InstanceMapScript { public: @@ -47,6 +52,7 @@ public: { SetHeaders(DataHeader); SetBossNumber(EncounterCount); + LoadBossBoundaries(boundaries); onyxiaLiftoffTimer = 0; manyWhelpsCounter = 0; diff --git a/src/server/scripts/Kalimdor/OnyxiasLair/onyxias_lair.h b/src/server/scripts/Kalimdor/OnyxiasLair/onyxias_lair.h index 049819f9f76..a2ee396a156 100644 --- a/src/server/scripts/Kalimdor/OnyxiasLair/onyxias_lair.h +++ b/src/server/scripts/Kalimdor/OnyxiasLair/onyxias_lair.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RagefireChasm/instance_ragefire_chasm.cpp b/src/server/scripts/Kalimdor/RagefireChasm/instance_ragefire_chasm.cpp index e6974a4f2e0..2352fe18cc8 100644 --- a/src/server/scripts/Kalimdor/RagefireChasm/instance_ragefire_chasm.cpp +++ b/src/server/scripts/Kalimdor/RagefireChasm/instance_ragefire_chasm.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RazorfenDowns/boss_amnennar_the_coldbringer.cpp b/src/server/scripts/Kalimdor/RazorfenDowns/boss_amnennar_the_coldbringer.cpp index cec9a6b558e..32218742aeb 100644 --- a/src/server/scripts/Kalimdor/RazorfenDowns/boss_amnennar_the_coldbringer.cpp +++ b/src/server/scripts/Kalimdor/RazorfenDowns/boss_amnennar_the_coldbringer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RazorfenDowns/boss_glutton.cpp b/src/server/scripts/Kalimdor/RazorfenDowns/boss_glutton.cpp index 6fd6b115c0b..66f2f342b66 100644 --- a/src/server/scripts/Kalimdor/RazorfenDowns/boss_glutton.cpp +++ b/src/server/scripts/Kalimdor/RazorfenDowns/boss_glutton.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RazorfenDowns/boss_mordresh_fire_eye.cpp b/src/server/scripts/Kalimdor/RazorfenDowns/boss_mordresh_fire_eye.cpp index dfb3d1882b8..0b9bdb87bc5 100644 --- a/src/server/scripts/Kalimdor/RazorfenDowns/boss_mordresh_fire_eye.cpp +++ b/src/server/scripts/Kalimdor/RazorfenDowns/boss_mordresh_fire_eye.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RazorfenDowns/boss_tuten_kash.cpp b/src/server/scripts/Kalimdor/RazorfenDowns/boss_tuten_kash.cpp index 73f93fa9ae7..b68ccf9a692 100644 --- a/src/server/scripts/Kalimdor/RazorfenDowns/boss_tuten_kash.cpp +++ b/src/server/scripts/Kalimdor/RazorfenDowns/boss_tuten_kash.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RazorfenDowns/instance_razorfen_downs.cpp b/src/server/scripts/Kalimdor/RazorfenDowns/instance_razorfen_downs.cpp index 6347da44991..f8e107c0c59 100644 --- a/src/server/scripts/Kalimdor/RazorfenDowns/instance_razorfen_downs.cpp +++ b/src/server/scripts/Kalimdor/RazorfenDowns/instance_razorfen_downs.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.cpp b/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.cpp index d6908384a71..b579f9fc608 100644 --- a/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.cpp +++ b/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.h b/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.h index cb1b56c267a..6108d135694 100644 --- a/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.h +++ b/src/server/scripts/Kalimdor/RazorfenDowns/razorfen_downs.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RazorfenKraul/instance_razorfen_kraul.cpp b/src/server/scripts/Kalimdor/RazorfenKraul/instance_razorfen_kraul.cpp index b57d1b78de0..bea6555a416 100644 --- a/src/server/scripts/Kalimdor/RazorfenKraul/instance_razorfen_kraul.cpp +++ b/src/server/scripts/Kalimdor/RazorfenKraul/instance_razorfen_kraul.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/RazorfenKraul/razorfen_kraul.cpp b/src/server/scripts/Kalimdor/RazorfenKraul/razorfen_kraul.cpp index f4a7e1f4185..ed683cc4af9 100644 --- a/src/server/scripts/Kalimdor/RazorfenKraul/razorfen_kraul.cpp +++ b/src/server/scripts/Kalimdor/RazorfenKraul/razorfen_kraul.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2013 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/RazorfenKraul/razorfen_kraul.h b/src/server/scripts/Kalimdor/RazorfenKraul/razorfen_kraul.h index eb9115f19c7..32f5c43ae9b 100644 --- a/src/server/scripts/Kalimdor/RazorfenKraul/razorfen_kraul.h +++ b/src/server/scripts/Kalimdor/RazorfenKraul/razorfen_kraul.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_ayamiss.cpp b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_ayamiss.cpp index beada0509c9..fa8eb2b706e 100644 --- a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_ayamiss.cpp +++ b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_ayamiss.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -129,10 +129,10 @@ class boss_ayamiss : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { me->ClearUnitState(UNIT_STATE_ROOT); - BossAI::EnterEvadeMode(); + BossAI::EnterEvadeMode(why); } void EnterCombat(Unit* attacker) override diff --git a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_buru.cpp b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_buru.cpp index 9dedd9da3ba..8a564c4974c 100644 --- a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_buru.cpp +++ b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_buru.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -72,9 +72,9 @@ class boss_buru : public CreatureScript _phase = 0; } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - BossAI::EnterEvadeMode(); + BossAI::EnterEvadeMode(why); for (ObjectGuid eggGuid : Eggs) if (Creature* egg = me->GetMap()->GetCreature(eggGuid)) diff --git a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_kurinnaxx.cpp b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_kurinnaxx.cpp index 2556530497e..69ae561e748 100644 --- a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_kurinnaxx.cpp +++ b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_kurinnaxx.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_moam.cpp b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_moam.cpp index 8ae1959a0d9..7748da21598 100644 --- a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_moam.cpp +++ b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_moam.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_ossirian.cpp b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_ossirian.cpp index 8ccc5f0b4ce..b192ff8ef4d 100644 --- a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_ossirian.cpp +++ b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_ossirian.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -163,11 +163,11 @@ class boss_ossirian : public CreatureScript Talk(SAY_SLAY); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { Cleanup(); summons.DespawnAll(); - BossAI::EnterEvadeMode(); + BossAI::EnterEvadeMode(why); } void JustDied(Unit* /*killer*/) override diff --git a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_rajaxx.cpp b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_rajaxx.cpp index f421033419a..73a6234ceb6 100644 --- a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_rajaxx.cpp +++ b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/boss_rajaxx.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/instance_ruins_of_ahnqiraj.cpp b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/instance_ruins_of_ahnqiraj.cpp index d16a86f350f..106d9d0515a 100644 --- a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/instance_ruins_of_ahnqiraj.cpp +++ b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/instance_ruins_of_ahnqiraj.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/ruins_of_ahnqiraj.h b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/ruins_of_ahnqiraj.h index 1d9440aadc1..3455c6eaae6 100644 --- a/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/ruins_of_ahnqiraj.h +++ b/src/server/scripts/Kalimdor/RuinsOfAhnQiraj/ruins_of_ahnqiraj.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_bug_trio.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_bug_trio.cpp index 9673ccf5165..06c4b46f386 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_bug_trio.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_bug_trio.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_cthun.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_cthun.cpp index 6016893a785..e0241807759 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_cthun.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_cthun.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_fankriss.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_fankriss.cpp index c086489cb1a..2e67d1280f2 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_fankriss.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_fankriss.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_huhuran.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_huhuran.cpp index dd4be9ebc6d..3dc33103e04 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_huhuran.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_huhuran.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_ouro.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_ouro.cpp index 3bbcdfdc7ad..fab2e8b7c70 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_ouro.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_ouro.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_sartura.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_sartura.cpp index 2d9af5792ee..cc7aca1a76a 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_sartura.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_sartura.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_skeram.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_skeram.cpp index 05ec05873f5..de425fbfce1 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_skeram.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_skeram.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -77,9 +77,9 @@ class boss_skeram : public CreatureScript Talk(SAY_SLAY); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); if (me->IsSummon()) ((TempSummon*)me)->UnSummon(); } diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_twinemperors.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_twinemperors.cpp index b39ce0307a5..e8bd52a809c 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_twinemperors.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_twinemperors.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_viscidus.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_viscidus.cpp index 5d9c5847cbc..9f4c2da91e2 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_viscidus.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/boss_viscidus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -190,10 +190,10 @@ class boss_viscidus : public CreatureScript events.ScheduleEvent(EVENT_POISON_SHOCK, urand(7000, 12000)); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { summons.DespawnAll(); - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); } void JustDied(Unit* /*killer*/) override diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp index 46036765a73..8d18a0cd436 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/instance_temple_of_ahnqiraj.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/mob_anubisath_sentinel.cpp b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/mob_anubisath_sentinel.cpp index a06242b4b1d..3bab621bfc2 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/mob_anubisath_sentinel.cpp +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/mob_anubisath_sentinel.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h index 49b817a03c9..fa1de26ecae 100644 --- a/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h +++ b/src/server/scripts/Kalimdor/TempleOfAhnQiraj/temple_of_ahnqiraj.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/WailingCaverns/instance_wailing_caverns.cpp b/src/server/scripts/Kalimdor/WailingCaverns/instance_wailing_caverns.cpp index 49a3b704138..ddcdb4fbd53 100644 --- a/src/server/scripts/Kalimdor/WailingCaverns/instance_wailing_caverns.cpp +++ b/src/server/scripts/Kalimdor/WailingCaverns/instance_wailing_caverns.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.cpp b/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.cpp index 126f79b3b93..29a754d5895 100644 --- a/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.cpp +++ b/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -58,6 +58,10 @@ enum Enums SAY_FAREWELL = 5, SAY_ATTACKED = 11, + GOSSIP_OPTION_LET_EVENT_BEGIN = 201, + NPC_TEXT_NARALEX_SLEEPS_AGAIN = 698, + NPC_TEXT_FANGLORDS_ARE_DEAD = 699, + SPELL_MARK_OF_THE_WILD_RANK_2 = 5232, SPELL_SERPENTINE_CLEANSING = 6270, SPELL_NARALEXS_AWAKENING = 6271, @@ -70,10 +74,6 @@ enum Enums NPC_MUTANUS_THE_DEVOURER = 3654, }; -#define GOSSIP_ID_START_1 698 //Naralex sleeps again! -#define GOSSIP_ID_START_2 699 //The fanglords are dead! -#define GOSSIP_ITEM_NARALEX "Let the event begin!" - class npc_disciple_of_naralex : public CreatureScript { public: @@ -116,8 +116,8 @@ public: if ((instance->GetData(TYPE_LORD_COBRAHN) == DONE) && (instance->GetData(TYPE_LORD_PYTHAS) == DONE) && (instance->GetData(TYPE_LADY_ANACONDRA) == DONE) && (instance->GetData(TYPE_LORD_SERPENTIS) == DONE)) { - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_ITEM_NARALEX, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); - player->SEND_GOSSIP_MENU(GOSSIP_ID_START_2, creature->GetGUID()); + player->ADD_GOSSIP_ITEM_DB(GOSSIP_OPTION_LET_EVENT_BEGIN, 0, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); + player->SEND_GOSSIP_MENU(NPC_TEXT_FANGLORDS_ARE_DEAD, creature->GetGUID()); if (!instance->GetData(TYPE_NARALEX_YELLED)) { @@ -127,7 +127,7 @@ public: } else { - player->SEND_GOSSIP_MENU(GOSSIP_ID_START_1, creature->GetGUID()); + player->SEND_GOSSIP_MENU(NPC_TEXT_NARALEX_SLEEPS_AGAIN, creature->GetGUID()); } } return true; diff --git a/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.h b/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.h index 99b108aac88..7f77e12eeaf 100644 --- a/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.h +++ b/src/server/scripts/Kalimdor/WailingCaverns/wailing_caverns.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/ZulFarrak/boss_zum_rah.cpp b/src/server/scripts/Kalimdor/ZulFarrak/boss_zum_rah.cpp index a0aeed89747..cfb7b9090a5 100644 --- a/src/server/scripts/Kalimdor/ZulFarrak/boss_zum_rah.cpp +++ b/src/server/scripts/Kalimdor/ZulFarrak/boss_zum_rah.cpp @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/ZulFarrak/instance_zulfarrak.cpp b/src/server/scripts/Kalimdor/ZulFarrak/instance_zulfarrak.cpp index 7bd197774bc..e6e5a7ce169 100644 --- a/src/server/scripts/Kalimdor/ZulFarrak/instance_zulfarrak.cpp +++ b/src/server/scripts/Kalimdor/ZulFarrak/instance_zulfarrak.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.cpp b/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.cpp index 025ba8d6bb2..440d34babb1 100644 --- a/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.cpp +++ b/src/server/scripts/Kalimdor/ZulFarrak/zulfarrak.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/boss_azuregos.cpp b/src/server/scripts/Kalimdor/boss_azuregos.cpp index b95b2fa7558..6fd1929865c 100644 --- a/src/server/scripts/Kalimdor/boss_azuregos.cpp +++ b/src/server/scripts/Kalimdor/boss_azuregos.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/zone_ashenvale.cpp b/src/server/scripts/Kalimdor/zone_ashenvale.cpp index b8e6bfb85e8..50730507b8f 100644 --- a/src/server/scripts/Kalimdor/zone_ashenvale.cpp +++ b/src/server/scripts/Kalimdor/zone_ashenvale.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -31,6 +31,7 @@ EndContentData */ #include "ScriptedCreature.h" #include "ScriptedEscortAI.h" #include "Player.h" +#include "SpellScript.h" /*#### # npc_ruul_snowhoof @@ -344,9 +345,42 @@ class go_naga_brazier : public GameObjectScript } }; +enum KingoftheFoulwealdMisc +{ + GO_BANNER = 178205 +}; + +class spell_destroy_karangs_banner : public SpellScriptLoader +{ + public: + spell_destroy_karangs_banner() : SpellScriptLoader("spell_destroy_karangs_banner") { } + + class spell_destroy_karangs_banner_SpellScript : public SpellScript + { + PrepareSpellScript(spell_destroy_karangs_banner_SpellScript); + + void HandleAfterCast() + { + if (GameObject* banner = GetCaster()->FindNearestGameObject(GO_BANNER, GetSpellInfo()->GetMaxRange(true))) + banner->Delete(); + } + + void Register() override + { + AfterCast += SpellCastFn(spell_destroy_karangs_banner_SpellScript::HandleAfterCast); + } + }; + + SpellScript* GetSpellScript() const override + { + return new spell_destroy_karangs_banner_SpellScript(); + } +}; + void AddSC_ashenvale() { new npc_ruul_snowhoof(); new npc_muglash(); new go_naga_brazier(); + new spell_destroy_karangs_banner(); } diff --git a/src/server/scripts/Kalimdor/zone_azshara.cpp b/src/server/scripts/Kalimdor/zone_azshara.cpp index d6aa943123b..1ed95c16a0d 100644 --- a/src/server/scripts/Kalimdor/zone_azshara.cpp +++ b/src/server/scripts/Kalimdor/zone_azshara.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_azuremyst_isle.cpp b/src/server/scripts/Kalimdor/zone_azuremyst_isle.cpp index 52e32d3d37c..65a2a14c52a 100644 --- a/src/server/scripts/Kalimdor/zone_azuremyst_isle.cpp +++ b/src/server/scripts/Kalimdor/zone_azuremyst_isle.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_bloodmyst_isle.cpp b/src/server/scripts/Kalimdor/zone_bloodmyst_isle.cpp index 0ae870b27ee..273e81d83c0 100644 --- a/src/server/scripts/Kalimdor/zone_bloodmyst_isle.cpp +++ b/src/server/scripts/Kalimdor/zone_bloodmyst_isle.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_darkshore.cpp b/src/server/scripts/Kalimdor/zone_darkshore.cpp index 4cf5cbc9567..b1399fae0b4 100644 --- a/src/server/scripts/Kalimdor/zone_darkshore.cpp +++ b/src/server/scripts/Kalimdor/zone_darkshore.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_desolace.cpp b/src/server/scripts/Kalimdor/zone_desolace.cpp index bb17de4fd6a..621e0b0a585 100644 --- a/src/server/scripts/Kalimdor/zone_desolace.cpp +++ b/src/server/scripts/Kalimdor/zone_desolace.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_durotar.cpp b/src/server/scripts/Kalimdor/zone_durotar.cpp index 2d1a10265c8..05caf9cca3a 100644 --- a/src/server/scripts/Kalimdor/zone_durotar.cpp +++ b/src/server/scripts/Kalimdor/zone_durotar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Kalimdor/zone_dustwallow_marsh.cpp b/src/server/scripts/Kalimdor/zone_dustwallow_marsh.cpp index fba0956ccfc..9df9f0b604a 100644 --- a/src/server/scripts/Kalimdor/zone_dustwallow_marsh.cpp +++ b/src/server/scripts/Kalimdor/zone_dustwallow_marsh.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_felwood.cpp b/src/server/scripts/Kalimdor/zone_felwood.cpp index 91b9ce08010..bce9d62105c 100644 --- a/src/server/scripts/Kalimdor/zone_felwood.cpp +++ b/src/server/scripts/Kalimdor/zone_felwood.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_feralas.cpp b/src/server/scripts/Kalimdor/zone_feralas.cpp index 20cc0ef703b..3e67a95b503 100644 --- a/src/server/scripts/Kalimdor/zone_feralas.cpp +++ b/src/server/scripts/Kalimdor/zone_feralas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_moonglade.cpp b/src/server/scripts/Kalimdor/zone_moonglade.cpp index c7decd3e286..99a209b5f0a 100644 --- a/src/server/scripts/Kalimdor/zone_moonglade.cpp +++ b/src/server/scripts/Kalimdor/zone_moonglade.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -25,7 +25,6 @@ EndScriptData */ /* ContentData npc_bunthen_plainswind -npc_great_bear_spirit npc_silva_filnaveth npc_clintar_spirit npc_clintar_dreamwalker @@ -305,7 +304,7 @@ public: } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { Player* player = ObjectAccessor::GetPlayer(*me, PlayerGUID); if (player && player->IsInCombat() && player->getAttackerForHelper()) @@ -313,7 +312,7 @@ public: AttackStart(player->getAttackerForHelper()); return; } - npc_escortAI::EnterEvadeMode(); + npc_escortAI::EnterEvadeMode(why); } void StartEvent(Player* player) diff --git a/src/server/scripts/Kalimdor/zone_orgrimmar.cpp b/src/server/scripts/Kalimdor/zone_orgrimmar.cpp index bf9b736f02f..ac26aa1f811 100644 --- a/src/server/scripts/Kalimdor/zone_orgrimmar.cpp +++ b/src/server/scripts/Kalimdor/zone_orgrimmar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_silithus.cpp b/src/server/scripts/Kalimdor/zone_silithus.cpp index 34f3ff535c0..cc285ab991e 100644 --- a/src/server/scripts/Kalimdor/zone_silithus.cpp +++ b/src/server/scripts/Kalimdor/zone_silithus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_stonetalon_mountains.cpp b/src/server/scripts/Kalimdor/zone_stonetalon_mountains.cpp index 32b7967401a..6e374fe2c59 100644 --- a/src/server/scripts/Kalimdor/zone_stonetalon_mountains.cpp +++ b/src/server/scripts/Kalimdor/zone_stonetalon_mountains.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_tanaris.cpp b/src/server/scripts/Kalimdor/zone_tanaris.cpp index efd47bf3e4b..22b4c86cbcd 100644 --- a/src/server/scripts/Kalimdor/zone_tanaris.cpp +++ b/src/server/scripts/Kalimdor/zone_tanaris.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_the_barrens.cpp b/src/server/scripts/Kalimdor/zone_the_barrens.cpp index bb54ae08d77..852cd62c277 100644 --- a/src/server/scripts/Kalimdor/zone_the_barrens.cpp +++ b/src/server/scripts/Kalimdor/zone_the_barrens.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_thousand_needles.cpp b/src/server/scripts/Kalimdor/zone_thousand_needles.cpp index 984d4fbba2c..85c3a621239 100644 --- a/src/server/scripts/Kalimdor/zone_thousand_needles.cpp +++ b/src/server/scripts/Kalimdor/zone_thousand_needles.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_thunder_bluff.cpp b/src/server/scripts/Kalimdor/zone_thunder_bluff.cpp index 7ebbb52bcd5..02ea032c0c3 100644 --- a/src/server/scripts/Kalimdor/zone_thunder_bluff.cpp +++ b/src/server/scripts/Kalimdor/zone_thunder_bluff.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_ungoro_crater.cpp b/src/server/scripts/Kalimdor/zone_ungoro_crater.cpp index d8ead179c19..9cc7aa17525 100644 --- a/src/server/scripts/Kalimdor/zone_ungoro_crater.cpp +++ b/src/server/scripts/Kalimdor/zone_ungoro_crater.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Kalimdor/zone_winterspring.cpp b/src/server/scripts/Kalimdor/zone_winterspring.cpp index 53eadd4a38b..dcbc016e18b 100644 --- a/src/server/scripts/Kalimdor/zone_winterspring.cpp +++ b/src/server/scripts/Kalimdor/zone_winterspring.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/ahnkahet.h b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/ahnkahet.h index fafe363e3f2..4d1be62554c 100644 --- a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/ahnkahet.h +++ b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/ahnkahet.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_amanitar.cpp b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_amanitar.cpp index 0dc52c29ced..d7c5731433b 100644 --- a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_amanitar.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_amanitar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_elder_nadox.cpp b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_elder_nadox.cpp index 61a48667c33..a1846094b4d 100644 --- a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_elder_nadox.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_elder_nadox.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_herald_volazj.cpp b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_herald_volazj.cpp index d8ebfbbd743..2e9c0698a0a 100644 --- a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_herald_volazj.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_herald_volazj.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_jedoga_shadowseeker.cpp b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_jedoga_shadowseeker.cpp index 240e8a7b957..ab09dd45710 100644 --- a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_jedoga_shadowseeker.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_jedoga_shadowseeker.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_prince_taldaram.cpp b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_prince_taldaram.cpp index bb190e94cc8..e25f64f61aa 100644 --- a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_prince_taldaram.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/boss_prince_taldaram.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/instance_ahnkahet.cpp b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/instance_ahnkahet.cpp index c482a156a91..36a094d2725 100644 --- a/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/instance_ahnkahet.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/Ahnkahet/instance_ahnkahet.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -22,8 +22,8 @@ DoorData const doorData[] = { - { GO_PRINCE_TALDARAM_GATE, DATA_PRINCE_TALDARAM, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_PRINCE_TALDARAM_GATE, DATA_PRINCE_TALDARAM, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_ahnkahet : public InstanceMapScript diff --git a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/azjol_nerub.h b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/azjol_nerub.h index f91ad2eb276..cc454882154 100644 --- a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/azjol_nerub.h +++ b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/azjol_nerub.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_anubarak.cpp b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_anubarak.cpp index 3b6e88b7c20..16cfb30e2dc 100644 --- a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_anubarak.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_anubarak.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp index 13c37f02adf..ff2588d204e 100644 --- a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_hadronox.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_krikthir_the_gatewatcher.cpp b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_krikthir_the_gatewatcher.cpp index 516bf186361..8c977e892df 100644 --- a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_krikthir_the_gatewatcher.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/boss_krikthir_the_gatewatcher.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/instance_azjol_nerub.cpp b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/instance_azjol_nerub.cpp index 467c6c2c11d..88003680ec7 100644 --- a/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/instance_azjol_nerub.cpp +++ b/src/server/scripts/Northrend/AzjolNerub/AzjolNerub/instance_azjol_nerub.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -21,11 +21,11 @@ DoorData const doorData[] = { - { GO_KRIKTHIR_DOOR, DATA_KRIKTHIR_THE_GATEWATCHER, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_ANUBARAK_DOOR_1, DATA_ANUBARAK, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_ANUBARAK_DOOR_2, DATA_ANUBARAK, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_ANUBARAK_DOOR_3, DATA_ANUBARAK, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_KRIKTHIR_DOOR, DATA_KRIKTHIR_THE_GATEWATCHER, DOOR_TYPE_PASSAGE }, + { GO_ANUBARAK_DOOR_1, DATA_ANUBARAK, DOOR_TYPE_ROOM }, + { GO_ANUBARAK_DOOR_2, DATA_ANUBARAK, DOOR_TYPE_ROOM }, + { GO_ANUBARAK_DOOR_3, DATA_ANUBARAK, DOOR_TYPE_ROOM }, + { 0, 0, DOOR_TYPE_ROOM } // END }; ObjectData const creatureData[] = diff --git a/src/server/scripts/Northrend/CMakeLists.txt b/src/server/scripts/Northrend/CMakeLists.txt index 66d9021223f..1dc453ad416 100644 --- a/src/server/scripts/Northrend/CMakeLists.txt +++ b/src/server/scripts/Northrend/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp index 3382eec6850..f0b5a02e66e 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/boss_sartharion.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -501,8 +501,6 @@ public: } DoMeleeAttackIfReady(); - - EnterEvadeIfOutOfCombatArea(diff); } private: diff --git a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/instance_obsidian_sanctum.cpp b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/instance_obsidian_sanctum.cpp index 63969eac354..b54010b386c 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/instance_obsidian_sanctum.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/instance_obsidian_sanctum.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -23,6 +23,11 @@ 0 - Sartharion */ +BossBoundaryData const boundaries = +{ + { DATA_SARTHARION, new RectangleBoundary(3218.86f, 3275.69f, 484.68f, 572.4f) } +}; + class instance_obsidian_sanctum : public InstanceMapScript { public: @@ -33,6 +38,8 @@ public: instance_obsidian_sanctum_InstanceMapScript(Map* map) : InstanceScript(map) { SetHeaders(DataHeader); + SetBossNumber(EncounterCount); + LoadBossBoundaries(boundaries); } void OnCreatureCreate(Creature* creature) override diff --git a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.cpp b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.cpp index 3b12104a90b..8c1e9197fe8 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.h b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.h index 7cb1212f75f..62c1ea96d9e 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.h +++ b/src/server/scripts/Northrend/ChamberOfAspects/ObsidianSanctum/obsidian_sanctum.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_baltharus_the_warborn.cpp b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_baltharus_the_warborn.cpp index 6ddab02487a..e53c50f0439 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_baltharus_the_warborn.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_baltharus_the_warborn.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_general_zarithrian.cpp b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_general_zarithrian.cpp index eb004505bab..84d7d92acfe 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_general_zarithrian.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_general_zarithrian.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -98,7 +98,7 @@ class boss_general_zarithrian : public CreatureScript { _Reset(); if (instance->GetBossState(DATA_SAVIANA_RAGEFIRE) == DONE && instance->GetBossState(DATA_BALTHARUS_THE_WARBORN) == DONE) - me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_IMMUNE_TO_PC); + me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_IMMUNE_TO_PC | UNIT_FLAG_NOT_SELECTABLE); } void EnterCombat(Unit* /*who*/) override @@ -135,9 +135,9 @@ class boss_general_zarithrian : public CreatureScript Talk(SAY_KILL); } - bool CanAIAttack(Unit const* /*target*/) const override + bool CanAIAttack(Unit const* target) const override { - return (instance->GetBossState(DATA_SAVIANA_RAGEFIRE) == DONE && instance->GetBossState(DATA_BALTHARUS_THE_WARBORN) == DONE); + return (instance->GetBossState(DATA_SAVIANA_RAGEFIRE) == DONE && instance->GetBossState(DATA_BALTHARUS_THE_WARBORN) == DONE && BossAI::CanAIAttack(target)); } void UpdateAI(uint32 diff) override @@ -145,13 +145,6 @@ class boss_general_zarithrian : public CreatureScript if (!UpdateVictim()) return; - // Can't use room boundary here, the gameobject is spawned at the same position as the boss. This is just as good anyway. - if (me->GetPositionX() > 3058.0f) - { - EnterEvadeMode(); - return; - } - events.Update(diff); if (me->HasUnitState(UNIT_STATE_CASTING)) @@ -228,7 +221,7 @@ class npc_onyx_flamecaller : public CreatureScript _events.ScheduleEvent(EVENT_LAVA_GOUT, 5000); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { // Prevent EvadeMode } diff --git a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_halion.cpp b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_halion.cpp index 6bc49de5319..7b8ca41772f 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_halion.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_halion.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -257,21 +257,9 @@ struct generic_halionAI : public BossAI } } - bool CheckInRoom() override - { - // Rough radius, it is not an exactly perfect circle - if (me->GetDistance2d(HalionControllerSpawnPos.GetPositionX(), HalionControllerSpawnPos.GetPositionY()) > 48.5f) - { - if (Creature* controller = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_HALION_CONTROLLER))) - controller->AI()->EnterEvadeMode(); - return false; - } - return true; - } - void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom() || me->HasUnitState(UNIT_STATE_CASTING)) + if (!UpdateVictim() || me->HasUnitState(UNIT_STATE_CASTING)) return; events.Update(diff); @@ -324,11 +312,15 @@ class boss_halion : public CreatureScript me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { + if (why == EVADE_REASON_BOUNDARY) + if (Creature* controller = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_HALION_CONTROLLER))) + controller->AI()->EnterEvadeMode(); + // Phase 1: We always can evade. Phase 2 & 3: We can evade if and only if the controller tells us to. if (events.IsInPhase(PHASE_ONE) || _canEvade) - generic_halionAI::EnterEvadeMode(); + generic_halionAI::EnterEvadeMode(why); } void EnterCombat(Unit* who) override @@ -498,7 +490,7 @@ class boss_twilight_halion : public CreatureScript } // Never evade - void EnterEvadeMode() override { } + void EnterEvadeMode(EvadeReason /*why*/) override { } void KilledUnit(Unit* victim) override { @@ -1023,7 +1015,7 @@ class npc_meteor_strike_initial : public CreatureScript } void UpdateAI(uint32 /*diff*/) override { } - void EnterEvadeMode() override { } + void EnterEvadeMode(EvadeReason /*why*/) override { } private: InstanceScript* _instance; std::list<Creature*> _meteorList; @@ -1149,7 +1141,7 @@ class npc_meteor_strike_flame : public CreatureScript flame->AI()->SetGUID(_rootOwnerGuid); } - void EnterEvadeMode() override { } + void EnterEvadeMode(EvadeReason /*why*/) override { } private: InstanceScript* _instance; diff --git a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_saviana_ragefire.cpp b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_saviana_ragefire.cpp index fdca8058578..b6c6a4d96d5 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_saviana_ragefire.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/boss_saviana_ragefire.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp index 3130bf20a0c..a6cd8362db3 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/instance_ruby_sanctum.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -23,10 +23,16 @@ #include "WorldPacket.h" #include "ruby_sanctum.h" +BossBoundaryData const boundaries = +{ + { DATA_GENERAL_ZARITHRIAN, new EllipseBoundary(Position(3013.409f, 529.492f), 45.0, 100.0) }, + { DATA_HALION, new CircleBoundary(Position(3156.037f, 533.2656f), 48.5) } +}; + DoorData const doorData[] = { - {GO_FIRE_FIELD, DATA_BALTHARUS_THE_WARBORN, DOOR_TYPE_PASSAGE, BOUNDARY_E }, - {0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE}, + {GO_FIRE_FIELD, DATA_BALTHARUS_THE_WARBORN, DOOR_TYPE_PASSAGE }, + {0, 0, DOOR_TYPE_ROOM }, }; class instance_ruby_sanctum : public InstanceMapScript @@ -40,6 +46,7 @@ class instance_ruby_sanctum : public InstanceMapScript { SetHeaders(DataHeader); SetBossNumber(EncounterCount); + LoadBossBoundaries(boundaries); LoadDoorData(doorData); BaltharusSharedHealth = 0; } diff --git a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.cpp b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.cpp index 07f295c6810..ae4a5e2a69a 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.cpp +++ b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.h b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.h index 7daa2f68d87..69c27a22ea0 100644 --- a/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.h +++ b/src/server/scripts/Northrend/ChamberOfAspects/RubySanctum/ruby_sanctum.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_argent_challenge.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_argent_challenge.cpp index 6d70e56edbb..15d1535fe95 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_argent_challenge.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_argent_challenge.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_black_knight.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_black_knight.cpp index e375a0acfd5..c10eb0f8a80 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_black_knight.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_black_knight.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_grand_champions.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_grand_champions.cpp index 512016c6eeb..154f14d1fa8 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_grand_champions.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/boss_grand_champions.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/instance_trial_of_the_champion.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/instance_trial_of_the_champion.cpp index cacef991ea6..00900d440c9 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/instance_trial_of_the_champion.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/instance_trial_of_the_champion.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.cpp index 96dc3725ea5..4ee8dcfb74c 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.h b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.h index 836743626e5..980da30321b 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.h +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheChampion/trial_of_the_champion.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_anubarak_trial.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_anubarak_trial.cpp index 05f608d28ec..c89510211b9 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_anubarak_trial.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_anubarak_trial.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2010 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_faction_champions.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_faction_champions.cpp index f50a26eae23..6c1b516c7de 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_faction_champions.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_faction_champions.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -461,13 +461,13 @@ class boss_toc_champion_controller : public CreatureScript if (playerTeam == ALLIANCE) { temp->SetHomePosition(vChampionJumpTarget[pos].GetPositionX(), vChampionJumpTarget[pos].GetPositionY(), vChampionJumpTarget[pos].GetPositionZ(), 0); - temp->GetMotionMaster()->MoveJump(vChampionJumpTarget[pos].GetPositionX(), vChampionJumpTarget[pos].GetPositionY(), vChampionJumpTarget[pos].GetPositionZ(), 20.0f, 20.0f); + temp->GetMotionMaster()->MoveJump(vChampionJumpTarget[pos], 20.0f, 20.0f); temp->SetOrientation(0); } else { temp->SetHomePosition((ToCCommonLoc[1].GetPositionX()*2)-vChampionJumpTarget[pos].GetPositionX(), vChampionJumpTarget[pos].GetPositionY(), vChampionJumpTarget[pos].GetPositionZ(), 3); - temp->GetMotionMaster()->MoveJump((ToCCommonLoc[1].GetPositionX()*2)-vChampionJumpTarget[pos].GetPositionX(), vChampionJumpTarget[pos].GetPositionY(), vChampionJumpTarget[pos].GetPositionZ(), 20.0f, 20.0f); + temp->GetMotionMaster()->MoveJump((ToCCommonLoc[1].GetPositionX() * 2) - vChampionJumpTarget[pos].GetPositionX(), vChampionJumpTarget[pos].GetPositionY(), vChampionJumpTarget[pos].GetPositionZ(), vChampionJumpTarget[pos].GetOrientation(), 20.0f, 20.0f); temp->SetOrientation(3); } } diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_lord_jaraxxus.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_lord_jaraxxus.cpp index 10090cbf9af..2fba0c2af42 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_lord_jaraxxus.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_lord_jaraxxus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2010 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_northrend_beasts.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_northrend_beasts.cpp index c56a49cb92c..e3720503d0a 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_northrend_beasts.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_northrend_beasts.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2010 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -167,10 +167,10 @@ class boss_gormok : public CreatureScript summons.DespawnAll(); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { instance->DoUseDoorOrButton(instance->GetGuidData(GO_MAIN_GATE_DOOR)); - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); } void MovementInform(uint32 type, uint32 pointId) override @@ -309,11 +309,6 @@ class npc_snobold_vassal : public CreatureScript me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_NOT_SELECTABLE); } - void EnterEvadeMode() override - { - ScriptedAI::EnterEvadeMode(); - } - void EnterCombat(Unit* who) override { _targetGUID = who->GetGUID(); @@ -395,7 +390,7 @@ class npc_snobold_vassal : public CreatureScript else if (Unit* target2 = SelectTarget(SELECT_TARGET_RANDOM, 0, 0.0f, true)) { _targetGUID = target2->GetGUID(); - me->GetMotionMaster()->MoveJump(target2->GetPositionX(), target2->GetPositionY(), target2->GetPositionZ(), 15.0f, 15.0f); + me->GetMotionMaster()->MoveJump(*target2, 15.0f, 15.0f); } } } @@ -751,10 +746,10 @@ class boss_dreadscale : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { instance->DoUseDoorOrButton(instance->GetGuidData(GO_MAIN_GATE_DOOR)); - boss_jormungarAI::EnterEvadeMode(); + boss_jormungarAI::EnterEvadeMode(why); } void JustReachedHome() override @@ -924,10 +919,10 @@ class boss_icehowl : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { instance->DoUseDoorOrButton(instance->GetGuidData(GO_MAIN_GATE_DOOR)); - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); } void JustReachedHome() override @@ -986,7 +981,7 @@ class boss_icehowl : public CreatureScript events.ScheduleEvent(EVENT_WHIRL, urand(15*IN_MILLISECONDS, 30*IN_MILLISECONDS)); return; case EVENT_MASSIVE_CRASH: - me->GetMotionMaster()->MoveJump(ToCCommonLoc[1].GetPositionX(), ToCCommonLoc[1].GetPositionY(), ToCCommonLoc[1].GetPositionZ(), 20.0f, 20.0f, 0); // 1: Middle of the room + me->GetMotionMaster()->MoveJump(ToCCommonLoc[1], 20.0f, 20.0f, 0); // 1: Middle of the room SetCombatMovement(false); me->AttackStop(); _stage = 7; //Invalid (Do nothing more than move) @@ -1039,7 +1034,7 @@ class boss_icehowl : public CreatureScript _trampleTargetY = target->GetPositionY(); _trampleTargetZ = target->GetPositionZ(); // 2: Hop Backwards - me->GetMotionMaster()->MoveJump(2*me->GetPositionX() - _trampleTargetX, 2*me->GetPositionY() - _trampleTargetY, me->GetPositionZ(), 30.0f, 20.0f, 0); + me->GetMotionMaster()->MoveJump(2*me->GetPositionX() - _trampleTargetX, 2*me->GetPositionY() - _trampleTargetY, me->GetPositionZ(), me->GetOrientation(), 30.0f, 20.0f, 0); _stage = 7; //Invalid (Do nothing more than move) } else diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_twin_valkyr.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_twin_valkyr.cpp index ae5ea2c6de4..eb1e769c07e 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_twin_valkyr.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/boss_twin_valkyr.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2010 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -416,10 +416,10 @@ class boss_fjola : public CreatureScript boss_twin_baseAI::EnterCombat(who); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { instance->DoUseDoorOrButton(instance->GetGuidData(GO_MAIN_GATE_DOOR)); - boss_twin_baseAI::EnterEvadeMode(); + boss_twin_baseAI::EnterEvadeMode(why); } void JustReachedHome() override diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp index 23bfd773a9b..b1a0f0217c4 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/instance_trial_of_the_crusader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -22,6 +22,14 @@ #include "Player.h" #include "TemporarySummon.h" +BossBoundaryData const boundaries = { + { BOSS_BEASTS, new CircleBoundary(Position(563.26f, 139.6f), 75.0) }, + { BOSS_JARAXXUS, new CircleBoundary(Position(563.26f, 139.6f), 75.0) }, + { BOSS_CRUSADERS, new CircleBoundary(Position(563.26f, 139.6f), 75.0) }, + { BOSS_VALKIRIES, new CircleBoundary(Position(563.26f, 139.6f), 75.0) }, + { BOSS_ANUBARAK, new EllipseBoundary(Position(746.0f, 135.0f), 100.0, 75.0) } +}; + class instance_trial_of_the_crusader : public InstanceMapScript { public: @@ -33,6 +41,7 @@ class instance_trial_of_the_crusader : public InstanceMapScript { SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTERS); + LoadBossBoundaries(boundaries); TrialCounter = 50; EventStage = 0; NorthrendBeasts = NOT_STARTED; diff --git a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/trial_of_the_crusader.cpp b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/trial_of_the_crusader.cpp index 974bd4672f1..0ffe74932e0 100644 --- a/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/trial_of_the_crusader.cpp +++ b/src/server/scripts/Northrend/CrusadersColiseum/TrialOfTheCrusader/trial_of_the_crusader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/DraktharonKeep/boss_king_dred.cpp b/src/server/scripts/Northrend/DraktharonKeep/boss_king_dred.cpp index 723a54e0c54..9bd02505d85 100644 --- a/src/server/scripts/Northrend/DraktharonKeep/boss_king_dred.cpp +++ b/src/server/scripts/Northrend/DraktharonKeep/boss_king_dred.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/DraktharonKeep/boss_novos.cpp b/src/server/scripts/Northrend/DraktharonKeep/boss_novos.cpp index 926ee6efecf..ce722e391d1 100644 --- a/src/server/scripts/Northrend/DraktharonKeep/boss_novos.cpp +++ b/src/server/scripts/Northrend/DraktharonKeep/boss_novos.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/DraktharonKeep/boss_tharon_ja.cpp b/src/server/scripts/Northrend/DraktharonKeep/boss_tharon_ja.cpp index a3dbc11e8ad..4d83992be7f 100644 --- a/src/server/scripts/Northrend/DraktharonKeep/boss_tharon_ja.cpp +++ b/src/server/scripts/Northrend/DraktharonKeep/boss_tharon_ja.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/DraktharonKeep/boss_trollgore.cpp b/src/server/scripts/Northrend/DraktharonKeep/boss_trollgore.cpp index 055dffd534d..395ffa8409e 100644 --- a/src/server/scripts/Northrend/DraktharonKeep/boss_trollgore.cpp +++ b/src/server/scripts/Northrend/DraktharonKeep/boss_trollgore.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/DraktharonKeep/drak_tharon_keep.h b/src/server/scripts/Northrend/DraktharonKeep/drak_tharon_keep.h index 98d23c024a6..d7409732f7f 100644 --- a/src/server/scripts/Northrend/DraktharonKeep/drak_tharon_keep.h +++ b/src/server/scripts/Northrend/DraktharonKeep/drak_tharon_keep.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/DraktharonKeep/instance_drak_tharon_keep.cpp b/src/server/scripts/Northrend/DraktharonKeep/instance_drak_tharon_keep.cpp index e45882187eb..c84771317a3 100644 --- a/src/server/scripts/Northrend/DraktharonKeep/instance_drak_tharon_keep.cpp +++ b/src/server/scripts/Northrend/DraktharonKeep/instance_drak_tharon_keep.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/boss_bronjahm.cpp b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/boss_bronjahm.cpp index 620eb54ffa9..e2c038f89fc 100644 --- a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/boss_bronjahm.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/boss_bronjahm.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/boss_devourer_of_souls.cpp b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/boss_devourer_of_souls.cpp index d5f00757039..055d0a07f41 100644 --- a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/boss_devourer_of_souls.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/boss_devourer_of_souls.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.cpp b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.cpp index 96a0b856d50..322f68fa112 100644 --- a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.h b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.h index ddbc117e7fd..47a2971a69c 100644 --- a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.h +++ b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/forge_of_souls.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp index db7628ebada..cd4386a796c 100644 --- a/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/ForgeOfSouls/instance_forge_of_souls.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/boss_falric.cpp b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/boss_falric.cpp index d1bc8eb25e8..e50eaa2075a 100644 --- a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/boss_falric.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/boss_falric.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/boss_marwyn.cpp b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/boss_marwyn.cpp index d8b09bb2f3f..bf597a44936 100644 --- a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/boss_marwyn.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/boss_marwyn.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.cpp b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.cpp index 12a745a34bc..4c2b92da0ea 100644 --- a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -1269,7 +1269,7 @@ class npc_the_lich_king_escape_hor : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { if (_despawn) return; @@ -1335,7 +1335,7 @@ class npc_the_lich_king_escape_hor : public CreatureScript } else if (me->getThreatManager().getThreatList().size() < 2 && me->HasAura(SPELL_REMORSELESS_WINTER)) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); return false; } @@ -1438,7 +1438,7 @@ struct npc_gauntlet_trash : public ScriptedAI _events.Reset(); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { if (_instance->GetData(DATA_WAVE_COUNT) != NOT_STARTED) _instance->SetData(DATA_WAVE_COUNT, NOT_STARTED); @@ -1546,10 +1546,10 @@ class npc_phantom_mage : public CreatureScript { npc_phantom_mageAI(Creature* creature) : npc_gauntlet_trash(creature) { } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { if (!me->HasAura(AURA_HALLUCINATION)) - npc_gauntlet_trash::EnterEvadeMode(); + npc_gauntlet_trash::EnterEvadeMode(why); } void EnterCombat(Unit* /*who*/) override @@ -1626,10 +1626,10 @@ class npc_phantom_hallucination : public CreatureScript DoZoneInCombat(me, 150.0f); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { if (me->GetOwner() && !me->GetOwner()->HasAura(AURA_HALLUCINATION)) - npc_phantom_mage::npc_phantom_mageAI::EnterEvadeMode(); + npc_phantom_mage::npc_phantom_mageAI::EnterEvadeMode(why); } void JustDied(Unit* /*killer*/) override diff --git a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.h b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.h index d2f9ab5d262..14cc3696797 100644 --- a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.h +++ b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/halls_of_reflection.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/instance_halls_of_reflection.cpp b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/instance_halls_of_reflection.cpp index fabe54303b8..dd48f9f0155 100644 --- a/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/instance_halls_of_reflection.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/HallsOfReflection/instance_halls_of_reflection.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_forgemaster_garfrost.cpp b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_forgemaster_garfrost.cpp index 141dc8415b4..13ba10d3542 100644 --- a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_forgemaster_garfrost.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_forgemaster_garfrost.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_krickandick.cpp b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_krickandick.cpp index c19af1cf79d..03f12e46bc3 100644 --- a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_krickandick.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_krickandick.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -166,10 +166,10 @@ class boss_ick : public CreatureScript events.ScheduleEvent(EVENT_SPECIAL, urand(30000, 35000)); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { me->GetMotionMaster()->Clear(); - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); } void JustDied(Unit* /*killer*/) override @@ -203,7 +203,7 @@ class boss_ick : public CreatureScript if (!me->GetVictim() && me->getThreatManager().isThreatListEmpty()) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_NO_HOSTILES); return; } diff --git a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_scourgelord_tyrannus.cpp b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_scourgelord_tyrannus.cpp index 3e56f9a1753..96bd0aaa35e 100644 --- a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_scourgelord_tyrannus.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/boss_scourgelord_tyrannus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -170,7 +170,7 @@ class boss_tyrannus : public CreatureScript me->GetMotionMaster()->MoveChase(victim); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { instance->SetBossState(DATA_TYRANNUS, FAIL); if (Creature* rimefang = GetRimefang()) diff --git a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/instance_pit_of_saron.cpp b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/instance_pit_of_saron.cpp index a8c77423ee6..12845d6e2b1 100644 --- a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/instance_pit_of_saron.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/instance_pit_of_saron.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -27,9 +27,9 @@ Position const EventLeaderPos2 = {1054.368f, 107.14620f, 628.4467f, 0.0f}; DoorData const Doors[] = { - {GO_ICE_WALL, DATA_GARFROST, DOOR_TYPE_PASSAGE, BOUNDARY_NONE}, - {GO_ICE_WALL, DATA_ICK, DOOR_TYPE_PASSAGE, BOUNDARY_NONE}, - {GO_HALLS_OF_REFLECTION_PORTCULLIS, DATA_TYRANNUS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE}, + {GO_ICE_WALL, DATA_GARFROST, DOOR_TYPE_PASSAGE }, + {GO_ICE_WALL, DATA_ICK, DOOR_TYPE_PASSAGE }, + {GO_HALLS_OF_REFLECTION_PORTCULLIS, DATA_TYRANNUS, DOOR_TYPE_PASSAGE }, }; class instance_pit_of_saron : public InstanceMapScript diff --git a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp index f3b70f069c4..a39c4518a4e 100644 --- a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp +++ b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.h b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.h index 9781bd0d124..8e2b46cba59 100644 --- a/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.h +++ b/src/server/scripts/Northrend/FrozenHalls/PitOfSaron/pit_of_saron.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Gundrak/boss_drakkari_colossus.cpp b/src/server/scripts/Northrend/Gundrak/boss_drakkari_colossus.cpp index 0ded2022e83..053e38ed93e 100644 --- a/src/server/scripts/Northrend/Gundrak/boss_drakkari_colossus.cpp +++ b/src/server/scripts/Northrend/Gundrak/boss_drakkari_colossus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -336,7 +336,7 @@ class boss_drakkari_elemental : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { me->DespawnOrUnsummon(); } diff --git a/src/server/scripts/Northrend/Gundrak/boss_eck.cpp b/src/server/scripts/Northrend/Gundrak/boss_eck.cpp index f6463611f3a..cc68f73b631 100644 --- a/src/server/scripts/Northrend/Gundrak/boss_eck.cpp +++ b/src/server/scripts/Northrend/Gundrak/boss_eck.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Gundrak/boss_gal_darah.cpp b/src/server/scripts/Northrend/Gundrak/boss_gal_darah.cpp index c1080a9c39f..ed2f15c77d5 100644 --- a/src/server/scripts/Northrend/Gundrak/boss_gal_darah.cpp +++ b/src/server/scripts/Northrend/Gundrak/boss_gal_darah.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Gundrak/boss_moorabi.cpp b/src/server/scripts/Northrend/Gundrak/boss_moorabi.cpp index d5751a55aec..b76a2ca0efb 100644 --- a/src/server/scripts/Northrend/Gundrak/boss_moorabi.cpp +++ b/src/server/scripts/Northrend/Gundrak/boss_moorabi.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Gundrak/boss_slad_ran.cpp b/src/server/scripts/Northrend/Gundrak/boss_slad_ran.cpp index 1679e989556..9eaa86cc03c 100644 --- a/src/server/scripts/Northrend/Gundrak/boss_slad_ran.cpp +++ b/src/server/scripts/Northrend/Gundrak/boss_slad_ran.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Gundrak/gundrak.h b/src/server/scripts/Northrend/Gundrak/gundrak.h index 35535ce4b7f..1999f84c440 100644 --- a/src/server/scripts/Northrend/Gundrak/gundrak.h +++ b/src/server/scripts/Northrend/Gundrak/gundrak.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Gundrak/instance_gundrak.cpp b/src/server/scripts/Northrend/Gundrak/instance_gundrak.cpp index 4438c4ab199..9f90b228247 100644 --- a/src/server/scripts/Northrend/Gundrak/instance_gundrak.cpp +++ b/src/server/scripts/Northrend/Gundrak/instance_gundrak.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -23,12 +23,12 @@ DoorData const doorData[] = { - { GO_GAL_DARAH_DOOR_1, DATA_GAL_DARAH, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_GAL_DARAH_DOOR_2, DATA_GAL_DARAH, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_GAL_DARAH_DOOR_3, DATA_GAL_DARAH, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_ECK_THE_FEROCIOUS_DOOR, DATA_MOORABI, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_ECK_THE_FEROCIOUS_DOOR_BEHIND, DATA_ECK_THE_FEROCIOUS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_GAL_DARAH_DOOR_1, DATA_GAL_DARAH, DOOR_TYPE_PASSAGE }, + { GO_GAL_DARAH_DOOR_2, DATA_GAL_DARAH, DOOR_TYPE_PASSAGE }, + { GO_GAL_DARAH_DOOR_3, DATA_GAL_DARAH, DOOR_TYPE_ROOM }, + { GO_ECK_THE_FEROCIOUS_DOOR, DATA_MOORABI, DOOR_TYPE_PASSAGE }, + { GO_ECK_THE_FEROCIOUS_DOOR_BEHIND, DATA_ECK_THE_FEROCIOUS, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; ObjectData const creatureData[] = diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp index cfeb31d5526..f59701b9c25 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_prince_council.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp index a7ac5d1227e..bc8c7f877a9 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -173,7 +173,7 @@ class boss_blood_queen_lana_thel : public CreatureScript { if (!instance->CheckRequiredBosses(DATA_BLOOD_QUEEN_LANA_THEL, who->ToPlayer())) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); instance->DoCastSpellOnPlayers(LIGHT_S_HAMMER_TELEPORT); return; } @@ -244,9 +244,11 @@ class boss_blood_queen_lana_thel : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - _EnterEvadeMode(); + if (!_EnterEvadeMode(why)) + return; + CleanAuras(); if (_killMinchar) { @@ -257,6 +259,7 @@ class boss_blood_queen_lana_thel : public CreatureScript } else { + me->AddUnitState(UNIT_STATE_EVADE); me->GetMotionMaster()->MoveTargetedHome(); Reset(); } @@ -333,7 +336,7 @@ class boss_blood_queen_lana_thel : public CreatureScript void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; events.Update(diff); diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp index 54c24769246..3ea0de31764 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_deathbringer_saurfang.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -287,7 +287,7 @@ class boss_deathbringer_saurfang : public CreatureScript if (!instance->CheckRequiredBosses(DATA_DEATHBRINGER_SAURFANG, who->ToPlayer())) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); instance->DoCastSpellOnPlayers(LIGHT_S_HAMMER_TELEPORT); return; } @@ -332,9 +332,9 @@ class boss_deathbringer_saurfang : public CreatureScript ScriptedAI::AttackStart(victim); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); if (_introDone) me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_IMMUNE_TO_PC); } @@ -390,7 +390,7 @@ class boss_deathbringer_saurfang : public CreatureScript if (target->GetTransport()) { summon->DespawnOrUnsummon(1); - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); return; } @@ -420,7 +420,7 @@ class boss_deathbringer_saurfang : public CreatureScript { if (target->GetTransport()) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); return; } @@ -598,7 +598,7 @@ class boss_deathbringer_saurfang : public CreatureScript if (target->GetTransport()) return false; - return true; + return BossAI::CanAIAttack(target); } static uint32 const FightWonValue; diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_festergut.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_festergut.cpp index f76c415ab92..55cb455d037 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_festergut.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_festergut.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -115,7 +115,7 @@ class boss_festergut : public CreatureScript { if (!instance->CheckRequiredBosses(DATA_FESTERGUT, who->ToPlayer())) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); instance->DoCastSpellOnPlayers(LIGHT_S_HAMMER_TELEPORT); return; } @@ -145,9 +145,9 @@ class boss_festergut : public CreatureScript instance->SetBossState(DATA_FESTERGUT, FAIL); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); if (Creature* professor = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_PROFESSOR_PUTRICIDE))) professor->AI()->EnterEvadeMode(); } @@ -166,7 +166,7 @@ class boss_festergut : public CreatureScript void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; events.Update(diff); diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp index babd444288f..9b0693ec95e 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_icecrown_gunship_battle.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -572,7 +572,7 @@ struct gunship_npc_AI : public ScriptedAI } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { if (!me->IsAlive() || !me->IsInCombat()) return; @@ -621,7 +621,7 @@ protected: { if (Instance->GetBossState(DATA_ICECROWN_GUNSHIP_BATTLE) != IN_PROGRESS) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); return false; } @@ -634,7 +634,7 @@ protected: } else if (me->getThreatManager().isThreatListEmpty()) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); return false; } @@ -875,7 +875,7 @@ class npc_high_overlord_saurfang_igb : public CreatureScript _events.ScheduleEvent(EVENT_CLEAVE, urand(2000, 10000)); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { if (!me->IsAlive()) return; @@ -1143,7 +1143,7 @@ class npc_muradin_bronzebeard_igb : public CreatureScript _events.ScheduleEvent(EVENT_CLEAVE, urand(2000, 10000)); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { if (!me->IsAlive()) return; @@ -1721,9 +1721,9 @@ class npc_gunship_mage : public CreatureScript me->SetReactState(REACT_PASSIVE); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); } void MovementInform(uint32 type, uint32 pointId) override diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_lady_deathwhisper.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_lady_deathwhisper.cpp index 78a279b94fd..d3cf6495aa7 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_lady_deathwhisper.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_lady_deathwhisper.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -421,7 +421,7 @@ class boss_lady_deathwhisper : public CreatureScript void UpdateAI(uint32 diff) override { - if ((!UpdateVictim() && !events.IsInPhase(PHASE_INTRO)) || !CheckInRoom()) + if ((!UpdateVictim() && !events.IsInPhase(PHASE_INTRO))) return; events.Update(diff); @@ -1043,8 +1043,9 @@ class at_lady_deathwhisper_entrance : public AreaTriggerScript bool OnTrigger(Player* player, AreaTriggerEntry const* /*areaTrigger*/) override { if (InstanceScript* instance = player->GetInstanceScript()) - if (Creature* ladyDeathwhisper = ObjectAccessor::GetCreature(*player, instance->GetGuidData(DATA_LADY_DEATHWHISPER))) - ladyDeathwhisper->AI()->DoAction(ACTION_START_INTRO); + if (instance->GetBossState(DATA_LADY_DEATHWHISPER) != DONE) + if (Creature* ladyDeathwhisper = ObjectAccessor::GetCreature(*player, instance->GetGuidData(DATA_LADY_DEATHWHISPER))) + ladyDeathwhisper->AI()->DoAction(ACTION_START_INTRO); return true; } diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp index 993fc75fcde..056231285e2 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_lord_marrowgar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -135,6 +135,7 @@ class boss_lord_marrowgar : public CreatureScript _boneStormDuration = RAID_MODE<uint32>(20000, 30000, 20000, 30000); _baseSpeed = creature->GetSpeedRate(MOVE_RUN); _coldflameLastPos.Relocate(creature); + _introDone = false; _boneSlice = false; } @@ -185,7 +186,7 @@ class boss_lord_marrowgar : public CreatureScript void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; events.Update(diff); diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp index 4c67c0a7163..2db9d206a00 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -236,6 +236,7 @@ class boss_professor_putricide : public CreatureScript summons.DespawnAll(); SetPhase(PHASE_COMBAT_1); _experimentState = EXPERIMENT_STATE_OOZE; + me->SetReactState(REACT_DEFENSIVE); me->SetWalk(false); if (me->GetMotionMaster()->GetCurrentMovementGeneratorType() == POINT_MOTION_TYPE) me->GetMotionMaster()->MovementExpired(); @@ -316,14 +317,12 @@ class boss_professor_putricide : public CreatureScript // no possible aura seen in sniff adding the aurastate summon->ModifyAuraState(AURA_STATE_UNKNOWN22, true); summon->CastSpell(summon, SPELL_GASEOUS_BLOAT_PROC, true); - summon->ApplySpellImmune(0, IMMUNITY_EFFECT, SPELL_EFFECT_KNOCK_BACK, true); summon->SetReactState(REACT_PASSIVE); break; case NPC_VOLATILE_OOZE: // no possible aura seen in sniff adding the aurastate summon->ModifyAuraState(AURA_STATE_UNKNOWN19, true); summon->CastSpell(summon, SPELL_OOZE_ERUPTION_SEARCH_PERIODIC, true); - summon->ApplySpellImmune(0, IMMUNITY_EFFECT, SPELL_EFFECT_KNOCK_BACK, true); summon->SetReactState(REACT_PASSIVE); break; case NPC_CHOKING_GAS_BOMB: @@ -563,7 +562,7 @@ class boss_professor_putricide : public CreatureScript void UpdateAI(uint32 diff) override { - if ((!(events.IsInPhase(PHASE_ROTFACE) || events.IsInPhase(PHASE_FESTERGUT)) && !UpdateVictim()) || !CheckInRoom()) + if ((!(events.IsInPhase(PHASE_ROTFACE) || events.IsInPhase(PHASE_FESTERGUT)) && !UpdateVictim())) return; events.Update(diff); diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_rotface.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_rotface.cpp index d03925f734a..683dd976b7a 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_rotface.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_rotface.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -119,7 +119,7 @@ class boss_rotface : public CreatureScript { if (!instance->CheckRequiredBosses(DATA_ROTFACE, who->ToPlayer())) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); instance->DoCastSpellOnPlayers(LIGHT_S_HAMMER_TELEPORT); return; } @@ -155,9 +155,9 @@ class boss_rotface : public CreatureScript Talk(SAY_KILL); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); if (Creature* professor = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_PROFESSOR_PUTRICIDE))) professor->AI()->EnterEvadeMode(); } @@ -179,7 +179,7 @@ class boss_rotface : public CreatureScript void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; events.Update(diff); diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp index 8917af0038f..ac094588d35 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_sindragosa.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -265,7 +265,7 @@ class boss_sindragosa : public CreatureScript { if (!instance->CheckRequiredBosses(DATA_SINDRAGOSA, victim->ToPlayer())) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_SEQUENCE_BREAK); instance->DoCastSpellOnPlayers(LIGHT_S_HAMMER_TELEPORT); return; } @@ -276,6 +276,13 @@ class boss_sindragosa : public CreatureScript Talk(SAY_AGGRO); } + void EnterEvadeMode(EvadeReason why) override + { + if (_isInAirPhase && why == EVADE_REASON_BOUNDARY) + return; + BossAI::EnterEvadeMode(why); + } + void JustReachedHome() override { BossAI::JustReachedHome(); @@ -417,7 +424,7 @@ class boss_sindragosa : public CreatureScript void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; events.Update(diff); diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_the_lich_king.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_the_lich_king.cpp index 4fadc0bf8fa..9fa624aaad3 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_the_lich_king.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_the_lich_king.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -285,6 +285,7 @@ enum Phases #define PHASE_TWO_THREE (events.IsInPhase(PHASE_TWO) ? PHASE_TWO : PHASE_THREE) Position const CenterPosition = {503.6282f, -2124.655f, 840.8569f, 0.0f}; +Position const TirionSpawn = {505.2118f, -2124.353f, 840.9403f, 3.141593f}; Position const TirionIntro = {489.2970f, -2124.840f, 840.8569f, 0.0f}; Position const TirionCharge = {482.9019f, -2124.479f, 840.8570f, 0.0f}; Position const LichKingIntro[3] = @@ -514,13 +515,33 @@ class boss_the_lich_king : public CreatureScript _vileSpiritExplosions = 0; } - void Reset() override + void InitializeAI() override + { + SetupEncounter(); + } + + void JustRespawned() override + { + SetupEncounter(); + } + + void SetupEncounter() { _Reset(); me->SetReactState(REACT_PASSIVE); events.SetPhase(PHASE_INTRO); Initialize(); SetEquipmentSlots(true); + + // Reset The Frozen Throne gameobjects + FrozenThroneResetWorker reset; + Trinity::GameObjectWorker<FrozenThroneResetWorker> worker(me, reset); + me->VisitNearbyGridObject(333.0f, worker); + + // Reset any light override + me->GetMap()->SetZoneOverrideLight(AREA_THE_FROZEN_THRONE, 0, 5000); + + me->SummonCreature(NPC_HIGHLORD_TIRION_FORDRING_LK, TirionSpawn, TEMPSUMMON_MANUAL_DESPAWN); } void JustDied(Unit* /*killer*/) override @@ -538,7 +559,7 @@ class boss_the_lich_king : public CreatureScript { if (!instance->CheckRequiredBosses(DATA_THE_LICH_KING, target->ToPlayer())) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); instance->DoCastSpellOnPlayers(LIGHT_S_HAMMER_TELEPORT); return; } @@ -556,40 +577,21 @@ class boss_the_lich_king : public CreatureScript events.ScheduleEvent(EVENT_SHADOW_TRAP, 15500, 0, PHASE_ONE); } - void JustReachedHome() override - { - _JustReachedHome(); - instance->SetBossState(DATA_THE_LICH_KING, NOT_STARTED); - - // Reset The Frozen Throne gameobjects - FrozenThroneResetWorker reset; - Trinity::GameObjectWorker<FrozenThroneResetWorker> worker(me, reset); - me->VisitNearbyGridObject(333.0f, worker); - - // Restore Tirion's gossip only after The Lich King fully resets to prevent - // restarting the encounter while LK still runs back to spawn point - if (Creature* tirion = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_HIGHLORD_TIRION_FORDRING))) - tirion->SetFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_GOSSIP); - - // Reset any light override - me->GetMap()->SetZoneOverrideLight(AREA_THE_FROZEN_THRONE, 0, 5000); - } - bool CanAIAttack(Unit const* target) const override { // The Lich King must not select targets in frostmourne room if he killed everyone outside - return !target->HasAura(SPELL_IN_FROSTMOURNE_ROOM); + return !target->HasAura(SPELL_IN_FROSTMOURNE_ROOM) && BossAI::CanAIAttack(target); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { - instance->SetBossState(DATA_THE_LICH_KING, FAIL); - BossAI::EnterEvadeMode(); if (Creature* tirion = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_HIGHLORD_TIRION_FORDRING))) - tirion->AI()->EnterEvadeMode(); + tirion->DespawnOrUnsummon(); DoCastAOE(SPELL_KILL_FROSTMOURNE_PLAYERS); EntryCheckPredicate pred(NPC_STRANGULATE_VEHICLE); summons.DoAction(ACTION_TELEPORT_BACK, pred); + summons.DespawnAll(); + _DespawnAtEvade(); } void KilledUnit(Unit* victim) override @@ -770,6 +772,8 @@ class boss_the_lich_king : public CreatureScript case NPC_STRANGULATE_VEHICLE: summons.Summon(summon); return; + case NPC_HIGHLORD_TIRION_FORDRING_LK: + return; default: break; } @@ -1153,6 +1157,7 @@ class npc_tirion_fordring_tft : public CreatureScript _events.Reset(); if (_instance->GetBossState(DATA_THE_LICH_KING) == DONE) me->RemoveFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_GOSSIP); + me->LoadEquipment(1); } void MovementInform(uint32 type, uint32 id) override @@ -1724,7 +1729,7 @@ class npc_terenas_menethil : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { // no running back home if (!me->IsAlive()) @@ -1967,7 +1972,7 @@ class npc_broken_frostmourne : public CreatureScript _events.ScheduleEvent(EVENT_OUTRO_SUMMON_TERENAS, 6000, 0, PHASE_OUTRO); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { } diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_valithria_dreamwalker.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_valithria_dreamwalker.cpp index 4a76dc667e8..4f35f848927 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/boss_valithria_dreamwalker.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_valithria_dreamwalker.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -557,6 +557,8 @@ class npc_green_dragon_combat_trigger : public CreatureScript if (!me->IsInCombat()) return; + // @TODO check out of bounds on all encounter creatures, evade if matched + std::list<HostileReference*> const& threatList = me->getThreatManager().getThreatList(); if (threatList.empty()) { diff --git a/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.cpp b/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.cpp index f05fc48c074..25ca99f6a20 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -1283,16 +1283,16 @@ struct npc_argent_captainAI : public ScriptedAI return (me->GetPositionY() > 2660.0f) == (target->GetPositionY() > 2660.0f); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { // not yet following if (me->GetMotionMaster()->GetMotionSlotType(MOTION_SLOT_IDLE) != CHASE_MOTION_TYPE || IsUndead) { - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); return; } - if (!_EnterEvadeMode()) + if (!_EnterEvadeMode(why)) return; if (!me->GetVehicle()) diff --git a/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.h b/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.h index 224aa6cda45..5a5b7aefc02 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.h +++ b/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -115,7 +115,7 @@ enum DataTypes DATA_ARTHAS_PLATFORM = 38, DATA_TERENAS_MENETHIL = 39, DATA_ENEMY_GUNSHIP = 40, - DATA_UPPERSPIRE_TELE_ACT = 41, + DATA_UPPERSPIRE_TELE_ACT = 41, /// also used by conditions DATA_BLOOD_QUEEN_LANA_THEL_COUNCIL = 42 }; @@ -569,14 +569,10 @@ class spell_trigger_spell_from_caster : public SpellScriptLoader TriggerCastFlags _triggerFlags; }; -template<class AI> -CreatureAI* GetIcecrownCitadelAI(Creature* creature) +template<class AI, class T> +inline AI* GetIcecrownCitadelAI(T* obj) { - if (InstanceMap* instance = creature->GetMap()->ToInstanceMap()) - if (instance->GetInstanceScript()) - if (instance->GetScriptId() == sObjectMgr->GetScriptId(ICCScriptName)) - return new AI(creature); - return NULL; + return GetInstanceAI<AI>(obj, ICCScriptName); } #endif // ICECROWN_CITADEL_H_ diff --git a/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel_teleport.cpp b/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel_teleport.cpp index a12e2d05285..8b5e03203e1 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel_teleport.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/icecrown_citadel_teleport.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -15,6 +15,7 @@ * with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include "GameObjectAI.h" #include "InstanceScript.h" #include "Player.h" #include "ScriptedGossip.h" @@ -22,57 +23,55 @@ #include "Spell.h" #include "icecrown_citadel.h" -#define GOSSIP_SENDER_ICC_PORT 631 +static std::vector<uint32> const TeleportSpells = +{ + LIGHT_S_HAMMER_TELEPORT, // 0 + ORATORY_OF_THE_DAMNED_TELEPORT, // 1 + 0, // 2 + RAMPART_OF_SKULLS_TELEPORT, // 3 + DEATHBRINGER_S_RISE_TELEPORT, // 4 + UPPER_SPIRE_TELEPORT, // 5 + SINDRAGOSA_S_LAIR_TELEPORT // 6 +}; class icecrown_citadel_teleport : public GameObjectScript { + static_assert(DATA_UPPERSPIRE_TELE_ACT == 41, "icecrown_citadel.h DATA_UPPERSPIRE_TELE_ACT set to value != 41, gossip condition of the teleporters won't work as intended."); + public: icecrown_citadel_teleport() : GameObjectScript("icecrown_citadel_teleport") { } - bool OnGossipHello(Player* player, GameObject* go) override + struct icecrown_citadel_teleportAI : public GameObjectAI { - if (InstanceScript* instance = go->GetInstanceScript()) + icecrown_citadel_teleportAI(GameObject* go) : GameObjectAI(go) { - if (instance->GetBossState(DATA_LORD_MARROWGAR) == DONE) - { - if (go->GetEntry() != GO_SCOURGE_TRANSPORTER_LIGHTSHAMMER) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, "Teleport to Light's Hammer.", GOSSIP_SENDER_ICC_PORT, LIGHT_S_HAMMER_TELEPORT); - if (go->GetEntry() != GO_SCOURGE_TRANSPORTER_ORATORY) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, "Teleport to the Oratory of the Damned.", GOSSIP_SENDER_ICC_PORT, ORATORY_OF_THE_DAMNED_TELEPORT); - } - if (instance->GetBossState(DATA_LADY_DEATHWHISPER) == DONE && go->GetEntry() != GO_SCOURGE_TRANSPORTER_RAMPART) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, "Teleport to the Rampart of Skulls.", GOSSIP_SENDER_ICC_PORT, RAMPART_OF_SKULLS_TELEPORT); - if (instance->GetBossState(DATA_ICECROWN_GUNSHIP_BATTLE) == DONE && go->GetEntry() != GO_SCOURGE_TRANSPORTER_DEATHBRINGER) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, "Teleport to the Deathbringer's Rise.", GOSSIP_SENDER_ICC_PORT, DEATHBRINGER_S_RISE_TELEPORT); - if (instance->GetData(DATA_UPPERSPIRE_TELE_ACT) == DONE && go->GetEntry() != GO_SCOURGE_TRANSPORTER_UPPERSPIRE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, "Teleport to the Upper Spire.", GOSSIP_SENDER_ICC_PORT, UPPER_SPIRE_TELEPORT); - /// @todo Gauntlet event before Sindragosa - if (instance->GetBossState(DATA_VALITHRIA_DREAMWALKER) == DONE && go->GetEntry() != GO_SCOURGE_TRANSPORTER_SINDRAGOSA) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, "Teleport to Sindragosa's Lair", GOSSIP_SENDER_ICC_PORT, SINDRAGOSA_S_LAIR_TELEPORT); } - player->SEND_GOSSIP_MENU(player->GetGossipTextId(go), go->GetGUID()); - return true; - } + bool GossipSelect(Player* player, uint32 /*menuId*/, uint32 gossipListId) override + { + if (gossipListId >= TeleportSpells.size()) + return false; - bool OnGossipSelect(Player* player, GameObject* /*go*/, uint32 sender, uint32 action) override - { - player->PlayerTalkClass->ClearMenus(); - player->CLOSE_GOSSIP_MENU(); - SpellInfo const* spell = sSpellMgr->GetSpellInfo(action); - if (!spell) - return false; + player->PlayerTalkClass->ClearMenus(); + player->CLOSE_GOSSIP_MENU(); + SpellInfo const* spell = sSpellMgr->GetSpellInfo(TeleportSpells[gossipListId]); + if (!spell) + return false; - if (player->IsInCombat()) - { - Spell::SendCastResult(player, spell, 0, SPELL_FAILED_AFFECTING_COMBAT); - return true; - } + if (player->IsInCombat()) + { + Spell::SendCastResult(player, spell, 0, SPELL_FAILED_AFFECTING_COMBAT); + return true; + } - if (sender == GOSSIP_SENDER_ICC_PORT) player->CastSpell(player, spell, true); + return true; + } + }; - return true; + GameObjectAI* GetAI(GameObject* go) const override + { + return GetIcecrownCitadelAI<icecrown_citadel_teleportAI>(go); } }; diff --git a/src/server/scripts/Northrend/IcecrownCitadel/instance_icecrown_citadel.cpp b/src/server/scripts/Northrend/IcecrownCitadel/instance_icecrown_citadel.cpp index 718c0ebe231..388d7ff7561 100644 --- a/src/server/scripts/Northrend/IcecrownCitadel/instance_icecrown_citadel.cpp +++ b/src/server/scripts/Northrend/IcecrownCitadel/instance_icecrown_citadel.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -47,34 +47,54 @@ enum TimedEvents EVENT_RESPAWN_GUNSHIP = 4 }; +BossBoundaryData const boundaries = +{ + { DATA_LORD_MARROWGAR, new CircleBoundary(Position(-428.0f,2211.0f), 95.0) }, + { DATA_LORD_MARROWGAR, new RectangleBoundary(-430.0f, -330.0f, 2110.0f, 2310.0f) }, + { DATA_LADY_DEATHWHISPER, new RectangleBoundary(-670.0f, -520.0f, 2145.0f, 2280.0f) }, + { DATA_DEATHBRINGER_SAURFANG, new RectangleBoundary(-565.0f, -465.0f, 2160.0f, 2260.0f) }, + + { DATA_ROTFACE, new RectangleBoundary(4385.0f, 4505.0f, 3082.0f, 3195.0f) }, + { DATA_FESTERGUT, new RectangleBoundary(4205.0f, 4325.0f, 3082.0f, 3195.0f) }, + { DATA_PROFESSOR_PUTRICIDE, new ParallelogramBoundary(Position(4356.0f, 3290.0f), Position(4435.0f, 3194.0f), Position(4280.0f, 3194.0f)) }, + { DATA_PROFESSOR_PUTRICIDE, new RectangleBoundary(4280.0f, 4435.0f, 3150.0f, 4360.0f) }, + + { DATA_BLOOD_PRINCE_COUNCIL, new EllipseBoundary(Position(4660.95f, 2769.194f), 85.0, 60.0) }, + { DATA_BLOOD_QUEEN_LANA_THEL, new CircleBoundary(Position(4595.93f, 2769.365f), 64.0) }, + + { DATA_SISTER_SVALNA, new RectangleBoundary(4291.0f, 4423.0f, 2438.0f, 2653.0f) }, + { DATA_VALITHRIA_DREAMWALKER, new RectangleBoundary(4112.5f, 4293.5f, 2385.0f, 2585.0f) }, + { DATA_SINDRAGOSA, new EllipseBoundary(Position(4408.6f, 2484.0f), 100.0, 75.0) } +}; + DoorData const doorData[] = { - {GO_LORD_MARROWGAR_S_ENTRANCE, DATA_LORD_MARROWGAR, DOOR_TYPE_ROOM, BOUNDARY_N }, - {GO_ICEWALL, DATA_LORD_MARROWGAR, DOOR_TYPE_PASSAGE, BOUNDARY_NONE}, - {GO_DOODAD_ICECROWN_ICEWALL02, DATA_LORD_MARROWGAR, DOOR_TYPE_PASSAGE, BOUNDARY_NONE}, - {GO_ORATORY_OF_THE_DAMNED_ENTRANCE, DATA_LADY_DEATHWHISPER, DOOR_TYPE_ROOM, BOUNDARY_N }, - {GO_SAURFANG_S_DOOR, DATA_DEATHBRINGER_SAURFANG, DOOR_TYPE_PASSAGE, BOUNDARY_NONE}, - {GO_ORANGE_PLAGUE_MONSTER_ENTRANCE, DATA_FESTERGUT, DOOR_TYPE_ROOM, BOUNDARY_E }, - {GO_GREEN_PLAGUE_MONSTER_ENTRANCE, DATA_ROTFACE, DOOR_TYPE_ROOM, BOUNDARY_E }, - {GO_SCIENTIST_ENTRANCE, DATA_PROFESSOR_PUTRICIDE, DOOR_TYPE_ROOM, BOUNDARY_E }, - {GO_CRIMSON_HALL_DOOR, DATA_BLOOD_PRINCE_COUNCIL, DOOR_TYPE_ROOM, BOUNDARY_S }, - {GO_BLOOD_ELF_COUNCIL_DOOR, DATA_BLOOD_PRINCE_COUNCIL, DOOR_TYPE_PASSAGE, BOUNDARY_W }, - {GO_BLOOD_ELF_COUNCIL_DOOR_RIGHT, DATA_BLOOD_PRINCE_COUNCIL, DOOR_TYPE_PASSAGE, BOUNDARY_E }, - {GO_DOODAD_ICECROWN_BLOODPRINCE_DOOR_01, DATA_BLOOD_QUEEN_LANA_THEL, DOOR_TYPE_ROOM, BOUNDARY_S }, - {GO_DOODAD_ICECROWN_GRATE_01, DATA_BLOOD_QUEEN_LANA_THEL, DOOR_TYPE_PASSAGE, BOUNDARY_NONE}, - {GO_GREEN_DRAGON_BOSS_ENTRANCE, DATA_SISTER_SVALNA, DOOR_TYPE_PASSAGE, BOUNDARY_S }, - {GO_GREEN_DRAGON_BOSS_ENTRANCE, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_ROOM, BOUNDARY_N }, - {GO_GREEN_DRAGON_BOSS_EXIT, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_PASSAGE, BOUNDARY_S }, - {GO_DOODAD_ICECROWN_ROOSTPORTCULLIS_01, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_SPAWN_HOLE, BOUNDARY_N }, - {GO_DOODAD_ICECROWN_ROOSTPORTCULLIS_02, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_SPAWN_HOLE, BOUNDARY_S }, - {GO_DOODAD_ICECROWN_ROOSTPORTCULLIS_03, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_SPAWN_HOLE, BOUNDARY_N }, - {GO_DOODAD_ICECROWN_ROOSTPORTCULLIS_04, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_SPAWN_HOLE, BOUNDARY_S }, - {GO_SINDRAGOSA_ENTRANCE_DOOR, DATA_SINDRAGOSA, DOOR_TYPE_ROOM, BOUNDARY_S }, - {GO_SINDRAGOSA_SHORTCUT_ENTRANCE_DOOR, DATA_SINDRAGOSA, DOOR_TYPE_PASSAGE, BOUNDARY_E }, - {GO_SINDRAGOSA_SHORTCUT_EXIT_DOOR, DATA_SINDRAGOSA, DOOR_TYPE_PASSAGE, BOUNDARY_NONE}, - {GO_ICE_WALL, DATA_SINDRAGOSA, DOOR_TYPE_ROOM, BOUNDARY_SE }, - {GO_ICE_WALL, DATA_SINDRAGOSA, DOOR_TYPE_ROOM, BOUNDARY_SW }, - {0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE} // END + {GO_LORD_MARROWGAR_S_ENTRANCE, DATA_LORD_MARROWGAR, DOOR_TYPE_ROOM }, + {GO_ICEWALL, DATA_LORD_MARROWGAR, DOOR_TYPE_PASSAGE }, + {GO_DOODAD_ICECROWN_ICEWALL02, DATA_LORD_MARROWGAR, DOOR_TYPE_PASSAGE }, + {GO_ORATORY_OF_THE_DAMNED_ENTRANCE, DATA_LADY_DEATHWHISPER, DOOR_TYPE_ROOM }, + {GO_SAURFANG_S_DOOR, DATA_DEATHBRINGER_SAURFANG, DOOR_TYPE_PASSAGE }, + {GO_ORANGE_PLAGUE_MONSTER_ENTRANCE, DATA_FESTERGUT, DOOR_TYPE_ROOM }, + {GO_GREEN_PLAGUE_MONSTER_ENTRANCE, DATA_ROTFACE, DOOR_TYPE_ROOM }, + {GO_SCIENTIST_ENTRANCE, DATA_PROFESSOR_PUTRICIDE, DOOR_TYPE_ROOM }, + {GO_CRIMSON_HALL_DOOR, DATA_BLOOD_PRINCE_COUNCIL, DOOR_TYPE_ROOM }, + {GO_BLOOD_ELF_COUNCIL_DOOR, DATA_BLOOD_PRINCE_COUNCIL, DOOR_TYPE_PASSAGE }, + {GO_BLOOD_ELF_COUNCIL_DOOR_RIGHT, DATA_BLOOD_PRINCE_COUNCIL, DOOR_TYPE_PASSAGE }, + {GO_DOODAD_ICECROWN_BLOODPRINCE_DOOR_01, DATA_BLOOD_QUEEN_LANA_THEL, DOOR_TYPE_ROOM }, + {GO_DOODAD_ICECROWN_GRATE_01, DATA_BLOOD_QUEEN_LANA_THEL, DOOR_TYPE_PASSAGE }, + {GO_GREEN_DRAGON_BOSS_ENTRANCE, DATA_SISTER_SVALNA, DOOR_TYPE_PASSAGE }, + {GO_GREEN_DRAGON_BOSS_ENTRANCE, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_ROOM }, + {GO_GREEN_DRAGON_BOSS_EXIT, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_PASSAGE }, + {GO_DOODAD_ICECROWN_ROOSTPORTCULLIS_01, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_SPAWN_HOLE }, + {GO_DOODAD_ICECROWN_ROOSTPORTCULLIS_02, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_SPAWN_HOLE }, + {GO_DOODAD_ICECROWN_ROOSTPORTCULLIS_03, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_SPAWN_HOLE }, + {GO_DOODAD_ICECROWN_ROOSTPORTCULLIS_04, DATA_VALITHRIA_DREAMWALKER, DOOR_TYPE_SPAWN_HOLE }, + {GO_SINDRAGOSA_ENTRANCE_DOOR, DATA_SINDRAGOSA, DOOR_TYPE_ROOM }, + {GO_SINDRAGOSA_SHORTCUT_ENTRANCE_DOOR, DATA_SINDRAGOSA, DOOR_TYPE_PASSAGE }, + {GO_SINDRAGOSA_SHORTCUT_EXIT_DOOR, DATA_SINDRAGOSA, DOOR_TYPE_PASSAGE }, + {GO_ICE_WALL, DATA_SINDRAGOSA, DOOR_TYPE_ROOM }, + {GO_ICE_WALL, DATA_SINDRAGOSA, DOOR_TYPE_ROOM }, + {0, 0, DOOR_TYPE_ROOM } // END }; // this doesnt have to only store questgivers, also can be used for related quest spawns @@ -115,6 +135,7 @@ class instance_icecrown_citadel : public InstanceMapScript { SetHeaders(DataHeader); SetBossNumber(EncounterCount); + LoadBossBoundaries(boundaries); LoadDoorData(doorData); TeamInInstance = 0; HeroicAttempts = MaxHeroicAttempts; diff --git a/src/server/scripts/Northrend/Naxxramas/boss_anubrekhan.cpp b/src/server/scripts/Northrend/Naxxramas/boss_anubrekhan.cpp index 11fe5f41455..e8c4216b00e 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_anubrekhan.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_anubrekhan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -173,7 +173,7 @@ public: void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; events.Update(diff); diff --git a/src/server/scripts/Northrend/Naxxramas/boss_faerlina.cpp b/src/server/scripts/Northrend/Naxxramas/boss_faerlina.cpp index dd9061603c8..39c41c935bf 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_faerlina.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_faerlina.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Naxxramas/boss_four_horsemen.cpp b/src/server/scripts/Northrend/Naxxramas/boss_four_horsemen.cpp index 3ef6a7c15e3..a7a89f44d81 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_four_horsemen.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_four_horsemen.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -15,382 +15,681 @@ * with this program. If not, see <http://www.gnu.org/licenses/>. */ +#include "Player.h" #include "ScriptMgr.h" #include "ScriptedCreature.h" #include "SpellScript.h" #include "SpellAuraEffects.h" #include "naxxramas.h" -enum Horsemen +enum Horseman { - HORSEMEN_THANE, - HORSEMEN_LADY, - HORSEMEN_BARON, - HORSEMEN_SIR, + THANE = DATA_THANE, + LADY = DATA_LADY, + BARON = DATA_BARON, + SIR = DATA_SIR, }; +static const std::vector<Horseman> horsemen = { THANE, LADY, BARON, SIR }; // for iterating enum Spells { - SPELL_MARK_DAMAGE = 28836 + /* all */ + SPELL_MARK_DAMAGE = 28836, + SPELL_BERSERK = 26662, + SPELL_ENCOUNTER_CREDIT = 59450, + + /* baron */ + SPELL_BARON_MARK = 28834, + SPELL_UNHOLY_SHADOW = 28882, + + /* thane */ + SPELL_THANE_MARK = 28832, + SPELL_METEOR = 28884, + + /* lady */ + SPELL_SHADOW_BOLT = 57374, + SPELL_LADY_MARK = 28833, + SPELL_VOID_ZONE = 28863, + SPELL_UNYIELDING_PAIN = 57381, + + /* sir */ + SPELL_HOLY_BOLT = 57376, + SPELL_SIR_MARK = 28835, + SPELL_HOLY_WRATH = 28883, + SPELL_CONDEMNATION = 57377 }; -enum Events +enum Actions { - EVENT_NONE, - EVENT_MARK, - EVENT_CAST, - EVENT_BERSERK, + ACTION_BEGIN_MOVEMENT = 1, + ACTION_BEGIN_FIGHTING +}; + +enum HorsemenData +{ + DATA_HORSEMEN_IS_TIMED_KILL = Data::DATA_HORSEMEN_CHECK_ACHIEVEMENT_CREDIT, // inherit from naxxramas.h - this needs to be the first entry to ensure that there are no conflicts + DATA_MOVEMENT_FINISHED, + DATA_DEATH_TIME }; -const Position WaypointPositions[12] = +enum Events { - // Thane waypoints - {2542.3f, -2984.1f, 241.49f, 5.362f}, - {2547.6f, -2999.4f, 241.34f, 5.049f}, - {2542.9f, -3015.0f, 241.35f, 4.654f}, - // Lady waypoints - {2498.3f, -2961.8f, 241.28f, 3.267f}, - {2487.7f, -2959.2f, 241.28f, 2.890f}, - {2469.4f, -2947.6f, 241.28f, 2.576f}, - // Baron waypoints - {2553.8f, -2968.4f, 241.33f, 5.757f}, - {2564.3f, -2972.5f, 241.33f, 5.890f}, - {2583.9f, -2971.67f, 241.35f, 0.008f}, - // Sir waypoints - {2534.5f, -2921.7f, 241.53f, 1.363f}, - {2523.5f, -2902.8f, 241.28f, 2.095f}, - {2517.8f, -2896.6f, 241.28f, 2.315f}, + /* all */ + EVENT_BERSERK = 1, + EVENT_MARK, + + /* rivendare */ + EVENT_UNHOLYSHADOW, + + /* thane */ + EVENT_METEOR, + + /* lady */ + EVENT_VOIDZONE, + + /* sir */ + EVENT_HOLYWRATH }; -const uint32 NPC_HORSEMEN[] = {16064, 16065, 30549, 16063}; -const uint32 SPELL_MARK[] = {28832, 28833, 28834, 28835}; -#define SPELL_PRIMARY(i) RAID_MODE(SPELL_PRIMARY_N[i], SPELL_PRIMARY_H[i]) -const uint32 SPELL_PRIMARY_N[] = {28884, 28863, 28882, 28883}; -const uint32 SPELL_PRIMARY_H[] = {57467, 57463, 57369, 57466}; -#define SPELL_SECONDARY(i) RAID_MODE(SPELL_SECONDARY_N[i], SPELL_SECONDARY_H[i]) -const uint32 SPELL_SECONDARY_N[]= {0, 57374, 0, 57376}; -const uint32 SPELL_SECONDARY_H[]= {0, 57464, 0, 57465}; -const uint32 SPELL_PUNISH[] = {0, 57381, 0, 57377}; -#define SPELL_BERSERK 26662 - -enum FourHorsemen +enum Yells { SAY_AGGRO = 0, - SAY_TAUNT = 1, SAY_SPECIAL = 2, SAY_SLAY = 3, - SAY_DEATH = 4 -}; + SAY_DEATH = 4, -class boss_four_horsemen : public CreatureScript -{ -public: - boss_four_horsemen() : CreatureScript("boss_four_horsemen") { } + EMOTE_RAGECAST = 7 +}; - CreatureAI* GetAI(Creature* creature) const override - { - return GetInstanceAI<boss_four_horsemenAI>(creature); - } +static const Position baronPath[3] = { { 2552.427f, -2969.737f, 241.3021f },{ 2566.759f, -2972.535f, 241.3217f },{ 2584.32f, -2971.96f, 241.3489f } }; +static const Position thanePath[3] = { { 2540.095f, -2983.192f, 241.3344f },{ 2546.005f, -2999.826f, 241.3665f },{ 2542.697f, -3014.055f, 241.3371f } }; +static const Position ladyPath[3] = { { 2507.94f, -2961.444f, 242.4557f },{ 2488.763f, -2960.007f, 241.2757f },{ 2468.26f, -2947.499f, 241.2753f } }; +static const Position sirPath[3] = { { 2533.141f, -2922.14f, 241.2764f },{ 2525.254f, -2905.907f, 241.2761f },{ 2517.636f, -2897.253f, 241.2758f } }; - struct boss_four_horsemenAI : public BossAI - { - boss_four_horsemenAI(Creature* creature) : BossAI(creature, BOSS_HORSEMEN) +struct boss_four_horsemen_baseAI : public BossAI +{ + public: + Creature* getHorsemanHandle(Horseman who) const { - Initialize(); - id = Horsemen(0); - for (uint8 i = 0; i < 4; ++i) - if (me->GetEntry() == NPC_HORSEMEN[i]) - id = Horsemen(i); - caster = (id == HORSEMEN_LADY || id == HORSEMEN_SIR); + if (_which == who) + return me; + else + return ObjectAccessor::GetCreature(*me, instance->GetGuidData(who)); } - - void Initialize() + boss_four_horsemen_baseAI(Creature* creature, Horseman which, Position const* initialPath) : + BossAI(creature, BOSS_HORSEMEN), _which(which), _initialPath(initialPath), _myMovementFinished(false), _nextMovement(0), _timeDied(0), _ourMovementFinished(false) { - uiEventStarterGUID.Clear(); - nextWP = 0; - punishTimer = 2000; - nextMovementStarted = false; - movementCompleted = false; - movementStarted = false; - encounterActionAttack = false; - encounterActionReset = false; - doDelayPunish = false; + if (!me->IsAlive() && instance->GetBossState(BOSS_HORSEMEN) != DONE) + me->SetRespawnTime(10); } - Horsemen id; - ObjectGuid uiEventStarterGUID; - uint8 nextWP; - uint32 punishTimer; - bool caster; - bool nextMovementStarted; - bool movementCompleted; - bool movementStarted; - bool encounterActionAttack; - bool encounterActionReset; - bool doDelayPunish; - - void Reset() override + uint32 GetData(uint32 type) const override { - if (!encounterActionReset) - DoEncounteraction(NULL, false, true, false); - - instance->SetData(DATA_HORSEMEN0 + id, NOT_STARTED); - - me->SetReactState(REACT_AGGRESSIVE); - Initialize(); - _Reset(); + switch (type) + { + case DATA_MOVEMENT_FINISHED: + return _myMovementFinished ? 1 : 0; + case DATA_DEATH_TIME: + return _timeDied; + case DATA_HORSEMEN_IS_TIMED_KILL: + { + uint32 minTime = 0, maxTime = 0; + for (Horseman boss : horsemen) + if (Creature* cBoss = getHorsemanHandle(boss)) + { + uint32 deathTime = cBoss->AI()->GetData(DATA_DEATH_TIME); + if (!deathTime) + { + TC_LOG_WARN("scripts", "FourHorsemenAI: Checking for achievement credit but horseman %s is reporting not dead", cBoss->GetName().c_str()); + return 0; + } + if (!minTime || deathTime < minTime) + minTime = deathTime; + if (!maxTime || deathTime > maxTime) + maxTime = deathTime; + } + else + { + TC_LOG_WARN("scripts", "FourHorsemenAI: Checking for achievement credit but horseman with id %u is not present", uint32(boss)); + return 0; + } + return (getMSTimeDiff(minTime, maxTime) <= 15 * IN_MILLISECONDS) ? 1 : 0; + } + default: + return 0; + } } - bool DoEncounteraction(Unit* who, bool attack, bool reset, bool checkAllDead) + void DoAction(int32 action) override { - Creature* Thane = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_THANE)); - Creature* Lady = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_LADY)); - Creature* Baron = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_BARON)); - Creature* Sir = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_SIR)); + switch (action) + { + case ACTION_BEGIN_MOVEMENT: + me->GetMotionMaster()->MovePoint(1, _initialPath[0], true); + break; + case ACTION_BEGIN_FIGHTING: + if (_ourMovementFinished) + break; + me->SetCombatPulseDelay(5); + BeginFighting(); + _ourMovementFinished = true; + break; + } + } - if (Thane && Lady && Baron && Sir) + void CheckIsMovementFinished() + { + for (Horseman boss : horsemen) { - if (attack && who) + if (Creature* cBoss = getHorsemanHandle(boss)) { - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Thane->AI())->encounterActionAttack = true; - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Lady->AI())->encounterActionAttack = true; - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Baron->AI())->encounterActionAttack = true; - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Sir->AI())->encounterActionAttack = true; - - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Thane->AI())->AttackStart(who); - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Lady->AI())->AttackStart(who); - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Baron->AI())->AttackStart(who); - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Sir->AI())->AttackStart(who); + if (cBoss->IsAlive() && !cBoss->AI()->GetData(DATA_MOVEMENT_FINISHED)) + return; } - - if (reset) + else { - if (instance->GetBossState(BOSS_HORSEMEN) != NOT_STARTED) - { - if (!Thane->IsAlive()) - Thane->Respawn(); - - if (!Lady->IsAlive()) - Lady->Respawn(); + TC_LOG_WARN("scripts", "FourHorsemenAI: Checking if movement is finished but horseman with id %u is not present", uint32(boss)); + ResetEncounter(); + return; + } + } - if (!Baron->IsAlive()) - Baron->Respawn(); + for (Horseman boss : horsemen) + if (Creature* cBoss = getHorsemanHandle(boss)) + cBoss->AI()->DoAction(ACTION_BEGIN_FIGHTING); + } - if (!Sir->IsAlive()) - Sir->Respawn(); + void BeginEncounter() + { + if (instance->GetBossState(BOSS_HORSEMEN) == IN_PROGRESS) + return; + if (!instance->CheckRequiredBosses(BOSS_HORSEMEN)) + { + ResetEncounter(); + return; + } + instance->SetBossState(BOSS_HORSEMEN, IN_PROGRESS); + Map::PlayerList const &players = me->GetMap()->GetPlayers(); + if (players.isEmpty()) // sanity check + ResetEncounter(); - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Thane->AI())->encounterActionReset = true; - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Lady->AI())->encounterActionReset = true; - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Baron->AI())->encounterActionReset = true; - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Sir->AI())->encounterActionReset = true; + for (Horseman boss : horsemen) + { + if (Creature* cBoss = getHorsemanHandle(boss)) + { + if (!cBoss->IsAlive()) + { + ResetEncounter(); + return; + } + cBoss->SetReactState(REACT_PASSIVE); + cBoss->AttackStop(); // clear initial target that was set on enter combat + cBoss->setActive(true); - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Thane->AI())->EnterEvadeMode(); - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Lady->AI())->EnterEvadeMode(); - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Baron->AI())->EnterEvadeMode(); - ENSURE_AI(boss_four_horsemen::boss_four_horsemenAI, Sir->AI())->EnterEvadeMode(); + for (Map::PlayerList::const_iterator it = players.begin(); it != players.end(); ++it) + { + if (Player* player = it->GetSource()) + { + if (player->IsGameMaster()) + continue; + + if (player->IsAlive()) + { + cBoss->AddThreat(player, 0.0f); + cBoss->SetInCombatWith(player); + player->SetInCombatWith(cBoss); + } + } } - } - if (checkAllDead) - return !Thane->IsAlive() && !Lady->IsAlive() && !Baron->IsAlive() && !Sir->IsAlive(); + /* Why do the Four Horsemen run to opposite corners of the room when engaged? * + * They saw all the mobs leading up to them being AoE'd down and made a judgment call. */ + cBoss->AI()->DoAction(ACTION_BEGIN_MOVEMENT); + } + else + { + TC_LOG_WARN("scripts", "FourHorsemenAI: Encounter starting but horseman with id %u is not present", uint32(boss)); + ResetEncounter(); + return; + } } - return false; } - void BeginFourHorsemenMovement() + void ResetEncounter() { - movementStarted = true; - me->SetReactState(REACT_PASSIVE); - me->SetWalk(false); - me->SetSpeed(MOVE_RUN, me->GetSpeedRate(MOVE_RUN), true); - - switch (id) + if (instance->GetBossState(BOSS_HORSEMEN) == NOT_STARTED || instance->GetBossState(BOSS_HORSEMEN) == DONE) + return; + instance->SetBossState(BOSS_HORSEMEN, NOT_STARTED); + for (Horseman boss : horsemen) { - case HORSEMEN_THANE: - me->GetMotionMaster()->MovePoint(0, WaypointPositions[0]); - break; - case HORSEMEN_LADY: - me->GetMotionMaster()->MovePoint(3, WaypointPositions[3]); - break; - case HORSEMEN_BARON: - me->GetMotionMaster()->MovePoint(6, WaypointPositions[6]); - break; - case HORSEMEN_SIR: - me->GetMotionMaster()->MovePoint(9, WaypointPositions[9]); - break; + if (Creature* cBoss = getHorsemanHandle(boss)) + { + cBoss->DespawnOrUnsummon(0); + cBoss->SetRespawnTime(15); + } + else + { + TC_LOG_WARN("scripts", "FourHorsemenAI: Encounter resetting but horseman with id %u is not present", uint32(boss)); + } } } - void MovementInform(uint32 type, uint32 point) override + void EncounterCleared() { - if (type != POINT_MOTION_TYPE) + if (instance->GetBossState(BOSS_HORSEMEN) == DONE) return; + instance->SetBossState(BOSS_HORSEMEN, DONE); + //instance->DoUpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_BE_SPELL_TARGET, SPELL_ENCOUNTER_CREDIT); + DoCastAOE(SPELL_ENCOUNTER_CREDIT, true); + } - if (point == 2 || point == 5 || point == 8 || point == 11) - { - movementCompleted = true; - me->SetReactState(REACT_AGGRESSIVE); + void EnterCombat(Unit* /*who*/) override + { + if (instance->GetBossState(BOSS_HORSEMEN) != NOT_STARTED) // another horseman already did it + return; + Talk(SAY_AGGRO); + BeginEncounter(); + } + + void EnterEvadeMode(EvadeReason /*why*/) override + { + ResetEncounter(); + } + + void Reset() override + { + if (!me->IsAlive()) + return; + _myMovementFinished = false; + _nextMovement = 0; + _timeDied = 0; + _ourMovementFinished = false; + me->SetReactState(REACT_AGGRESSIVE); + SetCombatMovement(false); + me->SetCombatPulseDelay(0); + me->ResetLootMode(); + events.Reset(); + summons.DespawnAll(); + } + + void KilledUnit(Unit* victim) override + { + if (victim->GetTypeId() == TYPEID_PLAYER) + Talk(SAY_SLAY, victim); + } - Unit* eventStarter = ObjectAccessor::GetUnit(*me, uiEventStarterGUID); + void JustDied(Unit* /*killer*/) override + { + if (instance->GetBossState(BOSS_HORSEMEN) != IN_PROGRESS) // necessary in case a horseman gets one-shot + { + BeginEncounter(); + return; + } - if (eventStarter && me->IsValidAttackTarget(eventStarter)) - AttackStart(eventStarter); - else if (!UpdateVictim()) + Talk(SAY_DEATH); + _timeDied = getMSTime(); + for (Horseman boss : horsemen) + { + if (Creature* cBoss = getHorsemanHandle(boss)) { - EnterEvadeMode(); - return; + if (cBoss->IsAlive()) + { + // in case a horseman dies while moving (unlikely but possible especially in non-335 branch) + CheckIsMovementFinished(); + return; + } } - - if (caster) + else { - me->GetMotionMaster()->Clear(); - me->GetMotionMaster()->MoveIdle(); + TC_LOG_WARN("scripts", "FourHorsemenAI: %s died but horseman with id %u is not present", me->GetName().c_str(), uint32(boss)); + ResetEncounter(); } - - return; } - nextMovementStarted = false; - nextWP = point + 1; + EncounterCleared(); } - // switch to "who" if nearer than current target. - void SelectNearestTarget(Unit* who) + void MovementInform(uint32 type, uint32 i) override { - if (me->GetVictim() && me->GetDistanceOrder(who, me->GetVictim()) && me->IsValidAttackTarget(who)) + if (type != POINT_MOTION_TYPE) + return; + if (i < 3) + _nextMovement = i; // delay to next updateai to prevent it from instantly expiring + else { - me->getThreatManager().modifyThreatPercent(me->GetVictim(), -100); - me->AddThreat(who, 1000000.0f); + _myMovementFinished = true; + CheckIsMovementFinished(); } } - void MoveInLineOfSight(Unit* who) override - + void UpdateAI(uint32 diff) override { - BossAI::MoveInLineOfSight(who); - if (caster) - SelectNearestTarget(who); + if (_nextMovement) + { + me->GetMotionMaster()->MovePoint(_nextMovement + 1, _initialPath[_nextMovement], true); + _nextMovement = 0; + } + _UpdateAI(diff); } - void AttackStart(Unit* who) override + virtual void BeginFighting() = 0; + virtual void _UpdateAI(uint32 /*diff*/) = 0; + + private: + const Horseman _which; + const Position* _initialPath; + bool _myMovementFinished; + uint8 _nextMovement; + uint32 _timeDied; + protected: + bool _ourMovementFinished; +}; + +class boss_four_horsemen_baron : public CreatureScript +{ + public: + boss_four_horsemen_baron() : CreatureScript("boss_four_horsemen_baron") { } + + struct boss_four_horsemen_baronAI : public boss_four_horsemen_baseAI { - if (!movementCompleted && !movementStarted) + boss_four_horsemen_baronAI(Creature* creature) : boss_four_horsemen_baseAI(creature, BARON, baronPath) { } + void BeginFighting() override { - uiEventStarterGUID = who->GetGUID(); - BeginFourHorsemenMovement(); + SetCombatMovement(true); + me->SetReactState(REACT_AGGRESSIVE); + ThreatManager& threat = me->getThreatManager(); + if (threat.isThreatListEmpty()) + { + if (Unit* nearest = me->SelectNearestPlayer(5000.0f)) + { + me->AddThreat(nearest, 1.0f); + AttackStart(nearest); + } + else + ResetEncounter(); + } + else + AttackStart(threat.getHostilTarget()); - if (!encounterActionAttack) - DoEncounteraction(who, true, false, false); + events.ScheduleEvent(EVENT_BERSERK, 10 * MINUTE * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_MARK, 24 * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_UNHOLYSHADOW, urandms(3,7)); } - else if (movementCompleted && movementStarted) + + void _UpdateAI(uint32 diff) override { - if (caster) - me->Attack(who, false); - else - BossAI::AttackStart(who); + if (!_ourMovementFinished || !UpdateVictim()) + return; + events.Update(diff); + + while (uint32 eventId = events.ExecuteEvent()) + { + switch (eventId) + { + case EVENT_BERSERK: + DoCastAOE(SPELL_BERSERK, true); + break; + case EVENT_MARK: + DoCastAOE(SPELL_BARON_MARK, true); + events.ScheduleEvent(EVENT_MARK, 12 * IN_MILLISECONDS); + break; + case EVENT_UNHOLYSHADOW: + DoCastVictim(SPELL_UNHOLY_SHADOW); + events.ScheduleEvent(EVENT_UNHOLYSHADOW, urandms(10,30)); + break; + } + } + + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; + DoMeleeAttackIfReady(); } - } - void KilledUnit(Unit* /*victim*/) override + void SpellHitTarget(Unit* /*target*/, SpellInfo const* spell) override + { + if (spell->Id == SPELL_UNHOLY_SHADOW) + Talk(SAY_SPECIAL); + } + }; + + CreatureAI* GetAI(Creature* creature) const override { - if (!(rand32() % 5)) - Talk(SAY_SLAY); + return GetInstanceAI<boss_four_horsemen_baronAI>(creature); } +}; - void JustDied(Unit* /*killer*/) override - { - events.Reset(); - summons.DespawnAll(); +class boss_four_horsemen_thane : public CreatureScript +{ + public: + boss_four_horsemen_thane() : CreatureScript("boss_four_horsemen_thane") { } - instance->SetData(DATA_HORSEMEN0 + id, DONE); + struct boss_four_horsemen_thaneAI : public boss_four_horsemen_baseAI + { + boss_four_horsemen_thaneAI(Creature* creature) : boss_four_horsemen_baseAI(creature, THANE, thanePath), _shouldSay(true) { } + void BeginFighting() override + { + SetCombatMovement(true); + me->SetReactState(REACT_AGGRESSIVE); + ThreatManager& threat = me->getThreatManager(); + if (threat.isThreatListEmpty()) + { + if (Unit* nearest = me->SelectNearestPlayer(5000.0f)) + { + me->AddThreat(nearest, 1.0f); + AttackStart(nearest); + } + else + ResetEncounter(); + } + else + AttackStart(threat.getHostilTarget()); - if (DoEncounteraction(NULL, false, false, true)) + events.ScheduleEvent(EVENT_BERSERK, 10 * MINUTE * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_MARK, 24 * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_METEOR, urandms(10,15)); + } + void _UpdateAI(uint32 diff) override { - instance->SetBossState(BOSS_HORSEMEN, DONE); - instance->SaveToDB(); + if (!_ourMovementFinished || !UpdateVictim()) + return; + events.Update(diff); + + while (uint32 eventId = events.ExecuteEvent()) + { + switch (eventId) + { + case EVENT_BERSERK: + DoCastAOE(SPELL_BERSERK, true); + break; + case EVENT_MARK: + DoCastAOE(SPELL_THANE_MARK, true); + events.ScheduleEvent(EVENT_MARK, 12 * IN_MILLISECONDS); + break; + case EVENT_METEOR: + if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 20.0f, true)) + { + DoCast(target, SPELL_METEOR); + _shouldSay = true; + } + events.ScheduleEvent(EVENT_METEOR, urandms(13,17)); + break; + } + } - // Achievements related to the 4-horsemen are given through spell 59450 which does not exist. - // There is thus no way it can be given by casting the spell on the players. - instance->DoUpdateAchievementCriteria(ACHIEVEMENT_CRITERIA_TYPE_BE_SPELL_TARGET, 59450); + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; + DoMeleeAttackIfReady(); } - Talk(SAY_DEATH); - } + void SpellHitTarget(Unit* /*target*/, SpellInfo const* spell) override + { + if (_shouldSay && spell->Id == SPELL_METEOR) + { + Talk(SAY_SPECIAL); + _shouldSay = false; + } + } - void EnterCombat(Unit* /*who*/) override - { - _EnterCombat(); - Talk(SAY_AGGRO); + private: + bool _shouldSay; // throttle to make sure we only talk on first target hit by meteor + }; - events.ScheduleEvent(EVENT_MARK, 15000); - events.ScheduleEvent(EVENT_CAST, 20000 + rand32() % 5000); - events.ScheduleEvent(EVENT_BERSERK, 15*100*1000); + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<boss_four_horsemen_thaneAI>(creature); } +}; - void UpdateAI(uint32 diff) override +class boss_four_horsemen_lady : public CreatureScript +{ + public: + boss_four_horsemen_lady() : CreatureScript("boss_four_horsemen_lady") { } + + struct boss_four_horsemen_ladyAI : public boss_four_horsemen_baseAI { - if (nextWP && movementStarted && !movementCompleted && !nextMovementStarted) + boss_four_horsemen_ladyAI(Creature* creature) : boss_four_horsemen_baseAI(creature, LADY, ladyPath) { } + void BeginFighting() override { - nextMovementStarted = true; - me->GetMotionMaster()->MovePoint(nextWP, WaypointPositions[nextWP]); + events.ScheduleEvent(EVENT_BERSERK, 10 * MINUTE * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_MARK, 24 * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_VOIDZONE, urandms(5,10)); } - if (!UpdateVictim() || !CheckInRoom() || !movementCompleted) - return; + void _UpdateAI(uint32 diff) override + { + if (!me->IsInCombat()) + return; + if (!_ourMovementFinished) + return; + if (me->getThreatManager().isThreatListEmpty()) + { + EnterEvadeMode(EVADE_REASON_NO_HOSTILES); + return; + } - events.Update(diff); + events.Update(diff); - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; + while (uint32 eventId = events.ExecuteEvent()) + { + switch (eventId) + { + case EVENT_BERSERK: + DoCastAOE(SPELL_BERSERK, true); + break; + case EVENT_MARK: + DoCastAOE(SPELL_LADY_MARK, true); + events.ScheduleEvent(EVENT_MARK, 15 * IN_MILLISECONDS); + break; + case EVENT_VOIDZONE: + if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 45.0f, true)) + { + DoCast(target, SPELL_VOID_ZONE, true); + Talk(SAY_SPECIAL); + } + events.ScheduleEvent(EVENT_VOIDZONE, urandms(12, 18)); + break; + } + } + + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; + + if (Unit* target = SelectTarget(SELECT_TARGET_NEAREST, 0, 45.0f, true)) + DoCast(target, SPELL_SHADOW_BOLT); + else + { + DoCastAOE(SPELL_UNYIELDING_PAIN); + Talk(EMOTE_RAGECAST); + } + } + }; + + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<boss_four_horsemen_ladyAI>(creature); + } +}; + +class boss_four_horsemen_sir : public CreatureScript +{ + public: + boss_four_horsemen_sir() : CreatureScript("boss_four_horsemen_sir") { } - while (uint32 eventId = events.ExecuteEvent()) + struct boss_four_horsemen_sirAI : public boss_four_horsemen_baseAI + { + boss_four_horsemen_sirAI(Creature* creature) : boss_four_horsemen_baseAI(creature, SIR, sirPath), _shouldSay(true) { } + void BeginFighting() override { - switch (eventId) + events.ScheduleEvent(EVENT_BERSERK, 10 * MINUTE * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_MARK, 24 * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_HOLYWRATH, urandms(13,18)); + } + + void _UpdateAI(uint32 diff) override + { + if (!me->IsInCombat()) + return; + if (!_ourMovementFinished) + return; + if (me->getThreatManager().isThreatListEmpty()) { - case EVENT_MARK: - if (!(rand32() % 5)) - Talk(SAY_SPECIAL); - DoCastAOE(SPELL_MARK[id]); - events.ScheduleEvent(EVENT_MARK, 15000); - break; - case EVENT_CAST: - if (!(rand32() % 5)) - Talk(SAY_TAUNT); + EnterEvadeMode(EVADE_REASON_NO_HOSTILES); + return; + } - if (caster) - { - if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0, 45.0f, true)) - DoCast(target, SPELL_PRIMARY(id)); - } - else - DoCastVictim(SPELL_PRIMARY(id)); + events.Update(diff); - events.ScheduleEvent(EVENT_CAST, 15000); - break; - case EVENT_BERSERK: - Talk(SAY_SPECIAL); - DoCast(me, EVENT_BERSERK); - break; + while (uint32 eventId = events.ExecuteEvent()) + { + switch (eventId) + { + case EVENT_BERSERK: + DoCastAOE(SPELL_BERSERK, true); + break; + case EVENT_MARK: + DoCastAOE(SPELL_SIR_MARK, true); + events.ScheduleEvent(EVENT_MARK, 15 * IN_MILLISECONDS); + break; + case EVENT_HOLYWRATH: + if (Unit* target = SelectTarget(SELECT_TARGET_NEAREST, 0, 45.0f, true)) + { + DoCast(target, SPELL_HOLY_WRATH, true); + _shouldSay = true; + } + events.ScheduleEvent(EVENT_HOLYWRATH, urandms(10,18)); + break; + } + } + + if (me->HasUnitState(UNIT_STATE_CASTING)) + return; + + if (Unit* target = SelectTarget(SELECT_TARGET_NEAREST, 0, 45.0f, true)) + DoCast(target, SPELL_HOLY_BOLT); + else + { + DoCastAOE(SPELL_CONDEMNATION); + Talk(EMOTE_RAGECAST); } } - if (punishTimer <= diff) + void SpellHitTarget(Unit* /*target*/, SpellInfo const* spell) override { - if (doDelayPunish) + if (_shouldSay && spell->Id == SPELL_HOLY_WRATH) { - DoCastAOE(SPELL_PUNISH[id], true); - doDelayPunish = false; + Talk(SAY_SPECIAL); + _shouldSay = false; } - punishTimer = 2000; - } else punishTimer -= diff; + } - if (!caster) - DoMeleeAttackIfReady(); - else if ((!DoSpellAttackIfReady(SPELL_SECONDARY(id)) || !me->IsWithinLOSInMap(me->GetVictim())) && movementCompleted && !doDelayPunish) - doDelayPunish = true; - } - }; + private: + bool _shouldSay; // throttle to make sure we only talk on first target hit by holy wrath + }; + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<boss_four_horsemen_sirAI>(creature); + } }; class spell_four_horsemen_mark : public SpellScriptLoader @@ -450,6 +749,9 @@ class spell_four_horsemen_mark : public SpellScriptLoader void AddSC_boss_four_horsemen() { - new boss_four_horsemen(); + new boss_four_horsemen_baron(); + new boss_four_horsemen_thane(); + new boss_four_horsemen_lady(); + new boss_four_horsemen_sir(); new spell_four_horsemen_mark(); } diff --git a/src/server/scripts/Northrend/Naxxramas/boss_gluth.cpp b/src/server/scripts/Northrend/Naxxramas/boss_gluth.cpp index fb1378f0124..ec47b0db101 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_gluth.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_gluth.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -100,7 +100,7 @@ public: void UpdateAI(uint32 diff) override { - if (!UpdateVictimWithGaze() || !CheckInRoom()) + if (!UpdateVictimWithGaze()) return; events.Update(diff); diff --git a/src/server/scripts/Northrend/Naxxramas/boss_gothik.cpp b/src/server/scripts/Northrend/Naxxramas/boss_gothik.cpp index 3778d8d25a0..be12894ebea 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_gothik.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_gothik.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -20,30 +20,70 @@ #include "SpellScript.h" #include "GridNotifiers.h" #include "CombatAI.h" +#include "AreaBoundary.h" #include "naxxramas.h" +/* Constants */ enum Yells { - SAY_SPEECH = 0, - SAY_KILL = 1, - SAY_DEATH = 2, - SAY_TELEPORT = 3 + SAY_INTRO_1 = 0, + SAY_INTRO_2 = 1, + SAY_INTRO_3 = 2, + SAY_INTRO_4 = 3, + SAY_PHASE_TWO = 4, + SAY_DEATH = 5, + SAY_KILL = 6, + + EMOTE_PHASE_TWO = 7, + EMOTE_GATE_OPENED = 8 }; -//Gothik enum Spells { + /* living trainee spells */ + SPELL_DEATH_PLAGUE = 55604, + + /* living knight spells */ + SPELL_SHADOW_MARK = 27825, + + /* living rider spells */ + SPELL_SHADOW_BOLT_VOLLEY = 27831, + + /* spectral trainee spells */ + SPELL_ARCANE_EXPLOSION = 27989, + + /* spectral knight spells */ + SPELL_WHIRLWIND = 56408, + + /* spectral rider spells */ + SPELL_DRAIN_LIFE = 27994, + SPELL_UNHOLY_FRENZY = 55648, + + /* spectral horse spells */ + SPELL_STOMP = 27993, + + /* gothik phase two spells */ SPELL_HARVEST_SOUL = 28679, SPELL_SHADOW_BOLT = 29317, - SPELL_INFORM_LIVE_TRAINEE = 27892, - SPELL_INFORM_LIVE_KNIGHT = 27928, - SPELL_INFORM_LIVE_RIDER = 27935, - SPELL_INFORM_DEAD_TRAINEE = 27915, - SPELL_INFORM_DEAD_KNIGHT = 27931, - SPELL_INFORM_DEAD_RIDER = 27937, - - SPELL_SHADOW_MARK = 27825 + + /* visual spells */ + SPELL_ANCHOR_1_TRAINEE = 27892, + SPELL_ANCHOR_1_DK = 27928, + SPELL_ANCHOR_1_RIDER = 27935, + + SPELL_ANCHOR_2_TRAINEE = 27893, + SPELL_ANCHOR_2_DK = 27929, + SPELL_ANCHOR_2_RIDER = 27936, + + SPELL_SKULLS_TRAINEE = 27915, + SPELL_SKULLS_DK = 27931, + SPELL_SKULLS_RIDER = 27937, + + /* teleport spells */ + SPELL_TELEPORT_DEAD = 28025, + SPELL_TELEPORT_LIVE = 28026 }; +#define SPELLHELPER_UNHOLY_FRENZY RAID_MODE<uint32>(SPELL_UNHOLY_FRENZY,27995) enum Creatures { @@ -53,108 +93,205 @@ enum Creatures NPC_DEAD_TRAINEE = 16127, NPC_DEAD_KNIGHT = 16148, NPC_DEAD_RIDER = 16150, - NPC_DEAD_HORSE = 16149 + NPC_DEAD_HORSE = 16149, + + NPC_TRIGGER = 16137 }; -struct Waves { uint32 entry, time, mode; }; -// wave setups are not the same in heroic and normal difficulty, -// mode is 0 only normal, 1 both and 2 only heroic -// but this is handled in DoGothikSummon function -const Waves waves[] = +enum Phases { - {NPC_LIVE_TRAINEE, 20000, 1}, - {NPC_LIVE_TRAINEE, 20000, 1}, - {NPC_LIVE_TRAINEE, 10000, 1}, - {NPC_LIVE_KNIGHT, 10000, 1}, - {NPC_LIVE_TRAINEE, 15000, 1}, - {NPC_LIVE_KNIGHT, 5000, 1}, - {NPC_LIVE_TRAINEE, 20000, 1}, - {NPC_LIVE_TRAINEE, 0, 1}, - {NPC_LIVE_KNIGHT, 10000, 1}, - {NPC_LIVE_TRAINEE, 10000, 2}, - {NPC_LIVE_RIDER, 10000, 0}, - {NPC_LIVE_RIDER, 5000, 2}, - {NPC_LIVE_TRAINEE, 5000, 0}, - {NPC_LIVE_TRAINEE, 15000, 2}, - {NPC_LIVE_KNIGHT, 15000, 0}, - {NPC_LIVE_TRAINEE, 0, 0}, - {NPC_LIVE_RIDER, 10000, 1}, - {NPC_LIVE_KNIGHT, 10000, 1}, - {NPC_LIVE_TRAINEE, 10000, 0}, - {NPC_LIVE_RIDER, 10000, 2}, - {NPC_LIVE_TRAINEE, 0, 2}, - {NPC_LIVE_RIDER, 5000, 1}, - {NPC_LIVE_TRAINEE, 0, 2}, - {NPC_LIVE_KNIGHT, 5000, 1}, - {NPC_LIVE_RIDER, 0, 2}, - {NPC_LIVE_TRAINEE, 20000, 1}, - {NPC_LIVE_RIDER, 0, 1}, - {NPC_LIVE_KNIGHT, 0, 1}, - {NPC_LIVE_TRAINEE, 25000, 2}, - {NPC_LIVE_TRAINEE, 15000, 0}, - {NPC_LIVE_TRAINEE, 25000, 0}, - {0, 0, 1}, + PHASE_ONE = 1, + PHASE_TWO = 2 }; -#define POS_Y_GATE -3360.78f -#define POS_Y_WEST -3285.0f -#define POS_Y_EAST -3434.0f -#define POS_X_NORTH 2750.49f -#define POS_X_SOUTH 2633.84f - -#define IN_LIVE_SIDE(who) (who->GetPositionY() < POS_Y_GATE) - enum Events { - EVENT_NONE, + EVENT_INTRO_2 = 1, + EVENT_INTRO_3, + EVENT_INTRO_4, + EVENT_PHASE_TWO, EVENT_SUMMON, + EVENT_DOORS_UNLOCK, + EVENT_TELEPORT, EVENT_HARVEST, EVENT_BOLT, - EVENT_TELEPORT -}; -enum Pos -{ - POS_LIVE = 6, - POS_DEAD = 5 + EVENT_RESUME_ATTACK }; -const Position PosSummonLive[POS_LIVE] = +enum Actions { - {2669.7f, -3428.76f, 268.56f, 1.6f}, - {2692.1f, -3428.76f, 268.56f, 1.6f}, - {2714.4f, -3428.76f, 268.56f, 1.6f}, - {2669.7f, -3431.67f, 268.56f, 1.6f}, - {2692.1f, -3431.67f, 268.56f, 1.6f}, - {2714.4f, -3431.67f, 268.56f, 1.6f}, + ACTION_GATE_OPENED = 1, + ACTION_MINION_EVADE, + ACTION_ACQUIRE_TARGET }; -const Position PosSummonDead[POS_DEAD] = + +/* Room side checking logic */ +static AreaBoundary* const livingSide = new RectangleBoundary(2633.84f, 2750.49f, -3434.0f, -3360.78f); +static AreaBoundary* const deadSide = new RectangleBoundary(2633.84f, 2750.49f, -3360.78f, -3285.0f); +enum Side { - {2725.1f, -3310.0f, 268.85f, 3.4f}, - {2699.3f, -3322.8f, 268.60f, 3.3f}, - {2733.1f, -3348.5f, 268.84f, 3.1f}, - {2682.8f, -3304.2f, 268.85f, 3.9f}, - {2664.8f, -3340.7f, 268.23f, 3.7f}, + SIDE_NONE = 0, + SIDE_LIVING, + SIDE_DEAD }; +inline static Side GetSide(Position const* who) +{ + if (livingSide->IsWithinBoundary(who)) + return SIDE_LIVING; + if (deadSide->IsWithinBoundary(who)) + return SIDE_DEAD; + return SIDE_NONE; +} +inline static bool IsOnSameSide(Position const* who, Position const* other) +{ + return (GetSide(who) == GetSide(other)); +} +static Player* FindEligibleTarget(Creature const* me, bool isGateOpen) +{ + Map::PlayerList const& players = me->GetMap()->GetPlayers(); + for (Map::PlayerList::const_iterator it = players.begin(); it != players.end(); ++it) + { + Player* player = it->GetSource(); + if (player && (isGateOpen || IsOnSameSide(me, player)) && me->CanSeeOrDetect(player) && me->IsValidAttackTarget(player) && player->isInAccessiblePlaceFor(me)) + { + return player; + } + } -float const PosGroundLiveSide[4] = {2691.2f, -3387.0f, 267.68f, 1.52f}; -float const PosGroundDeadSide[4] = {2693.5f, -3334.6f, 267.68f, 4.67f}; -float const PosPlatform[4] = {2640.5f, -3360.6f, 285.26f, 0.0f}; + return nullptr; +} -// Predicate function to check that the r efzr unit is NOT on the same side as the source. -struct NotOnSameSide : public std::unary_function<Unit*, bool> -{ - NotOnSameSide(Unit* source) : _onLiveSide(IN_LIVE_SIDE(source)) { } - bool operator() (Unit const* target) +/* Wave data */ +typedef std::pair<uint32, uint8> GothikWaveEntry; // (npcEntry, npcCount) +typedef std::set<GothikWaveEntry> GothikWave; +typedef std::pair<GothikWave, uint8> GothikWaveInfo; // (wave, secondsToNext) +typedef std::vector<GothikWaveInfo> GothikWaveData; +const GothikWaveData waves10 = +{ { - return (_onLiveSide != IN_LIVE_SIDE(target)); - } + {{NPC_LIVE_TRAINEE, 2}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 10}, + { + {{NPC_LIVE_KNIGHT, 1}}, + 10}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 15}, + { + {{NPC_LIVE_KNIGHT, 1}}, + 5}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 2}, {NPC_LIVE_KNIGHT, 1}}, + 10}, + { + {{NPC_LIVE_RIDER, 1}}, + 10}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 5}, + { + {{NPC_LIVE_KNIGHT, 1}}, + 15}, + { + {{NPC_LIVE_TRAINEE, 2}, {NPC_LIVE_RIDER, 1}}, + 10}, + { + {{NPC_LIVE_KNIGHT, 2}}, + 10}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 10}, + { + {{NPC_LIVE_RIDER, 1}}, + 5}, + { + {{NPC_LIVE_KNIGHT, 1}}, + 5}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 20}, + { + {{NPC_LIVE_RIDER, 1}, {NPC_LIVE_KNIGHT, 1}, {NPC_LIVE_TRAINEE, 2}}, + 15}, + { + {{NPC_LIVE_TRAINEE, 2}}, + 0} +}; - private: - bool _onLiveSide; +const GothikWaveData waves25 = +{ + { + {{NPC_LIVE_TRAINEE, 3}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 10}, + { + {{NPC_LIVE_KNIGHT, 2}}, + 10}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 15}, + { + {{NPC_LIVE_KNIGHT, 2}}, + 5}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 20}, + { + {{NPC_LIVE_TRAINEE, 3}, {NPC_LIVE_KNIGHT, 2}}, + 10}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 10}, + { + {{NPC_LIVE_RIDER, 1}}, + 5}, + { + {{NPC_LIVE_TRAINEE, 3}}, + 15}, + { + {{NPC_LIVE_RIDER, 1}}, + 10}, + { + {{NPC_LIVE_KNIGHT, 2}}, + 10}, + { + {{NPC_LIVE_RIDER, 1}}, + 10}, + { + {{NPC_LIVE_RIDER, 1}, {NPC_LIVE_TRAINEE, 3}}, + 5}, + { + {{NPC_LIVE_KNIGHT, 1}, {NPC_LIVE_TRAINEE, 3}}, + 5}, + { + {{NPC_LIVE_RIDER, 1}, {NPC_LIVE_TRAINEE, 3}}, + 20}, + { + {{NPC_LIVE_RIDER, 1}, {NPC_LIVE_KNIGHT, 2}, {NPC_LIVE_TRAINEE, 3}}, + 0} }; + +// GUID of first trigger NPC (used as offset for guid checks) +// 0-1 are living side soul triggers, 2-3 are spectral side soul triggers, 4 is living rider spawn trigger, 5-7 are living other spawn trigger, 8-12 are skull pile triggers +const uint32 CGUID_TRIGGER = 127618; +/* Creature AI */ class boss_gothik : public CreatureScript { public: @@ -165,29 +302,18 @@ class boss_gothik : public CreatureScript boss_gothikAI(Creature* creature) : BossAI(creature, BOSS_GOTHIK) { Initialize(); - waveCount = 0; } void Initialize() { - mergedSides = false; - phaseTwo = false; - thirtyPercentReached = false; + _waveCount = 0; + _gateCanOpen = false; + _gateIsOpen = true; + _lastTeleportDead = false; } - uint32 waveCount; - bool mergedSides; - bool phaseTwo; - bool thirtyPercentReached; - - GuidVector LiveTriggerGUID; - GuidVector DeadTriggerGUID; - void Reset() override { - LiveTriggerGUID.clear(); - DeadTriggerGUID.clear(); - me->SetReactState(REACT_PASSIVE); instance->SetData(DATA_GOTHIK_GATE, GO_STATE_ACTIVE); _Reset(); @@ -196,43 +322,29 @@ class boss_gothik : public CreatureScript void EnterCombat(Unit* /*who*/) override { - for (uint32 i = 0; i < POS_LIVE; ++i) - if (Creature* trigger = DoSummon(WORLD_TRIGGER, PosSummonLive[i])) - LiveTriggerGUID.push_back(trigger->GetGUID()); - for (uint32 i = 0; i < POS_DEAD; ++i) - if (Creature* trigger = DoSummon(WORLD_TRIGGER, PosSummonDead[i])) - DeadTriggerGUID.push_back(trigger->GetGUID()); - - if (LiveTriggerGUID.size() < POS_LIVE || DeadTriggerGUID.size() < POS_DEAD) - { - TC_LOG_ERROR("scripts", "Script Gothik: cannot summon triggers!"); - EnterEvadeMode(); - return; - } - _EnterCombat(); - waveCount = 0; - events.ScheduleEvent(EVENT_SUMMON, 30000); - DoTeleportTo(PosPlatform); - Talk(SAY_SPEECH); + events.SetPhase(PHASE_ONE); + events.ScheduleEvent(EVENT_SUMMON, 25 * IN_MILLISECONDS, 0, PHASE_ONE); + events.ScheduleEvent(EVENT_DOORS_UNLOCK, 205 * IN_MILLISECONDS, 0, PHASE_ONE); + events.ScheduleEvent(EVENT_PHASE_TWO, 270 * IN_MILLISECONDS, 0, PHASE_ONE); + Talk(SAY_INTRO_1); + events.ScheduleEvent(EVENT_INTRO_2, 4 * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_INTRO_3, 9 * IN_MILLISECONDS); + events.ScheduleEvent(EVENT_INTRO_4, 14 * IN_MILLISECONDS); instance->SetData(DATA_GOTHIK_GATE, GO_STATE_READY); + _gateIsOpen = false; } void JustSummoned(Creature* summon) override { - if (summon->GetEntry() == WORLD_TRIGGER) - summon->setActive(true); - else if (!mergedSides) + summons.Summon(summon); + if (me->IsInCombat()) { - summon->AI()->DoAction(me->HasReactState(REACT_PASSIVE) ? 1 : 0); - summon->AI()->EnterEvadeMode(); + summon->AI()->DoAction(_gateIsOpen ? ACTION_GATE_OPENED : ACTION_ACQUIRE_TARGET); + summon->SetCombatPulseDelay(5); } else - { - summon->AI()->DoAction(0); - summon->AI()->DoZoneInCombat(); - } - summons.Summon(summon); + summon->DespawnOrUnsummon(); } void SummonedCreatureDespawn(Creature* summon) override @@ -240,256 +352,208 @@ class boss_gothik : public CreatureScript summons.Despawn(summon); } - void KilledUnit(Unit* /*victim*/) override + void KilledUnit(Unit* victim) override { - if (!(rand32() % 5)) + if (victim && victim->GetTypeId() == TYPEID_PLAYER) Talk(SAY_KILL); } void JustDied(Unit* /*killer*/) override { - LiveTriggerGUID.clear(); - DeadTriggerGUID.clear(); _JustDied(); Talk(SAY_DEATH); instance->SetData(DATA_GOTHIK_GATE, GO_STATE_ACTIVE); + _gateIsOpen = false; } - void DoGothikSummon(uint32 entry) + void OpenGate() { - if (GetDifficulty() == RAID_DIFFICULTY_25MAN_NORMAL) - { - switch (entry) - { - case NPC_LIVE_TRAINEE: - { - if (Creature* liveTrigger = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[0])) - DoSummon(NPC_LIVE_TRAINEE, liveTrigger, 1); - if (Creature* liveTrigger1 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[1])) - DoSummon(NPC_LIVE_TRAINEE, liveTrigger1, 1); - if (Creature* liveTrigger2 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[2])) - DoSummon(NPC_LIVE_TRAINEE, liveTrigger2, 1); - break; - } - case NPC_LIVE_KNIGHT: - { - if (Creature* liveTrigger3 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[3])) - DoSummon(NPC_LIVE_KNIGHT, liveTrigger3, 1); - if (Creature* liveTrigger5 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[5])) - DoSummon(NPC_LIVE_KNIGHT, liveTrigger5, 1); - break; - } - case NPC_LIVE_RIDER: - { - if (Creature* liveTrigger4 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[4])) - DoSummon(NPC_LIVE_RIDER, liveTrigger4, 1); - break; - } - } - } - else + if (_gateIsOpen) + return; + instance->SetData(DATA_GOTHIK_GATE, GO_STATE_ACTIVE); + Talk(EMOTE_GATE_OPENED); + _gateIsOpen = true; + + for (ObjectGuid summonGuid : summons) { - switch (entry) - { - case NPC_LIVE_TRAINEE: - { - if (Creature* liveTrigger = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[4])) - DoSummon(NPC_LIVE_TRAINEE, liveTrigger, 1); - if (Creature* liveTrigger2 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[4])) - DoSummon(NPC_LIVE_TRAINEE, liveTrigger2, 1); - break; - } - case NPC_LIVE_KNIGHT: - { - if (Creature* liveTrigger5 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[4])) - DoSummon(NPC_LIVE_KNIGHT, liveTrigger5, 1); - break; - } - case NPC_LIVE_RIDER: - { - if (Creature* liveTrigger4 = ObjectAccessor::GetCreature(*me, LiveTriggerGUID[4])) - DoSummon(NPC_LIVE_RIDER, liveTrigger4, 1); - break; - } - } + if (Creature* summon = ObjectAccessor::GetCreature(*me, summonGuid)) + summon->AI()->DoAction(ACTION_GATE_OPENED); + if (summons.empty()) // ACTION_GATE_OPENED may cause an evade, despawning summons and invalidating our iterator + break; } } - bool CheckGroupSplitted() + void DamageTaken(Unit* /*who*/, uint32& damage) override { - bool checklife = false; - bool checkdead = false; - Map::PlayerList const &PlayerList = me->GetMap()->GetPlayers(); - for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i) - { - if (i->GetSource() && i->GetSource()->IsAlive() && - i->GetSource()->GetPositionX() <= POS_X_NORTH && - i->GetSource()->GetPositionX() >= POS_X_SOUTH && - i->GetSource()->GetPositionY() <= POS_Y_GATE && - i->GetSource()->GetPositionY() >= POS_Y_EAST) - { - checklife = true; - } - else if (i->GetSource() && i->GetSource()->IsAlive() && - i->GetSource()->GetPositionX() <= POS_X_NORTH && - i->GetSource()->GetPositionX() >= POS_X_SOUTH && - i->GetSource()->GetPositionY() >= POS_Y_GATE && - i->GetSource()->GetPositionY() <= POS_Y_WEST) - { - checkdead = true; - } - - if (checklife && checkdead) - return true; - } - - return false; + if (!events.IsInPhase(PHASE_TWO)) + damage = 0; } - void SpellHit(Unit* /*caster*/, SpellInfo const* spell) override + void DoAction(int32 action) override { - uint32 spellId = 0; - switch (spell->Id) - { - case SPELL_INFORM_LIVE_TRAINEE: spellId = SPELL_INFORM_DEAD_TRAINEE; break; - case SPELL_INFORM_LIVE_KNIGHT: spellId = SPELL_INFORM_DEAD_KNIGHT; break; - case SPELL_INFORM_LIVE_RIDER: spellId = SPELL_INFORM_DEAD_RIDER; break; - } - if (spellId && me->IsInCombat()) + switch (action) { - me->HandleEmoteCommand(EMOTE_ONESHOT_SPELL_CAST); - if (Creature* pRandomDeadTrigger = ObjectAccessor::GetCreature(*me, DeadTriggerGUID[rand32() % POS_DEAD])) - me->CastSpell(pRandomDeadTrigger, spellId, true); + case ACTION_MINION_EVADE: + if (_gateIsOpen || me->getThreatManager().isThreatListEmpty()) + return EnterEvadeMode(EVADE_REASON_NO_HOSTILES); + if (_gateCanOpen) + OpenGate(); + break; } } - void DamageTaken(Unit* /*who*/, uint32& damage) override + void EnterEvadeMode(EvadeReason why) override { - if (!phaseTwo) - damage = 0; + BossAI::EnterEvadeMode(why); + Position const& home = me->GetHomePosition(); + me->NearTeleportTo(home.GetPositionX(), home.GetPositionY(), home.GetPositionZ(), home.GetOrientation()); } - void SpellHitTarget(Unit* target, SpellInfo const* spell) override + void UpdateAI(uint32 diff) override { - if (!me->IsInCombat()) + if (!UpdateVictim()) return; - switch (spell->Id) + if (me->HasReactState(REACT_AGGRESSIVE) && !_gateIsOpen && !IsOnSameSide(me, me->GetVictim())) { - case SPELL_INFORM_DEAD_TRAINEE: - DoSummon(NPC_DEAD_TRAINEE, target, 0); - break; - case SPELL_INFORM_DEAD_KNIGHT: - DoSummon(NPC_DEAD_KNIGHT, target, 0); - break; - case SPELL_INFORM_DEAD_RIDER: - DoSummon(NPC_DEAD_RIDER, target, 1.0f); - DoSummon(NPC_DEAD_HORSE, target, 1.0f); - break; + // NBD: this should only happen in practice if there is nobody left alive on our side (we should open gate) + // thus we only do a cursory check to make sure (edge cases?) + if (Player* newTarget = FindEligibleTarget(me, _gateIsOpen)) + { + me->getThreatManager().resetAllAggro(); + me->AddThreat(newTarget, 1.0f); + AttackStart(newTarget); + } + else + OpenGate(); } - } - - void UpdateAI(uint32 diff) override - { - if (!UpdateVictim() || !CheckInRoom()) - return; events.Update(diff); - if (!thirtyPercentReached && HealthBelowPct(30) && phaseTwo) - { - thirtyPercentReached = true; - instance->SetData(DATA_GOTHIK_GATE, GO_STATE_ACTIVE); - } - - if (me->HasUnitState(UNIT_STATE_CASTING)) - return; + if (!_gateIsOpen && HealthBelowPct(30) && events.IsInPhase(PHASE_TWO)) + OpenGate(); while (uint32 eventId = events.ExecuteEvent()) { switch (eventId) { case EVENT_SUMMON: - if (waves[waveCount].entry) + { + if (RAID_MODE(waves10,waves25).size() <= _waveCount) // bounds check { - if ((waves[waveCount].mode == 2) && (GetDifficulty() == RAID_DIFFICULTY_25MAN_NORMAL)) - DoGothikSummon(waves[waveCount].entry); - else if ((waves[waveCount].mode == 0) && (GetDifficulty() == RAID_DIFFICULTY_10MAN_NORMAL)) - DoGothikSummon(waves[waveCount].entry); - else if (waves[waveCount].mode == 1) - DoGothikSummon(waves[waveCount].entry); - - // if group is not splitted, open gate and merge both sides at ~ 2 minutes (wave 11) - if (waveCount == 11) + TC_LOG_INFO("scripts", "GothikAI: Wave count %d is out of range for difficulty %d.", _waveCount, GetDifficulty()); + break; + } + + std::list<Creature*> triggers; + me->GetCreatureListWithEntryInGrid(triggers, NPC_TRIGGER, 150.0f); + for (GothikWaveEntry entry : RAID_MODE(waves10, waves25)[_waveCount].first) + for (uint8 i = 0; i < entry.second; ++i) { - if (!CheckGroupSplitted()) + // GUID layout is as follows: + // CGUID+4: center (back of platform) - primary rider spawn + // CGUID+5: north (back of platform) - primary knight spawn + // CGUID+6: center (front of platform) - second spawn + // CGUID+7: south (front of platform) - primary trainee spawn + uint32 targetDBGuid; + switch (entry.first) { - instance->SetData(DATA_GOTHIK_GATE, GO_STATE_ACTIVE); - DummyEntryCheckPredicate pred; - summons.DoAction(0, pred); //! Magic numbers fail - summons.DoZoneInCombat(); - mergedSides = true; + case NPC_LIVE_RIDER: // only spawns from center (back) > north + targetDBGuid = (CGUID_TRIGGER + 4) + (i % 2); + break; + case NPC_LIVE_KNIGHT: // spawns north > center (front) > south + targetDBGuid = (CGUID_TRIGGER + 5) + (i % 3); + break; + case NPC_LIVE_TRAINEE: // spawns south > center (front) > north + targetDBGuid = (CGUID_TRIGGER + 7) - (i % 3); + break; + default: + targetDBGuid = 0; } + + for (Creature* trigger : triggers) + if (trigger && trigger->GetSpawnId() == targetDBGuid) + { + DoSummon(entry.first, trigger, 1.0f, 15 * IN_MILLISECONDS, TEMPSUMMON_CORPSE_TIMED_DESPAWN); + break; + } } - if (waves[waveCount].mode == 1) - events.ScheduleEvent(EVENT_SUMMON, waves[waveCount].time); - else if ((waves[waveCount].mode == 2) && (GetDifficulty() == RAID_DIFFICULTY_25MAN_NORMAL)) - events.ScheduleEvent(EVENT_SUMMON, waves[waveCount].time); - else if ((waves[waveCount].mode == 0) && (GetDifficulty() == RAID_DIFFICULTY_10MAN_NORMAL)) - events.ScheduleEvent(EVENT_SUMMON, waves[waveCount].time); - else - events.ScheduleEvent(EVENT_SUMMON, 0); + if (uint8 timeToNext = RAID_MODE(waves10, waves25)[_waveCount].second) + events.ScheduleEvent(EVENT_SUMMON, timeToNext * IN_MILLISECONDS, 0, PHASE_ONE); - ++waveCount; - } - else - { - phaseTwo = true; - Talk(SAY_TELEPORT); - DoTeleportTo(PosGroundLiveSide); - me->SetReactState(REACT_AGGRESSIVE); - DummyEntryCheckPredicate pred; - summons.DoAction(0, pred); //! Magic numbers fail - summons.DoZoneInCombat(); - events.ScheduleEvent(EVENT_BOLT, 1000); - events.ScheduleEvent(EVENT_HARVEST, urand(3000, 15000)); - events.ScheduleEvent(EVENT_TELEPORT, 20000); - } + ++_waveCount; break; - case EVENT_BOLT: - DoCastVictim(SPELL_SHADOW_BOLT); - events.ScheduleEvent(EVENT_BOLT, 1000); + } + case EVENT_DOORS_UNLOCK: + _gateCanOpen = true; + for (ObjectGuid summonGuid : summons) + if (Creature* summon = ObjectAccessor::GetCreature(*me, summonGuid)) + if (summon->IsAlive() && (!summon->IsInCombat() || summon->IsInEvadeMode())) + { + OpenGate(); + break; + } break; - case EVENT_HARVEST: - DoCastVictim(SPELL_HARVEST_SOUL, true); - events.ScheduleEvent(EVENT_HARVEST, urand(20000, 25000)); + case EVENT_PHASE_TWO: + events.SetPhase(PHASE_TWO); + events.ScheduleEvent(EVENT_TELEPORT, 20 * IN_MILLISECONDS, 0, PHASE_TWO); + events.ScheduleEvent(EVENT_HARVEST, 15 * IN_MILLISECONDS, 0, PHASE_TWO); + events.ScheduleEvent(EVENT_RESUME_ATTACK, 2 * IN_MILLISECONDS, 0, PHASE_TWO); + Talk(SAY_PHASE_TWO); + Talk(EMOTE_PHASE_TWO); + me->SetReactState(REACT_PASSIVE); + me->getThreatManager().resetAllAggro(); + DoCastAOE(SPELL_TELEPORT_LIVE); break; case EVENT_TELEPORT: - if (!thirtyPercentReached) + if (!HealthBelowPct(30)) { + me->CastStop(); me->AttackStop(); - if (IN_LIVE_SIDE(me)) - DoTeleportTo(PosGroundDeadSide); - else - DoTeleportTo(PosGroundLiveSide); - - me->getThreatManager().resetAggro(NotOnSameSide(me)); - if (Unit* target = SelectTarget(SELECT_TARGET_NEAREST, 0)) - { - me->getThreatManager().addThreat(target, 100.0f); - AttackStart(target); - } - - events.ScheduleEvent(EVENT_TELEPORT, 20000); + me->StopMoving(); + me->SetReactState(REACT_PASSIVE); + me->getThreatManager().resetAllAggro(); + DoCastAOE(_lastTeleportDead ? SPELL_TELEPORT_LIVE : SPELL_TELEPORT_DEAD); + _lastTeleportDead = !_lastTeleportDead; + + events.CancelEvent(EVENT_BOLT); + events.ScheduleEvent(EVENT_TELEPORT, 20 * IN_MILLISECONDS, 0, PHASE_TWO); + events.ScheduleEvent(EVENT_RESUME_ATTACK, 2 * IN_MILLISECONDS, 0, PHASE_TWO); } break; + + case EVENT_HARVEST: + DoCastAOE(SPELL_HARVEST_SOUL, true); // triggered allows this to go "through" shadow bolt + events.ScheduleEvent(EVENT_HARVEST, 15 * IN_MILLISECONDS, 0, PHASE_TWO); + break; + case EVENT_RESUME_ATTACK: + me->SetReactState(REACT_AGGRESSIVE); + events.ScheduleEvent(EVENT_BOLT, 0, 0, PHASE_TWO); + // return to the start of this method so victim side etc is re-evaluated + return UpdateAI(0u); // tail recursion for efficiency + case EVENT_BOLT: + DoCastVictim(SPELL_SHADOW_BOLT); + events.ScheduleEvent(EVENT_BOLT, 1 * IN_MILLISECONDS, 0, PHASE_TWO); + break; + case EVENT_INTRO_2: + Talk(SAY_INTRO_2); + break; + case EVENT_INTRO_3: + Talk(SAY_INTRO_3); + break; + case EVENT_INTRO_4: + Talk(SAY_INTRO_4); + break; } } - - if (!phaseTwo) - DoMeleeAttackIfReady(); } + + private: + uint32 _waveCount; + bool _gateCanOpen; + bool _gateIsOpen; + bool _lastTeleportDead; }; CreatureAI* GetAI(Creature* creature) const override @@ -498,86 +562,407 @@ class boss_gothik : public CreatureScript } }; -class npc_gothik_minion : public CreatureScript +struct npc_gothik_minion_baseAI : public ScriptedAI { public: - npc_gothik_minion() : CreatureScript("npc_gothik_minion") { } + npc_gothik_minion_baseAI(Creature* creature, uint32 deathNotify=0) : ScriptedAI(creature), _deathNotify(deathNotify), _gateIsOpen(false) { } + + void JustDied(Unit* /*killer*/) override + { + if (_deathNotify) + DoCastAOE(_deathNotify, true); + } + + inline bool isOnSameSide(Unit const* who) const + { + return IsOnSameSide(me, who); + } + + void DamageTaken(Unit* attacker, uint32 &damage) override + { // do not allow minions to take damage before the gate is opened + if (!_gateIsOpen && !isOnSameSide(attacker)) + damage = 0; + } - struct npc_gothik_minionAI : public CombatAI + void DoAction(int32 action) override { - npc_gothik_minionAI(Creature* creature) : CombatAI(creature) + switch (action) { - liveSide = IN_LIVE_SIDE(me); - gateClose = false; + case ACTION_GATE_OPENED: + _gateIsOpen = true; + // intentional missing break + case ACTION_ACQUIRE_TARGET: + if (Player* target = FindEligibleTarget(me, _gateIsOpen)) + { + me->AddThreat(target, 1.0f); + AttackStart(target); + } + else + EnterEvadeMode(EVADE_REASON_NO_HOSTILES); + break; } + } - bool liveSide; - bool gateClose; + void EnterEvadeMode(EvadeReason why) override + { + ScriptedAI::EnterEvadeMode(why); - bool isOnSameSide(Unit const* who) const + if (InstanceScript* instance = me->GetInstanceScript()) + if (Creature* gothik = ObjectAccessor::GetCreature(*me, instance->GetGuidData(DATA_GOTHIK))) + gothik->AI()->DoAction(ACTION_MINION_EVADE); + } + + void UpdateAI(uint32 diff) override + { + if (!UpdateVictim()) + return; + + if (!_gateIsOpen && !isOnSameSide(me->GetVictim())) + { // reset threat, then try to find someone on same side as us to attack + if (Player* newTarget = FindEligibleTarget(me, _gateIsOpen)) + { + me->RemoveAurasByType(SPELL_AURA_MOD_TAUNT); + me->getThreatManager().resetAllAggro(); + me->AddThreat(newTarget, 1.0f); + AttackStart(newTarget); + } + else + EnterEvadeMode(EVADE_REASON_NO_HOSTILES); + } + + _UpdateAI(diff); + } + + virtual void _UpdateAI(uint32 diff) { ScriptedAI::UpdateAI(diff); }; + + private: + uint32 _deathNotify; + bool _gateIsOpen; +}; + +class npc_gothik_minion_livingtrainee : public CreatureScript +{ + public: + npc_gothik_minion_livingtrainee() : CreatureScript("npc_gothik_minion_livingtrainee") { } + + struct npc_gothik_minion_livingtraineeAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_livingtraineeAI(Creature* creature) : npc_gothik_minion_baseAI(creature, SPELL_ANCHOR_1_TRAINEE), _deathPlagueTimer(urandms(5,20)) { } + + void _UpdateAI(uint32 diff) { - return (liveSide == IN_LIVE_SIDE(who)); + if (diff < _deathPlagueTimer) + _deathPlagueTimer -= diff; + else + { + DoCastAOE(SPELL_DEATH_PLAGUE); + _deathPlagueTimer = urandms(5, 20); + } + DoMeleeAttackIfReady(); } + uint32 _deathPlagueTimer; + }; + + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_livingtraineeAI>(creature); + } +}; + +class npc_gothik_minion_livingknight : public CreatureScript +{ + public: + npc_gothik_minion_livingknight() : CreatureScript("npc_gothik_minion_livingknight") { } - void DoAction(int32 param) override + struct npc_gothik_minion_livingknightAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_livingknightAI(Creature* creature) : npc_gothik_minion_baseAI(creature, SPELL_ANCHOR_1_DK), _whirlwindTimer(urandms(5,10)) { } + + void _UpdateAI(uint32 diff) { - gateClose = param != 0; + if (diff < _whirlwindTimer) + _whirlwindTimer -= diff; + else + { + DoCastAOE(SPELL_SHADOW_MARK); + _whirlwindTimer = urandms(15, 20); + } + DoMeleeAttackIfReady(); } + uint32 _whirlwindTimer; + }; - void DamageTaken(Unit* attacker, uint32 &damage) override + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_livingknightAI>(creature); + } +}; + +class npc_gothik_minion_livingrider : public CreatureScript +{ + public: + npc_gothik_minion_livingrider() : CreatureScript("npc_gothik_minion_livingrider") { } + + struct npc_gothik_minion_livingriderAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_livingriderAI(Creature* creature) : npc_gothik_minion_baseAI(creature, SPELL_ANCHOR_1_RIDER), _boltVolleyTimer(urandms(5,10)) { } + + void _UpdateAI(uint32 diff) { - if (gateClose && !isOnSameSide(attacker)) - damage = 0; + if (diff < _boltVolleyTimer) + _boltVolleyTimer -= diff; + else + { + DoCastAOE(SPELL_SHADOW_BOLT_VOLLEY); + _boltVolleyTimer = urandms(10, 15); + } + if (!me->HasUnitState(UNIT_STATE_CASTING)) + DoMeleeAttackIfReady(); } + uint32 _boltVolleyTimer; + }; - void JustDied(Unit* /*killer*/) override + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_livingriderAI>(creature); + } +}; + +class npc_gothik_minion_spectraltrainee : public CreatureScript +{ + public: + npc_gothik_minion_spectraltrainee() : CreatureScript("npc_gothik_minion_spectraltrainee") { } + + struct npc_gothik_minion_spectraltraineeAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_spectraltraineeAI(Creature* creature) : npc_gothik_minion_baseAI(creature), _explosionTimer(2 * IN_MILLISECONDS) { } + + void _UpdateAI(uint32 diff) + { + if (diff < _explosionTimer) + _explosionTimer -= diff; + else { - if (me->IsSummon()) - if (Unit* owner = me->ToTempSummon()->GetSummoner()) - CombatAI::JustDied(owner); + DoCastAOE(SPELL_ARCANE_EXPLOSION); + _explosionTimer = 2 * IN_MILLISECONDS; } + DoMeleeAttackIfReady(); + } + uint32 _explosionTimer; + }; + + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_spectraltraineeAI>(creature); + } +}; - void EnterEvadeMode() override +class npc_gothik_minion_spectralknight : public CreatureScript +{ + public: + npc_gothik_minion_spectralknight() : CreatureScript("npc_gothik_minion_spectralknight") { } + + struct npc_gothik_minion_spectralknightAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_spectralknightAI(Creature* creature) : npc_gothik_minion_baseAI(creature), _whirlwindTimer(urandms(15,25)) { } + + void _UpdateAI(uint32 diff) + { + if (diff < _whirlwindTimer) + _whirlwindTimer -= diff; + else { - if (!gateClose) - { - CombatAI::EnterEvadeMode(); - return; - } + DoCastAOE(SPELL_WHIRLWIND); + _whirlwindTimer = urandms(20, 25); + } + DoMeleeAttackIfReady(); + } + uint32 _whirlwindTimer; + }; - if (!_EnterEvadeMode()) - return; + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_spectralknightAI>(creature); + } +}; + +class npc_gothik_minion_spectralrider : public CreatureScript +{ + public: + npc_gothik_minion_spectralrider() : CreatureScript("npc_gothik_minion_spectralrider") { } + + struct npc_gothik_minion_spectralriderAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_spectralriderAI(Creature* creature) : npc_gothik_minion_baseAI(creature), _frenzyTimer(urandms(2,5)), _drainTimer(urandms(8,12)) { } - Map::PlayerList const &PlayerList = me->GetMap()->GetPlayers(); - for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i) + void _UpdateAI(uint32 diff) + { + if (diff < _frenzyTimer) + _frenzyTimer -= diff; + else if (me->HasUnitState(UNIT_STATE_CASTING)) + _frenzyTimer = 0; + else + { // target priority: knight > other rider > horse > gothik + std::list<Creature*> potentialTargets = DoFindFriendlyMissingBuff(30.0, SPELLHELPER_UNHOLY_FRENZY); + Creature *knightTarget = nullptr, *riderTarget = nullptr, *horseTarget = nullptr, *gothikTarget = nullptr; + for (Creature* pTarget : potentialTargets) { - if (i->GetSource() && i->GetSource()->IsAlive() && isOnSameSide(i->GetSource())) + switch (pTarget->GetEntry()) { - AttackStart(i->GetSource()); - return; + case NPC_DEAD_KNIGHT: + knightTarget = pTarget; + break; + case NPC_DEAD_RIDER: + riderTarget = pTarget; + break; + case NPC_DEAD_HORSE: + horseTarget = pTarget; + break; + case NPC_GOTHIK: + gothikTarget = pTarget; + break; } + if (knightTarget) + break; } + Creature* target = knightTarget ? knightTarget : riderTarget ? riderTarget : horseTarget ? horseTarget : gothikTarget ? gothikTarget : nullptr; + if (target) + DoCast(target, SPELL_UNHOLY_FRENZY); + _frenzyTimer = 20 * IN_MILLISECONDS; + } - me->GetMotionMaster()->MoveIdle(); - Reset(); + if (diff < _drainTimer) + _drainTimer -= diff; + else + { + DoCastVictim(SPELL_DRAIN_LIFE); + _drainTimer = urandms(10,15); } - void UpdateAI(uint32 diff) override + if (!me->HasUnitState(UNIT_STATE_CASTING)) + DoMeleeAttackIfReady(); + } + uint32 _frenzyTimer, _drainTimer; + }; + + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_spectralriderAI>(creature); + } +}; + +class npc_gothik_minion_spectralhorse : public CreatureScript +{ + public: + npc_gothik_minion_spectralhorse() : CreatureScript("npc_gothik_minion_spectralhorse") { } + + struct npc_gothik_minion_spectralhorseAI : public npc_gothik_minion_baseAI + { + npc_gothik_minion_spectralhorseAI(Creature* creature) : npc_gothik_minion_baseAI(creature), _stompTimer(urandms(10,15)) { } + + void _UpdateAI(uint32 diff) + { + if (diff < _stompTimer) + _stompTimer -= diff; + else { - if (gateClose && (!isOnSameSide(me) || (me->GetVictim() && !isOnSameSide(me->GetVictim())))) - { - EnterEvadeMode(); - return; - } + DoCastAOE(SPELL_STOMP); + _stompTimer = urandms(14, 18); + } + DoMeleeAttackIfReady(); + } + uint32 _stompTimer; + }; - CombatAI::UpdateAI(diff); + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_minion_spectralhorseAI>(creature); + } +}; + +class npc_gothik_trigger : public CreatureScript +{ +public: + npc_gothik_trigger() : CreatureScript("npc_gothik_trigger") { } + + CreatureAI* GetAI(Creature* creature) const override + { + return GetInstanceAI<npc_gothik_triggerAI>(creature); + } + + struct npc_gothik_triggerAI : public ScriptedAI + { + npc_gothik_triggerAI(Creature* creature) : ScriptedAI(creature) { creature->SetDisableGravity(true); } + + void EnterEvadeMode(EvadeReason /*why*/) override { } + void UpdateAI(uint32 /*diff*/) override { } + void EnterCombat(Unit* /*who*/) override { } + void DamageTaken(Unit* /*who*/, uint32& damage) override { damage = 0; } + + Creature* SelectRandomSkullPile() + { + std::list<Creature*> triggers; + me->GetCreatureListWithEntryInGrid(triggers, NPC_TRIGGER, 150.0f); + uint32 targetDBGuid = CGUID_TRIGGER + urand(8, 12); // CGUID+8 to CGUID+12 are the triggers for the skull piles on dead side + for (Creature* trigger : triggers) + if (trigger && trigger->GetSpawnId() == targetDBGuid) + return trigger; + + return nullptr; + } + void SpellHit(Unit* /*caster*/, SpellInfo const* spell) override + { + if (!spell) + return; + + switch (spell->Id) + { + case SPELL_ANCHOR_1_TRAINEE: + DoCastAOE(SPELL_ANCHOR_2_TRAINEE, true); + break; + case SPELL_ANCHOR_1_DK: + DoCastAOE(SPELL_ANCHOR_2_DK, true); + break; + case SPELL_ANCHOR_1_RIDER: + DoCastAOE(SPELL_ANCHOR_2_RIDER, true); + break; + case SPELL_ANCHOR_2_TRAINEE: + if (Creature* target = SelectRandomSkullPile()) + DoCast(target, SPELL_SKULLS_TRAINEE, true); + break; + case SPELL_ANCHOR_2_DK: + if (Creature* target = SelectRandomSkullPile()) + DoCast(target, SPELL_SKULLS_DK, true); + break; + case SPELL_ANCHOR_2_RIDER: + if (Creature* target = SelectRandomSkullPile()) + DoCast(target, SPELL_SKULLS_RIDER, true); + break; + case SPELL_SKULLS_TRAINEE: + DoSummon(NPC_DEAD_TRAINEE, me, 0.0f, 15 * IN_MILLISECONDS, TEMPSUMMON_CORPSE_TIMED_DESPAWN); + break; + case SPELL_SKULLS_DK: + DoSummon(NPC_DEAD_KNIGHT, me, 0.0f, 15 * IN_MILLISECONDS, TEMPSUMMON_CORPSE_TIMED_DESPAWN); + break; + case SPELL_SKULLS_RIDER: + DoSummon(NPC_DEAD_RIDER, me, 0.0f, 15 * IN_MILLISECONDS, TEMPSUMMON_CORPSE_TIMED_DESPAWN); + DoSummon(NPC_DEAD_HORSE, me, 0.0f, 15 * IN_MILLISECONDS, TEMPSUMMON_CORPSE_TIMED_DESPAWN); + break; } - }; + } - CreatureAI* GetAI(Creature* creature) const override + // dead side summons are "owned" by gothik + void JustSummoned(Creature* summon) override + { + if (Creature* gothik = ObjectAccessor::GetCreature(*me, me->GetInstanceScript()->GetGuidData(DATA_GOTHIK))) + gothik->AI()->JustSummoned(summon); + } + void SummonedCreatureDespawn(Creature* summon) override { - return new npc_gothik_minionAI(creature); + if (Creature* gothik = ObjectAccessor::GetCreature(*me, me->GetInstanceScript()->GetGuidData(DATA_GOTHIK))) + gothik->AI()->SummonedCreatureDespawn(summon); } + }; }; class spell_gothik_shadow_bolt_volley : public SpellScriptLoader @@ -609,6 +994,13 @@ class spell_gothik_shadow_bolt_volley : public SpellScriptLoader void AddSC_boss_gothik() { new boss_gothik(); - new npc_gothik_minion(); + new npc_gothik_minion_livingtrainee(); + new npc_gothik_minion_livingknight(); + new npc_gothik_minion_livingrider(); + new npc_gothik_minion_spectraltrainee(); + new npc_gothik_minion_spectralknight(); + new npc_gothik_minion_spectralrider(); + new npc_gothik_minion_spectralhorse(); + new npc_gothik_trigger(); new spell_gothik_shadow_bolt_volley(); } diff --git a/src/server/scripts/Northrend/Naxxramas/boss_grobbulus.cpp b/src/server/scripts/Northrend/Naxxramas/boss_grobbulus.cpp index 563e5ca9bbd..a1d8f6e5e02 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_grobbulus.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_grobbulus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Naxxramas/boss_heigan.cpp b/src/server/scripts/Northrend/Naxxramas/boss_heigan.cpp index 36e48d068b5..9b9619fe5b9 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_heigan.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_heigan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -115,7 +115,7 @@ public: void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; events.Update(diff); diff --git a/src/server/scripts/Northrend/Naxxramas/boss_kelthuzad.cpp b/src/server/scripts/Northrend/Naxxramas/boss_kelthuzad.cpp index 89d0e5cfe1f..47807ec28cb 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_kelthuzad.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_kelthuzad.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/Naxxramas/boss_loatheb.cpp b/src/server/scripts/Northrend/Naxxramas/boss_loatheb.cpp index 494c173f5fc..086d21120e8 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_loatheb.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_loatheb.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Naxxramas/boss_maexxna.cpp b/src/server/scripts/Northrend/Naxxramas/boss_maexxna.cpp index 0d938122f28..9d8f1365afb 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_maexxna.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_maexxna.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -116,7 +116,7 @@ public: void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; if (HealthBelowPct(30) && !me->HasAura(SPELL_FRENZY_HELPER)) diff --git a/src/server/scripts/Northrend/Naxxramas/boss_noth.cpp b/src/server/scripts/Northrend/Naxxramas/boss_noth.cpp index 7b3a9f8ac74..8ee3936dee3 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_noth.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_noth.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -88,7 +88,7 @@ public: events.SetPhase(PHASE_NONE); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { Reset(); // teleport back first _EnterEvadeMode(); @@ -205,7 +205,7 @@ public: void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; events.Update(diff); diff --git a/src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp b/src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp index 7c85c5f73b9..b8ce402a939 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_patchwerk.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Naxxramas/boss_razuvious.cpp b/src/server/scripts/Northrend/Naxxramas/boss_razuvious.cpp index f94f7b227bf..1d12f64a949 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_razuvious.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_razuvious.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Naxxramas/boss_sapphiron.cpp b/src/server/scripts/Northrend/Naxxramas/boss_sapphiron.cpp index 02a7aa570e5..68b9e252150 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_sapphiron.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_sapphiron.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -231,7 +231,7 @@ class boss_sapphiron : public CreatureScript events.Update(diff); - if ((_phase != PHASE_BIRTH && !UpdateVictim()) || !CheckInRoom()) + if (_phase != PHASE_BIRTH && !UpdateVictim()) return; if (_phase == PHASE_GROUND) diff --git a/src/server/scripts/Northrend/Naxxramas/boss_thaddius.cpp b/src/server/scripts/Northrend/Naxxramas/boss_thaddius.cpp index 5d3b038d41d..7330f90e585 100644 --- a/src/server/scripts/Northrend/Naxxramas/boss_thaddius.cpp +++ b/src/server/scripts/Northrend/Naxxramas/boss_thaddius.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -456,6 +456,7 @@ public: { Initialize(); instance = creature->GetInstanceScript(); + SetBoundary(instance->GetBossBoundary(BOSS_THADDIUS)); } void Initialize() @@ -723,6 +724,7 @@ public: { Initialize(); instance = creature->GetInstanceScript(); + SetBoundary(instance->GetBossBoundary(BOSS_THADDIUS)); } void Initialize() @@ -990,7 +992,7 @@ public: { npc_teslaAI(Creature* creature) : ScriptedAI(creature) { } - void EnterEvadeMode() override { } // never stop casting due to evade + void EnterEvadeMode(EvadeReason /*why*/) override { } // never stop casting due to evade void UpdateAI(uint32 /*diff*/) override { } // never do anything unless told void EnterCombat(Unit* /*who*/) override { } void DamageTaken(Unit* /*who*/, uint32& damage) override { damage = 0; } // no, you can't kill it diff --git a/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp b/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp index 0e572835a51..c8a4eb7fbc8 100644 --- a/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp +++ b/src/server/scripts/Northrend/Naxxramas/instance_naxxramas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -20,51 +20,75 @@ #include "InstanceScript.h" #include "naxxramas.h" -DoorData const doorData[] = +BossBoundaryData const boundaries = { - { GO_ROOM_ANUBREKHAN, BOSS_ANUBREKHAN, DOOR_TYPE_ROOM, BOUNDARY_S }, - { GO_PASSAGE_ANUBREKHAN, BOSS_ANUBREKHAN, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_PASSAGE_FAERLINA, BOSS_FAERLINA, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_ROOM_MAEXXNA, BOSS_FAERLINA, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_ROOM_MAEXXNA, BOSS_MAEXXNA, DOOR_TYPE_ROOM, BOUNDARY_SW }, - { GO_ROOM_NOTH, BOSS_NOTH, DOOR_TYPE_ROOM, BOUNDARY_N }, - { GO_PASSAGE_NOTH, BOSS_NOTH, DOOR_TYPE_PASSAGE, BOUNDARY_E }, - { GO_ROOM_HEIGAN, BOSS_NOTH, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_ROOM_HEIGAN, BOSS_HEIGAN, DOOR_TYPE_ROOM, BOUNDARY_N }, - { GO_PASSAGE_HEIGAN, BOSS_HEIGAN, DOOR_TYPE_PASSAGE, BOUNDARY_E }, - { GO_ROOM_LOATHEB, BOSS_HEIGAN, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_ROOM_LOATHEB, BOSS_LOATHEB, DOOR_TYPE_ROOM, BOUNDARY_W }, - { GO_ROOM_GROBBULUS, BOSS_PATCHWERK, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_ROOM_GROBBULUS, BOSS_GROBBULUS, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_PASSAGE_GLUTH, BOSS_GLUTH, DOOR_TYPE_PASSAGE, BOUNDARY_NW }, - { GO_ROOM_THADDIUS, BOSS_GLUTH, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_ROOM_THADDIUS, BOSS_THADDIUS, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_ROOM_GOTHIK, BOSS_RAZUVIOUS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_ROOM_GOTHIK, BOSS_GOTHIK, DOOR_TYPE_ROOM, BOUNDARY_N }, - { GO_PASSAGE_GOTHIK, BOSS_GOTHIK, DOOR_TYPE_PASSAGE, BOUNDARY_S }, - { GO_ROOM_HORSEMEN, BOSS_GOTHIK, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_GOTHIK_GATE, BOSS_GOTHIK, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_ROOM_HORSEMEN, BOSS_HORSEMEN, DOOR_TYPE_ROOM, BOUNDARY_NE }, - { GO_PASSAGE_SAPPHIRON, BOSS_SAPPHIRON, DOOR_TYPE_PASSAGE, BOUNDARY_W }, - { GO_ROOM_KELTHUZAD, BOSS_KELTHUZAD, DOOR_TYPE_ROOM, BOUNDARY_S }, - { GO_ARAC_EYE_RAMP, BOSS_MAEXXNA, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_ARAC_EYE_RAMP_BOSS, BOSS_MAEXXNA, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_PLAG_EYE_RAMP, BOSS_LOATHEB, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_PLAG_EYE_RAMP_BOSS, BOSS_LOATHEB, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_MILI_EYE_RAMP, BOSS_HORSEMEN, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_MILI_EYE_RAMP_BOSS, BOSS_HORSEMEN, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_CONS_EYE_RAMP, BOSS_THADDIUS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_CONS_EYE_RAMP_BOSS, BOSS_THADDIUS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } + /* Arachnid Quarter */ + { BOSS_ANUBREKHAN, new CircleBoundary(Position(3273.376709f, -3475.876709f), Position(3195.668213f, -3475.930176f)) }, + { BOSS_FAERLINA, new RectangleBoundary(3315.0f, 3402.0f, -3727.0f, -3590.0f) }, + { BOSS_FAERLINA, new CircleBoundary(Position(3372.68f, -3648.2f), Position(3316.0f, -3704.26f)) }, + { BOSS_MAEXXNA, new CircleBoundary(Position(3502.2587f, -3892.1697f), Position(3418.7422f, -3840.271f)) }, + + /* Plague Quarter */ + { BOSS_NOTH, new RectangleBoundary(2618.0f, 2754.0f, -3557.43f, -3450.0f) }, + { BOSS_HEIGAN, new CircleBoundary(Position(2772.57f, -3685.28f), 56.0f) }, + { BOSS_LOATHEB, new CircleBoundary(Position(2909.0f, -3997.41f), 57.0f) }, + + /* Military Quarter */ + { BOSS_RAZUVIOUS, new ZRangeBoundary(260.0f, 287.0f) }, // will not chase onto the upper floor + { BOSS_GOTHIK, new RectangleBoundary(2627.0f, 2764.0f, -3440.0f, -3275.0f) }, + { BOSS_HORSEMEN, new ParallelogramBoundary(AreaBoundary::DoublePosition(2646.0, -2959.0), AreaBoundary::DoublePosition(2529.0, -3075.0), AreaBoundary::DoublePosition(2506.0, -2854.0)) }, + + /* Construct Quarter */ + { BOSS_PATCHWERK, new CircleBoundary(Position(3204.0f, -3241.4f), 240.0f) }, + { BOSS_PATCHWERK, new CircleBoundary(Position(3130.8576f, -3210.36f), Position(3085.37f, -3219.85f), true) }, // entrance slime circle blocker + { BOSS_GROBBULUS, new CircleBoundary(Position(3204.0f, -3241.4f), 240.0f) }, + { BOSS_GROBBULUS, new RectangleBoundary(3295.0f, 3340.0f, -3254.2f, -3230.18f, true) }, // entrance door blocker + { BOSS_GLUTH, new CircleBoundary(Position(3293.0f, -3142.0f), 80.0) }, + { BOSS_GLUTH, new ParallelogramBoundary(AreaBoundary::DoublePosition(3401.0, -3149.0), AreaBoundary::DoublePosition(3261.0, -3028.0), AreaBoundary::DoublePosition(3320.0, -3267.0)) }, + { BOSS_GLUTH, new ZRangeBoundary(285.0f, 310.0f) }, + { BOSS_THADDIUS, new ParallelogramBoundary(AreaBoundary::DoublePosition(3478.3, -3070.0), AreaBoundary::DoublePosition(3370.0, -2961.5), AreaBoundary::DoublePosition(3580.0, -2961.5)) }, + + /* Frostwyrm Lair */ + { BOSS_SAPPHIRON, new CircleBoundary(Position(3517.627f, -5255.5f), 110.0) }, + { BOSS_KELTHUZAD, new CircleBoundary(Position(3716.0f, -5107.0f), 85.0) } }; -MinionData const minionData[] = +DoorData const doorData[] = { - { NPC_SIR, BOSS_HORSEMEN }, - { NPC_THANE, BOSS_HORSEMEN }, - { NPC_LADY, BOSS_HORSEMEN }, - { NPC_BARON, BOSS_HORSEMEN }, - { 0, 0, } + { GO_ROOM_ANUBREKHAN, BOSS_ANUBREKHAN, DOOR_TYPE_ROOM }, + { GO_PASSAGE_ANUBREKHAN, BOSS_ANUBREKHAN, DOOR_TYPE_PASSAGE }, + { GO_PASSAGE_FAERLINA, BOSS_FAERLINA, DOOR_TYPE_PASSAGE }, + { GO_ROOM_MAEXXNA, BOSS_FAERLINA, DOOR_TYPE_PASSAGE }, + { GO_ROOM_MAEXXNA, BOSS_MAEXXNA, DOOR_TYPE_ROOM }, + { GO_ROOM_NOTH, BOSS_NOTH, DOOR_TYPE_ROOM }, + { GO_PASSAGE_NOTH, BOSS_NOTH, DOOR_TYPE_PASSAGE }, + { GO_ROOM_HEIGAN, BOSS_NOTH, DOOR_TYPE_PASSAGE }, + { GO_ROOM_HEIGAN, BOSS_HEIGAN, DOOR_TYPE_ROOM }, + { GO_PASSAGE_HEIGAN, BOSS_HEIGAN, DOOR_TYPE_PASSAGE }, + { GO_ROOM_LOATHEB, BOSS_HEIGAN, DOOR_TYPE_PASSAGE }, + { GO_ROOM_LOATHEB, BOSS_LOATHEB, DOOR_TYPE_ROOM }, + { GO_ROOM_GROBBULUS, BOSS_PATCHWERK, DOOR_TYPE_PASSAGE }, + { GO_ROOM_GROBBULUS, BOSS_GROBBULUS, DOOR_TYPE_ROOM }, + { GO_PASSAGE_GLUTH, BOSS_GLUTH, DOOR_TYPE_PASSAGE }, + { GO_ROOM_THADDIUS, BOSS_GLUTH, DOOR_TYPE_PASSAGE }, + { GO_ROOM_THADDIUS, BOSS_THADDIUS, DOOR_TYPE_ROOM }, + { GO_ROOM_GOTHIK, BOSS_RAZUVIOUS, DOOR_TYPE_PASSAGE }, + { GO_ROOM_GOTHIK, BOSS_GOTHIK, DOOR_TYPE_ROOM }, + { GO_PASSAGE_GOTHIK, BOSS_GOTHIK, DOOR_TYPE_PASSAGE }, + { GO_ROOM_HORSEMEN, BOSS_GOTHIK, DOOR_TYPE_PASSAGE }, + { GO_GOTHIK_GATE, BOSS_GOTHIK, DOOR_TYPE_ROOM }, + { GO_ROOM_HORSEMEN, BOSS_HORSEMEN, DOOR_TYPE_ROOM }, + { GO_PASSAGE_SAPPHIRON, BOSS_SAPPHIRON, DOOR_TYPE_PASSAGE }, + { GO_ROOM_KELTHUZAD, BOSS_KELTHUZAD, DOOR_TYPE_ROOM }, + { GO_ARAC_EYE_RAMP, BOSS_MAEXXNA, DOOR_TYPE_PASSAGE }, + { GO_ARAC_EYE_RAMP_BOSS, BOSS_MAEXXNA, DOOR_TYPE_PASSAGE }, + { GO_PLAG_EYE_RAMP, BOSS_LOATHEB, DOOR_TYPE_PASSAGE }, + { GO_PLAG_EYE_RAMP_BOSS, BOSS_LOATHEB, DOOR_TYPE_PASSAGE }, + { GO_MILI_EYE_RAMP, BOSS_HORSEMEN, DOOR_TYPE_PASSAGE }, + { GO_MILI_EYE_RAMP_BOSS, BOSS_HORSEMEN, DOOR_TYPE_PASSAGE }, + { GO_CONS_EYE_RAMP, BOSS_THADDIUS, DOOR_TYPE_PASSAGE }, + { GO_CONS_EYE_RAMP_BOSS, BOSS_THADDIUS, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } }; ObjectData const objectData[] = @@ -117,12 +141,10 @@ class instance_naxxramas : public InstanceMapScript { SetHeaders(DataHeader); SetBossNumber(EncounterCount); + LoadBossBoundaries(boundaries); LoadDoorData(doorData); - LoadMinionData(minionData); LoadObjectData(nullptr, objectData); - minHorsemenDiedTime = 0; - maxHorsemenDiedTime = 0; AbominationCount = 0; hadAnubRekhanGreet = false; hadFaerlinaGreet = false; @@ -145,6 +167,9 @@ class instance_naxxramas : public InstanceMapScript case NPC_RAZUVIOUS: RazuviousGUID = creature->GetGUID(); break; + case NPC_GOTHIK: + GothikGUID = creature->GetGUID(); + break; case NPC_THANE: ThaneGUID = creature->GetGUID(); break; @@ -181,13 +206,6 @@ class instance_naxxramas : public InstanceMapScript default: break; } - - AddMinion(creature, true); - } - - void OnCreatureRemove(Creature* creature) override - { - AddMinion(creature, false); } void ProcessEvent(WorldObject* /*source*/, uint32 eventId) override @@ -317,25 +335,6 @@ class instance_naxxramas : public InstanceMapScript if (GameObject* gate = instance->GetGameObject(GothikGateGUID)) gate->SetGoState(GOState(value)); break; - case DATA_HORSEMEN0: - case DATA_HORSEMEN1: - case DATA_HORSEMEN2: - case DATA_HORSEMEN3: - if (value == NOT_STARTED) - { - minHorsemenDiedTime = 0; - maxHorsemenDiedTime = 0; - } - else if (value == DONE) - { - time_t now = time(NULL); - - if (minHorsemenDiedTime == 0) - minHorsemenDiedTime = now; - - maxHorsemenDiedTime = now; - } - break; case DATA_ABOMINATION_KILLED: AbominationCount = value; break; @@ -382,6 +381,8 @@ class instance_naxxramas : public InstanceMapScript return FaerlinaGUID; case DATA_RAZUVIOUS: return RazuviousGUID; + case DATA_GOTHIK: + return GothikGUID; case DATA_THANE: return ThaneGUID; case DATA_LADY: @@ -614,13 +615,13 @@ class instance_naxxramas : public InstanceMapScript { switch (criteria_id) { - case 7600: // Criteria for achievement 2176: And They Would All Go Down Together 15sec of each other 10-man - if (Difficulty(instance->GetSpawnMode()) == RAID_DIFFICULTY_10MAN_NORMAL && (maxHorsemenDiedTime - minHorsemenDiedTime) < 15) - return true; - return false; - case 7601: // Criteria for achievement 2177: And They Would All Go Down Together 15sec of each other 25-man - if (Difficulty(instance->GetSpawnMode()) == RAID_DIFFICULTY_25MAN_NORMAL && (maxHorsemenDiedTime - minHorsemenDiedTime) < 15) - return true; + // And They Would All Go Down Together (kill 4HM within 15sec of each other) + case 7600: // 25-man + case 7601: // 10-man + if (criteria_id + instance->GetSpawnMode() == 7601) + return false; + if (Creature* baron = instance->GetCreature(BaronGUID)) // it doesn't matter which one we use, really + return (baron->AI()->GetData(DATA_HORSEMEN_CHECK_ACHIEVEMENT_CREDIT) == 1u); return false; // Difficulty checks are done on DB. // Criteria for achievement 2186: The Immortal (25-man) @@ -659,6 +660,7 @@ class instance_naxxramas : public InstanceMapScript // Instructor Razuvious ObjectGuid RazuviousGUID; // Gothik the Harvester + ObjectGuid GothikGUID; ObjectGuid GothikGateGUID; // The Four Horsemen ObjectGuid ThaneGUID; @@ -666,8 +668,6 @@ class instance_naxxramas : public InstanceMapScript ObjectGuid BaronGUID; ObjectGuid SirGUID; ObjectGuid HorsemenChestGUID; - time_t minHorsemenDiedTime; - time_t maxHorsemenDiedTime; /* The Construct Quarter */ // Thaddius diff --git a/src/server/scripts/Northrend/Naxxramas/naxxramas.h b/src/server/scripts/Northrend/Naxxramas/naxxramas.h index e4d15cf84ba..c0caa86e93f 100644 --- a/src/server/scripts/Northrend/Naxxramas/naxxramas.h +++ b/src/server/scripts/Northrend/Naxxramas/naxxramas.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -50,10 +50,7 @@ enum Data DATA_HAD_FAERLINA_GREET, DATA_HAD_THADDIUS_GREET, - DATA_HORSEMEN0, - DATA_HORSEMEN1, - DATA_HORSEMEN2, - DATA_HORSEMEN3, + DATA_HORSEMEN_CHECK_ACHIEVEMENT_CREDIT, DATA_ABOMINATION_KILLED, DATA_NAXX_PORTAL_ARACHNID, @@ -67,6 +64,7 @@ enum Data64 DATA_ANUBREKHAN, DATA_FAERLINA, DATA_RAZUVIOUS, + DATA_GOTHIK, DATA_THANE, DATA_LADY, DATA_BARON, @@ -89,6 +87,7 @@ enum CreaturesIds NPC_ANUBREKHAN = 15956, NPC_FAERLINA = 15953, NPC_RAZUVIOUS = 16061, + NPC_GOTHIK = 16060, NPC_THANE = 16064, NPC_LADY = 16065, NPC_BARON = 30549, diff --git a/src/server/scripts/Northrend/Nexus/EyeOfEternity/boss_malygos.cpp b/src/server/scripts/Northrend/Nexus/EyeOfEternity/boss_malygos.cpp index 33ffea4993b..277ca793a8f 100644 --- a/src/server/scripts/Northrend/Nexus/EyeOfEternity/boss_malygos.cpp +++ b/src/server/scripts/Northrend/Nexus/EyeOfEternity/boss_malygos.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -574,7 +574,7 @@ public: me->setActive(true); if (!instance->CheckRequiredBosses(DATA_MALYGOS_EVENT)) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); return; } @@ -585,7 +585,7 @@ public: instance->DoStartTimedAchievement(ACHIEVEMENT_TIMED_TYPE_EVENT, ACHIEV_TIMED_START_EVENT); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { instance->SetBossState(DATA_MALYGOS_EVENT, FAIL); @@ -1282,7 +1282,7 @@ public: VehicleAI::Reset(); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { } @@ -1341,7 +1341,7 @@ class npc_nexus_lord : public CreatureScript _events.Reset(); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { } @@ -1430,7 +1430,7 @@ class npc_scion_of_eternity : public CreatureScript { } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { } diff --git a/src/server/scripts/Northrend/Nexus/EyeOfEternity/eye_of_eternity.h b/src/server/scripts/Northrend/Nexus/EyeOfEternity/eye_of_eternity.h index d9b921b38a1..68f2928afc5 100644 --- a/src/server/scripts/Northrend/Nexus/EyeOfEternity/eye_of_eternity.h +++ b/src/server/scripts/Northrend/Nexus/EyeOfEternity/eye_of_eternity.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Nexus/EyeOfEternity/instance_eye_of_eternity.cpp b/src/server/scripts/Northrend/Nexus/EyeOfEternity/instance_eye_of_eternity.cpp index d1f2be5525d..e87115dd8e2 100644 --- a/src/server/scripts/Northrend/Nexus/EyeOfEternity/instance_eye_of_eternity.cpp +++ b/src/server/scripts/Northrend/Nexus/EyeOfEternity/instance_eye_of_eternity.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -21,6 +21,11 @@ #include "eye_of_eternity.h" #include "Player.h" +BossBoundaryData const boundaries = +{ + { DATA_MALYGOS_EVENT, new CircleBoundary(Position(754.362f, 1301.609985f), 280.0) } // sanity check boundary +}; + class instance_eye_of_eternity : public InstanceMapScript { public: @@ -37,6 +42,7 @@ public: { SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTER); + LoadBossBoundaries(boundaries); } void OnPlayerEnter(Player* player) override diff --git a/src/server/scripts/Northrend/Nexus/Nexus/boss_anomalus.cpp b/src/server/scripts/Northrend/Nexus/Nexus/boss_anomalus.cpp index 6d4f4baeace..a61b41c5c56 100644 --- a/src/server/scripts/Northrend/Nexus/Nexus/boss_anomalus.cpp +++ b/src/server/scripts/Northrend/Nexus/Nexus/boss_anomalus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/Nexus/Nexus/boss_keristrasza.cpp b/src/server/scripts/Northrend/Nexus/Nexus/boss_keristrasza.cpp index 495cf85b759..75f6b63b9ca 100644 --- a/src/server/scripts/Northrend/Nexus/Nexus/boss_keristrasza.cpp +++ b/src/server/scripts/Northrend/Nexus/Nexus/boss_keristrasza.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Nexus/Nexus/boss_magus_telestra.cpp b/src/server/scripts/Northrend/Nexus/Nexus/boss_magus_telestra.cpp index b849b095ce5..ae50e854e43 100644 --- a/src/server/scripts/Northrend/Nexus/Nexus/boss_magus_telestra.cpp +++ b/src/server/scripts/Northrend/Nexus/Nexus/boss_magus_telestra.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/Nexus/Nexus/boss_nexus_commanders.cpp b/src/server/scripts/Northrend/Nexus/Nexus/boss_nexus_commanders.cpp index d40f9fecc6a..6d3212e4781 100644 --- a/src/server/scripts/Northrend/Nexus/Nexus/boss_nexus_commanders.cpp +++ b/src/server/scripts/Northrend/Nexus/Nexus/boss_nexus_commanders.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Nexus/Nexus/boss_ormorok.cpp b/src/server/scripts/Northrend/Nexus/Nexus/boss_ormorok.cpp index 41645a6ebb8..4ae24d61ef8 100644 --- a/src/server/scripts/Northrend/Nexus/Nexus/boss_ormorok.cpp +++ b/src/server/scripts/Northrend/Nexus/Nexus/boss_ormorok.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/Nexus/Nexus/instance_nexus.cpp b/src/server/scripts/Northrend/Nexus/Nexus/instance_nexus.cpp index be9c593b313..6bcc8dc1899 100644 --- a/src/server/scripts/Northrend/Nexus/Nexus/instance_nexus.cpp +++ b/src/server/scripts/Northrend/Nexus/Nexus/instance_nexus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/Nexus/Nexus/nexus.h b/src/server/scripts/Northrend/Nexus/Nexus/nexus.h index c48c7323301..db1ed78d5e3 100644 --- a/src/server/scripts/Northrend/Nexus/Nexus/nexus.h +++ b/src/server/scripts/Northrend/Nexus/Nexus/nexus.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Nexus/Oculus/boss_drakos.cpp b/src/server/scripts/Northrend/Nexus/Oculus/boss_drakos.cpp index 512af5d61ab..adc9ff2fbb0 100644 --- a/src/server/scripts/Northrend/Nexus/Oculus/boss_drakos.cpp +++ b/src/server/scripts/Northrend/Nexus/Oculus/boss_drakos.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Nexus/Oculus/boss_eregos.cpp b/src/server/scripts/Northrend/Nexus/Oculus/boss_eregos.cpp index e67a87558f6..b4dbc340066 100644 --- a/src/server/scripts/Northrend/Nexus/Oculus/boss_eregos.cpp +++ b/src/server/scripts/Northrend/Nexus/Oculus/boss_eregos.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Nexus/Oculus/boss_urom.cpp b/src/server/scripts/Northrend/Nexus/Oculus/boss_urom.cpp index e163ad5ca61..829132a80e6 100644 --- a/src/server/scripts/Northrend/Nexus/Oculus/boss_urom.cpp +++ b/src/server/scripts/Northrend/Nexus/Oculus/boss_urom.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Nexus/Oculus/boss_varos.cpp b/src/server/scripts/Northrend/Nexus/Oculus/boss_varos.cpp index 04965bb531d..af368ba1a3e 100644 --- a/src/server/scripts/Northrend/Nexus/Oculus/boss_varos.cpp +++ b/src/server/scripts/Northrend/Nexus/Oculus/boss_varos.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp b/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp index 737a5d5c982..2c12f62d61a 100644 --- a/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp +++ b/src/server/scripts/Northrend/Nexus/Oculus/instance_oculus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -23,8 +23,8 @@ DoorData const doorData[] = { - { GO_DRAGON_CAGE_DOOR, DATA_DRAKOS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } + { GO_DRAGON_CAGE_DOOR, DATA_DRAKOS, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } }; Position const VerdisaMove = { 949.188f, 1032.91f, 359.967f, 1.093027f }; diff --git a/src/server/scripts/Northrend/Nexus/Oculus/oculus.cpp b/src/server/scripts/Northrend/Nexus/Oculus/oculus.cpp index 3ab9814b5b5..e1a4a6ed7b8 100644 --- a/src/server/scripts/Northrend/Nexus/Oculus/oculus.cpp +++ b/src/server/scripts/Northrend/Nexus/Oculus/oculus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Nexus/Oculus/oculus.h b/src/server/scripts/Northrend/Nexus/Oculus/oculus.h index 08fc15c5752..9ec2dacabc8 100644 --- a/src/server/scripts/Northrend/Nexus/Oculus/oculus.h +++ b/src/server/scripts/Northrend/Nexus/Oculus/oculus.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_bjarngrim.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_bjarngrim.cpp index a1644b07db7..bc2fbe00f27 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_bjarngrim.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_bjarngrim.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -187,14 +187,14 @@ public: instance->SetBossState(DATA_BJARNGRIM, NOT_STARTED); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { if (me->HasAura(SPELL_TEMPORARY_ELECTRICAL_CHARGE)) canBuff = true; else canBuff = false; - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); } void EnterCombat(Unit* /*who*/) override diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_ionar.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_ionar.cpp index 51a036eb029..a98da2c6e3d 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_ionar.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_ionar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_loken.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_loken.cpp index 453423bd287..0843455fe3b 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_loken.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_loken.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_volkhan.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_volkhan.cpp index 3853b0aedfc..f20de459b12 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_volkhan.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/boss_volkhan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/halls_of_lightning.h b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/halls_of_lightning.h index b1b4a3c09ca..f40cfc5798f 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/halls_of_lightning.h +++ b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/halls_of_lightning.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/instance_halls_of_lightning.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/instance_halls_of_lightning.cpp index 62079d7a2f2..37df62ac166 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfLightning/instance_halls_of_lightning.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfLightning/instance_halls_of_lightning.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -21,10 +21,10 @@ DoorData const doorData[] = { - { GO_VOLKHAN_DOOR, DATA_VOLKHAN, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_IONAR_DOOR, DATA_IONAR, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_LOKEN_DOOR, DATA_LOKEN, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_VOLKHAN_DOOR, DATA_VOLKHAN, DOOR_TYPE_PASSAGE }, + { GO_IONAR_DOOR, DATA_IONAR, DOOR_TYPE_PASSAGE }, + { GO_LOKEN_DOOR, DATA_LOKEN, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_halls_of_lightning : public InstanceMapScript diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_krystallus.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_krystallus.cpp index e4c4e14e02a..7cbd942ae54 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_krystallus.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_krystallus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_maiden_of_grief.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_maiden_of_grief.cpp index dbd7f888f75..2ffe06f0d75 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_maiden_of_grief.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_maiden_of_grief.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_sjonnir.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_sjonnir.cpp index 3bb3360433e..9eff8d17eed 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_sjonnir.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfStone/boss_sjonnir.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.cpp index 86dbe6c16fb..9ce713dae51 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.h b/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.h index df56aadfe22..c016513d877 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.h +++ b/src/server/scripts/Northrend/Ulduar/HallsOfStone/halls_of_stone.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/HallsOfStone/instance_halls_of_stone.cpp b/src/server/scripts/Northrend/Ulduar/HallsOfStone/instance_halls_of_stone.cpp index 227b9c208cc..c6822235ce6 100644 --- a/src/server/scripts/Northrend/Ulduar/HallsOfStone/instance_halls_of_stone.cpp +++ b/src/server/scripts/Northrend/Ulduar/HallsOfStone/instance_halls_of_stone.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -22,8 +22,8 @@ DoorData const doorData[] = { - { GO_SJONNIR_DOOR, DATA_TRIBUNAL_OF_AGES, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_SJONNIR_DOOR, DATA_TRIBUNAL_OF_AGES, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_halls_of_stone : public InstanceMapScript diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_algalon_the_observer.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_algalon_the_observer.cpp index 7618a0b9156..89868fc7bf2 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_algalon_the_observer.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_algalon_the_observer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -492,10 +492,10 @@ class boss_algalon_the_observer : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { instance->SetBossState(BOSS_ALGALON, FAIL); - BossAI::EnterEvadeMode(); + BossAI::EnterEvadeMode(why); me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_IMMUNE_TO_PC); me->SetSheath(SHEATH_STATE_UNARMED); } @@ -545,7 +545,7 @@ class boss_algalon_the_observer : public CreatureScript void UpdateAI(uint32 diff) override { - if ((!(events.IsInPhase(PHASE_ROLE_PLAY) || events.IsInPhase(PHASE_BIG_BANG)) && !UpdateVictim()) || !CheckInRoom()) + if (!(events.IsInPhase(PHASE_ROLE_PLAY) || events.IsInPhase(PHASE_BIG_BANG)) && !UpdateVictim()) return; events.Update(diff); @@ -639,7 +639,7 @@ class boss_algalon_the_observer : public CreatureScript events.ScheduleEvent(EVENT_EVADE, 2500); break; case EVENT_EVADE: - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); break; case EVENT_COSMIC_SMASH: Talk(EMOTE_ALGALON_COSMIC_SMASH); @@ -979,6 +979,9 @@ class go_celestial_planetarium_access : public GameObjectScript bool GossipHello(Player* player) override { + if (go->HasFlag(GAMEOBJECT_FLAGS, GO_FLAG_IN_USE)) + return true; + bool hasKey = true; if (LockEntry const* lock = sLockStore.LookupEntry(go->GetGOInfo()->goober.lockId)) { diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp index 60b29a9207c..833c51eee97 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_assembly_of_iron.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_auriaya.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_auriaya.cpp index 92960972652..eda40f0298e 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_auriaya.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_auriaya.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_flame_leviathan.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_flame_leviathan.cpp index b31436f656a..6dfc3bf01e7 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_flame_leviathan.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_flame_leviathan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -369,7 +369,7 @@ class boss_flame_leviathan : public CreatureScript void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; events.Update(diff); @@ -1186,6 +1186,7 @@ class npc_brann_bronzebeard_ulduar_intro : public CreatureScript { if (menuId == GOSSIP_MENU_BRANN_BRONZEBEARD && gossipListId == GOSSIP_OPTION_BRANN_BRONZEBEARD) { + me->RemoveFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_GOSSIP); player->PlayerTalkClass->SendCloseGossip(); if (Creature* loreKeeper = _instance->GetCreature(DATA_LORE_KEEPER_OF_NORGANNON)) loreKeeper->RemoveFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_GOSSIP); @@ -1238,6 +1239,7 @@ class npc_lorekeeper : public CreatureScript { if (menuId == GOSSIP_MENU_LORE_KEEPER && gossipListId == GOSSIP_OPTION_LORE_KEEPER) { + me->RemoveFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_GOSSIP); player->PlayerTalkClass->SendCloseGossip(); _instance->instance->LoadGrid(364, -16); // make sure leviathan is loaded @@ -1250,6 +1252,7 @@ class npc_lorekeeper : public CreatureScript { if (Creature* brann = _instance->GetCreature(DATA_BRANN_BRONZEBEARD_INTRO)) { + brann->RemoveFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_GOSSIP); delorah->GetMotionMaster()->MovePoint(0, brann->GetPositionX() - 4, brann->GetPositionY(), brann->GetPositionZ()); /// @todo delorah->AI()->Talk(xxxx, brann->GetGUID()); when reached at branz } @@ -1765,9 +1768,7 @@ class spell_vehicle_throw_passenger : public SpellScriptLoader else { passenger->ExitVehicle(); - float x, y, z; - targets.GetDstPos()->GetPosition(x, y, z); - passenger->GetMotionMaster()->MoveJump(x, y, z, targets.GetSpeedXY(), targets.GetSpeedZ()); + passenger->GetMotionMaster()->MoveJump(*targets.GetDstPos(), targets.GetSpeedXY(), targets.GetSpeedZ()); } } } diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_freya.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_freya.cpp index 6958b5d78a5..05beacca638 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_freya.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_freya.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -222,7 +222,6 @@ class npc_iron_roots : public CreatureScript { SetCombatMovement(false); - me->ApplySpellImmune(0, IMMUNITY_EFFECT, SPELL_EFFECT_KNOCK_BACK, true); me->ApplySpellImmune(0, IMMUNITY_ID, 49560, true); // Death Grip me->setFaction(14); me->SetReactState(REACT_PASSIVE); diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_general_vezax.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_general_vezax.cpp index 7e005eff303..09d95b34521 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_general_vezax.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_general_vezax.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -380,7 +380,6 @@ class npc_saronite_vapors : public CreatureScript { Talk(EMOTE_VAPORS); instance = me->GetInstanceScript(); - me->ApplySpellImmune(0, IMMUNITY_EFFECT, SPELL_EFFECT_KNOCK_BACK, true); me->ApplySpellImmune(0, IMMUNITY_ID, 49560, true); // Death Grip jump effect me->SetReactState(REACT_PASSIVE); } diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp index 4b60107a182..c35a5936822 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_hodir.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_ignis.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_ignis.cpp index a04b53ac495..cd214a0114f 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_ignis.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_ignis.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -277,8 +277,6 @@ class boss_ignis : public CreatureScript } DoMeleeAttackIfReady(); - - EnterEvadeIfOutOfCombatArea(diff); } private: diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_kologarn.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_kologarn.cpp index 92c7d18a065..470ad388fff 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_kologarn.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_kologarn.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_mimiron.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_mimiron.cpp index 5c852cd7f26..e694433c614 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_mimiron.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_mimiron.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -444,7 +444,7 @@ class boss_mimiron : public CreatureScript DoCastAOE(SPELL_DESPAWN_ASSAULT_BOTS); me->ExitVehicle(); // ExitVehicle() offset position is not implemented, so we make up for that with MoveJump()... - me->GetMotionMaster()->MoveJump(me->GetPositionX() + (10.f * std::cos(me->GetOrientation())), me->GetPositionY() + (10.f * std::sin(me->GetOrientation())), me->GetPositionZ(), 10.f, 5.f); + me->GetMotionMaster()->MoveJump(me->GetPositionX() + (10.f * std::cos(me->GetOrientation())), me->GetPositionY() + (10.f * std::sin(me->GetOrientation())), me->GetPositionZ(), me->GetOrientation(), 10.f, 5.f); events.ScheduleEvent(EVENT_OUTTRO_1, 7000); } @@ -478,7 +478,7 @@ class boss_mimiron : public CreatureScript void UpdateAI(uint32 diff) override { - if ((!UpdateVictim() || !CheckInRoom()) && instance->GetBossState(BOSS_MIMIRON) != DONE) + if (!UpdateVictim() && instance->GetBossState(BOSS_MIMIRON) != DONE) return; events.Update(diff); @@ -846,7 +846,7 @@ class boss_leviathan_mk_ii : public CreatureScript void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; events.Update(diff); @@ -999,7 +999,7 @@ class boss_vx_001 : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { summons.DespawnAll(); } @@ -1174,7 +1174,7 @@ class boss_aerial_command_unit : public CreatureScript } } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { summons.DespawnAll(); } @@ -1634,8 +1634,11 @@ class go_mimiron_hardmode_button : public GameObjectScript public: go_mimiron_hardmode_button() : GameObjectScript("go_mimiron_hardmode_button") { } - bool OnGossipHello(Player* /*player*/, GameObject* go) + bool OnGossipHello(Player* /*player*/, GameObject* go) override { + if (go->HasFlag(GAMEOBJECT_FLAGS, GO_FLAG_NOT_SELECTABLE)) + return true; + InstanceScript* instance = go->GetInstanceScript(); if (!instance) return false; diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_razorscale.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_razorscale.cpp index 56628ce7b97..f5337b2dca5 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_razorscale.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_razorscale.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_thorim.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_thorim.cpp index 597067fd81f..3f783e8201c 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_thorim.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_thorim.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -54,10 +54,10 @@ class boss_thorim : public CreatureScript _Reset(); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { Talk(SAY_WIPE); - _EnterEvadeMode(); + _EnterEvadeMode(why); } void KilledUnit(Unit* who) override @@ -78,7 +78,7 @@ class boss_thorim : public CreatureScript _EnterCombat(); } - void UpdateAI(uint32 diff) override + void UpdateAI(uint32 /*diff*/) override { if (!UpdateVictim()) return; @@ -86,8 +86,6 @@ class boss_thorim : public CreatureScript // DoMeleeAttackIfReady(); - - EnterEvadeIfOutOfCombatArea(diff); } }; diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_xt002.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_xt002.cpp index 4eb5c06b26f..8cb20eadc9f 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_xt002.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_xt002.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -267,7 +267,7 @@ class boss_xt002 : public CreatureScript void UpdateAI(uint32 diff) override { - if (!UpdateVictim() || !CheckInRoom()) + if (!UpdateVictim()) return; events.Update(diff); diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_yogg_saron.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_yogg_saron.cpp index 8545d5b21eb..7da67171b5c 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/boss_yogg_saron.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/boss_yogg_saron.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -447,9 +447,9 @@ class boss_voice_of_yogg_saron : public CreatureScript me->SetInCombatWithZone(); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - BossAI::EnterEvadeMode(); + BossAI::EnterEvadeMode(why); for (uint8 i = DATA_SARA; i <= DATA_MIMIRON_YS; ++i) if (Creature* creature = ObjectAccessor::GetCreature(*me, instance->GetGuidData(i))) diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp b/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp index f2edfa816a0..ab51128a5c4 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/instance_ulduar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -24,26 +24,43 @@ #include "WorldPacket.h" #include "ulduar.h" +static BossBoundaryData const boundaries = +{ + { BOSS_LEVIATHAN, new RectangleBoundary(148.0f, 401.3f, -155.0f, 90.0f) }, + { BOSS_IGNIS, new RectangleBoundary(495.0f, 680.0f, 90.0f, 400.0f) }, + { BOSS_RAZORSCALE, new RectangleBoundary(370.0f, 810.0f, -542.0f, -55.0f) }, + { BOSS_XT002, new RectangleBoundary(755.0f, 940.0f, -125.0f, 95.0f) }, + { BOSS_ASSEMBLY_OF_IRON, new CircleBoundary(Position(1587.2f, 121.0f), 90.0) }, + { BOSS_ALGALON, new CircleBoundary(Position(1632.668f, -307.7656f), 45.0) }, + { BOSS_ALGALON, new ZRangeBoundary(410.0f, 440.0f) }, + { BOSS_HODIR, new EllipseBoundary(Position(2001.5f, -240.0f), 50.0, 75.0) }, + { BOSS_THORIM, new CircleBoundary(Position(2134.73f, -263.2f), 50.0) }, + { BOSS_FREYA, new RectangleBoundary(2094.6f, 2520.0f, -250.0f, 200.0f) }, + { BOSS_MIMIRON, new CircleBoundary(Position(2744.0f, 2569.0f), 70.0) }, + { BOSS_VEZAX, new RectangleBoundary(1740.0f, 1930.0f, 31.0f, 228.0f) }, + { BOSS_YOGG_SARON, new CircleBoundary(Position(1980.42f, -27.68f), 105.0) } +}; + static DoorData const doorData[] = { - { GO_LEVIATHAN_DOOR, BOSS_LEVIATHAN, DOOR_TYPE_ROOM, BOUNDARY_S }, - { GO_XT_002_DOOR, BOSS_XT002, DOOR_TYPE_ROOM, BOUNDARY_S }, - { GO_IRON_COUNCIL_DOOR, BOSS_ASSEMBLY_OF_IRON, DOOR_TYPE_ROOM, BOUNDARY_N }, - { GO_ARCHIVUM_DOOR, BOSS_ASSEMBLY_OF_IRON, DOOR_TYPE_PASSAGE, BOUNDARY_S }, - { GO_HODIR_ENTRANCE, BOSS_HODIR, DOOR_TYPE_ROOM, BOUNDARY_E }, - { GO_HODIR_DOOR, BOSS_HODIR, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_HODIR_ICE_DOOR, BOSS_HODIR, DOOR_TYPE_PASSAGE, BOUNDARY_W }, - { GO_MIMIRON_DOOR_1, BOSS_MIMIRON, DOOR_TYPE_ROOM, BOUNDARY_W }, - { GO_MIMIRON_DOOR_2, BOSS_MIMIRON, DOOR_TYPE_ROOM, BOUNDARY_E }, - { GO_MIMIRON_DOOR_3, BOSS_MIMIRON, DOOR_TYPE_ROOM, BOUNDARY_S }, - { GO_VEZAX_DOOR, BOSS_VEZAX, DOOR_TYPE_PASSAGE, BOUNDARY_E }, - { GO_YOGG_SARON_DOOR, BOSS_YOGG_SARON, DOOR_TYPE_ROOM, BOUNDARY_S }, - { GO_DOODAD_UL_SIGILDOOR_03, BOSS_ALGALON, DOOR_TYPE_ROOM, BOUNDARY_W }, - { GO_DOODAD_UL_UNIVERSEFLOOR_01, BOSS_ALGALON, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_DOODAD_UL_UNIVERSEFLOOR_02, BOSS_ALGALON, DOOR_TYPE_SPAWN_HOLE, BOUNDARY_NONE }, - { GO_DOODAD_UL_UNIVERSEGLOBE01, BOSS_ALGALON, DOOR_TYPE_SPAWN_HOLE, BOUNDARY_NONE }, - { GO_DOODAD_UL_ULDUAR_TRAPDOOR_03, BOSS_ALGALON, DOOR_TYPE_SPAWN_HOLE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE }, + { GO_LEVIATHAN_DOOR, BOSS_LEVIATHAN, DOOR_TYPE_ROOM }, + { GO_XT_002_DOOR, BOSS_XT002, DOOR_TYPE_ROOM }, + { GO_IRON_COUNCIL_DOOR, BOSS_ASSEMBLY_OF_IRON, DOOR_TYPE_ROOM }, + { GO_ARCHIVUM_DOOR, BOSS_ASSEMBLY_OF_IRON, DOOR_TYPE_PASSAGE }, + { GO_HODIR_ENTRANCE, BOSS_HODIR, DOOR_TYPE_ROOM }, + { GO_HODIR_DOOR, BOSS_HODIR, DOOR_TYPE_PASSAGE }, + { GO_HODIR_ICE_DOOR, BOSS_HODIR, DOOR_TYPE_PASSAGE }, + { GO_MIMIRON_DOOR_1, BOSS_MIMIRON, DOOR_TYPE_ROOM }, + { GO_MIMIRON_DOOR_2, BOSS_MIMIRON, DOOR_TYPE_ROOM }, + { GO_MIMIRON_DOOR_3, BOSS_MIMIRON, DOOR_TYPE_ROOM }, + { GO_VEZAX_DOOR, BOSS_VEZAX, DOOR_TYPE_PASSAGE }, + { GO_YOGG_SARON_DOOR, BOSS_YOGG_SARON, DOOR_TYPE_ROOM }, + { GO_DOODAD_UL_SIGILDOOR_03, BOSS_ALGALON, DOOR_TYPE_ROOM }, + { GO_DOODAD_UL_UNIVERSEFLOOR_01, BOSS_ALGALON, DOOR_TYPE_ROOM }, + { GO_DOODAD_UL_UNIVERSEFLOOR_02, BOSS_ALGALON, DOOR_TYPE_SPAWN_HOLE }, + { GO_DOODAD_UL_UNIVERSEGLOBE01, BOSS_ALGALON, DOOR_TYPE_SPAWN_HOLE }, + { GO_DOODAD_UL_ULDUAR_TRAPDOOR_03, BOSS_ALGALON, DOOR_TYPE_SPAWN_HOLE }, + { 0, 0, DOOR_TYPE_ROOM }, }; MinionData const minionData[] = @@ -74,7 +91,7 @@ class instance_ulduar : public InstanceMapScript { SetHeaders(DataHeader); SetBossNumber(MAX_ENCOUNTER); - + LoadBossBoundaries(boundaries); LoadDoorData(doorData); LoadMinionData(minionData); LoadObjectData(creatureData, nullptr); @@ -818,12 +835,9 @@ class instance_ulduar : public InstanceMapScript { case DATA_COLOSSUS: ColossusData = data; - if (data == 2) + if (data == 2 && GetBossState(BOSS_LEVIATHAN) == NOT_STARTED) { - if (Creature* Leviathan = instance->GetCreature(LeviathanGUID)) - Leviathan->AI()->DoAction(ACTION_MOVE_TO_CENTER_POSITION); - if (GameObject* gameObject = instance->GetGameObject(LeviathanGateGUID)) - gameObject->SetGoState(GO_STATE_ACTIVE_ALTERNATIVE); + _events.ScheduleEvent(EVENT_LEVIATHAN_BREAK_DOOR, 5 * IN_MILLISECONDS); SaveToDB(); } break; @@ -1179,6 +1193,12 @@ class instance_ulduar : public InstanceMapScript } } break; + case EVENT_LEVIATHAN_BREAK_DOOR: + if (Creature* Leviathan = instance->GetCreature(LeviathanGUID)) + Leviathan->AI()->DoAction(ACTION_MOVE_TO_CENTER_POSITION); + if (GameObject* gameObject = instance->GetGameObject(LeviathanGateGUID)) + gameObject->SetGoState(GO_STATE_ACTIVE_ALTERNATIVE); + break; } } } diff --git a/src/server/scripts/Northrend/Ulduar/Ulduar/ulduar.h b/src/server/scripts/Northrend/Ulduar/Ulduar/ulduar.h index 834ab32864f..58c963f9cb5 100644 --- a/src/server/scripts/Northrend/Ulduar/Ulduar/ulduar.h +++ b/src/server/scripts/Northrend/Ulduar/Ulduar/ulduar.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -427,7 +427,8 @@ enum UlduarEvents EVENT_DESPAWN_ALGALON = 1, EVENT_UPDATE_ALGALON_TIMER = 2, ACTION_INIT_ALGALON = 6, - EVENT_DESPAWN_LEVIATHAN_VEHICLES = 7 + EVENT_DESPAWN_LEVIATHAN_VEHICLES = 7, + EVENT_LEVIATHAN_BREAK_DOOR = 8 }; enum YoggSaronIllusions diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_ingvar_the_plunderer.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_ingvar_the_plunderer.cpp index 483beda43ee..86a4a9caf3a 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_ingvar_the_plunderer.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_ingvar_the_plunderer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -110,30 +110,24 @@ class boss_ingvar_the_plunderer : public CreatureScript { if (me->GetEntry() != NPC_INGVAR) me->UpdateEntry(NPC_INGVAR); - me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_IMMUNE_TO_PC | UNIT_FLAG_NOT_SELECTABLE); _Reset(); - events.SetPhase(PHASE_HUMAN); - - events.ScheduleEvent(EVENT_CLEAVE, urand(6, 12)*IN_MILLISECONDS, 0, PHASE_HUMAN); - events.ScheduleEvent(EVENT_STAGGERING_ROAR, urand(18, 21)*IN_MILLISECONDS, 0, PHASE_HUMAN); - events.ScheduleEvent(EVENT_ENRAGE, urand(7, 14)*IN_MILLISECONDS, 0, PHASE_HUMAN); - events.ScheduleEvent(EVENT_SMASH, urand(12, 17)*IN_MILLISECONDS, 0, PHASE_HUMAN); } void DamageTaken(Unit* /*doneBy*/, uint32& damage) override { if (damage >= me->GetHealth() && events.IsInPhase(PHASE_HUMAN)) { + events.SetPhase(PHASE_EVENT); + events.ScheduleEvent(EVENT_SUMMON_BANSHEE, 3 * IN_MILLISECONDS, 0, PHASE_EVENT); + me->RemoveAllAuras(); + me->StopMoving(); DoCast(me, SPELL_INGVAR_FEIGN_DEATH, true); me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_IMMUNE_TO_PC | UNIT_FLAG_NOT_SELECTABLE); - events.SetPhase(PHASE_EVENT); - events.ScheduleEvent(EVENT_SUMMON_BANSHEE, 3 * IN_MILLISECONDS, 0, PHASE_EVENT); - Talk(SAY_DEATH); } @@ -152,13 +146,28 @@ class boss_ingvar_the_plunderer : public CreatureScript me->RemoveAura(SPELL_INGVAR_FEIGN_DEATH); DoCast(me, SPELL_INGVAR_TRANSFORM, true); me->UpdateEntry(NPC_INGVAR_UNDEAD); - events.ScheduleEvent(EVENT_JUST_TRANSFORMED, 2 * IN_MILLISECONDS, 0, PHASE_EVENT); + events.ScheduleEvent(EVENT_JUST_TRANSFORMED, IN_MILLISECONDS / 2, 0, PHASE_EVENT); } void EnterCombat(Unit* /*who*/) override { + if (events.IsInPhase(PHASE_EVENT) || events.IsInPhase(PHASE_UNDEAD)) // ingvar gets multiple EnterCombat calls + return; _EnterCombat(); + Talk(SAY_AGGRO); + events.SetPhase(PHASE_HUMAN); + events.ScheduleEvent(EVENT_CLEAVE, urand(6, 12)*IN_MILLISECONDS, 0, PHASE_HUMAN); + events.ScheduleEvent(EVENT_STAGGERING_ROAR, urand(18, 21)*IN_MILLISECONDS, 0, PHASE_HUMAN); + events.ScheduleEvent(EVENT_ENRAGE, urand(7, 14)*IN_MILLISECONDS, 0, PHASE_HUMAN); + events.ScheduleEvent(EVENT_SMASH, urand(12, 17)*IN_MILLISECONDS, 0, PHASE_HUMAN); + } + + void AttackStart(Unit* who) override + { + if (events.IsInPhase(PHASE_EVENT)) // prevent ingvar from beginning to attack/chase during transition + return; + BossAI::AttackStart(who); } void JustDied(Unit* /*killer*/) override @@ -171,7 +180,7 @@ class boss_ingvar_the_plunderer : public CreatureScript { events.SetPhase(PHASE_UNDEAD); events.ScheduleEvent(EVENT_DARK_SMASH, urand(14, 18)*IN_MILLISECONDS, 0, PHASE_UNDEAD); - events.ScheduleEvent(EVENT_DREADFUL_ROAR, urand(18, 22)*IN_MILLISECONDS, 0, PHASE_UNDEAD); + events.ScheduleEvent(EVENT_DREADFUL_ROAR, 0, 0, PHASE_UNDEAD); events.ScheduleEvent(EVENT_WOE_STRIKE, urand(10, 14)*IN_MILLISECONDS, 0, PHASE_UNDEAD); events.ScheduleEvent(EVENT_SHADOW_AXE, 30*IN_MILLISECONDS, 0, PHASE_UNDEAD); } @@ -214,9 +223,17 @@ class boss_ingvar_the_plunderer : public CreatureScript events.ScheduleEvent(EVENT_SMASH, urand(12, 16)*IN_MILLISECONDS, 0, PHASE_HUMAN); break; case EVENT_JUST_TRANSFORMED: + ScheduleSecondPhase(); me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE | UNIT_FLAG_IMMUNE_TO_PC | UNIT_FLAG_NOT_SELECTABLE); + if (Unit* target = me->getThreatManager().getHostilTarget()) + AttackStart(target); + else + { + EnterEvadeMode(EVADE_REASON_NO_HOSTILES); + return; + } + Talk(SAY_AGGRO); DoZoneInCombat(); - ScheduleSecondPhase(); return; case EVENT_SUMMON_BANSHEE: DoCast(me, SPELL_SUMMON_BANSHEE); diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_keleseth.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_keleseth.cpp index ff231a01296..4be4e4919da 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_keleseth.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_keleseth.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_skarvald_dalronn.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_skarvald_dalronn.cpp index 52d5761a038..32dcda6f1b9 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_skarvald_dalronn.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/boss_skarvald_dalronn.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/instance_utgarde_keep.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/instance_utgarde_keep.cpp index 38fee296bec..fbcf464d8b1 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/instance_utgarde_keep.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/instance_utgarde_keep.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -21,9 +21,9 @@ DoorData const doorData[] = { - { GO_GIANT_PORTCULLIS_1, DATA_INGVAR, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_GIANT_PORTCULLIS_2, DATA_INGVAR, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_GIANT_PORTCULLIS_1, DATA_INGVAR, DOOR_TYPE_PASSAGE }, + { GO_GIANT_PORTCULLIS_2, DATA_INGVAR, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; MinionData const minionData[] = diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/utgarde_keep.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/utgarde_keep.cpp index 974ee5b054b..6c9f7e215e6 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/utgarde_keep.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/utgarde_keep.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/utgarde_keep.h b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/utgarde_keep.h index b776b1a8c6a..3d1b57eda86 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/utgarde_keep.h +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardeKeep/utgarde_keep.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_palehoof.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_palehoof.cpp index acccdb2f912..1af45f3031a 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_palehoof.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_palehoof.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_skadi.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_skadi.cpp index a2b964cbe60..d7b65093898 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_skadi.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_skadi.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -238,7 +238,7 @@ public: me->SetInCombatWithZone(); instance->SetBossState(DATA_SKADI_THE_RUTHLESS, IN_PROGRESS); instance->DoStartTimedAchievement(ACHIEVEMENT_TIMED_TYPE_EVENT, ACHIEV_TIMED_START_EVENT); - me->GetMotionMaster()->MoveJump(Location[0].GetPositionX(), Location[0].GetPositionY(), Location[0].GetPositionZ(), 5.0f, 10.0f); + me->GetMotionMaster()->MoveJump(Location[0], 5.0f, 10.0f); me->SetWalk(false); m_uiMountTimer = 1000; Summons.DespawnEntry(NPC_GRAUF); @@ -289,7 +289,7 @@ public: pGrauf->GetMotionMaster()->MoveFall(); pGrauf->HandleEmoteCommand(EMOTE_ONESHOT_FLYDEATH); } - me->GetMotionMaster()->MoveJump(Location[4].GetPositionX(), Location[4].GetPositionY(), Location[4].GetPositionZ(), 5.0f, 10.0f); + me->GetMotionMaster()->MoveJump(Location[4], 5.0f, 10.0f); me->RemoveFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NOT_SELECTABLE | UNIT_FLAG_NON_ATTACKABLE); Talk(SAY_DRAKE_DEATH); m_uiCrushTimer = 8000; diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_svala.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_svala.cpp index 263304488b7..6804717037a 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_svala.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_svala.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_ymiron.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_ymiron.cpp index cfe8f24577d..8e06c1d670c 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_ymiron.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/boss_ymiron.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/instance_utgarde_pinnacle.cpp b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/instance_utgarde_pinnacle.cpp index c9202fd7007..8f2d5a61770 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/instance_utgarde_pinnacle.cpp +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/instance_utgarde_pinnacle.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -19,11 +19,16 @@ #include "InstanceScript.h" #include "utgarde_pinnacle.h" +BossBoundaryData const boundaries = +{ + { DATA_KING_YMIRON, new RectangleBoundary(340.0f, 450.0f, -412.0f, -275.0f) } +}; + DoorData const doorData[] = { - { GO_SKADI_THE_RUTHLESS_DOOR, DATA_SKADI_THE_RUTHLESS, DOOR_TYPE_PASSAGE, BOUNDARY_W }, - { GO_KING_YMIRON_DOOR, DATA_KING_YMIRON, DOOR_TYPE_PASSAGE, BOUNDARY_N }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_SKADI_THE_RUTHLESS_DOOR, DATA_SKADI_THE_RUTHLESS, DOOR_TYPE_PASSAGE }, + { GO_KING_YMIRON_DOOR, DATA_KING_YMIRON, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_utgarde_pinnacle : public InstanceMapScript @@ -37,6 +42,7 @@ class instance_utgarde_pinnacle : public InstanceMapScript { SetHeaders(DataHeader); SetBossNumber(EncounterCount); + LoadBossBoundaries(boundaries); LoadDoorData(doorData); } diff --git a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/utgarde_pinnacle.h b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/utgarde_pinnacle.h index 33fc08065ad..2265bc03b03 100644 --- a/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/utgarde_pinnacle.h +++ b/src/server/scripts/Northrend/UtgardeKeep/UtgardePinnacle/utgarde_pinnacle.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VaultOfArchavon/boss_archavon.cpp b/src/server/scripts/Northrend/VaultOfArchavon/boss_archavon.cpp index 96691a290b2..b89c11147b6 100644 --- a/src/server/scripts/Northrend/VaultOfArchavon/boss_archavon.cpp +++ b/src/server/scripts/Northrend/VaultOfArchavon/boss_archavon.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VaultOfArchavon/boss_emalon.cpp b/src/server/scripts/Northrend/VaultOfArchavon/boss_emalon.cpp index 27345d0dc6d..8a316381dbd 100644 --- a/src/server/scripts/Northrend/VaultOfArchavon/boss_emalon.cpp +++ b/src/server/scripts/Northrend/VaultOfArchavon/boss_emalon.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VaultOfArchavon/boss_koralon.cpp b/src/server/scripts/Northrend/VaultOfArchavon/boss_koralon.cpp index 9c96d7e3f49..8b52add48e3 100644 --- a/src/server/scripts/Northrend/VaultOfArchavon/boss_koralon.cpp +++ b/src/server/scripts/Northrend/VaultOfArchavon/boss_koralon.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VaultOfArchavon/boss_toravon.cpp b/src/server/scripts/Northrend/VaultOfArchavon/boss_toravon.cpp index 68be133b67b..06ebcbdc2fb 100644 --- a/src/server/scripts/Northrend/VaultOfArchavon/boss_toravon.cpp +++ b/src/server/scripts/Northrend/VaultOfArchavon/boss_toravon.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VaultOfArchavon/instance_vault_of_archavon.cpp b/src/server/scripts/Northrend/VaultOfArchavon/instance_vault_of_archavon.cpp index 72d5e8a0382..988346a282c 100644 --- a/src/server/scripts/Northrend/VaultOfArchavon/instance_vault_of_archavon.cpp +++ b/src/server/scripts/Northrend/VaultOfArchavon/instance_vault_of_archavon.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VaultOfArchavon/vault_of_archavon.h b/src/server/scripts/Northrend/VaultOfArchavon/vault_of_archavon.h index 581f7707c81..d86fd580949 100644 --- a/src/server/scripts/Northrend/VaultOfArchavon/vault_of_archavon.h +++ b/src/server/scripts/Northrend/VaultOfArchavon/vault_of_archavon.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VioletHold/boss_cyanigosa.cpp b/src/server/scripts/Northrend/VioletHold/boss_cyanigosa.cpp index d3868b8df9c..d247c3b04d6 100644 --- a/src/server/scripts/Northrend/VioletHold/boss_cyanigosa.cpp +++ b/src/server/scripts/Northrend/VioletHold/boss_cyanigosa.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VioletHold/boss_erekem.cpp b/src/server/scripts/Northrend/VioletHold/boss_erekem.cpp index cc27bf52118..ed58d6542b9 100644 --- a/src/server/scripts/Northrend/VioletHold/boss_erekem.cpp +++ b/src/server/scripts/Northrend/VioletHold/boss_erekem.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VioletHold/boss_ichoron.cpp b/src/server/scripts/Northrend/VioletHold/boss_ichoron.cpp index 3c29cc1123c..17f101b865c 100644 --- a/src/server/scripts/Northrend/VioletHold/boss_ichoron.cpp +++ b/src/server/scripts/Northrend/VioletHold/boss_ichoron.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VioletHold/boss_lavanthor.cpp b/src/server/scripts/Northrend/VioletHold/boss_lavanthor.cpp index c3b617f8199..06e41c178c4 100644 --- a/src/server/scripts/Northrend/VioletHold/boss_lavanthor.cpp +++ b/src/server/scripts/Northrend/VioletHold/boss_lavanthor.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VioletHold/boss_moragg.cpp b/src/server/scripts/Northrend/VioletHold/boss_moragg.cpp index 41542416468..31991480d36 100644 --- a/src/server/scripts/Northrend/VioletHold/boss_moragg.cpp +++ b/src/server/scripts/Northrend/VioletHold/boss_moragg.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VioletHold/boss_xevozz.cpp b/src/server/scripts/Northrend/VioletHold/boss_xevozz.cpp index 93e74aaca71..0db7cb2cf43 100644 --- a/src/server/scripts/Northrend/VioletHold/boss_xevozz.cpp +++ b/src/server/scripts/Northrend/VioletHold/boss_xevozz.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VioletHold/boss_zuramat.cpp b/src/server/scripts/Northrend/VioletHold/boss_zuramat.cpp index 14d7b5fcd95..2ed632ca07b 100644 --- a/src/server/scripts/Northrend/VioletHold/boss_zuramat.cpp +++ b/src/server/scripts/Northrend/VioletHold/boss_zuramat.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp b/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp index 14c3ac58b1f..868415d93b2 100644 --- a/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp +++ b/src/server/scripts/Northrend/VioletHold/instance_violet_hold.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VioletHold/violet_hold.cpp b/src/server/scripts/Northrend/VioletHold/violet_hold.cpp index fdb4c4dc3fc..4c8afb72886 100644 --- a/src/server/scripts/Northrend/VioletHold/violet_hold.cpp +++ b/src/server/scripts/Northrend/VioletHold/violet_hold.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/VioletHold/violet_hold.h b/src/server/scripts/Northrend/VioletHold/violet_hold.h index 113a3c46ea0..314de0cd42c 100644 --- a/src/server/scripts/Northrend/VioletHold/violet_hold.h +++ b/src/server/scripts/Northrend/VioletHold/violet_hold.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/isle_of_conquest.cpp b/src/server/scripts/Northrend/isle_of_conquest.cpp index fccdc8098b6..68121e940c9 100644 --- a/src/server/scripts/Northrend/isle_of_conquest.cpp +++ b/src/server/scripts/Northrend/isle_of_conquest.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -206,7 +206,7 @@ class spell_ioc_parachute_ic : public SpellScriptLoader class StartLaunchEvent : public BasicEvent { public: - StartLaunchEvent(float x, float y, float z, ObjectGuid::LowType lowGuid) : _x(x), _y(y), _z(z), _lowGuid(lowGuid) + StartLaunchEvent(Position const& pos, ObjectGuid::LowType lowGuid) : _pos(pos), _lowGuid(lowGuid) { } @@ -218,15 +218,15 @@ class StartLaunchEvent : public BasicEvent player->AddAura(SPELL_LAUNCH_NO_FALLING_DAMAGE, player); // prevents falling damage float speedZ = 10.0f; - float dist = player->GetExactDist2d(_x, _y); + float dist = player->GetExactDist2d(&_pos); player->ExitVehicle(); - player->GetMotionMaster()->MoveJump(_x, _y, _z, dist, speedZ); + player->GetMotionMaster()->MoveJump(_pos, dist, speedZ, EVENT_JUMP, true); return true; } private: - float _x, _y, _z; + Position _pos; ObjectGuid::LowType _lowGuid; }; @@ -244,11 +244,7 @@ class spell_ioc_launch : public SpellScriptLoader if (!GetCaster()->ToCreature() || !GetExplTargetDest()) return; - float x, y, z; - x = GetExplTargetDest()->GetPositionX(); - y = GetExplTargetDest()->GetPositionY(); - z = GetExplTargetDest()->GetPositionZ(); - GetCaster()->ToCreature()->m_Events.AddEvent(new StartLaunchEvent(x, y, z, GetHitPlayer()->GetGUID().GetCounter()), GetCaster()->ToCreature()->m_Events.CalculateTime(2500)); + GetCaster()->ToCreature()->m_Events.AddEvent(new StartLaunchEvent(*GetExplTargetDest(), GetHitPlayer()->GetGUID().GetCounter()), GetCaster()->ToCreature()->m_Events.CalculateTime(2500)); } void Register() override diff --git a/src/server/scripts/Northrend/zone_borean_tundra.cpp b/src/server/scripts/Northrend/zone_borean_tundra.cpp index 7e56fd6ed4b..698fd510411 100644 --- a/src/server/scripts/Northrend/zone_borean_tundra.cpp +++ b/src/server/scripts/Northrend/zone_borean_tundra.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/zone_crystalsong_forest.cpp b/src/server/scripts/Northrend/zone_crystalsong_forest.cpp index 2fd5e6e56fa..5356276aca1 100644 --- a/src/server/scripts/Northrend/zone_crystalsong_forest.cpp +++ b/src/server/scripts/Northrend/zone_crystalsong_forest.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/zone_dalaran.cpp b/src/server/scripts/Northrend/zone_dalaran.cpp index f1fb95a8916..03af1a6417f 100644 --- a/src/server/scripts/Northrend/zone_dalaran.cpp +++ b/src/server/scripts/Northrend/zone_dalaran.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/zone_dragonblight.cpp b/src/server/scripts/Northrend/zone_dragonblight.cpp index dc5b75d425d..2ec2af80624 100644 --- a/src/server/scripts/Northrend/zone_dragonblight.cpp +++ b/src/server/scripts/Northrend/zone_dragonblight.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Northrend/zone_grizzly_hills.cpp b/src/server/scripts/Northrend/zone_grizzly_hills.cpp index 54b06260e78..59802165a94 100644 --- a/src/server/scripts/Northrend/zone_grizzly_hills.cpp +++ b/src/server/scripts/Northrend/zone_grizzly_hills.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -239,7 +239,7 @@ public: } } - void EnterEvadeMode() override { } + void EnterEvadeMode(EvadeReason /*why*/) override { } void MoveInLineOfSight(Unit* /*who*/) override { } diff --git a/src/server/scripts/Northrend/zone_howling_fjord.cpp b/src/server/scripts/Northrend/zone_howling_fjord.cpp index ba69a1385d5..765490305df 100644 --- a/src/server/scripts/Northrend/zone_howling_fjord.cpp +++ b/src/server/scripts/Northrend/zone_howling_fjord.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/zone_icecrown.cpp b/src/server/scripts/Northrend/zone_icecrown.cpp index 2e426fd77cf..1e020edd10a 100644 --- a/src/server/scripts/Northrend/zone_icecrown.cpp +++ b/src/server/scripts/Northrend/zone_icecrown.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -213,7 +213,6 @@ class npc_tournament_training_dummy : public CreatureScript void Reset() override { me->SetControlled(true, UNIT_STATE_STUNNED); - me->ApplySpellImmune(0, IMMUNITY_EFFECT, SPELL_EFFECT_KNOCK_BACK, true); Initialize(); // Cast Defend spells to max stack size @@ -231,9 +230,9 @@ class npc_tournament_training_dummy : public CreatureScript events.ScheduleEvent(EVENT_DUMMY_RECAST_DEFEND, 5000); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - if (!_EnterEvadeMode()) + if (!_EnterEvadeMode(why)) return; Reset(); @@ -304,7 +303,7 @@ class npc_tournament_training_dummy : public CreatureScript case EVENT_DUMMY_RESET: if (UpdateVictim()) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); events.ScheduleEvent(EVENT_DUMMY_RESET, 10000); } break; diff --git a/src/server/scripts/Northrend/zone_sholazar_basin.cpp b/src/server/scripts/Northrend/zone_sholazar_basin.cpp index 5d47e7fa4ec..f2edccd99b5 100644 --- a/src/server/scripts/Northrend/zone_sholazar_basin.cpp +++ b/src/server/scripts/Northrend/zone_sholazar_basin.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Northrend/zone_storm_peaks.cpp b/src/server/scripts/Northrend/zone_storm_peaks.cpp index e86e907b550..e5263a8630a 100644 --- a/src/server/scripts/Northrend/zone_storm_peaks.cpp +++ b/src/server/scripts/Northrend/zone_storm_peaks.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -338,7 +338,7 @@ public: void AttackStart(Unit* /*who*/) override { } void EnterCombat(Unit* /*who*/) override { } - void EnterEvadeMode() override { } + void EnterEvadeMode(EvadeReason /*why*/) override { } void PassengerBoarded(Unit* who, int8 /*seatId*/, bool apply) override { diff --git a/src/server/scripts/Northrend/zone_zuldrak.cpp b/src/server/scripts/Northrend/zone_zuldrak.cpp index e36930f5745..d7eabc3408e 100644 --- a/src/server/scripts/Northrend/zone_zuldrak.cpp +++ b/src/server/scripts/Northrend/zone_zuldrak.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/CMakeLists.txt b/src/server/scripts/OutdoorPvP/CMakeLists.txt index 14f7b9d371b..91ce4ce4186 100644 --- a/src/server/scripts/OutdoorPvP/CMakeLists.txt +++ b/src/server/scripts/OutdoorPvP/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPEP.cpp b/src/server/scripts/OutdoorPvP/OutdoorPvPEP.cpp index 89f35457a44..214ea537d28 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPEP.cpp +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPEP.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPEP.h b/src/server/scripts/OutdoorPvP/OutdoorPvPEP.h index c174c94d0ad..b605343ac05 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPEP.h +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPEP.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPHP.cpp b/src/server/scripts/OutdoorPvP/OutdoorPvPHP.cpp index a639962efde..90435e2c0b8 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPHP.cpp +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPHP.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPHP.h b/src/server/scripts/OutdoorPvP/OutdoorPvPHP.h index 218e61b0c49..71dbd139ea0 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPHP.h +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPHP.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPNA.cpp b/src/server/scripts/OutdoorPvP/OutdoorPvPNA.cpp index 8664acdfc57..c1528d782cf 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPNA.cpp +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPNA.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPNA.h b/src/server/scripts/OutdoorPvP/OutdoorPvPNA.h index 07bf6919b7a..4ed47c42206 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPNA.h +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPNA.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPSI.cpp b/src/server/scripts/OutdoorPvP/OutdoorPvPSI.cpp index d2892541373..a0b9351fb75 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPSI.cpp +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPSI.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPSI.h b/src/server/scripts/OutdoorPvP/OutdoorPvPSI.h index b528dfd4daa..f28fea926fc 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPSI.h +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPSI.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPTF.cpp b/src/server/scripts/OutdoorPvP/OutdoorPvPTF.cpp index 0b68a45f8a5..1cdb5119fec 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPTF.cpp +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPTF.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPTF.h b/src/server/scripts/OutdoorPvP/OutdoorPvPTF.h index e6421678d41..237fee3283b 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPTF.h +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPTF.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPZM.cpp b/src/server/scripts/OutdoorPvP/OutdoorPvPZM.cpp index 54aa815617e..ae75a9e5281 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPZM.cpp +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPZM.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/OutdoorPvP/OutdoorPvPZM.h b/src/server/scripts/OutdoorPvP/OutdoorPvPZM.h index 4be0d0eedb7..e71fbf79280 100644 --- a/src/server/scripts/OutdoorPvP/OutdoorPvPZM.h +++ b/src/server/scripts/OutdoorPvP/OutdoorPvPZM.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/auchenai_crypts.h b/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/auchenai_crypts.h index eb363102223..1f05f25cbdd 100644 --- a/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/auchenai_crypts.h +++ b/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/auchenai_crypts.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/boss_exarch_maladaar.cpp b/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/boss_exarch_maladaar.cpp index eba6b25e8eb..77a75cd133e 100644 --- a/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/boss_exarch_maladaar.cpp +++ b/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/boss_exarch_maladaar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/boss_shirrak_the_dead_watcher.cpp b/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/boss_shirrak_the_dead_watcher.cpp index 6e43cfa2d0f..79e455500b5 100644 --- a/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/boss_shirrak_the_dead_watcher.cpp +++ b/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/boss_shirrak_the_dead_watcher.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/instance_auchenai_crypts.cpp b/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/instance_auchenai_crypts.cpp index 21b5c3958d4..aded6054f7d 100644 --- a/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/instance_auchenai_crypts.cpp +++ b/src/server/scripts/Outland/Auchindoun/AuchenaiCrypts/instance_auchenai_crypts.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/Auchindoun/ManaTombs/boss_nexusprince_shaffar.cpp b/src/server/scripts/Outland/Auchindoun/ManaTombs/boss_nexusprince_shaffar.cpp index a14721fcf3c..9de5ec91fe5 100644 --- a/src/server/scripts/Outland/Auchindoun/ManaTombs/boss_nexusprince_shaffar.cpp +++ b/src/server/scripts/Outland/Auchindoun/ManaTombs/boss_nexusprince_shaffar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/Auchindoun/ManaTombs/boss_pandemonius.cpp b/src/server/scripts/Outland/Auchindoun/ManaTombs/boss_pandemonius.cpp index 5a7bc2f2864..60c4c0dd7d4 100644 --- a/src/server/scripts/Outland/Auchindoun/ManaTombs/boss_pandemonius.cpp +++ b/src/server/scripts/Outland/Auchindoun/ManaTombs/boss_pandemonius.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/Auchindoun/ManaTombs/instance_mana_tombs.cpp b/src/server/scripts/Outland/Auchindoun/ManaTombs/instance_mana_tombs.cpp index c4128c0769d..f072e0caaa1 100644 --- a/src/server/scripts/Outland/Auchindoun/ManaTombs/instance_mana_tombs.cpp +++ b/src/server/scripts/Outland/Auchindoun/ManaTombs/instance_mana_tombs.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/Auchindoun/ManaTombs/mana_tombs.h b/src/server/scripts/Outland/Auchindoun/ManaTombs/mana_tombs.h index ff54a0527ac..ab31ef88683 100644 --- a/src/server/scripts/Outland/Auchindoun/ManaTombs/mana_tombs.h +++ b/src/server/scripts/Outland/Auchindoun/ManaTombs/mana_tombs.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_anzu.cpp b/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_anzu.cpp index aaba6d67117..1db39b68a5a 100644 --- a/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_anzu.cpp +++ b/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_anzu.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_darkweaver_syth.cpp b/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_darkweaver_syth.cpp index 69ec1a15c37..f4c2de1e204 100644 --- a/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_darkweaver_syth.cpp +++ b/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_darkweaver_syth.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_talon_king_ikiss.cpp b/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_talon_king_ikiss.cpp index cf6de2a7beb..267a0007a6c 100644 --- a/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_talon_king_ikiss.cpp +++ b/src/server/scripts/Outland/Auchindoun/SethekkHalls/boss_talon_king_ikiss.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/Auchindoun/SethekkHalls/instance_sethekk_halls.cpp b/src/server/scripts/Outland/Auchindoun/SethekkHalls/instance_sethekk_halls.cpp index 76d59da32cc..cbf0d6b1ce5 100644 --- a/src/server/scripts/Outland/Auchindoun/SethekkHalls/instance_sethekk_halls.cpp +++ b/src/server/scripts/Outland/Auchindoun/SethekkHalls/instance_sethekk_halls.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -21,8 +21,8 @@ DoorData const doorData[] = { - { GO_IKISS_DOOR, DATA_TALON_KING_IKISS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_IKISS_DOOR, DATA_TALON_KING_IKISS, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; ObjectData const gameObjectData[] = diff --git a/src/server/scripts/Outland/Auchindoun/SethekkHalls/sethekk_halls.h b/src/server/scripts/Outland/Auchindoun/SethekkHalls/sethekk_halls.h index a073b71f282..6d7f7fcd093 100644 --- a/src/server/scripts/Outland/Auchindoun/SethekkHalls/sethekk_halls.h +++ b/src/server/scripts/Outland/Auchindoun/SethekkHalls/sethekk_halls.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_ambassador_hellmaw.cpp b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_ambassador_hellmaw.cpp index 80cc2028cb3..8acd6067c0b 100644 --- a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_ambassador_hellmaw.cpp +++ b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_ambassador_hellmaw.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -143,7 +143,7 @@ class boss_ambassador_hellmaw : public CreatureScript if (me->HasAura(SPELL_BANISH)) { - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); return; } diff --git a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_blackheart_the_inciter.cpp b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_blackheart_the_inciter.cpp index 594441ae4fc..f6e84c01dd2 100644 --- a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_blackheart_the_inciter.cpp +++ b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_blackheart_the_inciter.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_grandmaster_vorpil.cpp b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_grandmaster_vorpil.cpp index 04d3a20d945..841565d4276 100644 --- a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_grandmaster_vorpil.cpp +++ b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_grandmaster_vorpil.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_murmur.cpp b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_murmur.cpp index e1371b07567..7238ca2974b 100644 --- a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_murmur.cpp +++ b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/boss_murmur.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/instance_shadow_labyrinth.cpp b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/instance_shadow_labyrinth.cpp index f984272f4d5..96978e92b19 100644 --- a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/instance_shadow_labyrinth.cpp +++ b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/instance_shadow_labyrinth.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -22,9 +22,9 @@ DoorData const doorData[] = { - { GO_REFECTORY_DOOR, DATA_BLACKHEART_THE_INCITER, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_SCREAMING_HALL_DOOR, DATA_GRANDMASTER_VORPIL, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_REFECTORY_DOOR, DATA_BLACKHEART_THE_INCITER, DOOR_TYPE_PASSAGE }, + { GO_SCREAMING_HALL_DOOR, DATA_GRANDMASTER_VORPIL, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_shadow_labyrinth : public InstanceMapScript diff --git a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/shadow_labyrinth.h b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/shadow_labyrinth.h index 7325ba37e9f..765a3443114 100644 --- a/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/shadow_labyrinth.h +++ b/src/server/scripts/Outland/Auchindoun/ShadowLabyrinth/shadow_labyrinth.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/BlackTemple/black_temple.cpp b/src/server/scripts/Outland/BlackTemple/black_temple.cpp index f044fcef5c7..0bbcbc7e9a8 100644 --- a/src/server/scripts/Outland/BlackTemple/black_temple.cpp +++ b/src/server/scripts/Outland/BlackTemple/black_temple.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/BlackTemple/black_temple.h b/src/server/scripts/Outland/BlackTemple/black_temple.h index 3c2aa183279..0856639f4c2 100644 --- a/src/server/scripts/Outland/BlackTemple/black_temple.h +++ b/src/server/scripts/Outland/BlackTemple/black_temple.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/BlackTemple/boss_gurtogg_bloodboil.cpp b/src/server/scripts/Outland/BlackTemple/boss_gurtogg_bloodboil.cpp index 04fc6a58afa..9c16379c9f1 100644 --- a/src/server/scripts/Outland/BlackTemple/boss_gurtogg_bloodboil.cpp +++ b/src/server/scripts/Outland/BlackTemple/boss_gurtogg_bloodboil.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/BlackTemple/boss_illidan.cpp b/src/server/scripts/Outland/BlackTemple/boss_illidan.cpp index f8c031f69e7..7902c585509 100644 --- a/src/server/scripts/Outland/BlackTemple/boss_illidan.cpp +++ b/src/server/scripts/Outland/BlackTemple/boss_illidan.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -1181,7 +1181,7 @@ public: void EnterCombat(Unit* /*who*/) override { } void MoveInLineOfSight(Unit* /*who*/) override { } - void EnterEvadeMode() override { } + void EnterEvadeMode(EvadeReason /*why*/) override { } void GetIllidanGUID(ObjectGuid guid) { @@ -1439,7 +1439,7 @@ public: } // Do not call reset in Akama's evade mode, as this will stop him from summoning minions after he kills the first bit - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { me->RemoveAllAuras(); me->DeleteThreatList(); @@ -1474,7 +1474,7 @@ public: } for (std::vector<Unit*>::const_iterator itr = eliteList.begin(); itr != eliteList.end(); ++itr) (*itr)->setDeathState(JUST_DIED); - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); } void BeginTalk() @@ -1544,7 +1544,7 @@ public: { if (Creature* illidan = ObjectAccessor::GetCreature(*me, IllidanGUID)) ENSURE_AI(boss_illidan_stormrage::boss_illidan_stormrageAI, illidan->AI())->DeleteFromThreatList(me->GetGUID()); - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); me->SetFlag(UNIT_FIELD_FLAGS, UNIT_FLAG_NON_ATTACKABLE); ++WalkCount; } diff --git a/src/server/scripts/Outland/BlackTemple/boss_mother_shahraz.cpp b/src/server/scripts/Outland/BlackTemple/boss_mother_shahraz.cpp index 1c9db80bbab..aaf72512ae9 100644 --- a/src/server/scripts/Outland/BlackTemple/boss_mother_shahraz.cpp +++ b/src/server/scripts/Outland/BlackTemple/boss_mother_shahraz.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/BlackTemple/boss_reliquary_of_souls.cpp b/src/server/scripts/Outland/BlackTemple/boss_reliquary_of_souls.cpp index b8b101944b3..afc7d3d0fd7 100644 --- a/src/server/scripts/Outland/BlackTemple/boss_reliquary_of_souls.cpp +++ b/src/server/scripts/Outland/BlackTemple/boss_reliquary_of_souls.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/BlackTemple/boss_shade_of_akama.cpp b/src/server/scripts/Outland/BlackTemple/boss_shade_of_akama.cpp index 25ff1bf9536..7e1215488e1 100644 --- a/src/server/scripts/Outland/BlackTemple/boss_shade_of_akama.cpp +++ b/src/server/scripts/Outland/BlackTemple/boss_shade_of_akama.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/BlackTemple/boss_supremus.cpp b/src/server/scripts/Outland/BlackTemple/boss_supremus.cpp index 3f421683bc9..ae4d17bdad4 100644 --- a/src/server/scripts/Outland/BlackTemple/boss_supremus.cpp +++ b/src/server/scripts/Outland/BlackTemple/boss_supremus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/BlackTemple/boss_teron_gorefiend.cpp b/src/server/scripts/Outland/BlackTemple/boss_teron_gorefiend.cpp index f56da23bfe9..72eb99bd7dc 100644 --- a/src/server/scripts/Outland/BlackTemple/boss_teron_gorefiend.cpp +++ b/src/server/scripts/Outland/BlackTemple/boss_teron_gorefiend.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/BlackTemple/boss_warlord_najentus.cpp b/src/server/scripts/Outland/BlackTemple/boss_warlord_najentus.cpp index 0bc6a4f49a4..9b33ea88ca7 100644 --- a/src/server/scripts/Outland/BlackTemple/boss_warlord_najentus.cpp +++ b/src/server/scripts/Outland/BlackTemple/boss_warlord_najentus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/BlackTemple/illidari_council.cpp b/src/server/scripts/Outland/BlackTemple/illidari_council.cpp index b84d2e1f70b..d883a48b630 100644 --- a/src/server/scripts/Outland/BlackTemple/illidari_council.cpp +++ b/src/server/scripts/Outland/BlackTemple/illidari_council.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -408,7 +408,7 @@ struct boss_illidari_councilAI : public ScriptedAI LoadGUIDs(); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { for (uint8 i = 0; i < 4; ++i) { @@ -419,7 +419,7 @@ struct boss_illidari_councilAI : public ScriptedAI return; } } - ScriptedAI::EnterEvadeMode(); + ScriptedAI::EnterEvadeMode(why); } void DamageTaken(Unit* done_by, uint32 &damage) override diff --git a/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp b/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp index a14be544921..86ad7958957 100644 --- a/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp +++ b/src/server/scripts/Outland/BlackTemple/instance_black_temple.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -21,18 +21,18 @@ DoorData const doorData[] = { - { GO_NAJENTUS_GATE, DATA_HIGH_WARLORD_NAJENTUS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_NAJENTUS_GATE, DATA_SUPREMUS, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_SUPREMUS_GATE, DATA_SUPREMUS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_SHADE_OF_AKAMA_DOOR, DATA_SHADE_OF_AKAMA, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_TERON_DOOR_1, DATA_TERON_GOREFIEND, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_TERON_DOOR_2, DATA_TERON_GOREFIEND, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_GURTOGG_DOOR, DATA_GURTOGG_BLOODBOIL, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_TEMPLE_DOOR, DATA_RELIQUARY_OF_SOULS, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_MOTHER_SHAHRAZ_DOOR, DATA_MOTHER_SHAHRAZ, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_COUNCIL_DOOR_1, DATA_ILLIDARI_COUNCIL, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_COUNCIL_DOOR_2, DATA_ILLIDARI_COUNCIL, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_NAJENTUS_GATE, DATA_HIGH_WARLORD_NAJENTUS, DOOR_TYPE_PASSAGE }, + { GO_NAJENTUS_GATE, DATA_SUPREMUS, DOOR_TYPE_ROOM }, + { GO_SUPREMUS_GATE, DATA_SUPREMUS, DOOR_TYPE_PASSAGE }, + { GO_SHADE_OF_AKAMA_DOOR, DATA_SHADE_OF_AKAMA, DOOR_TYPE_ROOM }, + { GO_TERON_DOOR_1, DATA_TERON_GOREFIEND, DOOR_TYPE_ROOM }, + { GO_TERON_DOOR_2, DATA_TERON_GOREFIEND, DOOR_TYPE_ROOM }, + { GO_GURTOGG_DOOR, DATA_GURTOGG_BLOODBOIL, DOOR_TYPE_PASSAGE }, + { GO_TEMPLE_DOOR, DATA_RELIQUARY_OF_SOULS, DOOR_TYPE_PASSAGE }, + { GO_MOTHER_SHAHRAZ_DOOR, DATA_MOTHER_SHAHRAZ, DOOR_TYPE_PASSAGE }, + { GO_COUNCIL_DOOR_1, DATA_ILLIDARI_COUNCIL, DOOR_TYPE_ROOM }, + { GO_COUNCIL_DOOR_2, DATA_ILLIDARI_COUNCIL, DOOR_TYPE_ROOM }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_black_temple : public InstanceMapScript diff --git a/src/server/scripts/Outland/CMakeLists.txt b/src/server/scripts/Outland/CMakeLists.txt index 42621b76941..55b0452fb0b 100644 --- a/src/server/scripts/Outland/CMakeLists.txt +++ b/src/server/scripts/Outland/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_fathomlord_karathress.cpp b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_fathomlord_karathress.cpp index e56d63e85bd..544842b4495 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_fathomlord_karathress.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_fathomlord_karathress.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_hydross_the_unstable.cpp b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_hydross_the_unstable.cpp index 9ec7c88d8fa..f0f5de47cd5 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_hydross_the_unstable.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_hydross_the_unstable.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lady_vashj.cpp b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lady_vashj.cpp index 0292ed65697..e24499c3aee 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lady_vashj.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lady_vashj.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_leotheras_the_blind.cpp b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_leotheras_the_blind.cpp index 253c601e228..8d117f7c3ef 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_leotheras_the_blind.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_leotheras_the_blind.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lurker_below.cpp b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lurker_below.cpp index 7c4dbdeaab1..ee7dca668a9 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lurker_below.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_lurker_below.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_morogrim_tidewalker.cpp b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_morogrim_tidewalker.cpp index a8d65cc096d..4c9001f66a3 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_morogrim_tidewalker.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/boss_morogrim_tidewalker.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/instance_serpent_shrine.cpp b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/instance_serpent_shrine.cpp index d7ba0a34939..c7de8530d82 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/instance_serpent_shrine.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/instance_serpent_shrine.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/serpent_shrine.h b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/serpent_shrine.h index d3d449c7e8c..497f6810c6a 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/serpent_shrine.h +++ b/src/server/scripts/Outland/CoilfangReservoir/SerpentShrine/serpent_shrine.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_hydromancer_thespia.cpp b/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_hydromancer_thespia.cpp index d76bd0db04b..026b9a491f6 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_hydromancer_thespia.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_hydromancer_thespia.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_mekgineer_steamrigger.cpp b/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_mekgineer_steamrigger.cpp index e9cfc07de1f..d29692b5728 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_mekgineer_steamrigger.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_mekgineer_steamrigger.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_warlord_kalithresh.cpp b/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_warlord_kalithresh.cpp index 8974b560e2a..934c046aeff 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_warlord_kalithresh.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SteamVault/boss_warlord_kalithresh.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/CoilfangReservoir/SteamVault/instance_steam_vault.cpp b/src/server/scripts/Outland/CoilfangReservoir/SteamVault/instance_steam_vault.cpp index 4cc522c7523..bc95813e681 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SteamVault/instance_steam_vault.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/SteamVault/instance_steam_vault.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/CoilfangReservoir/SteamVault/steam_vault.h b/src/server/scripts/Outland/CoilfangReservoir/SteamVault/steam_vault.h index d3a74fc661a..8c0359eaaa8 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/SteamVault/steam_vault.h +++ b/src/server/scripts/Outland/CoilfangReservoir/SteamVault/steam_vault.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_mennu_the_betrayer.cpp b/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_mennu_the_betrayer.cpp index 46c2ef22c50..d4b5c4d0805 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_mennu_the_betrayer.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_mennu_the_betrayer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_quagmirran.cpp b/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_quagmirran.cpp index ee35ade3552..0900a0ce131 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_quagmirran.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_quagmirran.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_rokmar_the_crackler.cpp b/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_rokmar_the_crackler.cpp index 0d19ffdc49f..5a9d8b409a9 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_rokmar_the_crackler.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/boss_rokmar_the_crackler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/instance_the_slave_pens.cpp b/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/instance_the_slave_pens.cpp index 03feba69ad3..87a07cd1e5e 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/instance_the_slave_pens.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/instance_the_slave_pens.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/the_slave_pens.h b/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/the_slave_pens.h index 916ba56182c..95e6e44121e 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/the_slave_pens.h +++ b/src/server/scripts/Outland/CoilfangReservoir/TheSlavePens/the_slave_pens.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/boss_hungarfen.cpp b/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/boss_hungarfen.cpp index adefcc041fd..3375372ab45 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/boss_hungarfen.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/boss_hungarfen.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/boss_the_black_stalker.cpp b/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/boss_the_black_stalker.cpp index 47e0769165b..4c8eda2b1a1 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/boss_the_black_stalker.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/boss_the_black_stalker.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/instance_the_underbog.cpp b/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/instance_the_underbog.cpp index b2c76b5b227..acf542d788f 100644 --- a/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/instance_the_underbog.cpp +++ b/src/server/scripts/Outland/CoilfangReservoir/TheUnderbog/instance_the_underbog.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp b/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp index 9a56b2e6e0c..aa519f1a8c9 100644 --- a/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp +++ b/src/server/scripts/Outland/GruulsLair/boss_gruul.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/GruulsLair/boss_high_king_maulgar.cpp b/src/server/scripts/Outland/GruulsLair/boss_high_king_maulgar.cpp index 88dbeff09f5..9868c414698 100644 --- a/src/server/scripts/Outland/GruulsLair/boss_high_king_maulgar.cpp +++ b/src/server/scripts/Outland/GruulsLair/boss_high_king_maulgar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/GruulsLair/gruuls_lair.h b/src/server/scripts/Outland/GruulsLair/gruuls_lair.h index 40ed13ad886..dad419e10d0 100644 --- a/src/server/scripts/Outland/GruulsLair/gruuls_lair.h +++ b/src/server/scripts/Outland/GruulsLair/gruuls_lair.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp b/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp index e97b004df06..67f980cf192 100644 --- a/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp +++ b/src/server/scripts/Outland/GruulsLair/instance_gruuls_lair.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -21,9 +21,9 @@ DoorData const doorData[] = { - { GO_MAULGAR_DOOR, DATA_MAULGAR, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_GRUUL_DOOR, DATA_GRUUL, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_MAULGAR_DOOR, DATA_MAULGAR, DOOR_TYPE_PASSAGE }, + { GO_GRUUL_DOOR, DATA_GRUUL, DOOR_TYPE_ROOM }, + { 0, 0, DOOR_TYPE_ROOM } // END }; MinionData const minionData[] = diff --git a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/blood_furnace.h b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/blood_furnace.h index a44854a3c7b..92c8eb4ca42 100644 --- a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/blood_furnace.h +++ b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/blood_furnace.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_broggok.cpp b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_broggok.cpp index 77fe17e4831..9c277f1350f 100644 --- a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_broggok.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_broggok.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_kelidan_the_breaker.cpp b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_kelidan_the_breaker.cpp index 1ed81f77414..f191a0c3ad7 100644 --- a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_kelidan_the_breaker.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_kelidan_the_breaker.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_the_maker.cpp b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_the_maker.cpp index 454da983642..98f99877329 100644 --- a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_the_maker.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/boss_the_maker.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/instance_blood_furnace.cpp b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/instance_blood_furnace.cpp index 212471002b4..92b74c029ba 100644 --- a/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/instance_blood_furnace.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/BloodFurnace/instance_blood_furnace.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -22,13 +22,13 @@ DoorData const doorData[] = { - { GO_PRISON_DOOR_01, DATA_KELIDAN_THE_BREAKER, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_PRISON_DOOR_02, DATA_THE_MAKER, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_PRISON_DOOR_03, DATA_THE_MAKER, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_PRISON_DOOR_04, DATA_BROGGOK, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_PRISON_DOOR_05, DATA_BROGGOK, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { GO_SUMMON_DOOR, DATA_KELIDAN_THE_BREAKER, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_PRISON_DOOR_01, DATA_KELIDAN_THE_BREAKER, DOOR_TYPE_PASSAGE }, + { GO_PRISON_DOOR_02, DATA_THE_MAKER, DOOR_TYPE_ROOM }, + { GO_PRISON_DOOR_03, DATA_THE_MAKER, DOOR_TYPE_PASSAGE }, + { GO_PRISON_DOOR_04, DATA_BROGGOK, DOOR_TYPE_PASSAGE }, + { GO_PRISON_DOOR_05, DATA_BROGGOK, DOOR_TYPE_ROOM }, + { GO_SUMMON_DOOR, DATA_KELIDAN_THE_BREAKER, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_blood_furnace : public InstanceMapScript diff --git a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_omor_the_unscarred.cpp b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_omor_the_unscarred.cpp index 364403acaa7..435c0807d39 100644 --- a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_omor_the_unscarred.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_omor_the_unscarred.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_vazruden_the_herald.cpp b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_vazruden_the_herald.cpp index 749f5cbf88b..4e20e6b0953 100644 --- a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_vazruden_the_herald.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_vazruden_the_herald.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_watchkeeper_gargolmar.cpp b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_watchkeeper_gargolmar.cpp index 774c5fcc874..41d94b60922 100644 --- a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_watchkeeper_gargolmar.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/boss_watchkeeper_gargolmar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/hellfire_ramparts.h b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/hellfire_ramparts.h index f41b76a1a0b..5624e910b06 100644 --- a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/hellfire_ramparts.h +++ b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/hellfire_ramparts.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/instance_hellfire_ramparts.cpp b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/instance_hellfire_ramparts.cpp index 4d45845c646..a41eba3a777 100644 --- a/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/instance_hellfire_ramparts.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/HellfireRamparts/instance_hellfire_ramparts.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/boss_magtheridon.cpp b/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/boss_magtheridon.cpp index d95026faa93..f18a1022f45 100644 --- a/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/boss_magtheridon.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/boss_magtheridon.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/instance_magtheridons_lair.cpp b/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/instance_magtheridons_lair.cpp index a1bac019e7d..fd591d5f887 100644 --- a/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/instance_magtheridons_lair.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/instance_magtheridons_lair.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/magtheridons_lair.h b/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/magtheridons_lair.h index e4d9f121242..d023d5f3194 100644 --- a/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/magtheridons_lair.h +++ b/src/server/scripts/Outland/HellfireCitadel/MagtheridonsLair/magtheridons_lair.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_nethekurse.cpp b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_nethekurse.cpp index dfc5f5992a6..499550945c6 100644 --- a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_nethekurse.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_nethekurse.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_warbringer_omrogg.cpp b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_warbringer_omrogg.cpp index a950882eddd..83218e8f00f 100644 --- a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_warbringer_omrogg.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_warbringer_omrogg.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_warchief_kargath_bladefist.cpp b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_warchief_kargath_bladefist.cpp index 9f7592a9ee4..4faab709e16 100644 --- a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_warchief_kargath_bladefist.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/boss_warchief_kargath_bladefist.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/instance_shattered_halls.cpp b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/instance_shattered_halls.cpp index 5cfae286f9b..dfe11287f15 100644 --- a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/instance_shattered_halls.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/instance_shattered_halls.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -34,9 +34,9 @@ EndScriptData */ DoorData const doorData[] = { - { GO_GRAND_WARLOCK_CHAMBER_DOOR_1, DATA_NETHEKURSE, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_GRAND_WARLOCK_CHAMBER_DOOR_2, DATA_NETHEKURSE, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } + { GO_GRAND_WARLOCK_CHAMBER_DOOR_1, DATA_NETHEKURSE, DOOR_TYPE_PASSAGE }, + { GO_GRAND_WARLOCK_CHAMBER_DOOR_2, DATA_NETHEKURSE, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } }; class instance_shattered_halls : public InstanceMapScript diff --git a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/shattered_halls.cpp b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/shattered_halls.cpp index f47e191c118..a327a02e9a2 100644 --- a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/shattered_halls.cpp +++ b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/shattered_halls.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/shattered_halls.h b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/shattered_halls.h index 894cc9c40a6..b78bb868e40 100644 --- a/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/shattered_halls.h +++ b/src/server/scripts/Outland/HellfireCitadel/ShatteredHalls/shattered_halls.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp index 48508aa4790..102d567e810 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp +++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_alar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -484,7 +484,7 @@ class npc_ember_of_alar : public CreatureScript DoZoneInCombat(); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { me->setDeathState(JUST_DIED); } diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp index ff9bdf15276..9fd1c5c7388 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp +++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_astromancer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp index 2d99fd9bacf..be27932e6b4 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp +++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_kaelthas.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -144,6 +144,7 @@ enum Spells // Thaladred the Darkener spells SPELL_PSYCHIC_BLOW = 10689, SPELL_SILENCE = 30225, + SPELL_REND = 36965, // Lord Sanguinar spells SPELL_BELLOWING_ROAR = 40636, // Grand Astromancer Capernian spells @@ -881,11 +882,13 @@ class boss_thaladred_the_darkener : public CreatureScript { Gaze_Timer = 100; Silence_Timer = 20000; + Rend_Timer = 4000; PsychicBlow_Timer = 10000; } uint32 Gaze_Timer; uint32 Silence_Timer; + uint32 Rend_Timer; uint32 PsychicBlow_Timer; void Reset() override @@ -939,6 +942,15 @@ class boss_thaladred_the_darkener : public CreatureScript else Silence_Timer -= diff; + //Rend_Timer + if (Rend_Timer <= diff) + { + DoCastVictim(SPELL_REND); + Rend_Timer = 4000; + } + else + Rend_Timer -= diff; + //PsychicBlow_Timer if (PsychicBlow_Timer <= diff) { diff --git a/src/server/scripts/Outland/TempestKeep/Eye/boss_void_reaver.cpp b/src/server/scripts/Outland/TempestKeep/Eye/boss_void_reaver.cpp index 1aa7d5298e5..46388c3a185 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/boss_void_reaver.cpp +++ b/src/server/scripts/Outland/TempestKeep/Eye/boss_void_reaver.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -159,8 +159,6 @@ class boss_void_reaver : public CreatureScript Berserk_Timer -= diff; DoMeleeAttackIfReady(); - - EnterEvadeIfOutOfCombatArea(diff); } }; diff --git a/src/server/scripts/Outland/TempestKeep/Eye/instance_the_eye.cpp b/src/server/scripts/Outland/TempestKeep/Eye/instance_the_eye.cpp index 173e0596bea..a751ed546ff 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/instance_the_eye.cpp +++ b/src/server/scripts/Outland/TempestKeep/Eye/instance_the_eye.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -36,9 +36,9 @@ EndScriptData */ DoorData const doorData[] = { - { GO_ARCANE_DOOR_LEFT, DATA_KAELTHAS, DOOR_TYPE_ROOM, BOUNDARY_SW }, - { GO_ARCANE_DOOR_RIGHT, DATA_KAELTHAS, DOOR_TYPE_ROOM, BOUNDARY_SE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_ARCANE_DOOR_LEFT, DATA_KAELTHAS, DOOR_TYPE_ROOM/*, BOUNDARY_SW */ }, + { GO_ARCANE_DOOR_RIGHT, DATA_KAELTHAS, DOOR_TYPE_ROOM/*, BOUNDARY_SE */ }, + { 0, 0, DOOR_TYPE_ROOM } // END }; ObjectData const gameObjectData[] = diff --git a/src/server/scripts/Outland/TempestKeep/Eye/the_eye.cpp b/src/server/scripts/Outland/TempestKeep/Eye/the_eye.cpp index d97ef766dd7..d9f64e0ef6b 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/the_eye.cpp +++ b/src/server/scripts/Outland/TempestKeep/Eye/the_eye.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/Eye/the_eye.h b/src/server/scripts/Outland/TempestKeep/Eye/the_eye.h index ca60e14e923..3df28dda895 100644 --- a/src/server/scripts/Outland/TempestKeep/Eye/the_eye.h +++ b/src/server/scripts/Outland/TempestKeep/Eye/the_eye.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_gyrokill.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_gyrokill.cpp index ccc8cf110ae..7a18e631cf2 100644 --- a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_gyrokill.cpp +++ b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_gyrokill.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_ironhand.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_ironhand.cpp index 49de90e200d..9b0f154eba0 100644 --- a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_ironhand.cpp +++ b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_gatewatcher_ironhand.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_mechano_lord_capacitus.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_mechano_lord_capacitus.cpp index ec2985b7053..861436ffbb2 100644 --- a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_mechano_lord_capacitus.cpp +++ b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_mechano_lord_capacitus.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp index cca11f2a270..3aa2674aec6 100644 --- a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp +++ b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_nethermancer_sepethrea.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_pathaleon_the_calculator.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_pathaleon_the_calculator.cpp index 6bb73d6d264..03827bcbae2 100644 --- a/src/server/scripts/Outland/TempestKeep/Mechanar/boss_pathaleon_the_calculator.cpp +++ b/src/server/scripts/Outland/TempestKeep/Mechanar/boss_pathaleon_the_calculator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp b/src/server/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp index b2d63315029..c2f93fd3910 100644 --- a/src/server/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp +++ b/src/server/scripts/Outland/TempestKeep/Mechanar/instance_mechanar.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -22,10 +22,10 @@ static DoorData const doorData[] = { - { GO_DOOR_MOARG_1, DATA_GATEWATCHER_IRON_HAND, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_DOOR_MOARG_2, DATA_GATEWATCHER_GYROKILL, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_DOOR_NETHERMANCER, DATA_NETHERMANCER_SEPRETHREA, DOOR_TYPE_ROOM, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } + { GO_DOOR_MOARG_1, DATA_GATEWATCHER_IRON_HAND, DOOR_TYPE_PASSAGE }, + { GO_DOOR_MOARG_2, DATA_GATEWATCHER_GYROKILL, DOOR_TYPE_PASSAGE }, + { GO_DOOR_NETHERMANCER, DATA_NETHERMANCER_SEPRETHREA, DOOR_TYPE_ROOM }, + { 0, 0, DOOR_TYPE_ROOM } }; class instance_mechanar : public InstanceMapScript diff --git a/src/server/scripts/Outland/TempestKeep/Mechanar/mechanar.h b/src/server/scripts/Outland/TempestKeep/Mechanar/mechanar.h index 6984d16af4c..b48fdbd9df4 100644 --- a/src/server/scripts/Outland/TempestKeep/Mechanar/mechanar.h +++ b/src/server/scripts/Outland/TempestKeep/Mechanar/mechanar.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.cpp index 9ffc151b3b9..cab5b9efbc3 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.cpp +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h b/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h index 8fb286855fa..720f845fe4a 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/arcatraz.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp index 6eb386f8f45..354003def5d 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_dalliah_the_doomsayer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_harbinger_skyriss.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_harbinger_skyriss.cpp index 03e2154792b..f203780dbc7 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_harbinger_skyriss.cpp +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_harbinger_skyriss.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp index a8025198baf..fd33b5c1da4 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_wrath_scryer_soccothrates.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp index f4fc51a7efc..cb0126e96e4 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/boss_zereketh_the_unbound.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp b/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp index 515ede7ea60..148420ad1a0 100644 --- a/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp +++ b/src/server/scripts/Outland/TempestKeep/arcatraz/instance_arcatraz.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -21,9 +21,9 @@ DoorData const doorData[] = { - { GO_CONTAINMENT_CORE_SECURITY_FIELD_ALPHA, DATA_SOCCOTHRATES, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { GO_CONTAINMENT_CORE_SECURITY_FIELD_BETA, DATA_DALLIAH, DOOR_TYPE_PASSAGE, BOUNDARY_NONE }, - { 0, 0, DOOR_TYPE_ROOM, BOUNDARY_NONE } // END + { GO_CONTAINMENT_CORE_SECURITY_FIELD_ALPHA, DATA_SOCCOTHRATES, DOOR_TYPE_PASSAGE }, + { GO_CONTAINMENT_CORE_SECURITY_FIELD_BETA, DATA_DALLIAH, DOOR_TYPE_PASSAGE }, + { 0, 0, DOOR_TYPE_ROOM } // END }; class instance_arcatraz : public InstanceMapScript diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp index e8b9c5cc1ce..d57a780e1f4 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_commander_sarannis.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp index 4377067e56b..09967c3b353 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_high_botanist_freywinn.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp index 1be87c9fb14..5070d9f1de9 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_laj.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_thorngrin_the_tender.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_thorngrin_the_tender.cpp index 8ed1166fbba..163ef657ebf 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/boss_thorngrin_the_tender.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_thorngrin_the_tender.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp b/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp index a918ff5cd08..856649c6c5e 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/boss_warp_splinter.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/TempestKeep/botanica/instance_the_botanica.cpp b/src/server/scripts/Outland/TempestKeep/botanica/instance_the_botanica.cpp index 2ee65c890cb..60864c012c9 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/instance_the_botanica.cpp +++ b/src/server/scripts/Outland/TempestKeep/botanica/instance_the_botanica.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h b/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h index efa27b8c662..71172eaf62f 100644 --- a/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h +++ b/src/server/scripts/Outland/TempestKeep/botanica/the_botanica.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/boss_doomlord_kazzak.cpp b/src/server/scripts/Outland/boss_doomlord_kazzak.cpp index cbef6d217c5..d4f0637c0d1 100644 --- a/src/server/scripts/Outland/boss_doomlord_kazzak.cpp +++ b/src/server/scripts/Outland/boss_doomlord_kazzak.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/boss_doomwalker.cpp b/src/server/scripts/Outland/boss_doomwalker.cpp index e6835c8865c..56313fd58b4 100644 --- a/src/server/scripts/Outland/boss_doomwalker.cpp +++ b/src/server/scripts/Outland/boss_doomwalker.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/zone_blades_edge_mountains.cpp b/src/server/scripts/Outland/zone_blades_edge_mountains.cpp index aaf006f6c5f..30bf085be43 100644 --- a/src/server/scripts/Outland/zone_blades_edge_mountains.cpp +++ b/src/server/scripts/Outland/zone_blades_edge_mountains.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/zone_hellfire_peninsula.cpp b/src/server/scripts/Outland/zone_hellfire_peninsula.cpp index 0a9f8640ad2..404cdc7ceb2 100644 --- a/src/server/scripts/Outland/zone_hellfire_peninsula.cpp +++ b/src/server/scripts/Outland/zone_hellfire_peninsula.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -168,9 +168,9 @@ public: } // Override Evade Mode event, recast buff that was removed by standard handler - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - npc_escortAI::EnterEvadeMode(); + npc_escortAI::EnterEvadeMode(why); DoCast(me, SPELL_ANCESTRAL_WOLF_BUFF, true); } diff --git a/src/server/scripts/Outland/zone_nagrand.cpp b/src/server/scripts/Outland/zone_nagrand.cpp index 81a31693521..40cc7bafa5a 100644 --- a/src/server/scripts/Outland/zone_nagrand.cpp +++ b/src/server/scripts/Outland/zone_nagrand.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/zone_netherstorm.cpp b/src/server/scripts/Outland/zone_netherstorm.cpp index 8266e80e7bb..d35dedb5d27 100644 --- a/src/server/scripts/Outland/zone_netherstorm.cpp +++ b/src/server/scripts/Outland/zone_netherstorm.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/zone_shadowmoon_valley.cpp b/src/server/scripts/Outland/zone_shadowmoon_valley.cpp index 318214978ae..7ea87a3c0c4 100644 --- a/src/server/scripts/Outland/zone_shadowmoon_valley.cpp +++ b/src/server/scripts/Outland/zone_shadowmoon_valley.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -560,6 +560,10 @@ public: me->DealDamage(me, me->GetHealth(), NULL, DIRECT_DAMAGE, SPELL_SCHOOL_MASK_NORMAL, NULL, false); } else PoisonTimer -= diff; } + if (!UpdateVictim()) + return; + + DoMeleeAttackIfReady(); } }; }; diff --git a/src/server/scripts/Outland/zone_shattrath_city.cpp b/src/server/scripts/Outland/zone_shattrath_city.cpp index fa3ef9e863e..c734d000077 100644 --- a/src/server/scripts/Outland/zone_shattrath_city.cpp +++ b/src/server/scripts/Outland/zone_shattrath_city.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/zone_terokkar_forest.cpp b/src/server/scripts/Outland/zone_terokkar_forest.cpp index d948862431f..06a8af947b7 100644 --- a/src/server/scripts/Outland/zone_terokkar_forest.cpp +++ b/src/server/scripts/Outland/zone_terokkar_forest.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/Outland/zone_zangarmarsh.cpp b/src/server/scripts/Outland/zone_zangarmarsh.cpp index 0dc12c8f4c4..6f38cce0e5b 100644 --- a/src/server/scripts/Outland/zone_zangarmarsh.cpp +++ b/src/server/scripts/Outland/zone_zangarmarsh.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -48,8 +48,6 @@ EndContentData */ enum AshyenAndKeleth { - GOSSIP_REWARD_BLESS = 0, - NPC_ASHYEN = 17900, NPC_KELETH = 17901, @@ -117,7 +115,6 @@ public: if (spell) { creature->CastSpell(player, spell, true); - creature->AI()->Talk(GOSSIP_REWARD_BLESS); } } @@ -145,7 +142,6 @@ public: if (spell) { creature->CastSpell(player, spell, true); - creature->AI()->Talk(GOSSIP_REWARD_BLESS); } } player->CLOSE_GOSSIP_MENU(); diff --git a/src/server/scripts/Pet/CMakeLists.txt b/src/server/scripts/Pet/CMakeLists.txt index a0d165f5afa..9ca268a9a3f 100644 --- a/src/server/scripts/Pet/CMakeLists.txt +++ b/src/server/scripts/Pet/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/scripts/Pet/pet_dk.cpp b/src/server/scripts/Pet/pet_dk.cpp index 95364c5ae08..80b3a00774b 100644 --- a/src/server/scripts/Pet/pet_dk.cpp +++ b/src/server/scripts/Pet/pet_dk.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Pet/pet_generic.cpp b/src/server/scripts/Pet/pet_generic.cpp index f11039c60d0..35455bc474b 100644 --- a/src/server/scripts/Pet/pet_generic.cpp +++ b/src/server/scripts/Pet/pet_generic.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Pet/pet_hunter.cpp b/src/server/scripts/Pet/pet_hunter.cpp index 1904d7ce184..321e44c8603 100644 --- a/src/server/scripts/Pet/pet_hunter.cpp +++ b/src/server/scripts/Pet/pet_hunter.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Pet/pet_mage.cpp b/src/server/scripts/Pet/pet_mage.cpp index 14d2687c298..37584bda2ae 100644 --- a/src/server/scripts/Pet/pet_mage.cpp +++ b/src/server/scripts/Pet/pet_mage.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -167,7 +167,7 @@ class npc_pet_mage_mirror_image : public CreatureScript events.ScheduleEvent(SPELL_MAGE_FIRE_BLAST, TIMER_MIRROR_IMAGE_FIRE_BLAST); } else - EnterEvadeMode(); + EnterEvadeMode(EVADE_REASON_OTHER); } void Reset() override @@ -178,6 +178,9 @@ class npc_pet_mage_mirror_image : public CreatureScript void UpdateAI(uint32 diff) override { Unit* owner = me->GetCharmerOrOwner(); + if (!owner) + return; + Unit* target = owner->getAttackerForHelper(); events.Update(diff); @@ -192,9 +195,6 @@ class npc_pet_mage_mirror_image : public CreatureScript if (me->HasUnitState(UNIT_STATE_CASTING)) return; - if (!owner) - return; - // assign target if image doesnt have any or the target is not actual if (!target || me->GetVictim() != target) { @@ -233,7 +233,7 @@ class npc_pet_mage_mirror_image : public CreatureScript } // Do not reload Creature templates on evade mode enter - prevent visual lost - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { if (me->IsInEvadeMode() || !me->IsAlive()) return; diff --git a/src/server/scripts/Pet/pet_priest.cpp b/src/server/scripts/Pet/pet_priest.cpp index a4e780349e6..a3110ce8f8b 100644 --- a/src/server/scripts/Pet/pet_priest.cpp +++ b/src/server/scripts/Pet/pet_priest.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -44,7 +44,7 @@ class npc_pet_pri_lightwell : public CreatureScript DoCast(me, SPELL_PRIEST_LIGHTWELL_CHARGES, false); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason /*why*/) override { if (!me->IsAlive()) return; diff --git a/src/server/scripts/Pet/pet_shaman.cpp b/src/server/scripts/Pet/pet_shaman.cpp index e80957f1aa3..1feec353c24 100644 --- a/src/server/scripts/Pet/pet_shaman.cpp +++ b/src/server/scripts/Pet/pet_shaman.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Spells/CMakeLists.txt b/src/server/scripts/Spells/CMakeLists.txt index b434c6b76cb..7434d98cf49 100644 --- a/src/server/scripts/Spells/CMakeLists.txt +++ b/src/server/scripts/Spells/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/scripts/Spells/spell_dk.cpp b/src/server/scripts/Spells/spell_dk.cpp index 88271dc7139..3cea620559a 100644 --- a/src/server/scripts/Spells/spell_dk.cpp +++ b/src/server/scripts/Spells/spell_dk.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -22,6 +22,7 @@ */ #include "Player.h" +#include "UnitAI.h" #include "ScriptMgr.h" #include "SpellScript.h" #include "SpellAuraEffects.h" @@ -63,7 +64,10 @@ enum DeathKnightSpells SPELL_DK_UNHOLY_PRESENCE = 48265, SPELL_DK_UNHOLY_PRESENCE_TRIGGERED = 49772, SPELL_DK_WILL_OF_THE_NECROPOLIS_TALENT_R1 = 49189, - SPELL_DK_WILL_OF_THE_NECROPOLIS_AURA_R1 = 52284 + SPELL_DK_WILL_OF_THE_NECROPOLIS_AURA_R1 = 52284, + SPELL_DK_RAISE_ALLY_INITIAL = 61999, + SPELL_DK_RAISE_ALLY = 46619, + SPELL_DK_GHOUL_THRASH = 47480 }; enum DeathKnightSpellIcons @@ -1699,6 +1703,303 @@ public: } }; +enum RaiseAllyMisc +{ + TEXT_RISE_ALLY = 33055, + + SPELL_DK_RISEN_GHOUL_SELF_STUN = 47466, + SPELL_DK_RISEN_GHOUL_SPAWN__IN = 47448, + SPELL_DK_SUMMON_HEAL = 36492, + SPELL_DK_DEATH_KNIGHT_RUNE_WEAPON_SCALING_02 = 51906, + SPELL_DK_DEATH_KNIGHT_PET_SCALING_01 = 54566, + SPELL_DK_DEATH_KNIGHT_PET_SCALING_03 = 61697, + SPELL_DK_MIRROR_NAME = 62224, + SPELL_DK_MIRROR_NAME_TRIGGERED = 62214, + SPELL_DK_PET_SCALING___MASTER_SPELL_03___INTELLECT_SPIRIT_RESILIENCE = 67557, + SPELL_DK_PET_SCALING___MASTER_SPELL_06___SPELL_HIT_EXPERTISE_SPELL_PENETRATION = 67561, + + SPELL_GHOUL_FRENZY = 62218, + + NPC_RISEN_ALLY = 30230 +}; + +// 61999 - Raise Ally Initial +class spell_dk_raise_ally_initial : public SpellScriptLoader +{ +public: + spell_dk_raise_ally_initial() : SpellScriptLoader("spell_dk_raise_ally_initial") { } + + class spell_dk_raise_ally_initial_SpellScript : public SpellScript + { + PrepareSpellScript(spell_dk_raise_ally_initial_SpellScript); + + bool Validate(SpellInfo const* /*spellInfo*/) override + { + if (!sSpellMgr->GetSpellInfo(SPELL_DK_RAISE_ALLY_INITIAL)) + return false; + return true; + } + + SpellCastResult CheckCast() + { + // Raise Ally cannot be casted on alive players + Unit* target = GetExplTargetUnit(); + if (!target) + return SPELL_FAILED_NO_VALID_TARGETS; + if (target->IsAlive()) + return SPELL_FAILED_TARGET_NOT_DEAD; + if (Player* playerCaster = GetCaster()->ToPlayer()) + if (playerCaster->InArena()) + return SPELL_FAILED_NOT_IN_ARENA; + if (target->IsGhouled()) + return SPELL_FAILED_CANT_DO_THAT_RIGHT_NOW; + + return SPELL_CAST_OK; + } + + void HandleDummy(SpellEffIndex /*effIndex*/) + { + Player* caster = GetCaster()->ToPlayer(); + Player* target = GetHitPlayer(); + if (caster && target) + caster->SendGhoulResurrectRequest(target); + } + + void Register() override + { + OnCheckCast += SpellCheckCastFn(spell_dk_raise_ally_initial_SpellScript::CheckCast); + OnEffectHitTarget += SpellEffectFn(spell_dk_raise_ally_initial_SpellScript::HandleDummy, EFFECT_0, SPELL_EFFECT_DUMMY); + } + }; + + SpellScript* GetSpellScript() const override + { + return new spell_dk_raise_ally_initial_SpellScript(); + } +}; + +class player_ghoulAI : public PlayerAI +{ + public: + player_ghoulAI(Player* player, ObjectGuid ghoulGUID) : PlayerAI(player), _ghoulGUID(ghoulGUID) { } + + void UpdateAI(uint32 /*diff*/) override + { + if (Creature* ghoul = ObjectAccessor::GetCreature(*me, _ghoulGUID)) + { + if (!ghoul->IsAlive()) + me->RemoveAura(SPELL_DK_RAISE_ALLY); + } + else + me->RemoveAura(SPELL_DK_RAISE_ALLY); + } + + private: + ObjectGuid _ghoulGUID; +}; + +// 46619 - Raise Ally +class spell_dk_raise_ally : public SpellScriptLoader +{ +public: + spell_dk_raise_ally() : SpellScriptLoader("spell_dk_raise_ally") { } + + class spell_dk_raise_ally_SpellScript : public SpellScript + { + PrepareSpellScript(spell_dk_raise_ally_SpellScript); + + bool Validate(SpellInfo const* /*spellInfo*/) override + { + if (!sSpellMgr->GetSpellInfo(SPELL_DK_RAISE_ALLY)) + return false; + return true; + } + + void SendText() + { + Player* caster = GetCaster()->ToPlayer(); + Unit* original = GetOriginalCaster(); + if (caster && original) + original->Whisper(TEXT_RISE_ALLY, caster, true); + } + + void HandleSummon(SpellEffIndex effIndex) + { + PreventHitDefaultEffect(effIndex); + + Unit* caster = GetCaster(); + Unit* originalCaster = GetOriginalCaster(); + if (!originalCaster) + return; + + uint32 entry = uint32(GetSpellInfo()->Effects[effIndex].MiscValue); + + //! HACK - StatSystem needs further develop to enable update on Puppet stats + // Using same summon properties as Raise Dead 46585 (Guardian) - EffectMiscValueB = 829 + SummonPropertiesEntry const* properties = sSummonPropertiesStore.LookupEntry(829); + + uint32 duration = uint32(GetSpellInfo()->GetDuration()); + Position pos = caster->GetPosition(); + + TempSummon* summon = originalCaster->GetMap()->SummonCreature(entry, pos, properties, duration, originalCaster, GetSpellInfo()->Id); + if (!summon) + return; + + //! Leaving this here as it's necessary if statsystem problem is solved + /* + Default SUMMON_CATEGORY_PUPPET behaviour sets possesor as originalCaster, + in this case we need caster as possesor and originalCaster as owner + */ + //summon->RemoveCharmedBy(NULL); + + summon->SetCharmedBy(caster, CHARM_TYPE_POSSESS); + + summon->CastSpell(summon, SPELL_DK_RISEN_GHOUL_SELF_STUN, true); + summon->CastSpell(summon, SPELL_DK_RISEN_GHOUL_SPAWN__IN, true); + summon->CastSpell(summon, SPELL_DK_SUMMON_HEAL, true); + summon->CastSpell(caster, SPELL_DK_MIRROR_NAME, true); + caster->CastSpell(summon, SPELL_DK_MIRROR_NAME_TRIGGERED, true); + summon->CastSpell(summon, SPELL_DK_DEATH_KNIGHT_RUNE_WEAPON_SCALING_02, true); + summon->CastSpell(summon, SPELL_DK_DEATH_KNIGHT_PET_SCALING_01, true); + summon->CastSpell(summon, SPELL_DK_DEATH_KNIGHT_PET_SCALING_03, true); + summon->CastSpell(summon, SPELL_DK_PET_SCALING___MASTER_SPELL_03___INTELLECT_SPIRIT_RESILIENCE, true); + summon->CastSpell(summon, SPELL_DK_PET_SCALING___MASTER_SPELL_06___SPELL_HIT_EXPERTISE_SPELL_PENETRATION, true); + + // SMSG_POWER_UPDATE is sent + summon->SetMaxPower(POWER_ENERGY, 100); + + if (Player* player = GetCaster()->ToPlayer()) + player->SetGhoulResurrectGhoulGUID(summon->GetGUID()); + } + + void Register() override + { + AfterHit += SpellHitFn(spell_dk_raise_ally_SpellScript::SendText); + OnEffectHit += SpellEffectFn(spell_dk_raise_ally_SpellScript::HandleSummon, EFFECT_0, SPELL_EFFECT_SUMMON); + } + }; + + SpellScript* GetSpellScript() const override + { + return new spell_dk_raise_ally_SpellScript(); + } + + class spell_dk_raise_ally_AuraScript : public AuraScript + { + PrepareAuraScript(spell_dk_raise_ally_AuraScript); + + public: + spell_dk_raise_ally_AuraScript() + { + oldAI = nullptr; + oldAIState = false; + } + + private: + bool Validate(SpellInfo const* /*spellInfo*/) override + { + if (!sSpellMgr->GetSpellInfo(SPELL_DK_RAISE_ALLY)) + return false; + return true; + } + + void OnApply(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/) + { + Player* player = GetTarget()->ToPlayer(); + if (!player || player->GetGhoulResurrectGhoulGUID().IsEmpty()) + return; + + oldAI = player->GetAI(); + oldAIState = player->IsAIEnabled; + player->SetAI(new player_ghoulAI(player, player->GetGhoulResurrectGhoulGUID())); + player->IsAIEnabled = true; + } + + void OnRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/) + { + Player* player = GetTarget()->ToPlayer(); + if (!player) + return; + + player->IsAIEnabled = oldAIState; + UnitAI* thisAI = player->GetAI(); + player->SetAI(oldAI); + delete thisAI; + + // Dismiss ghoul if necessary + if (Creature* ghoul = ObjectAccessor::GetCreature(*player, player->GetGhoulResurrectGhoulGUID())) + { + ghoul->RemoveCharmedBy(nullptr); + ghoul->DespawnOrUnsummon(1000); + } + + player->SetGhoulResurrectGhoulGUID(ObjectGuid::Empty); + player->RemoveAura(SPELL_GHOUL_FRENZY); + } + + void Register() override + { + AfterEffectApply += AuraEffectApplyFn(spell_dk_raise_ally_AuraScript::OnApply, EFFECT_1, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL); + AfterEffectRemove += AuraEffectRemoveFn(spell_dk_raise_ally_AuraScript::OnRemove, EFFECT_1, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL); + } + + UnitAI* oldAI; + bool oldAIState; + }; + + AuraScript* GetAuraScript() const override + { + return new spell_dk_raise_ally_AuraScript(); + } +}; + +// 47480 - Thrash +class spell_dk_ghoul_thrash : public SpellScriptLoader +{ +public: + spell_dk_ghoul_thrash() : SpellScriptLoader("spell_dk_ghoul_thrash") { } + + class spell_dk_ghoul_thrash_SpellScript : public SpellScript + { + PrepareSpellScript(spell_dk_ghoul_thrash_SpellScript); + + bool Validate(SpellInfo const* /*spellInfo*/) override + { + if (!sSpellMgr->GetSpellInfo(SPELL_DK_GHOUL_THRASH)) + return false; + return true; + } + + void CalcDamage() + { + if (Aura* aur = GetCaster()->GetAura(SPELL_GHOUL_FRENZY)) + { + int32 damage = GetHitDamage(); + damage += int32(GetCaster()->GetTotalAttackPowerValue(BASE_ATTACK) * 0.05f * aur->GetStackAmount()); + aur->Remove(); + SetHitDamage(damage); + } + + /* + Also remove aura from charmer + SPELL_GHOUL_FRENZY (62218) - Targets (1, 27) (TARGET_UNIT_CASTER, TARGET_UNIT_MASTER) + */ + if (Unit* charmer = GetCaster()->GetCharmer()) + charmer->RemoveAura(SPELL_GHOUL_FRENZY); + } + + void Register() override + { + OnHit += SpellHitFn(spell_dk_ghoul_thrash_SpellScript::CalcDamage); + } + }; + + SpellScript* GetSpellScript() const override + { + return new spell_dk_ghoul_thrash_SpellScript(); + } +}; + void AddSC_deathknight_spell_scripts() { new spell_dk_anti_magic_shell_raid(); @@ -1729,4 +2030,7 @@ void AddSC_deathknight_spell_scripts() new spell_dk_vampiric_blood(); new spell_dk_will_of_the_necropolis(); new spell_dk_death_grip_initial(); + new spell_dk_raise_ally_initial(); + new spell_dk_raise_ally(); + new spell_dk_ghoul_thrash(); } diff --git a/src/server/scripts/Spells/spell_druid.cpp b/src/server/scripts/Spells/spell_druid.cpp index d6e5dc1a2ab..c088ae07e66 100644 --- a/src/server/scripts/Spells/spell_druid.cpp +++ b/src/server/scripts/Spells/spell_druid.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -29,11 +29,17 @@ enum DruidSpells { + SPELL_DRUID_BEAR_FORM_PASSIVE = 1178, + SPELL_DRUID_DIRE_BEAR_FORM_PASSIVE = 9635, + SPELL_DRUID_ENRAGE = 5229, SPELL_DRUID_ENRAGE_MOD_DAMAGE = 51185, + SPELL_DRUID_ENRAGED_DEFENSE = 70725, SPELL_DRUID_GLYPH_OF_TYPHOON = 62135, SPELL_DRUID_IDOL_OF_FERAL_SHADOWS = 34241, SPELL_DRUID_IDOL_OF_WORSHIP = 60774, SPELL_DRUID_INCREASED_MOONFIRE_DURATION = 38414, + SPELL_DRUID_ITEM_T8_BALANCE_RELIC = 64950, + SPELL_DRUID_ITEM_T10_FERAL_4P_BONUS = 70726, SPELL_DRUID_KING_OF_THE_JUNGLE = 48492, SPELL_DRUID_LIFEBLOOM_ENERGIZE = 64372, SPELL_DRUID_LIFEBLOOM_FINAL_HEAL = 33778, @@ -42,8 +48,58 @@ enum DruidSpells SPELL_DRUID_NATURES_SPLENDOR = 57865, SPELL_DRUID_SURVIVAL_INSTINCTS = 50322, SPELL_DRUID_SAVAGE_ROAR = 62071, - SPELL_DRUID_TIGER_S_FURY_ENERGIZE = 51178, - SPELL_DRUID_ITEM_T8_BALANCE_RELIC = 64950, + SPELL_DRUID_TIGER_S_FURY_ENERGIZE = 51178 +}; + +// 1178 - Bear Form (Passive) +// 9635 - Dire Bear Form (Passive) +class spell_dru_bear_form_passive : public SpellScriptLoader +{ + public: + spell_dru_bear_form_passive() : SpellScriptLoader("spell_dru_bear_form_passive") { } + + class spell_dru_bear_form_passive_AuraScript : public AuraScript + { + PrepareAuraScript(spell_dru_bear_form_passive_AuraScript); + + bool Validate(SpellInfo const* /*spellInfo*/) override + { + if (!sSpellMgr->GetSpellInfo(SPELL_DRUID_ENRAGE) + || !sSpellMgr->GetSpellInfo(SPELL_DRUID_ITEM_T10_FERAL_4P_BONUS)) + return false; + return true; + } + + void CalculateAmount(AuraEffect const* /*aurEff*/, int32& amount, bool& /*canBeRecalculated*/) + { + if (!GetUnitOwner()->HasAura(SPELL_DRUID_ENRAGE) || GetUnitOwner()->HasAura(SPELL_DRUID_ITEM_T10_FERAL_4P_BONUS)) + return; + + int32 mod = 0; + switch (GetId()) + { + case SPELL_DRUID_BEAR_FORM_PASSIVE: + mod = -27; + break; + case SPELL_DRUID_DIRE_BEAR_FORM_PASSIVE: + mod = -16; + break; + default: + return; + } + amount += mod; + } + + void Register() override + { + DoEffectCalcAmount += AuraEffectCalcAmountFn(spell_dru_bear_form_passive_AuraScript::CalculateAmount, EFFECT_0, SPELL_AURA_MOD_BASE_RESISTANCE_PCT); + } + }; + + AuraScript* GetAuraScript() const override + { + return new spell_dru_bear_form_passive_AuraScript(); + } }; // -1850 - Dash @@ -81,33 +137,63 @@ class spell_dru_enrage : public SpellScriptLoader public: spell_dru_enrage() : SpellScriptLoader("spell_dru_enrage") { } - class spell_dru_enrage_SpellScript : public SpellScript + class spell_dru_enrage_AuraScript : public AuraScript { - PrepareSpellScript(spell_dru_enrage_SpellScript); + PrepareAuraScript(spell_dru_enrage_AuraScript); bool Validate(SpellInfo const* /*spellInfo*/) override { if (!sSpellMgr->GetSpellInfo(SPELL_DRUID_KING_OF_THE_JUNGLE) - || !sSpellMgr->GetSpellInfo(SPELL_DRUID_ENRAGE_MOD_DAMAGE)) + || !sSpellMgr->GetSpellInfo(SPELL_DRUID_ENRAGE_MOD_DAMAGE) + || !sSpellMgr->GetSpellInfo(SPELL_DRUID_ENRAGED_DEFENSE) + || !sSpellMgr->GetSpellInfo(SPELL_DRUID_ITEM_T10_FERAL_4P_BONUS)) return false; return true; } - void OnHit() + void RecalculateBaseArmor() { - if (AuraEffect const* aurEff = GetHitUnit()->GetAuraEffectOfRankedSpell(SPELL_DRUID_KING_OF_THE_JUNGLE, EFFECT_0)) - GetHitUnit()->CastCustomSpell(SPELL_DRUID_ENRAGE_MOD_DAMAGE, SPELLVALUE_BASE_POINT0, aurEff->GetAmount(), GetHitUnit(), true); + Unit::AuraEffectList const& auras = GetTarget()->GetAuraEffectsByType(SPELL_AURA_MOD_BASE_RESISTANCE_PCT); + for (Unit::AuraEffectList::const_iterator i = auras.begin(); i != auras.end(); ++i) + { + SpellInfo const* spellInfo = (*i)->GetSpellInfo(); + // Dire- / Bear Form (Passive) + if (spellInfo->SpellFamilyName == SPELLFAMILY_DRUID && spellInfo->SpellFamilyFlags.HasFlag(0x0, 0x0, 0x2)) + (*i)->RecalculateAmount(); + } + } + + void HandleApply(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/) + { + Unit* target = GetTarget(); + if (AuraEffect const* aurEff = target->GetAuraEffectOfRankedSpell(SPELL_DRUID_KING_OF_THE_JUNGLE, EFFECT_0)) + target->CastCustomSpell(SPELL_DRUID_ENRAGE_MOD_DAMAGE, SPELLVALUE_BASE_POINT0, aurEff->GetAmount(), target, true); + + // Item - Druid T10 Feral 4P Bonus + if (target->HasAura(SPELL_DRUID_ITEM_T10_FERAL_4P_BONUS)) + target->CastSpell(target, SPELL_DRUID_ENRAGED_DEFENSE, true); + + RecalculateBaseArmor(); + } + + void HandleRemove(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/) + { + GetTarget()->RemoveAurasDueToSpell(SPELL_DRUID_ENRAGE_MOD_DAMAGE); + GetTarget()->RemoveAurasDueToSpell(SPELL_DRUID_ENRAGED_DEFENSE); + + RecalculateBaseArmor(); } void Register() override { - AfterHit += SpellHitFn(spell_dru_enrage_SpellScript::OnHit); + AfterEffectApply += AuraEffectApplyFn(spell_dru_enrage_AuraScript::HandleApply, EFFECT_0, SPELL_AURA_PERIODIC_ENERGIZE, AURA_EFFECT_HANDLE_REAL); + AfterEffectRemove += AuraEffectRemoveFn(spell_dru_enrage_AuraScript::HandleRemove, EFFECT_0, SPELL_AURA_PERIODIC_ENERGIZE, AURA_EFFECT_HANDLE_REAL); } }; - SpellScript* GetSpellScript() const override + AuraScript* GetAuraScript() const override { - return new spell_dru_enrage_SpellScript(); + return new spell_dru_enrage_AuraScript(); } }; @@ -905,6 +991,37 @@ class spell_dru_swift_flight_passive : public SpellScriptLoader } }; +// -33943 - Flight Form +class spell_dru_flight_form : public SpellScriptLoader +{ + public: + spell_dru_flight_form() : SpellScriptLoader("spell_dru_flight_form") { } + + class spell_dru_flight_form_SpellScript : public SpellScript + { + PrepareSpellScript(spell_dru_flight_form_SpellScript); + + SpellCastResult CheckCast() + { + Unit* caster = GetCaster(); + if (caster->IsInDisallowedMountForm()) + return SPELL_FAILED_NOT_SHAPESHIFT; + + return SPELL_CAST_OK; + } + + void Register() override + { + OnCheckCast += SpellCheckCastFn(spell_dru_flight_form_SpellScript::CheckCast); + } + }; + + SpellScript* GetSpellScript() const override + { + return new spell_dru_flight_form_SpellScript(); + } +}; + // -5217 - Tiger's Fury class spell_dru_tiger_s_fury : public SpellScriptLoader { @@ -1089,6 +1206,7 @@ class spell_dru_wild_growth : public SpellScriptLoader void AddSC_druid_spell_scripts() { + new spell_dru_bear_form_passive(); new spell_dru_dash(); new spell_dru_enrage(); new spell_dru_glyph_of_starfire(); @@ -1109,6 +1227,7 @@ void AddSC_druid_spell_scripts() new spell_dru_starfall_dummy(); new spell_dru_survival_instincts(); new spell_dru_swift_flight_passive(); + new spell_dru_flight_form(); new spell_dru_tiger_s_fury(); new spell_dru_typhoon(); new spell_dru_t10_restoration_4p_bonus(); diff --git a/src/server/scripts/Spells/spell_generic.cpp b/src/server/scripts/Spells/spell_generic.cpp index ca8c9a9ef93..abde43ef952 100644 --- a/src/server/scripts/Spells/spell_generic.cpp +++ b/src/server/scripts/Spells/spell_generic.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -1930,10 +1930,7 @@ class spell_gen_mount : public SpellScriptLoader if (map == 530 || (map == 571 && target->HasSpell(SPELL_COLD_WEATHER_FLYING))) canFly = true; - float x, y, z; - target->GetPosition(x, y, z); - uint32 areaFlag = target->GetBaseMap()->GetAreaFlag(x, y, z); - AreaTableEntry const* area = sAreaStore.LookupEntry(areaFlag); + AreaTableEntry const* area = sAreaTableStore.LookupEntry(target->GetAreaId()); if (!area || (canFly && (area->flags & AREA_FLAG_NO_FLY_ZONE))) canFly = false; @@ -4120,6 +4117,44 @@ public: } }; +enum LandmineKnockbackAchievement +{ + SPELL_LANDMINE_KNOCKBACK_ACHIEVEMENT = 57064 +}; + +class spell_gen_landmine_knockback_achievement : public SpellScriptLoader +{ +public: + spell_gen_landmine_knockback_achievement() : SpellScriptLoader("spell_gen_landmine_knockback_achievement") { } + + class spell_gen_landmine_knockback_achievement_SpellScript : public SpellScript + { + PrepareSpellScript(spell_gen_landmine_knockback_achievement_SpellScript); + + void HandleScript(SpellEffIndex /*effIndex*/) + { + if (Player* target = GetHitPlayer()) + { + Aura const* aura = GetHitAura(); + if (!aura || aura->GetStackAmount() < 10) + return; + + target->CastSpell(target, SPELL_LANDMINE_KNOCKBACK_ACHIEVEMENT, true); + } + } + + void Register() override + { + OnEffectHitTarget += SpellEffectFn(spell_gen_landmine_knockback_achievement_SpellScript::HandleScript, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT); + } + }; + + SpellScript* GetSpellScript() const override + { + return new spell_gen_landmine_knockback_achievement_SpellScript(); + } +}; + void AddSC_generic_spell_scripts() { new spell_gen_absorb0_hitlimit1(); @@ -4205,4 +4240,5 @@ void AddSC_generic_spell_scripts() new spell_gen_gm_freeze(); new spell_gen_stand(); new spell_gen_mixology_bonus(); + new spell_gen_landmine_knockback_achievement(); } diff --git a/src/server/scripts/Spells/spell_holiday.cpp b/src/server/scripts/Spells/spell_holiday.cpp index e29f87a5ff9..7fe1f54a594 100644 --- a/src/server/scripts/Spells/spell_holiday.cpp +++ b/src/server/scripts/Spells/spell_holiday.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -410,6 +410,80 @@ class spell_pilgrims_bounty_buff_food : public SpellScriptLoader } }; +enum TheTurkinator +{ + SPELL_KILL_COUNTER_VISUAL = 62015, + SPELL_KILL_COUNTER_VISUAL_MAX = 62021, + EMOTE_TURKEY_HUNTER = 0, + EMOTE_TURKEY_DOMINATION = 1, + EMOTE_TURKEY_SLAUGHTER = 2, + EMOTE_TURKEY_TRIUMPH = 3 +}; + +class spell_pilgrims_bounty_turkey_tracker : public SpellScriptLoader +{ + public: + spell_pilgrims_bounty_turkey_tracker() : SpellScriptLoader("spell_pilgrims_bounty_turkey_tracker") { } + + class spell_pilgrims_bounty_turkey_tracker_SpellScript : public SpellScript + { + PrepareSpellScript(spell_pilgrims_bounty_turkey_tracker_SpellScript); + + bool Validate(SpellInfo const* /*spell*/) + { + if (!sSpellMgr->GetSpellInfo(SPELL_KILL_COUNTER_VISUAL) || !sSpellMgr->GetSpellInfo(SPELL_KILL_COUNTER_VISUAL_MAX)) + return false; + return true; + } + + void HandleScript(SpellEffIndex /*effIndex*/) + { + Creature* caster = GetCaster()->ToCreature(); + Unit* target = GetHitUnit(); + + if (!target || !caster) + return; + + if (target->HasAura(SPELL_KILL_COUNTER_VISUAL_MAX)) + return; + + if (Aura const* aura = target->GetAura(GetSpellInfo()->Id)) + { + switch (aura->GetStackAmount()) + { + case 10: + caster->AI()->Talk(EMOTE_TURKEY_HUNTER, target); + break; + case 20: + caster->AI()->Talk(EMOTE_TURKEY_DOMINATION, target); + break; + case 30: + caster->AI()->Talk(EMOTE_TURKEY_SLAUGHTER, target); + break; + case 40: + caster->AI()->Talk(EMOTE_TURKEY_TRIUMPH, target); + target->CastSpell(target, SPELL_KILL_COUNTER_VISUAL_MAX, true); + target->RemoveAurasDueToSpell(GetSpellInfo()->Id); + break; + default: + return; + } + target->CastSpell(target, SPELL_KILL_COUNTER_VISUAL, true); + } + } + + void Register() + { + OnEffectHitTarget += SpellEffectFn(spell_pilgrims_bounty_turkey_tracker_SpellScript::HandleScript, EFFECT_1, SPELL_EFFECT_SCRIPT_EFFECT); + } + }; + + SpellScript* GetSpellScript() const + { + return new spell_pilgrims_bounty_turkey_tracker_SpellScript(); + } +}; + enum Mistletoe { SPELL_CREATE_MISTLETOE = 26206, @@ -973,6 +1047,7 @@ void AddSC_holiday_spell_scripts() new spell_pilgrims_bounty_buff_food("spell_gen_spice_bread_stuffing", SPELL_WELL_FED_HIT_TRIGGER); new spell_pilgrims_bounty_buff_food("spell_gen_pumpkin_pie", SPELL_WELL_FED_SPIRIT_TRIGGER); new spell_pilgrims_bounty_buff_food("spell_gen_candied_sweet_potato", SPELL_WELL_FED_HASTE_TRIGGER); + new spell_pilgrims_bounty_turkey_tracker(); // Winter Veil new spell_winter_veil_mistletoe(); new spell_winter_veil_px_238_winter_wondervolt(); diff --git a/src/server/scripts/Spells/spell_hunter.cpp b/src/server/scripts/Spells/spell_hunter.cpp index 0ca4112b288..abf4c6c1ad8 100644 --- a/src/server/scripts/Spells/spell_hunter.cpp +++ b/src/server/scripts/Spells/spell_hunter.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Spells/spell_item.cpp b/src/server/scripts/Spells/spell_item.cpp index f0b6c0945c2..0abff255e4b 100644 --- a/src/server/scripts/Spells/spell_item.cpp +++ b/src/server/scripts/Spells/spell_item.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -29,6 +29,7 @@ #include "SpellAuraEffects.h" #include "SkillDiscovery.h" #include "Battleground.h" +#include "DBCStores.h" // Generic script for handling item dummy effects which trigger another spell. class spell_item_trigger_spell : public SpellScriptLoader @@ -2630,6 +2631,43 @@ public: } }; +class spell_item_toy_train_set_pulse : public SpellScriptLoader +{ +public: + spell_item_toy_train_set_pulse() : SpellScriptLoader("spell_item_toy_train_set_pulse") { } + + class spell_item_toy_train_set_pulse_SpellScript : public SpellScript + { + PrepareSpellScript(spell_item_toy_train_set_pulse_SpellScript); + + void HandleDummy(SpellEffIndex /*index*/) + { + if (Player* target = GetHitUnit()->ToPlayer()) + { + target->HandleEmoteCommand(EMOTE_ONESHOT_TRAIN); + if (EmotesTextSoundEntry const* soundEntry = FindTextSoundEmoteFor(TEXT_EMOTE_TRAIN, target->getRace(), target->getGender())) + target->PlayDistanceSound(soundEntry->SoundId); + } + } + + void HandleTargets(std::list<WorldObject*>& targetList) + { + targetList.remove_if([](WorldObject const* obj) { return obj->GetTypeId() != TYPEID_PLAYER; }); + } + + void Register() override + { + OnEffectHitTarget += SpellEffectFn(spell_item_toy_train_set_pulse_SpellScript::HandleDummy, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT); + OnObjectAreaTargetSelect += SpellObjectAreaTargetSelectFn(spell_item_toy_train_set_pulse_SpellScript::HandleTargets, EFFECT_ALL, TARGET_UNIT_SRC_AREA_ALLY); + } + }; + + SpellScript* GetSpellScript() const override + { + return new spell_item_toy_train_set_pulse_SpellScript(); + } +}; + void AddSC_item_spell_scripts() { // 23074 Arcanite Dragonling @@ -2698,4 +2736,5 @@ void AddSC_item_spell_scripts() new spell_item_chicken_cover(); new spell_item_muisek_vessel(); new spell_item_greatmothers_soulcatcher(); + new spell_item_toy_train_set_pulse(); } diff --git a/src/server/scripts/Spells/spell_mage.cpp b/src/server/scripts/Spells/spell_mage.cpp index c45442e1f80..d08968fbf55 100644 --- a/src/server/scripts/Spells/spell_mage.cpp +++ b/src/server/scripts/Spells/spell_mage.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Spells/spell_paladin.cpp b/src/server/scripts/Spells/spell_paladin.cpp index 197d55486a8..8bd4b3eb070 100644 --- a/src/server/scripts/Spells/spell_paladin.cpp +++ b/src/server/scripts/Spells/spell_paladin.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -43,6 +43,12 @@ enum PaladinSpells SPELL_PALADIN_BLESSING_OF_LOWER_CITY_PRIEST = 37880, SPELL_PALADIN_BLESSING_OF_LOWER_CITY_SHAMAN = 37881, + SPELL_PALADIN_BEACON_OF_LIGHT = 53563, + SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_1 = 53652, + SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_2 = 53653, + SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_3 = 53654, + SPELL_PALADIN_HOLY_LIGHT = 635, + SPELL_PALADIN_DIVINE_STORM = 53385, SPELL_PALADIN_DIVINE_STORM_DUMMY = 54171, SPELL_PALADIN_DIVINE_STORM_HEAL = 54172, @@ -1153,6 +1159,68 @@ class spell_pal_lay_on_hands : public SpellScriptLoader } }; +// 53651 - Light's Beacon - Beacon of Light +class spell_pal_light_s_beacon : public SpellScriptLoader +{ + public: + spell_pal_light_s_beacon() : SpellScriptLoader("spell_pal_light_s_beacon") { } + + class spell_pal_light_s_beacon_AuraScript : public AuraScript + { + PrepareAuraScript(spell_pal_light_s_beacon_AuraScript); + + bool Validate(SpellInfo const* /*spellInfo*/) override + { + if (!sSpellMgr->GetSpellInfo(SPELL_PALADIN_BEACON_OF_LIGHT) + || !sSpellMgr->GetSpellInfo(SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_1) + || !sSpellMgr->GetSpellInfo(SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_2) + || !sSpellMgr->GetSpellInfo(SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_3) + || !sSpellMgr->GetSpellInfo(SPELL_PALADIN_HOLY_LIGHT)) + return false; + return true; + } + + bool CheckProc(ProcEventInfo& eventInfo) + { + if (GetTarget()->HasAura(SPELL_PALADIN_BEACON_OF_LIGHT, eventInfo.GetActor()->GetGUID())) + return false; + return true; + } + + void HandleProc(AuraEffect const* aurEff, ProcEventInfo& eventInfo) + { + PreventDefaultAction(); + + SpellInfo const* procSpell = eventInfo.GetSpellInfo(); + if (!procSpell) + return; + + uint32 healSpellId = procSpell->IsRankOf(sSpellMgr->EnsureSpellInfo(SPELL_PALADIN_HOLY_LIGHT)) ? SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_1 : SPELL_PALADIN_BEACON_OF_LIGHT_HEAL_3; + uint32 heal = CalculatePct(eventInfo.GetHealInfo()->GetHeal(), aurEff->GetAmount()); + + Unit* beaconTarget = GetCaster(); + if (!beaconTarget || !beaconTarget->HasAura(SPELL_PALADIN_BEACON_OF_LIGHT, eventInfo.GetActor()->GetGUID())) + return; + + /// @todo: caster must be the healed unit to perform distance checks correctly + /// but that will break animation on clientside + /// caster in spell packets must be the healing unit + eventInfo.GetActor()->CastCustomSpell(healSpellId, SPELLVALUE_BASE_POINT0, heal, beaconTarget, true); + } + + void Register() override + { + DoCheckProc += AuraCheckProcFn(spell_pal_light_s_beacon_AuraScript::CheckProc); + OnEffectProc += AuraEffectProcFn(spell_pal_light_s_beacon_AuraScript::HandleProc, EFFECT_0, SPELL_AURA_DUMMY); + } + }; + + AuraScript* GetAuraScript() const override + { + return new spell_pal_light_s_beacon_AuraScript(); + } +}; + // 31789 - Righteous Defense class spell_pal_righteous_defense : public SpellScriptLoader { @@ -1338,6 +1406,7 @@ void AddSC_paladin_spell_scripts() new spell_pal_judgement("spell_pal_judgement_of_wisdom", SPELL_PALADIN_JUDGEMENT_OF_WISDOM); new spell_pal_judgement_of_command(); new spell_pal_lay_on_hands(); + new spell_pal_light_s_beacon(); new spell_pal_righteous_defense(); new spell_pal_sacred_shield(); new spell_pal_seal_of_righteousness(); diff --git a/src/server/scripts/Spells/spell_pet.cpp b/src/server/scripts/Spells/spell_pet.cpp index a0664a2ea00..7393a7d3bcb 100644 --- a/src/server/scripts/Spells/spell_pet.cpp +++ b/src/server/scripts/Spells/spell_pet.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Spells/spell_priest.cpp b/src/server/scripts/Spells/spell_priest.cpp index b5c3b26f1bf..ecf5b7b5acf 100644 --- a/src/server/scripts/Spells/spell_priest.cpp +++ b/src/server/scripts/Spells/spell_priest.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Spells/spell_quest.cpp b/src/server/scripts/Spells/spell_quest.cpp index 8af97e46dee..3121a18734d 100644 --- a/src/server/scripts/Spells/spell_quest.cpp +++ b/src/server/scripts/Spells/spell_quest.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Spells/spell_rogue.cpp b/src/server/scripts/Spells/spell_rogue.cpp index 23a6cdee8a9..9b577d4e140 100644 --- a/src/server/scripts/Spells/spell_rogue.cpp +++ b/src/server/scripts/Spells/spell_rogue.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -41,6 +41,9 @@ enum RogueSpells SPELL_ROGUE_SHIV_TRIGGERED = 5940, SPELL_ROGUE_TRICKS_OF_THE_TRADE_DMG_BOOST = 57933, SPELL_ROGUE_TRICKS_OF_THE_TRADE_PROC = 59628, + SPELL_ROGUE_HONOR_AMONG_THIEVES = 51698, + SPELL_ROGUE_HONOR_AMONG_THIEVES_PROC = 52916, + SPELL_ROGUE_HONOR_AMONG_THIEVES_2 = 51699 }; // 13877, 33735, (check 51211, 65956) - Blade Flurry @@ -703,6 +706,143 @@ class spell_rog_tricks_of_the_trade_proc : public SpellScriptLoader } }; +// 51698,51700,51701 - Honor Among Thieves +class spell_rog_honor_among_thieves : public SpellScriptLoader +{ +public: + spell_rog_honor_among_thieves() : SpellScriptLoader("spell_rog_honor_among_thieves") { } + + class spell_rog_honor_among_thieves_AuraScript : public AuraScript + { + PrepareAuraScript(spell_rog_honor_among_thieves_AuraScript); + + bool CheckProc(ProcEventInfo& /*eventInfo*/) + { + Unit* caster = GetCaster(); + if (!caster) + return false; + + if (!caster->GetSpellHistory()->HasCooldown(GetSpellInfo()->Effects[EFFECT_0].TriggerSpell)) + return true; + + return false; + } + + void HandleProc(AuraEffect const* aurEff, ProcEventInfo& /*eventInfo*/) + { + PreventDefaultAction(); + + Unit* caster = GetCaster(); + if (!caster) + return; + + Unit* target = GetTarget(); + target->CastSpell(target, GetSpellInfo()->Effects[EFFECT_0].TriggerSpell, TriggerCastFlags(TRIGGERED_FULL_MASK & ~TRIGGERED_IGNORE_SPELL_AND_CATEGORY_CD), nullptr, aurEff, caster->GetGUID()); + } + + void Register() override + { + DoCheckProc += AuraCheckProcFn(spell_rog_honor_among_thieves_AuraScript::CheckProc); + OnEffectProc += AuraEffectProcFn(spell_rog_honor_among_thieves_AuraScript::HandleProc, EFFECT_0, SPELL_AURA_PROC_TRIGGER_SPELL); + } + }; + + AuraScript* GetAuraScript() const override + { + return new spell_rog_honor_among_thieves_AuraScript(); + } +}; + +// 52916 - Honor Among Thieves (Proc) +class spell_rog_honor_among_thieves_proc : public SpellScriptLoader +{ +public: + spell_rog_honor_among_thieves_proc() : SpellScriptLoader("spell_rog_honor_among_thieves_proc") { } + + class spell_rog_honor_among_thieves_proc_SpellScript : public SpellScript + { + PrepareSpellScript(spell_rog_honor_among_thieves_proc_SpellScript); + + bool Validate(SpellInfo const* /*spellInfo*/) override + { + if (!sSpellMgr->GetSpellInfo(SPELL_ROGUE_HONOR_AMONG_THIEVES_PROC)) + return false; + + return true; + } + + void FilterTargets(std::list<WorldObject*>& targets) + { + targets.clear(); + + Unit* target = GetOriginalCaster(); + if (!target) + return; + + targets.push_back(target); + } + + void HandleBeforeHit() + { + Unit* target = GetHitUnit(); + if (!target) + return; + + /* + * The applied aura has a duration of 8 seconds + * This prevents new applications while its active + * Removing it on each new proc enables the application from different sources (different grouped players) + * and on new procs after the source cooldown is finished (1 second) + */ + if (target->HasAura(GetSpellInfo()->Id)) + target->RemoveAura(GetSpellInfo()->Id); + } + + void TriggerCooldown() + { + Unit* target = GetHitUnit(); + if (!target) + return; + + target->GetSpellHistory()->AddCooldown(GetSpellInfo()->Id, 0, std::chrono::seconds(1)); + } + + void Register() override + { + OnObjectAreaTargetSelect += SpellObjectAreaTargetSelectFn(spell_rog_honor_among_thieves_proc_SpellScript::FilterTargets, EFFECT_0, TARGET_UNIT_CASTER_AREA_PARTY); + BeforeHit += SpellHitFn(spell_rog_honor_among_thieves_proc_SpellScript::HandleBeforeHit); + AfterHit += SpellHitFn(spell_rog_honor_among_thieves_proc_SpellScript::TriggerCooldown); + } + }; + + SpellScript* GetSpellScript() const override + { + return new spell_rog_honor_among_thieves_proc_SpellScript(); + } + + class spell_rog_honor_among_thieves_proc_AuraScript : public AuraScript + { + PrepareAuraScript(spell_rog_honor_among_thieves_proc_AuraScript); + + void HandleEffectApply(AuraEffect const* /*aurEff*/, AuraEffectHandleModes /*mode*/) + { + if (Player* player = GetTarget()->ToPlayer()) + if (Unit* spellTarget = ObjectAccessor::GetUnit(*player, player->GetTarget())) + player->CastSpell(spellTarget, SPELL_ROGUE_HONOR_AMONG_THIEVES_2, true); + } + + void Register() override + { + AfterEffectApply += AuraEffectApplyFn(spell_rog_honor_among_thieves_proc_AuraScript::HandleEffectApply, EFFECT_0, SPELL_AURA_DUMMY, AURA_EFFECT_HANDLE_REAL); + } + }; + + AuraScript* GetAuraScript() const override + { + return new spell_rog_honor_among_thieves_proc_AuraScript(); + } +}; + void AddSC_rogue_spell_scripts() { new spell_rog_blade_flurry(); @@ -716,4 +856,6 @@ void AddSC_rogue_spell_scripts() new spell_rog_shiv(); new spell_rog_tricks_of_the_trade(); new spell_rog_tricks_of_the_trade_proc(); + new spell_rog_honor_among_thieves(); + new spell_rog_honor_among_thieves_proc(); } diff --git a/src/server/scripts/Spells/spell_shaman.cpp b/src/server/scripts/Spells/spell_shaman.cpp index 5564a8275c8..41e72b1388b 100644 --- a/src/server/scripts/Spells/spell_shaman.cpp +++ b/src/server/scripts/Spells/spell_shaman.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -55,7 +55,8 @@ enum ShamanSpells SPELL_SHAMAN_TOTEM_EARTHBIND_EARTHGRAB = 64695, SPELL_SHAMAN_TOTEM_EARTHBIND_TOTEM = 6474, SPELL_SHAMAN_TOTEM_EARTHEN_POWER = 59566, - SPELL_SHAMAN_TOTEM_HEALING_STREAM_HEAL = 52042 + SPELL_SHAMAN_TOTEM_HEALING_STREAM_HEAL = 52042, + SPELL_SHAMAN_TOTEMIC_MASTERY = 38437 }; enum ShamanSpellIcons @@ -1025,6 +1026,46 @@ class spell_sha_thunderstorm : public SpellScriptLoader } }; +// 38443 - Totemic Mastery (Tier 6 - 2P) +class spell_sha_totemic_mastery : public SpellScriptLoader +{ +public: + spell_sha_totemic_mastery() : SpellScriptLoader("spell_sha_totemic_mastery") { } + + class spell_sha_totemic_mastery_AuraScript : public AuraScript + { + PrepareAuraScript(spell_sha_totemic_mastery_AuraScript); + + bool Validate(SpellInfo const* /*spellInfo*/) override + { + if (!sSpellMgr->GetSpellInfo(SPELL_SHAMAN_TOTEMIC_MASTERY)) + return false; + return true; + } + + void HandleDummy(AuraEffect const* /*aurEff*/) + { + Unit* target = GetTarget(); + for (uint8 i = SUMMON_SLOT_TOTEM; i < MAX_TOTEM_SLOT; ++i) + if (!target->m_SummonSlot[i]) + return; + + target->CastSpell(target, SPELL_SHAMAN_TOTEMIC_MASTERY, true); + PreventDefaultAction(); + } + + void Register() override + { + OnEffectPeriodic += AuraEffectPeriodicFn(spell_sha_totemic_mastery_AuraScript::HandleDummy, EFFECT_0, SPELL_AURA_PERIODIC_TRIGGER_SPELL); + } + }; + + AuraScript* GetAuraScript() const override + { + return new spell_sha_totemic_mastery_AuraScript(); + } +}; + void AddSC_shaman_spell_scripts() { new spell_sha_ancestral_awakening_proc(); @@ -1048,4 +1089,5 @@ void AddSC_shaman_spell_scripts() new spell_sha_mana_tide_totem(); new spell_sha_sentry_totem(); new spell_sha_thunderstorm(); + new spell_sha_totemic_mastery(); } diff --git a/src/server/scripts/Spells/spell_warlock.cpp b/src/server/scripts/Spells/spell_warlock.cpp index a2bbfdc246a..7cc6fe888e9 100644 --- a/src/server/scripts/Spells/spell_warlock.cpp +++ b/src/server/scripts/Spells/spell_warlock.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/Spells/spell_warrior.cpp b/src/server/scripts/Spells/spell_warrior.cpp index c7839a59608..d224c234cb4 100644 --- a/src/server/scripts/Spells/spell_warrior.cpp +++ b/src/server/scripts/Spells/spell_warrior.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/World/CMakeLists.txt b/src/server/scripts/World/CMakeLists.txt index 56b8a3209ae..17b3f2d8492 100644 --- a/src/server/scripts/World/CMakeLists.txt +++ b/src/server/scripts/World/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/scripts/World/achievement_scripts.cpp b/src/server/scripts/World/achievement_scripts.cpp index 310284a0461..a97df93bed6 100644 --- a/src/server/scripts/World/achievement_scripts.cpp +++ b/src/server/scripts/World/achievement_scripts.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/World/action_ip_logger.cpp b/src/server/scripts/World/action_ip_logger.cpp index f0ffbe1c7f3..f7ed11569a4 100644 --- a/src/server/scripts/World/action_ip_logger.cpp +++ b/src/server/scripts/World/action_ip_logger.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/World/areatrigger_scripts.cpp b/src/server/scripts/World/areatrigger_scripts.cpp index 1ad09eb65b0..1ac819cc119 100644 --- a/src/server/scripts/World/areatrigger_scripts.cpp +++ b/src/server/scripts/World/areatrigger_scripts.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/World/boss_emerald_dragons.cpp b/src/server/scripts/World/boss_emerald_dragons.cpp index 40aa759caf6..1f89720803d 100644 --- a/src/server/scripts/World/boss_emerald_dragons.cpp +++ b/src/server/scripts/World/boss_emerald_dragons.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/World/chat_log.cpp b/src/server/scripts/World/chat_log.cpp index 87dba586678..cbc7845f28d 100644 --- a/src/server/scripts/World/chat_log.cpp +++ b/src/server/scripts/World/chat_log.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/World/duel_reset.cpp b/src/server/scripts/World/duel_reset.cpp index 9e720455692..3c46255a1bf 100644 --- a/src/server/scripts/World/duel_reset.cpp +++ b/src/server/scripts/World/duel_reset.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 @@ -34,9 +34,8 @@ class DuelResetScript : public PlayerScript player1->GetSpellHistory()->SaveCooldownStateBeforeDuel(); player2->GetSpellHistory()->SaveCooldownStateBeforeDuel(); - - ResetSpellCooldowns(player1); - ResetSpellCooldowns(player2); + ResetSpellCooldowns(player1, true); + ResetSpellCooldowns(player2, true); } // Health and mana reset @@ -73,9 +72,8 @@ class DuelResetScript : public PlayerScript // Cooldown restore if (sWorld->getBoolConfig(CONFIG_RESET_DUEL_COOLDOWNS)) { - - ResetSpellCooldowns(winner); - ResetSpellCooldowns(loser); + ResetSpellCooldowns(winner, false); + ResetSpellCooldowns(loser, false); winner->GetSpellHistory()->RestoreCooldownStateAfterDuel(); loser->GetSpellHistory()->RestoreCooldownStateAfterDuel(); @@ -98,14 +96,35 @@ class DuelResetScript : public PlayerScript } } - static void ResetSpellCooldowns(Player* player) + static void ResetSpellCooldowns(Player* player, bool onStartDuel) { - // remove cooldowns on spells that have < 10 min CD and has no onHold - player->GetSpellHistory()->ResetCooldowns([](SpellHistory::CooldownStorageType::iterator itr) -> bool + if (onStartDuel) { - SpellInfo const* spellInfo = sSpellMgr->EnsureSpellInfo(itr->first); - return spellInfo->RecoveryTime < 10 * MINUTE * IN_MILLISECONDS && spellInfo->CategoryRecoveryTime < 10 * MINUTE * IN_MILLISECONDS && !itr->second.OnHold; - }, true); + // remove cooldowns on spells that have < 10 min CD > 30 sec and has no onHold + player->GetSpellHistory()->ResetCooldowns([](SpellHistory::CooldownStorageType::iterator itr) -> bool + { + SpellHistory::Clock::time_point now = SpellHistory::Clock::now(); + uint32 cooldownDuration = itr->second.CooldownEnd > now ? std::chrono::duration_cast<std::chrono::milliseconds>(itr->second.CooldownEnd - now).count() : 0; + SpellInfo const* spellInfo = sSpellMgr->EnsureSpellInfo(itr->first); + return spellInfo->RecoveryTime < 10 * MINUTE * IN_MILLISECONDS + && spellInfo->CategoryRecoveryTime < 10 * MINUTE * IN_MILLISECONDS + && !itr->second.OnHold + && cooldownDuration > 0 + && ( spellInfo->RecoveryTime - cooldownDuration ) > (MINUTE / 2) * IN_MILLISECONDS + && ( spellInfo->CategoryRecoveryTime - cooldownDuration ) > (MINUTE / 2) * IN_MILLISECONDS; + }, true); + } + else + { + // remove cooldowns on spells that have < 10 min CD and has no onHold + player->GetSpellHistory()->ResetCooldowns([](SpellHistory::CooldownStorageType::iterator itr) -> bool + { + SpellInfo const* spellInfo = sSpellMgr->EnsureSpellInfo(itr->first); + return spellInfo->RecoveryTime < 10 * MINUTE * IN_MILLISECONDS + && spellInfo->CategoryRecoveryTime < 10 * MINUTE * IN_MILLISECONDS + && !itr->second.OnHold; + }, true); + } // pet cooldowns if (Pet* pet = player->GetPet()) diff --git a/src/server/scripts/World/go_scripts.cpp b/src/server/scripts/World/go_scripts.cpp index f3accdf4c77..b90839f50c5 100644 --- a/src/server/scripts/World/go_scripts.cpp +++ b/src/server/scripts/World/go_scripts.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -41,6 +41,7 @@ go_tadpole_cage go_amberpine_outhouse go_hive_pod go_veil_skith_cage +go_toy_train_set EndContentData */ #include "ScriptMgr.h" @@ -1196,6 +1197,48 @@ public: } }; + +enum ToyTrainSpells +{ + SPELL_TOY_TRAIN_PULSE = 61551, +}; + +class go_toy_train_set : public GameObjectScript +{ + public: + go_toy_train_set() : GameObjectScript("go_toy_train_set") { } + + struct go_toy_train_setAI : public GameObjectAI + { + go_toy_train_setAI(GameObject* go) : GameObjectAI(go), _pulseTimer(3 * IN_MILLISECONDS) { } + + void UpdateAI(uint32 diff) override + { + if (diff < _pulseTimer) + _pulseTimer -= diff; + else + { + go->CastSpell(nullptr, SPELL_TOY_TRAIN_PULSE, true); + _pulseTimer = 6 * IN_MILLISECONDS; + } + } + + // triggered on wrecker'd + void DoAction(int32 /*action*/) override + { + go->Delete(); + } + + private: + uint32 _pulseTimer; + }; + + GameObjectAI* GetAI(GameObject* go) const override + { + return new go_toy_train_setAI(go); + } +}; + void AddSC_go_scripts() { new go_cat_figurine(); @@ -1231,4 +1274,5 @@ void AddSC_go_scripts() new go_veil_skith_cage(); new go_frostblade_shrine(); new go_midsummer_bonfire(); + new go_toy_train_set(); } diff --git a/src/server/scripts/World/guards.cpp b/src/server/scripts/World/guards.cpp index ff0b13757ba..e44feff10c8 100644 --- a/src/server/scripts/World/guards.cpp +++ b/src/server/scripts/World/guards.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/World/item_scripts.cpp b/src/server/scripts/World/item_scripts.cpp index e8aa9cf1949..f4241ba0819 100644 --- a/src/server/scripts/World/item_scripts.cpp +++ b/src/server/scripts/World/item_scripts.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/World/mob_generic_creature.cpp b/src/server/scripts/World/mob_generic_creature.cpp index dfb7d62bc71..b3d751ea7c3 100644 --- a/src/server/scripts/World/mob_generic_creature.cpp +++ b/src/server/scripts/World/mob_generic_creature.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/scripts/World/npc_innkeeper.cpp b/src/server/scripts/World/npc_innkeeper.cpp index 09f9acf5740..d4670bd5695 100644 --- a/src/server/scripts/World/npc_innkeeper.cpp +++ b/src/server/scripts/World/npc_innkeeper.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/scripts/World/npc_professions.cpp b/src/server/scripts/World/npc_professions.cpp index 9c05e4e2c08..867ebafe32b 100644 --- a/src/server/scripts/World/npc_professions.cpp +++ b/src/server/scripts/World/npc_professions.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -18,27 +18,26 @@ /* ScriptData SDName: Npc_Professions -SD%Complete: 80 -SDComment: Provides learn/unlearn/relearn-options for professions. Not supported: Unlearn engineering, re-learn engineering, re-learn leatherworking. -SDCategory: NPCs +SD%Complete: 100 +SDComment: Provides learn/unlearn/relearn-options for professions. +SDCategory: NPCs/GOBs EndScriptData */ #include "ScriptMgr.h" #include "ScriptedCreature.h" #include "ScriptedGossip.h" +#include "GameObjectAI.h" #include "Player.h" #include "SpellInfo.h" #include "WorldSession.h" /* A few notes for future developement: -- A full implementation of gossip for GO's is required. They must have the same scripting capabilities as creatures. Basically, -there is no difference here (except that default text is chosen with `gameobject_template`.`data3` (for GO type2, different dataN for a few others) - It's possible blacksmithing still require some tweaks and adjustments due to the way we _have_ to use reputation. */ /*### -# to be removed from here (->ncp_text). This is data for database projects. +# to be removed from here (->npc_text). This is data for database projects. ###*/ #define TALK_MUST_UNLEARN_WEAPON "You must forget your weapon type specialty before I can help you. Go to Everlook in Winterspring and seek help there." @@ -153,6 +152,9 @@ enum ProfessionSpells S_LEARN_GOBLIN = 20221, S_LEARN_GNOMISH = 20220, + S_UNLEARN_GOBLIN = 68334, + S_UNLEARN_GNOMISH = 68333, + S_SPELLFIRE = 26797, S_MOONCLOTH = 26798, S_SHADOWEAVE = 26801, @@ -376,6 +378,27 @@ void ProfessionUnlearnSpells(Player* player, uint32 type) player->RemoveSpell(36075); // Wildfeather Leggings player->RemoveSpell(36078); // Living Crystal Breastplate break; + case S_UNLEARN_GOBLIN: // S_UNLEARN_GOBLIN + player->RemoveSpell(30565); // Foreman's Enchanted Helmet + player->RemoveSpell(30566); // Foreman's Reinforced Helmet + player->RemoveSpell(30563); // Goblin Rocket Launcher + player->RemoveSpell(56514); // Global Thermal Sapper Charge + player->RemoveSpell(36954); // Dimensional Ripper - Area 52 + player->RemoveSpell(23486); // Dimensional Ripper - Everlook + player->RemoveSpell(23078); // Goblin Jumper Cables XL + player->RemoveSpell(72952); // Shatter Rounds + break; + case S_UNLEARN_GNOMISH: // S_UNLEARN_GNOMISH + player->RemoveSpell(30575); // Gnomish Battle Goggles + player->RemoveSpell(30574); // Gnomish Power Goggles + player->RemoveSpell(56473); // Gnomish X-Ray Specs + player->RemoveSpell(30569); // Gnomish Poultryizer + player->RemoveSpell(30563); // Ultrasafe Transporter - Toshley's Station + player->RemoveSpell(23489); // Ultrasafe Transporter - Gadgetzan + player->RemoveSpell(23129); // World Enlarger + player->RemoveSpell(23096); // Gnomish Alarm-o-Bot + player->RemoveSpell(72953); // Iceblade Arrow + break; case S_UNLEARN_SPELLFIRE: // S_UNLEARN_SPELLFIRE player->RemoveSpell(26752); // Spellfire Belt player->RemoveSpell(26753); // Spellfire Gloves @@ -923,6 +946,76 @@ public: } }; +// Object ID - 177226 +// Book "Soothsaying for dummies" +enum SoothsayingForDummies +{ + GOSSIP_ID = 7058, + + // Engineering + OPTION_UNLEARN_GNOMISH = 0, + OPTION_UNLEARN_GOBLIN = 1, + OPTION_LEARN_GNOMISH = 2, + OPTION_LEARN_GOBLIN = 3, + + // Leatherworking + OPTION_LEARN_DRAGONSCALE = 4, + OPTION_LEARN_ELEMENTAL = 5, + OPTION_LEARN_TRIBAL = 6 +}; + +class go_soothsaying_for_dummies : public GameObjectScript +{ + public: + go_soothsaying_for_dummies() : GameObjectScript("go_soothsaying_for_dummies") { } + + struct go_soothsaying_for_dummiesAI : public GameObjectAI + { + go_soothsaying_for_dummiesAI(GameObject* go) : GameObjectAI(go) { } + + bool GossipSelect(Player* player, uint32 menuId, uint32 gossipListId) override + { + if (menuId != GOSSIP_ID) + return false; + + switch (gossipListId) + { + case OPTION_UNLEARN_GNOMISH: + ProcessUnlearnAction(player, nullptr, S_UNLEARN_GNOMISH, 0, 0); // cost is handled by gossip code + break; + case OPTION_UNLEARN_GOBLIN: + ProcessUnlearnAction(player, nullptr, S_UNLEARN_GOBLIN, 0, 0); + break; + case OPTION_LEARN_GNOMISH: + player->CastSpell(player, S_LEARN_GNOMISH, true); + break; + case OPTION_LEARN_GOBLIN: + player->CastSpell(player, S_LEARN_GOBLIN, true); + break; + case OPTION_LEARN_DRAGONSCALE: + player->CastSpell(player, S_LEARN_DRAGON, true); + break; + case OPTION_LEARN_ELEMENTAL: + player->CastSpell(player, S_LEARN_ELEMENTAL, true); + break; + case OPTION_LEARN_TRIBAL: + player->CastSpell(player, S_LEARN_TRIBAL, true); + break; + default: + return false; + } + + player->CLOSE_GOSSIP_MENU(); + return true; // prevent further processing + } + }; + + GameObjectAI* GetAI(GameObject* go) const override + { + return new go_soothsaying_for_dummiesAI(go); + } +}; + /*### # start menues leatherworking ###*/ @@ -1212,6 +1305,7 @@ void AddSC_npc_professions() new npc_prof_alchemy(); new npc_prof_blacksmith(); new npc_engineering_tele_trinket(); + new go_soothsaying_for_dummies(); new npc_prof_leather(); new npc_prof_tailor(); } diff --git a/src/server/scripts/World/npc_taxi.cpp b/src/server/scripts/World/npc_taxi.cpp deleted file mode 100644 index 16dc0d02960..00000000000 --- a/src/server/scripts/World/npc_taxi.cpp +++ /dev/null @@ -1,312 +0,0 @@ -/* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> - * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> - * - * This program is free software; you can redistribute it and/or modify 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, see <http://www.gnu.org/licenses/>. - */ - -/* ScriptData -SDName: Npc_Taxi -SD%Complete: 0% -SDComment: To be used for taxi NPCs that are located globally. -SDCategory: NPCs -EndScriptData -*/ - -#include "ScriptMgr.h" -#include "ScriptedCreature.h" -#include "ScriptedGossip.h" -#include "Player.h" -#include "WorldSession.h" - -#define GOSSIP_SUSURRUS "I am ready." -#define GOSSIP_NETHER_DRAKE "I'm ready to fly! Take me up, dragon!" -#define GOSSIP_BRAZEN "I am ready to go to Durnholde Keep." -#define GOSSIP_IRONWING "I'd like to take a flight around Stormwind Harbor." -#define GOSSIP_DABIREE1 "Fly me to Murketh and Shaadraz Gateways" -#define GOSSIP_DABIREE2 "Fly me to Shatter Point" -#define GOSSIP_WINDBELLOW1 "Fly me to The Abyssal Shelf" -#define GOSSIP_WINDBELLOW2 "Fly me to Honor Point" -#define GOSSIP_BRACK1 "Fly me to Murketh and Shaadraz Gateways" -#define GOSSIP_BRACK2 "Fly me to The Abyssal Shelf" -#define GOSSIP_BRACK3 "Fly me to Spinebreaker Post" -#define GOSSIP_IRENA "Fly me to Skettis please" -#define GOSSIP_CLOUDBREAKER1 "Speaking of action, I've been ordered to undertake an air strike." -#define GOSSIP_CLOUDBREAKER2 "I need to intercept the Dawnblade reinforcements." -#define GOSSIP_DRAGONHAWK "<Ride the dragonhawk to Sun's Reach>" -#define GOSSIP_VERONIA "Fly me to Manaforge Coruu please" -#define GOSSIP_DEESAK "Fly me to Ogri'la please" -#define GOSSIP_AFRASASTRASZ1 "I would like to take a flight to the ground, Lord Of Afrasastrasz." -#define GOSSIP_AFRASASTRASZ2 "My Lord, I must go to the upper floor of the temple." -#define GOSSIP_TARIOLSTRASZ1 "My Lord, I must go to the upper floor of the temple." -#define GOSSIP_TARIOLSTRASZ2 "Can you spare a drake to travel to Lord Of Afrasastrasz, in the middle of the temple?" -#define GOSSIP_TORASTRASZA1 "I would like to see Lord Of Afrasastrasz, in the middle of the temple." -#define GOSSIP_TORASTRASZA2 "Yes, Please. I would like to return to the ground floor of the temple." -#define GOSSIP_CRIMSONWING "<Ride the gryphons to Survey Alcaz Island>" -#define GOSSIP_WILLIAMKEILAR1 "Take me to Northpass Tower." -#define GOSSIP_WILLIAMKEILAR2 "Take me to Eastwall Tower." -#define GOSSIP_WILLIAMKEILAR3 "Take me to Crown Guard Tower." - -class npc_taxi : public CreatureScript -{ -public: - npc_taxi() : CreatureScript("npc_taxi") { } - - bool OnGossipHello(Player* player, Creature* creature) override - { - if (creature->IsQuestGiver()) - player->PrepareQuestMenu(creature->GetGUID()); - - switch (creature->GetEntry()) - { - case 17435: // Azuremyst Isle - Susurrus - if (player->HasItemCount(23843, 1, true)) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_SUSURRUS, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF); - break; - case 20903: // Netherstorm - Protectorate Nether Drake - if (player->GetQuestStatus(10438) == QUEST_STATUS_INCOMPLETE && player->HasItemCount(29778)) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_NETHER_DRAKE, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 1); - break; - case 18725: // Old Hillsbrad Foothills - Brazen - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_BRAZEN, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 2); - break; - case 29154: // Stormwind City - Thargold Ironwing - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_IRONWING, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 3); - break; - case 19409: // Hellfire Peninsula - Wing Commander Dabir'ee - //Mission: The Murketh and Shaadraz Gateways - if (player->GetQuestStatus(10146) == QUEST_STATUS_INCOMPLETE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_DABIREE1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 4); - - //Shatter Point - if (!player->GetQuestRewardStatus(10340)) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_DABIREE2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 5); - break; - case 20235: // Hellfire Peninsula - Gryphoneer Windbellow - //Mission: The Abyssal Shelf || Return to the Abyssal Shelf - if (player->GetQuestStatus(10163) == QUEST_STATUS_INCOMPLETE || player->GetQuestStatus(10346) == QUEST_STATUS_INCOMPLETE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_WINDBELLOW1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 6); - - //Go to the Front - if (player->GetQuestStatus(10382) != QUEST_STATUS_NONE && !player->GetQuestRewardStatus(10382)) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_WINDBELLOW2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 7); - break; - case 19401: // Hellfire Peninsula - Wing Commander Brack - //Mission: The Murketh and Shaadraz Gateways - if (player->GetQuestStatus(10129) == QUEST_STATUS_INCOMPLETE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_BRACK1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 8); - - //Mission: The Abyssal Shelf || Return to the Abyssal Shelf - if (player->GetQuestStatus(10162) == QUEST_STATUS_INCOMPLETE || player->GetQuestStatus(10347) == QUEST_STATUS_INCOMPLETE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_BRACK2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 9); - - //Spinebreaker Post - if (player->GetQuestStatus(10242) == QUEST_STATUS_COMPLETE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_BRACK3, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 10); - break; - case 23413: // Blade's Edge Mountains - Skyguard Handler Irena - if (player->GetReputationRank(1031) >= REP_HONORED) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_IRENA, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 11); - break; - case 25059: // Isle of Quel'Danas - Ayren Cloudbreaker - if (player->GetQuestStatus(11532) == QUEST_STATUS_INCOMPLETE || player->GetQuestStatus(11533) == QUEST_STATUS_INCOMPLETE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_CLOUDBREAKER1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 12); - - if (player->GetQuestStatus(11542) == QUEST_STATUS_INCOMPLETE || player->GetQuestStatus(11543) == QUEST_STATUS_INCOMPLETE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_CLOUDBREAKER2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 13); - break; - case 25236: // Isle of Quel'Danas - Unrestrained Dragonhawk - if (player->GetQuestStatus(11542) == QUEST_STATUS_COMPLETE || player->GetQuestStatus(11543) == QUEST_STATUS_COMPLETE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_DRAGONHAWK, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 14); - break; - case 20162: // Netherstorm - Veronia - //Behind Enemy Lines - if (player->GetQuestStatus(10652) != QUEST_STATUS_REWARDED) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_VERONIA, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 15); - break; - case 23415: // Terokkar Forest - Skyguard Handler Deesak - if (player->GetReputationRank(1031) >= REP_HONORED) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_DEESAK, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 16); - break; - case 27575: // Dragonblight - Lord Afrasastrasz - // middle -> ground - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_AFRASASTRASZ1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 17); - // middle -> top - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_AFRASASTRASZ2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 18); - break; - case 26443: // Dragonblight - Tariolstrasz //need to check if quests are required before gossip available (12123, 12124) - // ground -> top - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_TARIOLSTRASZ1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 19); - // ground -> middle - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_TARIOLSTRASZ2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 20); - break; - case 26949: // Dragonblight - Torastrasza - // top -> middle - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_TORASTRASZA1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 21); - // top -> ground - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_TORASTRASZA2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 22); - break; - case 23704: // Dustwallow Marsh - Cassa Crimsonwing - if (player->GetQuestStatus(11142) == QUEST_STATUS_INCOMPLETE) - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_CRIMSONWING, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF+25); - break; - case 17209: - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_WILLIAMKEILAR1, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 26); - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_WILLIAMKEILAR2, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 27); - player->ADD_GOSSIP_ITEM(GOSSIP_ICON_CHAT, GOSSIP_WILLIAMKEILAR3, GOSSIP_SENDER_MAIN, GOSSIP_ACTION_INFO_DEF + 28); - break; - } - - player->SEND_GOSSIP_MENU(player->GetGossipTextId(creature), creature->GetGUID()); - return true; - } - - bool OnGossipSelect(Player* player, Creature* creature, uint32 /*sender*/, uint32 action) override - { - player->PlayerTalkClass->ClearMenus(); - switch (action) - { - case GOSSIP_ACTION_INFO_DEF: - //spellId is correct, however it gives flight a somewhat funny effect //TaxiPath 506. - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 32474, true); - break; - case GOSSIP_ACTION_INFO_DEF + 1: - player->CLOSE_GOSSIP_MENU(); - player->ActivateTaxiPathTo(627); //TaxiPath 627 (possibly 627+628(152->153->154->155)) - break; - case GOSSIP_ACTION_INFO_DEF + 2: - if (!player->HasItemCount(25853)) - player->SEND_GOSSIP_MENU(9780, creature->GetGUID()); - else - { - player->CLOSE_GOSSIP_MENU(); - player->ActivateTaxiPathTo(534); //TaxiPath 534 - } - break; - case GOSSIP_ACTION_INFO_DEF + 3: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 53335, true); //TaxiPath 1041 (Stormwind Harbor) - break; - case GOSSIP_ACTION_INFO_DEF + 4: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 33768, true); //TaxiPath 585 (Gateways Murket and Shaadraz) - break; - case GOSSIP_ACTION_INFO_DEF + 5: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 35069, true); //TaxiPath 612 (Taxi - Hellfire Peninsula - Expedition Point to Shatter Point) - break; - case GOSSIP_ACTION_INFO_DEF + 6: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 33899, true); //TaxiPath 589 (Aerial Assault Flight (Alliance)) - break; - case GOSSIP_ACTION_INFO_DEF + 7: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 35065, true); //TaxiPath 607 (Taxi - Hellfire Peninsula - Shatter Point to Beach Head) - break; - case GOSSIP_ACTION_INFO_DEF + 8: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 33659, true); //TaxiPath 584 (Gateways Murket and Shaadraz) - break; - case GOSSIP_ACTION_INFO_DEF + 9: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 33825, true); //TaxiPath 587 (Aerial Assault Flight (Horde)) - break; - case GOSSIP_ACTION_INFO_DEF + 10: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 34578, true); //TaxiPath 604 (Taxi - Reaver's Fall to Spinebreaker Ridge) - break; - case GOSSIP_ACTION_INFO_DEF + 11: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 41278, true); //TaxiPath 706 - break; - case GOSSIP_ACTION_INFO_DEF + 12: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 45071, true); //TaxiPath 779 - break; - case GOSSIP_ACTION_INFO_DEF + 13: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 45113, true); //TaxiPath 784 - break; - case GOSSIP_ACTION_INFO_DEF + 14: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 45353, true); //TaxiPath 788 - break; - case GOSSIP_ACTION_INFO_DEF + 15: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 34905, true); //TaxiPath 606 - break; - case GOSSIP_ACTION_INFO_DEF + 16: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 41279, true); //TaxiPath 705 (Taxi - Skettis to Skyguard Outpost) - break; - case GOSSIP_ACTION_INFO_DEF + 17: - player->CLOSE_GOSSIP_MENU(); - player->ActivateTaxiPathTo(882); - break; - case GOSSIP_ACTION_INFO_DEF + 18: - player->CLOSE_GOSSIP_MENU(); - player->ActivateTaxiPathTo(881); - break; - case GOSSIP_ACTION_INFO_DEF + 19: - player->CLOSE_GOSSIP_MENU(); - player->ActivateTaxiPathTo(878); - break; - case GOSSIP_ACTION_INFO_DEF + 20: - player->CLOSE_GOSSIP_MENU(); - player->ActivateTaxiPathTo(883); - break; - case GOSSIP_ACTION_INFO_DEF + 21: - player->CLOSE_GOSSIP_MENU(); - player->ActivateTaxiPathTo(880); - break; - case GOSSIP_ACTION_INFO_DEF + 22: - player->CLOSE_GOSSIP_MENU(); - player->ActivateTaxiPathTo(879); - break; - case GOSSIP_ACTION_INFO_DEF + 23: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 43074, true); //TaxiPath 736 - break; - case GOSSIP_ACTION_INFO_DEF + 24: - player->CLOSE_GOSSIP_MENU(); - //player->ActivateTaxiPathTo(738); - player->CastSpell(player, 43136, false); - break; - case GOSSIP_ACTION_INFO_DEF + 25: - player->CLOSE_GOSSIP_MENU(); - player->CastSpell(player, 42295, true); - break; - case GOSSIP_ACTION_INFO_DEF + 26: - player->CLOSE_GOSSIP_MENU(); - player->ActivateTaxiPathTo(494); - break; - case GOSSIP_ACTION_INFO_DEF + 27: - player->CLOSE_GOSSIP_MENU(); - player->ActivateTaxiPathTo(495); - break; - case GOSSIP_ACTION_INFO_DEF + 28: - player->CLOSE_GOSSIP_MENU(); - player->ActivateTaxiPathTo(496); - break; - } - - return true; - } -}; - -void AddSC_npc_taxi() -{ - new npc_taxi; -} diff --git a/src/server/scripts/World/npcs_special.cpp b/src/server/scripts/World/npcs_special.cpp index 22eabd3dd65..80b4fac4333 100644 --- a/src/server/scripts/World/npcs_special.cpp +++ b/src/server/scripts/World/npcs_special.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2006-2009 ScriptDev2 <https://scriptdev2.svn.sourceforge.net/> * * This program is free software; you can redistribute it and/or modify it @@ -38,6 +38,8 @@ npc_snake_trap_serpents 80% AI for snakes that summoned by Snake Trap npc_shadowfiend 100% restore 5% of owner's mana when shadowfiend die from damage npc_locksmith 75% list of keys needs to be confirmed npc_firework 100% NPC's summoned by rockets and rocket clusters, for making them cast visual +npc_train_wrecker 100% Wind-Up Train Wrecker that kills train set +npc_egbert 100% Egbert run's around EndContentData */ #include "ScriptMgr.h" @@ -56,6 +58,7 @@ EndContentData */ #include "SpellHistory.h" #include "SpellAuras.h" #include "Pet.h" +#include "PetAI.h" #include "CreatureTextMgr.h" #include "SmartAI.h" @@ -519,6 +522,67 @@ public: }; /*###### +## npc_torch_tossing_target_bunny_controller +######*/ + +enum TorchTossingTarget +{ + NPC_TORCH_TOSSING_TARGET_BUNNY = 25535, + SPELL_TARGET_INDICATOR = 45723 +}; + +class npc_torch_tossing_target_bunny_controller : public CreatureScript +{ +public: + npc_torch_tossing_target_bunny_controller() : CreatureScript("npc_torch_tossing_target_bunny_controller") { } + + struct npc_torch_tossing_target_bunny_controllerAI : public ScriptedAI + { + npc_torch_tossing_target_bunny_controllerAI(Creature* creature) : ScriptedAI(creature) + { + _targetTimer = 3000; + } + + ObjectGuid DoSearchForTargets(ObjectGuid lastTargetGUID) + { + std::list<Creature*> targets; + me->GetCreatureListWithEntryInGrid(targets, NPC_TORCH_TOSSING_TARGET_BUNNY, 60.0f); + targets.remove_if([lastTargetGUID](Creature* creature) { return creature->GetGUID() == lastTargetGUID; }); + + if (!targets.empty()) + { + _lastTargetGUID = Trinity::Containers::SelectRandomContainerElement(targets)->GetGUID(); + + return _lastTargetGUID; + } + return ObjectGuid::Empty; + } + + void UpdateAI(uint32 diff) override + { + if (_targetTimer < diff) + { + if (Unit* target = ObjectAccessor::GetUnit(*me, DoSearchForTargets(_lastTargetGUID))) + target->CastSpell(target, SPELL_TARGET_INDICATOR, true); + + _targetTimer = 3000; + } + else + _targetTimer -= diff; + } + + private: + uint32 _targetTimer; + ObjectGuid _lastTargetGUID; + }; + + CreatureAI* GetAI(Creature* creature) const override + { + return new npc_torch_tossing_target_bunny_controllerAI(creature); + } +}; + +/*###### ## Triage quest ######*/ @@ -1422,7 +1486,6 @@ public: void Reset() override { me->SetControlled(true, UNIT_STATE_STUNNED);//disable rotate - me->ApplySpellImmune(0, IMMUNITY_EFFECT, SPELL_EFFECT_KNOCK_BACK, true);//imune to knock aways like blast wave _events.Reset(); _damageTimes.clear(); @@ -1432,9 +1495,9 @@ public: _events.ScheduleEvent(EVENT_TD_DESPAWN, 15000); } - void EnterEvadeMode() override + void EnterEvadeMode(EvadeReason why) override { - if (!_EnterEvadeMode()) + if (!_EnterEvadeMode(why)) return; Reset(); @@ -2130,7 +2193,7 @@ public: // Check if we are near Elune'ara lake south, if so try to summon Omen or a minion if (me->GetZoneId() == ZONE_MOONGLADE) { - if (!me->FindNearestCreature(NPC_OMEN, 100.0f, false) && me->GetDistance2d(omenSummonPos.GetPositionX(), omenSummonPos.GetPositionY()) <= 100.0f) + if (!me->FindNearestCreature(NPC_OMEN, 100.0f) && me->GetDistance2d(omenSummonPos.GetPositionX(), omenSummonPos.GetPositionY()) <= 100.0f) { switch (urand(0, 9)) { @@ -2387,12 +2450,300 @@ class npc_stable_master : public CreatureScript } }; +enum TrainWrecker +{ + GO_TOY_TRAIN = 193963, + SPELL_TOY_TRAIN_PULSE = 61551, + SPELL_WRECK_TRAIN = 62943, + ACTION_WRECKED = 1, + EVENT_DO_JUMP = 1, + EVENT_DO_FACING = 2, + EVENT_DO_WRECK = 3, + EVENT_DO_DANCE = 4, + MOVEID_CHASE = 1, + MOVEID_JUMP = 2 +}; +class npc_train_wrecker : public CreatureScript +{ + public: + npc_train_wrecker() : CreatureScript("npc_train_wrecker") { } + + struct npc_train_wreckerAI : public NullCreatureAI + { + npc_train_wreckerAI(Creature* creature) : NullCreatureAI(creature), _isSearching(true), _nextAction(0), _timer(1 * IN_MILLISECONDS) { } + + GameObject* VerifyTarget() const + { + if (GameObject* target = ObjectAccessor::GetGameObject(*me, _target)) + return target; + me->HandleEmoteCommand(EMOTE_ONESHOT_RUDE); + me->DespawnOrUnsummon(3 * IN_MILLISECONDS); + return nullptr; + } + + void UpdateAI(uint32 diff) override + { + if (_isSearching) + { + if (diff < _timer) + _timer -= diff; + else + { + if (GameObject* target = me->FindNearestGameObject(GO_TOY_TRAIN, 15.0f)) + { + _isSearching = false; + _target = target->GetGUID(); + me->SetWalk(true); + me->GetMotionMaster()->MovePoint(MOVEID_CHASE, target->GetNearPosition(3.0f, target->GetAngle(me))); + } + else + _timer = 3 * IN_MILLISECONDS; + } + } + else + { + switch (_nextAction) + { + case EVENT_DO_JUMP: + if (GameObject* target = VerifyTarget()) + me->GetMotionMaster()->MoveJump(*target, 5.0, 10.0, MOVEID_JUMP); + _nextAction = 0; + break; + case EVENT_DO_FACING: + if (GameObject* target = VerifyTarget()) + { + me->SetFacingTo(target->GetOrientation()); + me->HandleEmoteCommand(EMOTE_ONESHOT_ATTACK1H); + _timer = 1.5 * IN_MILLISECONDS; + _nextAction = EVENT_DO_WRECK; + } + else + _nextAction = 0; + break; + case EVENT_DO_WRECK: + if (diff < _timer) + { + _timer -= diff; + break; + } + if (GameObject* target = VerifyTarget()) + { + me->CastSpell(target, SPELL_WRECK_TRAIN, false); + target->AI()->DoAction(ACTION_WRECKED); + _timer = 2 * IN_MILLISECONDS; + _nextAction = EVENT_DO_DANCE; + } + else + _nextAction = 0; + break; + case EVENT_DO_DANCE: + if (diff < _timer) + { + _timer -= diff; + break; + } + me->SetUInt32Value(UNIT_NPC_EMOTESTATE, EMOTE_ONESHOT_DANCE); + me->DespawnOrUnsummon(5 * IN_MILLISECONDS); + _nextAction = 0; + break; + default: + break; + } + } + } + + void MovementInform(uint32 /*type*/, uint32 id) override + { + if (id == MOVEID_CHASE) + _nextAction = EVENT_DO_JUMP; + else if (id == MOVEID_JUMP) + _nextAction = EVENT_DO_FACING; + } + + private: + bool _isSearching; + uint8 _nextAction; + uint32 _timer; + ObjectGuid _target; + }; + + CreatureAI* GetAI(Creature* creature) const override + { + return new npc_train_wreckerAI(creature); + } +}; + +enum EgbertMisc +{ + SPELL_EGBERT = 40669, + EVENT_RETURN = 3 +}; + +class npc_egbert : public CreatureScript +{ +public: + npc_egbert() : CreatureScript("npc_egbert") {} + + struct npc_egbertAI : public NullCreatureAI + { + npc_egbertAI(Creature* creature) : NullCreatureAI(creature) + { + if (Unit* owner = me->GetCharmerOrOwner()) + if (owner->GetMap()->GetEntry()->addon > 1) + me->SetCanFly(true); + } + + void Reset() override + { + _events.Reset(); + if (Unit* owner = me->GetCharmerOrOwner()) + me->GetMotionMaster()->MoveFollow(owner, PET_FOLLOW_DIST, me->GetFollowAngle()); + } + + void EnterEvadeMode(EvadeReason why) override + { + if (!_EnterEvadeMode(why)) + return; + + Reset(); + } + + void UpdateAI(uint32 diff) override + { + _events.Update(diff); + + if (Unit* owner = me->GetCharmerOrOwner()) + { + if (!me->IsWithinDist(owner, 40.f)) + { + me->RemoveAura(SPELL_EGBERT); + me->GetMotionMaster()->MoveFollow(owner, PET_FOLLOW_DIST, me->GetFollowAngle()); + } + } + + if (me->HasAura(SPELL_EGBERT)) + _events.ScheduleEvent(EVENT_RETURN, urandms(5, 20)); + + while (uint32 eventId = _events.ExecuteEvent()) + { + switch (eventId) + { + case EVENT_RETURN: + me->RemoveAura(SPELL_EGBERT); + break; + default: + break; + } + } + } + private: + EventMap _events; + }; + + CreatureAI* GetAI(Creature* creature) const + { + return new npc_egbertAI(creature); + } +}; + +enum PandarenMonkMisc +{ + SPELL_PANDAREN_MONK = 69800, + EVENT_FOCUS = 1, + EVENT_EMOTE = 2, + EVENT_FOLLOW = 3, + EVENT_DRINK = 4 +}; + +class npc_pandaren_monk : public CreatureScript +{ +public: + npc_pandaren_monk() : CreatureScript("npc_pandaren_monk") {} + + struct npc_pandaren_monkAI : public NullCreatureAI + { + npc_pandaren_monkAI(Creature* creature) : NullCreatureAI(creature) { } + + void Reset() override + { + _events.Reset(); + _events.ScheduleEvent(EVENT_FOCUS, 1000); + } + + void EnterEvadeMode(EvadeReason why) override + { + if (!_EnterEvadeMode(why)) + return; + + Reset(); + } + + void ReceiveEmote(Player* /*player*/, uint32 emote) override + { + me->InterruptSpell(CURRENT_CHANNELED_SPELL); + me->StopMoving(); + + switch (emote) + { + case TEXT_EMOTE_BOW: + _events.ScheduleEvent(EVENT_FOCUS, 1000); + break; + case TEXT_EMOTE_DRINK: + _events.ScheduleEvent(EVENT_DRINK, 1000); + break; + } + } + + void UpdateAI(uint32 diff) override + { + _events.Update(diff); + + if (Unit* owner = me->GetCharmerOrOwner()) + if (!me->IsWithinDist(owner, 30.f)) + me->InterruptSpell(CURRENT_CHANNELED_SPELL); + + while (uint32 eventId = _events.ExecuteEvent()) + { + switch (eventId) + { + case EVENT_FOCUS: + if (Unit* owner = me->GetCharmerOrOwner()) + me->SetFacingToObject(owner); + _events.ScheduleEvent(EVENT_EMOTE, 1000); + break; + case EVENT_EMOTE: + me->HandleEmoteCommand(EMOTE_ONESHOT_BOW); + _events.ScheduleEvent(EVENT_FOLLOW, 1000); + break; + case EVENT_FOLLOW: + if (Unit* owner = me->GetCharmerOrOwner()) + me->GetMotionMaster()->MoveFollow(owner, PET_FOLLOW_DIST, PET_FOLLOW_ANGLE); + break; + case EVENT_DRINK: + me->CastSpell(me, SPELL_PANDAREN_MONK, false); + break; + default: + break; + } + } + } + private: + EventMap _events; + }; + + CreatureAI* GetAI(Creature* creature) const + { + return new npc_pandaren_monkAI(creature); + } +}; + void AddSC_npcs_special() { new npc_air_force_bots(); new npc_lunaclaw_spirit(); new npc_chicken_cluck(); new npc_dancing_flames(); + new npc_torch_tossing_target_bunny_controller(); new npc_doctor(); new npc_injured_patient(); new npc_garments_of_quests(); @@ -2410,4 +2761,7 @@ void AddSC_npcs_special() new npc_spring_rabbit(); new npc_imp_in_a_ball(); new npc_stable_master(); + new npc_train_wrecker(); + new npc_egbert(); + new npc_pandaren_monk(); } diff --git a/src/server/shared/CMakeLists.txt b/src/server/shared/CMakeLists.txt index b43abb60481..b6e5c8b1c6f 100644 --- a/src/server/shared/CMakeLists.txt +++ b/src/server/shared/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/shared/DataStores/DBCFileLoader.cpp b/src/server/shared/DataStores/DBCFileLoader.cpp index f1a93b500d3..04faa320ef9 100644 --- a/src/server/shared/DataStores/DBCFileLoader.cpp +++ b/src/server/shared/DataStores/DBCFileLoader.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/DataStores/DBCFileLoader.h b/src/server/shared/DataStores/DBCFileLoader.h index 1f34f6a4bf1..00b1ee54a4a 100644 --- a/src/server/shared/DataStores/DBCFileLoader.h +++ b/src/server/shared/DataStores/DBCFileLoader.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/DataStores/DBCStore.h b/src/server/shared/DataStores/DBCStore.h index 1cb67a4235e..b93bbdaea12 100644 --- a/src/server/shared/DataStores/DBCStore.h +++ b/src/server/shared/DataStores/DBCStore.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Dynamic/FactoryHolder.h b/src/server/shared/Dynamic/FactoryHolder.h index c218af9e947..06fd76db09a 100644 --- a/src/server/shared/Dynamic/FactoryHolder.h +++ b/src/server/shared/Dynamic/FactoryHolder.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Dynamic/LinkedList.h b/src/server/shared/Dynamic/LinkedList.h index 1971af91419..94f67cac909 100644 --- a/src/server/shared/Dynamic/LinkedList.h +++ b/src/server/shared/Dynamic/LinkedList.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Dynamic/LinkedReference/RefManager.h b/src/server/shared/Dynamic/LinkedReference/RefManager.h index 81b67c6f050..9dbab4f338e 100644 --- a/src/server/shared/Dynamic/LinkedReference/RefManager.h +++ b/src/server/shared/Dynamic/LinkedReference/RefManager.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Dynamic/LinkedReference/Reference.h b/src/server/shared/Dynamic/LinkedReference/Reference.h index 8e3a0854a1d..4a473b0f2ac 100644 --- a/src/server/shared/Dynamic/LinkedReference/Reference.h +++ b/src/server/shared/Dynamic/LinkedReference/Reference.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Dynamic/ObjectRegistry.h b/src/server/shared/Dynamic/ObjectRegistry.h index 1eb9368be61..9db6381c9b8 100644 --- a/src/server/shared/Dynamic/ObjectRegistry.h +++ b/src/server/shared/Dynamic/ObjectRegistry.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Dynamic/TypeContainer.h b/src/server/shared/Dynamic/TypeContainer.h index 7addf8028bf..17ca8c24c43 100644 --- a/src/server/shared/Dynamic/TypeContainer.h +++ b/src/server/shared/Dynamic/TypeContainer.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Dynamic/TypeContainerFunctions.h b/src/server/shared/Dynamic/TypeContainerFunctions.h index bd6d4c348ba..c4071b76590 100644 --- a/src/server/shared/Dynamic/TypeContainerFunctions.h +++ b/src/server/shared/Dynamic/TypeContainerFunctions.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Dynamic/TypeContainerVisitor.h b/src/server/shared/Dynamic/TypeContainerVisitor.h index e10a2331e25..7656e0bb99b 100644 --- a/src/server/shared/Dynamic/TypeContainerVisitor.h +++ b/src/server/shared/Dynamic/TypeContainerVisitor.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Dynamic/TypeList.h b/src/server/shared/Dynamic/TypeList.h index f0355929700..63f1d8d372c 100644 --- a/src/server/shared/Dynamic/TypeList.h +++ b/src/server/shared/Dynamic/TypeList.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Networking/AsyncAcceptor.h b/src/server/shared/Networking/AsyncAcceptor.h index 832e408db34..260e1c8ea11 100644 --- a/src/server/shared/Networking/AsyncAcceptor.h +++ b/src/server/shared/Networking/AsyncAcceptor.h @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/shared/Networking/MessageBuffer.h b/src/server/shared/Networking/MessageBuffer.h index 5f9af33a45d..189a56f18b6 100644 --- a/src/server/shared/Networking/MessageBuffer.h +++ b/src/server/shared/Networking/MessageBuffer.h @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/shared/Networking/NetworkThread.h b/src/server/shared/Networking/NetworkThread.h index 05ca99ea6a6..ac216838bce 100644 --- a/src/server/shared/Networking/NetworkThread.h +++ b/src/server/shared/Networking/NetworkThread.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/shared/Networking/Socket.h b/src/server/shared/Networking/Socket.h index 3f588298617..a2f57b5029e 100644 --- a/src/server/shared/Networking/Socket.h +++ b/src/server/shared/Networking/Socket.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/shared/Networking/SocketMgr.h b/src/server/shared/Networking/SocketMgr.h index 2078ae90c62..ce5bc2d8fc2 100644 --- a/src/server/shared/Networking/SocketMgr.h +++ b/src/server/shared/Networking/SocketMgr.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/shared/Packets/ByteBuffer.cpp b/src/server/shared/Packets/ByteBuffer.cpp index 119aca072f2..0aa94f9d06c 100644 --- a/src/server/shared/Packets/ByteBuffer.cpp +++ b/src/server/shared/Packets/ByteBuffer.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Packets/ByteBuffer.h b/src/server/shared/Packets/ByteBuffer.h index 083f1d6e329..5ebe5258a44 100644 --- a/src/server/shared/Packets/ByteBuffer.h +++ b/src/server/shared/Packets/ByteBuffer.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Packets/WorldPacket.h b/src/server/shared/Packets/WorldPacket.h index 6c31ddf8f34..191dd084766 100644 --- a/src/server/shared/Packets/WorldPacket.h +++ b/src/server/shared/Packets/WorldPacket.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Service/ServiceWin32.cpp b/src/server/shared/Service/ServiceWin32.cpp index 3e5e416b1a3..b6a1682993b 100644 --- a/src/server/shared/Service/ServiceWin32.cpp +++ b/src/server/shared/Service/ServiceWin32.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/shared/Service/ServiceWin32.h b/src/server/shared/Service/ServiceWin32.h index 9d9c732cd20..3d67bfe5445 100644 --- a/src/server/shared/Service/ServiceWin32.h +++ b/src/server/shared/Service/ServiceWin32.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/worldserver/CMakeLists.txt b/src/server/worldserver/CMakeLists.txt index 78f39e077a1..535383ac605 100644 --- a/src/server/worldserver/CMakeLists.txt +++ b/src/server/worldserver/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/server/worldserver/CommandLine/CliRunnable.cpp b/src/server/worldserver/CommandLine/CliRunnable.cpp index 3901e17f9c2..9936143a88e 100644 --- a/src/server/worldserver/CommandLine/CliRunnable.cpp +++ b/src/server/worldserver/CommandLine/CliRunnable.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/worldserver/CommandLine/CliRunnable.h b/src/server/worldserver/CommandLine/CliRunnable.h index 66617c515a1..0ac91bbeb16 100644 --- a/src/server/worldserver/CommandLine/CliRunnable.h +++ b/src/server/worldserver/CommandLine/CliRunnable.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/worldserver/Main.cpp b/src/server/worldserver/Main.cpp index ab132621437..53c5f250851 100644 --- a/src/server/worldserver/Main.cpp +++ b/src/server/worldserver/Main.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/worldserver/RemoteAccess/RASession.cpp b/src/server/worldserver/RemoteAccess/RASession.cpp index 2d383d685a1..59e7b138c48 100644 --- a/src/server/worldserver/RemoteAccess/RASession.cpp +++ b/src/server/worldserver/RemoteAccess/RASession.cpp @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/worldserver/RemoteAccess/RASession.h b/src/server/worldserver/RemoteAccess/RASession.h index efd2106fdd1..b3271c8033c 100644 --- a/src/server/worldserver/RemoteAccess/RASession.h +++ b/src/server/worldserver/RemoteAccess/RASession.h @@ -1,5 +1,5 @@ /* -* Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +* Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/server/worldserver/TCSoap/TCSoap.cpp b/src/server/worldserver/TCSoap/TCSoap.cpp index 18b9d07a8fd..df0819c4513 100644 --- a/src/server/worldserver/TCSoap/TCSoap.cpp +++ b/src/server/worldserver/TCSoap/TCSoap.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/worldserver/TCSoap/TCSoap.h b/src/server/worldserver/TCSoap/TCSoap.h index 70d319b0670..c6871f92137 100644 --- a/src/server/worldserver/TCSoap/TCSoap.h +++ b/src/server/worldserver/TCSoap/TCSoap.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <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 diff --git a/src/server/worldserver/worldserver.conf.dist b/src/server/worldserver/worldserver.conf.dist index 840b819fe99..217995cb88a 100644 --- a/src/server/worldserver/worldserver.conf.dist +++ b/src/server/worldserver/worldserver.conf.dist @@ -406,6 +406,24 @@ CleanCharacterDB = 0 PersistentCharacterCleanFlags = 0 # +# Auction.GetAllScanDelay +# Description: Sets the minimum time in seconds, a single player character can perform a getall scan. +# The value is only held in memory so a server restart will clear it. +# Setting this to zero, will disable GetAll functions completely. +# Default: 900 - (GetAll scan limited to once every 15mins per player character) + +Auction.GetAllScanDelay = 900 + +# +# Auction.SearchDelay +# Description: Sets the minimum time in milliseconds (seconds x 1000), that the client must wait between +# auction search operations. This can be increased if somehow Auction House activity is causing +# too much load. +# Default: 300 - (Time delay between auction searches set to 0.3secs) + +Auction.SearchDelay = 300 + +# ################################################################################################### ################################################################################################### @@ -3190,6 +3208,46 @@ AuctionHouseBot.forceIncludeItems = "" AuctionHouseBot.forceExcludeItems = "" # +# AuctionHouseBot.Class.RandomStackRatio.* +# Description: Used to determine how often a stack of the class will be single or randomly-size stacked when posted +# Value needs to be between 0 and 100, no decimal. Anything higher than 100 will be treated as 100 +# Examples: 100 = stacks will always be random in size +# 50 = half the time the stacks are random, the other half being single stack +# 0 = stacks will always single size +# Default: Consumable: 20 (20% random stack size, 80% single stack size) +# Container: 0 (100% single stack size) +# Weapon: 0 (100% single stack size) +# Gem: 20 (20% random stack size, 80% single stack size) +# Armor: 0 (100% single stack size) +# Reagent: 100 (100% random stack size) +# Projectile: 100 (100% random stack size) +# TradeGood: 50 (50% random stack size, 50% single stack size) +# Generic: 100 (100% random stack size) +# Recipe: 0 (100% single stack size) +# Quiver: 0 (100% single stack size) +# Quest: 100 (100% random stack size) +# Key: 100 (100% random stack size) +# Misc: 100 (100% random stack size) +# Glyph: 0 (100% single stack size) +# + +AuctionHouseBot.Class.RandomStackRatio.Consumable = 20 +AuctionHouseBot.Class.RandomStackRatio.Container = 0 +AuctionHouseBot.Class.RandomStackRatio.Weapon = 0 +AuctionHouseBot.Class.RandomStackRatio.Gem = 20 +AuctionHouseBot.Class.RandomStackRatio.Armor = 0 +AuctionHouseBot.Class.RandomStackRatio.Reagent = 100 +AuctionHouseBot.Class.RandomStackRatio.Projectile = 100 +AuctionHouseBot.Class.RandomStackRatio.TradeGood = 50 +AuctionHouseBot.Class.RandomStackRatio.Generic = 100 +AuctionHouseBot.Class.RandomStackRatio.Recipe = 0 +AuctionHouseBot.Class.RandomStackRatio.Quiver = 0 +AuctionHouseBot.Class.RandomStackRatio.Quest = 100 +AuctionHouseBot.Class.RandomStackRatio.Key = 100 +AuctionHouseBot.Class.RandomStackRatio.Misc = 100 +AuctionHouseBot.Class.RandomStackRatio.Glyph = 0 + +# ################################################################################################### ################################################################################################### diff --git a/src/server/worldserver/worldserver.rc b/src/server/worldserver/worldserver.rc index 9af2db46ce0..a265b032bdc 100644 --- a/src/server/worldserver/worldserver.rc +++ b/src/server/worldserver/worldserver.rc @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2009 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/CMakeLists.txt b/src/tools/CMakeLists.txt index 350c8becb35..4e787eb3d7e 100644 --- a/src/tools/CMakeLists.txt +++ b/src/tools/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/tools/map_extractor/CMakeLists.txt b/src/tools/map_extractor/CMakeLists.txt index b10956b3264..d0f3e42cef8 100644 --- a/src/tools/map_extractor/CMakeLists.txt +++ b/src/tools/map_extractor/CMakeLists.txt @@ -1,5 +1,5 @@ # Copyright (C) 2005-2009 MaNGOS project <http://getmangos.com/> -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without @@ -14,6 +14,7 @@ file(GLOB_RECURSE mapextractor_SRCS *.cpp *.h) set(include_Dirs ${CMAKE_SOURCE_DIR} ${CMAKE_SOURCE_DIR}/dep/cppformat + ${CMAKE_SOURCE_DIR}/dep/g3dlite/include ${CMAKE_SOURCE_DIR}/dep/libmpq ${CMAKE_SOURCE_DIR}/src/common ${CMAKE_SOURCE_DIR}/src/common/Utilities @@ -37,6 +38,7 @@ add_executable(mapextractor target_link_libraries(mapextractor common format + g3dlib mpq ${BZIP2_LIBRARIES} ${ZLIB_LIBRARIES} diff --git a/src/tools/map_extractor/System.cpp b/src/tools/map_extractor/System.cpp index c0497a1cefb..f3a761fd437 100644 --- a/src/tools/map_extractor/System.cpp +++ b/src/tools/map_extractor/System.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -31,6 +31,7 @@ #include "adt.h" #include "wdt.h" +#include <G3D/Plane.h> #include <boost/filesystem.hpp> extern ArchiveSet gOpenArchives; @@ -42,12 +43,10 @@ typedef struct } map_id; map_id *map_ids; -uint16 *areas; uint16 *LiqType; #define MAX_PATH_LENGTH 128 char output_path[MAX_PATH_LENGTH] = "."; char input_path[MAX_PATH_LENGTH] = "."; -uint32 maxAreaId = 0; // ************************************************** // Extractor options @@ -231,30 +230,6 @@ uint32 ReadMapDBC() return map_count; } -void ReadAreaTableDBC() -{ - printf("Read AreaTable.dbc file..."); - DBCFile dbc("DBFilesClient\\AreaTable.dbc"); - - if(!dbc.open()) - { - printf("Fatal error: Invalid AreaTable.dbc file format!\n"); - exit(1); - } - - size_t area_count = dbc.getRecordCount(); - size_t maxid = dbc.getMaxId(); - areas = new uint16[maxid + 1]; - memset(areas, 0xff, (maxid + 1) * sizeof(uint16)); - - for(uint32 x = 0; x < area_count; ++x) - areas[dbc.getRecord(x).getUInt(0)] = dbc.getRecord(x).getUInt(3); - - maxAreaId = dbc.getMaxId(); - - printf("Done! (" SZFMTD " areas loaded)\n", area_count); -} - void ReadLiquidTypeTableDBC() { printf("Read LiquidType.dbc file..."); @@ -282,7 +257,7 @@ void ReadLiquidTypeTableDBC() // Map file format data static char const* MAP_MAGIC = "MAPS"; -static char const* MAP_VERSION_MAGIC = "v1.3"; +static char const* MAP_VERSION_MAGIC = "v1.8"; static char const* MAP_AREA_MAGIC = "AREA"; static char const* MAP_HEIGHT_MAGIC = "MHGT"; static char const* MAP_LIQUID_MAGIC = "MLIQ"; @@ -311,9 +286,10 @@ struct map_areaHeader uint16 gridArea; }; -#define MAP_HEIGHT_NO_HEIGHT 0x0001 -#define MAP_HEIGHT_AS_INT16 0x0002 -#define MAP_HEIGHT_AS_INT8 0x0004 +#define MAP_HEIGHT_NO_HEIGHT 0x0001 +#define MAP_HEIGHT_AS_INT16 0x0002 +#define MAP_HEIGHT_AS_INT8 0x0004 +#define MAP_HEIGHT_HAS_FLIGHT_BOUNDS 0x0008 struct map_heightHeader { @@ -358,7 +334,7 @@ float selectUInt16StepStore(float maxDiff) return 65535 / maxDiff; } // Temporary grid data store -uint16 area_flags[ADT_CELLS_PER_GRID][ADT_CELLS_PER_GRID]; +uint16 area_ids[ADT_CELLS_PER_GRID][ADT_CELLS_PER_GRID]; float V8[ADT_GRID_SIZE][ADT_GRID_SIZE]; float V9[ADT_GRID_SIZE+1][ADT_GRID_SIZE+1]; @@ -372,6 +348,9 @@ uint8 liquid_flags[ADT_CELLS_PER_GRID][ADT_CELLS_PER_GRID]; bool liquid_show[ADT_GRID_SIZE][ADT_GRID_SIZE]; float liquid_height[ADT_GRID_SIZE+1][ADT_GRID_SIZE+1]; +int16 flight_box_max[3][3]; +int16 flight_box_min[3][3]; + bool ConvertADT(std::string const& inputPath, std::string const& outputPath, int /*cell_y*/, int /*cell_x*/, uint32 build) { ADT_file adt; @@ -397,34 +376,20 @@ bool ConvertADT(std::string const& inputPath, std::string const& outputPath, int map.buildMagic = build; // Get area flags data - for (int i=0;i<ADT_CELLS_PER_GRID;i++) - { - for(int j=0;j<ADT_CELLS_PER_GRID;j++) - { - adt_MCNK * cell = cells->getMCNK(i,j); - uint32 areaid = cell->areaid; - if(areaid && areaid <= maxAreaId) - { - if(areas[areaid] != 0xffff) - { - area_flags[i][j] = areas[areaid]; - continue; - } - printf("File: %s\nCan't find area flag for areaid %u [%d, %d].\n", inputPath.c_str(), areaid, cell->ix, cell->iy); - } - area_flags[i][j] = 0xffff; - } - } + for (int i = 0; i < ADT_CELLS_PER_GRID; i++) + for (int j = 0; j < ADT_CELLS_PER_GRID; j++) + area_ids[i][j] = cells->getMCNK(i, j)->areaid; + //============================================ // Try pack area data //============================================ bool fullAreaData = false; - uint32 areaflag = area_flags[0][0]; - for (int y=0;y<ADT_CELLS_PER_GRID;y++) + uint32 areaId = area_ids[0][0]; + for (int y = 0; y < ADT_CELLS_PER_GRID; ++y) { - for(int x=0;x<ADT_CELLS_PER_GRID;x++) + for (int x = 0; x < ADT_CELLS_PER_GRID; ++x) { - if(area_flags[y][x]!=areaflag) + if (area_ids[y][x] != areaId) { fullAreaData = true; break; @@ -441,12 +406,12 @@ bool ConvertADT(std::string const& inputPath, std::string const& outputPath, int if (fullAreaData) { areaHeader.gridArea = 0; - map.areaMapSize+=sizeof(area_flags); + map.areaMapSize += sizeof(area_ids); } else { areaHeader.flags |= MAP_AREA_NO_AREA; - areaHeader.gridArea = static_cast<uint16>(areaflag); + areaHeader.gridArea = static_cast<uint16>(areaId); } // @@ -561,6 +526,14 @@ bool ConvertADT(std::string const& inputPath, std::string const& outputPath, int maxHeight = CONF_use_minHeight; } + bool hasFlightBox = false; + if (adt_MFBO* mfbo = adt.a_grid->getMFBO()) + { + memcpy(flight_box_max, &mfbo->max, sizeof(flight_box_max)); + memcpy(flight_box_min, &mfbo->min, sizeof(flight_box_min)); + hasFlightBox = true; + } + map.heightMapOffset = map.areaMapOffset + map.areaMapSize; map.heightMapSize = sizeof(map_heightHeader); @@ -577,6 +550,12 @@ bool ConvertADT(std::string const& inputPath, std::string const& outputPath, int if (CONF_allow_float_to_int && (maxHeight - minHeight) < CONF_flat_height_delta_limit) heightHeader.flags |= MAP_HEIGHT_NO_HEIGHT; + if (hasFlightBox) + { + heightHeader.flags |= MAP_HEIGHT_HAS_FLIGHT_BOUNDS; + map.heightMapSize += sizeof(flight_box_max) + sizeof(flight_box_min); + } + // Try store as packed in uint16 or uint8 values if (!(heightHeader.flags & MAP_HEIGHT_NO_HEIGHT)) { @@ -875,8 +854,8 @@ bool ConvertADT(std::string const& inputPath, std::string const& outputPath, int outFile.write(reinterpret_cast<const char*>(&map), sizeof(map)); // Store area data outFile.write(reinterpret_cast<const char*>(&areaHeader), sizeof(areaHeader)); - if (!(areaHeader.flags&MAP_AREA_NO_AREA)) - outFile.write(reinterpret_cast<const char*>(area_flags), sizeof(area_flags)); + if (!(areaHeader.flags & MAP_AREA_NO_AREA)) + outFile.write(reinterpret_cast<const char*>(area_ids), sizeof(area_ids)); // Store height data outFile.write(reinterpret_cast<const char*>(&heightHeader), sizeof(heightHeader)); @@ -899,6 +878,12 @@ bool ConvertADT(std::string const& inputPath, std::string const& outputPath, int } } + if (heightHeader.flags & MAP_HEIGHT_HAS_FLIGHT_BOUNDS) + { + outFile.write(reinterpret_cast<char*>(flight_box_max), sizeof(flight_box_max)); + outFile.write(reinterpret_cast<char*>(flight_box_min), sizeof(flight_box_min)); + } + // Store liquid data if need if (map.liquidMapOffset) { @@ -935,7 +920,6 @@ void ExtractMapsFromMpq(uint32 build) uint32 map_count = ReadMapDBC(); - ReadAreaTableDBC(); ReadLiquidTypeTableDBC(); std::string path = output_path; @@ -972,8 +956,7 @@ void ExtractMapsFromMpq(uint32 build) } } printf("\n"); - delete [] areas; - delete [] map_ids; + delete[] map_ids; } bool ExtractFile( char const* mpq_name, std::string const& filename ) diff --git a/src/tools/map_extractor/adt.cpp b/src/tools/map_extractor/adt.cpp index 0667f8c6330..e97b40475d0 100644 --- a/src/tools/map_extractor/adt.cpp +++ b/src/tools/map_extractor/adt.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -21,15 +21,16 @@ #include "adt.h" // Helper -int holetab_h[4] = {0x1111, 0x2222, 0x4444, 0x8888}; -int holetab_v[4] = {0x000F, 0x00F0, 0x0F00, 0xF000}; +int holetab_h[4] = { 0x1111, 0x2222, 0x4444, 0x8888 }; +int holetab_v[4] = { 0x000F, 0x00F0, 0x0F00, 0xF000 }; -u_map_fcc MHDRMagic = { {'R','D','H','M'} }; -u_map_fcc MCINMagic = { {'N','I','C','M'} }; -u_map_fcc MH2OMagic = { {'O','2','H','M'} }; -u_map_fcc MCNKMagic = { {'K','N','C','M'} }; -u_map_fcc MCVTMagic = { {'T','V','C','M'} }; -u_map_fcc MCLQMagic = { {'Q','L','C','M'} }; +u_map_fcc MHDRMagic = { { 'R','D','H','M' } }; +u_map_fcc MCINMagic = { { 'N','I','C','M' } }; +u_map_fcc MH2OMagic = { { 'O','2','H','M' } }; +u_map_fcc MCNKMagic = { { 'K','N','C','M' } }; +u_map_fcc MCVTMagic = { { 'T','V','C','M' } }; +u_map_fcc MCLQMagic = { { 'Q','L','C','M' } }; +u_map_fcc MFBOMagic = { { 'O','B','F','M' } }; bool isHole(int holes, int i, int j) { @@ -81,7 +82,7 @@ bool adt_MHDR::prepareLoadedData() if (fcc != MHDRMagic.fcc) return false; - if (size!=sizeof(adt_MHDR)-8) + if (size != sizeof(adt_MHDR) - 8) return false; // Check and prepare MCIN @@ -92,6 +93,9 @@ bool adt_MHDR::prepareLoadedData() if (offsMH2O && !getMH2O()->prepareLoadedData()) return false; + if (offsMFBO && flags & 1 && !getMFBO()->prepareLoadedData()) + return false; + return true; } @@ -154,3 +158,8 @@ bool adt_MCLQ::prepareLoadedData() return true; } + +bool adt_MFBO::prepareLoadedData() +{ + return fcc == MFBOMagic.fcc; +} diff --git a/src/tools/map_extractor/adt.h b/src/tools/map_extractor/adt.h index cad773fbee4..30389939f38 100644 --- a/src/tools/map_extractor/adt.h +++ b/src/tools/map_extractor/adt.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -263,6 +263,28 @@ public: }; // +// Adt file min/max height chunk +// +class adt_MFBO +{ + union + { + uint32 fcc; + char fcc_txt[4]; + }; +public: + uint32 size; + struct plane + { + int16 coords[9]; + }; + plane max; + plane min; + + bool prepareLoadedData(); +}; + +// // Adt file header chunk // class adt_MHDR @@ -274,12 +296,12 @@ class adt_MHDR public: uint32 size; - uint32 pad; + uint32 flags; uint32 offsMCIN; // MCIN - uint32 offsTex; // MTEX - uint32 offsModels; // MMDX - uint32 offsModelsIds; // MMID - uint32 offsMapObejcts; // MWMO + uint32 offsTex; // MTEX + uint32 offsModels; // MMDX + uint32 offsModelsIds; // MMID + uint32 offsMapObejcts; // MWMO uint32 offsMapObejctsIds; // MWID uint32 offsDoodsDef; // MDDF uint32 offsObjectsDef; // MODF @@ -291,9 +313,22 @@ public: uint32 data4; uint32 data5; bool prepareLoadedData(); - adt_MCIN *getMCIN(){ return (adt_MCIN *)((uint8 *)&pad+offsMCIN);} - adt_MH2O *getMH2O(){ return offsMH2O ? (adt_MH2O *)((uint8 *)&pad+offsMH2O) : 0;} - + adt_MCIN* getMCIN() + { + return reinterpret_cast<adt_MCIN*>(reinterpret_cast<uint8*>(&flags) + offsMCIN); + } + adt_MH2O* getMH2O() + { + if (offsMH2O) + return reinterpret_cast<adt_MH2O*>(reinterpret_cast<uint8*>(&flags) + offsMH2O); + return nullptr; + } + adt_MFBO* getMFBO() + { + if (flags & 1 && offsMFBO) + return reinterpret_cast<adt_MFBO*>(reinterpret_cast<uint8*>(&flags) + offsMFBO); + return nullptr; + } }; class ADT_file : public FileLoader{ diff --git a/src/tools/map_extractor/dbcfile.cpp b/src/tools/map_extractor/dbcfile.cpp index d481a4902ef..1732c255536 100644 --- a/src/tools/map_extractor/dbcfile.cpp +++ b/src/tools/map_extractor/dbcfile.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/map_extractor/dbcfile.h b/src/tools/map_extractor/dbcfile.h index f23d01374c9..1149c15133f 100644 --- a/src/tools/map_extractor/dbcfile.h +++ b/src/tools/map_extractor/dbcfile.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/map_extractor/loadlib.cpp b/src/tools/map_extractor/loadlib.cpp index 2f31b472b56..9d18e3a66e8 100644 --- a/src/tools/map_extractor/loadlib.cpp +++ b/src/tools/map_extractor/loadlib.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/map_extractor/loadlib/loadlib.h b/src/tools/map_extractor/loadlib/loadlib.h index 6547704d885..683dc5519aa 100644 --- a/src/tools/map_extractor/loadlib/loadlib.h +++ b/src/tools/map_extractor/loadlib/loadlib.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/map_extractor/mpq_libmpq.cpp b/src/tools/map_extractor/mpq_libmpq.cpp index 482e3a3abbd..8f0da9144e2 100644 --- a/src/tools/map_extractor/mpq_libmpq.cpp +++ b/src/tools/map_extractor/mpq_libmpq.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/map_extractor/mpq_libmpq04.h b/src/tools/map_extractor/mpq_libmpq04.h index b9b332f95b0..97069177eb3 100644 --- a/src/tools/map_extractor/mpq_libmpq04.h +++ b/src/tools/map_extractor/mpq_libmpq04.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/map_extractor/wdt.cpp b/src/tools/map_extractor/wdt.cpp index 108e0830061..8e0f7a46069 100644 --- a/src/tools/map_extractor/wdt.cpp +++ b/src/tools/map_extractor/wdt.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/map_extractor/wdt.h b/src/tools/map_extractor/wdt.h index 3732fe87dba..9a3448fb0ab 100644 --- a/src/tools/map_extractor/wdt.h +++ b/src/tools/map_extractor/wdt.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/mmaps_generator/CMakeLists.txt b/src/tools/mmaps_generator/CMakeLists.txt index 52a7f5504d6..4eb416a106b 100644 --- a/src/tools/mmaps_generator/CMakeLists.txt +++ b/src/tools/mmaps_generator/CMakeLists.txt @@ -1,4 +1,4 @@ -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/tools/mmaps_generator/IntermediateValues.cpp b/src/tools/mmaps_generator/IntermediateValues.cpp index 3a7326ec34f..e7cc5cfca42 100644 --- a/src/tools/mmaps_generator/IntermediateValues.cpp +++ b/src/tools/mmaps_generator/IntermediateValues.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/mmaps_generator/IntermediateValues.h b/src/tools/mmaps_generator/IntermediateValues.h index 580e9e43139..cae5f0483cd 100644 --- a/src/tools/mmaps_generator/IntermediateValues.h +++ b/src/tools/mmaps_generator/IntermediateValues.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/mmaps_generator/MapBuilder.cpp b/src/tools/mmaps_generator/MapBuilder.cpp index 0c41be65cf7..3a63f9718db 100644 --- a/src/tools/mmaps_generator/MapBuilder.cpp +++ b/src/tools/mmaps_generator/MapBuilder.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/mmaps_generator/MapBuilder.h b/src/tools/mmaps_generator/MapBuilder.h index 432a0ee7489..d4b1bdf00fc 100644 --- a/src/tools/mmaps_generator/MapBuilder.h +++ b/src/tools/mmaps_generator/MapBuilder.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/mmaps_generator/PathCommon.h b/src/tools/mmaps_generator/PathCommon.h index aa9591fba22..ae87ef4b00f 100644 --- a/src/tools/mmaps_generator/PathCommon.h +++ b/src/tools/mmaps_generator/PathCommon.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/mmaps_generator/PathGenerator.cpp b/src/tools/mmaps_generator/PathGenerator.cpp index 992dee7d403..7bec37a64e8 100644 --- a/src/tools/mmaps_generator/PathGenerator.cpp +++ b/src/tools/mmaps_generator/PathGenerator.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/mmaps_generator/TerrainBuilder.cpp b/src/tools/mmaps_generator/TerrainBuilder.cpp index e525f24fced..69b1ffcb062 100644 --- a/src/tools/mmaps_generator/TerrainBuilder.cpp +++ b/src/tools/mmaps_generator/TerrainBuilder.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it @@ -80,7 +80,7 @@ struct map_liquidHeader namespace MMAP { - char const* MAP_VERSION_MAGIC = "v1.3"; + char const* MAP_VERSION_MAGIC = "v1.8"; TerrainBuilder::TerrainBuilder(bool skipLiquid) : m_skipLiquid (skipLiquid){ } TerrainBuilder::~TerrainBuilder() { } diff --git a/src/tools/mmaps_generator/TerrainBuilder.h b/src/tools/mmaps_generator/TerrainBuilder.h index f305bf0bd48..98fa691d4d3 100644 --- a/src/tools/mmaps_generator/TerrainBuilder.h +++ b/src/tools/mmaps_generator/TerrainBuilder.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_assembler/CMakeLists.txt b/src/tools/vmap4_assembler/CMakeLists.txt index 4513bdaf316..c33b2996685 100644 --- a/src/tools/vmap4_assembler/CMakeLists.txt +++ b/src/tools/vmap4_assembler/CMakeLists.txt @@ -1,5 +1,5 @@ # Copyright (C) 2005-2009 MaNGOS project <http://getmangos.com/> -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/tools/vmap4_assembler/VMapAssembler.cpp b/src/tools/vmap4_assembler/VMapAssembler.cpp index 20fd101c4b4..efe705e8b6c 100644 --- a/src/tools/vmap4_assembler/VMapAssembler.cpp +++ b/src/tools/vmap4_assembler/VMapAssembler.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/CMakeLists.txt b/src/tools/vmap4_extractor/CMakeLists.txt index 6685779dafe..55e66b32ea8 100644 --- a/src/tools/vmap4_extractor/CMakeLists.txt +++ b/src/tools/vmap4_extractor/CMakeLists.txt @@ -1,5 +1,5 @@ # Copyright (C) 2005-2009 MaNGOS project <http://getmangos.com/> -# Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> +# Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> # # This file is free software; as a special exception the author gives # unlimited permission to copy and/or distribute it, with or without diff --git a/src/tools/vmap4_extractor/adtfile.cpp b/src/tools/vmap4_extractor/adtfile.cpp index 3a8b3495655..3411cbec18f 100644 --- a/src/tools/vmap4_extractor/adtfile.cpp +++ b/src/tools/vmap4_extractor/adtfile.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/adtfile.h b/src/tools/vmap4_extractor/adtfile.h index 2ea9b647b16..5b05a614553 100644 --- a/src/tools/vmap4_extractor/adtfile.h +++ b/src/tools/vmap4_extractor/adtfile.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/dbcfile.cpp b/src/tools/vmap4_extractor/dbcfile.cpp index 534d93e5c4f..810f8f847d7 100644 --- a/src/tools/vmap4_extractor/dbcfile.cpp +++ b/src/tools/vmap4_extractor/dbcfile.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/dbcfile.h b/src/tools/vmap4_extractor/dbcfile.h index 00df092f048..afdbd0107bf 100644 --- a/src/tools/vmap4_extractor/dbcfile.h +++ b/src/tools/vmap4_extractor/dbcfile.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/gameobject_extract.cpp b/src/tools/vmap4_extractor/gameobject_extract.cpp index 5757f44b98a..989cc0099e1 100644 --- a/src/tools/vmap4_extractor/gameobject_extract.cpp +++ b/src/tools/vmap4_extractor/gameobject_extract.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/loadlib/loadlib.h b/src/tools/vmap4_extractor/loadlib/loadlib.h index bc964ab4911..687f1667679 100644 --- a/src/tools/vmap4_extractor/loadlib/loadlib.h +++ b/src/tools/vmap4_extractor/loadlib/loadlib.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/model.cpp b/src/tools/vmap4_extractor/model.cpp index 29230db16e8..5ae47ff7a55 100644 --- a/src/tools/vmap4_extractor/model.cpp +++ b/src/tools/vmap4_extractor/model.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/model.h b/src/tools/vmap4_extractor/model.h index 6292bf53bf6..ad6b59ced48 100644 --- a/src/tools/vmap4_extractor/model.h +++ b/src/tools/vmap4_extractor/model.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/modelheaders.h b/src/tools/vmap4_extractor/modelheaders.h index 218d07ccbb8..b09851ba543 100644 --- a/src/tools/vmap4_extractor/modelheaders.h +++ b/src/tools/vmap4_extractor/modelheaders.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/mpq_libmpq.cpp b/src/tools/vmap4_extractor/mpq_libmpq.cpp index f3eb3da96b6..690600867d9 100644 --- a/src/tools/vmap4_extractor/mpq_libmpq.cpp +++ b/src/tools/vmap4_extractor/mpq_libmpq.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/mpq_libmpq04.h b/src/tools/vmap4_extractor/mpq_libmpq04.h index 4c8b4d376ca..97b77d4643b 100644 --- a/src/tools/vmap4_extractor/mpq_libmpq04.h +++ b/src/tools/vmap4_extractor/mpq_libmpq04.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/vec3d.h b/src/tools/vmap4_extractor/vec3d.h index 211f5f26c72..1e042cfb426 100644 --- a/src/tools/vmap4_extractor/vec3d.h +++ b/src/tools/vmap4_extractor/vec3d.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/vmapexport.cpp b/src/tools/vmap4_extractor/vmapexport.cpp index 78d6e86358f..d9aa8643348 100644 --- a/src/tools/vmap4_extractor/vmapexport.cpp +++ b/src/tools/vmap4_extractor/vmapexport.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/vmapexport.h b/src/tools/vmap4_extractor/vmapexport.h index f105b3dd9d4..8dcf01a1d55 100644 --- a/src/tools/vmap4_extractor/vmapexport.h +++ b/src/tools/vmap4_extractor/vmapexport.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/wdtfile.cpp b/src/tools/vmap4_extractor/wdtfile.cpp index 4e0b7b97705..c78ea95055a 100644 --- a/src/tools/vmap4_extractor/wdtfile.cpp +++ b/src/tools/vmap4_extractor/wdtfile.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/wdtfile.h b/src/tools/vmap4_extractor/wdtfile.h index 81e84b36d1e..2fab77f3183 100644 --- a/src/tools/vmap4_extractor/wdtfile.h +++ b/src/tools/vmap4_extractor/wdtfile.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/wmo.cpp b/src/tools/vmap4_extractor/wmo.cpp index 80dfbb97c5a..2a8d053bbb6 100644 --- a/src/tools/vmap4_extractor/wmo.cpp +++ b/src/tools/vmap4_extractor/wmo.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it diff --git a/src/tools/vmap4_extractor/wmo.h b/src/tools/vmap4_extractor/wmo.h index 8c91393c3a4..50712289472 100644 --- a/src/tools/vmap4_extractor/wmo.h +++ b/src/tools/vmap4_extractor/wmo.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2015 TrinityCore <http://www.trinitycore.org/> + * Copyright (C) 2008-2016 TrinityCore <http://www.trinitycore.org/> * Copyright (C) 2005-2011 MaNGOS <http://getmangos.com/> * * This program is free software; you can redistribute it and/or modify it |
