Sha256: 980d29f72faac487de3c4f33083c6ddf62606ff430167000f2cd52d089342e4d
Contents?: true
Size: 521 Bytes
Versions: 4
Compression:
Stored size: 521 Bytes
Contents
$:.unshift File.expand_path(File.dirname(__FILE__) + "/../../lib") $:.unshift File.expand_path(File.dirname(__FILE__) + "/../../ext") require 'ray' class HelloScene < Ray::Scene scene_name :hello def setup @text = text "Hello world!", :size => 30 end def render(win) win.draw @text end end class HelloWorld < Ray::Game def initialize super("Hello world!") HelloScene.bind(self) push_scene :hello end def register add_hook :quit, method(:exit!) end end HelloWorld.new.run
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
ray-0.2.1 | samples/hello_world/hello.rb |
ray-0.2.0 | samples/hello_world/hello.rb |
ray-0.1.1 | samples/hello_world/hello.rb |
ray-0.1.0 | samples/hello_world/hello.rb |