This reverts commit d5f6eefd1bb3c64797e54d19cc58ccc8c4cf8a4f.
Some 3.0.x talents not work without this like 44441
Signed-off-by: VladimirMangos <vladimir@getmangos.com>
* Use AI::AttackStart calls only in case explicit request creature attack from core or AI code "attack it if can".
Like taunt, pet handler attack command.
* Use AI::AttackedBy for reaction at hostile action "do something at hostile action"
Like non-dot damage, swing, negative spell landing, or fade fear/etc.
And provided by default call AttackStart if no current target.
This fix some problems, like:
* Civilian will react propertly at attack by another creature (not pet or player).
* Will not cases (at least triggred by core) when attack target start run to attacker before any real hostile action apply.
Also send pointer to AI constructors ans mark constructors as explicit.
This changes allow move now some generic often used AI code to CreatureAI helper functions.
Signed-off-by: VladimirMangos <vladimir@getmangos.com>
Also fix problems with talent 58426 and 31223 work in case
* fast stealth reapply after stealth lost
* second stealth aura apply while another active.
Signed-off-by: VladimirMangos <vladimir@getmangos.com>
Signed-off-by: VladimirMangos <vladimir@getmangos.com>
Also fixed problem with remembering transform spell in case possible stacked negative and positive transforms.
Move near teleport landing code to WorldSession::HandleMoveTeleportAck.
This make Player::TeleportTo code working in same way for both far/near teleports.
Move mSemaphoreTeleport from WorldObject to Player and merge with DoNotMove (using 2 fields for far/near teleport flag).
Skip movement packets until landing confirmation for near teleport from client.
* Save temporary unsummoned pet to current slot (instead non_in_slot mode) and
prevent save as current pet summoned while temporay unsummon (arena)
* Prevent overwrite temporary summoned pet data
* At player loading set temporary unsummoned pet data instead pet loading
if pet expected to be temporary unsummoned in current player state (loading in taxi flight/etc)
* Restore proper pet at arena leave and unsummon in arena summoned.
Problem exist from client version switch when stable slot amount changed.
In result this has been source problems with stable use (3-4 slots) and possible pet lost in some cases
or "not save state" for summoned pets.
Use enums to avoid repeating problem, use more safe value for not-in-slot save (for summoned pets)
Fixed data preparing for MSG_LIST_STABLED_PETS.
Many in world gameobject that unexpected daspawned before must now work in more expected way.
In tests i not found any damage to bg gameobject work, and at least this restore expected work for non-bg dorrs//buttons broken
after half-year ago patch (that has been reverted partly in this commit)
Signed-off-by: VladimirMangos <vladimir@getmangos.com>
Moved method BattleGroundMrg::InvitePlayer to BattleGroundQueue::InviteGroupToBG
Added some comments to RemindInvite and RemoveInvite events.
Optimalise code.
Signed-off-by: Triply <triply@getmangos.com>