aboutsummaryrefslogtreecommitdiff
path: root/sql
diff options
context:
space:
mode:
authorModoX <moardox@gmail.com>2023-04-06 01:01:02 +0200
committerGitHub <noreply@github.com>2023-04-06 01:01:02 +0200
commit0750b7f8455df39a64462636ca296c6f2aa2b048 (patch)
tree935678cc42b5829dff44efababb3133c9df4e27a /sql
parent20a1e21cc5dc890d858a4a8dceba16a4fc3caa72 (diff)
Core/Creature: Implemented sparring with max health percent thresholds (#27198)
Co-authored-by: Ovah <dreadkiller@gmx.de>
Diffstat (limited to 'sql')
-rw-r--r--sql/updates/world/master/2023_04_06_00_world.sql25
1 files changed, 25 insertions, 0 deletions
diff --git a/sql/updates/world/master/2023_04_06_00_world.sql b/sql/updates/world/master/2023_04_06_00_world.sql
new file mode 100644
index 00000000000..82ca9eb6d69
--- /dev/null
+++ b/sql/updates/world/master/2023_04_06_00_world.sql
@@ -0,0 +1,25 @@
+--
+DROP TABLE IF EXISTS `creature_template_sparring`;
+CREATE TABLE `creature_template_sparring` (
+ `Entry` int unsigned NOT NULL,
+ `NoNPCDamageBelowHealthPct` float NOT NULL,
+ PRIMARY KEY (`Entry`,`NoNPCDamageBelowHealthPct`)
+) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
+
+-- transition from old sparring system
+DELETE FROM `creature_template_sparring` WHERE `Entry` IN(32882,32883,32885,32886,32907,32908);
+INSERT INTO `creature_template_sparring` (`Entry`, `NoNPCDamageBelowHealthPct`) VALUES
+(32882, 100),
+(32883, 100),
+(32885, 100),
+(32907, 100),
+(32908, 100);
+
+-- example in sentinel hill
+DELETE FROM `creature_template_sparring` WHERE `Entry` IN(54372, 54373, 54371, 42407);
+INSERT INTO `creature_template_sparring` (`Entry`, `NoNPCDamageBelowHealthPct`) VALUES
+(54372, 85),
+(54373, 85),
+(54371, 85),
+(42407, 85),
+(51915, 85);