~/bend-docscommunity

ordinary_machine_schedule.bend checks

raw source on the hub · import bendvy-ecs-core@0.1.0.2/ordinary_machine_schedule.bend as Ordinary_machine_schedule

4 imports
import Base
import ./schedule.bend as Sch
import ./world.bend as W
import ./system.bend as Sys

Types

type Declaration source · line 7 · raw

@-S:Data -> Data

Declaration lowering owns fixed group order; closed callbacks retain failure outcomes. Detached ordinary marker schedule name; phase lowering is fixed by the library.

Definitions

def phase_name source · line 10 · raw

@id:U32 -> String

def steps source · line 18 · raw

List<&2, 0xb2b0f04555daca474f0f77d0966945c9/schedule.Step>

Fixed sequence: structural barrier, then apply, exit, transition and enter system groups with their phase labels and condition slot zero.

Templates

template declare source · line 9 · raw

@-S:Data -> @name:String -> Declaration<S>

Declare the marker schedule label without building or executing handlers.

template install source · line 21 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @-H:Type -> @-Error:Data -> @declaration:Declaration<S> -> @namespace:U32 -> @owners:H -> 0xb2b0f04555daca474f0f77d0966945c9/schedule.Build<S, C, R, E, H>

Build the fixed four-group schedule retaining actual H owners. Group ids 1..4 are internal dispatch slots, not newly registered gameplay system identities.

template dispatch source · line 27 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @-H:Type -> @-Error:Data -> @-apply:(@_:H -> @_:0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E> -> Pair(H, 0xb2b0f04555daca474f0f77d0966945c9/system.Outcome<0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E>, Error, Unit>)) -> @-exit:(@_:H -> @_:0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E> -> Pair(H, 0xb2b0f04555daca474f0f77d0966945c9/system.Outcome<0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E>, Error, Unit>)) -> @-transition:(@_:H -> @_:0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E> -> Pair(H, 0xb2b0f04555daca474f0f77d0966945c9/system.Outcome<0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E>, Error, Unit>)) -> @-enter:(@_:H -> @_:0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E> -> Pair(H, 0xb2b0f04555daca474f0f77d0966945c9/system.Outcome<0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E>, Error, Unit>)) -> @owners:H -> @world:0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E> -> @id:U32 -> Pair(H, 0xb2b0f04555daca474f0f77d0966945c9/system.Outcome<0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E>, Error, Unit>)

Advanced fixed-group router: ids 1/2/3 call apply/exit/transition; the remaining case calls enter. Use with steps(), not arbitrary ids assumed validated here. Closed callbacks must return actual owners/World and their failure outcome.

template condition source · line 34 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @world:0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E> -> @_:U32 -> Pair(0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E>, Bool)

Fixed marker group condition returns World unchanged and True.

template run source · line 39 · raw

@-S:Data -> @-C:Type -> @-R:Type -> @-E:Data -> @-H:Type -> @-Error:Data -> @-apply:(@_:H -> @_:0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E> -> Pair(H, 0xb2b0f04555daca474f0f77d0966945c9/system.Outcome<0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E>, Error, Unit>)) -> @-exit:(@_:H -> @_:0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E> -> Pair(H, 0xb2b0f04555daca474f0f77d0966945c9/system.Outcome<0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E>, Error, Unit>)) -> @-transition:(@_:H -> @_:0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E> -> Pair(H, 0xb2b0f04555daca474f0f77d0966945c9/system.Outcome<0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E>, Error, Unit>)) -> @-enter:(@_:H -> @_:0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E> -> Pair(H, 0xb2b0f04555daca474f0f77d0966945c9/system.Outcome<0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E>, Error, Unit>)) -> @schedule:0xb2b0f04555daca474f0f77d0966945c9/schedule.Schedule<S, C, R, E, H> -> @world:0xb2b0f04555daca474f0f77d0966945c9/world.World<S, C, R, E> -> 0xb2b0f04555daca474f0f77d0966945c9/schedule.RunResult<S, C, R, E, H, Error>

Run the fixed schedule after namespace admission, preserving H and World in all results. Stop on first failed callback; earlier successful transactions are not one marker-wide rollback. Explicit initial barrier precedes group dispatch. See docs/parity/handlers.md for the higher-level transition-marker contract.