Jump to content
Sign in to follow this  
Frode789

Agents & traffic - hopeless system

18 posts in this topic Last Reply

Recommended Posts

Who was the smart guy who came up with the idea that the people go to the first house/work/shop etc available, and they all rush to the same house.. 

 

Idiot step 1) Find the closest house/job/shop/etc of the desired type that is not currently full.
2. Go there.
3. When they get there;

3A. Free spot? Ok cool..
3B. Full? Go back to idiot step 1.

 

So watch all the muppets run towards the closest house, then the 98 remaining percentage go to the next one, and so it goes on until they are all gotten there. Ineffective and horrible system? Yes, very. And it really screws the traffic over, when they behave like this.

 

Great post about this on SC official forum (http://forum.ea.com/eaforum/posts/list/9369635.page)

Share this post


Link to post
Share on other sites

It would be a good system if they had limited a number of agents that can go after a single building at the same time. The entire population going to the same spot on the map at the same time and then having to re-target is the problem. They then go into streets and avenues that take them even further.

 

If someone had been smart enough to write a piece of code that simply went like : Building 1XB can take 50 agents. Only 50 agents at the same time may target this building.

Share this post


Link to post
Share on other sites

The system actually works fine if you balance your city correctly.  LTP

 

To many people are comparing this to SC4 (you know the one, that came out 10 years ago and outshines this pile)

 

Sure you COULD balance your city...but maybe he wanted to make it realistic? 

 

haha could you actually imagine a life where once you get off work you go to the closest empty house and live there, until the next day?!

 

who's wife would I end up with o.O

Share this post


Link to post
Share on other sites

I'm tired of people saying "if you do X (where X is some gameplay mechanic that is completely counter-intuitive to real life), then it works just fine." 

 

NO! This is a city simulator. My expectations are that the engine at least half-way decently simulates a city. Yes, I know I can T-Intersection my city to death to get rid of some traffic issues, but I should NOT have to do that, because no city on this planet has only T-intersections  or else the city will decline into perpetual gridlock.

Share this post


Link to post
Share on other sites

It's a stupidly unrealistic system though. I love the agent-based traffic, but the agents should behave like actual traffic cars instead of grains of sand going down a set of tubes. In a real city, people have their destination in mind ahead of time; not everyone is trying to force their way into the same building at the same time. I can understand having a bit of that when it comes to shoppers and tourists, but commuters and students should have preset destinations.

Share this post


Link to post
Share on other sites

I understand the reasons for the agent system, and it makes perfect sense as an approach if you're trying to have a 'real' simulator - one where what you see is whats actually happening, as opposed to a vague approximation of what is essentially a spreadsheet behind the scenes (SC4)

 

However, It does seem that in order to make this transition they have abandoned a lot of the 'realism' that was present in simpler simulations like SC4. I would personally much rather have some visual trickery and more logic behind the scenes.

 

For me, though, the agent system is not in itself broken. A few changes would make it infinitely more realistic:

 

1) People should not all leave at the same time for work. It should be random what time they leave, say between 6-8am, as an example. So you have a realistic traffic distribution.

 

2) Instead of agents going to the closest available job first, why not have a weighting system (like they now do with road usage) so that they'll go to a random job, but thats weighted toward ones that are closer. So again, you'd have a more realistic traffic flow

 

3) Tune the performance of intersections by allowing better light timings, and by allowing 2 sides of an intersection to flow at the same time. Or, even simpler, allow turning on red lights

 

4) service vehicles should not behave like normal sim agents. They should, at the time of being 'summoned' (by a fire or start of shift) have a route plotted for them individually. So although this takes way more simulation power, you're only doing it for relatively few service vehicle agents, not the thousands of sims. So fire trucks would respond 1 truck to 1 fire, no matter the size (yes, not realistic, but better than 5 going to 1 fire when there are 3 fires!) and garbage vehicles would have a route plotted for them that divides them amongst the map in an efficient way.

 

5) Apply a weighting to shoppers and tourists too. Instead of them going simply to the closest appropriate building, these should be weighted. Sims should want to go to fancier landmarks more, even if they are further away. Casinos should be the same, if I build a fancy casino, it should draw gamblers away from the gambling houses. Its fancier!

 

6) Streetcars should have plotted routes. I'm OK with buses being more random, because if you make them go round every stop in a prescribed route, it becomes really inefficient unless you let players set routes, which is much more complicated. But streetcars should follow a loop. The game should plot a route, from the depot, and back to the depot, which stops at every stop with the least travel distance possible. Yes, its not ideal, but it would prevent the completely random wait times that you currently have. Streetcars should leave the depot at minimum intervals to avoid clumping.

 

7) lastly, trains should visit all stations in a city in the same way as above, with equal preference.

 

These 7 things would transform the game into something way more playable, and don't require creating complete agent persistance, which I understand would essentially require a complete rethink of how the engine works.

Share this post


Link to post
Share on other sites

To answer OP, I'll say what I said to some people when Maxis first announced how glassbox would work...

It's a really good idea ! But it came ~10 years too soon for a game of the scale of a simcity. Our computers are yet too weak to properly handle a population of a whole city. So we have to deal with stupid compromises for performences issues... The map size is the most evident one, but the stupid pathfinding is also a consequence of that (and a few other aspect of the game in its current state).

 

If you ask me, they should have "tested" GlassBox with another lower-scale game before attempting to apply it to something as big as a Simcity. It would have been (in its current state) perfect for a SimTower remake for example. and would have allowed to tweak it, debug it, and improve it's perfs, with less impact on the players, then only when Glassbox gets "well known" by both devs and players, starting to work on a brand new Simcity. So yes, with this approach, we would probably not have had an announcement for a new simcity till at least 2015, the average hardware would at that time be more likely to be able to handle Glassbox at its full potential without having (or at least "with only minimal") to deal with performences compromises like we are dealing with now.

Share this post


Link to post
Share on other sites

Understand the limitations of what they were trying to do.  When CXL made bus routes you traced the route.  If anything changed the route would break.  Eliminate one street and the bus had nowhere to go.  This way lets you get bus service to any point without worrying about how it gets there or how many changes you make and the same is true for trash, recyclables, school buses or any traffic that needs to get to a specific location.. I suspect the algorithm is something like a random walk search.  This is why intersections are problematic. In any city of the density represented by these maps traffic problems would be a foregone conclusion  On a 2 kilometer square map with a reported population of 300,000 that's a density of 75000 sims per square kilometer. Manhattan is  26,939 per square kilometer.  What I like about the sim is in what you can see.  The map feels alive.  Buses pick up people, garbage trucks pick up trash and so on.  All the things you see in a real city.

 

Having said that it does lead to some things which are problematic.  Conga lines of vehicles. Five buses tailgating each other.  This happens in real life but over time, rather than all at once.  The way roads are constructed adds to the problem.  Because one of the possibilities at an intersection is for traffic to reverse and go out the way it came in, what this means is that a road of varying density doesn't act right.  If you reduce road density it creates an intersection.    On a continuous road of differing densities objects to the rear get less of everything than they should.  The expected strategy would be to vary the density along a road so that high density objects get fill first followed by the lesser densities in order.  This doesn't work correctly.

Share this post


Link to post
Share on other sites

Core of the problem, from what I can see, is the way that destinations are selected. We end up with bus pileups because you have 16 buses trying to pick people up from the same stop. We end up with stuck fire trucks because every single fireman goes to the same fire at the same time. We end up with commuter traffic jams because everyone is trying to get a job at the same office (this becomes really obvious when you have high density businesses; traffic stalls on the road because everyone is trying to turn into one driveway. Adding more entrances to larger buildings would help with this somewhat). The traffic itself doesn't get bad until one of these events happens. Once you have everyone trying to go to the same place, traffic stops moving completely, and this results in garbage trucks getting blocked in, cops not being able to go to crimes, school buses can't get to kids, and so on. Which breaks the whole city.

Share this post


