Class: Raylib::Rectangle

Inherits:
FFI::Struct
  • Object
show all
Defined in:
lib/raylib_main.rb,
lib/raylib_helper.rb

Overview

Rectangle, 4 components

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.create(x = 0, y = 0, width = 0, height = 0) ⇒ Object



162
163
164
# File 'lib/raylib_helper.rb', line 162

def self.create(x = 0, y = 0, width = 0, height = 0)
  Rectangle.new.set(x, y, width, height)
end

Instance Method Details

#heightObject



548
# File 'lib/raylib_main.rb', line 548

def height = self[:height]

#height=(v) ⇒ Object



549
# File 'lib/raylib_main.rb', line 549

def height=(v) self[:height] = v end

#set(x, y, width, height) ⇒ Object



166
167
168
169
170
171
172
# File 'lib/raylib_helper.rb', line 166

def set(x, y, width, height)
  self[:x] = x
  self[:y] = y
  self[:width] = width
  self[:height] = height
  self
end

#widthObject



546
# File 'lib/raylib_main.rb', line 546

def width = self[:width]

#width=(v) ⇒ Object



547
# File 'lib/raylib_main.rb', line 547

def width=(v) self[:width] = v end

#xObject



542
# File 'lib/raylib_main.rb', line 542

def x = self[:x]

#x=(v) ⇒ Object



543
# File 'lib/raylib_main.rb', line 543

def x=(v) self[:x] = v end

#yObject



544
# File 'lib/raylib_main.rb', line 544

def y = self[:y]

#y=(v) ⇒ Object



545
# File 'lib/raylib_main.rb', line 545

def y=(v) self[:y] = v end