Files
cell/tests/window.js
John Alanbrook 3a4547fb80
Some checks failed
Build and Deploy / package-dist (push) Has been cancelled
Build and Deploy / deploy-itch (push) Has been cancelled
Build and Deploy / deploy-gitea (push) Has been cancelled
Build and Deploy / build-windows (CLANG64) (push) Has been cancelled
Build and Deploy / build-linux (push) Has been cancelled
add blob; pull out crypto, time; add sdl_renderer
2025-03-27 14:31:02 -05:00

52 lines
956 B
JavaScript

//var draw = use('draw2d')
prosperon.win = prosperon.engine_start({
title:`Prosperon [${prosperon.version}-${prosperon.revision}]`,
width: 1280,
height: 720,
high_dpi:0,
alpha:1,
fullscreen:0,
sample_count:1,
enable_clipboard:true,
enable_dragndrop: true,
max_dropped_files: 1,
swap_interval: 1,
name: "Prosperon",
version:prosperon.version + "-" + prosperon.revision,
identifier: "world.pockle.prosperon",
creator: "Pockle World LLC",
copyright: "Copyright Pockle World 2025",
type: "game",
url: "https://prosperon.dev"
})
var ren = prosperon.win.make_renderer("opengl")
function loop() {
ren.clear()
ren.fillrect({x:50,y:50,height:50,width:50})
ren.present()
$_.delay(loop, 1/60)
}
loop()
$_.delay($_.stop, 3)
var os = use('os')
var ioguy = {
__ACTORDATA__: {
id: os.ioactor()
}
}
$_.send(ioguy, {
type: "subscribe",
actor: $_
})
$_.receiver(e => {
if (e.type === 'quit')
os.quit()
})