Skip to content
floere edited this page Sep 14, 2010 · 4 revisions

For starters, please look at the examples provided in the examples folder. Also, try them :)

In the Gosu Extensions, you basically have Things and Traits.

class Spaceship < Thing

The Things can have Traits:

class Spaceship < Thing
  it_is Turnable # This will enable it to turn
  it_is_a Controllable # This will enable controls, and install the "controls" method.
   
  controls Gosu::Button::KbA => Turnable::Left

Read more about these here Game Objects and Game Traits.