function · ui
button
Records one semantic button bound to a logical action.
ui.button(label, action_id, semantic_label, focus_order?)
- Stable ID
ui.button- Owner
- app.ScriptPackageHost
- Authority
- presentation
- Timing
- composition
- Availability
- Phase 14 package callbacks
- Side effects
- records bounded detached presentation intent
- Determinism
- Host-created package identity and per-callback budgets.
- Introduced
- 1.0.0
Usage
Call during composition to append validated semantic presentation state. This function cannot mutate simulation owners.
Parameters
- label: visible button text.
- action_id: registered logical action dispatched to handle_action.
- semantic_label: assistive description of the action.
- focus_order: optional deterministic keyboard order.
Returns
No gameplay value. The call appends or updates semantic presentation state for the current composition pass.
Cost
Counts against the package composition instruction and surface work budgets; it does not traverse simulation ownership.
Fields
This symbol has no fields.
Errors
- None
Examples
ui.button("Take Control", "ui.action.actor.take-control", "Directly control the selected villager", 1)
API history
- 1.0.0: Runtime contract published from the complete Phase 14 registry.