[11501] Implement item 46098/46348 enchanting work.

This commit is contained in:
VladimirMangos 2011-05-18 03:13:56 +04:00
parent d00592f692
commit eb61995f7e
6 changed files with 30 additions and 3 deletions

View file

@ -24,7 +24,7 @@ CREATE TABLE `db_version` (
`version` varchar(120) default NULL,
`creature_ai_version` varchar(120) default NULL,
`cache_id` int(10) default '0',
`required_11489_01_mangos_creature_template` bit(1) default NULL
`required_11501_02_mangos_spell_bonus_data` bit(1) default NULL
) ENGINE=MyISAM DEFAULT CHARSET=utf8 ROW_FORMAT=FIXED COMMENT='Used DB version notes';
--
@ -14657,6 +14657,7 @@ INSERT INTO `spell_bonus_data` VALUES
(30294, 0, 0, 0, 0, 'Warlock - Soul Leech'),
(31117, 1.8, 0, 0, 0, 'Warlock - Unstable Affliction Dispell'),
/* Item */
(64569, 0, 0, 0, 0, 'Item - Blood Reserve'),
(56131, 0, 0, 0, 0, 'Item - Glyph of Dispel Magic'),
(56160, 0, 0, 0, 0, 'Item - Glyph of Power Word: Shield'),
(46567, 0, 0, 0, 0, 'Item - Goblin Rocket Launcher'),
@ -17551,6 +17552,7 @@ INSERT INTO `spell_proc_event` VALUES
(63625, 0x00, 6, 0x02000000, 0x02000000, 0x02000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00010000, 0x00000000, 0.000000, 0.000000, 0),
(63730, 0x00, 6, 0x00000800, 0x00000800, 0x00000800, 0x00000004, 0x00000004, 0x00000004, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0.000000, 0.000000, 0),
(64440, 0x7F, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000020, 0.000000, 0.000000, 0),
(64571, 0x7F, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0.000000, 0.000000, 10),
(64860, 0x00, 9, 0x00000000, 0x00000000, 0x00000000, 0x00000001, 0x00000001, 0x00000001, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0.000000, 0.000000, 0),
(64952, 0x00, 7, 0x00000000, 0x00000000, 0x00000000, 0x00000440, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0.000000, 0.000000, 0),
(64964, 0x00, 15, 0x00000000, 0x00000000, 0x00000000, 0x20000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0.000000, 0.000000, 0),

View file

@ -0,0 +1,5 @@
ALTER TABLE db_version CHANGE COLUMN required_11489_01_mangos_creature_template required_11501_01_mangos_spell_proc_event bit;
DELETE FROM spell_proc_event WHERE entry = 64571;
INSERT INTO spell_proc_event VALUES
(64571, 0x7F, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0.000000, 0.000000, 10);

View file

@ -0,0 +1,5 @@
ALTER TABLE db_version CHANGE COLUMN required_11501_01_mangos_spell_proc_event required_11501_02_mangos_spell_bonus_data bit;
DELETE FROM spell_bonus_data WHERE entry IN (64569);
INSERT INTO spell_bonus_data VALUES
(64569, 0, 0, 0, 0, 'Item - Blood Reserve');

View file

@ -2910,6 +2910,21 @@ SpellAuraProcResult Unit::HandleProcTriggerSpellAuraProc(Unit *pVictim, uint32 d
break;
}
case 64568: // Blood Reserve
{
// When your health drops below 35% ....
uint32 health35 = uint32(GetMaxHealth() * 0.35);
if (GetHealth() - damage > health35 || GetHealth() < health35)
return SPELL_AURA_PROC_FAILED;
trigger_spell_id = 64569;
// need scale damage base at stack size
if (SpellEntry const* trigEntry = sSpellStore.LookupEntry(trigger_spell_id))
basepoints[EFFECT_INDEX_0] = trigEntry->CalculateSimpleValue(EFFECT_INDEX_0) * triggeredByAura->GetStackAmount();
break;
}
case 67702: // Death's Choice, Item - Coliseum 25 Normal Melee Trinket
{
float stat = 0.0f;

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "11500"
#define REVISION_NR "11501"
#endif // __REVISION_NR_H__

View file

@ -1,6 +1,6 @@
#ifndef __REVISION_SQL_H__
#define __REVISION_SQL_H__
#define REVISION_DB_CHARACTERS "required_11436_01_characters_character_queststatus"
#define REVISION_DB_MANGOS "required_11489_01_mangos_creature_template"
#define REVISION_DB_MANGOS "required_11501_02_mangos_spell_bonus_data"
#define REVISION_DB_REALMD "required_10008_01_realmd_realmd_db_version"
#endif // __REVISION_SQL_H__