def set
bendvy-ecs-core@0.1.0.4 · ordinary_machine_operations.bend:19
import bendvy-ecs-core@0.1.0.4/ordinary_machine_operations.bend as OrdinaryMachineOperations
import Base
import bendvy-ecs-core@0.1.0.4/ordinary_machine_declaration.bend as OD
import bendvy-ecs-core@0.1.0.4/machine_queue.bend as Q
import bendvy-ecs-core@0.1.0.4/machine.bend as M
import bendvy-ecs-core@0.1.0.4/machine_world.bend as MW
import bendvy-ecs-core@0.1.0.4/transaction.bend as Tx
import bendvy-ecs-core@0.1.0.4/world.bend as W
19
20
21
22
23def set(~S:Data,~K:Data,~V:Data,~C:Type,~R:Type,~E:Data,~take:R -> R & M.Slot<S,K,V>,~put:R -> M.Slot<S,K,V> -> R,~same:V -> V -> Bool,~declaration:OD.Declaration<S,K,V,R,take>,frame:Tx.Tx<W.World<S,C,R,E>,E>,input:M.QueueInput<V>) -> Tx.Tx<W.World<S,C,R,E>,E>:
24 Q.next_declared(~S,~K,~V,~W.World<S,C,R,E>,~E,~MW.take(~S,~K,~V,~C,~R,~E,~take),~MW.put(~S,~K,~V,~C,~R,~E,~put),~same,M.Family{OD.name(~S,~K,~V,~R,~take,declaration)},frame,input)