Link to post
Share on other sites
  • Original Poster
  • Core of the problem, from what I can see, is the way that destinations are selected. We end up with bus pileups because you have 16 buses trying to pick people up from the same stop. We end up with stuck fire trucks because every single fireman goes to the same fire at the same time. We end up with commuter traffic jams because everyone is trying to get a job at the same office (this becomes really obvious when you have high density businesses; traffic stalls on the road because everyone is trying to turn into one driveway. Adding more entrances to larger buildings would help with this somewhat). The traffic itself doesn't get bad until one of these events happens. Once you have everyone trying to go to the same place, traffic stops moving completely, and this results in garbage trucks getting blocked in, cops not being able to go to crimes, school buses can't get to kids, and so on. Which breaks the whole city.

     

    Exactly. Bad design, and really kills any chance of making a realistic city/traffic network.

    Share this post


    Link to post
    Share on other sites

    Core of the problem, from what I can see, is the way that destinations are selected. We end up with bus pileups because you have 16 buses trying to pick people up from the same stop. We end up with stuck fire trucks because every single fireman goes to the same fire at the same time. We end up with commuter traffic jams because everyone is trying to get a job at the same office (this becomes really obvious when you have high density businesses; traffic stalls on the road because everyone is trying to turn into one driveway. Adding more entrances to larger buildings would help with this somewhat). The traffic itself doesn't get bad until one of these events happens. Once you have everyone trying to go to the same place, traffic stops moving completely, and this results in garbage trucks getting blocked in, cops not being able to go to crimes, school buses can't get to kids, and so on. Which breaks the whole city.

     

    Exactly. Bad design, and really kills any chance of making a realistic city/traffic network.

     

    It's really sad, because the agent based sim could have been the best traffic simulator ever implemented in a game had Maxis properly designed the agent behavior. They squandered an opportunity here.

    Share this post


    Link to post
    Share on other sites

    I think that these issues are totally fixable within the current architecture. The beauty of an agent system is that its easy to change the rules that govern the agents.

     

    The real question is will it be fixed in time to 'save' the game from a slow fade out. EA need to repair the game in order to claw back from the PR nightmare. But beyond that, they aren't going to flog a dead horse....

    Share this post


    Link to post
    Share on other sites

     

    Core of the problem, from what I can see, is the way that destinations are selected. We end up with bus pileups because you have 16 buses trying to pick people up from the same stop. We end up with stuck fire trucks because every single fireman goes to the same fire at the same time. We end up with commuter traffic jams because everyone is trying to get a job at the same office (this becomes really obvious when you have high density businesses; traffic stalls on the road because everyone is trying to turn into one driveway. Adding more entrances to larger buildings would help with this somewhat). The traffic itself doesn't get bad until one of these events happens. Once you have everyone trying to go to the same place, traffic stops moving completely, and this results in garbage trucks getting blocked in, cops not being able to go to crimes, school buses can't get to kids, and so on. Which breaks the whole city.

     

    Exactly. Bad design, and really kills any chance of making a realistic city/traffic network.

     

    It's really sad, because the agent based sim could have been the best traffic simulator ever implemented in a game had Maxis properly designed the agent behavior. They squandered an opportunity here.

    The lack of Permenant destinations and homes really kills the traffic simulation.

    Share this post


    Link to post
    Share on other sites

     I think this is a major letdown. I just hope with future updates and dlc they can make it more realistic. Traffic and roads should be first as implementing turning lights, one way, culdasac, free flow lanes would help dramatically. Second would be rail, shipping, and airports. Just a poor attempt at making something so critical in the game almost useless. Hurry up maxis and get this stuff out as my game is collecting dust just like cities xl.

    Share this post


    Link to post
    Share on other sites

    I've been paying attention to cars in the city and how they navigate. I'm noticing a whole lot of driving in circles. Doesn't seem like the problem has been fixed even though Maxis claimed update 1.7 (I believe) fixed a lot of the problems.....

    Share this post


    Link to post
    Share on other sites

    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an Account  

    Sign up to join our friendly community. It's easy!  

    Register a New Account

    Sign In  

    Already have an account? Sign in here.

    Sign In Now

    Sign in to follow this  

    • Recently Browsing   0 members

      No registered users viewing this page.

    ×

    Help Keep Simtropolis Online, Open & Free!

    stexcollection-header.png

    Would you be able to help us catch up after a bit of a shortfall?

    We had a small shortfall last month. Your donation today would help us catch up for this month.

    Make a Donation, Get a Gift!

    We need to continue to raise enough money each month to pay for expenses which includes hardware, bandwidth, software licenses, support licenses and other necessary 3rd party costs.

    By way of a "Thank You" gift, we'd like to send you our STEX Collector's DVD. It's some of the best buildings, lots, maps and mods collected for you over the years. Check out the STEX Collections for more info.

    Each donation helps keep Simtropolis online, open and free!

    Thank you for reading and enjoy the site!

    More About STEX Collections