Class: Box
Extends
BaseType
<{height
:number
;width
:number
;x
:number
;y
:number
; }>
Constructors
new Box()
new Box(raw: {
height: number;
width: number;
x: number;
y: number;
}): Box
Parameters
Parameter | Type |
---|---|
|
|
|
|
|
|
|
|
|
|
Returns
Inherited from
BaseType<{ height: number; width: number; x: number; y: number; }>.constructor
Properties
raw
readonly raw: {
height: number;
width: number;
x: number;
y: number;
};
height
height: number;
width
width: number;
x
x: number;
y
y: number;
Inherited from
BaseType.raw
Accessors
centerX
get centerX(): number
Returns
number
centerY
get centerY(): number
Returns
number
height
get height(): number
Returns
number
width
get width(): number
Returns
number
x
get x(): number
Returns
number
y
get y(): number
Returns
number
Methods
toJSON()
toJSON(): {
height: number;
width: number;
x: number;
y: number;
}
Returns
{
height: number;
width: number;
x: number;
y: number;
}
Name | Type |
---|---|
height | number |
width | number |
x | number |
y | number |
Inherited from
BaseType.toJSON