[World] Restore weekly currency cap reset wiring#297
Merged
billy1arm merged 2 commits intoJul 4, 2026
Conversation
InitCurrencyResetTime() and ResetCurrencyWeekCounts() have been orphaned since 165cfba reverted World.cpp to the previous core: the init call and the World::Update trigger were dropped, so character_currencies.weekCount was never reset and the shipped Currency.Reset* config options were dead. Re-wire both call sites as originally added in 8e5d609. Requires char DB update Rel22_03_004 which adds the saved_variables.NextCurrenciesResetTime column these functions persist to (content-level bump, older DBs still boot with a warning).
billy1arm
pushed a commit
to mangosthree/database
that referenced
this pull request
Jul 4, 2026
#132) Paired with mangosthree/server#297 (weekly currency cap reset). Chains db_version 22/03/003 -> 22/03/004, so it sequences after Rel22_03_003 (#296); if landing alone, renumber to 003.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Cata's weekly currency-cap reset is dead.
saved_variableshas noNextCurrenciesResetTimecolumn, andWorld::InitCurrencyResetTime()/World::ResetCurrencyWeekCounts()have no callers — commit165cfba9c(2016) removed the wiring (it reverted8e5d609e1, which had replaced WotLK arena-point distribution with the currency reset). Result:character_currencies.weekCountnever resets, so the weekly Conquest cap silently becomes a permanent lifetime cap — a player who caps in week 1 can never earn Conquest again. Arena-team weekly stats never reset either.Restores the wiring:
InitCurrencyResetTime()inSetInitialWorldSettingsand theif (m_gameTime > m_NextCurrencyReset) { ResetCurrencyWeekCounts(); }trigger inWorld::Update(next to the daily/weekly/monthly resets). The reset function, config keys (Currency.Reset*), and per-playerCurrencyMgr::ResetWeekCountsall already exist.Schema coordination: needs a paired
mangosthree/databasemigrationRel22_03_004_Add_NextCurrenciesResetTime(adds thebigintcolumn); this PR bumpsCHAR_DB_CONTENT_NRto4. It sequences after #296 (the cleaner,Rel22_03_003/ content3) — the two are a schema pair. If you'd rather land this one first/alone, the content number and migration should be renumbered to3/Rel22_03_003. Migration SQL is ready.This change is