Component / System: Account Migration / Asphodel Graveyard Script / Server Merges
Severity: Major (Permanent loss of massive amounts of player resources/progress upon transfer)
Summary of the Issue
When an account is sent to the Graveyard (Asphodel) server or undergoes a server merge, the total historical wood donations from all islands are compiled to be refunded to the player as "free donation wood." However, the script handling this transfer utilizes a 32-bit unsigned integer (uint32) for the temporary allocation variable or the "free wood" account field.
As a result, if a player's total lifetime raw wood donations exceed 4,294,967,295 units, any amount above this threshold is permanently truncated/deleted during the migration. Meanwhile, the player's global High Score (which calculates 0.01 points per 100 wood) remains correct, creating a discrepancy between the scoreboard and the actual refundable wood balance.
Expected Behavior
The migration script should utilize a 64-bit integer (uint64) or a data type matching the core game database to ensure 100% of a player’s historical island donations are successfully transferred and refunded as free wood, regardless of how high the number is.
Actual Behavior
The total raw wood balance hits a hard mathematical ceiling at exactly 4,294,967,295. Any wood donated beyond this number disappears from the account's refundable "free wood" wallet upon landing on a new server.
Steps to Reproduce (for QA)
- Prepare a Test Account: Create or modify an account on an internal QA or the public test server and distribute massive donations across multiple islands (e.g., using developer tools or testing environments to simulate high-end gameplay). Ensure the cumulative sum of raw wood donated across all islands exceeds the 32-bit limit—for example, 5,000,000,000 raw wood.
- Verify High Score: Confirm that the global High Score correctly reflects the total amount (5 billion wood should display as roughly 50,000,000 points on the scoreboard).
- Trigger Graveyard/Migration: Trigger the inactivity/ghosting script to send the account to the Asphodel (Graveyard) server, or execute a standard server merge script on the account.
- Log into New Server: Select a destination server and revive the account.
-
Check Refundable Balance: Look at the available "Free Wood" donation balance.
- Observed Result: The available free wood balance will be exactly 4,294,967,295, and the remaining 705,032,705 wood is completely missing.
Technical Analysis for Developers
The Root Cause: The main game loop and high-score databases handle these numbers correctly (likely by tracking points or utilizing 64-bit data structures). However, the legacy migration script that aggregates individual island lines (SUM(island_donations)) dumps the total into a uint32 variable or updates a uint32 column in the temporary migration database.
The Fix: Update the variable data type inside the graveyard/migration script from a 32-bit integer to a 64-bit integer (uint64 or BIGINT depending on the database architecture) to prevent data truncation.