Skip to content

Commit

Permalink
fix(server): ko printing by default
Browse files Browse the repository at this point in the history
  • Loading branch information
Molaryy committed Jun 23, 2024
1 parent dd6ea51 commit 1463c70
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/server/src/commands/ai/incantation.c
Original file line number Diff line number Diff line change
Expand Up @@ -142,6 +142,7 @@ static bool are_requierment_met_encapsulation(
required_level)
) {
dprintf(client->fd, "ko\n");
client->is_incanting = false;
return false;
}
return true;
Expand All @@ -168,6 +169,8 @@ void incantation_callback_end_of_command(client_t *c, server_t *s)
size_t players_on_tile = get_nb_players_on_tile(c, s);
tile_t *tile = &s->map[c->x + c->y * s->proprieties.width];

if (c->is_incanting == false)
return;
if (!are_requierment_met_encapsulation(c, resource_count,
players_on_tile, c->level)) {
run_logic_on_group(c, s, c->level, callback_unfreeze);
Expand Down

0 comments on commit 1463c70

Please sign in to comment.