Skip to content

Instantly share code, notes, and snippets.

@tido64
Last active August 29, 2015 14:20
Show Gist options
  • Save tido64/a3f267a3ede7a8d0f42e to your computer and use it in GitHub Desktop.
Save tido64/a3f267a3ede7a8d0f42e to your computer and use it in GitHub Desktop.
"Hello World" in Rainbow
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