Skip to content

Commit

Permalink
fix challenge
Browse files Browse the repository at this point in the history
  • Loading branch information
dubzn committed Nov 4, 2024
1 parent c136b76 commit 6de040f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/models/status/round/challenge.cairo
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ impl ChallengeImpl of ChallengeTrait {
} else {
challenge_player.plays -= 1;
emit!(world, (challenge_player));
ChallengePlayerStore::set(@challenge_player, world);
if challenge_player.plays.is_zero() {
game
.current_player_hp =
Expand Down Expand Up @@ -145,7 +146,6 @@ impl ChallengeImpl of ChallengeTrait {
let play_game_over_event = PlayGameOverEvent { player: get_caller_address(), game_id: game.id };
emit!(world, (play_game_over_event));
game.state = GameState::FINISHED;
GameStore::set(@game, world);
}
}
}
Expand Down

0 comments on commit 6de040f

Please sign in to comment.