Add debug var to remove all randomizable enemies from the game
@@ -12,6 +12,10 @@ from logic.logic import Logic
# Set it to the name of a specific enemy type and it will handle putting that enemy type in every single enemy location throughout the game - ignoring memory and logic limits.
DEBUG_ENEMY_NAME_TO_PLACE_EVERYWHERE = None
+# This variable is for removing all randomizable enemies from the game.
+# This helps with figuring out how much free memory each room has, not counting memory used by the enemies themselves.
+DEBUG_REMOVE_ALL_ENEMIES = False
+
# Limit the number of species that appear in a given stage to prevent issues loading too many particles and to prevent stages from feeling too chaotic.
# (This limit does not apply to the sea.)
MAX_ENEMY_SPECIES_PER_STAGE = 10
@@ -104,6 +108,9 @@ def randomize_enemies(self):
# Now that all randomized enemy locations have been decided successfully, actually save the changed enemies.
save_changed_enemies_and_randomize_their_params(self)
+ if DEBUG_REMOVE_ALL_ENEMIES:
+ return
+
add_modify_and_replace_actors_for_enemy_rando(self)
randomize_enemies_spawned_by_objects(self)
@@ -354,6 +361,10 @@ def save_changed_enemies_and_randomize_their_params(self):
enemy, arc_name, dzx, layer = get_enemy_instance_by_path(self, path)
stage_folder, room_arc_name = arc_name.split("/")
+ if DEBUG_REMOVE_ALL_ENEMIES:
+ dzx.remove_entity(enemy, "ACTR", layer=layer)
+ continue
+
if False:
group_path = "/".join(path.split("/")[0:-1])
if group_path != last_printed_group_path:
