Commit Graph
1099 Commits
Author SHA1 Message Date
treeston 0f0a51b87a Game/Maps: Instance handling follow-up:
- Fix a bug where a player could maintain a conflicting non-perm solo bind if they were in the instance when invited to group. Closes #16150.
- If a group is created while the leader is in an instance that nobody is bound to, the group will take over the instance and bind to it. This stops the homebind timer when reforming group after disconnects and the like.
2016-01-04 15:48:53 +01:00
Rushor 923a368ac7 Update copyright note for 2016 2016-01-01 12:02:33 +01:00
treeston 43fa7d48a5 Game/Maps: Clean up instance handling.
- Rename Map::CanEnter to Map::CannotEnter. Return value changed from boolean (true means player can enter) to enum Map::EnterState (CAN_ENTER=0 means player can enter, any other value is a reason for deny).
- Move hack-y player error messages from within Map::CanEnter to the function calling CanEnter as appropriate (primarily WorldSession::HandleAreaTriggerOpcode).
- Modify WorldSession::HandleAreaTriggerOpcode to properly revive the player upon touching the portal leading to the instance they died in even if they are currently unable to zone in. Fixes and closes #15758.
- Modify Player::LoadFromDB to properly spawn players in the instance they logged off in if possible. Fixes and closes #15561.
- Modify permanent save behavior to be blizzlike: Players can always enter an instance they are saved to (assuming there are no map constraints against it), but get a homebind timer if the instance is already in use.
2015-12-31 01:02:07 +01:00
rockz1152 60311e0aae Core/Player: Fixed Weapon Skillup on low level mobs
Closes #15998

Removed block for skill up on grey level mobs.
2015-12-15 14:47:59 -05:00
pete318 0ac442f19f Improved Auction house deposit handling.
Including the weird quirks.

Changes:
* Deposit caculated according to same rule as client. (detailed below). Should always match client deposit now
* Deposit for multiple auctions now only collected once. Deferred calculation of deposit until all auctions listed.

Deposit calculation is as follows:

Base deposit calculation = MSV x 15/75% (depending on AH). However this is not rounded. Case to int is used (so always round down)
The remainder is held in a float.
The base is then multiplied by number of items, and the time multiplier (x2 for 24 hour, x4 for 48 hour)
The nearest (no of items or lower) no of items when multiplied by the remainder that creates a whole number is then multiplied by the time multiplier (x1/x2/x4) and then added to deposit.

Example:

Item sell price 1s25. Deposit 18.75c (15% of 1s25). So base deposit = 18, remainder 0.75. Time 24h (x2) Item count 1 = 36c. Remainder = 0.75 (n) Min = 1s. Deposit 1s
Item sell price 1s25. Deposit 18.75c (15% of 1s25). So base deposit = 18, remainder 0.75. Time 24h (x2) Item count 2 = 72c. Remainder = 1.50 (n)  Min = 1s. Deposit 1s
Item sell price 1s25. Deposit 18.75c (15% of 1s25). So base deposit = 18, remainder 0.75. Time 24h (x2) Item count 3 = 108c. Remainder = 2.25 (n) Min = 1s. Deposit 1s08c
Item sell price 1s25. Deposit 18.75c (15% of 1s25). So base deposit = 18, remainder 0.75. Time 24h (x2) Item count 4 = 144c. Remainder = 3.00 (n) Min = 1s. Deposit 1s50c (144c + (3c * 2))

Horrible kludge, to re-create a very weird deposit method.

Closes #15674 (PR)
Closes #15643 (Issue)
2015-12-14 19:54:58 +01:00
jackpoz 80ed03a84d Merge pull request #15402 from chaodhib/taunt_player 2015-12-09 22:08:43 +01:00
Shauren cc685ac334 Core/Items: Fixed a possible crash with soulbound tradable items
Closes #15700

