World.replace_resource: def of bendvy-ecs-core@0.1.0.4 Import: import bendvy-ecs-core@0.1.0.4/world.bend as World Lines 244-248 of bendvy-ecs-core@0.1.0.4/world.bend: https://jend.leeeet.dev/read.txt?path=bendvy-ecs-core@0.1.0.4/world.bend&start_line=244&end_line=248 import Base # Immediate whole-resource swap returning the displaced actual R owner. This raw # administrative operation supplies neither projection restrictions nor undo. def replace_resource(~S: Data,~C: Type,~R: Type,~E: Data,world: World,replacement: R) -> World & R: match world: case World{+namespace,allocator,store,resource,+events,pending,+registrations,+nextSystemId,+clock}: (World{namespace,allocator,store,replacement,events,pending,registrations,nextSystemId,clock},resource) Uses (3): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Sigma https://jend.leeeet.dev/definition.txt?path=bendvy-ecs-core@0.1.0.4/world.bend&name=World