diff --git a/src/ReceiveCommands.cc b/src/ReceiveCommands.cc index 47a05b4d..8cc80169 100644 --- a/src/ReceiveCommands.cc +++ b/src/ReceiveCommands.cc @@ -1841,10 +1841,7 @@ void set_lobby_quest(shared_ptr l, shared_ptr q) { l->quest = q; l->episode = q->episode; if (l->item_creator) { - l->item_creator->clear_destroyed_entities(); - if (q->battle_rules) { - l->item_creator->set_restrictions(q->battle_rules); - } + l->create_item_creator(); } for (size_t client_id = 0; client_id < l->max_clients; client_id++) { diff --git a/src/ReceiveSubcommands.cc b/src/ReceiveSubcommands.cc index 6762be21..b4d9fd0f 100644 --- a/src/ReceiveSubcommands.cc +++ b/src/ReceiveSubcommands.cc @@ -2267,6 +2267,7 @@ static void on_battle_restart_bb(shared_ptr c, uint8_t, uint8_t, const v shared_ptr new_rules(new BattleRules(cmd.rules)); if (l->item_creator) { l->item_creator->set_restrictions(new_rules); + l->item_creator->clear_destroyed_entities(); } for (auto& lc : l->clients) { @@ -2276,9 +2277,6 @@ static void on_battle_restart_bb(shared_ptr c, uint8_t, uint8_t, const v } } l->map->clear(); - if (l->item_creator) { - l->item_creator->clear_destroyed_entities(); - } } }