Increase energy parameters and initial cell count for simulation dynamics

This commit is contained in:
Sam 2025-11-09 01:25:52 -06:00
parent 69296cf4b7
commit de45db4393
3 changed files with 6 additions and 6 deletions

View File

@ -79,7 +79,7 @@ class InteractiveConfig:
grid_width=GRID_WIDTH,
grid_height=GRID_HEIGHT,
cell_size=CELL_SIZE,
initial_cells=50,
initial_cells=350,
initial_food=FOOD_OBJECTS_COUNT,
food_spawning=FOOD_SPAWNING,
random_seed=RANDOM_SEED,

View File

@ -81,7 +81,7 @@ class SimulationEngine:
grid_width=GRID_WIDTH,
grid_height=GRID_HEIGHT,
cell_size=CELL_SIZE,
initial_cells=50,
initial_cells=350,
initial_food=FOOD_OBJECTS_COUNT,
food_spawning=FOOD_SPAWNING,
random_seed=RANDOM_SEED,

View File

@ -93,7 +93,7 @@ class FoodObject(BaseEntity):
self.max_visual_width: int = 8
self.decay: int = 0
self.decay_rate: int = 1
self.max_decay = 200
self.max_decay = 400
self.interaction_radius: int = 50
self.neighbors: int = 0
self.flags: dict[str, bool] = {
@ -300,11 +300,11 @@ class DefaultCell(BaseEntity):
distance_to_food = get_distance_between_objects(self, food_object)
if distance_to_food < self.max_visual_width and food_objects:
self.energy += 130
self.energy += 140
food_object.flag_for_death()
return self
if self.energy >= 1600:
if self.energy >= 1700:
# too much energy, split
duplicate_x, duplicate_y = self.position.get_position()
duplicate_x += random.randint(-self.max_visual_width, self.max_visual_width)
@ -350,7 +350,7 @@ class DefaultCell(BaseEntity):
movement_cost = abs(output_data["angular_acceleration"]) + abs(output_data["linear_acceleration"])
self.energy -= (self.behavioral_model.neural_network.network_cost * 0.1) + 1.2 + (0.15 * movement_cost)
self.energy -= (self.behavioral_model.neural_network.network_cost * 0.08) + 1.5 + (0.25 * movement_cost)
return self