Commit Graph
28009 Commits
Author SHA1 Message Date
Shauren 176cb72b70 Core/PacketIO: Fixed SMSG_INSPECT_RESULT structure 2019-07-28 16:14:14 +02:00
MaxtorCoder 2e8d7194a9 Core/PacketIO: Fixed inspect client crash 2019-07-28 16:14:14 +02:00
Shauren f2ef5f878d Core/PacketIO: Added missing packet array size checks 2019-07-28 00:07:19 +02:00
Shauren 168fd20709 Core/Proto: Update client protobuf messages 2019-07-27 14:11:46 +02:00
Shauren 13440434c3 Core/DBLayer: Prevent mixing databases with query holders 2019-07-27 11:45:56 +02:00
Shauren f6e2b8cdc1 Core/DBLayer: Prevent committing transactions started on a different database 2019-07-27 10:52:33 +02:00
Shauren e8e89f58fb Core/DBLayer: Prevent using prepared statements on wrong database 2019-07-27 01:00:37 +02:00
Shauren 1dcbceba81 Nopch fix4 2019-07-26 19:09:29 +02:00
Shauren d211d20b8d Nopch fix3 2019-07-26 19:00:34 +02:00
Shauren 030cb72bdc Nopch fix2 2019-07-26 18:58:37 +02:00
Shauren d57f020a34 Nopch fix 2019-07-26 18:31:45 +02:00
Shauren 71cbb0ae1c Core: Updated allowed build to 8.2.0.31229 2019-07-26 18:25:25 +02:00
treeston 6455f1c256 DB/Creature: The instance_encounters extra flag (CREATURE_FLAG_EXTRA_DUNGEON_BOSS) now properly propagates to all difficulty entries (not just difficulty 0).
This lets us simplify IsDungeonBoss() on Creature (and move it to header).

Closes #18824.

(cherrypicked from 1beb2e5fd6e85332173b1f3e414d5b385c3022fb)
2019-07-21 21:06:54 +02:00
r00ty-tc 83e2777249 [Core/AH] Correctly check player can pay deposit
- Deposit amount wasn't correctly checked in the case of multiple items,
   player with insufficient funds could auctin more items than they should

