views:

98

answers:

1

I'm doing some graphics programming using the Gosu gem. The thing is, when I create a Window my mouse pointer is hidden. I can guess where the mouse is at a certain moment, and I can intuitively click, but my users may not.

Is there a way to show the pointer?

+1  A: 

I'm using something like this:

class Game < Gosu::Window
  def initialize
    super 800, 600, false
    @cursor = Gosu::Image.new(self, 'media/cursor.png')
  end

  def draw
    @cursor.draw self.mouse_x, self.mouse_y, 0
  end
end

Game.new.show
Ariel H. Pillet
Yeah, it's the same approach I settled on.
Geo