command · command.work
Assign work
Assigns one current visible Work job to one Actor through the retained order path.
command.work.assign(actor_id, expected_actor_revision, job_id, expected_job_revision, work_task_id, expected_task_revision, target_site_id, expected_topology_revision) -> command.receipt
- Stable ID
command.work.assign- Owner
- game.work-lifecycle
- Authority
- request
- Timing
- fixed_tick
- Availability
- active-session
- Side effects
- may create and activate one durable player assignment order
- Determinism
- record request and Work result in engine sequence order
- Introduced
- 1.5.0
Usage
Use one current row from world.work.targets without altering its stable IDs or revisions. The normal assignment-order path decides whether the Actor can accept the work.
Parameters
- actor_id: target Actor.
- expected_actor_revision: current Actor revision.
- job_id: visible Work job.
- expected_job_revision: current job revision.
- work_task_id: first target Work task.
- expected_task_revision: current task revision.
- target_site_id: target Site.
- expected_topology_revision: current World topology revision.
Returns
A fixed-tick receipt for a durable player assignment-order request.
Cost
Bounded indexed validation across Actor, Work, World, and ControlAuthority.
Fields
| ID | Type | Units | Required | Description |
|---|---|---|---|---|
actor_id | stable-id | none | yes | Actor receiving the work direction. |
expected_actor_revision | revision | none | yes | Expected Actor owner revision. |
expected_job_revision | revision | none | yes | Expected Work job revision. |
expected_task_revision | revision | none | yes | Expected Work task revision. |
expected_topology_revision | revision | none | yes | Expected World topology revision. |
job_id | stable-id | none | yes | Current visible Work job. |
target_site_id | stable-id | none | yes | World Site that owns the work target. |
work_task_id | stable-id | none | yes | First task of the selected job. |
Errors
error.command-budget-exhaustederror.command-owner-rejectederror.command-queue-fullerror.invalid-commanderror.restricted-command
Examples
command.submit("command.work.assign", target, 1)
API history
- 1.5.0: Player assignment to visible settlement work added for Phase 16D.