(cherry picked from commit 094f505e404b5a4e4846657031f89ac44626a1f8)
2015-12-08 18:02:43 +01:00
jackpoz 2cb54d5606 Core/Player: Fix crash related to vehicles
Fix assertion triggered when entering a vehicle while channelling a shared vision spell.
Fix #15953
2015-12-07 23:34:00 +01:00
jackpoz a67f378f10 Merge pull request #15904 from 'ForesterDev/instance_login_cleanup' 2015-11-28 21:45:41 +01:00
Vincent-Michael e266278f7d Core/Players: Fixed warning 2015-11-27 22:10:21 +01:00
Shauren ba1e00399d Core/Players: Use constant gender from PLAYER_BYTES_3 where appropriate.
Closes #15895
2015-11-27 18:30:01 +01:00
ForesterDev 9573ec52f0 Core/Player: cleanup function CheckInstanceLoginValid 2015-11-27 12:53:48 +04:00
jackpoz 5f917e2286 Core/Player: Always allow accounts with RBAC_PERM_COMMAND_GM to enter instances on login
Always allow accounts with RBAC_PERM_COMMAND_GM to enter instances on login even if player had .gm off .
Send an ingame message to notify the user about the avoided kick.
2015-11-26 21:54:22 +01:00
jackpoz fbaed38b5e Core/Quest: Fix issues reported by static analysis
Coverity defect IDs: 1339309, 1339310
2015-11-15 16:17:12 +01:00
jackpoz 63f2675076 Core/Player: Fix issue reported by static analysis
Coverity defect IDs: 1010154
2015-11-15 16:01:14 +01:00
Carbenium b292321798 Core/Player: Move KillRewarder to its own file
(cherry picked from commit 4e76974ce5ba3f6ebd73d6dd96860b60d50a19f4)

Conflicts:
	src/server/game/Entities/Player/Player.cpp
	src/server/game/Entities/Player/Player.h
2015-11-14 15:06:47 +01:00
Carbenium 1438c841ed Core/Player: Move TradeData to its own file
(cherry picked from commit 2d7d6f505c6e4e08b5fbbd0bc88b46753191c7aa)

Conflicts:
	src/server/game/Entities/Item/Item.cpp
	src/server/game/Entities/Player/Player.cpp
	src/server/game/Entities/Player/Player.h
	src/server/game/Handlers/TradeHandler.cpp
	src/server/game/Spells/Spell.cpp
2015-11-14 13:40:32 +01:00
Carbenium 2a36b00907 Core/Player: Improve a log message
(cherry picked from commit 7eb314fcd16c2265daf0948c6744a9f206da3150)
2015-11-10 00:50:15 +01:00
Carbenium 12ae32a9b6 Merge pull request #15720 from Tonghost/3.3.5
Core/Items: Fix a trading spoof exploit.
2015-11-03 17:48:01 +01:00
ShinDarth 7ab1d1b7d0 Core/Ticket improved ticket system
- Safely close ticket before character deletion
- Allow to keep trace of delete characters tickets (configurable)
- Closes #15655

Closes #15699
2015-11-03 16:07:30 +01:00
Shauren 965d29484b Core/Items: Corrected all spellid checks from item_template to also check -1
Closes #15797
2015-11-01 16:29:29 +01:00
Shauren cba122ad94 Core/Conditions: Optimizations part 3 removed copying condition containers all over the place
(cherry picked from commit b09e63e9debfab49e635a591339294dd96b09d95)
2015-10-31 20:26:40 +01:00
Shauren dc74454356 Core/Conditions: Type renaming
(cherry picked from commit 5e0cee85ddd67188365ead3f18206df088e1f0c7)
2015-10-31 20:26:40 +01:00
joschiwald df88c7f278 Core/Misc: removed some useless map checks
(cherry picked from commit cf1e80e3d09067ca4d0078a8113a09227a9f91ae)
2015-10-31 19:11:41 +01:00
Shauren 635dc9c02a Core/Players: Fixed automatic learning skills gained from learning spells when leveling
Closes #15391

