Fixing warning on character selection
authorDavid Négrier <d.negrier@thecodingmachine.com>
Tue, 2 Jun 2020 13:57:11 +0000 (15:57 +0200)
committerDavid Négrier <d.negrier@thecodingmachine.com>
Tue, 2 Jun 2020 13:57:11 +0000 (15:57 +0200)
front/src/Phaser/Login/SelectCharacterScene.ts

index 98b5262e0431cf8440ebbb4acbfb223f9d868c35..8a52afcd443b3458b8c3b72b2cc51b5ff760b6e9 100644 (file)
@@ -168,7 +168,7 @@ export class SelectCharacterScene extends Phaser.Scene {
             let row = Math.floor(i / this.nbCharactersPerRow);
 
             let [x, y] = this.getCharacterPosition(col, row);
-            let player = this.physics.add.sprite(x, y, playerResource.name, playerResource.name);
+            let player = this.physics.add.sprite(x, y, playerResource.name, 0);
             player.setBounce(0.2);
             player.setCollideWorldBounds(true);
             this.anims.create({