Skip to content

Commit

Permalink
🩹 trim sprites and landing pad collision box
Browse files Browse the repository at this point in the history
  • Loading branch information
haliphax committed Dec 1, 2023
1 parent 7021104 commit d69a9fb
Show file tree
Hide file tree
Showing 8 changed files with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/game.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ export default class Game extends Phaser.Scene {
);

this.pad.body.immovable = true;
this.pad.body.setSize(this.pad.width, this.pad.height, true);
this.pad.body.setSize(this.pad.width, this.pad.height - 10, true);
this.physics.add.collider(
this.pad,
this.dropGroup,
Expand Down Expand Up @@ -239,6 +239,11 @@ export default class Game extends Phaser.Scene {
avatar.swayTween?.stop();
avatar.swayTween = null;
avatar.score = score;
avatar.container.setY(
this.game.scale.gameSize.height -
this.pad!.body!.height -
avatar.sprite.height / 2,
);
drop.body.enable = false;
this.dropGroup!.remove(drop);
avatar.active = false;
Expand Down
Binary file modified src/public/default/chute.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/public/default/drop1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/public/default/drop2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/public/default/drop3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/public/default/drop4.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/public/default/drop5.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified src/public/default/pad.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit d69a9fb

Please sign in to comment.