(cherry picked from commit 3fceabfa113983549b5784dfd3f42259a53c258b)
2015-10-31 18:57:59 +01:00
Shauren f56bb2e0a6 Core/Spells: Extended spell required shapeshift masks to 64 bits and defined a new spell attribute
(cherry picked from commit 191d2c7262d3680776579055a063a433add54277)
2015-10-31 18:14:36 +01:00
MitchesD a968595977 Core/PacketIO: fixed instance binding of gamemasters
(cherry picked from commit 231fb1d322bc1c91f9227d43d3ef672605232154)
2015-10-31 17:39:17 +01:00
Shauren 1de03cf107 Core/Players: Implemented serverside validation of reserved/profane names
Closes #15357

New library dependency: Boost.Regex

(cherry picked from commit b564c10b13effed63c7b7dae25117e2e0a2c64e4)
2015-10-31 17:27:45 +01:00
Shauren 6c53f820ae Core/Players: Fixed saving players with incorrect gender 2015-10-31 12:30:22 +01:00
Shauren 4a36850167 Core/World: Store account id in CharacterInfo to reduce the amount of database queries
(cherry picked from commit aaaa1c34410c160c7b0382f5ecdb39fa01ba007c)
2015-10-29 21:08:00 +01:00
Shauren c7bad70e55 Core/Players: Check if player can enter the instance during login before trying to add him to map
* Fixes name displaying as "Unknown"

(cherry picked from commit 45994a177c128dc83ea01b0697377f7b74b5c4ba)
2015-10-29 18:59:06 +01:00
Shauren 7dcddd90be Core/Spells: Improved spell category cooldown handling
* Category cooldown is stored with the spell that started the cooldown (and only resetting cooldown on that spell will clear cooldowns on entire category - this fully mirrors client behavior)
* This significantly reduces the amount of data saved to database for cooldowns
* Spell casts from items that have a different category specified than on spell will now check for cooldown during the cast

(cherry picked from commit 1efb3f08e278530f59d681f676b031a7fc6db3ac)

Closes #15766
Closes #15137
Closes #14837
2015-10-29 17:56:18 +01:00
Shauren 20b4e6f03a Core/Corpses: Fixed leaking corpses
Closes  #15765

(cherry picked from commit bd16520ecc91d827abae7f0447cc292fe9e843e9)
2015-10-28 21:56:40 +01:00
MitchesD 8e7012f076 Merge pull request #15736 from ShinDarth/deserters
BG Deserters tracking system
2015-10-28 20:40:25 +01:00
ShinDarth d380c12c56 Core/Battleground: implement deserters tracker feature 2015-10-28 20:39:04 +01:00
w1sht0l1v3 56b27711a4 Core/Player: Fix copy/paste mistake in 1ef1d42d14 2015-10-26 20:15:18 +02:00
w1sht0l1v3 1ef1d42d14 Core/Player: Fix not being able to do seasonal quests(if already done in the past) 2015-10-25 18:22:57 +02:00
ShinDarth c6c3e72b55 Core/Scripts: convert the Duel Cooldown Reset feature to scripts 2015-10-18 18:41:58 +02:00
MitchesD 4204805d47 Merge pull request #15697 from ShinDarth/cd
Core/Player rewritten duel CD reset system
2015-10-17 18:38:31 +02:00
ShinDarth 1e52dd4797 Core/Player rewritten duel CD reset system 2015-10-17 18:37:34 +02:00
Incorrect a120053de7 Core/Items: Fix a trading spoof exploit. 2015-10-17 14:37:02 +03:00
ShinDarth 2185165e84 Core/Misc split Rate.XP.Kill and Rate.XP.BattlegroundKill settings 2015-10-16 00:04:40 +02:00
pete318 b1032ed620 Change many uint32 to ObjectGuid::LowType in line with 6.x changes. 2015-10-12 23:10:41 +02:00
ShinDarth 24b41a5211 Core/Player: implement ResetCoolDownAfterDuel configurable feature 2015-10-05 15:57:53 +02:00
Shauren 402a3c45ff Core/Maps: Moved corpse management to map level
(cherry picked from commit cd27fd38b93884797c094a82dc7beb0498e2f124)

