Skip to main content

std-game-canvas2d

Level: Atom | Entity: GameCanvas2d | Persistence: runtime

2 states, 4 events, 4 transitions

Live Preview

orbital GameCanvas2dOrbital {
entity GameCanvas2d [runtime] {
id : string
name : string
description : string
status : string
createdAt : string
}
trait GameCanvas2dGameCanvas2d -> GameCanvas2d [interaction] {
initial: idle
state idle {
INIT -> idle
(fetch GameCanvas2d)
(render-ui main { type: "stack", direction: "vertical", gap: "md", children: [{ type: "stack", direction: "horizontal", gap: "sm", align: "center", children: [{ type: "icon", name: "monitor", size: "md" }, { type: "typography", content: "GameCanvas2d Canvas", variant: "h3" }] }, { type: "typography", content: "800x600 @ 60fps", variant: "caption", color: "muted" }, { type: "game-canvas2-d", width: 800, height: 600, fps: 60 }, { type: "button", label: "Start", event: "START", variant: "primary", icon: "play" }] })
START -> rendering
(render-ui main { type: "stack", direction: "vertical", gap: "md", children: [{ type: "stack", direction: "horizontal", gap: "sm", align: "center", children: [{ type: "icon", name: "monitor", size: "md" }, { type: "typography", content: "GameCanvas2d Canvas", variant: "h3" }] }, { type: "game-canvas2-d", width: 800, height: 600, fps: 60 }, { type: "button", label: "Stop", event: "STOP", variant: "ghost", icon: "square" }] })
}
state rendering {
TICK -> rendering
STOP -> idle
(render-ui main { type: "stack", direction: "vertical", gap: "md", children: [{ type: "stack", direction: "horizontal", gap: "sm", align: "center", children: [{ type: "icon", name: "monitor", size: "md" }, { type: "typography", content: "GameCanvas2d Canvas", variant: "h3" }] }, { type: "typography", content: "800x600 @ 60fps", variant: "caption", color: "muted" }, { type: "game-canvas2-d", width: 800, height: 600, fps: 60 }, { type: "button", label: "Start", event: "START", variant: "primary", icon: "play" }] })
}
}
page "/gamecanvas2ds" -> GameCanvas2dGameCanvas2d
}
Loading preview...

Orbital Visualization

Loading visualization...

Entity Fields

FieldTypeDefault
idstring-
namestring-
descriptionstring-
statusstring"active"
createdAtstring-

States

StateType
idleInitial
rendering-

Events

EventPayload
INIT-
START-
STOP-
TICK-

Transitions

FromEventToEffects
idleINITidle2 effects
idleSTARTrendering1 effect
renderingTICKrendering-
renderingSTOPidle1 effect