Skip to content

Commit

Permalink
Altered materialize button to redirect to correct player tab
Browse files Browse the repository at this point in the history
  • Loading branch information
IsThatRay committed Oct 21, 2023
1 parent 02389e8 commit 209514b
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions src/ui/interface.js
Original file line number Diff line number Diff line change
Expand Up @@ -949,6 +949,17 @@ export class UI {

if (activeCreature.player.getNbrOfCreatures() > game.creaLimitNbr) {
$j('#materialize_button p').text(game.msg.ui.dash.materializeOverload);
} else if (activeCreature.player.id !== player) {
$j('#materialize_button p').text(game.msg.ui.dash.wrongPlayer);

this.materializeButton.click = () => {
this.showCreature("--", activeCreature.player.id);
};

$j('#card .sideA').on('click', this.materializeButton.click);
$j('#card .sideA').removeClass('disabled');
this.materializeButton.changeState(ButtonStateEnum.glowing);
$j('#materialize_button').show();
} else if (
!summonedOrDead &&
activeCreature.player.id === player &&
Expand Down

0 comments on commit 209514b

Please sign in to comment.