Class: MG::Application

Inherits:
Object
  • Object
show all
Defined in:
motion-game

Overview

The application class. A proper subclass is generated for you by the project template with a #start method, in which you are responsible to create a scene and ask the director to run it:

class Application < MG::Application
  def start
    MG::Director.shared.run(MyScene.new)
  end
end

Constructors (collapse)

Entry Point (collapse)

Class Method Details

+ (Application) shared

Returns the shared Application instance.

Returns:



18
# File 'motion-game', line 18

def self.shared; end

Instance Method Details

- (Application) start

This method is called when the application finished launching. This method is empty by default, and you are responsible to provide a custom implementation that will create the interface of your game.

Returns:



27
# File 'motion-game', line 27

def start; end