Hacker News new | ask | show | jobs
by skimmed_milk 15 days ago
This is cool, it could be a neat way to get Love2d games on the web with wasm
2 comments

I'm currently learning to make games with love2d. I'm using love.js to deploy for web. Would this have some advantage over love.js?
Probably not today.

Love.js is already a mature solution for running Love2D games in the browser through WebAssembly. Clx currently focuses on ahead-of-time compilation to native executables rather than web deployment.

The idea I was referring to is more about native distribution: compiling Lua code into standalone executables without requiring a Lua runtime on the target machine.

That said, if Clx eventually gains a WebAssembly backend, it could become an interesting alternative path for Lua-to-web deployment.

That would be interesting!

Since clx generates portable C++, targeting WebAssembly through Emscripten is theoretically possible.

The challenge is that Love2D does not really expose its backend as a reusable library.

A more natural fit could be a game library like SFML or raylib, used as the base of a game engine provided as a third-party clx module.