diff options
| author | QAston <qaston@gmail.com> | 2011-06-26 00:29:36 +0200 |
|---|---|---|
| committer | QAston <qaston@gmail.com> | 2011-06-26 00:29:36 +0200 |
| commit | 6dcee0c0ea23617849a6b04ae22d2b74fb04f097 (patch) | |
| tree | eb68d1f2f1c8518263ffdf53cc01c292fe83ded8 /src/server/game | |
| parent | 2bcf63d3879cdb7175b83e98f8cd37bacd6449b3 (diff) | |
| parent | 9a5f8dc844be68fa239d9c5ac6b95b7a6b2dfcee (diff) | |
Merge branch 'master' of https://github.com/TrinityCore/TrinityCore
Diffstat (limited to 'src/server/game')
| -rwxr-xr-x | src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp | 4 | ||||
| -rwxr-xr-x | src/server/game/Entities/GameObject/GameObject.h | 2 | ||||
| -rwxr-xr-x | src/server/game/Entities/Unit/Unit.cpp | 71 | ||||
| -rwxr-xr-x | src/server/game/Instances/InstanceScript.cpp | 18 | ||||
| -rwxr-xr-x | src/server/game/Instances/InstanceScript.h | 3 | ||||
| -rwxr-xr-x | src/server/game/Miscellaneous/Language.h | 4 | ||||
| -rwxr-xr-x | src/server/game/Server/Protocol/Handlers/ItemHandler.cpp | 66 | ||||
| -rwxr-xr-x | src/server/game/Server/Protocol/Handlers/SpellHandler.cpp | 2 | ||||
| -rwxr-xr-x | src/server/game/Server/WorldSession.h | 2 | ||||
| -rwxr-xr-x | src/server/game/Spells/Spell.cpp | 3 | ||||
| -rwxr-xr-x | src/server/game/Spells/Spell.h | 3 | ||||
| -rwxr-xr-x | src/server/game/Spells/SpellMgr.cpp | 5 |
12 files changed, 100 insertions, 83 deletions
diff --git a/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp b/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp index bd3125ff18d..d5fd8cca112 100755 --- a/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp +++ b/src/server/game/Battlegrounds/Zones/BattlegroundIC.cpp @@ -186,7 +186,7 @@ void BattlegroundIC::Update(uint32 diff) siege->Respawn(true); } - // we need to confirm this, i am not sure if this every 3 minutes + // we need to confirm if it is every 3 minutes for (uint8 u = (nodePoint[i].faction == TEAM_ALLIANCE ? BG_IC_NPC_DEMOLISHER_1_A : BG_IC_NPC_DEMOLISHER_1_H); u < (nodePoint[i].faction == TEAM_ALLIANCE ? BG_IC_NPC_DEMOLISHER_4_A : BG_IC_NPC_DEMOLISHER_4_H); u++) { if (Creature* demolisher = GetBGCreature(u)) @@ -200,7 +200,7 @@ void BattlegroundIC::Update(uint32 diff) } } - // the point is waiting for a change on his banner + // the point is waiting for a change on its banner if (nodePoint[i].needChange) { if (nodePoint[i].timer <= diff) diff --git a/src/server/game/Entities/GameObject/GameObject.h b/src/server/game/Entities/GameObject/GameObject.h index 6634760fdfd..95be55e595e 100755 --- a/src/server/game/Entities/GameObject/GameObject.h +++ b/src/server/game/Entities/GameObject/GameObject.h @@ -774,7 +774,7 @@ class GameObject : public WorldObject, public GridObject<GameObject> uint64 GetRotation() const { return m_rotation; } virtual uint32 GetScriptId() const { return GetGOInfo()->ScriptId; } - GameObjectAI* AI() const { return (GameObjectAI*)m_AI; } + GameObjectAI* AI() const { return m_AI; } std::string GetAIName() const; protected: diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index c5122b04d69..fd8be29c3e0 100755 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -5704,7 +5704,7 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger { if (effIndex != 0) return false; - AuraEffect* counter = triggeredByAura->GetBase()->GetEffect(1); + AuraEffect* counter = triggeredByAura->GetBase()->GetEffect(EFFECT_1); if (!counter) return true; @@ -6040,7 +6040,7 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger // regen mana for caster CastCustomSpell(this, 59117, &basepoints0, NULL, NULL, true, castItem, triggeredByAura); // Get second aura of spell for replenishment effect on party - if (AuraEffect const* aurEff = (*i)->GetBase()->GetEffect(1)) + if (AuraEffect const* aurEff = (*i)->GetBase()->GetEffect(EFFECT_1)) { // Replenishment - roll chance if (roll_chance_i(aurEff->GetAmount())) @@ -6108,7 +6108,7 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger { // Multiple effects stack, so let's try to find this aura. int32 bonus = 0; - if (AuraEffect* aurEff = target->GetAuraEffect(47753, 0)) + if (AuraEffect const* aurEff = target->GetAuraEffect(47753, 0)) bonus = aurEff->GetAmount(); basepoints0 = CalculatePctN(int32(damage), triggerAmount) + bonus; @@ -6605,7 +6605,6 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger // This effect only from Rapid Killing (mana regen) if (!(procSpell->SpellFamilyFlags[1] & 0x01000000)) return false; - triggered_spell_id = 56654; target = this; @@ -6688,7 +6687,7 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger { if (procFlag & PROC_FLAG_TAKEN_SPELL_MAGIC_DMG_CLASS_POS) { - if ((procSpell->SpellFamilyName == SPELLFAMILY_PALADIN) && (procSpell->SpellFamilyFlags[0] & 0x40000000)) + if (procSpell->SpellFamilyName == SPELLFAMILY_PALADIN && (procSpell->SpellFamilyFlags[0] & 0x40000000)) { basepoints0 = damage / 12; @@ -6703,6 +6702,11 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger else if (damage > 0) triggered_spell_id = 58597; + // Item - Paladin T8 Holy 4P Bonus + if (Unit* caster = triggeredByAura->GetCaster()) + if (AuraEffect const* aurEff = caster->GetAuraEffect(64895, 0)) + cooldown = aurEff->GetAmount(); + target = this; break; } @@ -6710,7 +6714,7 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger if (dummySpell->SpellIconID == 3025) { // 4 damage tick - basepoints0 = triggerAmount*damage/400; + basepoints0 = triggerAmount * damage / 400; triggered_spell_id = 61840; // Add remaining ticks to damage done basepoints0 += pVictim->GetRemainingPeriodicAmount(GetGUID(), triggered_spell_id, SPELL_AURA_PERIODIC_DAMAGE); @@ -6720,7 +6724,7 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger if (dummySpell->SpellIconID == 3030) { // 4 healing tick - basepoints0 = triggerAmount*damage/400; + basepoints0 = triggerAmount * damage / 400; triggered_spell_id = 54203; break; } @@ -6808,7 +6812,8 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger // At melee attack or Hammer of the Righteous spell damage considered as melee attack bool stacker = !procSpell || procSpell->Id == 53595; - bool damager = procSpell && procSpell->EquippedItemClass == ITEM_CLASS_WEAPON; + // spells with SPELL_DAMAGE_CLASS_MELEE excluding Judgements + bool damager = procSpell && procSpell->EquippedItemClass != -1; if (!stacker && !damager) return false; @@ -6839,7 +6844,8 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger // At melee attack or Hammer of the Righteous spell damage considered as melee attack bool stacker = !procSpell || procSpell->Id == 53595; - bool damager = procSpell && procSpell->EquippedItemClass == ITEM_CLASS_WEAPON; + // spells with SPELL_DAMAGE_CLASS_MELEE excluding Judgements + bool damager = procSpell && procSpell->EquippedItemClass != -1; if (!stacker && !damager) return false; @@ -6913,6 +6919,13 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger basepoints0 = CalculatePctN(int32(damage), triggerAmount); break; } + // Item - Paladin T8 Holy 2P Bonus + case 64890: + { + triggered_spell_id = 64891; + basepoints0 = triggerAmount * damage / 300; + break; + } case 71406: // Tiny Abomination in a Jar case 71545: // Tiny Abomination in a Jar (Heroic) { @@ -7239,6 +7252,26 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger } return false; } + // Item - Shaman T10 Elemental 4P Bonus + case 70817: + { + // try to find spell Flame Shock on the target + if (AuraEffect const* aurEff = target->GetAuraEffect(SPELL_AURA_PERIODIC_DAMAGE, SPELLFAMILY_SHAMAN, 0x10000000, 0x0, 0x0, GetGUID())) + { + Aura* flameShock = aurEff->GetBase(); + int32 maxDuration = flameShock->GetMaxDuration(); + int32 newDuration = flameShock->GetDuration() + 2 * aurEff->GetAmplitude(); + + flameShock->SetDuration(newDuration); + // is it blizzlike to change max duration for FS? + if (newDuration > maxDuration) + flameShock->SetMaxDuration(newDuration); + + return true; + } + // if not found Flame Shock + return false; + } case 63280: // Glyph of Totem of Wrath { if (procSpell->SpellIconID != 2019) @@ -7942,6 +7975,9 @@ bool Unit::HandleAuraProc(Unit* pVictim, uint32 damage, Aura * triggeredByAura, if (pVictim->HasAura(53601)) { int32 bp0 = CalculatePctN(int32(damage / 12), SpellMgr::CalculateSpellEffectAmount(dummySpell, 2)); + // Item - Paladin T9 Holy 4P Bonus + if (AuraEffect const* aurEff = GetAuraEffect(67191, 0)) + AddPctN(bp0, aurEff->GetAmount()); CastCustomSpell(pVictim, 66922, &bp0, NULL, NULL, true); return true; } @@ -8014,7 +8050,7 @@ bool Unit::HandleAuraProc(Unit* pVictim, uint32 damage, Aura * triggeredByAura, return false; int32 bp0 = int32(CalculatePctN(GetCreateMana(), SpellMgr::CalculateSpellEffectAmount(spInfo, 0))); - CastCustomSpell(this, 67545, &bp0, NULL, NULL, true, NULL, triggeredByAura->GetEffect(0), GetGUID()); + CastCustomSpell(this, 67545, &bp0, NULL, NULL, true, NULL, triggeredByAura->GetEffect(EFFECT_0), GetGUID()); return true; } } @@ -8037,7 +8073,7 @@ bool Unit::HandleAuraProc(Unit* pVictim, uint32 damage, Aura * triggeredByAura, // can't proc from death rune use if (rune == RUNE_DEATH) return false; - AuraEffect* aurEff = triggeredByAura->GetEffect(0); + AuraEffect* aurEff = triggeredByAura->GetEffect(EFFECT_0); if (!aurEff) return false; // Reset amplitude - set death rune remove timer to 30s @@ -8786,7 +8822,7 @@ bool Unit::HandleProcTriggerSpell(Unit *pVictim, uint32 damage, AuraEffect* trig } // Cast positive spell on enemy target case 7099: // Curse of Mending - case 39647: // Curse of Mending + case 39703: // Curse of Mending case 29494: // Temptation case 20233: // Improved Lay on Hands (cast on target) { @@ -10940,7 +10976,7 @@ bool Unit::isSpellCrit(Unit *pVictim, SpellEntry const *spellProto, SpellSchoolM // Improved Faerie Fire if (pVictim->HasAuraState(AURA_STATE_FAERIE_FIRE)) if (AuraEffect const* aurEff = GetDummyAuraEffect(SPELLFAMILY_DRUID, 109, 0)) - crit_chance+=aurEff->GetAmount(); + crit_chance += aurEff->GetAmount(); // cumulative effect - don't break @@ -10950,7 +10986,7 @@ bool Unit::isSpellCrit(Unit *pVictim, SpellEntry const *spellProto, SpellSchoolM // Improved Insect Swarm if (AuraEffect const* aurEff = GetDummyAuraEffect(SPELLFAMILY_DRUID, 1771, 0)) if (pVictim->GetAuraEffect(SPELL_AURA_PERIODIC_DAMAGE, SPELLFAMILY_DRUID, 0x00000002, 0, 0)) - crit_chance+=aurEff->GetAmount(); + crit_chance += aurEff->GetAmount(); break; } break; @@ -10964,9 +11000,8 @@ bool Unit::isSpellCrit(Unit *pVictim, SpellEntry const *spellProto, SpellSchoolM if (spellProto->SpellFamilyFlags[0] & 0x40000000) { // Sacred Shield - AuraEffect const* aura = pVictim->GetAuraEffect(58597, 1); - if (aura && aura->GetCasterGUID() == GetGUID()) - crit_chance+=aura->GetAmount(); + if (AuraEffect const* aura = pVictim->GetAuraEffect(58597, 1, GetGUID())) + crit_chance += aura->GetAmount(); break; } // Exorcism @@ -11839,7 +11874,7 @@ void Unit::MeleeDamageBonus(Unit *pVictim, uint32 *pdamage, WeaponAttackType att case 6427: case 6428: // Dirty Deeds if (pVictim->HasAuraState(AURA_STATE_HEALTHLESS_35_PERCENT, spellProto, this)) { - AuraEffect* eff0 = (*i)->GetBase()->GetEffect(0); + AuraEffect* eff0 = (*i)->GetBase()->GetEffect(EFFECT_0); if (!eff0 || (*i)->GetEffIndex() != 1) { sLog->outError("Spell structure of DD (%u) changed.", (*i)->GetId()); diff --git a/src/server/game/Instances/InstanceScript.cpp b/src/server/game/Instances/InstanceScript.cpp index 2281caf4e74..c7800b0223c 100755 --- a/src/server/game/Instances/InstanceScript.cpp +++ b/src/server/game/Instances/InstanceScript.cpp @@ -319,24 +319,6 @@ void InstanceScript::DoSendNotifyToInstance(const char *format, ...) } } -// Complete Achievement for all players in instance -void InstanceScript::DoCompleteAchievement(uint32 achievement) -{ - AchievementEntry const* pAE = GetAchievementStore()->LookupEntry(achievement); - Map::PlayerList const &PlayerList = instance->GetPlayers(); - - if (!pAE) - { - sLog->outError("TSCR: DoCompleteAchievement called for not existing achievement %u", achievement); - return; - } - - if (!PlayerList.isEmpty()) - for (Map::PlayerList::const_iterator i = PlayerList.begin(); i != PlayerList.end(); ++i) - if (Player *pPlayer = i->getSource()) - pPlayer->CompletedAchievement(pAE); -} - // Update Achievement Criteria for all players in instance void InstanceScript::DoUpdateAchievementCriteria(AchievementCriteriaTypes type, uint32 miscValue1 /*= 0*/, uint32 miscValue2 /*= 0*/, Unit* unit /*= NULL*/) { diff --git a/src/server/game/Instances/InstanceScript.h b/src/server/game/Instances/InstanceScript.h index b3dcb9525c5..d2c98af0838 100755 --- a/src/server/game/Instances/InstanceScript.h +++ b/src/server/game/Instances/InstanceScript.h @@ -169,9 +169,6 @@ class InstanceScript : public ZoneScript // Send Notify to all players in instance void DoSendNotifyToInstance(char const* format, ...); - // Complete Achievement for all players in instance - DECLSPEC_DEPRECATED void DoCompleteAchievement(uint32 achievement) ATTR_DEPRECATED; - // Update Achievement Criteria for all players in instance void DoUpdateAchievementCriteria(AchievementCriteriaTypes type, uint32 miscValue1 = 0, uint32 miscValue2 = 0, Unit* unit = NULL); diff --git a/src/server/game/Miscellaneous/Language.h b/src/server/game/Miscellaneous/Language.h index 41458ecaf55..bd2c34aef5c 100755 --- a/src/server/game/Miscellaneous/Language.h +++ b/src/server/game/Miscellaneous/Language.h @@ -831,8 +831,8 @@ enum TrinityStrings LANG_BG_IC_REFINERY = 1222, LANG_BG_IC_QUARRY = 1223, LANG_BG_IC_HANGAR = 1224, - LANG_BG_IC_ALLIANCE = 1225, - LANG_BG_IC_HORDE = 1226, + LANG_BG_IC_ALLIANCE = 1300, + LANG_BG_IC_HORDE = 1301, // FREE IDS 1228-9999 diff --git a/src/server/game/Server/Protocol/Handlers/ItemHandler.cpp b/src/server/game/Server/Protocol/Handlers/ItemHandler.cpp index db2c76b422a..84f54786256 100755 --- a/src/server/game/Server/Protocol/Handlers/ItemHandler.cpp +++ b/src/server/game/Server/Protocol/Handlers/ItemHandler.cpp @@ -718,14 +718,14 @@ void WorldSession::HandleListInventoryOpcode(WorldPacket & recv_data) SendListInventory(guid); } -void WorldSession::SendListInventory(uint64 vendorguid) +void WorldSession::SendListInventory(uint64 vendorGuid) { sLog->outDebug(LOG_FILTER_NETWORKIO, "WORLD: Sent SMSG_LIST_INVENTORY"); - Creature *pCreature = GetPlayer()->GetNPCIfCanInteractWith(vendorguid, UNIT_NPC_FLAG_VENDOR); - if (!pCreature) + Creature* vendor = GetPlayer()->GetNPCIfCanInteractWith(vendorGuid, UNIT_NPC_FLAG_VENDOR); + if (!vendor) { - sLog->outDebug(LOG_FILTER_NETWORKIO, "WORLD: SendListInventory - Unit (GUID: %u) not found or you can not interact with him.", uint32(GUID_LOPART(vendorguid))); + sLog->outDebug(LOG_FILTER_NETWORKIO, "WORLD: SendListInventory - Unit (GUID: %u) not found or you can not interact with him.", uint32(GUID_LOPART(vendorGuid))); _player->SendSellError(SELL_ERR_CANT_FIND_VENDOR, NULL, 0, 0); return; } @@ -735,56 +735,62 @@ void WorldSession::SendListInventory(uint64 vendorguid) GetPlayer()->RemoveAurasByType(SPELL_AURA_FEIGN_DEATH); // Stop the npc if moving - if (pCreature->HasUnitState(UNIT_STAT_MOVING)) - pCreature->StopMoving(); + if (vendor->HasUnitState(UNIT_STAT_MOVING)) + vendor->StopMoving(); - VendorItemData const* vItems = pCreature->GetVendorItems(); - if (!vItems) + VendorItemData const* items = vendor->GetVendorItems(); + if (!items) { - WorldPacket data(SMSG_LIST_INVENTORY, (8+1+1)); - data << uint64(vendorguid); - data << uint8(0); // count==0, next will be error code + WorldPacket data(SMSG_LIST_INVENTORY, 8 + 1 + 1); + data << uint64(vendorGuid); + data << uint8(0); // count == 0, next will be error code data << uint8(0); // "Vendor has no inventory" SendPacket(&data); return; } - uint8 numitems = vItems->GetItemCount(); + uint8 itemCount = items->GetItemCount(); uint8 count = 0; - WorldPacket data(SMSG_LIST_INVENTORY, (8+1+numitems*8*4)); - data << uint64(vendorguid); + WorldPacket data(SMSG_LIST_INVENTORY, 8 + 1 + itemCount * 8 * 4); + data << uint64(vendorGuid); - size_t count_pos = data.wpos(); + size_t countPos = data.wpos(); data << uint8(count); - float discountMod = _player->GetReputationPriceDiscount(pCreature); + float discountMod = _player->GetReputationPriceDiscount(vendor); - for (uint8 vendorslot = 0; vendorslot < numitems; ++vendorslot ) + for (uint8 slot = 0; slot < itemCount; ++slot) { - if (VendorItem const* crItem = vItems->GetItem(vendorslot)) + if (VendorItem const* item = items->GetItem(slot)) { - if (ItemTemplate const *pProto = sObjectMgr->GetItemTemplate(crItem->item)) + if (ItemTemplate const* itemTemplate = sObjectMgr->GetItemTemplate(item->item)) { - if ((pProto->AllowableClass & _player->getClassMask()) == 0 && pProto->Bonding == BIND_WHEN_PICKED_UP && !_player->isGameMaster()) + if (!(itemTemplate->AllowableClass & _player->getClassMask()) && itemTemplate->Bonding == BIND_WHEN_PICKED_UP && !_player->isGameMaster()) continue; // Only display items in vendor lists for the team the // player is on. If GM on, display all items. - if (!_player->isGameMaster() && ((pProto->Flags2 & ITEM_FLAGS_EXTRA_HORDE_ONLY && _player->GetTeam() == ALLIANCE) || (pProto->Flags2 == ITEM_FLAGS_EXTRA_ALLIANCE_ONLY && _player->GetTeam() == HORDE))) + if (!_player->isGameMaster() && ((itemTemplate->Flags2 & ITEM_FLAGS_EXTRA_HORDE_ONLY && _player->GetTeam() == ALLIANCE) || (itemTemplate->Flags2 == ITEM_FLAGS_EXTRA_ALLIANCE_ONLY && _player->GetTeam() == HORDE))) continue; + + // Items sold out are not displayed in list + uint32 leftInStock = !item->maxcount ? 0xFFFFFFFF : vendor->GetVendorItemCurrentCount(item); + if (!_player->isGameMaster() && !leftInStock) + continue; + ++count; // reputation discount - int32 price = crItem->IsGoldRequired(pProto) ? uint32(floor(pProto->BuyPrice * discountMod)) : 0; + int32 price = item->IsGoldRequired(itemTemplate) ? uint32(floor(itemTemplate->BuyPrice * discountMod)) : 0; - data << uint32(vendorslot+1); // client expects counting to start at 1 - data << uint32(crItem->item); - data << uint32(pProto->DisplayInfoID); - data << int32(crItem->maxcount <= 0 ? 0xFFFFFFFF : pCreature->GetVendorItemCurrentCount(crItem)); + data << uint32(slot + 1); // client expects counting to start at 1 + data << uint32(item->item); + data << uint32(itemTemplate->DisplayInfoID); + data << int32(leftInStock); data << uint32(price); - data << uint32(pProto->MaxDurability); - data << uint32(pProto->BuyCount); - data << uint32(crItem->ExtendedCost); + data << uint32(itemTemplate->MaxDurability); + data << uint32(itemTemplate->BuyCount); + data << uint32(item->ExtendedCost); } } } @@ -796,7 +802,7 @@ void WorldSession::SendListInventory(uint64 vendorguid) return; } - data.put<uint8>(count_pos, count); + data.put<uint8>(countPos, count); SendPacket(&data); } diff --git a/src/server/game/Server/Protocol/Handlers/SpellHandler.cpp b/src/server/game/Server/Protocol/Handlers/SpellHandler.cpp index b127831bad5..6193b0c6213 100755 --- a/src/server/game/Server/Protocol/Handlers/SpellHandler.cpp +++ b/src/server/game/Server/Protocol/Handlers/SpellHandler.cpp @@ -402,7 +402,7 @@ void WorldSession::HandleCastSpellOpcode(WorldPacket& recvPacket) spellInfo = actualSpellInfo; } - Spell* spell = new Spell(mover, spellInfo, false); + Spell* spell = new Spell(mover, spellInfo, false, 0, false, true); spell->m_cast_count = castCount; // set count of casts spell->prepare(&targets); } diff --git a/src/server/game/Server/WorldSession.h b/src/server/game/Server/WorldSession.h index eb1fd068bc3..f45ee79847c 100755 --- a/src/server/game/Server/WorldSession.h +++ b/src/server/game/Server/WorldSession.h @@ -284,7 +284,7 @@ class WorldSession void SendTrainerList(uint64 guid); void SendTrainerList(uint64 guid, const std::string& strTitle); - void SendListInventory(uint64 guid); + void SendListInventory(uint64 vendorGuid); void SendShowBank(uint64 guid); void SendTabardVendorActivate(uint64 guid); void SendSpiritResurrect(); diff --git a/src/server/game/Spells/Spell.cpp b/src/server/game/Spells/Spell.cpp index f52ce6461b3..17f8b246c83 100755 --- a/src/server/game/Spells/Spell.cpp +++ b/src/server/game/Spells/Spell.cpp @@ -439,7 +439,7 @@ void SpellCastTargets::OutDebug() const sLog->outString("elevation: %f", m_elevation); } -Spell::Spell(Unit* Caster, SpellEntry const *info, bool triggered, uint64 originalCasterGUID, bool skipCheck): +Spell::Spell(Unit* Caster, SpellEntry const *info, bool triggered, uint64 originalCasterGUID, bool skipCheck, bool castedClientside): m_spellInfo(sSpellMgr->GetSpellForDifficultyFromSpell(info, Caster)), m_caster(Caster), m_spellValue(new SpellValue(m_spellInfo)) { @@ -502,6 +502,7 @@ m_caster(Caster), m_spellValue(new SpellValue(m_spellInfo)) m_spellState = SPELL_STATE_NULL; + m_castedClientside = castedClientside; m_IsTriggeredSpell = bool(triggered || (info->AttributesEx4 & SPELL_ATTR4_TRIGGERED)); m_CastItem = NULL; diff --git a/src/server/game/Spells/Spell.h b/src/server/game/Spells/Spell.h index a05ad331776..57fbf815a9d 100755 --- a/src/server/game/Spells/Spell.h +++ b/src/server/game/Spells/Spell.h @@ -386,7 +386,7 @@ class Spell typedef std::set<Aura*> UsedSpellMods; - Spell(Unit* Caster, SpellEntry const *info, bool triggered, uint64 originalCasterGUID = 0, bool skipCheck = false); + Spell(Unit* Caster, SpellEntry const *info, bool triggered, uint64 originalCasterGUID = 0, bool skipCheck = false, bool castedClientside = false); ~Spell(); void prepare(SpellCastTargets const* targets, AuraEffect const* triggeredByAura = NULL); @@ -684,6 +684,7 @@ class Spell uint32 m_timer; bool m_IsTriggeredSpell; + bool m_castedClientside; // if need this can be replaced by Aura copy // we can't store original aura link to prevent access to deleted auras diff --git a/src/server/game/Spells/SpellMgr.cpp b/src/server/game/Spells/SpellMgr.cpp index 4167b9e1516..d6a447bd75f 100755 --- a/src/server/game/Spells/SpellMgr.cpp +++ b/src/server/game/Spells/SpellMgr.cpp @@ -3823,7 +3823,6 @@ void SpellMgr::LoadSpellCustomAttr() case 45641: // Fire Bloom case 55665: // Life Drain - Sapphiron (H) case 28796: // Poison Bolt Volly - Faerlina - case 5484: // Howl Of Terror (Warlock) spellInfo->MaxAffectedTargets = 5; ++count; break; @@ -4176,7 +4175,6 @@ void SpellMgr::LoadSpellCustomAttr() spellInfo->AreaGroupId = 0; // originally, these require area 4522, which is... outside of Icecrown Citadel ++count; break; - case 70588: // Suppression case 70602: // Corruption spellInfo->AttributesEx |= SPELL_ATTR1_STACK_FOR_DIFF_CASTERS; ++count; @@ -4227,9 +4225,6 @@ void SpellMgr::LoadSpellCustomAttr() // Starfall Target Selection if (spellInfo->SpellFamilyFlags[2] & 0x100) spellInfo->MaxAffectedTargets = 2; - // Starfall AOE Damage - else if (spellInfo->SpellFamilyFlags[2] & 0x800000) - mSpellCustomAttr[i] |= SPELL_ATTR0_CU_EXCLUDE_SELF; // Roar else if (spellInfo->SpellFamilyFlags[0] & 0x8) mSpellCustomAttr[i] |= SPELL_ATTR0_CU_AURA_CC; |
