Ruby Sketch Extra Quality (Free HOW-TO)

500.times particles << Particle.new(rand(800), rand(600))

show require 'ruby2d' set width: 500, height: 500 ruby sketch

require 'ruby2d' set width: 800, height: 600, title: "My Ruby Sketch", background: '#111' on :key_down do |e| clear if e.key == 'r' end 500.times particles &lt