Choosing an engine / framework for a 404 error page game 2

FlipBit • 5 days ago on 16th Kajam 

There was a small discussion about the requirements for the 404 error page and what I'm taking away from it is that I will try to make a very small game, hopefully around 2 MB altogether.
I aim to keep the footprint minimal and use the tools I like, which excludes JavaScript frameworks.
I'm going with Sokol and Odinlang. I haven't really tried Sokol properly, so this will be a learning experience and I'm looking forward to it!

This is the gist of it. Everything else is just notes and rants you might want to skip.

JS frameworks I find interesting

Although I don't want to use JS I thought in the spirit of serving the user and not just myself, I should have a look at what's out there in the world of minimal JS engines and frameworks. Maybe that would change my mind, if there was something overwhelmingly well suited to the task of creating an HTML5 game.

  • https://melonjs.org Very small and self contained 2D game framework, but it looks fairly limited at first glance
  • https://createjs.com A handful of libraries for interactive experiences and they look minimalistic and straightforwand in the exact way I want
  • https://pixijs.com 2D web graphics framework with an optional audio module
  • https://p5js.org The JS version of Processing and not really a classical game engine, more a creative coding environment
  • https://www.babylonjs.com I'm not sure if this fits my "no NPM-hairballs" requirement, but it looks very capable

What I clearly don't want to use: Phaser, Playcanvas, GDevelop, ct.js and loads more

While those projects aren't necessarily bad, they don't fit my prerequesites: I want to host the game on my server / itch.io, not some sharing platfrom dictated by the framework. I don't want to create an account anywhere. I want to quickly download very few, small JS files, include them in my HTML file and hack away. I absolutely and under no circumstances want to npm install anything!

After looking through the options I might actually try out some of those frameworks at some point in the future. I mean a browser really is a platform for interactive media these days and ships with loads of useful stuff.

What I'm actually using

I wasn't quite sure how to approach this, because some libraries I usually use (like SDL) tend to create relatively big files for the web. Also I sure am not going to use Godot with an insane minimum web deployment size of 50 MB! This is fine if someone wants to explicitly play a web game, but it's obnoxious if it is more or less forced down your throat via an error page.

Using Sokol and Odinlang I can get the boilerplate Javascript and WASM module to compile to around 1.2 MB (no minification applied yet). If I can generate most of my assets procedurally and make a tiny game, then I think 2 MB should be doable. Wish me luck!

Comments (2)

Mobuos
 • 3 days ago • 

Nice! I myself will also use Odin, although not with Sokol or SDL. I'm going a bit higher level, but still lower than what I'm used to in Godot, with Raylib! It will be my first experience with Odin.

Wishing you the best of luck!

FlipBit
  • 3 days ago • 

@Mobuos Cool, I'm looking forward to seeing your progress and your game! Good luck to you too!

Login to comment