Sfoglia il codice sorgente

Update hello world sample

Daniele Bartolini 11 anni fa
parent
commit
4741a6a99e

+ 5 - 0
samples/01.hello-world/boot.package

@@ -0,0 +1,5 @@
+{
+	"lua" : [
+		"lua/game"
+	]
+}

+ 3 - 1
samples/01.hello-world/crown.config

@@ -1,5 +1,7 @@
 {
-	"boot" : "lua/game",
+	"boot_script" : "lua/game",
+	"boot_package" : "boot",
+	"console_port" : 10001,
 	"window_width" : 800,
 	"window_height" : 600
 }

+ 2 - 2
samples/01.hello-world/lua/game.lua

@@ -3,10 +3,10 @@ function init()
 	Window.set_title("Hello world!")
 end
 
-function frame(dt)
+function update(dt)
 	-- Stop the engine when the 'ESC' key is released
 	if Keyboard.button_released(Keyboard.ESCAPE) then
-		Device.stop()
+		Device.quit()
 	end
 end