Skip to content

Commit

Permalink
Fix card drag bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Golen87 committed Apr 26, 2024
1 parent 4446780 commit 99d395c
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/components/Card.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ export class Card extends Button {
this.target = new Phaser.Math.Vector2(this.x, this.y);

if (this.type != CardType.Rule) {
this.bindInteractive(this.edges);
this.bindInteractive(this.edges, true);
}
}

Expand Down Expand Up @@ -160,9 +160,7 @@ export class Card extends Button {
}

updateState(state: State) {
if (this.edges.input) {
this.edges.input.enabled = state == State.Planning;
}
this.enabled = state == State.Planning;
}

get color(): number {
Expand Down

0 comments on commit 99d395c

Please sign in to comment.