Represents an axis aligned rectangle

Constructors

Properties

Accessors

Methods

Constructors

Properties

height: number = 0
width: number = 0

Accessors

Methods

  • Check if the target rectangle is contained

    Parameters

    Returns boolean

    TRUE or FALSE

  • Check if the target vector is contained

    Parameters

    Returns boolean

    TRUE or FALSE

  • Compare if two rectangles are equals

    Parameters

    • rectangle: Rectangle

      The rectangle to compare

    Returns boolean

    TRUE if the rectangles are equals, FALSE if not

  • Check if the target rectangle is overlapping

    Parameters

    Returns boolean

    TRUE or FALSE

  • Set the rectangle

    Parameters

    • x: number
    • y: number
    • width: number
    • height: number

    Returns void