I'm Creating a 2D Platformer Using Julia!

Hello everyone! I just wanted to post some progress about a small project I’m working on using my game engine written in Julia. I’m using this game as a reference, as I’m not worried about designing a game at this point. This project will be the example for the upcoming first user-friendly(ish) version of my engine. Without further ado, here’s the gameplay I have so far:

For anyone unaware, I’ve been working on a 2D game engine in Julia, and have been posting updates for projects here. Here’s the last post I made: I created an online multiplayer game with Julia!

35 Likes

Hey Kyle! Love what you’re doing keep it up!!

As you’re basically pioneering this I’m wondering how you are finding julia as a language for writing games? It seems to me like easy to write math with good performance and concise syntax is a really good combo for game dev. But how is it going in practice? Do you have problems with realtime and the GC, or is there anything else that’s particularly difficult currently?

4 Likes

Hey @Raf !

I love Julia syntax-wise. To be honest, I haven’t had too many, if any, issue with the GC yet. But I don’t think I’m at the point with the projects I’ve been creating for that to matter yet. I also haven’t dug too deep into performance yet to understand any bottlenecks I have. The main focus is to get it working right now, and then go back and find performance gains. As I’m not really creating something conventional by Julia standards, I’m sure there’s a lot of improvements I’ll be able to make to my code with very little effort.

As for other things, I think the hardest part of this is understanding Julia documentation, and finding code examples for when I get stuck. Dealing with the package ecosystem has been a struggle at times. Finding packages that are actually maintained (especially for game dev), have good documentation/examples, and that have the full functionality of their c/c++ counterparts (when they are bindings) feels next to impossible. But overall, I’ve been able to work past a lot of that.

Another thing is binaries. Obviously for games, I want to be able to run it on other people’s machines. I’ve been using PackageCompiler.jl, which has been great overall, but the binary size is pretty big for the size of the game I’m creating. Also, dealing with file paths with the builds on different machines was a nightmare, and still quite isn’t where I want it. Also, the builds take 10+ minutes on my main machine (i9-12900k), so any mistakes I make are pretty costly when I need to recompile my projects.

However, overall I am very satisfied with using Julia for game dev. I’m hoping I can make a solid 2d engine that people can use to learn Julia and how to make games fairly easily. It’s going to be quite a while until I get there, but hopefully next year I can build some momentum, and get some external contributors to the project.

11 Likes

I have no technical comment to make whatsoever, but amazing job!
This is really groundbreaking work and could attract a lot of people to the language and the community.

Keep it up and stay motivated, it will pay up!

2 Likes

Thank you!!

Thanks that’s really interesting feedback! Good for us all to be tuned in to what the actual problems are for various fields.

You’re not alone in the experience finding good dependencies when you’re doing something new. I’ve had to work on a lot of low-level tooling for spatial modelling that is easily available in other languages. The good news is jsut a few people can write a lot base functionality for a field in Julia, I couldn’t imagine doing that in another language.

Also it seems there is a bunch of work going into better binary compilation, hopefully that’s available to you in the next few releases to reduce those pain points.

3 Likes

No problem! Like I said, overall I am very happy with this so far. I am excited to see all of the upcoming improvements though!

Awesome job!!
I hope you keep the motivation to follow this through to the end!!

2 Likes

Thanks! Here soon(ish) I’ll create a post detailing how to use it so I can hopefully start gathering users.

1 Like


Figured some people would get a kick out of this. I have it running on a little handheld I have. It’s running at a glorious 12 fps haha.

9 Likes

Could some feedback on performance help that fps? I could have a look at JulGame if you like

3 Likes

That would be amazing. Whenever you get the time, I would really appreciate it. I was able to gain some fps by skipping sprites that were too far from the camera to be rendered. Also running that fps counter seems like it takes a couple of fps on that device so it feels like it runs a bit faster without it. But if somehow I could get a solid 40 fps on it that would be amazing. It’s powered by a raspberry pi 4 btw