fix: deleted animatedsprites in story
not finish loading function yet
This commit is contained in:
parent
edcc5eaffc
commit
21068c799a
|
@ -136,15 +136,15 @@ export default class SceneWithStory extends Scene {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case "loadAnimatedSprite":
|
// case "loadAnimatedSprite":
|
||||||
this.load.spritesheet(action.key, action.path);
|
// this.load.spritesheet(action.key, action.path);
|
||||||
this.load.loadResourcesFromQueue(() => {
|
// this.load.loadResourcesFromQueue(() => {
|
||||||
tmp = this.add.animatedSprite(action.key, "story");
|
// tmp = this.add.animatedSprite(action.key, "story");
|
||||||
tmp.position.set(action.positon[0], action.positon[1]);
|
// tmp.position.set(action.positon[0], action.positon[1]);
|
||||||
tmp.scale.set(action.scale[0], action.scale[1]);
|
// tmp.scale.set(action.scale[0], action.scale[1]);
|
||||||
this.storySprites.push(tmp);
|
// this.storySprites.push(tmp);
|
||||||
});
|
// });
|
||||||
break;
|
// break;
|
||||||
case "moveSprite":
|
case "moveSprite":
|
||||||
tmp = this.storySprites.find(function (sprite) {
|
tmp = this.storySprites.find(function (sprite) {
|
||||||
return sprite.imageId === action.key;
|
return sprite.imageId === action.key;
|
||||||
|
|
|
@ -10,7 +10,7 @@ export class Text {
|
||||||
}
|
}
|
||||||
|
|
||||||
export class Action {
|
export class Action {
|
||||||
type: "loadSprite" | "loadAnimatedSprite" | "moveSprite" | "showSprite" | "hideSprite";
|
type: "loadSprite" /*| "loadAnimatedSprite"*/ | "moveSprite" | "showSprite" | "hideSprite";
|
||||||
key: string;
|
key: string;
|
||||||
path?: string;
|
path?: string;
|
||||||
positon?: [number, number];
|
positon?: [number, number];
|
||||||
|
|
Loading…
Reference in New Issue
Block a user