chronofanz / EnhancedDistrictServices

EnhancedDistrictServices mod for Cities Skylines, which allows more granular control of services and supply chains.
MIT License
8 stars 5 forks source link

Simulation hangs indefinitely on busy traffic #43

Closed Jamby93 closed 4 years ago

Jamby93 commented 4 years ago

After #38, TransferManagerMod.MatchOffersClosest try in an endless loop to find a route that, if roads are full can always return false on StartTransfer. That's caused by while (requestAmount != 0) that always loops since it always find an (invalid) route. That has the side effect of completely hangs the simulation and lock the game. I discovered it by simply attaching a debugger when the game was frozen. I guess a simple decrement of requestAmount would solve, but anything else also. I'm willing to help if needed, since I've got the mod auto-updated from Steam and have a save game that freezes after few minutes that I'd like to recover 😟 I haven't found a way to download a previous version of the mod, since it was working pretty well till yesterday when I got the update.

Jamby93 commented 4 years ago

@chronofanz I just want to confirm you that #45 definitely fixed the issue, got no more problem since last update. Thanks a lot for the effort you keep putting into this awesome mod. 🍻