-
Notifications
You must be signed in to change notification settings - Fork 1.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WorkerAutomation cached per Civ - BFS cached #4868
Conversation
Fair enough. |
Resolve conflicts though |
# Conflicts: # core/src/com/unciv/logic/automation/UnitAutomation.kt # core/src/com/unciv/logic/map/MapUnit.kt # core/src/com/unciv/ui/worldscreen/unit/UnitActions.kt
I'm not 100% happy with it, too many todo's, and they lead to more code review after merge and another push I couldn't resist. But |
about automate workers being the most expensive: i got a proposal for this but i have no idea how the project works, if there are 2 improvements that the workers can build and there are 5 workers first sort them by their land distance (not pathfind) to that improvement (and maybe increase the distance by 1.3 something as there are often many hills on the way) and only pathfind 2 workers (2 comes from improvement count on map) if some dont have a direct path remove it from that list, if everything is fine load them with that task and dont check other workers at all also about city production reassignation: xlenstra said that it will be implemented by it will check for yields every turn which i think is very inefficient, i think only cities should update their yields in those cases:
|
@logicminimal You have literally no idea how many changes are possible that would lead to a change in yield. There are definitely dozens of factors. The nice thing is, that most major changes occur over turns, not within turns. I'm completely with xlenstra on this. |
great improvements? |
Resolve #4840
Brings the Next-Turn of the save included in the issue from almost 1000 seconds (my box, before ZOC) to 360s (with ZOC) by reusing city-to-city BFS'es on a Civ/Turn level. All kudos to @xlenstra for the idea. Greetings to @avdstaaij - we're going to compensate that cost away - I hope.
Unsuccessful leads: