+ Reply to Thread
Page 1 of 2 1 2 LastLast
Results 1 to 20 of 26

Thread: Temporary Traffic Fix: A Step-by-Step Guide

  1. #1

    Temporary Traffic Fix: A Step-by-Step Guide

    There's been some confusion about how to manually update the traffic in the game so I've decided to post this step-by-step guide. Hopefully, this alleviates the traffic and gridlock issues for some and give Collosal Order a little more time to fix the problem.


    UPDATE 2/24/11: pdguru created a thread that simplifies this process a bit. He followed the instructions here, modified the necessary file and packaged it all up to make the process easier for the masses. Go here if you want to skip the steps I've outlined below and just download the modified files: http://forum.paradoxplaza.com/forum/...ffic-Reduction

    Step 1: Download, unpack and run the GS File Viewer
    Download Liechti's excellent utility here, make sure you get the latest version: http://www.citiesinmotion.net/downlo...iles&entryID=5

    Once downloaded, create a folder on your computer and unpack the contents of the downloaded zip file to that folder. I simply created a folder on my desktop and unpacked the files to it.

    You should now have a folder with a bunch of files in it. Look for an application called "GSFileViewer" (GSFileViewer.exe). It'll have a blue icon that resembles a barrel. Run that program.

    Step 2: Extract the metro.gs file
    In GS File Viewer press the "Open GS file..." button. Next, navigate to your Cities in Motion folder and select the metro.gs file. Press "Open". If you did this correctly, you should now see a collection of folders with each one containing more files and folders:



    Press the "Extract whole GS file to folder..." button. Navigate to your Cities in Motion folder and select it. Make sure it is highlighted and press the "Make New Folder" button towards the bottom. It'll make a new folder and allow you to name it. It is very important that you name it "metro". After you've named it, make sure it is selected and press "OK". The GS File Viewer will now extract all of the files inside metro.gs into your new "metro" folder.

    IMPORTANT NOTE: When the Cities in Motion game starts up it'll check for the existence of the "metro" folder. If it sees it, it'll ignore the metro.gs file and use the files in the metro folder instead. Be aware that any patches you apply to your game will only update the "metro.gs" file and not any files in your metro folder. Therefore, you must remember to delete your metro folder after installing a patch or else some of the changes made by the developers will be ignored.

    Step 3: Fixing traffic
    Navigate to your "Cities in Motion\metro\scripts" folder. Open the "game.script" file with a text editor like Notepad. Scroll down until you see the following lines (around line 80 approx.):

    Code:
    // time in seconds after the citizen can move again
    $grid.citizens.minCycleDuration = 300;
    $grid.citizens.maxCycleDuration = 600;
    These values control how often a citizen moves about the city. After arriving at their destination a citizen will not move again for at least 300 seconds but is guaranteed to be moving again within 600 seconds.

    If you revise these values upwards you will reduce the number of citizens moving around at any given time and therefore, reduce the amount of traffic on the streets. However, you will also reduce the number of citizens looking to use your public transport.

    I've set these to 450 and 900 respectively and am very happy with the results so far.

    Good luck!
    NullCharacter
    Last edited by NullCharacter; 24-02-2011 at 19:36. Reason: Added update regarding pdguru's simplified method

  2. #2
    Corporal
    Cities in Motion

    Join Date
    Feb 2011
    Location
    Germany
    Posts
    27
    Thanks for the good and detailed guide!

  3. #3
    Thank you for this - trying it right away!

  4. #4
    Excellent guide - thanks for your help. The traffic was getting quite annoying.

  5. #5
    Sergeant
    Hearts of Iron 2: ArmageddonCities in MotionCrusader Kings IIEU3 CompleteDivine Wind
    Hearts of Iron IIISemper FiSupreme Ruler 2020Victoria 2

    Join Date
    Aug 2009
    Location
    Oxford, UK
    Posts
    92
    Many thanks!

  6. #6
    Nullcharacter - this helps a lot, thank you. Now, is there a variable that sets the way traffic goes (i.e. chooses major or minor roads)? Some of the problem (particularly Amsterdam) seems to be that cars come off the main roads and take the minor ones and clog them up.

  7. #7
    Quote Originally Posted by pdguru View Post
    Now, is there a variable that sets the way traffic goes (i.e. chooses major or minor roads)?
    Haven't seen anything along those lines yet. I'll keep an eye out for it.

  8. #8
    You could also try the following:
    Follow Steps 1 and 2 (you'll have to extract objects.gs too) from NullCharacters Post then go to ..\Cities In Motion\metro\objects\vehicles\ where there should be the folders era1 to era 4 which contain the vehicles. Each ground-vehicle folder contains a script file which will contain these lines (with different values):

    Code:
    this.acceleration = 2.0;
    this.braking = 0.3;
    this.speed = 0.9;
    this.turning = 1.0;
    I doubled all acceleration values and set all braking values to 0.8. This seems to make traffic run alot (maybe too much - the values are too high I guess) smoother. Pretty unrealistic of course but for a temporary fix it could be worth trying.

  9. #9
    I did something similar. However instead of changing the private cars vehicle speed, or the overall traffic, I changed the amount of passengers each of the player vehicles can carry.

    For me, the main problem is not so much congestions (that can be reduced by going off road, and seems to be somewhat realistic (if a bit over the top for the top roads)). However I wouldn't mind that if I wouldn't go bancrupt on every map, unless I rush to metro, a one way tactic I do not deem fun. I play on easy, and I want to rake up insane amounts of cash to create an insane public transport network. I can't do that if the ROI of my whole network is either 2'000 in the negative, or barely profitable, often 100 or less, even when I pay minimum wages, and neglect all the infrastructure, while keeping the prices in dark red. All that, and i'm still not able to transport all the customers, it's insane.

    To do a similar thing as I did, you need to use the gs-unpack tool (mentioned in the first post) but instead of the metro.gs file you need the object.gs file (btw. what _is_ this gs archive format? I was unable to find any information online), then go to the "vehicles" subfolder and change all the *.script files entry on the "capacity" line. I used a quick and dirty script that added half to what already was there, for example the streetcar used to carry 10 but now carries 15.

    This increases the income a bit much, but as I said, I wanted it easy. Obviously I also now need less busses, so the whole network isn't overworked by 20 buses serving less then 10 stations in addition to the private cars. Even better, one can now actually achieve the scenario help demands, before they come back and say "you helped a lot the first time now do another thing for me". I might reduce the multiplier or actually subtract from the preset for metros, one of the desingers must hate all other forms of public transport

    Caveat: at the end you need to put the resulting "objects" folder into a "metro" folder in the application directory, otherwise your changes will be ignored by CiM.

    For example (note objects in metro, not directly in CiM folder):
    /Applications(x86)/Paradox/Cities in Motion/metro/objects/

  10. #10
    Quote Originally Posted by Sbuiko View Post
    I did something similar. However instead of changing the private cars vehicle speed, or the overall traffic, I changed the amount of passengers each of the player vehicles can carry.

    For me, the main problem is not so much congestions (that can be reduced by going off road, and seems to be somewhat realistic (if a bit over the top for the top roads)). However I wouldn't mind that if I wouldn't go bancrupt on every map, unless I rush to metro, a one way tactic I do not deem fun. I play on easy, and I want to rake up insane amounts of cash to create an insane public transport network. I can't do that if the ROI of my whole network is either 2'000 in the negative, or barely profitable, often 100 or less, even when I pay minimum wages, and neglect all the infrastructure, while keeping the prices in dark red. All that, and i'm still not able to transport all the customers, it's insane.

    To do a similar thing as I did, you need to use the gs-unpack tool (mentioned in the first post) but instead of the metro.gs file you need the object.gs file (btw. what _is_ this gs archive format? I was unable to find any information online), then go to the "vehicles" subfolder and change all the *.script files entry on the "capacity" line. I used a quick and dirty script that added half to what already was there, for example the streetcar used to carry 10 but now carries 15.

    This increases the income a bit much, but as I said, I wanted it easy. Obviously I also now need less busses, so the whole network isn't overworked by 20 buses serving less then 10 stations in addition to the private cars. Even better, one can now actually achieve the scenario help demands, before they come back and say "you helped a lot the first time now do another thing for me". I might reduce the multiplier or actually subtract from the preset for metros, one of the desingers must hate all other forms of public transport

    Caveat: at the end you need to put the resulting "objects" folder into a "metro" folder in the application directory, otherwise your changes will be ignored by CiM.

    For example (note objects in metro, not directly in CiM folder):
    /Applications(x86)/Paradox/Cities in Motion/metro/objects/
    You might want to have alook here mate http://forum.paradoxplaza.com/forum/...ehicle-Realism

  11. #11
    Field Marshal Zarine's Avatar
    CK2: Holy KnightEU3 Collectors Edition500k clubEuropa Universalis IV: Pre-order

    Join Date
    Feb 2007
    Location
    Antibes,France
    Posts
    3,262
    Increasing the capacity of vehicles doesn't change the traffic congestion problem.
    For fun, I multiply by 10 all capacities and I still had problem because of congestion. with over 300 peoples waiting at some bus station.

  12. #12
    The unbeheadable king. JCFast's Avatar
    200k clubCities in MotionCrusader Kings IIEuropa Universalis 3EU3 Complete
    Divine WindHeir to the ThroneVictoria: RevolutionsVictoria 2Victoria II: A House Divided
    Victoria II: Heart of Darkness500k clubEuropa Universalis IV: Pre-order

    Join Date
    Jan 2007
    Location
    Fortress Europe
    Posts
    454
    Anyone found more optimal numbers than 450 and 900? I'm still getting long lines of traffic and gridlocks with these numbers. Haven't yet experimented with any other numbers.
    "When life gives you lemons, make lemonade, and then throw it in the face of the person who gave you the lemons until they give you the oranges you originally asked for?"
    -Bill McNeal

  13. #13
    Field Marshal Zarine's Avatar
    CK2: Holy KnightEU3 Collectors Edition500k clubEuropa Universalis IV: Pre-order

    Join Date
    Feb 2007
    Location
    Antibes,France
    Posts
    3,262
    The main problem is more traffic lock than people taking their car going somewhere adding to the traffic.
    A good solution would be to find a way to avoid those lock.

  14. #14
    what happens if you set the value to 0 and is okay with currently traffic levels, are there any negative effects this will have?

  15. #15
    Field Marshal Zarine's Avatar
    CK2: Holy KnightEU3 Collectors Edition500k clubEuropa Universalis IV: Pre-order

    Join Date
    Feb 2007
    Location
    Antibes,France
    Posts
    3,262
    After some try with a demo/beta mix, here is what I saw after modding acceleration/brake x2 :
    - without any intervention on the map by me, the traffic is normal. There are some little problem sometimes but it doesn't stay for long.
    - if I put a bus/tram line going on heavy traffic road without stoping there but stoping in little street with few vehicles, the traffic was ok
    - with the same setting, if you put too much vehicles, they create jam on the road joining the street where they are because player vehicle always go first
    - if you put bus/tram stop on heavy traffic road, you're pretty much dead. The chance that it blocks everyone behind is so high and the time to load as well makes it the jam master.

    So, this show 2 problems :
    - loading time
    - no possibilities to overtake stopped vehicles

    if one of these problems get solved, then there should be less jam.

  16. #16
    Hi,

    Im from german Fanpage http://www.citiesinmotion.net/index.php?page=Portal. My english is very boring. But I have good news. The traffic Problem seems to be modifiable.

    Extract metro.gs -->Go to Scripts--->Economy, then search for:


    Quellcode

    1 if ($num < 17700) {
    2 $grid.citizens.carMultiplier = clamp(1000.0 / max(1.0, $num - 22550.0) + 1.04, 0.0, 1.0);
    3 } else {
    4 $grid.citizens.carMultiplier = clamp(8000.0 / max(1.0, $num - 4000.0) + 0.25, 0.0, 1.0);
    5 }

    then change to:

    Quellcode

    1 if ($num < 17700) {
    2 $grid.citizens.carMultiplier = clamp(1000.0 / max(1.0, $num - 22550.0) + 1.04, 0.0, 0.5);
    3 } else {
    4 $grid.citizens.carMultiplier = clamp(8000.0 / max(1.0, $num - 4000.0) + 0.25, 0.0, 0.5);
    5 }

    The red Number can be changed between 0.0 and 1.0.

    The traffic will be reduced obviously. The customer traffic remains unchanged. Its a first step. Try it out.

    big thank you to Bennhardt

  17. #17
    Quote Originally Posted by eagleFMJ View Post
    You might want to have alook here mate http://forum.paradoxplaza.com/forum/...ehicle-Realism
    Dude, I totally looked at your link and totally was not interested, what gives?

    I got less congestions and nice ROI that's all I cared about. I told people how I achieved it. What is there to see at your link regarding that? Nothing but a unreadable list of numbers, and a mod that is not doing what I did.

  18. #18
    @Schweinehirt: Do I need to delete "metro.gs" or replace it with the new one created?

  19. #19
    Sergeant
    Cities in MotionCities in Motion 2Crusader Kings IIEU3 Complete500k club

    Join Date
    Feb 2011
    Location
    Germany
    Posts
    72
    Quote Originally Posted by Kopernikus79 View Post
    @Schweinehirt: Do I need to delete "metro.gs" or replace it with the new one created?
    neither. when you extracted the metro.gs to 'metro/' in your game directory, the game will look in the directory first before searching the metro.gs archive.

  20. #20
    Tried this one for a while, but found that while it did eliminate traffic on the first Vienna scenario, it also killed my number of passengers. I'm assuming this is because "the fix" simply makes fewer people need to travel.

    I found that renaming the metro-folder and trying with the latest patch was a more balanced solution.

+ Reply to Thread
Page 1 of 2 1 2 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts