-
Notifications
You must be signed in to change notification settings - Fork 85
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
Electric Cars
policy does not work as expected with ParkingAI enabled
#1527
Comments
Unrelated issue: reading the ParkingAI logs I noticed that TM:PE is trying to search parking spot when citizen exit its vehicle at outside connection (going outside), same for incoming citizens (just before they spawn at outside connection). Since usually there are no buildings then not a big deal but on the other hand, time is wasted for things that always fail... Side note, maybe I don't have enough car asset but I feel like once I created a small district in the corner with Electric Cars policy, 80% cars driving in the city are...electric. What is going on😂 |
@aubergine10 should we despawn parked vehicle (if not electric) if citizen home is located in the district with |
@krzychu124 How does the situation arise in first place - does it only occur if the district policy is set after the car is already driving/parked? Does it only affect home, or does it also affect industry/commerce? IMO rather than despawn it would be better to just give them electric car but that might look bit weird if they park and suddenly their car changes upon parking (despawning on park would look even more weird). |
There is bug in the code - always spawns random vehicle regardless of citizen type (resident/tourist).
I didn't want to swap vehicle when they park but when cim starts his journey (and vehicle was parked too far and has to be moved closer) or is close enough but not electric. With the fix for mentioned bug vehicle swap would only occur when user set the policy (and obviously owns Green Cities DLC). The only way for cim to lose his parked car reference is when vehicle cannot be moved either because game is shuffling parked vehicles or was parked too far and there is not free parking spot closer to home. |
👍 |
Does that need tracking in separate issue? Maybe it's due to Lifecycle Rebalance mod or something like that? |
I would add it to some existing issue. I think it might be some kind of problem with randomization when they could use roadside parking. I don't use any other mods while testing ParkingAI since that feature is already pretty complex - I need to be sure it's a bug in TM:PE so later can try with other mods to search for regression/conflict |
Describe the problem
It looks like
ParkingAI
does not ensure that spawned parked residents vehicle in the district with mentioned policy are only electric cars. I've checked the code and found other weird issues but still nothing which could explain that behavior.Steps to reproduce
Electric Cars
policyfinal probability = random.Int(100) < 100 (forced probability when spawning vehicle at building located in the district with mentioned policy)
)Notes
Maybe we should also try to force already spawned vehicles (and assigned to resident) to be electric, potential solutions:
The text was updated successfully, but these errors were encountered: