Zmiana w population growth

This commit is contained in:
Tirith 2025-10-17 13:11:55 +02:00
parent 13047e2c54
commit 81121819f1
2 changed files with 7 additions and 5 deletions

View File

@ -28,6 +28,7 @@ func _ready():
randomize()
_initialize_sectors()
print("[Manager] Initialized global manager with %d sectors" % SECTOR_COUNT)
print(sectors_data[0])
func _process(delta):
update_timer += delta
@ -66,7 +67,8 @@ func _update_planets():
continue
for planet in sector["planets"]:
if planet["is_colonized"]:
var growth = int(planet["population"] / 10)
var growth_rate = 0.1
var growth = int(max(1, planet["population"] * 0.05 * growth_rate))
planet["population"] = min(planet["population"] + growth, planet["max_population"])
planet["resources"] += get_mined_per_cycle(planet)

View File

@ -48,10 +48,10 @@ anchor_left = 1.0
anchor_top = 0.5
anchor_right = 1.0
anchor_bottom = 0.5
offset_left = 2393.0
offset_top = 1315.0
offset_right = 2479.0
offset_bottom = 1346.0
offset_left = 1291.0
offset_top = 742.0
offset_right = 1377.0
offset_bottom = 773.0
grow_horizontal = 0
grow_vertical = 2
text = "Galaktyka"