fix: initialization
This commit is contained in:
parent
d9f5869a37
commit
84ee8ee997
|
@ -73,6 +73,7 @@ export default class Sprite extends Component {
|
||||||
}
|
}
|
||||||
initialize(values, defaults) {
|
initialize(values, defaults) {
|
||||||
let {
|
let {
|
||||||
|
animation = defaults.animation,
|
||||||
anchorX = defaults.anchorX,
|
anchorX = defaults.anchorX,
|
||||||
anchorY = defaults.anchorY,
|
anchorY = defaults.anchorY,
|
||||||
frame = defaults.frame,
|
frame = defaults.frame,
|
||||||
|
@ -83,6 +84,7 @@ export default class Sprite extends Component {
|
||||||
this.$$scale = {x: scaleX, y: scaleY};
|
this.$$scale = {x: scaleX, y: scaleY};
|
||||||
super.initialize(values, defaults);
|
super.initialize(values, defaults);
|
||||||
this.frame = frame;
|
this.frame = frame;
|
||||||
|
this.animation = animation;
|
||||||
}
|
}
|
||||||
get lightness() {
|
get lightness() {
|
||||||
return this.$$lightness;
|
return this.$$lightness;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user