feat: complete playtest parity improvements
This commit is contained in:
+9
-7
@@ -1,6 +1,6 @@
|
||||
# Playing Dungeon Crawler World
|
||||
|
||||
Dungeon Crawler World is a desktop Godot prototype. It supports Linux x86_64 and Windows x86_64 exports. The reference display is 1280×720, but the window is resizable.
|
||||
Dungeon Crawler World is a desktop Godot prototype. It supports Linux x86_64 and Windows x86_64 exports. The reference display is 1920×1080, but the window is resizable.
|
||||
|
||||
## Install or run
|
||||
|
||||
@@ -38,7 +38,7 @@ The Linux script exports `build/linux/DungeonCrawlerWorld.x86_64` and smoke-laun
|
||||
|
||||
Choose **NEW RUN** at the main menu, choose a character, then enter the dungeon. **CONTINUE** loads the most recently updated occupied slot; **LOAD SLOT** opens a specific slot.
|
||||
|
||||
The main menu exposes **CONTINUE** and **LOAD SLOT**. During an active run, the game API provides the five-slot Save/Load panel; builds that do not expose that command in the current UI should be treated as prototype builds and should not be represented as offering a player-facing manual-save shortcut. Saves are versioned JSON files below Godot's `user://saves` directory, named `slot1.json` through `slot5.json`. The exact native location is platform-dependent. To find it in a running build, open the Godot editor for the same project and use its user-data path, or inspect `ProjectSettings.globalize_path("user://")` from a debug tool. Copy the whole `saves` directory to back up a run; do not edit a save while the game is writing it.
|
||||
La sauvegarde est **manuelle** : pendant une partie, appuyez sur **V** (fonctionne aussi dans le jeu lancé depuis l’éditeur Godot) ou sur **Ctrl+S** dans une version autonome, puis choisissez l’un des cinq emplacements. Un message confirme l’emplacement écrit. Il n’est pas nécessaire d’avoir un menu Échap et le ciblage ou l’ouverture du panneau de sauvegarde ne consomme aucun tour. Le menu principal expose **CONTINUE** et **LOAD SLOT** pour reprendre la sauvegarde la plus récente ou choisir un emplacement. Les sauvegardes sont des fichiers JSON versionnés dans `user://saves`, nommés `slot1.json` à `slot5.json`. Leur chemin natif dépend de la plateforme. Copiez le dossier `saves` complet pour sauvegarder vos parties hors jeu; ne modifiez pas un fichier pendant son écriture.
|
||||
|
||||
The game recognizes its current schema and can migrate the supported parts of the supplied ASCII save shape. Unsupported legacy keys are reported rather than silently claimed as preserved.
|
||||
|
||||
@@ -52,7 +52,9 @@ Press **F1** in a run for the current in-game control list. It is generated from
|
||||
| Move north-west / north-east / south-west / south-east | **Q / keypad 9 / Z / C** |
|
||||
| Interact, open doors/chests, use stairs | **Space** or **E** |
|
||||
| Wait | **.** |
|
||||
| Melee / ranged / cast | **F / R / X** |
|
||||
| Attaque de mêlée | Se déplacer vers la case d’un ennemi adjacent |
|
||||
| Attaque à distance / lancer un sort | **F / X** |
|
||||
| Sauvegarder manuellement | **V** dans le debug Godot, ou **Ctrl+S** en version autonome, puis choisir un emplacement |
|
||||
| Talk / rest | **T / H** |
|
||||
| Inventory / crafting | **I / B** |
|
||||
| Character / quests | **P / J** |
|
||||
@@ -63,13 +65,13 @@ Press **F1** in a run for the current in-game control list. It is generated from
|
||||
| Options / help | **O / F1** |
|
||||
| Expand journal | **L** (shares the achievements default) |
|
||||
|
||||
Several commands open contextual panels. Within selection panels, use arrows to select, **Enter** or **Space** to confirm, and **Esc** to close. In the inventory, use **E** to equip, **U** to use, and **D** to drop the selected item. In the shop, **Tab** changes buy/sell mode. The Options panel supports UI scaling, a high-contrast/color-blind marker mode, and remapping the Inventory control; its displayed keys control ambience and effects volume.
|
||||
Plusieurs commandes ouvrent des panneaux contextuels. Dans les panneaux de sélection, utilisez les flèches pour choisir, **Entrée** ou **Espace** pour confirmer et **Échap** pour annuler. Avec une arme à distance équipée, **F** ouvre les cibles actuellement à portée et en ligne de vue; confirmer le tir consomme immédiatement un tour et les adversaires survivants se déplacent ou attaquent. **K** ouvre les ordres du familier : **Reste en arrière**, **Défends-moi** ou **Attaque à vue**. Dans l’inventaire, utilisez **E** pour équiper, **U** pour utiliser et **D** pour déposer. Dans la boutique, **Tab** change le mode achat/vente.
|
||||
|
||||
## Audio (optional)
|
||||
## Musique et audio
|
||||
|
||||
The game works silently with no audio files. Playback only uses `AudioStream` resources registered in `user://audio/audio_import_manifest.tres`; it does not scan or decode arbitrary files from a directory. The manifest accepts these ambience contexts: `exploration`, `combat`, `danger`; and these SFX events: `attack_given`, `attack_received`, `menu_select`, `menu_cancel`, `item_use`, `death`.
|
||||
Le jeu contient trois ambiances originales intégrées : exploration, combat et danger. L’exploration démarre automatiquement avec la partie et le contexte passe à la musique de combat lors d’un affrontement. Le panneau Options contrôle séparément les volumes Ambiance et Effets.
|
||||
|
||||
This is intentionally a safe, Godot-native setup boundary. A setup/modding tool must import a supported sound into Godot and register the resulting `AudioStream` in the manifest. The Options panel changes separate Ambience and SFX bus volumes; missing, invalid, or unregistered audio remains silent and never blocks gameplay.
|
||||
La personnalisation reste sécurisée : le jeu ne parcourt et ne décode jamais des fichiers arbitraires. Un manifeste Godot optionnel dans `user://audio/audio_import_manifest.tres` peut remplacer individuellement les ressources intégrées avec des `AudioStream` déjà importés. Il reconnaît les contextes `exploration`, `combat`, `danger` et les effets `attack_given`, `attack_received`, `menu_select`, `menu_cancel`, `item_use`, `death`. Une entrée absente du manifeste utilisateur conserve la ressource intégrée correspondante.
|
||||
|
||||
## Known limitations
|
||||
|
||||
|
||||
@@ -0,0 +1,116 @@
|
||||
# Playtest Parity Fixes Implementation Plan
|
||||
|
||||
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
|
||||
|
||||
**Goal:** Corriger les quatre écarts constatés en playtest concernant le jalon race/classe, la lisibilité de l’interface, la représentation du combat et le niveau principal.
|
||||
|
||||
**Architecture:** Conserver les domaines existants et corriger les branchements qui les exposent. La création de partie reste limitée aux paramètres de run; un panneau modal dédié consomme `ClassEngine` à l’entrée de l’étage 3. Le monde affiché reste piloté par `FloorState`, mais la surface et le profil de l’étage 1 sont alignés sur `DCWASCII`.
|
||||
|
||||
**Tech Stack:** Godot 4, GDScript, GUT 9.5.
|
||||
|
||||
**Spec:** Retours de playtest du 2026-10-07 et projet de référence `../DCWASCII` (`dcw/game.py`, `dcw/world/surface.py`, `dcw/world/generator.py`).
|
||||
|
||||
## Global Constraints
|
||||
|
||||
- Préserver la modification locale préexistante de `project.godot`.
|
||||
- Ne pas confondre le niveau principal avec la minimap.
|
||||
- Les choix de race puis de classe sont obligatoires à l’entrée de l’étage 3 du Donjon, pas à la création ni au niveau de personnage 3.
|
||||
- Une attaque de mêlée reste déclenchée uniquement en tentant d’entrer dans la case adjacente occupée.
|
||||
- Les noms techniques et le code restent en anglais.
|
||||
|
||||
---
|
||||
|
||||
### Task 1: Jalon race et classe de l’étage 3
|
||||
|
||||
**Files:**
|
||||
- Modify: `scenes/menu/CharacterCreation.tscn`
|
||||
- Modify: `scripts/presentation/menu/character_creation.gd`
|
||||
- Modify: `scripts/presentation/menu/main_menu.gd`
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Modify: `scripts/domain/progression/class_engine.gd`
|
||||
- Modify: `scripts/domain/run/run_state.gd`
|
||||
- Create: `scenes/ui/RaceClassChoicePanel.tscn`
|
||||
- Create: `scripts/presentation/race_class_choice_panel.gd`
|
||||
- Test: `tests/e2e/test_new_run_creation_e2e.gd`
|
||||
- Test: `tests/e2e/test_floor_three_race_class_e2e.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Consumes: `ClassEngine.race_definitions()`, compatibility rules, `FloorTransition.transition()`.
|
||||
- Produces: a mandatory `RaceClassChoicePanel`, an initially empty race/archetype, and a persisted `RunState.base_archetype` after confirmation.
|
||||
|
||||
- [ ] Add a failing creation-flow test proving there are no race/class controls and the new player has empty choices.
|
||||
- [ ] Remove race/class fields and arguments from the creation flow.
|
||||
- [ ] Add a failing floor-transition test proving entry to floor 3 opens a mandatory race-first modal.
|
||||
- [ ] Add separate race and class application methods to `ClassEngine` and implement the modal sequence.
|
||||
- [ ] Verify both focused E2E tests.
|
||||
|
||||
### Task 2: HUD and chest layout
|
||||
|
||||
**Files:**
|
||||
- Modify: `scenes/Game.tscn`
|
||||
- Modify: `scenes/ui/LootPanel.tscn`
|
||||
- Test: `tests/unit/test_hud_layout.gd`
|
||||
- Test: `tests/unit/test_loot_panel_layout.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Consumes: existing HUD node paths retained for compatibility.
|
||||
- Produces: non-overlapping visible rectangles at 1280×720.
|
||||
|
||||
- [ ] Add failing rectangle-intersection assertions for all visible HUD labels and chest panel sections.
|
||||
- [ ] Give each visible HUD datum a distinct row and sufficient wrapping space.
|
||||
- [ ] Put chest title, entries and action inside a vertical layout container.
|
||||
- [ ] Verify focused layout tests.
|
||||
|
||||
### Task 3: Combat presentation and action wording
|
||||
|
||||
**Files:**
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Modify: `scripts/domain/turn_resolver.gd`
|
||||
- Test: `tests/e2e/test_enemy_ai_e2e.gd`
|
||||
- Test: `tests/unit/test_turn_resolver.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Consumes: authoritative `ActorState.cell` positions and equipped main-hand metadata when available.
|
||||
- Produces: synchronized enemy sprites after every resolved turn and melee messages that name the attack method.
|
||||
|
||||
- [ ] Add a failing E2E assertion that an enemy view follows the enemy state after movement.
|
||||
- [ ] Resynchronize enemy views during player-action presentation updates.
|
||||
- [ ] Add failing assertions that melee messages identify bare hands, equipped weapon, or natural attack while retaining damage wording.
|
||||
- [ ] Add attack-method metadata to result messages without changing melee range rules.
|
||||
- [ ] Verify focused combat tests.
|
||||
|
||||
### Task 4: Surface and procedural dungeon
|
||||
|
||||
**Files:**
|
||||
- Modify: `scripts/domain/world/surface_generator.gd`
|
||||
- Modify: `scripts/domain/world/floor_generator.gd`
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Modify: `tests/unit/test_surface_floor_transition.gd`
|
||||
- Modify: `tests/unit/test_floor_generator_rooms.gd`
|
||||
- Replace: `tests/unit/test_demo_map.gd`
|
||||
- Replace: `tests/e2e/test_demo_map_chest_e2e.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Consumes: reference surface contract (42×16, empty zone, corridor, door, stairs) and regular procedural formula `180 + floor*30`, `90 + floor*15`, `150 + floor*20`.
|
||||
- Produces: the true reference surface at floor 0 and a 210×105, 170-room procedural floor 1.
|
||||
|
||||
- [ ] Add failing surface assertions for dimensions, empty population, entrance, door and stairs.
|
||||
- [ ] Port the reference surface geometry.
|
||||
- [ ] Add failing floor-1 profile assertions for map size and room target.
|
||||
- [ ] Remove the obsolete shallow floor-1 profile and dead duplicate POC construction.
|
||||
- [ ] Replace POC route tests with surface-to-generated-dungeon behavior tests.
|
||||
- [ ] Verify world unit, integration and E2E tests.
|
||||
|
||||
### Task 5: Regression verification
|
||||
|
||||
**Files:**
|
||||
- Modify only tests whose old expectations explicitly encoded the removed POC or creation-time class choice.
|
||||
|
||||
**Interfaces:**
|
||||
- Consumes: `scripts/verify.sh` and focused GUT runners.
|
||||
- Produces: passing unit, integration, E2E and visual verification without modifying `project.godot`.
|
||||
|
||||
- [ ] Run focused suites after every red/green cycle.
|
||||
- [ ] Run `git diff --check`.
|
||||
- [ ] Run `./scripts/verify.sh`.
|
||||
- [ ] Inspect the regenerated visual captures for the main level, HUD and chest panel.
|
||||
@@ -0,0 +1,107 @@
|
||||
# Health Regeneration and Pets Implementation Plan
|
||||
|
||||
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
|
||||
|
||||
**Goal:** Porter dans le jeu Godot la régénération passive automatique des PV et rendre le familier créé avec la partie réellement configurable, persistant et utile en exploration/combat, conformément aux comportements de référence de DCWASCII.
|
||||
|
||||
**Architecture:** La formule de régénération reste une règle de domaine pure, appelée une seule fois à la fin de chaque tour résolu et appliquée silencieusement au joueur puis au familier vivant. Le familier reste l’agrégat `CompanionState` existant, enrichi avec son identité, ses caractéristiques de régénération et une IA agressive/défensive/soutien; la création, les transitions d’étage, l’UI et la sauvegarde consomment cet agrégat sans dupliquer les règles.
|
||||
|
||||
**Tech Stack:** Godot 4.7, GDScript, GUT 9.5, scènes `.tscn`, sauvegardes JSON.
|
||||
|
||||
**Spec:** Référence fonctionnelle `../DCWASCII/README.md` sections « Familier jouable » et « Système de soins », ainsi que `../DCWASCII/dcw/entities/{player,companion}.py`, `../DCWASCII/dcw/game.py`, `../DCWASCII/dcw/ai/companion_behaviors.py`.
|
||||
|
||||
## Global Constraints
|
||||
|
||||
- Préserver tous les changements locaux déjà présents; ne pas réinitialiser ni réécrire les modifications non liées.
|
||||
- Régénération ASCII: `max(1, Endurance / 3)`, bonus `regen_bonus`, amplification de 15 % par rang de compétence Régénération au-delà du rang de base 1, puis multiplicateur de difficulté (1,5 / 1 / 0,75 / 0,5).
|
||||
- La régénération est silencieuse, plafonnée aux PV max, active dès le niveau 1, une fois par tour consommé, et ne ranime jamais une entité morte.
|
||||
- Le familier est optionnel, autonome, persistant, suit le joueur entre les étages et sa mort ne termine pas la partie.
|
||||
- Conserver les coutures publiques et les sauvegardes existantes compatibles.
|
||||
|
||||
---
|
||||
|
||||
### Task 1: Passive health regeneration rule
|
||||
|
||||
**Files:**
|
||||
- Create: `scripts/domain/combat/health_regeneration.gd`
|
||||
- Test: `tests/unit/test_health_regeneration.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Produces: `HealthRegeneration.amount(endurance: int, regeneration_skill: int, perk_bonus: int, difficulty_id: StringName) -> int`
|
||||
- Produces: `HealthRegeneration.apply(actor: ActorState, endurance: int, regeneration_skill: int, perk_bonus: int, difficulty_id: StringName) -> int`
|
||||
|
||||
- [ ] **Step 1: Write the failing formula and cap/death tests**
|
||||
- [ ] **Step 2: Run the focused test and confirm RED because the rule does not exist**
|
||||
- [ ] **Step 3: Implement the exact ASCII formula and difficulty multipliers**
|
||||
- [ ] **Step 4: Run the focused test and confirm GREEN**
|
||||
|
||||
### Task 2: End-of-turn regeneration integration
|
||||
|
||||
**Files:**
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Modify: `scripts/domain/entities/companion_state.gd`
|
||||
- Test: `tests/e2e/test_health_regeneration_e2e.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Consumes: `HealthRegeneration.apply(...)`
|
||||
- Produces: automatic, silent player/pet healing through normal `submit_player_action` gameplay turns.
|
||||
|
||||
- [ ] **Step 1: Add an E2E test that damages the player, consumes real movement turns and observes exact healing without a regeneration journal event**
|
||||
- [ ] **Step 2: Run it and confirm RED because completed turns do not heal**
|
||||
- [ ] **Step 3: Add one centralized end-of-turn hook using the character model’s effective Endurance/skill/perk values and the run difficulty**
|
||||
- [ ] **Step 4: Extend the test to a living pet and confirm dead actors remain at zero**
|
||||
- [ ] **Step 5: Run focused unit/E2E tests and confirm GREEN**
|
||||
|
||||
### Task 3: Configurable pet identity and persistence
|
||||
|
||||
**Files:**
|
||||
- Modify: `scripts/domain/run/run_settings.gd`
|
||||
- Modify: `scripts/domain/entities/companion_state.gd`
|
||||
- Modify: `scripts/presentation/menu/character_creation.gd`
|
||||
- Modify: `scenes/menu/CharacterCreation.tscn`
|
||||
- Modify: `scripts/infrastructure/save/save_repository.gd`
|
||||
- Modify: `scripts/presentation/companion_panel.gd`
|
||||
- Test: `tests/unit/test_companion.gd`
|
||||
- Test: `tests/unit/test_save_repository.gd`
|
||||
- Test: `tests/e2e/test_new_run_creation_e2e.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Produces: optional `RunSettings.pet_name` and `RunSettings.pet_species`, with backward-compatible defaults.
|
||||
- Produces: `CompanionState.name`, `species`, Endurance/skill/perk regeneration fields serialized with the companion.
|
||||
|
||||
- [ ] **Step 1: Add failing tests for identity defaults/custom values and save/load round-trip**
|
||||
- [ ] **Step 2: Run focused tests and confirm RED**
|
||||
- [ ] **Step 3: Add name/species fields shown only when the pet checkbox is enabled and pass them through `RunSettings`**
|
||||
- [ ] **Step 4: Persist the complete companion record while accepting legacy companion records**
|
||||
- [ ] **Step 5: Show name, species and PV in the companion panel**
|
||||
- [ ] **Step 6: Run focused tests and confirm GREEN**
|
||||
|
||||
### Task 4: Functional autonomous pet behavior and floor following
|
||||
|
||||
**Files:**
|
||||
- Modify: `scripts/domain/ai/companion_behaviors.gd`
|
||||
- Modify: `scripts/domain/turn_resolver.gd`
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Test: `tests/unit/test_companion.gd`
|
||||
- Test: `tests/e2e/test_pet_companion_e2e.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Consumes: existing stances `FOLLOW`, `DEFEND`, `SUPPORT` as backward-compatible storage identifiers.
|
||||
- Produces: aggressive chase/attack for `FOLLOW`, threat interception for `DEFEND`, low-PV player healing for `SUPPORT`, nearest-target enemy attacks, and adjacent pet placement after floor changes.
|
||||
|
||||
- [ ] **Step 1: Add one failing behavior test for aggressive chase and one for support healing**
|
||||
- [ ] **Step 2: Run focused tests and confirm RED for the missing decisions**
|
||||
- [ ] **Step 3: Implement deterministic nearest-enemy pursuit and a bounded support-heal action**
|
||||
- [ ] **Step 4: Resolve heal actions and make enemies pursue/attack the nearer living player or pet, with ties favoring the pet**
|
||||
- [ ] **Step 5: Add an E2E floor-transition assertion that the pet is placed next to the player**
|
||||
- [ ] **Step 6: Run pet unit/integration/E2E tests and confirm GREEN**
|
||||
|
||||
### Task 5: Verification and parity evidence
|
||||
|
||||
**Files:**
|
||||
- Modify: `docs/parity/ASCII_TEST_MATRIX.md` only if a new explicit mapping row/note is required.
|
||||
|
||||
- [ ] **Step 1: Run unit tests for regeneration, companions, settings and saves**
|
||||
- [ ] **Step 2: Run pet/new-run/regeneration E2E tests**
|
||||
- [ ] **Step 3: Run the project verification script and inspect failures**
|
||||
- [ ] **Step 4: Confirm `git diff --check` and review the final diff for unrelated changes**
|
||||
@@ -0,0 +1,103 @@
|
||||
# Save, Ranged Combat, and Pet Controls Implementation Plan
|
||||
|
||||
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
|
||||
|
||||
**Goal:** Rendre la sauvegarde accessible sans menu Échap, déplacer l’attaque à distance sur `F` avec sélection de cible et tour ennemi immédiat, puis exposer trois comportements de familier en français avec un sprite temporaire de chien.
|
||||
|
||||
**Architecture:** Le menu principal reste le propriétaire du `SaveRepository`, mais le jeu actif lui demande d’ouvrir le panneau de sauvegarde par signal afin d’éviter un second dépôt et de conserver les cinq emplacements existants. Le ciblage à distance continue d’utiliser `RangedCombat` et `TargetingOverlay`; seules la touche, la validation des cibles et la résolution complète du tour sont renforcées. Les identifiants persistés des postures du familier restent compatibles, tandis que leurs libellés et règles deviennent « reste en arrière », « défends-moi » et « attaque à vue ».
|
||||
|
||||
**Tech Stack:** Godot 4.7, GDScript, GUT 9.5, scènes `.tscn`, sauvegardes JSON.
|
||||
|
||||
**Spec:** Retour de playtest utilisateur du 2026-10-08.
|
||||
|
||||
## Global Constraints
|
||||
|
||||
- Préserver tous les changements locaux déjà présents; ne pas réinitialiser ni réécrire les modifications non liées.
|
||||
- L’attaque à distance se déclenche sur `F` seulement si une arme à distance est équipée; `Entrée` confirme et `Échap` annule la cible sans consommer de tour.
|
||||
- Une attaque à distance valide consomme exactement un tour et fait immédiatement résoudre le déplacement ou l’attaque des adversaires survivants.
|
||||
- Les trois comportements visibles du familier sont « Reste en arrière », « Défends-moi » et « Attaque à vue ».
|
||||
- Le familier utilise temporairement un sprite animal de type chien compatible avec la licence CC0 existante.
|
||||
- Conserver la lecture des anciennes sauvegardes et des anciennes valeurs de posture.
|
||||
|
||||
---
|
||||
|
||||
### Task 1: Sauvegarde accessible et explicite
|
||||
|
||||
**Files:**
|
||||
- Modify: `project.godot`
|
||||
- Modify: `scripts/game/input_bindings.gd`
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Modify: `scripts/presentation/menu/main_menu.gd`
|
||||
- Modify: `scripts/presentation/save_load_panel.gd`
|
||||
- Modify: `scenes/ui/SaveLoadPanel.tscn`
|
||||
- Modify: `tests/unit/test_action_router.gd`
|
||||
- Modify: `tests/e2e/test_save_load_e2e.gd`
|
||||
- Modify: `docs/PLAYING.md`
|
||||
|
||||
**Interfaces:**
|
||||
- Produces: input action `save` on `Ctrl+S`, routed as `PlayerAction(&"save")`.
|
||||
- Produces: `Game.save_requested` connected by `MainMenu` to `show_save_slots()`.
|
||||
- Produces: French save-panel feedback that states that saves are manual and confirms the slot written.
|
||||
|
||||
- [ ] Add a failing action-router assertion for `save` and an E2E test that `Ctrl+S` opens the save-slot panel during a run.
|
||||
- [ ] Add the input binding/help label and the `Game.save_requested` signal branch.
|
||||
- [ ] Connect the game signal in `MainMenu` and keep repository ownership there.
|
||||
- [ ] Translate/clarify save-panel labels and update the player documentation.
|
||||
- [ ] Run focused action-router and save/load tests.
|
||||
|
||||
### Task 2: Attaque à distance sur F et tour ennemi
|
||||
|
||||
**Files:**
|
||||
- Modify: `project.godot`
|
||||
- Modify: `scripts/game/input_bindings.gd`
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Modify: `scripts/presentation/targeting_overlay.gd`
|
||||
- Modify: `tests/e2e/test_ranged_targeting_e2e.gd`
|
||||
- Modify: `tests/e2e/test_input_action_router_e2e.gd`
|
||||
- Modify: `docs/PLAYING.md`
|
||||
|
||||
**Interfaces:**
|
||||
- Produces: `F` bound to `ranged`; the obsolete standalone `attack` input is removed because melee remains movement into an adjacent enemy.
|
||||
- Produces: targeting candidates filtered by weapon range and line of sight.
|
||||
- Consumes: `TurnResolver.append_enemy_response(...)` for every valid shot against a surviving enemy.
|
||||
|
||||
- [ ] Add failing E2E assertions proving `F` opens targeting, invalid/no-weapon input does not consume a turn, cancellation does not consume a turn, and a valid shot advances exactly one turn while the enemy approaches.
|
||||
- [ ] Move `ranged` from `R` to `F` and remove the conflicting unused `attack` action from the input catalog/map.
|
||||
- [ ] Filter displayed targets through `RangedCombat` validation without consuming ammunition.
|
||||
- [ ] Keep confirmation/cancellation explicit in French and resolve one enemy response after a valid shot.
|
||||
- [ ] Run focused ranged, input, turn-resolver, and combat tests.
|
||||
|
||||
### Task 3: Comportements du familier et sprite chien
|
||||
|
||||
**Files:**
|
||||
- Modify: `scripts/domain/entities/companion_state.gd`
|
||||
- Modify: `scripts/domain/ai/companion_behaviors.gd`
|
||||
- Modify: `scripts/domain/turn_resolver.gd`
|
||||
- Modify: `scripts/infrastructure/save/save_repository.gd`
|
||||
- Modify: `scripts/presentation/companion_panel.gd`
|
||||
- Modify: `scenes/Game.tscn`
|
||||
- Create: `assets/dcss/war_dog.png`
|
||||
- Modify: `assets/ASSET_REGISTRY.md`
|
||||
- Modify: `tests/unit/test_companion.gd`
|
||||
- Modify: `tests/e2e/test_pet_companion_e2e.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Produces: persistent stances `stay_back`, `defend`, `attack_on_sight`, while mapping legacy `follow`, `defend`, `support` values.
|
||||
- Produces: behavior rules where `stay_back` follows without engaging, `defend` attacks threats adjacent to the player, and `attack_on_sight` pursues the nearest living enemy.
|
||||
- Produces: French UI labels/descriptions and `assets/dcss/war_dog.png` on `$World/Companion`.
|
||||
|
||||
- [ ] Add failing deterministic unit tests for the three named policies and an E2E panel-selection test for their French labels.
|
||||
- [ ] Define the new stance identifiers and compatibility aliases/migration.
|
||||
- [ ] Implement passive following, player defense, and nearest-enemy aggression.
|
||||
- [ ] Replace support-only interception checks with the defend stance and update journal wording.
|
||||
- [ ] Copy the local CC0 DCSS war-dog tile, wire it to the companion sprite, and register its source/license.
|
||||
- [ ] Run focused companion, support-compatibility, save, and pet E2E tests.
|
||||
|
||||
### Task 4: Vérification
|
||||
|
||||
**Files:**
|
||||
- Modify: `docs/parity/ASCII_TEST_MATRIX.md` only if a mapped contract needs an explicit note.
|
||||
|
||||
- [ ] Run all unit, integration, and E2E suites.
|
||||
- [ ] Run the visual check and inspect the companion sprite and new HUD/help wording.
|
||||
- [ ] Run `git diff --check` and inspect the final diff for unrelated changes.
|
||||
@@ -0,0 +1,57 @@
|
||||
# Temporary Starting Playtest Chests Implementation Plan
|
||||
|
||||
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
|
||||
|
||||
**Goal:** Garantir temporairement trois coffres dans la salle de départ d’une nouvelle partie pour tester la mêlée, la distance et un sort offensif.
|
||||
|
||||
**Architecture:** Un module `TemporaryPlaytestKit` isolé place trois coffres à récompense fixe sur l’étage de surface. `Game` l’appelle uniquement lors d’une nouvelle partie configurée, jamais lors du chargement d’une sauvegarde ni dans le générateur procédural. Les récompenses utilisent le flux normal des coffres; le payload de distance ajoute des munitions et le grimoire utilise l’effet normal `learn_spell`.
|
||||
|
||||
**Tech Stack:** Godot 4.5, GDScript, GUT.
|
||||
|
||||
**Spec:** Retour de playtest du 2026-10-08.
|
||||
|
||||
## Global Constraints
|
||||
|
||||
- Code explicitement temporaire et supprimable dans un fichier autonome.
|
||||
- Exactement trois coffres de playtest sur une nouvelle surface.
|
||||
- Aucun changement aux tables de loot ou aux étages procéduraux.
|
||||
- Les sauvegardes chargées ne recréent pas les coffres.
|
||||
- Récompenses fixes : mêlée, distance avec munitions, grimoire offensif.
|
||||
|
||||
---
|
||||
|
||||
### Task 1: Fixture temporaire de coffres
|
||||
|
||||
**Files:**
|
||||
- Create: `scripts/game/temporary_playtest_kit.gd`
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Create: `tests/e2e/test_temporary_playtest_chests_e2e.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Produces: `TemporaryPlaytestKit.apply_to_new_run(floor: FloorState) -> void`.
|
||||
|
||||
- [ ] Écrire un test E2E rouge instanciant une nouvelle partie et exigeant trois coffres fixes accessibles.
|
||||
- [ ] Créer le module isolé avec trois cellules, trois récompenses et un marqueur metadata temporaire.
|
||||
- [ ] Appeler le module seulement dans le chemin de nouvelle partie configurée.
|
||||
- [ ] Vérifier qu’un chargement ne recrée aucun coffre.
|
||||
|
||||
### Task 2: Récompenses réellement testables
|
||||
|
||||
**Files:**
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Modify: `tests/e2e/test_temporary_playtest_chests_e2e.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Consumes: payload coffre `ammunition` et effet d’objet `learn_spell`.
|
||||
- Produces: munitions ajoutées lors de la récupération; `SpellState.learn(spell_id)` lors de l’utilisation du grimoire.
|
||||
|
||||
- [ ] Tester l’ouverture/récupération normale de chaque coffre.
|
||||
- [ ] Ajouter les munitions du payload à `ActorState.ammunition` dans `_take_all_loot`.
|
||||
- [ ] Après `InventoryState.use_item`, appliquer les effets `learn_spell` acceptés à `spell_state`.
|
||||
- [ ] Vérifier qu’on peut équiper l’arme à distance, cibler avec F, et sélectionner le sort avec X après lecture.
|
||||
|
||||
### Task 3: Vérification
|
||||
|
||||
- [ ] Exécuter les tests ciblés coffre/inventaire/distance/magie.
|
||||
- [ ] Exécuter les suites unitaires et E2E.
|
||||
- [ ] Exécuter `git diff --check` et vérifier que le code temporaire reste contenu dans son module.
|
||||
@@ -0,0 +1,144 @@
|
||||
# UI, Input, Loot, and 1080p Fixes Implementation Plan
|
||||
|
||||
> **For agentic workers:** REQUIRED SUB-SKILL: Use superpowers:subagent-driven-development (recommended) or superpowers:executing-plans to implement this plan task-by-task. Steps use checkbox (`- [ ]`) syntax for tracking.
|
||||
|
||||
**Goal:** Corriger les panneaux à choix illisibles, rendre la sauvegarde accessible depuis le jeu embarqué dans l’éditeur, fiabiliser les flèches de déplacement, diversifier les coffres, matérialiser le butin des ennemis et migrer l’affichage de référence vers 1920×1080.
|
||||
|
||||
**Architecture:** Les panneaux modaux utilisent des conteneurs de mise en page plutôt que des offsets concurrents. Le routeur d’entrée conserve l’InputMap, mais expose une touche de sauvegarde sans modificateur qui n’est pas interceptée par l’éditeur et verrouille un seul déplacement par pression physique. Le résolveur de butin interdit de sélectionner deux fois le même objet pendant une résolution, tandis qu’une étape post-combat unique dans `Game` matérialise les tables de butin sur la cellule de mort pour toutes les voies létales. La résolution de référence devient un contrat 1920×1080 partagé par le projet, les tests et la capture visuelle.
|
||||
|
||||
**Tech Stack:** Godot 4.5, GDScript, GUT 9.5, scènes `.tscn`, JSON de contenu, scripts Bash/Python de vérification visuelle.
|
||||
|
||||
**Spec:** Retours de playtest et capture fournis le 2026-10-08.
|
||||
|
||||
## Global Constraints
|
||||
|
||||
- Préserver les nombreuses modifications locales déjà présentes et ne pas réinitialiser les fichiers hors périmètre.
|
||||
- Les PNJ ne sont jamais des cibles de combat ou des sources de butin ennemi.
|
||||
- Les corrections restent déterministes pour un seed et un contexte identiques.
|
||||
- Les objets d’ennemis doivent être visibles au sol et passer par le flux de ramassage existant.
|
||||
- Le viewport, la fenêtre de référence et les captures deviennent exactement 1920×1080.
|
||||
- Les panneaux ne doivent plus superposer le récit, les choix et l’aide, y compris avec du texte long.
|
||||
|
||||
---
|
||||
|
||||
### Task 1: Résolution de référence 1920×1080
|
||||
|
||||
**Files:**
|
||||
- Modify: `project.godot`
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Modify: `scripts/check-visual-capture.py`
|
||||
- Modify: `scripts/run-visual-check.sh`
|
||||
- Modify: `scripts/build-linux.sh`
|
||||
- Modify: `tests/scripts/test_godot_import_runners.sh`
|
||||
- Modify: `tests/unit/test_display_layout.gd`
|
||||
- Modify: `tests/e2e/test_display_camera_grid_e2e.gd`
|
||||
- Modify: `tests/unit/test_hud_layout.gd`
|
||||
- Modify: `docs/PLAYING.md`
|
||||
|
||||
**Interfaces:**
|
||||
- Produces: `Game.REFERENCE_VIEWPORT == Vector2i(1920, 1080)`.
|
||||
- Produces: exact 1920×1080 PNG visual captures and smoke displays.
|
||||
|
||||
- [ ] Add failing assertions for the new project and `Game` reference dimensions.
|
||||
- [ ] Change project viewport/window overrides and the public game constant.
|
||||
- [ ] Update Xvfb, fake PNG and PNG validation dimensions; derive the measured dungeon crop from the new dimensions.
|
||||
- [ ] Re-express the central HUD clearance area relative to `REFERENCE_VIEWPORT`.
|
||||
- [ ] Run display, HUD, E2E camera and script-runner tests.
|
||||
|
||||
### Task 2: Panneaux de choix adaptatifs et non chevauchants
|
||||
|
||||
**Files:**
|
||||
- Modify: `scenes/ui/EventPanel.tscn`
|
||||
- Modify: `scenes/ui/DialoguePanel.tscn`
|
||||
- Modify: `scenes/ui/QuestPanel.tscn`
|
||||
- Modify: `scripts/presentation/event_panel.gd`
|
||||
- Modify: `scripts/presentation/dialogue_panel.gd`
|
||||
- Modify: `scripts/presentation/quest_panel.gd`
|
||||
- Modify: affected E2E node paths
|
||||
- Create: `tests/unit/test_choice_panel_layout.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Produces: each modal as `PanelContainer > VBoxContainer Layout > Title, Body, Entries, Help`.
|
||||
- Produces: distinct, contained narrative, choice and help rectangles at 1920×1080.
|
||||
|
||||
- [ ] Write a failing rectangle test with representative multiline narrative and choices for Event, Dialogue and Quest.
|
||||
- [ ] Replace direct children and absolute offsets with one `VBoxContainer`, content margins and explicit vertical allocation.
|
||||
- [ ] Update scripts and E2E paths from `$Body`/`$Entries` to `$Layout/Body`/`$Layout/Entries`.
|
||||
- [ ] Verify at least 12 px logical separation and containment after two layout frames.
|
||||
- [ ] Run choice-panel, dialogue, event and quest tests.
|
||||
|
||||
### Task 3: Sauvegarde utilisable depuis le debug embarqué et entrée fiable
|
||||
|
||||
**Files:**
|
||||
- Modify: `project.godot`
|
||||
- Modify: `scripts/game/input_bindings.gd`
|
||||
- Modify: `scripts/game/action_router.gd`
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Modify: `scenes/Game.tscn`
|
||||
- Modify: `tests/unit/test_action_router.gd`
|
||||
- Modify: `tests/e2e/test_save_load_e2e.gd`
|
||||
- Modify: `tests/e2e/test_input_action_router_e2e.gd`
|
||||
- Modify: `docs/PLAYING.md`
|
||||
|
||||
**Interfaces:**
|
||||
- Consumes: existing `save` player action and `Game.save_requested` signal.
|
||||
- Produces: `V` as editor-safe save shortcut while retaining `Ctrl+S` for standalone/exported builds.
|
||||
- Produces: one movement action per non-echo physical arrow press.
|
||||
|
||||
- [ ] Add a failing E2E test that opens save slots with plain `V` through real input.
|
||||
- [ ] Add `V` as a second `save` binding and document why `Ctrl+S` is intercepted by the Godot editor’s own Save command in embedded play.
|
||||
- [ ] Add a repeated alternating Up/Down E2E test proving every press is routed once and echo events do not create or swallow actions.
|
||||
- [ ] Handle arrow physical keycodes deterministically before ambiguous action matching and ignore `InputEventKey.echo` for turn commands.
|
||||
- [ ] Update the HUD/help text and run action/input/save tests.
|
||||
|
||||
### Task 4: Coffres sans objets répétés
|
||||
|
||||
**Files:**
|
||||
- Modify: `scripts/domain/items/loot_resolver.gd`
|
||||
- Modify: `scripts/domain/world/floor_populator.gd`
|
||||
- Modify: `tests/unit/test_loot_resolver.gd`
|
||||
- Modify: `tests/unit/test_floor_populator.gd`
|
||||
- Modify: `tests/e2e/test_world_chest_loot_e2e.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Produces: `LootResolver.resolve(...)` selects each `item_id` at most once per reward; explicit `min_qty/max_qty` remains the sole source of quantity.
|
||||
- Produces: ordinary treasure rooms use `floor_treasure`, not arbitrary enemy or boss tables.
|
||||
|
||||
- [ ] Add a failing dominant-weight multi-roll test showing the same item is currently selected twice.
|
||||
- [ ] Filter already-selected item IDs from subsequent weighted rolls while leaving gold/empty repeatable.
|
||||
- [ ] Assert that generated treasure chests use the floor treasure table.
|
||||
- [ ] Run resolver, chest, population and deterministic-generation tests.
|
||||
|
||||
### Task 5: Butin ennemi matérialisé et ramassable
|
||||
|
||||
**Files:**
|
||||
- Modify: `scripts/game/game.gd`
|
||||
- Modify: `scripts/domain/magic/magic_engine.gd`
|
||||
- Modify: `scripts/presentation/loot_feedback.gd`
|
||||
- Modify: `tests/e2e/test_melee_feedback_e2e.gd`
|
||||
- Modify: `tests/e2e/test_ranged_targeting_e2e.gd`
|
||||
- Modify: `tests/e2e/test_spell_casting_e2e.gd`
|
||||
- Modify: `tests/unit/test_save_repository.gd`
|
||||
|
||||
**Interfaces:**
|
||||
- Produces: one post-combat materialization step that resolves each `loot_dropped` descriptor exactly once.
|
||||
- Produces: valid `ItemInstance` entries in `FloorState.ground_items[death_cell]` and immediate run gold credit.
|
||||
- Produces: resolved `loot_dropped` payload containing `loot_table`, `items`, `gold`, and `empty`.
|
||||
|
||||
- [ ] Add a failing melee E2E assertion that a catalog-backed killed enemy leaves a ground item at its death cell.
|
||||
- [ ] Resolve the enemy loot table using a stable `enemy:<floor>:<actor_id>` context before event journaling, create item instances, add them to `ground_items`, and credit gold.
|
||||
- [ ] Add the missing loot descriptor to lethal spell outcomes so magic shares the same post-combat pipeline.
|
||||
- [ ] Verify melee, ranged, companion and spell deaths each materialize once, and the existing interaction picks the item up.
|
||||
- [ ] Verify save/load round-trips the generated drop and update feedback wording from “secured” to “dropped”.
|
||||
|
||||
### Task 6: Verification complète
|
||||
|
||||
**Files:**
|
||||
- Modify: no production files unless a verified regression requires it.
|
||||
|
||||
- [ ] Run all unit tests.
|
||||
- [ ] Run all integration tests.
|
||||
- [ ] Run all E2E tests.
|
||||
- [ ] Run visual capture and inspect both 1920×1080 images.
|
||||
- [ ] Run matrix parity gate and `git diff --check`.
|
||||
- [ ] Review the final diff for unrelated or generated temporary files.
|
||||
Reference in New Issue
Block a user