Commit Graph

145 Commits

Author SHA1 Message Date
QAston
3f6999f744 *Some cleanup in SharedDefines
*Implement spell target modes 96-103, 91, 92

--HG--
branch : trunk
2010-01-25 12:40:03 +01:00
thenecromancer
e893ad71cf Fix Empowered Rune Weapon
Cleanup cast flags

--HG--
branch : trunk
2010-01-23 16:06:06 +01:00
n0n4m3
99f66a6bc9 Updated copyright for new year.
--HG--
branch : trunk
2010-01-16 20:19:18 +03:00
thenecromancer
c36a8d2d5f Change SPELL_EFFECT_SUMMON_PHANTAS to SPELL_EFFECT_FORCE_DESELECT and allow 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-13 10:27:44 +01:00
QAston
8e9d2cdf01 Update aura system:
* 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-10 01:23:15 +01:00
n0n4m3
947b258479 Fixed Mana Gems, implement SPELL_EFFECT_CREATE_MANA_GEM and revert prev. commit...
--HG--
branch : trunk
2009-12-26 18:25:49 +01:00
Rat
6fe36efe0f *apply trinity style to whole source
*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-20 15:20:04 +01:00
n0n4m3
3e133c4786 [9012] fix crash when achievement is completed and player isn't in world
--HG--
branch : trunk
2009-12-17 19:09:40 +01:00
n0n4m3
515cf192ef Update Spell code for 322a. Part 1
--HG--
branch : trunk
2009-12-17 12:18:10 +01:00
tartalo
5b7ef6fd2f Set proper orientation after being teleported by spell, by Spp. Closes #100
--HG--
branch : trunk
2009-11-07 18:47:11 +01:00
maximius
3f338cc1c3 *Massive cleanup redux.
--HG--
branch : trunk
2009-10-17 16:20:24 -07:00
maximius
e585187b24 *Backed out changeset 3be01fb200a5
--HG--
branch : trunk
2009-10-17 15:51:44 -07:00
maximius
26b5e033ff *Massive cleanup (\n\n -> \n, *\n -> \n, cleanup for(...) to for (...), and some other cleanups by hand)
*Fix a possible crash in Spell::DoAllEffectOnTarget

--HG--
branch : trunk
2009-10-17 15:35:07 -07:00
maximius
2bb0c31978 *[8474] Allow to delete BattleGround objects when any of invited players didn't click to enter battle. Rename m_TeamScores500disadvantage to m_TeamScores500Disadvantage, and optimize its update. Patch is tested. Author: Triply
*Added some missed changes that might of broken compile in the last 2~ commits.
*Some fixes to Warlock's Death Coil by Gyullo.
*Last MaNGOS merge until KingPin says otherwise..

--HG--
branch : trunk
2009-09-11 16:25:11 -07:00
megamage
d802cd3811 *More update about positions.
*Ulduar: do not allow demolisher to regenerate pyrite. Player must shoot down and grab the containers to refill pyrite.

--HG--
branch : trunk
2009-08-29 23:20:16 -05:00
megamage
2a4c9bcaf9 *Make position as a class;
--HG--
branch : trunk
2009-08-29 14:58:45 -05:00
megamage
eeb18e51bb *Correctly process more movement packets. Author: VladimirMangos
--HG--
branch : trunk
2009-08-27 20:14:50 -05:00
megamage
ee3c766bc9 *Use one dynobj to handle multiple aura effects.
--HG--
branch : trunk
2009-08-27 16:41:10 -05:00
megamage
b35fe879ad *Some update of spell target selection.
--HG--
branch : trunk
2009-08-23 00:46:21 -05:00
megamage
21ffda7eaf *Consider target size for AOE spells.
--HG--
branch : trunk
2009-08-22 21:29:43 -05:00
megamage
012d6fa865 [8381] Some refactoring work in Unit::m_currentSpells code. Author: VladimirMangos
* Restrict access, use enum args, move some repeated code parts to function.
    * Make m_selfContainer set only part of Unit::SetCurrentCastedSpell

--HG--
branch : trunk
2009-08-19 16:52:51 -05:00
maximius
2fd68eab44 *Add Dual Spec support, original by EnderGT, thanks to Thyros and XTElite1 for helping me test :)
--HG--
branch : trunk
2009-08-14 17:24:52 -07:00
QAston
e2e70b936b *Cleanups and obsolete spell handlers remove.
--HG--
branch : trunk
2009-08-11 19:57:27 +02:00
megamage
9dcaf30500 [8220] Implement SPELL_EFFECT_PLAY_MUSIC(132) Author: evilstar
Thanks to GriffonHeart for help in reseach.

--HG--
branch : trunk
2009-07-30 10:18:05 +08:00
QAston
4a17224a65 *Creature eventAI cancast power check - by smellbee.
--HG--
branch : trunk
2009-07-23 18:32:32 +02:00
megamage
9c9c9f5078 [8089] Implement SPELL_EFFECT_CHARGE2(149), more correct monster flags use in charge effects. Author: VladimirMangos
Last fix let for example correct charge for flight creatures...

--HG--
branch : trunk
2009-07-01 17:36:34 -05:00
QAston
4067989096 *Implement aura rank selection for aoe auras casted by player
*More correct level requirement checks for unit target
*Fix some visual issues with spells which are interrupted after SendSpellStart but before SendSpellGo
*Prevent adding spellmods permamently to already finished spells.

