You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

37 lines
878B

  1. require_relative '../module'
  2. module DHE
  3. class Ranger < DHE::Module
  4. def initialize
  5. super(name: 'RANGER', hp: 6, foreground: [60, 100, 15], background: [60, 100, 97])
  6. left = @width / 3.5 + 1.0 / 3.0
  7. right = @width - left
  8. y = 24.0
  9. delta_y = 16.0
  10. panel_buffer = delta_y + 4.0
  11. separator_offset = panel_buffer / 2.0 + 2.0
  12. medium_knob(x: left, y: y, label: 'LEVEL')
  13. output_port(x: right, y: y)
  14. y += delta_y
  15. cv_port(x: left, y: y)
  16. attenuverter(x: right, y: y)
  17. 2.times do
  18. y += panel_buffer
  19. separator(y: y - separator_offset)
  20. medium_knob(x: left, y: y, label: 'LIMIT')
  21. polarity_toggle(x: right, y: y)
  22. y += delta_y
  23. cv_port(x: left, y: y)
  24. attenuverter(x: right, y: y)
  25. end
  26. end
  27. end
  28. end
  29. MODULE_TO_FILENAME[DHE::Ranger.new] = __FILE__