feat(rust): Economics — pay coins, balances, staff adjust, the richest (PLAN_REDESIGNS §11.2)
The site half of §11.2.2, on protocol 14:
- `rust.coins.pay` ("Pay coins"): irreversible, reversible none (D335). The
recipient modes of rust.kit.entitle including `linked`, one payment per
website user (D103's rule), an optional message with {amount}, a new
`rust.coins` budget. Refused with "Economics is not installed on this
server" in the dry run too (D199). Core's key goes to the plugin, so a
retried step answers `repeat` and pays nobody twice.
- `rust_player_wipe_stats.balance`: the tally's balance, written as a value.
A nameless balance frame (an offline player) moves nobody's last-seen.
`economics.wiped` clears the wipe's balances, except at a new save.
- The richest: a Coins leaderboard column on one wipe of a server that
reports Economics, `sort=balance`, and a `richest` title category
(Magnate); both rank only above the starting balance (D336).
- GET /player/rust/economics (live, falling back to the last known), and
GET/POST /admin/users/:id/rust/economics for staff — scoped to the user's
own links, keyed per submission, an activity row with before and after.
- Client: the account page's Coins, the admin user page's Coins panel with
its form, the leaderboard column, and Economics in the server's mod line
(saying when its config could not be read).
Server 535/535 (14 new in test/economics.test.js), client 74/74,
routes.manifest regenerated against the pinned core (87 routes), swagger
fragment regenerated.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01E14m6SuuY6i1vASFeGDBeY
This commit is contained in:
10
README.md
10
README.md
@@ -38,11 +38,12 @@ rows here; the website core never learns there is more than one.
|
||||
| Public | `GET /api/v1/public/rust/servers` — every server and what it last reported |
|
||||
| Public | `GET …/servers/:id` — one server, or a `404`; the only route under `:id` that can say a server does not exist |
|
||||
| Public | `GET …/servers/:id/events` — the feed, served from a default-deny allowlist (`server/catalogue.js`) |
|
||||
| Public | `GET …/servers/:id/leaderboard` — per wipe, or all-time as those rows summed; each row carries the player's chat titles |
|
||||
| Public | `GET …/servers/:id/leaderboard` — per wipe, or all-time as those rows summed; each row carries the player's chat titles, and on one wipe of a server with Economics their coin balance |
|
||||
| Public | `GET …/servers/:id/wipes` and `…/online` |
|
||||
| Public | `GET …/servers/:id/clans` — the server's clans, best score first (public: names nobody) |
|
||||
| Public | `GET /api/v1/public/rust/clans/:externalId` — one clan, and its roster inside the roster audience |
|
||||
| Player | `GET /api/v1/player/rust/servers` — the server list, on the authenticated tier |
|
||||
| Player | `GET /api/v1/player/rust/economics` — your coin balances on every server, per linked account |
|
||||
| Admin | `GET/PUT/DELETE /api/v1/admin/rust/servers` and `POST …/:id/test` — the `PUT` carries the wipe schedule |
|
||||
| Admin | `GET/PUT /api/v1/admin/rust/visibility` — who may see who is online, fleet-wide and per server |
|
||||
| Admin | `PUT …/servers/:id/titles`, `GET …/servers/:id/integrations`, `GET/PUT /api/v1/admin/rust/voice` — chat titles, the optional mods a server has, and the announcement voice |
|
||||
@@ -82,7 +83,7 @@ forced wipe (first Thursday, 19:00 UK time) — plus an optional one-off date th
|
||||
computed wipe. It is computed on every read and never stored, so it cannot go stale after a wipe.
|
||||
The server list, the server page, the Android app and `/wipe` all show it.
|
||||
|
||||
**Two uMod plugins are optional, and the module works without either** (`docs/modules/rust/PLAN.md`
|
||||
**Three uMod plugins are optional, and the module works without any of them** (`docs/modules/rust/PLAN.md`
|
||||
§33). The bridge plugin's hard requirements are **Kits** and **ZoneManager**.
|
||||
|
||||
- **BetterChat** (LaserHydra, 5.2.15). With it: **chat titles** an operator sets per server — "top 3
|
||||
@@ -94,6 +95,11 @@ The server list, the server page, the Android app and `/wipe` all show it.
|
||||
- **PopupNotifications** (k1lly0u, 0.2.1). With it: `rust.announce` and a server's news posts can be
|
||||
a popup instead of a chat line. Without it a popup is refused with a sentence saying so, and chat
|
||||
works as before.
|
||||
- **Economics** (Wulf, 3.9.2). With it: the **Pay coins** event step (`rust.coins.pay`, kept once
|
||||
paid), each player's balance on their account page and in the app, staff deposit / withdraw / set
|
||||
from a user's admin page, a **Coins** leaderboard column and the **Magnate** title — both ranking
|
||||
only balances above the server's starting balance. Without it each of those says "Economics is not
|
||||
installed on this server" (`docs/modules/rust/PLAN_REDESIGNS.md` §11.2).
|
||||
|
||||
News and event lines said in chat can wear one styled group's title and colours — the
|
||||
**announcement voice**, chosen in Admin → Rust servers. The line is said by the bridge plugin with no
|
||||
|
||||
Reference in New Issue
Block a user