animal crossing new Horizon beginnings

This commit is contained in:
Able 2024-10-15 17:06:38 -05:00
parent 34cbd9a5e6
commit ed7c8f20cb
2 changed files with 34 additions and 6 deletions

View file

@ -3,9 +3,37 @@ stn := @use("../../../libraries/stn/src/lib.hb");
horizon_api := @use("../../../libraries/horizon_api/src/lib.hb")
render := @use("../../../libraries/render/src/lib.hb");
.{Vec2} := @use("../../../libraries/stn/src/lib.hb").math
Window := struct {
// TODO: Replace this with widgets
// implicit_framebuffer:
width: int,
height: int,
x: int,
y: int,
}
main := fn(): int {
a := buffer.create("XHorizon\0")
screen := render.init(true)
image := render.new_surface(screen.width / 3, screen.height / 3)
pos := Vec2(int).(100, 100)
loop {
// Clear the screen
render.clear(screen, render.black)
// TODO: Get windows out of the hashmap
render.clear(image, render.white)
// Apply the image to the screen
render.put_surface(screen, image, pos)
// Sync the screen
render.sync(screen)
}
return 0

View file

@ -31,17 +31,17 @@ resolution = "1024x768x24"
# [boot.limine.ableos.modules.diskio_driver]
# path = "boot:///diskio_driver.hbf"
[boot.limine.ableos.modules.render_example]
path = "boot:///render_example.hbf"
# [boot.limine.ableos.modules.render_example]
# path = "boot:///render_example.hbf"
# [boot.limine.ableos.modules.serial_driver_test]
# path = "boot:///serial_driver_test.hbf"
# [boot.limine.ableos.modules.horizon]
# path = "boot:///horizon.hbf"
[boot.limine.ableos.modules.horizon]
path = "boot:///horizon.hbf"
# [boot.limine.ableos.modules.horizon_testing_program]
# path = "boot:///horizon_testing_program.hbf"
[boot.limine.ableos.modules.horizon_testing_program]
path = "boot:///horizon_testing_program.hbf"
# [boot.limine.ableos.modules.dt_buffer_test]
# path = "boot:///dt_buffer_test.hbf"