feat(settings): edit reward_config, the table the game pays from
The settings page edited system_config, which nothing in the game reads.
It now edits reward_config: coins and XP per game and place (read by
complete_match() and domino-match), the seven-day daily reward ladder and
the chess Elo K-factor steps (El3ab includes/game-config.php). All 47 keys
have an Arabic label and group and say whether the game reads them today;
chess draw/loss and backgammon loss rows are marked unpaid because those
games report only the winner to complete_match(). Values are validated
whole numbers stored as plain text (complete_match casts value::int); only
changed rows are written and the change is audited.
system_config is shown read-only for reference, with where each value
really comes from. Its update no longer json_encode()s the value before
PostgREST encodes it again (the cause of elo_k_factor_master = "\"20\"",
repaired in the migration).
Co-Authored-By:
Claude Opus 5.5 <noreply@anthropic.com>
Showing
This diff is collapsed.
Please register or sign in to comment