finish market system

This commit is contained in:
ErikasKontenis
2022-04-10 22:15:53 +03:00
parent fadbf8b64d
commit 6e6b2dc4a6
25 changed files with 2670 additions and 1166 deletions

View File

@@ -138,7 +138,8 @@ function onStartup()
db.asyncQuery("DELETE FROM `guild_wars` WHERE `status` = 0")
db.asyncQuery("DELETE FROM `players` WHERE `deletion` != 0 AND `deletion` < " .. os.time())
db.asyncQuery("DELETE FROM `ip_bans` WHERE `expires_at` != 0 AND `expires_at` <= " .. os.time())
db.asyncQuery("DELETE FROM `market_history` WHERE `inserted` <= " .. (os.time() - configManager.getNumber(configKeys.MARKET_OFFER_DURATION)))
-- Move expired bans to ban history
local resultId = db.storeQuery("SELECT * FROM `account_bans` WHERE `expires_at` != 0 AND `expires_at` <= " .. os.time())
if resultId ~= false then