feat(game): NAVIGATION AI unlocks two-hop jumps in one action (#35)
CI / build + unit + e2e (pull_request) Failing after 3m11s

This commit is contained in:
2026-09-29 14:53:11 +00:00
parent d083b5b708
commit d14ffdcf2f
10 changed files with 167 additions and 26 deletions
+4 -4
View File
@@ -8,7 +8,7 @@ export const openApiSpec = {
info: {
title: 'SpaceWanderer API',
description:
'JSON API for SpaceWanderer — a single-player turn-based space adventure (one save, no accounts). World endpoints: read the generated world state and jump between adjacent solar systems.',
'JSON API for SpaceWanderer — a single-player turn-based space adventure (one save, no accounts). World endpoints: read the generated world state and jump between solar systems within range (adjacent by default; two hops once NAVIGATION AI is researched).',
// Sourced from package.json so it stays in sync with every version bump.
version: pkg.version,
},
@@ -52,9 +52,9 @@ export const openApiSpec = {
},
'/api/jump': {
post: {
summary: 'Jump to an adjacent solar system',
summary: 'Jump to a solar system within range',
description:
'Validates that the target is a jump route away from the current system, sets it as current (discovering it if new and generating its neighbours), increments the turn counter and writes a jump event. Returns the fresh world state.',
'Validates that the target is within jump range of the current system — one hop away, or two hops once NAVIGATION AI is researched (#35) — sets it as current (discovering it if new and generating its neighbours), advances the turn counter by the hop count and writes a jump event. Returns the fresh world state.',
operationId: 'jumpToSystem',
requestBody: {
required: true,
@@ -90,7 +90,7 @@ export const openApiSpec = {
},
},
409: {
description: 'Target is not adjacent to the current system (or is the current system itself)',
description: 'Target is outside jump range of the current system — more than one hop away, or more than two hops without NAVIGATION AI researched (or is the current system itself)',
content: {
'application/json': {
schema: { $ref: '#/components/schemas/Error' },