diff --git a/packages/3d-web-client-core/src/character/CharacterModel.ts b/packages/3d-web-client-core/src/character/CharacterModel.ts index 35a8de5c..267ac007 100644 --- a/packages/3d-web-client-core/src/character/CharacterModel.ts +++ b/packages/3d-web-client-core/src/character/CharacterModel.ts @@ -50,22 +50,24 @@ export class CharacterModel { public async init(): Promise { await this.loadMainMesh(); - await this.setAnimationFromFile( - this.config.animationConfig.idleAnimationFileUrl, - AnimationState.idle, - ); - await this.setAnimationFromFile( - this.config.animationConfig.jogAnimationFileUrl, - AnimationState.walking, - ); - await this.setAnimationFromFile( - this.config.animationConfig.sprintAnimationFileUrl, - AnimationState.running, - ); - await this.setAnimationFromFile( - this.config.animationConfig.airAnimationFileUrl, - AnimationState.air, - ); + await Promise.all([ + this.setAnimationFromFile( + this.config.animationConfig.idleAnimationFileUrl, + AnimationState.idle, + ), + this.setAnimationFromFile( + this.config.animationConfig.jogAnimationFileUrl, + AnimationState.walking, + ), + this.setAnimationFromFile( + this.config.animationConfig.sprintAnimationFileUrl, + AnimationState.running, + ), + this.setAnimationFromFile( + this.config.animationConfig.airAnimationFileUrl, + AnimationState.air, + ), + ]); this.applyCustomMaterials(); }