Don't create animation if assets isnt in sprite_animations group
This commit is contained in:
parent
0f01a4ec7c
commit
8c8ec69f42
@ -64,7 +64,7 @@ const gameConfig = {
|
||||
antialias: true,
|
||||
roundPixels: true
|
||||
},
|
||||
resolution: 5,
|
||||
resolution: 10,
|
||||
pixelArt: true
|
||||
}
|
||||
|
||||
@ -138,6 +138,8 @@ const createScene = async (scene: Phaser.Scene) => {
|
||||
* This is done here because phaser forces us to
|
||||
*/
|
||||
gameStore.assets.forEach((asset) => {
|
||||
if (asset.group !== 'sprite_animations') return
|
||||
|
||||
scene.anims.create({
|
||||
key: asset.key,
|
||||
frameRate: 7,
|
||||
|
Loading…
x
Reference in New Issue
Block a user