Anatomy of a Game: Startup and Loading

Med1980

Second Lieutenant
113 Badges
Feb 3, 2007
132
53
  • Supreme Ruler 2020
  • The Kings Crusade
  • Majesty 2
  • March of the Eagles
  • Europa Universalis III Complete
  • Europa Universalis IV: Res Publica
  • Victoria: Revolutions
  • Europa Universalis: Rome
  • Rome Gold
  • Semper Fi
  • Sengoku
  • Ship Simulator Extremes
  • Sword of the Stars
  • Lead and Gold
  • Victoria 2
  • Victoria 2: A House Divided
  • Rome: Vae Victis
  • 200k Club
  • 500k Club
  • Cities: Skylines
  • Cities: Skylines Deluxe Edition
  • Crusader Kings II: Holy Knight (pre-order)
  • Europa Universalis III: Collection
  • Europa Universalis IV: El Dorado
  • Europa Universalis IV: Pre-order
  • Europa Universalis 4: Emperor
  • Deus Vult
  • Hearts of Iron II: Armageddon
  • Cities in Motion 2
  • Crusader Kings II
  • 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: Sons of Abraham
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Sword of Islam
  • Commander: Conquest of the Americas
  • Arsenal of Democracy
  • Europa Universalis III
  • Divine Wind
  • Europa Universalis IV
  • Europa Universalis IV: Art of War
  • Europa Universalis IV: Conquest of Paradise
  • Europa Universalis IV: Wealth of Nations
  • For The Glory
  • For the Motherland
  • Hearts of Iron III
  • Heir to the Throne
You mentioned Linux and the performance with respect to open small files compared to Windows. I was wondering, is there any difference in the loading time between MS Windows and Linux? Actually, it would be interesting to have an “Anatomy of a Game” regarding the port to minor platforms, the compilers used (MSVC and GCC I imagine), DirectX vs OpenGL vs Vulkan (vs Metal), etc. In my (small) experience supporting different platforms is really useful to squash hard-to-find bugs and keep the code clean enough.
 

blackninja9939

Experienced Programmer - Crusader Kings 3
77 Badges
Aug 28, 2013
2.366
6.066
  • Crusader Kings III
  • Stellaris: Federations
  • Battle for Bosporus
  • Stellaris: Nemesis
  • Stellaris: Necroids
  • Europa Universalis IV
  • Crusader Kings III: Royal Edition
  • Europa Universalis 4: Emperor
  • Crusader Kings II
  • Crusader Kings II: Holy Fury
  • Imperator: Rome - Magna Graecia
  • Crusader Kings II: Charlemagne
  • Crusader Kings II: Rajas of India
  • Crusader Kings II: Sons of Abraham
  • Crusader Kings II: The Old Gods
  • Europa Universalis IV: Rights of Man
  • Europa Universalis IV: Cradle of Civilization
  • Stellaris: Synthetic Dawn
  • Surviving Mars
  • BATTLETECH
  • Europa Universalis IV: Mandate of Heaven
  • Crusader Kings II: Monks and Mystics
  • Tyranny: Archon Edition
  • Europa Universalis IV: Rule Britannia
  • Crusader Kings II: Reapers Due
  • Hearts of Iron IV: Colonel
  • Stellaris Sign-up
  • Hearts of Iron IV: Expansion Pass
  • Stellaris: Apocalypse
  • Stellaris: Lithoids
  • Stellaris: Distant Stars
  • Europa Universalis IV: Dharma
  • Shadowrun Returns
  • Imperator: Rome Deluxe Edition
  • Prison Architect
  • Imperator: Rome Sign Up
  • Stellaris: Ancient Relics
  • Age of Wonders: Planetfall
  • Crusader Kings II: Conclave
  • Crusader Kings II: The Republic
  • Victoria 2
  • Cities: Skylines
  • Europa Universalis IV: El Dorado
  • Crusader Kings II: Way of Life
  • Stellaris
  • Mount & Blade: Warband
  • Crusader Kings II: Horse Lords
  • Europa Universalis IV: Common Sense
  • Crusader Kings II: Sunset Invasion
  • Crusader Kings II: Legacy of Rome
You mentioned Linux and the performance with respect to open small files compared to Windows. I was wondering, is there any difference in the loading time between MS Windows and Linux? Actually, it would be interesting to have an “Anatomy of a Game” regarding the port to minor platforms, the compilers used (MSVC and GCC I imagine), DirectX vs OpenGL vs Vulkan (vs Metal), etc. In my (small) experience supporting different platforms is really useful to squash hard-to-find bugs and keep the code clean enough.
I'd have to get a Linux machine or have someone do a load compare, in general Linux loads faster than Windows from my prior experience on our games by a decent amount but run time is usually pretty comparable.

As for the porting to other PC platforms there is not a whole lot to say really, we use MSVC and Clang for compilers. DirectX and OpenGL with a future looking at Vulkan/Metal but that is all on our engine side, on the game team (and even a lot of the engine code) is just abstractions over that so we never need to directly mess with that ourselves. Otherwise we generally use portable code only, or if we do need platform things then again wrap it in one API that dispatches to the platform versions.

Most of the benefit I've found is that Clang catches bugs MSVC will let through as its a bit more strict on C++'s rules sometimes (though I'm sure a few of those MSVC ignores are due to some of our compile flags there). But its never world ending stuff really, but nice to catch though for sure as its objectively more correct programming wise. Otherwise its a lot of annoying bugs that are tedious to fix that only show up for a small % of users, we still aim to fix them but platform specific bugs are a bit of a pain ;)
 
  • 3
  • 1Like
Reactions: