• We have updated our Community Code of Conduct. Please read through the new rules for the forum that are an integral part of Paradox Interactive’s User Agreement.

Carlzilla

Private
76 Badges
Sep 9, 2014
14
0
  • Crusader Kings II
  • Impire
  • Knights of Pen and Paper +1 Edition
  • Hearts of Iron III
  • Pillars of Eternity
  • Magicka
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV
  • Europa Universalis IV: Common Sense
  • Cities: Skylines Deluxe Edition
  • Europa Universalis IV: Cossacks
  • Crusader Kings II: Sons of Abraham
  • Sengoku
  • Ship Simulator Extremes
  • Stellaris
  • Europa Universalis III: Collection
  • Europa Universalis IV: El Dorado
  • Cities: Skylines
  • Crusader Kings III: Royal Edition
  • War of the Roses
  • Europa Universalis IV: Pre-order
  • Mount & Blade: Warband
  • Crusader Kings II: Way of Life
  • Humble Paradox Bundle
  • Magicka 2
  • Crusader Kings II: Horse Lords
  • Cities: Skylines - After Dark
  • Crusader Kings II: Conclave
  • Cities: Skylines - Snowfall
  • Europa Universalis IV: Mare Nostrum
  • Cities in Motion 2
  • Europa Universalis IV: Art of War
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Legacy of Rome
  • Crusader Kings II: The Old Gods
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: The Republic
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Europa Universalis III
  • Divine Wind
  • Victoria 2
  • Europa Universalis IV: Wealth of Nations
  • For the Motherland
  • Hearts of Iron III: Their Finest Hour
  • Hearts of Iron III Collection
  • Heir to the Throne
  • Majesty 2 Collection
  • Europa Universalis IV: Res Publica
  • Semper Fi
I'm wondering if anyone has figured out a way to get a traffic figure from a specific section of road. I can get traffic counts for the entire map, but I can't figure out how to get it for a specific section of highway.
 
Get the nearest node number\index in question for the location in question (or the exact segment number\idx directly would be better\easier), enum though the node's segment list (up to 8) for each segment you can query m_trafficDensity (0-255) or m_trafficBuffer(0-65535) assuming you know which segment is the one you are looking for, or you can just add them up for the whole node. I forget which one holds what exactly, I think Density was more related to the color status in the infoManager, and the Buffer was actual number of vehicles currently 'buffered' on said segment.
 
Last edited:
  • 1
Reactions: