Module: Ruby2D::DSL

Defined in:
lib/ruby2d/dsl.rb

Overview

dsl.rb

Instance Method Summary collapse

Instance Method Details

#clearObject



28
29
30
# File 'lib/ruby2d/dsl.rb', line 28

def clear
  Ruby2D::Application.clear
end

#get(sym) ⇒ Object



8
9
10
# File 'lib/ruby2d/dsl.rb', line 8

def get(sym)
  Ruby2D::Application.get(sym)
end

#helloObject



4
5
6
# File 'lib/ruby2d/dsl.rb', line 4

def hello
  puts "hi"
end

#on(mouse: nil, key: nil, key_down: nil, controller: nil, &proc) ⇒ Object



16
17
18
# File 'lib/ruby2d/dsl.rb', line 16

def on(mouse: nil, key: nil, key_down: nil, controller: nil, &proc)
  Ruby2D::Application.on(mouse: mouse, key: key, key_down: key_down, controller: controller, &proc)
end

#set(opts) ⇒ Object



12
13
14
# File 'lib/ruby2d/dsl.rb', line 12

def set(opts)
  Ruby2D::Application.set(opts)
end

#showObject



24
25
26
# File 'lib/ruby2d/dsl.rb', line 24

def show
  Ruby2D::Application.show
end

#update(&proc) ⇒ Object



20
21
22
# File 'lib/ruby2d/dsl.rb', line 20

def update(&proc)
  Ruby2D::Application.update(&proc)
end