struct GSF::Box

Defined in:

gsf/box.cr

Constructors

Instance Method Summary

Constructor Detail

def self.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


[View source]

Instance Method Detail

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

with other Box


[View source]
def collides?(x, y, circle : Circle, cx, cy) #

with circle (radius, cx, cy)


[View source]
def collides?(x, y, radius, cx, cy) #

with circle (cx, cy, radius)


[View source]
def height : Int32 #

[View source]
def height=(height : Int32) #

[View source]
def width : Int32 #

[View source]
def width=(width : Int32) #

[View source]