struct

GSF::Box

Inherits Struct < Value < Object

Constructors

new(width : Int32 = 1, height : Int32 = width)

if only one arg is used, width is used for both width and height, like a square size

Source

Instance methods

collides?(x, y, other : Box, other_x, other_y)

with other Box

Source
collides?(x, y, circle : Circle, cx, cy)

with circle (radius, cx, cy)

Source
collides?(x, y, radius, cx, cy)

with circle (cx, cy, radius)

Source
height
Source
height=(height : Int32)
Source
width
Source
width=(width : Int32)
Source