Refactor: clean up unused code and improve variable initialization in evolution and entity management
This commit is contained in:
@@ -5,9 +5,9 @@ var evolution: OwniverseEvolution = OwniverseEvolution.new()
|
||||
|
||||
signal unlock_item(item_id: String)
|
||||
|
||||
var current_year: float = 0
|
||||
var current_year: float = 0.0
|
||||
var current_speed: int = 1
|
||||
var current_speed_in_years: float = 1
|
||||
var current_speed_in_years: float = 1.0
|
||||
|
||||
var entities: Dictionary[String, OwniverseEntity] = {}
|
||||
var entity_groups: Dictionary[String, Array] = {}
|
||||
@@ -21,24 +21,15 @@ var locked_entities: Array = []
|
||||
var cumulative_amount: Dictionary[String, float] = {}
|
||||
var current_amount: Dictionary[String, float] = {}
|
||||
|
||||
#var batch_count: int = 40
|
||||
#var entity_batches = {}
|
||||
|
||||
|
||||
func cycle(year_delta: float) -> void:
|
||||
# all owniverse activity should be called here
|
||||
_auto_production(year_delta)
|
||||
#_entity_evolution(year_delta)
|
||||
|
||||
_check_locked_items()
|
||||
|
||||
#var v = _get_distribution(current_amount)
|
||||
evolution.update_distribution(current_amount)
|
||||
|
||||
#for k in current_amount:
|
||||
#if current_amount[k] != 0:
|
||||
#print(k, "|", current_amount[k])
|
||||
|
||||
|
||||
#region auto production and evolution
|
||||
|
||||
|
||||
Reference in New Issue
Block a user