# Conflicts:
#	src/server/database/Database/Implementation/CharacterDatabase.cpp
#	src/server/database/Database/Implementation/CharacterDatabase.h
#	src/server/game/Entities/Corpse/Corpse.cpp
#	src/server/game/Entities/Creature/GossipDef.cpp
#	src/server/game/Entities/Player/Player.cpp
#	src/server/game/Entities/Player/Player.h
#	src/server/game/Globals/ObjectAccessor.cpp
#	src/server/game/Globals/ObjectAccessor.h
#	src/server/game/Globals/ObjectMgr.cpp
#	src/server/game/Globals/ObjectMgr.h
#	src/server/game/Grids/ObjectGridLoader.cpp
#	src/server/game/Handlers/AuctionHouseHandler.cpp
#	src/server/game/Handlers/CharacterHandler.cpp
#	src/server/game/Handlers/ChatHandler.cpp
#	src/server/game/Handlers/QueryHandler.cpp
#	src/server/game/Maps/Map.cpp
#	src/server/game/Server/Packets/CharacterPackets.cpp
#	src/server/game/World/World.cpp
#	src/server/scripts/Commands/cs_reload.cpp
2015-09-29 18:45:01 +02:00
pete318 dcb7082277 Map local guids 6.x -> 3.3.35:
Implemented:
  https://github.com/TrinityCore/TrinityCore/commit/ca83e14f8b141fab0a13e08f48fca6c1ace0c4c7
  https://github.com/TrinityCore/TrinityCore/commit/ee1c1b97be4492ecabe8b15ea6323fc37e4eaa8c
  https://github.com/TrinityCore/TrinityCore/commit/18e4ab6911468b829b0fc768e532a770263c3717
  https://github.com/TrinityCore/TrinityCore/commit/bf37446b3c2ed73b4d3aa9e227d3eff5c53b378b
  https://github.com/TrinityCore/TrinityCore/commit/cb854a2b7bb7bd96cf9c4d1daf3789f797bf4db8

* This adds separate (per map) guid sequences depending on object type
* Ported map object container from cmangos/mangos-wotlk@a2d396e
* Added type container visitor for TypeUnorderedMapContainer
* Implemented helper function to erase unique pairs from multimap containers
* Moved object storage of all objects except players and transports to map level
* Added containers linking database spawn id with creature/gameobject in world
* Renamed DBTableGuid to spawnId
* Added a separate spawn id sequence generator for creatures and gameobjects - this will be used in db tables
* Moved building SMSG_UPDATE_OBJECT - updatefields changes broadcast to map update
* Added new function to return but not increment guid
* Adjusted .debug loadcells to show low guid in map before/after load
* Added debug messages for creature spawn/destroy, for map guid debugging
* Store all Gameobjects and Creatures added to OutdoorPvP, so the callback script can be removed when OutdoorPvP instance is destroyed.
2015-09-22 21:33:57 +02:00
StormBytePP 7b245a0b6b Core: Added ABORT() macro to prevent the usage of ASSERT(false) as a quick hack to crash the core misusing assert 2015-09-21 15:11:06 +02:00
MitchesD 0eea8d686b Merge pull request #15497 from ShinDarth/335-misc
[3.3.5] Low priority changes after latest backports
2015-09-15 10:45:40 +02:00
ShinDarth b1d773f3d5 Core/Misc: rename some variables after latest backports 2015-09-14 23:35:58 +02:00
Shauren 2056961aae Core/Players: Changed multi-segment taxi paths to fly nearby flight masters along the way, not directly through them
* Taxi cost on multi-segment paths is now charged per segment when it is started
2015-09-12 20:15:34 +02:00