@almadar/std 16.151.0 → 16.153.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/behaviors/lolo/infra/atoms/std-data-erasure.lolo +5 -1
- package/behaviors/lolo/ui/core/atoms/std-browse.lolo +15 -4
- package/behaviors/lolo/ui/core/molecules/ui-data-list.lolo +12 -0
- package/behaviors/lolo/ui/core/molecules/ui-emoji-picker.lolo +56 -0
- package/behaviors/lolo/ui/core/molecules/ui-popover.lolo +39 -0
- package/behaviors/lolo/ui/core/molecules/ui-table-view.lolo +11 -0
- package/behaviors/lolo/ui/game/atoms/ui-draw-group.lolo +54 -0
- package/behaviors/lolo/ui/game/atoms/ui-draw-shape.lolo +6 -1
- package/behaviors/lolo/ui/game/atoms/ui-draw-sprite.lolo +2 -2
- package/behaviors/lolo/ui/game/atoms/ui-svg-draw-group.lolo +58 -0
- package/behaviors/lolo/ui/game/atoms/ui-svg-draw-shape.lolo +103 -0
- package/behaviors/lolo/ui/game/atoms/ui-svg-draw-text.lolo +58 -0
- package/behaviors/lolo/ui/game/molecules/ui-canvas-2d.lolo +11 -1
- package/behaviors/lolo/ui/game/molecules/ui-canvas.lolo +10 -0
- package/behaviors/lolo/ui/game/molecules/ui-draw-shape-layer.lolo +3 -2
- package/behaviors/lolo/ui/game/molecules/ui-svg-draw-shape-layer.lolo +52 -0
- package/behaviors/lolo/ui/game/molecules/ui-svg-stage.lolo +98 -0
- package/behaviors/lolo/ui/game/organisms/ui-fishing-board.lolo +8 -8
- package/behaviors/lolo/ui/game/organisms/ui-physics-sandbox-board.lolo +5 -5
- package/behaviors/lolo/ui/game/organisms/ui-roguelike-board.lolo +5 -5
- package/behaviors/lolo/ui/game/organisms/ui-sokoban-board.lolo +5 -5
- package/behaviors/lolo/ui/game/organisms/ui-state-architect-board.lolo +4 -4
- package/behaviors/lolo/ui/game/organisms/ui-winter-ski-board.lolo +7 -7
- package/behaviors/registry/factory-signatures.json +6211 -2181
- package/behaviors/registry/infra/atoms/std-approval-gate.orb +16 -8
- package/behaviors/registry/infra/atoms/std-cache-aside.orb +62 -31
- package/behaviors/registry/infra/atoms/std-circuit-breaker.orb +32 -16
- package/behaviors/registry/infra/atoms/std-data-erasure.orb +17 -9
- package/behaviors/registry/infra/atoms/std-mod-queue.orb +16 -8
- package/behaviors/registry/infra/atoms/std-rate-limiter.orb +28 -14
- package/behaviors/registry/ml/molecules/std-escalating-decision.orb +10 -5
- package/behaviors/registry/ml/molecules/std-knowledge-tracing.orb +4 -2
- package/behaviors/registry/ui/core/atoms/std-billable-hour.orb +2 -1
- package/behaviors/registry/ui/core/atoms/std-browse.orb +108 -28
- package/behaviors/registry/ui/core/atoms/std-dashboard-grid-embedded.orb +2 -1
- package/behaviors/registry/ui/core/atoms/std-esign-flow.orb +4 -2
- package/behaviors/registry/ui/core/atoms/std-esign-request.orb +6 -3
- package/behaviors/registry/ui/core/atoms/std-gallery.orb +18 -9
- package/behaviors/registry/ui/core/atoms/std-import.orb +4 -2
- package/behaviors/registry/ui/core/molecules/ui-data-list.orb +21 -0
- package/behaviors/registry/ui/core/molecules/ui-emoji-picker.orb +214 -0
- package/behaviors/registry/ui/core/molecules/ui-popover.orb +112 -1
- package/behaviors/registry/ui/core/molecules/ui-table-view.orb +44 -0
- package/behaviors/registry/ui/game/atoms/std-arcade-flow.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-arcade-play.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-chase-ai.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-dungeon-combat.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-fx-particles.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-gather.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-gold.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-grid-tactics.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-hero-nav.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-market-flow.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-objective-flow.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-objective-reach.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-patience.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-production.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-round-flow.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-score.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-survival-flow.orb +1 -0
- package/behaviors/registry/ui/game/atoms/std-xp.orb +1 -0
- package/behaviors/registry/ui/game/atoms/ui-draw-group.orb +196 -0
- package/behaviors/registry/ui/game/atoms/ui-draw-shape.orb +9 -1
- package/behaviors/registry/ui/game/atoms/ui-draw-sprite.orb +2 -2
- package/behaviors/registry/ui/game/atoms/ui-svg-draw-group.orb +186 -0
- package/behaviors/registry/ui/game/atoms/ui-svg-draw-shape.orb +259 -0
- package/behaviors/registry/ui/game/atoms/ui-svg-draw-text.orb +195 -0
- package/behaviors/registry/ui/game/molecules/std-worldmap-board-2d.orb +6 -3
- package/behaviors/registry/ui/game/molecules/ui-canvas-2d.orb +16 -1
- package/behaviors/registry/ui/game/molecules/ui-canvas.orb +14 -0
- package/behaviors/registry/ui/game/molecules/ui-draw-shape-layer.orb +9 -1
- package/behaviors/registry/ui/game/molecules/ui-svg-draw-shape-layer.orb +188 -0
- package/behaviors/registry/ui/game/molecules/ui-svg-stage.orb +362 -0
- package/behaviors/registry/ui/game/organisms/ui-fishing-board.orb +16 -16
- package/behaviors/registry/ui/game/organisms/ui-physics-sandbox-board.orb +10 -10
- package/behaviors/registry/ui/game/organisms/ui-roguelike-board.orb +10 -10
- package/behaviors/registry/ui/game/organisms/ui-sokoban-board.orb +10 -10
- package/behaviors/registry/ui/game/organisms/ui-state-architect-board.orb +8 -8
- package/behaviors/registry/ui/game/organisms/ui-winter-ski-board.orb +14 -14
- package/dist/behaviors/behaviors-embeddings.json +371 -343
- package/dist/behaviors/behaviors-registry.json +4851 -2388
- package/dist/behaviors/exports-reader.js +3409 -3101
- package/dist/behaviors/functions/index.d.ts +609 -6
- package/dist/behaviors/functions/index.js +3389 -3102
- package/dist/behaviors/index.d.ts +1 -1
- package/dist/behaviors/index.js +3410 -3102
- package/dist/behaviors/knob-embeddings.json +1 -1
- package/dist/behaviors/query.js +3409 -3101
- package/dist/behaviors/registry/factory-signatures.json +6211 -2181
- package/dist/behaviors/registry/infra/atoms/std-approval-gate.orb +16 -8
- package/dist/behaviors/registry/infra/atoms/std-cache-aside.orb +62 -31
- package/dist/behaviors/registry/infra/atoms/std-circuit-breaker.orb +32 -16
- package/dist/behaviors/registry/infra/atoms/std-data-erasure.orb +17 -9
- package/dist/behaviors/registry/infra/atoms/std-mod-queue.orb +16 -8
- package/dist/behaviors/registry/infra/atoms/std-rate-limiter.orb +28 -14
- package/dist/behaviors/registry/ml/molecules/std-escalating-decision.orb +10 -5
- package/dist/behaviors/registry/ml/molecules/std-knowledge-tracing.orb +4 -2
- package/dist/behaviors/registry/ui/core/atoms/std-billable-hour.orb +2 -1
- package/dist/behaviors/registry/ui/core/atoms/std-browse.orb +108 -28
- package/dist/behaviors/registry/ui/core/atoms/std-dashboard-grid-embedded.orb +2 -1
- package/dist/behaviors/registry/ui/core/atoms/std-esign-flow.orb +4 -2
- package/dist/behaviors/registry/ui/core/atoms/std-esign-request.orb +6 -3
- package/dist/behaviors/registry/ui/core/atoms/std-gallery.orb +18 -9
- package/dist/behaviors/registry/ui/core/atoms/std-import.orb +4 -2
- package/dist/behaviors/registry/ui/core/molecules/ui-data-list.orb +21 -0
- package/dist/behaviors/registry/ui/core/molecules/ui-emoji-picker.orb +214 -0
- package/dist/behaviors/registry/ui/core/molecules/ui-popover.orb +112 -1
- package/dist/behaviors/registry/ui/core/molecules/ui-table-view.orb +44 -0
- package/dist/behaviors/registry/ui/game/atoms/std-arcade-flow.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-arcade-play.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-chase-ai.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-dungeon-combat.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-fx-particles.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-gather.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-gold.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-grid-tactics.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-hero-nav.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-market-flow.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-objective-flow.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-objective-reach.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-patience.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-production.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-round-flow.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-score.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-survival-flow.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/std-xp.orb +1 -0
- package/dist/behaviors/registry/ui/game/atoms/ui-draw-group.orb +196 -0
- package/dist/behaviors/registry/ui/game/atoms/ui-draw-shape.orb +9 -1
- package/dist/behaviors/registry/ui/game/atoms/ui-draw-sprite.orb +2 -2
- package/dist/behaviors/registry/ui/game/atoms/ui-svg-draw-group.orb +186 -0
- package/dist/behaviors/registry/ui/game/atoms/ui-svg-draw-shape.orb +259 -0
- package/dist/behaviors/registry/ui/game/atoms/ui-svg-draw-text.orb +195 -0
- package/dist/behaviors/registry/ui/game/molecules/std-worldmap-board-2d.orb +6 -3
- package/dist/behaviors/registry/ui/game/molecules/ui-canvas-2d.orb +16 -1
- package/dist/behaviors/registry/ui/game/molecules/ui-canvas.orb +14 -0
- package/dist/behaviors/registry/ui/game/molecules/ui-draw-shape-layer.orb +9 -1
- package/dist/behaviors/registry/ui/game/molecules/ui-svg-draw-shape-layer.orb +188 -0
- package/dist/behaviors/registry/ui/game/molecules/ui-svg-stage.orb +362 -0
- package/dist/behaviors/registry/ui/game/organisms/ui-fishing-board.orb +16 -16
- package/dist/behaviors/registry/ui/game/organisms/ui-physics-sandbox-board.orb +10 -10
- package/dist/behaviors/registry/ui/game/organisms/ui-roguelike-board.orb +10 -10
- package/dist/behaviors/registry/ui/game/organisms/ui-sokoban-board.orb +10 -10
- package/dist/behaviors/registry/ui/game/organisms/ui-state-architect-board.orb +8 -8
- package/dist/behaviors/registry/ui/game/organisms/ui-winter-ski-board.orb +14 -14
- package/dist/behaviors-embeddings.json +371 -343
- package/dist/behaviors-registry.json +4851 -2388
- package/dist/index.d.ts +1 -1
- package/dist/index.js +3410 -3102
- package/dist/knob-embeddings.json +1 -1
- package/dist/registry/factory-signatures.json +6211 -2181
- package/package.json +2 -2
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
app ui-svg-draw-shape-layer "1.0.0"
|
|
2
|
+
"SvgDrawShapeLayer — UI factory (1:1 with the @almadar/ui svg-draw-shape-layer pattern)."
|
|
3
|
+
orbital SvgDrawShapeLayerOrbital {
|
|
4
|
+
type SvgDrawShapeLayerItemsItem = {
|
|
5
|
+
id : string!
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
entity SvgDrawShapeLayerItem [runtime] {
|
|
9
|
+
id : string!
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
trait SvgDrawShapeLayerRender -> @rebindable SvgDrawShapeLayerItem [interaction, instance] {
|
|
13
|
+
initial: idle
|
|
14
|
+
|
|
15
|
+
state idle {
|
|
16
|
+
INIT -> idle
|
|
17
|
+
(render-ui main {
|
|
18
|
+
items: @config.items
|
|
19
|
+
fill: @config.fill
|
|
20
|
+
stroke: @config.stroke
|
|
21
|
+
strokeWidth: @config.strokeWidth
|
|
22
|
+
opacity: @config.opacity
|
|
23
|
+
type: svg-draw-shape-layer
|
|
24
|
+
})
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
config {
|
|
28
|
+
items : [SvgDrawShapeLayerItemsItem] = [{ id: "Id" }, { id: "Id 2" }]
|
|
29
|
+
@label "Items"
|
|
30
|
+
@description "items prop"
|
|
31
|
+
@tier "presentation"
|
|
32
|
+
fill : string
|
|
33
|
+
@label "Fill"
|
|
34
|
+
@description "Default fill for items that don't set one."
|
|
35
|
+
@tier "presentation"
|
|
36
|
+
stroke : string
|
|
37
|
+
@label "Stroke"
|
|
38
|
+
@description "Default stroke for items that don't set one."
|
|
39
|
+
@tier "presentation"
|
|
40
|
+
strokeWidth : number
|
|
41
|
+
@label "Stroke Width"
|
|
42
|
+
@description "Default strokeWidth for items that don't set one."
|
|
43
|
+
@tier "presentation"
|
|
44
|
+
opacity : number
|
|
45
|
+
@label "Opacity"
|
|
46
|
+
@description "Default 0..1 opacity for items that don't set one."
|
|
47
|
+
@tier "presentation"
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
page "/svg-draw-shape-layer" as SvgDrawShapeLayerPage -> SvgDrawShapeLayerRender
|
|
52
|
+
}
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
app ui-svg-stage "1.0.0"
|
|
2
|
+
"SvgStage — UI factory (1:1 with the @almadar/ui svg-stage pattern)."
|
|
3
|
+
orbital SvgStageOrbital {
|
|
4
|
+
entity SvgStageItem [runtime] {
|
|
5
|
+
id : string!
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
trait SvgStageRender -> @rebindable SvgStageItem [interaction, instance] {
|
|
9
|
+
initial: idle
|
|
10
|
+
|
|
11
|
+
state idle {
|
|
12
|
+
INIT -> idle
|
|
13
|
+
(render-ui main {
|
|
14
|
+
cols: @config.cols
|
|
15
|
+
rows: @config.rows
|
|
16
|
+
tileSize: @config.tileSize
|
|
17
|
+
background: @config.background
|
|
18
|
+
tileClickEvent: @config.tileClickEvent
|
|
19
|
+
tileHoverEvent: @config.tileHoverEvent
|
|
20
|
+
tileLeaveEvent: @config.tileLeaveEvent
|
|
21
|
+
keyMap: @config.keyMap
|
|
22
|
+
keyUpMap: @config.keyUpMap
|
|
23
|
+
className: @config.className
|
|
24
|
+
children: @config.children
|
|
25
|
+
type: svg-stage
|
|
26
|
+
})
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
emits {
|
|
30
|
+
@config.tileClickEvent -> external {
|
|
31
|
+
x : number!
|
|
32
|
+
y : number!
|
|
33
|
+
}
|
|
34
|
+
@description "Emitted as `UI:<event>` with `{ x, y }` cell coords on pointer up (<5px drag)."
|
|
35
|
+
@tier "essential"
|
|
36
|
+
@config.tileHoverEvent -> external {
|
|
37
|
+
x : number!
|
|
38
|
+
y : number!
|
|
39
|
+
}
|
|
40
|
+
@description "Emitted as `UI:<event>` with `{ x, y }` cell coords on pointer move."
|
|
41
|
+
@tier "essential"
|
|
42
|
+
@config.tileLeaveEvent -> external {
|
|
43
|
+
id : string
|
|
44
|
+
}
|
|
45
|
+
@description "Emitted as `UI:<event>` with `{}` when the pointer leaves the stage."
|
|
46
|
+
@tier "essential"
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
config {
|
|
50
|
+
cols : number = 1
|
|
51
|
+
@label "Cols"
|
|
52
|
+
@description "Grid width in cells."
|
|
53
|
+
@tier "presentation"
|
|
54
|
+
rows : number = 1
|
|
55
|
+
@label "Rows"
|
|
56
|
+
@description "Grid height in cells."
|
|
57
|
+
@tier "presentation"
|
|
58
|
+
tileSize : number = 32
|
|
59
|
+
@label "Tile Size"
|
|
60
|
+
@description "ViewBox units per cell (default 32); viewBox is `0 0 cols*tileSize rows*tileSize`."
|
|
61
|
+
@tier "presentation"
|
|
62
|
+
background : string = "var(--color-background)"
|
|
63
|
+
@label "Background"
|
|
64
|
+
@description "Background rect fill (default `var(--color-background)`)."
|
|
65
|
+
@tier "presentation"
|
|
66
|
+
tileClickEvent : string = "TILE_CLICK"
|
|
67
|
+
@label "Tile Click Event"
|
|
68
|
+
@description "Emitted as `UI:<event>` with `{ x, y }` cell coords on pointer up (<5px drag)."
|
|
69
|
+
@tier "presentation"
|
|
70
|
+
tileHoverEvent : string = "TILE_HOVER"
|
|
71
|
+
@label "Tile Hover Event"
|
|
72
|
+
@description "Emitted as `UI:<event>` with `{ x, y }` cell coords on pointer move."
|
|
73
|
+
@tier "presentation"
|
|
74
|
+
tileLeaveEvent : string = "TILE_LEAVE"
|
|
75
|
+
@label "Tile Leave Event"
|
|
76
|
+
@description "Emitted as `UI:<event>` with `{}` when the pointer leaves the stage."
|
|
77
|
+
@tier "presentation"
|
|
78
|
+
keyMap : Map string string = { item: "Item" }
|
|
79
|
+
@label "Key Map"
|
|
80
|
+
@description "Keyboard → semantic events: `e.code` → event name, emitted as `UI:<event>` with `{}`."
|
|
81
|
+
@tier "presentation"
|
|
82
|
+
keyUpMap : Map string string = { item: "Item" }
|
|
83
|
+
@label "Key Up Map"
|
|
84
|
+
@description "Keyup counterpart of `keyMap`."
|
|
85
|
+
@tier "presentation"
|
|
86
|
+
className : string
|
|
87
|
+
@label "Class Name"
|
|
88
|
+
@description "Additional CSS classes"
|
|
89
|
+
@tier "presentation"
|
|
90
|
+
children : node
|
|
91
|
+
@label "Children"
|
|
92
|
+
@description "children prop"
|
|
93
|
+
@tier "presentation"
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
page "/svg-stage" as SvgStagePage -> SvgStageRender
|
|
98
|
+
}
|
|
@@ -127,7 +127,7 @@ orbital FishingBoardOrbital {
|
|
|
127
127
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: CAST, label: "Cast", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cast", thumbnailUrl: "" }, variant: primary }, { type: button, action: REEL, label: "Reel", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-reel", thumbnailUrl: "" }, variant: primary } ] }
|
|
128
128
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, children: [
|
|
129
129
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
130
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
130
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
131
131
|
{ type: draw-sprite-layer, items: (array/map @config.features (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get @f sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
132
132
|
{ type: draw-sprite-layer, items: (array/map @entity.units (fn u { type: draw-sprite, position: (object/get @u position), asset: (object/get @u sprite), anchor: "ground", width: 0.5, height: 0.5 })) }
|
|
133
133
|
{ type: draw-shape-layer, items: (array/map @entity.units (fn u { type: draw-shape, shape: "rect", position: (object/get @u position), anchor: "ground", offsetX: -0.25, offsetY: -0.6, width: 0.5, height: 0.12, fill: "rgba(0,0,0,0.6)" })) }
|
|
@@ -149,7 +149,7 @@ orbital FishingBoardOrbital {
|
|
|
149
149
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: CAST, label: "Cast", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cast", thumbnailUrl: "" }, variant: primary }, { type: button, action: REEL, label: "Reel", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-reel", thumbnailUrl: "" }, variant: primary } ] }
|
|
150
150
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, children: [
|
|
151
151
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
152
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
152
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
153
153
|
{ type: draw-sprite-layer, items: (array/map @config.features (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get @f sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
154
154
|
{ type: draw-sprite-layer, items: (array/map @entity.units (fn u { type: draw-sprite, position: (object/get @u position), asset: (object/get @u sprite), anchor: "ground", width: 0.5, height: 0.5 })) }
|
|
155
155
|
{ type: draw-shape-layer, items: (array/map @entity.units (fn u { type: draw-shape, shape: "rect", position: (object/get @u position), anchor: "ground", offsetX: -0.25, offsetY: -0.6, width: 0.5, height: 0.12, fill: "rgba(0,0,0,0.6)" })) }
|
|
@@ -176,7 +176,7 @@ orbital FishingBoardOrbital {
|
|
|
176
176
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: CAST, label: "Cast", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cast", thumbnailUrl: "" }, variant: primary }, { type: button, action: REEL, label: "Reel", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-reel", thumbnailUrl: "" }, variant: primary } ] }
|
|
177
177
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, children: [
|
|
178
178
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
179
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
179
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
180
180
|
{ type: draw-sprite-layer, items: (array/map @config.features (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get @f sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
181
181
|
{ type: draw-sprite-layer, items: (array/map @entity.units (fn u { type: draw-sprite, position: (object/get @u position), asset: (object/get @u sprite), anchor: "ground", width: 0.5, height: 0.5 })) }
|
|
182
182
|
{ type: draw-shape-layer, items: (array/map @entity.units (fn u { type: draw-shape, shape: "rect", position: (object/get @u position), anchor: "ground", offsetX: -0.25, offsetY: -0.6, width: 0.5, height: 0.12, fill: "rgba(0,0,0,0.6)" })) }
|
|
@@ -196,7 +196,7 @@ orbital FishingBoardOrbital {
|
|
|
196
196
|
overlay: { type: game-menu, title: "VICTORY", subtitle: (str/concat "Full net! Score: " @entity.score), options: [ { id: "again", label: "Play Again", event: "PLAY_AGAIN", variant: "primary" } ] }
|
|
197
197
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, children: [
|
|
198
198
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
199
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
199
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
200
200
|
{ type: draw-sprite-layer, items: (array/map @config.features (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get @f sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
201
201
|
{ type: draw-sprite-layer, items: (array/map @entity.units (fn u { type: draw-sprite, position: (object/get @u position), asset: (object/get @u sprite), anchor: "ground", width: 0.5, height: 0.5 })) }
|
|
202
202
|
{ type: draw-shape-layer, items: (array/map @entity.units (fn u { type: draw-shape, shape: "rect", position: (object/get @u position), anchor: "ground", offsetX: -0.25, offsetY: -0.6, width: 0.5, height: 0.12, fill: "rgba(0,0,0,0.6)" })) }
|
|
@@ -224,7 +224,7 @@ orbital FishingBoardOrbital {
|
|
|
224
224
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: CAST, label: "Cast", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cast", thumbnailUrl: "" }, variant: primary }, { type: button, action: REEL, label: "Reel", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-reel", thumbnailUrl: "" }, variant: primary } ] }
|
|
225
225
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, children: [
|
|
226
226
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
227
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
227
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
228
228
|
{ type: draw-sprite-layer, items: (array/map @config.features (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get @f sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
229
229
|
{ type: draw-sprite-layer, items: (array/map @entity.units (fn u { type: draw-sprite, position: (object/get @u position), asset: (object/get @u sprite), anchor: "ground", width: 0.5, height: 0.5 })) }
|
|
230
230
|
{ type: draw-shape-layer, items: (array/map @entity.units (fn u { type: draw-shape, shape: "rect", position: (object/get @u position), anchor: "ground", offsetX: -0.25, offsetY: -0.6, width: 0.5, height: 0.12, fill: "rgba(0,0,0,0.6)" })) }
|
|
@@ -251,7 +251,7 @@ orbital FishingBoardOrbital {
|
|
|
251
251
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: CAST, label: "Cast", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cast", thumbnailUrl: "" }, variant: primary }, { type: button, action: REEL, label: "Reel", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-reel", thumbnailUrl: "" }, variant: primary } ] }
|
|
252
252
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, children: [
|
|
253
253
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
254
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
254
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
255
255
|
{ type: draw-sprite-layer, items: (array/map @config.features (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get @f sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
256
256
|
{ type: draw-sprite-layer, items: (array/map @entity.units (fn u { type: draw-sprite, position: (object/get @u position), asset: (object/get @u sprite), anchor: "ground", width: 0.5, height: 0.5 })) }
|
|
257
257
|
{ type: draw-shape-layer, items: (array/map @entity.units (fn u { type: draw-shape, shape: "rect", position: (object/get @u position), anchor: "ground", offsetX: -0.25, offsetY: -0.6, width: 0.5, height: 0.12, fill: "rgba(0,0,0,0.6)" })) }
|
|
@@ -275,7 +275,7 @@ orbital FishingBoardOrbital {
|
|
|
275
275
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: CAST, label: "Cast", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cast", thumbnailUrl: "" }, variant: primary }, { type: button, action: REEL, label: "Reel", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-reel", thumbnailUrl: "" }, variant: primary } ] }
|
|
276
276
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, children: [
|
|
277
277
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
278
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
278
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
279
279
|
{ type: draw-sprite-layer, items: (array/map @config.features (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get @f sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
280
280
|
{ type: draw-sprite-layer, items: (array/map @entity.units (fn u { type: draw-sprite, position: (object/get @u position), asset: (object/get @u sprite), anchor: "ground", width: 0.5, height: 0.5 })) }
|
|
281
281
|
{ type: draw-shape-layer, items: (array/map @entity.units (fn u { type: draw-shape, shape: "rect", position: (object/get @u position), anchor: "ground", offsetX: -0.25, offsetY: -0.6, width: 0.5, height: 0.12, fill: "rgba(0,0,0,0.6)" })) }
|
|
@@ -295,7 +295,7 @@ orbital FishingBoardOrbital {
|
|
|
295
295
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: CAST, label: "Cast", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cast", thumbnailUrl: "" }, variant: primary }, { type: button, action: REEL, label: "Reel", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector", variant: "", dimension: "2d", aspect: "1:1", name: "icon-reel", thumbnailUrl: "" }, variant: primary } ] }
|
|
296
296
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, children: [
|
|
297
297
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
298
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
298
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
299
299
|
{ type: draw-sprite-layer, items: (array/map @config.features (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get @f sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
300
300
|
{ type: draw-sprite-layer, items: (array/map @entity.units (fn u { type: draw-sprite, position: (object/get @u position), asset: (object/get @u sprite), anchor: "ground", width: 0.5, height: 0.5 })) }
|
|
301
301
|
{ type: draw-shape-layer, items: (array/map @entity.units (fn u { type: draw-shape, shape: "rect", position: (object/get @u position), anchor: "ground", offsetX: -0.25, offsetY: -0.6, width: 0.5, height: 0.12, fill: "rgba(0,0,0,0.6)" })) }
|
|
@@ -79,7 +79,7 @@ orbital PhysicsSandboxBoardOrbital {
|
|
|
79
79
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: SPAWN, label: "Spawn", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-spawn", thumbnailUrl: "" }, variant: primary }, { type: button, action: CYCLE_KIND, label: "Cycle Kind", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cycle-kind", thumbnailUrl: "" }, variant: secondary }, { type: button, action: CLEAR, label: "Clear", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "zoom_reset.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-clear", thumbnailUrl: "" }, variant: secondary } ] }
|
|
80
80
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, keyMap: { Space: "SPAWN" }, children: [
|
|
81
81
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
82
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
82
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
83
83
|
{ type: draw-sprite-layer, items: (array/map @entity.blocks (fn b { type: draw-sprite, position: { x: (object/get @b x), y: (object/get @b y) }, asset: (object/get @b sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
84
84
|
] } ]
|
|
85
85
|
})
|
|
@@ -97,7 +97,7 @@ orbital PhysicsSandboxBoardOrbital {
|
|
|
97
97
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: SPAWN, label: "Spawn", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-spawn", thumbnailUrl: "" }, variant: primary }, { type: button, action: CYCLE_KIND, label: "Cycle Kind", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cycle-kind", thumbnailUrl: "" }, variant: secondary }, { type: button, action: CLEAR, label: "Clear", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "zoom_reset.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-clear", thumbnailUrl: "" }, variant: secondary } ] }
|
|
98
98
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, keyMap: { Space: "SPAWN" }, children: [
|
|
99
99
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
100
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
100
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
101
101
|
{ type: draw-sprite-layer, items: (array/map @entity.blocks (fn b { type: draw-sprite, position: { x: (object/get @b x), y: (object/get @b y) }, asset: (object/get @b sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
102
102
|
] } ]
|
|
103
103
|
})
|
|
@@ -113,7 +113,7 @@ orbital PhysicsSandboxBoardOrbital {
|
|
|
113
113
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: SPAWN, label: "Spawn", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-spawn", thumbnailUrl: "" }, variant: primary }, { type: button, action: CYCLE_KIND, label: "Cycle Kind", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cycle-kind", thumbnailUrl: "" }, variant: secondary }, { type: button, action: CLEAR, label: "Clear", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "zoom_reset.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-clear", thumbnailUrl: "" }, variant: secondary } ] }
|
|
114
114
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, keyMap: { Space: "SPAWN" }, children: [
|
|
115
115
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
116
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
116
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
117
117
|
{ type: draw-sprite-layer, items: (array/map @entity.blocks (fn b { type: draw-sprite, position: { x: (object/get @b x), y: (object/get @b y) }, asset: (object/get @b sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
118
118
|
] } ]
|
|
119
119
|
})
|
|
@@ -133,7 +133,7 @@ orbital PhysicsSandboxBoardOrbital {
|
|
|
133
133
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: SPAWN, label: "Spawn", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-spawn", thumbnailUrl: "" }, variant: primary }, { type: button, action: CYCLE_KIND, label: "Cycle Kind", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cycle-kind", thumbnailUrl: "" }, variant: secondary }, { type: button, action: CLEAR, label: "Clear", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "zoom_reset.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-clear", thumbnailUrl: "" }, variant: secondary } ] }
|
|
134
134
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, keyMap: { Space: "SPAWN" }, children: [
|
|
135
135
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
136
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
136
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
137
137
|
{ type: draw-sprite-layer, items: (array/map @entity.blocks (fn b { type: draw-sprite, position: { x: (object/get @b x), y: (object/get @b y) }, asset: (object/get @b sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
138
138
|
] } ]
|
|
139
139
|
})
|
|
@@ -156,7 +156,7 @@ orbital PhysicsSandboxBoardOrbital {
|
|
|
156
156
|
addons: { type: stack, direction: vertical, gap: sm, children: [ { type: button, action: SPAWN, label: "Spawn", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-emote-pack/ui/vector_style1.json", sprite: "emote_drop.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-spawn", thumbnailUrl: "" }, variant: primary }, { type: button, action: CYCLE_KIND, label: "Cycle Kind", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "rotate_cw.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-cycle-kind", thumbnailUrl: "" }, variant: secondary }, { type: button, action: CLEAR, label: "Clear", iconAsset: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-cursor-pack/ui/kenney-cursor-pack.generated.json", sprite: "zoom_reset.png", role: "ui", category: "ui", animations: ["static"], style: "vector-flat", variant: "", dimension: "2d", aspect: "1:1", name: "icon-clear", thumbnailUrl: "" }, variant: secondary } ] }
|
|
157
157
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, keyMap: { Space: "SPAWN" }, children: [
|
|
158
158
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
159
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
159
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
160
160
|
{ type: draw-sprite-layer, items: (array/map @entity.blocks (fn b { type: draw-sprite, position: { x: (object/get @b x), y: (object/get @b y) }, asset: (object/get @b sprite), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
161
161
|
] } ]
|
|
162
162
|
})
|
|
@@ -127,7 +127,7 @@ orbital RoguelikeBoardOrbital {
|
|
|
127
127
|
controls: { type: control-grid, kind: "dpad", directionEvents: { up: "MOVE_UP", down: "MOVE_DOWN", left: "MOVE_LEFT", right: "MOVE_RIGHT" }, directionAssets: { up: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "30,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-up", thumbnailUrl: "" }, down: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "32,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-down", thumbnailUrl: "" }, left: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "33,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-left", thumbnailUrl: "" }, right: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "31,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-right", thumbnailUrl: "" } } }
|
|
128
128
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @entity.tiles "x") (array/max @entity.tiles "y"))))), pos: { x: (/ (+ (array/min @entity.tiles "x") (array/max @entity.tiles "x")) 2), y: (/ (+ (array/min @entity.tiles "y") (array/max @entity.tiles "y")) 2) } }, projection: "flat", showMinimap: true, tileClickEvent: TILE_CLICK, unitClickEvent: UNIT_CLICK, keyMap: { ArrowUp: "MOVE_UP", KeyW: "MOVE_UP", ArrowDown: "MOVE_DOWN", KeyS: "MOVE_DOWN", ArrowLeft: "MOVE_LEFT", KeyA: "MOVE_LEFT", ArrowRight: "MOVE_RIGHT", KeyD: "MOVE_RIGHT" }, children: [
|
|
129
129
|
{ type: draw-shape-layer, items: (array/map @entity.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
130
|
-
{ type: draw-sprite-layer, items: (array/map @entity.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
130
|
+
{ type: draw-sprite-layer, items: (array/map @entity.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
131
131
|
{ type: draw-sprite-layer, items: (array/map @entity.items (fn i { type: draw-sprite, position: { x: (object/get @i x), y: (object/get @i y) }, asset: (if (== (object/get @i kind) "health_potion") (object/get (object/get @config.assetManifest features) health_potion) (if (== (object/get @i kind) "sword") (object/get (object/get @config.assetManifest features) sword) (object/get (object/get @config.assetManifest features) shield))), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
132
132
|
{ type: draw-shape-layer, items: (array/map @entity.validMoves (fn m { type: draw-shape, shape: "cell", position: { x: (object/get @m x), y: (object/get @m y) }, fill: "rgba(74,222,128,0.4)" })) }
|
|
133
133
|
{ type: draw-shape-layer, items: (array/map (array/filter (array/append (array/map @entity.enemies (fn e { id: @e.id, x: @e.x, y: @e.y })) { id: "player", x: (object/get @entity.player x), y: (object/get @entity.player y) }) (fn u (== (object/get @u id) @entity.selectedUnitId))) (fn u { type: draw-shape, shape: "ellipse", position: { x: (object/get @u x), y: (object/get @u y) }, radiusX: 0.5, radiusY: 0.2, stroke: "rgba(0,200,255,0.8)", strokeWidth: 3 })) }
|
|
@@ -359,7 +359,7 @@ orbital RoguelikeBoardOrbital {
|
|
|
359
359
|
controls: { type: control-grid, kind: "dpad", directionEvents: { up: "MOVE_UP", down: "MOVE_DOWN", left: "MOVE_LEFT", right: "MOVE_RIGHT" }, directionAssets: { up: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "30,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-up", thumbnailUrl: "" }, down: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "32,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-down", thumbnailUrl: "" }, left: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "33,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-left", thumbnailUrl: "" }, right: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "31,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-right", thumbnailUrl: "" } } }
|
|
360
360
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @entity.tiles "x") (array/max @entity.tiles "y"))))), pos: { x: (/ (+ (array/min @entity.tiles "x") (array/max @entity.tiles "x")) 2), y: (/ (+ (array/min @entity.tiles "y") (array/max @entity.tiles "y")) 2) } }, projection: "flat", showMinimap: true, tileClickEvent: TILE_CLICK, unitClickEvent: UNIT_CLICK, keyMap: { ArrowUp: "MOVE_UP", KeyW: "MOVE_UP", ArrowDown: "MOVE_DOWN", KeyS: "MOVE_DOWN", ArrowLeft: "MOVE_LEFT", KeyA: "MOVE_LEFT", ArrowRight: "MOVE_RIGHT", KeyD: "MOVE_RIGHT" }, children: [
|
|
361
361
|
{ type: draw-shape-layer, items: (array/map @entity.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
362
|
-
{ type: draw-sprite-layer, items: (array/map @entity.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
362
|
+
{ type: draw-sprite-layer, items: (array/map @entity.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
363
363
|
{ type: draw-sprite-layer, items: (array/map @entity.items (fn i { type: draw-sprite, position: { x: (object/get @i x), y: (object/get @i y) }, asset: (if (== (object/get @i kind) "health_potion") (object/get (object/get @config.assetManifest features) health_potion) (if (== (object/get @i kind) "sword") (object/get (object/get @config.assetManifest features) sword) (object/get (object/get @config.assetManifest features) shield))), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
364
364
|
{ type: draw-shape-layer, items: (array/map @entity.validMoves (fn m { type: draw-shape, shape: "cell", position: { x: (object/get @m x), y: (object/get @m y) }, fill: "rgba(74,222,128,0.4)" })) }
|
|
365
365
|
{ type: draw-shape-layer, items: (array/map (array/filter (array/append (array/map @entity.enemies (fn e { id: @e.id, x: @e.x, y: @e.y })) { id: "player", x: (object/get @entity.player x), y: (object/get @entity.player y) }) (fn u (== (object/get @u id) @entity.selectedUnitId))) (fn u { type: draw-shape, shape: "ellipse", position: { x: (object/get @u x), y: (object/get @u y) }, radiusX: 0.5, radiusY: 0.2, stroke: "rgba(0,200,255,0.8)", strokeWidth: 3 })) }
|
|
@@ -381,7 +381,7 @@ orbital RoguelikeBoardOrbital {
|
|
|
381
381
|
overlay: { type: game-menu, title: (if (== @entity.result "won") "VICTORY" "DEFEAT"), subtitle: (if (== @entity.result "won") "Depth 5 conquered" "The dungeon claims another hero"), options: [ { id: "again", label: "Play Again", event: "PLAY_AGAIN", variant: "primary" } ] }
|
|
382
382
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @entity.tiles "x") (array/max @entity.tiles "y"))))), pos: { x: (/ (+ (array/min @entity.tiles "x") (array/max @entity.tiles "x")) 2), y: (/ (+ (array/min @entity.tiles "y") (array/max @entity.tiles "y")) 2) } }, projection: "flat", showMinimap: true, tileClickEvent: TILE_CLICK, unitClickEvent: UNIT_CLICK, keyMap: { ArrowUp: "MOVE_UP", KeyW: "MOVE_UP", ArrowDown: "MOVE_DOWN", KeyS: "MOVE_DOWN", ArrowLeft: "MOVE_LEFT", KeyA: "MOVE_LEFT", ArrowRight: "MOVE_RIGHT", KeyD: "MOVE_RIGHT" }, children: [
|
|
383
383
|
{ type: draw-shape-layer, items: (array/map @entity.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
384
|
-
{ type: draw-sprite-layer, items: (array/map @entity.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
384
|
+
{ type: draw-sprite-layer, items: (array/map @entity.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
385
385
|
{ type: draw-sprite-layer, items: (array/map @entity.items (fn i { type: draw-sprite, position: { x: (object/get @i x), y: (object/get @i y) }, asset: (if (== (object/get @i kind) "health_potion") (object/get (object/get @config.assetManifest features) health_potion) (if (== (object/get @i kind) "sword") (object/get (object/get @config.assetManifest features) sword) (object/get (object/get @config.assetManifest features) shield))), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
386
386
|
{ type: draw-shape-layer, items: (array/map @entity.validMoves (fn m { type: draw-shape, shape: "cell", position: { x: (object/get @m x), y: (object/get @m y) }, fill: "rgba(74,222,128,0.4)" })) }
|
|
387
387
|
{ type: draw-shape-layer, items: (array/map (array/filter (array/append (array/map @entity.enemies (fn e { id: @e.id, x: @e.x, y: @e.y })) { id: "player", x: (object/get @entity.player x), y: (object/get @entity.player y) }) (fn u (== (object/get @u id) @entity.selectedUnitId))) (fn u { type: draw-shape, shape: "ellipse", position: { x: (object/get @u x), y: (object/get @u y) }, radiusX: 0.5, radiusY: 0.2, stroke: "rgba(0,200,255,0.8)", strokeWidth: 3 })) }
|
|
@@ -427,7 +427,7 @@ orbital RoguelikeBoardOrbital {
|
|
|
427
427
|
controls: { type: control-grid, kind: "dpad", directionEvents: { up: "MOVE_UP", down: "MOVE_DOWN", left: "MOVE_LEFT", right: "MOVE_RIGHT" }, directionAssets: { up: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "30,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-up", thumbnailUrl: "" }, down: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "32,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-down", thumbnailUrl: "" }, left: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "33,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-left", thumbnailUrl: "" }, right: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "31,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-right", thumbnailUrl: "" } } }
|
|
428
428
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @entity.tiles "x") (array/max @entity.tiles "y"))))), pos: { x: (/ (+ (array/min @entity.tiles "x") (array/max @entity.tiles "x")) 2), y: (/ (+ (array/min @entity.tiles "y") (array/max @entity.tiles "y")) 2) } }, projection: "flat", showMinimap: true, tileClickEvent: TILE_CLICK, unitClickEvent: UNIT_CLICK, keyMap: { ArrowUp: "MOVE_UP", KeyW: "MOVE_UP", ArrowDown: "MOVE_DOWN", KeyS: "MOVE_DOWN", ArrowLeft: "MOVE_LEFT", KeyA: "MOVE_LEFT", ArrowRight: "MOVE_RIGHT", KeyD: "MOVE_RIGHT" }, children: [
|
|
429
429
|
{ type: draw-shape-layer, items: (array/map @entity.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
430
|
-
{ type: draw-sprite-layer, items: (array/map @entity.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
430
|
+
{ type: draw-sprite-layer, items: (array/map @entity.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
431
431
|
{ type: draw-sprite-layer, items: (array/map @entity.items (fn i { type: draw-sprite, position: { x: (object/get @i x), y: (object/get @i y) }, asset: (if (== (object/get @i kind) "health_potion") (object/get (object/get @config.assetManifest features) health_potion) (if (== (object/get @i kind) "sword") (object/get (object/get @config.assetManifest features) sword) (object/get (object/get @config.assetManifest features) shield))), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
432
432
|
{ type: draw-shape-layer, items: (array/map @entity.validMoves (fn m { type: draw-shape, shape: "cell", position: { x: (object/get @m x), y: (object/get @m y) }, fill: "rgba(74,222,128,0.4)" })) }
|
|
433
433
|
{ type: draw-shape-layer, items: (array/map (array/filter (array/append (array/map @entity.enemies (fn e { id: @e.id, x: @e.x, y: @e.y })) { id: "player", x: (object/get @entity.player x), y: (object/get @entity.player y) }) (fn u (== (object/get @u id) @entity.selectedUnitId))) (fn u { type: draw-shape, shape: "ellipse", position: { x: (object/get @u x), y: (object/get @u y) }, radiusX: 0.5, radiusY: 0.2, stroke: "rgba(0,200,255,0.8)", strokeWidth: 3 })) }
|
|
@@ -452,7 +452,7 @@ orbital RoguelikeBoardOrbital {
|
|
|
452
452
|
controls: { type: control-grid, kind: "dpad", directionEvents: { up: "MOVE_UP", down: "MOVE_DOWN", left: "MOVE_LEFT", right: "MOVE_RIGHT" }, directionAssets: { up: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "30,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-up", thumbnailUrl: "" }, down: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "32,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-down", thumbnailUrl: "" }, left: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "33,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-left", thumbnailUrl: "" }, right: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "31,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-right", thumbnailUrl: "" } } }
|
|
453
453
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @entity.tiles "x") (array/max @entity.tiles "y"))))), pos: { x: (/ (+ (array/min @entity.tiles "x") (array/max @entity.tiles "x")) 2), y: (/ (+ (array/min @entity.tiles "y") (array/max @entity.tiles "y")) 2) } }, projection: "flat", showMinimap: true, tileClickEvent: TILE_CLICK, unitClickEvent: UNIT_CLICK, keyMap: { ArrowUp: "MOVE_UP", KeyW: "MOVE_UP", ArrowDown: "MOVE_DOWN", KeyS: "MOVE_DOWN", ArrowLeft: "MOVE_LEFT", KeyA: "MOVE_LEFT", ArrowRight: "MOVE_RIGHT", KeyD: "MOVE_RIGHT" }, children: [
|
|
454
454
|
{ type: draw-shape-layer, items: (array/map @entity.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
455
|
-
{ type: draw-sprite-layer, items: (array/map @entity.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
455
|
+
{ type: draw-sprite-layer, items: (array/map @entity.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
456
456
|
{ type: draw-sprite-layer, items: (array/map @entity.items (fn i { type: draw-sprite, position: { x: (object/get @i x), y: (object/get @i y) }, asset: (if (== (object/get @i kind) "health_potion") (object/get (object/get @config.assetManifest features) health_potion) (if (== (object/get @i kind) "sword") (object/get (object/get @config.assetManifest features) sword) (object/get (object/get @config.assetManifest features) shield))), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
457
457
|
{ type: draw-shape-layer, items: (array/map @entity.validMoves (fn m { type: draw-shape, shape: "cell", position: { x: (object/get @m x), y: (object/get @m y) }, fill: "rgba(74,222,128,0.4)" })) }
|
|
458
458
|
{ type: draw-shape-layer, items: (array/map (array/filter (array/append (array/map @entity.enemies (fn e { id: @e.id, x: @e.x, y: @e.y })) { id: "player", x: (object/get @entity.player x), y: (object/get @entity.player y) }) (fn u (== (object/get @u id) @entity.selectedUnitId))) (fn u { type: draw-shape, shape: "ellipse", position: { x: (object/get @u x), y: (object/get @u y) }, radiusX: 0.5, radiusY: 0.2, stroke: "rgba(0,200,255,0.8)", strokeWidth: 3 })) }
|
|
@@ -83,7 +83,7 @@ orbital SokobanBoardOrbital {
|
|
|
83
83
|
controls: { type: control-grid, kind: "dpad", directionEvents: { up: "MOVE_UP", down: "MOVE_DOWN", left: "MOVE_LEFT", right: "MOVE_RIGHT" }, directionAssets: { up: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "30,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-up", thumbnailUrl: "" }, down: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "32,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-down", thumbnailUrl: "" }, left: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "33,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-left", thumbnailUrl: "" }, right: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "31,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-right", thumbnailUrl: "" } } }
|
|
84
84
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, keyMap: { ArrowUp: "MOVE_UP", KeyW: "MOVE_UP", ArrowDown: "MOVE_DOWN", KeyS: "MOVE_DOWN", ArrowLeft: "MOVE_LEFT", KeyA: "MOVE_LEFT", ArrowRight: "MOVE_RIGHT", KeyD: "MOVE_RIGHT" }, children: [
|
|
85
85
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
86
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
86
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
87
87
|
{ type: draw-sprite-layer, items: (array/map @entity.crates (fn c { type: draw-sprite, position: { x: (object/get @c x), y: (object/get @c y) }, asset: (if (!= (array/find @config.targets (fn t (and (== (object/get @t x) (object/get @c x)) (== (object/get @t y) (object/get @c y))))) null) (object/get (object/get @config.assetManifest features) crate_done) (object/get (object/get @config.assetManifest features) crate)), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
88
88
|
{ type: draw-sprite-layer, items: [ { type: draw-sprite, position: { x: (object/get @entity.player x), y: (object/get @entity.player y) }, asset: (object/get (object/get @config.assetManifest units) pusher), anchor: "ground", width: 0.5, height: 0.5 } ] }
|
|
89
89
|
{ type: draw-sprite-layer, items: (array/map @entity.effects (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get (object/get @config.assetManifest effects) (object/get @f key)) })) }
|
|
@@ -190,7 +190,7 @@ orbital SokobanBoardOrbital {
|
|
|
190
190
|
controls: { type: control-grid, kind: "dpad", directionEvents: { up: "MOVE_UP", down: "MOVE_DOWN", left: "MOVE_LEFT", right: "MOVE_RIGHT" }, directionAssets: { up: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "30,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-up", thumbnailUrl: "" }, down: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "32,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-down", thumbnailUrl: "" }, left: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "33,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-left", thumbnailUrl: "" }, right: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "31,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-right", thumbnailUrl: "" } } }
|
|
191
191
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, keyMap: { ArrowUp: "MOVE_UP", KeyW: "MOVE_UP", ArrowDown: "MOVE_DOWN", KeyS: "MOVE_DOWN", ArrowLeft: "MOVE_LEFT", KeyA: "MOVE_LEFT", ArrowRight: "MOVE_RIGHT", KeyD: "MOVE_RIGHT" }, children: [
|
|
192
192
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
193
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
193
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
194
194
|
{ type: draw-sprite-layer, items: (array/map @entity.crates (fn c { type: draw-sprite, position: { x: (object/get @c x), y: (object/get @c y) }, asset: (if (!= (array/find @config.targets (fn t (and (== (object/get @t x) (object/get @c x)) (== (object/get @t y) (object/get @c y))))) null) (object/get (object/get @config.assetManifest features) crate_done) (object/get (object/get @config.assetManifest features) crate)), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
195
195
|
{ type: draw-sprite-layer, items: [ { type: draw-sprite, position: { x: (object/get @entity.player x), y: (object/get @entity.player y) }, asset: (object/get (object/get @config.assetManifest units) pusher), anchor: "ground", width: 0.5, height: 0.5 } ] }
|
|
196
196
|
{ type: draw-sprite-layer, items: (array/map @entity.effects (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get (object/get @config.assetManifest effects) (object/get @f key)) })) }
|
|
@@ -208,7 +208,7 @@ orbital SokobanBoardOrbital {
|
|
|
208
208
|
overlay: { type: game-menu, title: "SOLVED!", subtitle: (str/concat "All crates home in " (str/concat @entity.moves " moves")), options: [ { id: "again", label: "Play Again", event: "PLAY_AGAIN", variant: "primary" } ] }
|
|
209
209
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, keyMap: { ArrowUp: "MOVE_UP", KeyW: "MOVE_UP", ArrowDown: "MOVE_DOWN", KeyS: "MOVE_DOWN", ArrowLeft: "MOVE_LEFT", KeyA: "MOVE_LEFT", ArrowRight: "MOVE_RIGHT", KeyD: "MOVE_RIGHT" }, children: [
|
|
210
210
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
211
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
211
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
212
212
|
{ type: draw-sprite-layer, items: (array/map @entity.crates (fn c { type: draw-sprite, position: { x: (object/get @c x), y: (object/get @c y) }, asset: (if (!= (array/find @config.targets (fn t (and (== (object/get @t x) (object/get @c x)) (== (object/get @t y) (object/get @c y))))) null) (object/get (object/get @config.assetManifest features) crate_done) (object/get (object/get @config.assetManifest features) crate)), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
213
213
|
{ type: draw-sprite-layer, items: [ { type: draw-sprite, position: { x: (object/get @entity.player x), y: (object/get @entity.player y) }, asset: (object/get (object/get @config.assetManifest units) pusher), anchor: "ground", width: 0.5, height: 0.5 } ] }
|
|
214
214
|
{ type: draw-sprite-layer, items: (array/map @entity.effects (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get (object/get @config.assetManifest effects) (object/get @f key)) })) }
|
|
@@ -233,7 +233,7 @@ orbital SokobanBoardOrbital {
|
|
|
233
233
|
controls: { type: control-grid, kind: "dpad", directionEvents: { up: "MOVE_UP", down: "MOVE_DOWN", left: "MOVE_LEFT", right: "MOVE_RIGHT" }, directionAssets: { up: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "30,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-up", thumbnailUrl: "" }, down: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "32,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-down", thumbnailUrl: "" }, left: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "33,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-left", thumbnailUrl: "" }, right: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "31,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-right", thumbnailUrl: "" } } }
|
|
234
234
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, keyMap: { ArrowUp: "MOVE_UP", KeyW: "MOVE_UP", ArrowDown: "MOVE_DOWN", KeyS: "MOVE_DOWN", ArrowLeft: "MOVE_LEFT", KeyA: "MOVE_LEFT", ArrowRight: "MOVE_RIGHT", KeyD: "MOVE_RIGHT" }, children: [
|
|
235
235
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
236
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
236
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
237
237
|
{ type: draw-sprite-layer, items: (array/map @entity.crates (fn c { type: draw-sprite, position: { x: (object/get @c x), y: (object/get @c y) }, asset: (if (!= (array/find @config.targets (fn t (and (== (object/get @t x) (object/get @c x)) (== (object/get @t y) (object/get @c y))))) null) (object/get (object/get @config.assetManifest features) crate_done) (object/get (object/get @config.assetManifest features) crate)), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
238
238
|
{ type: draw-sprite-layer, items: [ { type: draw-sprite, position: { x: (object/get @entity.player x), y: (object/get @entity.player y) }, asset: (object/get (object/get @config.assetManifest units) pusher), anchor: "ground", width: 0.5, height: 0.5 } ] }
|
|
239
239
|
{ type: draw-sprite-layer, items: (array/map @entity.effects (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get (object/get @config.assetManifest effects) (object/get @f key)) })) }
|
|
@@ -253,7 +253,7 @@ orbital SokobanBoardOrbital {
|
|
|
253
253
|
controls: { type: control-grid, kind: "dpad", directionEvents: { up: "MOVE_UP", down: "MOVE_DOWN", left: "MOVE_LEFT", right: "MOVE_RIGHT" }, directionAssets: { up: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "30,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-up", thumbnailUrl: "" }, down: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "32,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-down", thumbnailUrl: "" }, left: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "33,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-left", thumbnailUrl: "" }, right: { url: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/tilemap_packed.png", atlas: "https://almadar-kflow-assets.web.app/shared/_shared/kenney-input-prompts-pixel-16/terrain/Tilemap_tilemap_packed.tiles.json", sprite: "31,4", role: "ui", category: "ui", animations: [], style: "pixel", variant: "", dimension: "2d", aspect: "1:1", name: "key-right", thumbnailUrl: "" } } }
|
|
254
254
|
children: [ { type: canvas, camera: { zoom: (math/min 1 (/ 5 (+ 1 (math/max (array/max @config.tiles "x") (array/max @config.tiles "y"))))), pos: { x: (/ (+ (array/min @config.tiles "x") (array/max @config.tiles "x")) 2), y: (/ (+ (array/min @config.tiles "y") (array/max @config.tiles "y")) 2) } }, projection: "flat", showMinimap: false, keyMap: { ArrowUp: "MOVE_UP", KeyW: "MOVE_UP", ArrowDown: "MOVE_DOWN", KeyS: "MOVE_DOWN", ArrowLeft: "MOVE_LEFT", KeyA: "MOVE_LEFT", ArrowRight: "MOVE_RIGHT", KeyD: "MOVE_RIGHT" }, children: [
|
|
255
255
|
{ type: draw-shape-layer, items: (array/map @config.tiles (fn t { type: draw-shape, shape: "cell", position: { x: (object/get @t x), y: (object/get @t y) }, fill: "#5c94fc", stroke: "rgba(255,255,255,0.35)", strokeWidth: 1 })) }
|
|
256
|
-
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width:
|
|
256
|
+
{ type: draw-sprite-layer, items: (array/map @config.tiles (fn t { type: draw-sprite, position: { x: (object/get @t x), y: (object/get @t y) }, asset: (object/get @t terrainSprite), anchor: "center", width: 1, height: 1 })) }
|
|
257
257
|
{ type: draw-sprite-layer, items: (array/map @entity.crates (fn c { type: draw-sprite, position: { x: (object/get @c x), y: (object/get @c y) }, asset: (if (!= (array/find @config.targets (fn t (and (== (object/get @t x) (object/get @c x)) (== (object/get @t y) (object/get @c y))))) null) (object/get (object/get @config.assetManifest features) crate_done) (object/get (object/get @config.assetManifest features) crate)), anchor: "center", width: 0.5, height: 0.5 })) }
|
|
258
258
|
{ type: draw-sprite-layer, items: [ { type: draw-sprite, position: { x: (object/get @entity.player x), y: (object/get @entity.player y) }, asset: (object/get (object/get @config.assetManifest units) pusher), anchor: "ground", width: 0.5, height: 0.5 } ] }
|
|
259
259
|
{ type: draw-sprite-layer, items: (array/map @entity.effects (fn f { type: draw-sprite, position: { x: (object/get @f x), y: (object/get @f y) }, asset: (object/get (object/get @config.assetManifest effects) (object/get @f key)) })) }
|
|
@@ -195,9 +195,9 @@ orbital StateArchitectBoardOrbital {
|
|
|
195
195
|
]
|
|
196
196
|
})
|
|
197
197
|
|
|
198
|
-
RUN_TESTS -> complete when (and (> (array/len @entity.transitions) 0) (== @entity.totalTests (array/len (array/filter @entity.testCases (fn tc (== (array/reduce @tc.events (fn st e (object/get (array/find @entity.transitions (fn t (and (== @t.from @st) (== @t.event @e)))) "to" @st))
|
|
198
|
+
RUN_TESTS -> complete when (and (> (array/len @entity.transitions) 0) (== @entity.totalTests (array/len (array/filter @entity.testCases (fn tc (== (array/reduce @tc.events @entity.initialState (fn st e (object/get (array/find @entity.transitions (fn t (and (== @t.from @st) (== @t.event @e)))) "to" @st))) @tc.expectedState))))))
|
|
199
199
|
(set @entity.attempts (+ @entity.attempts 1))
|
|
200
|
-
(set @entity.passedTests (array/len (array/filter @entity.testCases (fn tc (== (array/reduce @tc.events (fn st e (object/get (array/find @entity.transitions (fn t (and (== @t.from @st) (== @t.event @e)))) "to" @st))
|
|
200
|
+
(set @entity.passedTests (array/len (array/filter @entity.testCases (fn tc (== (array/reduce @tc.events @entity.initialState (fn st e (object/get (array/find @entity.transitions (fn t (and (== @t.from @st) (== @t.event @e)))) "to" @st))) @tc.expectedState)))))
|
|
201
201
|
(set @entity.result "win")
|
|
202
202
|
(render-ui main {
|
|
203
203
|
type: game-shell
|
|
@@ -211,9 +211,9 @@ orbital StateArchitectBoardOrbital {
|
|
|
211
211
|
]
|
|
212
212
|
})
|
|
213
213
|
|
|
214
|
-
RUN_TESTS -> playing when (or (== (array/len @entity.transitions) 0) (!= @entity.totalTests (array/len (array/filter @entity.testCases (fn tc (== (array/reduce @tc.events (fn st e (object/get (array/find @entity.transitions (fn t (and (== @t.from @st) (== @t.event @e)))) "to" @st))
|
|
214
|
+
RUN_TESTS -> playing when (or (== (array/len @entity.transitions) 0) (!= @entity.totalTests (array/len (array/filter @entity.testCases (fn tc (== (array/reduce @tc.events @entity.initialState (fn st e (object/get (array/find @entity.transitions (fn t (and (== @t.from @st) (== @t.event @e)))) "to" @st))) @tc.expectedState))))))
|
|
215
215
|
(set @entity.attempts (+ @entity.attempts 1))
|
|
216
|
-
(set @entity.passedTests (array/len (array/filter @entity.testCases (fn tc (== (array/reduce @tc.events (fn st e (object/get (array/find @entity.transitions (fn t (and (== @t.from @st) (== @t.event @e)))) "to" @st))
|
|
216
|
+
(set @entity.passedTests (array/len (array/filter @entity.testCases (fn tc (== (array/reduce @tc.events @entity.initialState (fn st e (object/get (array/find @entity.transitions (fn t (and (== @t.from @st) (== @t.event @e)))) "to" @st))) @tc.expectedState)))))
|
|
217
217
|
(render-ui main {
|
|
218
218
|
type: game-shell
|
|
219
219
|
hud: { type: stack, direction: horizontal, gap: md, justify: between, children: [ { type: game-hud, stats: [ { label: "Passed", value: @entity.passedTests }, { label: "Total", value: @entity.totalTests }, { label: "Attempts", value: @entity.attempts }, { label: "Result", value: @entity.result } ] }, { type: stack, direction: horizontal, gap: sm, children: [ { type: button, action: START_CONNECT, label: "Add Transition", variant: ghost }, { type: button, action: RUN_TESTS, label: "Run Tests", variant: primary }, { type: button, action: PLAY_AGAIN, label: "Reset", variant: secondary } ] } ] }
|