fix
This commit is contained in:
parent
14bcb46735
commit
4fe3efa045
@ -2314,8 +2314,8 @@ class CitizenMilitary(CitizenTravel):
|
|||||||
if source['type'] == 'pool':
|
if source['type'] == 'pool':
|
||||||
_energy -= source['energy']
|
_energy -= source['energy']
|
||||||
elif source['type'] in ['food', 'energy_bar']:
|
elif source['type'] in ['food', 'energy_bar']:
|
||||||
recovers = source['energy'] / source['amount']
|
recovers = source['energy'] // source['amount']
|
||||||
amount = recoverable // recovers
|
amount = (recoverable if source['type'] == 'food' else _energy) // recovers
|
||||||
amount = amount if amount < source['amount'] else source['amount']
|
amount = amount if amount < source['amount'] else source['amount']
|
||||||
if amount > 0:
|
if amount > 0:
|
||||||
energy_sources.update({f'energySources[{source_idx}][quality]': source['quality']})
|
energy_sources.update({f'energySources[{source_idx}][quality]': source['quality']})
|
||||||
|
Loading…
x
Reference in New Issue
Block a user