feat(rect): add getDimensions
This commit is contained in:
parent
0ce811fa97
commit
02edc4fc07
1 changed files with 4 additions and 0 deletions
|
@ -67,6 +67,10 @@ function Rect:getRelativeCoordinate(dx, dy)
|
||||||
return dx - self.x, dy - self.y
|
return dx - self.x, dy - self.y
|
||||||
end
|
end
|
||||||
|
|
||||||
|
function Rect:getDimensions()
|
||||||
|
return self.w, self.h
|
||||||
|
end
|
||||||
|
|
||||||
function Rect:drawBox()
|
function Rect:drawBox()
|
||||||
utils.graphics.box(self.x, self.y, self.w, self.h)
|
utils.graphics.box(self.x, self.y, self.w, self.h)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue