def tx_despawn_observed

bendvy-ecs-core@0.1.0.4 · commands.bend:174

import bendvy-ecs-core@0.1.0.4/commands.bend as Commands
import Base
import bendvy-ecs-core@0.1.0.4/world.bend as W
import bendvy-ecs-core@0.1.0.4/transaction.bend as T

174# Stage cleanup plus typed lifecycle publication for a command-valid handle.
175# Queue admission returns Tx and Status; barrier application rechecks live validity
176# before consuming payloads and publishing records. These Data records do not own
177# the removed Type payloads or imply automatic recovery.
178def tx_despawn_observed(~S: Data,~C: Type,~R: Type,~E: Data,~clear: C -> W.Handle<S> -> C & List<&2,E>,~record: W.Handle<S> -> E,tx: T.Tx<W.World<S,C,R,E>,E>,+handle: W.Handle<S>) -> T.Tx<W.World<S,C,R,E>,E> & W.Status:
179  match tx:
180    case T.Tx{world,undo,commands,events,trace}: despawn_join_observed(~S,~C,~R,~E,~clear,~record,W.command_valid(~S,~C,~R,~E,world,handle),undo,commands,events,trace,handle)

Uses (8)

Used by (2)