class Core::GUI::Draggable
Public Class Methods
new(x, y, w, h, type, sprite)
click to toggle source
Calls superclass method
Core::GUI::Element::new
# File lib/gui/draggable.rb, line 5 def initialize(x, y, w, h, type, sprite) super(x, y, w, h) @type = type @sprite = sprite end
Public Instance Methods
draw()
click to toggle source
# File lib/gui/draggable.rb, line 13 def draw @sprite.img.draw(@x, @y, Core::GUI_Z + 20, @w/@sprite.width, @h/@sprite.height) end
update(window)
click to toggle source
Calls superclass method
Core::GUI::Element#update
# File lib/gui/draggable.rb, line 10 def update(window) super end