30 Commits

Author SHA1 Message Date
Shauren
7657a289d7 Core/Misc: Kill copy/move constructors for singleton classes 2025-06-10 13:12:33 +02:00
Shauren
d791afae1d Core/Logging: Switch from fmt::sprintf to fmt::format (c++20 standard compatible api) 2023-01-08 21:16:53 +01:00
Shauren
ad4f4bfab7 Core/Misc: Minor game include cleanup 2022-02-13 00:49:10 +01:00
Jinnaix
2e10a2de3b Core/Misc: Update Worldserver.conf for AhBot Pricing -make things more clear (#25341)
* AhBot Pricing: Make things more clear

* Change default value to BuyPrice and add some more information to how two sided AH works

* Sync c++ configs with .conf ones

Co-authored-by: Giacomo Pozzoni <giacomopoz@gmail.com>
(cherry picked from commit 812c2af4da)
2022-02-04 13:01:25 +01:00
jackpoz
4051ccd1bd Core/AHBot: Warn about different AHBot behavior when AllowTwoSide.Interaction.Auction is enabled
Closes #18243

(cherry picked from commit 92f9abab06)
2022-02-04 12:19:15 +01:00
Peter Keresztes Schmidt
37777ac6e8 Scripts/Commands: Convert argument parsing of ahbot commands (PR #25264)
(cherry picked from commit 426513ec8e)
2022-02-02 21:17:51 +01:00
Treeston
d11c3807b3 Core/Time: Rename GetGameTime{System, Steady}Point methods
The names are a bit unhandy. Rename them (shorter but still meaningful).

GetGameTimeSystemPoint() -> GetSystemTime()
GetGameTimeSteadyPoint() -> Now()

Also add 2 new typedefs:

typedef std::chrono::steady_clock::time_point TimePoint;
typedef std::chrono::system_clock::time_point SystemTimePoint;

Closes #25042

(cherry picked from commit 896b68d5c2)
2022-01-23 21:36:03 +01:00
ariel-
8be8b7cff4 Core/AHBot: fix a typo
(cherry picked from commit e594c2d096)
2020-04-27 12:25:52 +02:00
ariel-
d6e293c718 Core/AHBot: Refactor of AuctionHouseBotSeller:
- Use AuctionHouseBot.Class.* for what they really are, priorities, factor them when calculating item amount per class, changed enums to CONFIG_AHBOT_CLASS_*_PRIORITY to reflect this change
- Don't factor in the priority calc empty item lists:
  * Let's say you had AuctionHouseBot.Class.Glyph set to 10, sum of AuctionHouseBot.Class.* is 20, and AuctionHouseBot.Items.Amount.White is 5000
  * If there were no glyphs on the item list, you automatically lost 50% of the total item amount, meaning only 2500 of original 5000 were alloted to fill
- Fixed AuctionHouseBot.AH.Price.Ratio to be an actual percentage factor

- Separated containers in SellerConfiguration, each one better reflects what kind of data is stored there, now we won't use magic index 0 from _ItemInfo :P
- General cleanup, removal of bad voodoo and magical numbers
- Use unordered_sets for loading item lists, as they were only used to check for item presence

(cherry picked from commit 7f8bfe68d0)
2020-04-27 12:25:52 +02:00
Shauren
aced88b09b Core/AuctionHouse: After taking a break at the start of patch 8.3 auction house is now back in business. 2020-04-20 20:36:24 +02:00
Aokromes
b0bf1275ee New Year 2020-01-02 06:44:10 +01:00
xinef1
60663d1374 Ensure that all actions are compared to fixed point in time (ie. world update start) (#18910)
- Actions will not be dependent on processing moment
- Increased GameObjects cooldown resolution to milliseconds, fixes arming time of traps to be exactly one second and not something from range (1000, 1999)
- Created GameTime namespace and UpdateTime class and moved there some code out of world

(cherrypicked from 7567cafec8)
2019-08-17 20:04:14 +02:00
Shauren
e8e89f58fb Core/DBLayer: Prevent using prepared statements on wrong database 2019-07-27 01:00:37 +02:00
vincent-michael
5620eb9463 Update copyright note for 2019
auto happy = new year(2019);
2019-01-01 10:14:33 +01:00
Ayrton Stout
8cff0d4a90 Fixed array size bug with the auction house bid price. Lowered the default max bid price (#18697)
Closes #18698

(cherry picked from commit 4df1b28054)
2018-03-18 00:19:48 +01:00
Ayrton Stout
bec131eac3 Core/AH: AuctionHouseBot BidPrice determined by config options
(cherry picked from commit bed369e7c8)
2018-03-18 00:19:48 +01:00
vincent-michael
7d00ae4045 Update copyright note for 2018
auto happy = new year(2018);
2018-01-01 00:40:17 +01:00
ariel-
6505747f50 Core/AuctionHouseBot: ahbot characters subsystem shake-up
Bonus: fix moar static analysis issues
(cherry picked from commit f4a10571f7)
2017-10-03 17:56:42 +02:00
iridinite
fd53cbc5f2 [3.3.5] AHBot Characters (#17885)
(cherry picked from commit 6dc0a9f04a)
2017-10-03 16:02:32 +02:00
vincent-michael
86b98686a9 Update copyright note for 2017
Happy new year
2017-01-01 16:23:13 +01:00
Duarte Duarte
af0da1dde1 Merge pull request #16101 from NathanHandley/3.3.5
Updated AuctionHouseSeller to have item class stack control
(cherry picked from commit bddf9ec6fe)
2016-03-21 23:33:00 +01:00
Naios
329225b40d Core/Game: Move singleton instances into compilation units
* Fixes issues when building shared libraries
  (prevents gcc and clang from providing several instance)
2016-03-11 18:35:49 +01:00
Vincent-Michael
478cc756eb Update copyright note for 2016
Happy new year (Again new year with idiots ...)
2016-01-01 00:34:25 +01:00
jackpoz
cf67b7d375 Core/AHBot: Adjust AHBot bid and buyout chances
Apply an exponential formula to define the chance to bid/buyout an auction depending on auction price and item price ratio. The formula can be adjusted changing the new AuctionHouseBot.Buyer.ChanceFactor config parameter
Chance = 100 ^ (1 + (1 - (auction_price / item_price) / k)
k is the config parameter AuctionHouseBot.Buyer.ChanceFactor, the higher the number the higher chance to buy overpriced auctions.

(cherry picked from commit 177b6319d1)

Conflicts:
	src/server/game/AuctionHouseBot/AuctionHouseBotBuyer.cpp
2015-09-24 19:48:31 +02:00
jackpoz
a7c8caf2ef Core/AHBot: Fix AHBot bidding and correct logged AH type
Correct AuctionHouseType definition to log the right AH type.
Handle auctions without bidder but with a bid as bought by the AH Bot
Closes #14124

(cherry picked from commit 2eee1b349f)

Conflicts:
	src/server/game/AuctionHouse/AuctionHouseMgr.cpp
2015-02-22 06:21:02 +00:00
jackpoz
582313e545 Merge PR #14059 from 'Rochet2/ahbot_buyer' into 3.3.5
(cherry picked from commit b69fd4ac68)

Conflicts:
	src/server/game/AuctionHouseBot/AuctionHouseBotBuyer.cpp
2015-02-11 19:27:44 +00:00
Vincent-Michael
ab90f74486 Update copyright note for 2015
Happy new year
2015-01-01 00:28:09 +01:00
Shauren
6dbb516b65 Core/Items: Refactored ItemTemplate 2014-12-21 13:35:43 +01:00
jackpoz
04ddbc374a Core/Misc: Remove unneeded NULL checks 2014-08-28 23:07:04 +02:00
Blipi
a7d1394c2e Core/AHBot: Implemented AHBot based on MaNGOS code
Warning: CMake must be rerun

Apply if you have crashes

Rewrite Seller prices, add random properties and implement some suggestions on price calculations

Core/AHBot: Update to latest suggestions

Fix SQLs after merge, split the AH bot to spearate headers and cpps, fix the config default values

Remove case 8 from GetBuyModifier. It was not correct

Fix Gray Grey GRAY typos

Change message config name

Fix non pch build

Fix switch ident, also earlier removed whitespace. Add missing include for non pch build

Fix possible crash: if (forplayer || GetOwnerGUID()) changed to if (forplayer)

Apply Nayd.diff - Code style fixes

Fix leftovers from nayd

Correct SQL transaction and change one SQL query to C++ instead

Make loot items distinct
2014-08-25 22:15:59 +03:00