(cherrypicked from 6bd9aa27872cd0d76d785bc38162001c4bacd913)
2019-07-21 21:06:54 +02:00
xinef1 fb5c07ffe8 Fixed setting and unsetting of m_spellModTakingSpell (#19116)
- A problem when a different spell tries to overwrite existing ModTakingSpell should no longer happen

(cherrypicked from e261754c9cd8b14a0555e866b4e193e1fe3c25ae)
2019-07-21 21:06:54 +02:00
xinef1 ecb44f82a4 Core/Creatures: Remove template immunities only for hunter pets (#19100)
(cherrypicked from 949b38b0481a752db124f8a3dbc1251d5b98b7cf)
2019-07-21 21:06:54 +02:00
xinef1 fc9f00d351 Core/Spells: Fixed some item ranged spells dealing wrong damage (#19104)
(cherrypicked from e7a9549422b09da6c88b0a191bae072997cbeddb)
2019-07-21 21:06:54 +02:00
xinef1 cfefd27cb8 Added some missing SetFallInformation calls (#19121)
Fixed HP drop bug on zeppelins
Fixed possible packet relocation problems on huge transports

(cherrypicked from b3f04ec1570c7fd6ef0d1dacfb7ff9f8ab00a43d)
2019-07-21 21:06:54 +02:00
xinef1 89f728cd5b Core/Misc: Fixed player corpse looting, added player corpse loot and some more (#19122)
* Fixed corpse looting in wintergrasp
Added corpse loot for wintergrasp quests and To the Looter Go the Spoils (1166) achievement
Don't generate money for loot if no loot mode is available
Simplified few things

(cherrypicked from 2412886ef69d305df1bd6e6422ca3134c0ab1449)
2019-07-21 21:06:54 +02:00
Gustavo c860522ecf Core/Scripts Update boss Skadi the Ruthless (#19114)
(cherrypicked from 4536846d7d30508a046f394d1f561a2c3fdcf5f0)
2019-07-21 21:06:54 +02:00
jackpoz 5b78f19879 Core/Misc: Fix static analysis issues
(cherrypicked from 865a3a47eaa518cb9c7827e863d679697e38b03e)
2019-07-21 21:06:54 +02:00
ariel- 4ce758a726 Update spell_item.cpp
Small indent and codestyle fixes

(cherrypicked from 149e449506abd75add8f9a73f744860e1e5ad0ae)
2019-07-21 21:06:54 +02:00
xinef1 4f65dc5e20 Core/Misc: Various crash fixes (#19059)
* Replaced some FindPlayer calls with GetPlayer
Fixed some more crashes

* Correction

(cherrypicked from 14dfc377b48bc909894396e65d4e4ce89d9708b6)
2019-07-21 21:06:54 +02:00
xinef1 ad4e63bae1 Core/Misc: Moved CharacterInfo out of world to separate class
Closes #19030

(cherrypicked from 59ce3d6c9bd82d55cbfa505bb945b71cab21a12f)
2019-07-21 21:06:54 +02:00
Keader d400d3d8e9 Core/Scripts: Illidan Stormrage Rewrite (#18963)
Closes #5018

(cherrypicked from 8731975187694d1989af93f9569b591d4ebd767b and 3194d089cbf2dd30bb3fed3a7f6f7e85730ad0cb)
2019-07-21 21:06:54 +02:00
xinef1 36a4e008d0 Corrected immunity checking after recent changes (#19049)
- Shouldn't compare immunity to spells without schoolmask

(cherrypicked from 78a729b6a4f1643eea7120da87a5a10f268dd3c3)
2019-07-21 21:06:54 +02:00
xinef1 fe63cd3dbb Core/Creatures: Various fixes for creatures, regarding combat conditions, despawning, and few others (#18998)
* Made some changes to kiting mechanics, simplified code and made taunt auras prolong combat no matter the distance from the spawn
Unified some creature despawning code, removed some brutal direct calls in scripts
Don't play death anim on forced despawn
Removed some redundant visibility changes on creature despawn
Fixed possible problem with pet initializing template info from difficulty greater than normal
Properly keep UNIT_FLAG_IN_COMBAT on UpdateEntry call
Moved RegenerateMana function to general Regenerate(Power) function
Fixed increased health regeneration from polymorph for pets
Implemented CREATURE_TYPE_FLAG_GHOST_VISIBLE, those creatures will be properly seen when player is dead also
Removed hackfix from Gaeriyan and Franclorn Forgewright, fixed properly
Simplified ForcedRespawnTime code in ForcedDespawn
Do not allow to assist unit while evading or when enemy is evading
Do not allow to attack other units when evading or when the unit is evading
Corrected distance checking code before creature is allowed to evade, should fix some common problems
Properly return summon position for summoned creatures as their respawn position
Properly stop all moving units on gossip hello, no matter their npc flags

(cherrypicked from e1f14215d86fc9f0cd041f0e87bf0a689c086329)
2019-07-21 21:06:54 +02:00
xinef1 ca26c33145 Implemented binary resistances and some more (#18933)
- Fixed possible exploit with tamed pets having template immunities
- Implemented binary resistances
- Corrected resistances calculations
- Pets properly inherit players spell penetration
- Fixed doubled block calculation for damaging melee spells
- Auras removing snare effects will only remove the snaring component
- Shapeshifting will properly remove movement impairing auras only and not crowd control (dragon's breath)
- Immunities are properly checked versus all schools appearing in spell, unit is immune only if immune to all schools
- Spells with melee and magic school mask should compare armor reduction with resistances and select smaller reduction
- Demonic Circle: Teleport no longer removes root effects

(cherrypicked from 93746e8c4a79c8256cd4896533315683f143508c)
2019-07-21 21:06:54 +02:00
xinef1 ad008c43b7 Core/Misc: Fix various crashes, also related to multithreading (#19012)
* When iterating groups we have to either do it not in multithreaded context (map updates) or start with checking maps (they are guaranteed to change in single thread update).
* Properly clear ComboPoint references on player remove
* remove some possible references item may have when it is deleted during save.
* Also clear all hostile references when unit is removed from map.

(cherrypicked from 86da1a19bb36edf3242dafac6e45e87434ddff73)
2019-07-21 21:06:54 +02:00
xinef1 92e95ddf55 Core/Spells: Fixed spell effect 93 (SPELL_EFFECT_FORCE_DESELECT) (#19001)
(cherrypicked from 9e1b286984c63b801561a67dd4eae7910ec1af10)
2019-07-21 21:06:54 +02:00
ariel- 26fe949619 Core/Server: fix duplicated inserts into tutorials table for newly created characters
(cherrypicked from 60dd803bbe01283b15e2b2c5b02d8f857b96745a)
2019-07-21 21:06:54 +02:00
xinef1 192f088248 Core/Achievements: Mountain o' Mounts and similar achievement will be properly awarded when you have required amount of mounts, not earlier (#19002)
(cherrypicked from 8646e72f18172062e98b449478d3f8e1d554d4b9)
2019-07-21 21:06:54 +02:00
Gerhood 7e83cce81f Core/Spells: implement Mad/Crazy Alchemist's potions
(cherrypicked frombab59b28faad262dc5d9873ca7c0856477ec4d66)
2019-07-21 21:06:54 +02:00
ariel- 894c667d32 Core/World: readd lines lost in rebase
(cherrypicked from d3d6c55650b83611d3a2a8c7f7b43675ffb3cdf0)
2019-07-21 21:06:54 +02:00
ariel- 7f490819f5 Misc: fixed some headers.
Updated year, bye bye 2016!

(cherrypicked from 6245b0703e92cb096a9a9c4f2411a43011100043)
2019-07-21 21:06:54 +02:00
xinef1 07d02d744f Remade who list processing (#18636)
* Remade who list processing, requests are now processed in maps. Player entries are now copied every 5 seconds to dedicated storage (avoids usage of hashmapholder mutex)

(cherrypicked from 88f746935ff6a9055c5712997254aff63b406352)
2019-07-21 21:06:54 +02:00
ariel- b742c87222 Core: add some missing Player Name normalization on input data
(cherrypicked from 6f9e8b6c9174249025562faf9ad4c56bbb642547)
2019-07-21 21:06:54 +02:00
xinef1 b485f3e673 Few small optimizations here and there (#18684)
Changes list:
- Added CharacterGuidByNameContainer which contains name -> guid unordered map (updated along CharacterInfo)
- Extended CharacterInfo structure with GuildId
- Extended CharacterInfo structure with ArenaTeamId[3], for all possible teams (2v2, 3v3, 5v5)
- Removed CHAR_SEL_GUID_BY_NAME and CHAR_SEL_CHAR_GUID_BY_NAME synchronous queries, name -> guid can be now retrieved in World::GetCharacterGuidByName
- Removed CHAR_SEL_GUID_RACE_ACC_BY_NAME synchronous query, guid can be retrieved by name and rest of the data can be retrieved by guid
- Removed CHAR_SEL_CHAR_LEVEL synchronous query, level can be retrieved by guid
- Changed CHAR_SEL_CHARACTER_ACTIONS_SPEC to asynchronous query, action bars are now loaded asynchronously
- Removed CHAR_SEL_CHARACTER_NAME_CLASS synchronous query, guid can be retrieved by name and rest of the data can be retrieved by guid
- Removed CHAR_SEL_PLAYER_ARENA_TEAMS and CHAR_SEL_ARENA_TEAM_ID_BY_PLAYER_GUID synchronous queries, arena teams are now stored in CharacterInfo
- Replaced synchronous db calls with CharacterInfo lookups
- Removed ObjectMgr::GetPlayerGUIDByName, as it used db query
- Replaced some unnecessary UpdateObjectVisibility() calls because they were either duplicated (called few lines above in other function) or it is enough to call DestroyForNearbyPlayers because object is being removed or should be invisible and DestroyForNearbyPlayers is faster
- Corrected typo in Player::DestroyForPlayer, only items in slots 0 to EQUIPMENT_SLOT_END are sent to other players
- Renamed Player::GetGuildIdFromDB to Player::GetGuildIdFromCharacterInfo and changed the function to use CharacterInfo structure
- Renamed Player::GetArenaTeamIdFromDB to Player::GetArenaTeamIdFromCharacterInfo and changed the function to use CharacterInfo structure
- Renamed Player::GetLevelFromDB to Player::GetLevelFromCharacterInfo and changed the function to use CharacterInfo structure
- Removed GameEventMgr::_questToEventLinks and associated functions, eventId is now stored in Quest class under _eventIdForQuest variable
- Changed some functions checking quest status to use other functions for quest status check instead of duplicating code
- Removed callback from add friend, because we can get the guid from appropriate storage, no need to make db query
- Removed callback from add ignore, because we can get the guid from appropriate storage, no need to make db query
- Added callback to unwrap wrapped items asynchronously
- Removed synchronous select in tutorials to check if we have any entries in db, if any entry exists in db, m_TutorialsChanged variable will have TUTORIALS_FLAG_LOADED_FROM_DB flag added and it is no longer necessary to query database

(cherrypicked from b955456008191e60b6bda1f22e3486a3792b08db)
2019-07-21 21:06:54 +02:00
ariel- 17703e8924 Core/Spell: remove duplicated SPELL_AURA_MOD_DEBUFF_RESISTANCE handling.
Each spell had two rolls in which it could be resisted, effectively adding to the resist chance.

Closes #7406

(cherrypicked from 23f76b563f3002e1557eb5dd75e0d26bd22357ab)
2019-07-21 21:06:54 +02:00
Keader 9bd8ca0e5f Core/Scripts: Palehoof rewritten & Utgarde Pinnacle updated (#18712)
Closes #15405

(cherrypicked from ba1df45d36285e283a295ea93560c2215ec21e37)
2019-07-21 21:06:54 +02:00
Shauren ff334ae707 Core/Conditions: Reimplemented CONDITION_OBJECT_ENTRY_GUID and CONDITION_TYPE_MASK under new values to allow easier porting conditions between branches. Old data is dynamically converted during startup 2019-07-21 17:12:34 +02:00
Shauren 3058d8c5ab Core/bnetserver: Fixed crash happening when sending packets larger than 4096 bytes 2019-07-21 16:32:49 +02:00
Shauren 3bb26a04f2 Core/PacketIO: Fix sending uninitialized data 2019-07-16 20:39:25 +02:00
Shauren 5ba2d3616e Fixed mmaps_generator crash 2019-07-15 19:46:15 +02:00
Shauren 7dc057fedb Warning fix 2019-07-15 18:25:57 +02:00
Shauren 87bcf6c3c1 Warning fix 2019-07-15 18:03:48 +02:00
r00ty-tc 75efb5d431 Core/Database: Correction for later MariaDB version
- Removed unused define CR_INVALID_CONN_HANDLE which was removed entirely in more modern MariaDB versions

(cherry picked from commit 2a7a1b27d59d26d48e958c64f2a05b58fa7434c1)
2019-07-15 15:08:19 +02:00
Shauren 4d0910d9c2 Fix nopch build 2019-07-14 19:45:58 +02:00
Shauren ce1091cf88 Fix build for openssl 1.0 2019-07-14 19:32:31 +02:00
Shauren 857bb68deb Core/Spells: Fixed creating enchant scrolls 2019-07-14 19:20:45 +02:00