feat: Renderable::scale
This commit is contained in:
parent
3d670c6189
commit
58cebcd827
|
@ -37,6 +37,21 @@ export class Renderable {
|
|||
this.internal.rotation = rotation;
|
||||
}
|
||||
|
||||
get scale() {
|
||||
const scale = this.internal.scale || {x: 1, y: 1};
|
||||
return [
|
||||
scale.x,
|
||||
scale.y,
|
||||
];
|
||||
}
|
||||
|
||||
set scale(scale) {
|
||||
this.internal.scale = {
|
||||
x: scale[0],
|
||||
y: scale[1]
|
||||
};
|
||||
}
|
||||
|
||||
get visible() {
|
||||
return this.internal.visible;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user