From cb9e72e521d3cc415dd15bf6912c87f89e41b92a Mon Sep 17 00:00:00 2001 From: ariel- Date: Sat, 13 Jan 2018 06:45:21 -0300 Subject: Core/Auras: removed caster dependency from core - Decoupled Unit logic: split of spell critical chance into done (caster bonuses) and taken (target bonuses), this allows to precalculate caster bonuses on aura apply and then check victim's auras on damage/healing calc - Made static a bunch of methods (they no longer have this pointer because they are now called from periodic handlers which may or may not have an active caster in world) - Simplified all AuraEffect bonuses into AuraEffect::_amount, no more duplicated code - Critical chance and whether or not caster is player owned unit (for resilience calcs) is now saved one level upper, on Aura itself (it's impossible as of 3.3.5 to have different effects with different critical chances) - Minor cleanup of SPELL_DAMAGE_CLASS_NONE and Arcane Potency (#18813) crit handling Closes #19876 --- sql/base/characters_database.sql | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'sql/base') diff --git a/sql/base/characters_database.sql b/sql/base/characters_database.sql index 75fb30efcaa..734c6673400 100644 --- a/sql/base/characters_database.sql +++ b/sql/base/characters_database.sql @@ -543,6 +543,8 @@ CREATE TABLE `character_aura` ( `maxDuration` int(11) NOT NULL DEFAULT '0', `remainTime` int(11) NOT NULL DEFAULT '0', `remainCharges` tinyint(3) unsigned NOT NULL DEFAULT '0', + `critChance` float NOT NULL DEFAULT '0', + `applyResilience` tinyint(3) NOT NULL DEFAULT '0', PRIMARY KEY (`guid`,`casterGuid`,`spell`,`effectMask`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Player System'; /*!40101 SET character_set_client = @saved_cs_client */; @@ -2317,6 +2319,8 @@ CREATE TABLE `pet_aura` ( `maxDuration` int(11) NOT NULL DEFAULT '0', `remainTime` int(11) NOT NULL DEFAULT '0', `remainCharges` tinyint(3) unsigned NOT NULL DEFAULT '0', + `critChance` float NOT NULL DEFAULT '0', + `applyResilience` tinyint(3) NOT NULL DEFAULT '0', PRIMARY KEY (`guid`,`casterGuid`,`spell`,`effectMask`) ) ENGINE=InnoDB DEFAULT CHARSET=utf8 COMMENT='Pet System'; /*!40101 SET character_set_client = @saved_cs_client */; @@ -2616,7 +2620,8 @@ INSERT INTO `updates` VALUES ('2017_04_12_01_characters.sql','5A8A1215E3A2356722F52CD7A64BBE03D21FBEA3','ARCHIVED','2017-04-12 00:00:00',0), ('2017_04_19_00_characters.sql','CE06FA9005C8A8EE4BDD925520278A5D83E87485','RELEASED','2017-04-19 00:07:40',25), ('2017_10_29_00_characters.sql','6209D716E22C391F1FB464221D9F25AF','RELEASED','2017-04-19 00:07:40',25), -('2017_11_27_00_characters.sql','6FF1F84B8985ADFC7FF97F0BF8E53403CF13C320','RELEASED','2017-11-27 22:08:42',0); +('2017_11_27_00_characters.sql','6FF1F84B8985ADFC7FF97F0BF8E53403CF13C320','RELEASED','2017-11-27 22:08:42',0), +('2018_01_13_00_characters.sql','E3C0DA9995BA71ED5A267294470CD03DC51862DD','RELEASED','2018-01-13 00:00:00',0); /*!40000 ALTER TABLE `updates` ENABLE KEYS */; UNLOCK TABLES; -- cgit v1.2.3