Jump to content

amxxL

Members
  • Posts

    11
  • Joined

  • Last visited

    Never
  • Donations

    0.00 GBP 

Everything posted by amxxL

  1. I fixed it. There's the code: // Deathbringer's Will Normal case 71519: // Deathbringer's Will Heroic case 71562: { if (((Player*)this)->HasSpellCooldown(dummySpell->Id)) return SPELL_AURA_PROC_FAILED; switch (getClass()) { case CLASS_WARRIOR: case CLASS_PALADIN: case CLASS_DEATH_KNIGHT: { uint32 proc_spells[] = {71491, 71492, 71484, 71559, 71560, 71561}; triggered_spell_id = (dummySpell->Id) == 71519 ? proc_spells[urand(0, 2)] : proc_spells[urand(3, 5)]; break; } case CLASS_ROGUE: case CLASS_SHAMAN: { uint32 proc_spells[] = {71485, 71486, 71492, 71556, 71558, 71560}; triggered_spell_id = (dummySpell->Id) == 71519 ? proc_spells[urand(0, 2)] : proc_spells[urand(3, 5)]; break; } case CLASS_HUNTER: { uint32 proc_spells[] = {71485, 71486, 71491, 71556, 71558, 71559}; triggered_spell_id = (dummySpell->Id) == 71519 ? proc_spells[urand(0, 2)] : proc_spells[urand(3, 5)]; break; } case CLASS_DRUID: { uint32 proc_spells[] = {71485, 71492, 71484, 71556, 71560, 71561}; triggered_spell_id = (dummySpell->Id) == 71519 ? proc_spells[urand(0, 2)] : proc_spells[urand(3, 5)]; break; } default: return SPELL_AURA_PROC_FAILED; } target = this; ((Player*)this)->AddSpellCooldown(dummySpell->Id, 0, time(NULL) + cooldown); break; } if someone need it add this code to UnitAuraProcHandler.cpp this function: SpellAuraProcResult Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, Aura* triggeredByAura, SpellEntry const * procSpell, uint32 procFlag, uint32 procEx, uint32 cooldown)
  2. Someone please help me to fix cooldowns. Why nobody doesn't help me?
  3. Something like this? case 71519: // Deathbringer's Will Normal { if (GetTypeId() != TYPEID_PLAYER) return SPELL_AURA_PROC_FAILED; switch (getClass()) { case CLASS_PALADIN: case CLASS_DEATH_KNIGHT: { uint32 RandomSpell[] = {71484, 71491, 71492}; triggered_spell_id = RandomSpell[urand(0, countof(RandomSpell) - 1)]; break; } case CLASS_ROGUE: case CLASS_DRUID: case CLASS_SHAMAN: { uint32 RandomSpell[] = {71485, 71486, 71492}; triggered_spell_id = RandomSpell[urand(0, countof(RandomSpell) - 1)]; break; } case CLASS_WARRIOR: { uint32 RandomSpell[] = {71484, 71491, 71492}; triggered_spell_id = RandomSpell[urand(0, countof(RandomSpell) - 1)]; break; } case CLASS_HUNTER: { uint32 RandomSpell[] = {71485, 71486, 71491}; triggered_spell_id = RandomSpell[urand(0, countof(RandomSpell) - 1)]; break; } default: return SPELL_AURA_PROC_FAILED; } target = this; break; } case 71562: // Deathbringer's Will Heroic { if (GetTypeId() != TYPEID_PLAYER) return SPELL_AURA_PROC_FAILED; switch (getClass()) { case CLASS_PALADIN: case CLASS_DEATH_KNIGHT: { uint32 RandomSpell[] = {71561, 71560, 71559}; triggered_spell_id = RandomSpell[urand(0, countof(RandomSpell) - 1)]; break; } case CLASS_ROGUE: case CLASS_DRUID: case CLASS_SHAMAN: { uint32 RandomSpell[] = {71560, 71558, 71556}; triggered_spell_id = RandomSpell[urand(0, countof(RandomSpell) - 1)]; break; } case CLASS_WARRIOR: { uint32 RandomSpell[] = {71561, 71560, 71559}; triggered_spell_id = RandomSpell[urand(0, countof(RandomSpell) - 1)]; break; } case CLASS_HUNTER: { uint32 RandomSpell[] = {71558, 71557, 71559}; triggered_spell_id = RandomSpell[urand(0, countof(RandomSpell) - 1)]; break; } default: return SPELL_AURA_PROC_FAILED; } target = this; break; } This code works but the problem with cooldowns did not disappear How i can fix cooldowns? I try add cooldown to spell_proc_event table but it's doesn't work for me.
  4. Sorry for double post but i need help. please look at this code: case 71562: // Deathbringer's Will Heroic { if (GetTypeId() != TYPEID_PLAYER) return SPELL_AURA_PROC_FAILED; std::vector<uint32> RandomSpells; switch (getClass()) { case CLASS_WARRIOR: case CLASS_PALADIN: case CLASS_DEATH_KNIGHT: RandomSpells.push_back(71561); RandomSpells.push_back(71559); RandomSpells.push_back(71560); break; case CLASS_SHAMAN: case CLASS_ROGUE: RandomSpells.push_back(71558); RandomSpells.push_back(71556); RandomSpells.push_back(71560); break; case CLASS_DRUID: RandomSpells.push_back(71561); RandomSpells.push_back(71556); RandomSpells.push_back(71558); break; case CLASS_HUNTER: RandomSpells.push_back(71558); RandomSpells.push_back(71559); RandomSpells.push_back(71556); break; default: return SPELL_AURA_PROC_FAILED; } if (RandomSpells.empty()) return SPELL_AURA_PROC_FAILED; uint8 rand_spell = irand(0, (RandomSpells.size() - 1)); CastSpell(target, RandomSpells[rand_spell], true, castItem, triggeredByAura); return SPELL_AURA_PROC_OK; break; } this code works but not correctly. how i can add cooldown for that spell?
  5. Thanks but i need more information
  6. Hello everyone, i want to fix Deathbringer's Will but i don't know where is it in source code. Someone please tell me where is it. Thanks for helping. (I bad speak english)
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use