aboutsummaryrefslogtreecommitdiff
path: root/src/game/Spell.cpp
AgeCommit message (Collapse)Author
2010-03-11Convert some C style casts to new functionsthenecromancer
--HG-- branch : trunk
2010-03-09Fix enchant items in trade window.Spp
Original patch by Kierkegaard closes issue #985 --HG-- branch : trunk
2010-03-09Rename 'Hostil' to 'Hostile'Spp
Credits to NoFantasy (Mangos) Closes issue #411 --HG-- branch : trunk
2010-03-07Some Creature* casts moved to new ToCreature.raczman
Added const Creature* ToCreature() --HG-- branch : trunk
2010-03-07Added new type-safe cast functions.raczman
This, when properly used, should get rid of most memory corruption issues, currently, casting types C-style with no checks leads to some abstract crashing. Functionality is same as with dynamic_cast<>, but with no RTTI check - so when casting into invalid type you will receive NULL, and most probably crash. At the same time, i took the liberty to convert most Player* casts to ToPlayer(). Still needs crapload of casts being moved to new facility. --HG-- branch : trunk
2010-03-07Remove 94567c94e6, instead don't check range/facing when finishing instant ↵thenecromancer
cast spells --HG-- branch : trunk
2010-03-02If stealth-only spell fails, shouldn't remove you from stealth. Fix by ↵p0wer
lol584. Closes issue #99. --HG-- branch : trunk
2010-02-27refactor UnitAI::SelectTarget to allow having a predicate function (1st step).Trazom62
--HG-- branch : trunk
2010-02-22*Remove no longer needed hack after trigger target fixes.QAston
--HG-- branch : trunk
2010-02-20*CRLF:(QAston
--HG-- branch : trunk
2010-02-20*Move summon water elemental handler to correct place.QAston
--HG-- branch : trunk
2010-02-20Don't take away runes when not hittingthenecromancer
--HG-- branch : trunk
2010-02-18Treat rune cooldowns as timers and not as remaining tick countsthenecromancer
Implement support for modifiers changing rune regeneration rate Apply all spells from Improved Unholy Aura --HG-- branch : trunk
2010-02-17Compile fix.raczman
Whoever pushed that, *PLEASE* do a test compile before pushing. --HG-- branch : trunk
2010-02-16* Removed hack for summon water elementalBrian
* Proper handling for Glyph of Eternal Water * Summoned water elemental still doesn't last forever, but the right spells * are cast in the right situations. * Credits to Edrinn --HG-- branch : trunk
2010-02-15*Backout some WTF fixes. Do things correctly, or do not touch them at all...QAston
*Really fix windows build. --HG-- branch : trunk
2010-02-15Fix talent Shockwave and typo in comment.n0n4m3
--HG-- branch : trunk
2010-02-15Add missing changes for rev b7d758f3e5n0n4m3
--HG-- branch : trunk
2010-02-15Removed stupid/not needed file Spellid.h.n0n4m3
--HG-- branch : trunk
2010-02-15Store to be traded items in array based on item guid instead of item slot to ↵Machiavelli
prevent exploiting. Fixes #667. --HG-- branch : trunk
2010-02-14* Core switch to client 3.3.2 (11403)Brian
* Credits (in no particular order) to: * n0n4m3, raczman, manuel, Spp, Malcrom, Teacher, QAston, Tartalo, * thenecromancer, Xanadu, Trazom, Zor, kiper * Additional credits to: * TOM_RUS and NoFantasy from MaNGOS * Thanks for testing Aokromes and XTElite1 * SoTA still needs some work, but is very playable (huge thanks to raczman and * kiper) * To upgrade, you need to apply all SQL from sql/updates/3.2.2a_old from the * last rev you are on * and then apply all SQL from sql/updates/3.3.2_old to char / realmd / world * DBs * Known problem with guild banks. --HG-- branch : trunk
2010-02-05Yet more cleanup, mostly in the script system. This should conclude the ↵Xanadu
script integration into core. --HG-- branch : trunk
2010-02-04*Implement spell target type TARGET_GAMEOBJECT_NEARBY_ENTRYQAston
--HG-- branch : trunk
2010-01-27Fixed hunter trap procs - Entrapment and Lock and Load shall be henceforth ↵Xanadu
proced only by the correct traps. Closes issue #110. --HG-- branch : trunk
2010-01-25*Some cleanup in SharedDefinesQAston
*Implement spell target modes 96-103, 91, 92 --HG-- branch : trunk
2010-01-25Backed out changeset: 4cc8628cc8ef. That wasn't a good call. Thanks go to ↵Xanadu
QAston for pointing it out to me. --HG-- branch : trunk
2010-01-24Fix Entrapment - now only proc on Frost Trap and Snake Trap activation.Xanadu
--HG-- branch : trunk
2010-01-24*Bring back one unintentionally removed check in Aura::UpdateOwnerQAston
*Remove not blizzlike hack for Vanish (it should not remove delayed spells from player) --HG-- branch : trunk
2010-01-24Add support for Maelstrom Weapon to prevent melee attack interruption when ↵thenecromancer
affecting spells --HG-- branch : trunk
2010-01-24*Do not keep area aura targets in combat with aura ownerQAston
*Add some safety checks to area aura target map update. --HG-- branch : trunk
2010-01-23* Remove CellLock class and all cell-level thread locking.XTZGZoReX
** It was wasting CPU power as cell-level locking is not needed. ** Our multithreading is on map-level, not cell-level. ** CellLock was just a 'proxy' between Cell and CellPair and in some cases carried redundant data. ** Some minor cleanup in Cell::Visit/Map::Visit. --HG-- branch : trunk
2010-01-23Apply SPELLMOD_COST in takeRunePower() ( replacement for removed hack in ↵thenecromancer
previous commit ) --HG-- branch : trunk
2010-01-23Fix Empowered Rune Weaponthenecromancer
Cleanup cast flags --HG-- branch : trunk
2010-01-19*Integrate Script system to CoreRat
-added ScriptMgr for loading scripts -removed bindings -moved script system to src/game -moved scripts to src/scripts -VC project files updated -cmakes updated (not 100% done yet) NOTE to Devs: -file locations changed -precompiled renamed to ScriptedPch -ecsort_ai renamed to ScriptedEscortAI -follower_ai renamed to ScriptedFollowerAI -guard_ai renamed to ScriptedGuardAI -simple_ai renamed to ScriptedSimpleAI -sc_creature renamed to ScriptedCreature -sc_gossip renamed to ScriptedGossip -sc_instance renamed to ScriptedInstance *use the new headers in scripts, thank you NOTE to ALL: cmake not fully tested, please report any errors with it could make creashes, incompability USE AT YOUR OWN RISK before further tests!! --HG-- branch : trunk
2010-01-16Updated copyright for new year.n0n4m3
--HG-- branch : trunk
2010-01-13* Fix CRLF.XTZGZoReX
--HG-- branch : trunk
2010-01-13Fix pickpocket - reveal rogue only if spell is resistedthenecromancer
--HG-- branch : trunk
2010-01-13Some more casting requirementsthenecromancer
*Not allow cast on invisible/stealth target if not detected *Not allow banish/cyclone tapped unit *Not allow pickpocket players and units that can never be pickpocketed *Not allow disarm unarmed units --HG-- branch : trunk
2010-01-13Change SPELL_EFFECT_SUMMON_PHANTAS to SPELL_EFFECT_FORCE_DESELECT and allow ↵thenecromancer
it to be casted with active pet This fixes Mirror Image not changing names when Water Elemental is active. (Note that deselect effect is done in linked spells for Killing Spree/Shadowmeld) --HG-- branch : trunk
2010-01-13Check if precast spell exists before trying to cast it. (Otherwise ↵thenecromancer
charge-like spells spam console a lot) --HG-- branch : trunk
2010-01-13Remove hack for Freezing Fog aura.thenecromancer
Instead apply modifier directly to rune cost ( this will also fix runic power generation in that case ) --HG-- branch : trunk
2010-01-11Do not compute incoming time for self casts.Astellar
--HG-- branch : trunk
2010-01-10Fixed quest Catch and Release, some fixes for Tag Murloc spell.Astellar
--HG-- branch : trunk
2010-01-10*cleaned up SharedDefinesRat
--HG-- branch : trunk
2010-01-10*fix spell: Tag Murloc (30877)Rat
--HG-- branch : trunk
2010-01-10Update aura system:QAston
* Change system logic - unify Auras, AreaAuras and PersistentAreaAuras: * Aura has now its owner - which is the WorldObject, which applies aura (creates AuraApplication object) dependant on aura radius, and effect type * Owner can be Dynobj (DynObjAura class) for PersistentAreaAuras, or Unit (UnitAura class) for Area and nonArea auras * Aura data is shared for all units which have AuraApplication of the Aura * Because of that AuraEffect handlers , and periodic tick functions can't modify AuraEffect object (they are const now) * Remove spell source and AreaAuraEffect classes * Add AuraEffect::UpdatePeriodic function, to allow periodic aura object modification (target independant) * Add AuraEffect::CalculateAmount and AuraEffect::CalculateSpellMod function, to allow non-default amount calculation * AreaAura updates are done in owner _UpdateSpells cycle * Since now you don't need to wait an aura update cycle to get area aura applied on it's correct target list * And you can access area aura target list * Add basic support for aura amount recalculation * Save recalculation state and base amount of auras to db * Add AuraEffect::CalculatePeriodic function to determine if aura is periodic, and to set correct tick number after aura is loaded from db * Add ChangeAmount function in addition to SetAmount function, to allow easy reapplication of AuraEffect handlers on all targets * Sort aura effect handlers in SpellAuras.cpp and .h by their use * Add check for already existing aura of that type to some AuraEffect handlers, to prevent incorrect effect removal * SPELL_AURA_CONVERT_RUNE and MOD_POWER_REGEN and MOD_REGEN hacky handlers are now implemented correctly * Send aura application client update only once per unit update - prevent unnecesary packet spam * Fix ByteBuffer::appendPackGUID function - it added additionall 0s at the end of the packet * Fix memory leak at player creation (not deleted auras) * Updated some naming conventions (too many to mention) * Added Unit::GetAuraOfRankedSpell() function * Remove procflags on aura remove, use Aura::HandleAuraSpecificMods instead * Added functions to maintain owned auras (GetOwnedAuras, GetOwnedAura, RemoveOwnedAura, etc) * Implement AURA_INTERRUPT_FLAG_LANDING * Implement EffectPlayerNotification (thanks to Spp) * Remove wrong aura 304 handler * Add better handler for death runes * Remove unnecesary variables from DynamicObject class, and cleanup related code, link dynobj duration with aura * Add GetAuraEffectTriggerTarget function in CreatureAi for special target selection for periodic trigger auras used in a script * Add many assert() procection from idiots using some functions in wrong way * I am to lazy to write here anything more Thanks to Visagalis for testing this patch PS: Do not make patches like this, please --HG-- branch : trunk
2010-01-06mergesilver1ce
--HG-- branch : trunk
2010-01-06fixed the bug that GetVmapHeight returns incorrect height on terrains(flying ↵silver1ce
units fall below map etc) also unlocked max ray lenght for getHeight, by default it's 10 yards --HG-- branch : trunk
2010-01-06Fixed Issue 11. Now combo points are kept when finishing move misses. Revert ↵Astellar
it if it's wrong. --HG-- branch : trunk
2009-12-31Add support for TARGET_UNIT_DRIVER where the target must be controlling a ↵p0wer
vehicle. Should fix 63665 used for ToC. --HG-- branch : trunk