aboutsummaryrefslogtreecommitdiff
path: root/src/game/DynamicObject.cpp
AgeCommit message (Collapse)Author
2010-04-07Code style (game + scripts only):Spp
"( " --> "(" " )" --> ")" --HG-- branch : trunk
2010-04-07Code style (game + scripts only):Spp
"if(" --> "if (" --HG-- branch : trunk
2010-04-07Code Style: Remove trailing spacesSpp
--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-02-11Fixed persistent area aura visual radii (flamestrike, consecration etc.). ↵Xanadu
Thanks to QAston and _manuel_ for research. Closes issue 522. Closes issue 719. --HG-- branch : trunk
2010-01-16Updated copyright for new year.n0n4m3
--HG-- branch : trunk
2010-01-16*Fix single target auras related crashQAston
*Apply aura stacking rules to m_ownedAuras holder. --HG-- branch : trunk
2010-01-12*Make sure that any aura (in case of aura remove linked auras for example) ↵QAston
won't survive Unit::RemoveAllAuras. --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
2009-12-20*apply trinity style to whole sourceRat
*comment out all mangos to trinity defines *this will make merging a little harder, but code will be more clear --HG-- branch : trunk
2009-12-17Some fixes for GameObject, Chat, Creature, update DuelHandler for 322an0n4m3
--HG-- branch : trunk
2009-10-17*Massive cleanup redux.maximius
--HG-- branch : trunk
2009-10-17*Backed out changeset 3be01fb200a5maximius
--HG-- branch : trunk
2009-10-17*Massive cleanup (\n\n -> \n, *\n -> \n, cleanup for(...) to for (...), and ↵maximius
some other cleanups by hand) *Fix a possible crash in Spell::DoAllEffectOnTarget --HG-- branch : trunk
2009-09-27*Merge [8524] New cell search algorithm implemented. You can now choose ↵maximius
different visibility distances on continents, in BG/Arenas and instances. Author: Ambal *Some warning cleanup --HG-- branch : trunk
2009-09-26*Gundrak: GO Handling & Slad Ran script by Tartalomaximius
*Cleanup, and don't consider creatures to be in combat if they have no victim, or if their victim is a GM. --HG-- branch : trunk
2009-08-29*More update about positions.megamage
*Ulduar: do not allow demolisher to regenerate pyrite. Player must shoot down and grab the containers to refill pyrite. --HG-- branch : trunk
2009-08-27*Use one dynobj to handle multiple aura effects.megamage
--HG-- branch : trunk
2009-08-11*Only use m_isWorldObject to check if an object is in grid or world.megamage
--HG-- branch : trunk
2009-08-01*Improvements in map managing.QAston
--HG-- branch : trunk
2009-07-16 [8182] Store and use Map* pointer in WorldObject instead map ids for ↵megamage
speedup Author: Ambal Also some code logic cleanups. Changes let make more cleanups in base map access and other places, but this chnages not inlcuded in patch. *This patch may cause crash. --HG-- branch : trunk
2009-06-11*Switch to support client version 3.1.3megamage
*I strongly recommend you not to use this until you get the 313 db. Now all destructible buildings cause client crash. Source: Mangos Thanks to TOM_RUS for most work to make this switch possible ;) --HG-- branch : trunk
2009-06-06[7967] Removed unused field. Author: tomrus88megamage
--HG-- branch : trunk
2009-04-30*Merge.megamage
--HG-- branch : trunk
2009-04-30*Change the radius of dynamic object to normal. I cannot see any bug by ↵megamage
myself using normal radius. --HG-- branch : trunk
2009-04-06*Update of aura system.QAston
--HG-- branch : trunk
2009-03-28*First remove object from world then unregister it. This may fix some crashes.megamage
--HG-- branch : trunk
2009-03-26*Remove viewpoint when dynamicobject is removed from world.megamage
--HG-- branch : trunk
2009-03-25*Merge.megamage
--HG-- branch : trunk
2009-03-25*Do not allow to add/remove obj to/from world more than once.megamage
--HG-- branch : trunk
2009-03-25*Fix dynamic object radius. Backported from TC2.megamage
--HG-- branch : trunk
2009-03-23*Try to fix the bug that dynamic object has too small size.megamage
--HG-- branch : trunk
2009-03-21*Remove dual ERROR in logs Author: AlexDerekamegamage
--HG-- branch : trunk
2009-03-10*Update bind sight spells code.megamage
--HG-- branch : trunk
2009-03-08[7403] much more unneeded includes removed Author: balrokmegamage
--HG-- branch : trunk
2009-03-05*Merge.megamage
--HG-- branch : trunk
2009-03-05*Do not let farsight dynobj apply non-exist auras. This fixed farsight.megamage
--HG-- branch : trunk
2009-02-26*Merge.megamage
--HG-- branch : trunk
2009-02-26*Update active object code.megamage
--HG-- branch : trunk
2009-02-25*Update active object code. By VladimirMangos.megamage
--HG-- branch : trunk
2009-02-22*Merge.megamage
--HG-- branch : trunk
2009-02-22*Check IsInWorld() when calling GetMap() in RemoveFromWorld(). This may fix ↵megamage
some crash bugs. --HG-- branch : trunk
2009-02-18*Merge.megamage
--HG-- branch : trunk
2009-02-17*Merge.megamage
--HG-- branch : trunk
2009-02-17*Fix some bugs of map/grid. Hope this can fix some crashes (without ↵megamage
introducing new crash) --HG-- branch : trunk
2009-02-17Newline added to bottom of all files.KingPin
--HG-- branch : trunk
2009-02-04Replace tabs with spaces, and fix crlf issuesmegamage
--HG-- branch : trunk
2009-02-04*Merge.megamage
--HG-- branch : trunk
2009-02-04*Merge.megamage
--HG-- branch : trunk
2009-02-04* Updated copyright notice for new year (2009) part 2Drahy
* Changed mangos website --HG-- branch : trunk