Files
purpur-tyrant/design/user-stories/us-018-complete-commands-contextually.md
T
dmg 0c4a95801a
Release / release (push) Successful in 2m56s
CI / build (push) Successful in 1m12s
feat(gear): add Tyrant legacy tools and weapons
2026-09-09 22:02:59 -04:00

50 lines
3.1 KiB
Markdown

---
type: User Story
title: "US-018: Complete Tyrant commands contextually"
description: Replace Bukkit's player-name fallback with valid context-aware command suggestions.
status: done
---
# US-018: Complete Tyrant commands contextually
As a **player or administrator**, I want contextual command suggestions so that I can discover valid Tyrant commands and arguments.
## Acceptance criteria
- [x] `/tyrant` suggests its available subcommands instead of arbitrary player names.
- [x] `/tyrant buy` suggests Tyrant unlock names.
- [x] `/tyrant gear` suggests `axe`, `pickaxe`, `sword`, `hoe`, and `shovel` and accepts no further arguments; see [US-022](us-022-purchase-legacy-tools-and-weapons.md).
- [x] `/tyrant armor` suggests `helmet`, `chestplate`, `leggings`, and `boots` and accepts no further arguments.
- [x] `/tyrant assign` suggests `assassin`, `fixer`, and `tamer`, followed by eligible online players.
- [x] `/tyrant relinquish` suggests `confirm`.
- [x] `/vigilante` suggests its available subcommands.
- [x] `/vigilante invite` suggests eligible online recruitment candidates.
- [x] `/vigilante dismiss` suggests current online Followers.
- [x] `/tyrantadmin` suggestions are visible only to senders with `spigottyrant.admin`.
- [x] `/tyrantadmin start` suggests online Tyrant and Vigilante candidates.
- [x] `/tyrantadmin reset` suggests `confirm`.
- [x] `/tyrantadmin arena` suggests `set` and `status`.
- [x] `/tyrantadmin` suggests `grantpoint`, which accepts no additional arguments.
- [x] Suggestions are filtered case-insensitively by the partially typed argument.
- [x] Suggestions never include syntactically invalid options for the current argument position.
- [x] Console completion works for administrative commands without exposing player-only commands as executable console actions.
- [x] Existing command execution behavior remains unchanged.
## Validation
Automated tests verify root syntax, unlocks, legacy armor pieces, classes, confirmations, eligible recruits, current Followers, permission gating, online administrative candidates, the argument-free `grantpoint` command, argument positions, and case-insensitive prefix filtering. The complete `./gradlew clean check jar` lifecycle passes.
## US-022 validation
Verified gear discovery, all five alphabetically sorted tool names, case-insensitive prefix matching, no extra arguments, and unchanged armor-only suggestions with `./gradlew clean check jar` (177 passing tests); see [US-022 verification](us-022-purchase-legacy-tools-and-weapons.md#validation-scope).
## Related
- [Start, pause, and administer the game](us-001-start-pause-and-administer.md)
- [Assign unlocked classes](us-004-assign-unlocked-classes.md)
- [Support the Vigilante and Followers](us-008-support-vigilante-and-followers.md)
- [Manage a reign through the Tyrant control panel](us-015-manage-tyrant-control-panel.md)
- [Claim the Vigilante role in the arena](us-019-claim-vigilante-in-arena.md)
- [Manage Followers through the Vigilante control panel](us-016-manage-vigilante-control-panel.md)
- [Claim Tyrant legacy armor](us-021-claim-tyrant-legacy-armor.md)