Last active
August 29, 2015 14:20
-
-
Save tido64/a3f267a3ede7a8d0f42e to your computer and use it in GitHub Desktop.
"Hello World" in Rainbow
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function init() | |
local label = rainbow.label("Hello World!") | |
label:set_alignment('c') | |
local font = rainbow.font("OpenSans-Light.ttf", 60) | |
label:set_font(font) | |
local screen = rainbow.platform.screen | |
local center_x = screen.width * 0.5 | |
local center_y = screen.height * 0.5 | |
label:set_position(center_x, center_y) | |
rainbow.scenegraph:add_label(label) | |
end | |
function update(dt) end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment