|
|
@ -54,6 +54,30 @@ A `chance` answer needs a `{"type": "chance", "outcomes": [...]}` entry at its p |
|
|
it is flattened into sibling entries instead, the outcome lookup silently returns `nil` and |
|
|
it is flattened into sibling entries instead, the outcome lookup silently returns `nil` and |
|
|
that branch scores nothing. Verify with a `bin/rails runner` walk of the tree after editing. |
|
|
that branch scores nothing. Verify with a `bin/rails runner` walk of the tree after editing. |
|
|
|
|
|
|
|
|
|
|
|
### Result band consistency guard |
|
|
|
|
|
|
|
|
|
|
|
The two axes can diverge: a good `chance` outcome gives only `overall: 1` where a safe good |
|
|
|
|
|
answer gives `2`, so a player can accumulate green impact but a low `overall` — and land a |
|
|
|
|
|
"close call" headline above three positive impact texts. |
|
|
|
|
|
|
|
|
|
|
|
`GameHelper#result_state` therefore raises the band from `overall` to at least |
|
|
|
|
|
`GameHelper#tone_floor`, computed from the same `impact_tone` values the impact texts use: |
|
|
|
|
|
all three positive floors at `:best`, none negative floors at `:balanced`. **The guard only |
|
|
|
|
|
lifts, never lowers** — a high `overall` still reaches `:best`, and any negative metric still |
|
|
|
|
|
allows `:worst`. The early-exit / last-save branch returns before the guard and is unaffected. |
|
|
|
|
|
|
|
|
|
|
|
**Consequence:** the headline and the three impact texts are no longer independent. Retuning |
|
|
|
|
|
`impact` values in `question_scores.json` can move the headline even when `overall` is |
|
|
|
|
|
untouched, and changing `IMPACT_TONE_BANDS` changes both the texts and the band floor. |
|
|
|
|
|
|
|
|
|
|
|
### Results copy |
|
|
|
|
|
|
|
|
|
|
|
Each impact category needs three distinct tone strings — `positive`, `neutral`, `negative` |
|
|
|
|
|
under `game.results.<category>` — in **all 24 locale files**. A missing tone is easy to miss |
|
|
|
|
|
because nothing raises: `neutral` was a verbatim copy of `positive` in every locale, so an |
|
|
|
|
|
`income: 0` player was told they "earned some money". When touching these, sweep all locales |
|
|
|
|
|
and check the three strings actually differ, not just that the key exists. |
|
|
|
|
|
|
|
|
## Project Structure |
|
|
## Project Structure |
|
|
|
|
|
|
|
|
- `app/controllers/admin/`: Admin backend logic. |
|
|
- `app/controllers/admin/`: Admin backend logic. |
|
|
|