Skip to content

Commit

Permalink
Fixed double player free on world regen
Browse files Browse the repository at this point in the history
  • Loading branch information
Rafael-Dev-21 committed Apr 25, 2024
1 parent 010b4d4 commit 53ac275
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/modes/generate.c
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ Mode *generate_mode(ModeData *data)
}
data->world = create_world(1024, 1024);
init_world(data->world);
if (data->player != NULL) {
/*if (data->player != NULL) {
free_creature(data->player);
}
}*/
data->player = create_player(data->world);

for (int i = 0; i < 256; i++) {
Expand Down

0 comments on commit 53ac275

Please sign in to comment.