Method: Castaway::RelativeTo#position

Defined in:
lib/castaway/relative_to.rb

#position(x, y) ⇒ Object



14
15
16
# File 'lib/castaway/relative_to.rb', line 14

def position(x, y)
  Castaway::Point.new(x / @width, y / @height) * @production.resolution
end