Commit Graph
356 Commits
Author SHA1 Message Date
Meji 924182f692 Core/BattlePets: Misc fixes (#27446)
* Added script for "Summon Battle Pet" spell (118301).
* Set the saved display of the battle pet when summoning it.
* If a summon has SummonPropertiesFlags::SummonFromBattlePetJournal it will remove NpcFlag UNIT_NPC_FLAG_WILD_BATTLE_PET (Wild battle pets).
* When a creature is summoned with SummonTitle::Companion, it will check to see if it has SummonPropertiesFlags::SummonFromBattlePetJournal before updating the battle pet's update fields. (If you have a summoned battle pet and summon a creature with that SummonTitle, it will incorrectly update the battle pet's update fields with the summoned battle pet's data).
* Implemented SummonPropertiesFlags::UseCreatureLevel. If a summon has this flag, it will use the owner's level (If the summon doesn't have SummonProperties it will always use the selected level).
2021-12-25 15:27:58 +01:00
Rushor 10cf49e130 Spell/Script: Spawn Blood Pool
Closes #23878

(cherry picked from commit 3ddc6e70df0401a0677bef536e6b0e46e3dbf9e9)
2021-12-23 00:21:24 +01:00
Alan Deutscher cd72ecce78 Scripts/Spells: fix Turkey Timer duration (#24048)
* spell_gen_turkey_marker::OnPeriodic: Pop expired stack timestamps from tracking list.

* Be a bit more explicit about the data type of removedCount.

* Formatting nudge.

* Remove brackets.

(cherry picked from commit a0c07655eb6b42a2e1fd9319d53c7ed7f2c585d8)
2021-12-20 21:24:37 +01:00
Keader f358ac39cc Build fix
(cherry picked from commit ecd4ffc1ceac6b1d6e9f86f192673ce95f94aaae)
2021-12-19 01:42:27 +01:00
Killyana 16ddcdfd0a DB/Quest: Take Down Tethyr!
Closes #22407

(cherry picked from commit c22b1e6cb46ff76729f44eb846043e1614abc9f9)
2021-12-19 01:42:16 +01:00
Giacomo Pozzoni 9bede687ce Core/GameObjects: Skip LoS checks for traps (#23936)
* Core/GameObjects: Skip LoS checks for traps

* Core/GameObjects: Fix spells cast by traps missing always

* Scripts/Spells: Fix WSG heal buff not healing

The WSG green heal buff is now cast by a GameObject so the spell target should be used to calculate the healing, not the GameObject.

(cherry picked from commit 909941e1b44250b0fa646d363af817f40ca48355)
2021-12-19 01:05:54 +01:00
ForesterDev 104ec7a81a Core/Unit: Implement more helper methods (#23555)
(cherry picked from commit c44fb37f74347e3b6d399c941716971503af4cf8)
2021-12-14 20:42:32 +01:00
ForesterDev 27886c7f5d Core/Player: add helper methods GetNativeGender/SetNativeGender/SetGender (#23520)
* Core/Player: add helper methods GetNativeGender/SetNativeGender/SetGender and fix some cases, where we should get player gender, instead of modified by display gender

* fix merge

* Add virtual methods for Unit class

(cherry picked from commit b47bb59e2a3e42aff3793517ef94f51678b54905)
2021-12-13 00:42:20 +01:00
ccrs 4e6c59dca7 Core/Unit: rename several getters to follow codestyle
uint8 GetLevel()
        uint8 GetLevelForTarget(WorldObject const* /*target*/)
        void SetLevel(uint8 lvl)
        uint8 GetRace()
        uint32 GetRaceMask()
        uint8 GetClass()
        uint32 GetClassMask()
        uint8 GetGender()

(cherry picked from commit 5c09ff51f7015b775def8d5cc1f678eaef37200f)
2021-12-13 00:42:20 +01:00
Sorikoff 8fc52bc5e5 Scripts/Spells: Migrate Teleporting to Script (#23458)
* Scripts/Spells: Migrate Teleporting to Script

* Rename 9999_99_99_99_world.sql to 2019_06_21_02_world.sql

(cherry picked from commit e9d803ccee2fb5d229babbf6c2c4a17b1986edb0)
2021-12-11 22:28:55 +01:00
Wyrserth 6b7bc82641 Core/Spell: allow Northrend Inscription Research to unlock three recipes the first time it is cast. (#23401)
Also prevent double skill-up because of duplicate UpdateCraftSkill() calls.

(cherry picked from commit 2315d43b2c1f478bd5f612e39f3a938bf6640ab6)
2021-12-11 12:06:54 +01:00
Killyana adb5535483 Spell/Script: Stasis Field
Closes #23355

(cherry picked from commit 7dd87e3df44c1c5b9b8ffb9652911d46d6676c38)
2021-12-10 21:37:45 +01:00
Giacomo Pozzoni 5f545f5402 3.3.5 gameobject summoner (#23289)
* Scripts/Misc: Change IsSummonedBy(Unit*) to IsSummonedBy(WorldObject*)

* Scripts/Misc: Fix build

* Core/TempSummons: Rename GetSummoner() to GetSummonerUnit()

* Core/TempSummons: Add support to TempSummons::GetSummoner() to return GameObject too

* Fix build

* Core/TempSummons: Allow GameObject to be owner of TempSummon

* Core/TempSummons: Add support to SAI for GameObject owner of TempSummon

* Scripts/Misc: Fix no-pch build

* Core/TempSummons: Implement PR comments

(cherry picked from commit 797fba98e95da1236465a15061ec4122d7ec33fe)
2021-12-07 00:02:03 +01:00
Wyrserth fd030069f7 Core/Spell: add proper cooldowns to some spells used by vehicles (#23260)
* Core/Spell: add proper cooldowns to some spells used by vehicles, thanks to jackpoz and sirikfoll.

* Add Wing Buffet and Stampy's Stompy-Stomp.

* Add Tag Greater Felfire Diemetradon and Touch of Darkness.

* Rename 9999_99_99_99_world.sql to 2019_05_17_00_world.sql

(cherry picked from commit 4d04344b414adc965bd2760d3f30338bcce70431)
2021-12-05 18:44:59 +01:00
Sorikoff d72e809ecf Scripts/Spells: Migrate Some Scripted Spells to Scripts (#23185)
* Migrate spells to scripts

* Simplify code

* I need to sleep

* Update chapter1.cpp

* Use actual damage

* No need in null check here

(cherry picked from commit 2cfaeb14004cfbb5500855472ad89ab9238df13d)
2021-11-30 22:30:53 +01:00
Gustavo b86a66c5be Core/Scripts: Fix Blood summon position (#23088)
* Core/Scripts: Fix Blood summon position

Updates #13162

(cherry picked from commit cc3293c0023b36434747190103a1f0ffee0f8488)
2021-11-26 11:21:24 +01:00
PolarCookie f7299dce97 Core/Spell: SpellAura Redux (#22794)
* typo and correction

* spell aura no longer shared between targets

_spellAura isolated

* SPELL_AURA_CONTROL_VEHICLE is not strictly single target spell

Steam Tank Control and Wyrmrest Commander

units can reseat themselves again

* Rename 9999_99_99_99_world.sql to 2019_03_08_00_world.sql

(cherry picked from commit ec3cb05d7fbc5cef60d000af910dc39dd3af92bf)
2021-11-24 20:35:19 +01:00
Keader 955ac45cf5 Spell/Script: Freezing Circle
Closes #11312
See the original issue before cherry pick

(cherry picked from commit 990ad000f8e869e55353e6531d9e38f23104bcd6)
2021-11-24 20:34:56 +01:00
Killyana d8b76a6e6d DB/Creature: Wrath Corruptor
Thanks to Keader for the spell_script
Original sql by Tobschinski https://github.com/cmangos/tbc-db/commit/c8f1753834ba3dba4c6263346afe29cd363c2431

(cherry picked from commit fb28083b3b2966952b1227f6585b48fcc70dbe7a)
2021-11-21 14:38:17 +01:00
Rynem Storm c7ad7d5e15 DB/Spell: fix mistake in Blood Draining's CheckProc and remove Attack Power scaling (#22862)
(cherry picked from commit a057d26f20ef2d18fa276534d727b03a6b5a2931)
2021-11-18 23:04:07 +01:00
DanVS 3b1ed434ae Core/Scripts: Move some spells to scripts (#22332)
(cherry picked from commit 8051ff13dfcf3819b58adfcec1608c08dcbcd080)
2021-11-18 22:41:57 +01:00
ShaurenandSeyden 732a8ee261 Core/Movement: Corrected values sent in knockback packet when speedXY < 0
Co-authored-by: Seyden <[email protected]>
2021-11-06 23:17:43 +01:00
Treeston e4e8c1c59c Core/AI: Clean up charm AI handling, we now have two unique_ptr instead of a crapton of booleans
(cherry picked from commit 042f5515e4f3e52b0d2e23d9b9e147041849ce12)
2021-10-22 23:47:51 +02:00
DanVS 3503e9dc92 Scripts/Pets: Some cleanup for Snake Trap. Tagging #21847, though this doesn't address it (yet).
(cherry picked from commit 15ab24756dab76066bc24ca2a8c3289afbe836c0)
2021-10-17 01:40:21 +02:00
ModoX ece3a8036e Scripts/DK: Fixed Defender of Azeroth quest
* added graveyard in case someone wants to die there
* added serverside spells to handle death gate usage properly (including bind points)
* added SmartAI script to Mograine for Defender of Azeroth quest
2021-10-13 19:33:19 +02:00
Shauren 3af9be830d Core/Spells: Removed CastSpellExtraArgs constructors accepting ObjectGuid, they would become ambiguous with future changes 2021-10-03 14:58:35 +02:00
ariel- 6d3a11e1d1 Scripts/Spells: fix Seaforium Blast script crash
Closes #21663

(cherry picked from commit 6eb122792cb1446a35752c6f62dd0febb6387671)
2021-09-19 22:20:30 +02:00
Shauren 8a4e1119ac Core/Spells: Unify spell effect access api in both branches 2021-09-04 15:13:15 +02:00
Shauren 3af33b9ff9 Warning fixes 2021-08-28 20:24:21 +02:00
Shauren 3dd75a49b1 Core/Spells: Removed SpellEffIndex effIndex argument from spell effect handlers, it was commented out in almost every handler 2021-08-28 19:51:29 +02:00
ariel- d36f8bb754 Core/Scripts: implemented Fungal Decay & Tail Sting
Refs #18542

(cherry picked from commit 7dc78d8e3f437ad7f3ad40bf1ef6801ac1ed5fc2)
2021-06-22 13:15:11 +02:00
Treeston ffce2c1f9a Core/Spell: Properly remove REACT_PASSIVE on permanent feign death unapply. Fixes and closes #21156.
(cherry picked from commit ac8b9be5d67ccaba3f51663eeccca60ae86cea5b)
2021-06-20 20:22:18 +02:00
ariel- 5fbddef85f Core/Spell: SpellValueOverrides encapsulation
- No sense to let scripts use SpellValueOverrides, we already have modifiers in CastSpellExtraArgs struct

(cherry picked from commit 3b01cccd7eafaff9f3b8236a544e4fa46818926c)
2021-06-14 00:19:50 +02:00
Shauren c79e5528e1 Core/Units: Remove Unit::EnergizeBySpell overload taking spellId argument 2021-05-16 21:56:06 +02:00
Treeston 9b141207d1 [3.3.5] CastSpell unclusterfucking (that's a word now) (#21123)
Core/Spell: The giant CastSpell unclusterfucking (that's a word now) of this generation.

- CastSpell now always takes three arguments - target, spellId, and a struct containing extra arguments
- This struct (CastSpellExtraArgs, see SpellDefines.h) serves as a conglomerate of every previous combination of the 20 billion different CastSpell overloads, all merged into one
  - It has some great utility constructors - check them out! All of these can be used to implicitly construct the ExtraArgs object.
- A gajillion refactors to make everything behave the way it always has

(cherry picked from commit d507a7e3388382960108b24143da48e5f912b4a7)
2021-04-16 15:22:42 +02:00
Keader a5635526ed Scripts/Trial of Crusader: Northrend Beasts Rework (#21031)
* Rewritten Gormok encounter
* Rewritten Snobold Vassal Script
* Rewritten Jormungars encounter
* Rewritten Icehowl encounter
* Added missing texts
* Added missing spells
* Implemented berserk mechanic on heroic diffs.
* Implemented Achievement requirement to make heroic diffs.
* Rewritten Barrett Ramsay scripts
* Added Barrett gossips and ported everything to DB.
* Added right Barrett in each encounter
* Removed a lot of hacks
* Rewritten Tirion Fordring script
* Rewritten Varian Wrynn script
* Rewritten Garrosh script
* Rewritten Wilfred event
* Rewritten Lich King event
* Updated codestyle
* Added missing spawns
* Fixed combat behavior before Gormok
* Fixed some visual stuff

(cherry picked from commit 2362e9c79410c689afc10266b94f7e78c88bbddc)
2021-04-15 05:53:27 +02:00
ariel- 16ec008290 Core/Spells: fix some DB errors
Ref #18542

- Implemented Choking Vines transformation at 5 stacks
- Implemented periodic Aura of Fear ticks
- Fixed Savage Rend passive proccing on anything (raptor pets)

(cherry picked from commit de9f9042699e849af38363430cd9aa390c62d1a2)
(cherry picked from commit 32e2207ab9863b9d79b994afd929730ca04bbce8)
(cherry picked from commit 9934a43e0948b6dfd46bd549e6a1c7028c40e22d)
2021-04-15 05:53:27 +02:00
Matan Shukry d2b70397ab Spells/Scripts: Updated Gift of the Naaru script
Closes #22468
2021-04-12 22:32:53 +02:00
ariel- 33fbd7c773 Core/Scripts: fix drink auras
(cherry picked from commit 5fc4d36a1fd8214a0b52ba571b2e1b9c6afef79a)
2021-03-15 20:17:31 +01:00
ariel- 6042126916 Core/Scripts: travis fixes
(cherry picked from commit ea0224e3bd8a4b081725c1eae5c597f8c7d74d7f)
2021-03-15 20:17:31 +01:00
ariel- 44c8ccadd7 Core/Auras: periodics refactor part 5: ported periodic trigger spell auras to scripts
(cherry picked from commit a36e804ae4639be40be17282e6c79fad9a769517)
2021-03-15 20:17:31 +01:00
ariel- 97e869e8b3 Core/Auras: periodics refactor part 3: move more switch hacks to scripts
- Incidentally fixed some spells which were supposed to be removed by proc instead of healing to full

(cherry picked from commit 16e20711d277bc43ae3ac350208df73827306ea6)
2021-03-15 20:17:31 +01:00
ariel- fd786c03a3 Core/Auras: periodics refactor part 2: Move UpdatePeriodic to AuraScripts
(cherry picked from commit 0510bf7afe9fa5ded572cda00f5a5a989a887146)
2021-03-15 20:17:31 +01:00
ariel- 5f9e0d92d5 Core/Auras: periodics refactor part 1:
- Don't skip ticks if diff is greater than amplitude
- Fixed spells without ampltude in DBC

(cherry picked from commit 5d91beb1dbc795382a12ec05f6e72c76b195b141)
2021-03-15 20:17:31 +01:00
Matan Shukry 7159de62b6 Scripts/Spells: Remove const from AuraEffect argument for AuraEffectProcFn 2021-02-13 14:08:16 +01:00
Matan Shukry 0cae71eac5 Core/Spells: Adding SpellTargetObjectTypes to spell target checker to early-eliminate alive units (#26028)
* Added object type into checker that is used by grid search to early eliminate alive units when looking for corpses
* Removed script 'spell_hun_pet_carrion_feeder'. Ability doesn't exist anymore
2021-02-05 21:29:00 +01:00
Shauren b630e9a485 Warning fix 2020-08-20 00:12:20 +02:00
Treeston b1d2e4e906 Scripts/Spell: Port spell_generic.cpp to new script registration syntax wherever possible. No actual changes in functionality. (fb87ac8 follow-up)
(cherry picked from commit 49aa8a2e59b8873da109638cd7dbe24ef359f0ce)
2020-08-19 23:42:29 +02:00
Shauren 1c52d5fff7 Core/Misc: Replace NULL with nullptr 2020-08-14 17:06:03 +02:00
ForesterDev c34b83a467 Core/Defines: define faction templates and replace magic numbers from scripts
(cherry picked from commit abea8bf4cb3034f56d833982f951a0742dc36fc7)
2020-06-14 23:49:03 +02:00