Colyseus-jutalmak tartós tárolása
A megerősített meccseredményt a szoba átmeneti memóriájából tartós tárolóba viszi. Külön kezeli a sikeres, függő és bizonytalan írást, hogy az újrapróbálás ne duplázzon vagy veszítsen jutalmat.
colyseus-persistence-rewards
Nézd meg, miben segítMikor hasznos?
Akkor használd, ha készletnek vagy jutalomnak szobafelszabadítás és megszakadt adatbázis-nyugtázás után is meg kell maradnia.
Miben segít neked?
- Stabil azonosítót rendel a szerver által igazolt meccseredményhez.
- Elkülöníti a függő, véglegesített és bizonytalan tárolási eredményt.
- Újrapróbálás és szobafelszabadítás előtt egyezteti a megszakadt írást.
Például ezt kérheted
A kooperatív rajtaütés után minden jogosult résztvevő egyszer kapjon jutalmat az eredmény azonosítójával. Szimulálj sikeres tárolást elvesző visszajelzéssel, majd újrapróbálást és szobalezárást. Egyeztesd az eredeti műveletet, és játékosonként pontosan egy eltárolt jutalmat mutass.
Részletes dokumentáció
Itt a skill eredeti útmutatóját, példáit és ellenőrzési szempontjait olvashatod az eredeti nyelven.
Összecsukás
Colyseus — persistence rewards
Use when persisting Colyseus match results, inventory or rewards outside room memory.
Version and project gate
Inspect Server, client SDK and @colyseus/schema versions, TypeScript/decorator configuration, room registrations, auth hooks, patch/simulation rates, transport, deployment topology and persistence adapters. The 0.17 reconnection lifecycle must not be assumed for older versions. Never turn a task into an engine upgrade without the user’s intent. Read the version-matching official reference when an API decision depends on it.
Work
Assign a stable match/outcome identifier and separate pending, committed and unknown outcomes. Validate results from authoritative state and make durable writes idempotent. Reconcile an interrupted write before retrying; keep room disposal from silently dropping an uncommitted outcome.
Deliver
A persistence/outcome contract with retry and reconciliation behavior. Keep the change in the existing project structure; separate actual observations from the proposed acceptance scenario below.
Failure to prevent
A successful room broadcast does not prove a database commit; never reward twice after an uncertain response.
Acceptance scenario
Interrupt after persistence but before acknowledgement, retry with the same outcome ID and confirm exactly one durable reward. Follow the project’s execution and verification permissions. If execution or a target device is unavailable, provide the reproduction steps and name the remaining uncertainty; do not mark it passed.
Scope and sources
This skill belongs to Relay. Agent selection is restricted by Orqestria’s assigned-agent policy, including forced skill selection; instruction text alone is not an access control. These are original task workflows researched from official documentation, not a copied or endorsed vendor skill.
Csomagban lévő fájlok 1
SKILL.md