--HG--
branch : trunk
2009-06-29 20:32:56 +02:00
QAston
33b2917bb7 *Fix Ferocious Bite energy to dmg conversion
*Remove duplicated AP coefficients for Hammer of Wrath and Avengers Shield
*Correctly do effectaddcombopoints for spells which take them.
*Do not proc spelleffects on player login.

--HG--
branch : trunk
2009-06-24 15:58:44 +02:00
QAston
f558a785fc [8069] Fixed copy/paste mistake in achievement error output. Author: Saeba
[8070] Restore spell casting loot items and recipes.

* SPELL_EFFECT_OPEN_LOCK_ITEM (59) effect removed in 3.1.3
* It replaced by SPELL_EFFECT_CREATE_RANDOM_ITEM (59), random item without
template replace spells like clam loot spells)
  Used by spells that use before SPELL_EFFECT_CREATE_ITEM_2 (157) with
  itemtype==0

Note: required DB support in `spell_loot_termplate` Author: VladimirMangos

--HG--
branch : trunk
2009-06-23 14:44:16 +02:00
megamage
a2f10c496f [8030] Fixed spell 64901 work and related target selection code refactoring. Author: VladimirMangos
* Replace 64904 by 64901 in spellbook and action bars.
    * Implement proper max mana percent buff
    * Implement proper target selection.
    * Move group/raid targets seelction code to functions for reuse code.

--HG--
branch : trunk
2009-06-17 18:35:40 -05:00
megamage
74e4f3f059 *Merge.
--HG--
branch : trunk
2009-06-15 23:38:57 -05:00
megamage
9055f25030 *Fix a bug that dark rider of dk quest cannot be attacked.
--HG--
branch : trunk
2009-06-15 12:12:22 -05:00
QAston
425863abd9 *Fix dead loop in proc system.
*Fix curse of doom.

--HG--
branch : trunk
2009-06-15 17:15:19 +02:00
megamage
314a4f8f00 [8008] Fixed SMSG_RAID_INSTANCE_MESSAGE opcode. Author: tomrus88
--HG--
branch : trunk
2009-06-14 10:06:41 -05:00
megamage
375641398a [7983] Make static Spell::SendCastResult accessable from script DLL. Author: VladimirMangos
--HG--
branch : trunk
2009-06-10 14:37:30 -05:00
megamage
4e130dcdfd [7980] Implement item use target requirements store and check (new table item_required_target). Author: NoFantasy
Signed-off-by: VladimirMangos <vladimir@getmangos.com>

    * Also implement this table reload
    * Static Spell::SendCastResult function for call not from spell code.
      Can be also used in scripts where need send explicitly spell cast error to client.

--HG--
branch : trunk
2009-06-08 17:25:02 -05:00
Machiavelli
91e9b27449 * Fix bug that potions and other energize effects make client display twice as much of a gain, by nos4r2zod.
* Rename 'EffectEnergisePct' to 'EffectEnergizePct'

--HG--
branch : trunk
2009-06-08 21:19:34 +02:00
krz
c7c092f54b Calculate spell critical hit chance at spell cast instead spell hit. Patch by thenecromancer.
--HG--
branch : trunk
2009-06-07 19:10:01 +02:00
QAston
39548d6822 *Update spellmod system
*Implement SPELL_ATTR_EX6_IGNORE_CASTER_AURAS
*Fix some bugs with traps proc flags

--HG--
branch : trunk
2009-06-06 08:27:36 +02:00
megamage
c2588042e9 *Move some random generator functions to map class: functions in map/object/movementgenerator/spell
--HG--
branch : trunk
2009-05-25 12:05:23 -05:00
megamage
4ed847a6e3 *Implement spell effect wmo damage.
--HG--
branch : trunk
2009-05-21 10:01:03 -05:00
megamage
6f8dc61871 *Record target live state at filltarget and check live state at doeffect.
--HG--
branch : trunk
2009-05-20 12:58:38 -05:00
QAston
7c6757d7ee *Update proc system.
--HG--
branch : trunk
2009-05-17 18:00:33 +02:00
megamage
a5df3c9e72 *Do not allow positive AOE affect totem.
--HG--
branch : trunk
2009-05-16 15:28:58 -05:00
megamage
047cc95388 *Add some distance check functions. By VladimirMangos.
--HG--
branch : trunk
2009-05-14 16:50:47 -05:00
megamage
904300b4c2 *Use better summon positions for summon spells with more than one summons. (Still a temp fix)
--HG--
branch : trunk
2009-05-10 22:47:03 -05:00
megamage
b8e82a23a6 [7808] Move corpse search code in function with template arg for class-check. Author: Astellar
This let reuse code for other similar near corpse target selection spells.
    Also provided currently not used class-checks for 2 spells

--HG--
branch : trunk
2009-05-10 14:47:56 -05:00
megamage
979073cebd *Update some spell attr flag. Use better way to check IsRangedSpell and UnaffectedByInvulnerability
--HG--
branch : trunk
2009-05-08 00:49:02 -05:00
megamage
84fc76439c *Fix a crash caused by feedpet.
*Also have delay for jump spells.

--HG--
branch : trunk
2009-05-03 16:29:33 -05:00
megamage
eeeae2e349 *Merge.
--HG--
branch : trunk
2009-05-02 19:45:55 -05:00