class Rhythmmml::Scene::Title
Public Class Methods
new(window)
click to toggle source
Calls superclass method
Rhythmmml::Scene::Base::new
# File lib/rhythmmml/scene.rb, line 37 def initialize(window) super @title = Gosu::Image.from_text(@window, "Rhythmmml", @font_path, 64, 4, @window.width, :center) @guide = Gosu::Image.from_text(@window, "press enter", @font_path, 36, 4, @window.width, :center) @guide_color = Gosu::Color::WHITE end
Public Instance Methods
draw()
click to toggle source
Calls superclass method
Rhythmmml::Scene::Base#draw
# File lib/rhythmmml/scene.rb, line 65 def draw super @title.draw(0, @window.height * 0.2, ZOrder::TEXT) @guide.draw(0, @window.height * 0.6, ZOrder::TEXT, 1, 1, @guide_color) end
update()
click to toggle source
Calls superclass method
Rhythmmml::Scene::Base#update
# File lib/rhythmmml/scene.rb, line 56 def update super if Time.now.sec % 2 == 0 @guide_color = Gosu::Color::WHITE else @guide_color = Gosu::Color::GRAY end end