Hacker News new | ask | show | jobs
by CyberDildonics 913 days ago
Why wouldn't you just make a game that runs in a browser at that point?
2 comments

Same reason why Electron exists, but in a much smaller bundle (since most of the actual browser engine wouldn't be included).

This would also be an opportunity to build better cross-platform APIs than what's available in browsers (e.g. WebAudio, fullscreen, pointer lock, text input (input in general), networking, ... are all a royal PITA on the web - basically any web API that isn't WebGL or WebGPU is mostly broken or half-assed).

That is what middleware is for.

So lets call it a game engine using JavaScript, instead of the usual ones.

If you want to call something simple like winit, GLFW or SDL a 'middleware' then yes. It definitely would not be a game engine in the popular sense like UE or Unity, those are way to bloated for most use cases such a minimal cross-platform wrapper would be good for. It would be something you could build a game engine on top though.
It's more a cross platform UI tooklkit built around web standards.
It would just be a nice way to turn your standalone WASM game into an .exe (or whatever equivalent) without needing too much extra stuff, like if you wanted to distribute a version on Steam, or offer multiple downloads like itch.io does.

It's nothing groundbreaking. It would just be a nice and convenient, is all.