Module: Engine::Debug

Defined in:
lib/engine/debug.rb

Class Method Summary collapse

Class Method Details

.clearObject



25
26
27
28
# File 'lib/engine/debug.rb', line 25

def clear
  @lines.clear
  @spheres.clear
end

.line(from, to, color: [1, 1, 1]) ⇒ Object



9
10
11
# File 'lib/engine/debug.rb', line 9

def line(from, to, color: [1, 1, 1])
  @lines << { from: from, to: to, color: color }
end

.linesObject



17
18
19
# File 'lib/engine/debug.rb', line 17

def lines
  @lines
end

.sphere(center, radius, color: [1, 1, 1], segments: 16) ⇒ Object



13
14
15
# File 'lib/engine/debug.rb', line 13

def sphere(center, radius, color: [1, 1, 1], segments: 16)
  @spheres << { center: center, radius: radius, color: color, segments: segments }
end

.spheresObject



21
22
23
# File 'lib/engine/debug.rb', line 21

def spheres
  @spheres
end