How exactly do video game developers adapt their games’ programming for different types of consoles/platforms?

642 views

Is there some form of re-usable asset/programing templates involved? And what happens if a new platform releases unexpectedly? (Like the Steamdeck)

What is the process and how do they stay up to date?

In: Technology

3 Answers

Anonymous 0 Comments

The compilers do much of the work.The code that programmers has to be translated to instructions that the console’s processors can execute, so a lot of it boils down to how it’s translated/compiled.

It’s a lot easier nowadays since consoles are running AMD chips that are not much different from a PC. Even the best compilers require programmers to bear in mind some of the differences between various architectures. If consoles and PCs run very similar hardware though, there’s fewer differences to account for. There’s still some platform-specific tweaking that needs to be done, but far less than there were in previous generations when consoles were completely different from PCs.

Anonymous 0 Comments

The Steamdeck isn’t a new platform, it’s just a shitty PC. For the most part, modern consoles all use the same architecture, so there isn’t any need to adapt. When there is a need to adapt for a system that uses a different architecture, most of the time it’s only a matter of recompiling using a compiler designed for the target system.

Anonymous 0 Comments

Former game developer here,

There is a lot of variability, so answering this question isn’t terribly straight forward.

Most of the work is done by engine developers. Game developers use engines as a product and don’t modify the engine code much, though there may be a number of variables one can tweak to change it’s characteristics. Most of the code a game developer is going to write is gameplay logic, like that cool game mechanic that’s central to the game; this code isn’t going to change per platform.

What does change the most is fine tuning to fit the capabilities and performance profile of the target. This could mean adjusting polygon counts, or texture sizes, more or less pre-processing, enabling or disabling render features, changing the depth of view, and even reorganizing the data to capitalize on how data is loaded, how big cache sizes are, bus widths and latencies, etc.

All of this is going to be made to be configurable so that it doesn’t take a developer to make a change, you can adjust a parameter in a config file. That doesn’t mean that these parameters are runtime configurable, the configuration may very well require a recompilation of the software – the configuration may be baked into the source code.

The goal is to write modular software that is easy to customize. For example, the x86 PC processor has some handy vectorization instructions where it can perform multiple multiplications at the same time, so where that comes up, you want to be able to use that. Other platforms, like the ARM processor since at least the ARM6(?) has had par-analog circuits. That is to say, you can perform differentiation using voltages and convert that analog voltage to a digital value, which will give you an approximate result, and then use a Monte Carlo simulation to march the value to the level of precision that you need. This can be much, much faster than computing digitally from scratch. For everything else, you just use a generic multiply instruction and hope for the best.

There will be many customization points built into the engine like this, and many layers of abstraction built on top that are principally concerned with deducing the right strategy and modules for you. I don’t have to see low level floating point numbers and multiplication methods, I just see a physics object and I can describe calculus equations in terms of the provided vectors and matrices.

So there is work like this that has to be done, but it tends to be done by the engine developers, and it tends to be per console/generation, and not per game. That doesn’t mean the engine developers aren’t looking for ever more improvement to their engines, so an early console game will be less performant and featureful than a late console game. But we see the biggest jumps occur with the release of new generations. And it shows – game engines are focused on consoles, so when they get better, PC games get suddenly a lot better, even though PCs have superior hardware to game consoles, because PC games are often built on console-centric engines.