2.1 KiB
2.1 KiB
| id | title | priority | status | scope | owner | parent | updated_at | evidence | |||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| p2-53a1 | Sentry bridge state pipe — extend `GdUnitActions` signature to pass `is_sentrying` | p2 | done | game1 | simulator-infra | p2-53a | 2026-05-01 |
|
Summary
p2-53a shipped the Sentry/Unsentry ActionKind end-to-end EXCEPT the GDExtension bridge: api-gdext/src/action.rs:58 and :96 hardcode is_sentrying: false with TODO comments. This means the unit panel in Godot cannot show the Unsentry button (it never thinks the unit is sentrying), only the Sentry button, regardless of actual state.
This sub-objective closes the loop. Tiny scope — one signature extension, one GDScript caller update, one test.
Acceptance
- [✓]
GdUnitActions::legal_actions_forsignature gainsis_sentrying: bool(afteris_fortified). —api-gdext/src/action.rs:40-62 - [✓]
GdUnitActions::can_invokesame. —api-gdext/src/action.rs:73-104 - [✓]
unit_panel.gd::_refresh_action_buttonspasses_get_is_sentrying(_selected_unit)(new helper readingunit.is_sentrying). —unit_panel.gd:185,190,560-566 - [✓]
Unit.gd(entities/unit.gd) exposesis_sentrying: boolproperty mirroring the Rust state field. —entities/unit.gd:67 - [✓] Bridge test: sentrying unit's
legal_actions_forreturns Unsentry-enabled and Sentry-disabled withAlreadySentryingreason. —test_unit_actions.gd: test_gd_unit_actions_bridge_sentrying_unit_shows_unsentry - [✓] All gates green. —
cargo test -p mc-core 87 passed 0 failed
Non-goals
- Refactoring the bridge to take a Dictionary instead of accumulating positional bools (that's a separate cleanup; track if it grows further).