Hope this doesn't offend anyone, that's not my int...
# linking-together
r
Hope this doesn't offend anyone, that's not my intention, but I do think this is one of the most effective and concise ways of illustrating the absurdity of the relative capabilities of various technology stacks. And I don't even think the web comes up as a loser in those comparisons. E.g., if game engines are so good, why aren't more tools like Figma or Framer built in them? https://www.theolognion.com/unreal-engine-5-is-meant-to-ridicule-web-developers/
c
Graphics demos are relatively easy to write for how impressive they look. Actual games, having to deal with the complexity of user interactions and complex state are in my experience just as hacky and messy as every other piece of complex software
m
But this article is just a joke, parody, right?
šŸ‘ 4
r
Absolutely, state management in particular is a completely different ballgame. I suppose the answer to my original question is probably obvious, web apps and Electron apps just don't need the same performance level as games, the popularity of existing apps that use these technologies proves that.
i
if game engines are so good, why aren't more tools like Figma or Framer built in them?
That's a great question, and there's a good answer. Web-based tools like Figma and Framer do use a lot of the same graphics tech as games, just applied to 2d graphics instead of 3d graphics. For instance, the layer compositing in all modern browsers happens on the GPU. If you stick to using CSS Transforms instead of flow-based positioning, your positioning happens entirely in the compositing step, GPU-accelerated, and you get a huge perf boost. You can make some highly complex HTML-based scenes that are animated at a buttery 60fps, even on mobile. The thing is, there are very few kinds of jobs that you need to do on the web that benefit from GPU acceleration, the way it's currently implemented. And that's where you feel the perf hit. But that's also where you feel the hit in games, too! I think a good way to appreciate this is to come at it from the other side — what are the things that happen in games that show just how weak these engines are when you look at things other than the graphics pipeline? There's.. a lot. In fact, most of the things that game engines do.. aren't great, especially when compared to graphics. I think the state of animation and physics in modern games is particularly appalling. Havok is awful — it's unnatural, ugly, slow, and often sucks the fun out of gameplay. The graphics pipeline has improved many orders of magnitude over the past 30 years. The similar explosive growth of physics stalled out around 20 years ago, and has only improved incrementally since then.
šŸ‘ 6
s
Different priorities
One thing about this demo is that it's running on a PS5, which is "commodity hardware" (well it will be in 6 months) but new consoles have a ton of advantages over any other consumer platform when it comes to showcasing high compute applications
šŸ‘ 1
Lower level system access(console games run in ring zero), custom hardware. PS5 has a custom SSD with hardware kraken decompression and it beats any PC SSD on the market in terms of bandwidth
I'm sure this demo runs on a high end PC fine
All this tech has a much higher skill ceiling to use than web, so you end up losing developer efficiency, you need graphics PHDs and 20+ year industry veterans to do 10 years of research to build systems like this
šŸ‘ 3
The only equivalent in web tech companies is in ML research
Web is successful because you can throw a bunch of relatively smart new grads at a code base and end up with a working application that runs on pretty much anything
šŸ‘ 3
Safety is also a big concern, so the web trades a lot of performance for safety, a lot of web developers can only really think in terms of computers being attack surfaces for bad actors because the web consumes arbitrary code and content from any remote machine, games don't do that, and safety is less of a concern
šŸ‘ 5
Web also cares a lot about legacy things working, sure many things are deprecated but most of HTML and JavaScript are still kind of the same with new features added
@Ivan Reese I disagree that animation and physics are appalling, less so with physics
Animation is consistently improving and has come a long way, even though you could argue it still doesn't get as much love as rendering
Physics has a ton of interesting developments, they just aren't used in games
But rigid body dynamics are very sparingly used in most games for gameplay reasons
So there hasn't been a ton of demand for better physics engines
VR has pushed things forward a little bit because tracked controllers finally give us an interface that makes playing with physics fun instead of awkward, but it's mostly about improved usage of existing rigid body dynamics rather than brand new techniques... Gameplay code not physics code
šŸ‘ 1
But if you look at research in position based dynamics or MPM in film, or using ML for physics acceleration, there has been a lot of interesting development in physics
šŸ‘ 1
Once again none of it or very little makes it to production games because "better" (more realistic? More expensive? More destruction) Physics don't fit in popular games genres, in the sense that they can actually detract from what makes the game fun
And maybe indies could use this stuff, but it's not very accessible because of difficulty of implementation or lack of knowledge
r
I'm no expert in game engines, but intuitively I'd expect them to be the state of the art for physics and animation. Which begs the question, if games are not the state of the art for physics and animation, then what is?
i
Once again none of it or very little makes it to production games because "better" physics don't fit in popular games genres, in the sense that they can actually detract from what makes the game fun
I don't think that's it. I think it's an economics thing. The penalty springs in Halo 1 was the most fun-feeling physics of any game in the series. The way Havok handles restitution feels so damp and sticky and crunchy by comparison, and all the sequels are worse for how they used it. But developing a custom physics solution tailor-made for each game is way more expensive than licensing middleware and tweaking parameters, right? It's like using an off-the-shelf character controller as opposed to writing your own. That's why games like Celeste feel so much better than your run-of-the-mill indie platformer — custom physics and a custom character controller, designed hand-in-hand as an essential facet of the gameplay. I'm simplifying, of course. It's possible to make a game use Havok and not feel awful (Breath of the Wild, say). But that depends on the gameplay, creative direction, etc. etc.
šŸ‘ 4
I just wish the range of expression, and the variability in quality and style, was as great in animation and physics as it is in graphics. In the 90s, when physics and animation basically had to be custom built for each game by the game's dev team, guided by the creative direction for the game, we had games like Mario 64 and Crash Bandicoot coexisting,Ā with wildly different approaches in look and feel. Now, everything looks like bog-standard RK4 IK and Havok or PhysX, with the occasional flirtation with new ways to do foot or hand planting, blending, soft bodies, etc. Even cuphead, which went to tremendous lengths to look like a classic cartoon, didn't do anything to feel like one. I'd like to see more games like Rain World or Noita.
šŸ’Æ 5
w
@Ivan Reese I was looking for the Celeste reference. Game feel is easy to undervalue since it's subtle.
s
Gameplay physics in most popular games I can think of is custom though, collision is often handled by a physics engine, but everyone writes a custom character controller unless they're hobbyists
Depends on how you define state of the art, real-time is different than offline, film is more state of the art in animation and simulation but they can spend hours per frame so it's not exactly equivalent
Physics engines used by industrial or scientific computing applications are way more accurate
y
Game engines, being built for games, have a lot of in-built premises that make them difficult to use for apps, the same way a web framework might. As we know, frameworks can be hard to extend and adapt when your usecase is different from the happy path. Certainly web apps could perform better, I get pretty frustrated with them myself too. But it’s also worth noting that: • games usually hog most system resources • browser apps need to run on a huge spectrum of hardware profiles • game developers have a huge amount of control over the execution environment that browser devs don’t. Browsers are political constructs as much as they are technical ones. • There do exist performant web apps • There do exist shitty games Changing the status quo of web development is a much bigger hairball of political, developmental, and technical problems than a lot smug system programmers would care to admit.
šŸ’Æ 4
s
The initial article is satire, so it’s probably not the best anchor for a serious conversation. However, if we had a serious conversation, I’d be missing the notion of waste. There are developers who care about coding in a way that ā€œminimizes wasteā€, in the sense that they try to use system resources sparingly and effectively. And there are those that don’t. That is partly based on the developer’s mindset. And it is partly based on what the tools and environments offer to make you aware of wasteful behavior and how they incentivize you to minimize it. Some environments encourage you to minimize waste, for instance by showing you a frame rate and making you want to hit 60fps or by limiting you to a tiny amount of memory. Other environments do the opposite, hide metrics like this, and support you in not caring. That is often beneficial when you want to avoid the additional complexity, for instance when learning. There are both kinds in both games and web development (and pretty much anywhere). And note that I haven’t defined waste — it’s easiest to understand as manifested in performance, but it goes beyond that.
šŸ° 4
c
One thing I find interesting is how if you use an outrageous hack, i.e. achieve what you want by doing things the wrong way - a brittle, special case solution using a tool differently to how it was intended - then in webdev it's seen as shameful, embarrassing, and a sign of a bad developer, whereas in gamedev it's seen as delightful genius and a sign of a great developer
šŸ¤” 2
If you did something like passed data by setting the window.title, but then changed it back before it was rendered, this would be laughably bad, but the "gamedev war stories" YouTube series is full of the equivalent misuse of APIs
s
Hacks tend to be more acceptable in game dev due to the old business model of shipping a game, and the game being mostly a finished product
Web software has always been software as service that needs to be maintained over time, so one off hacks aren't desired
You can't get away with hacks with a more modern software as service style game as much
šŸ‘ 1
The hacks are (often) the first thing to go when starting a sequel or a new game with the old code base, it's a lie that all game code is always garbage and game developers never refactor
šŸ‘ 1
w
To make room for new hacks!
🐣 2