r/odinlang • • Aug 23 '26

not a fluid sim, not ecs

404 Upvotes

Hello all,

Just posting a little progress update on my auto-battler/tower defense/idle incremental/online dueling deckbuilder in progress.

pure odin.

This is a stress test, 2 armies of 1 million soldiers clashing with wisps casting a few hacky spells.

The tech feels pretty good. I need to tighten up some of the sim values but I split the struct into 3 parts, hot, warm, and cold which has really reduced the GPU memory bandwidth. We were in budget but now we're roughly using half of what we were using.

Does anyone know how to turn this into a game? I didn't have much of a plan beyond tech demo.

There's a good chance I can make an online duel work.. I always thought a round-less Legion TD 2 would be cool...with battles scaled to the millions?


r/odinlang • • Jul 07 '26

Odin 1.0 Announcement

Thumbnail
youtube.com
362 Upvotes

r/odinlang • • 16d ago

I made a TUI library in pure Odin

197 Upvotes

Been working on hnoss for a while: an immediate-mode TUI library, no C, no ncurses, just Odin. Would love your feedback!

repo: https://github.com/Huseynteymurzade28/hnoss


r/odinlang • • 25d ago

10 months ago we picked Odin for our first commercial game. Last week it got a Steam page. Thank you, Odin!

Post image
172 Upvotes

10 months ago, my friend Markus and I had a bit of a crisis in our long-term game project. It was something we had worked on for 5 years in Unity, but as crazy as it sounds, we never found the core game loop of the game. At this point in the project, we had put sooooo many hours into it, especially building tech to support what we wanted to do. And to be honest, doing things we really shouldn't have done. I'm cringing saying this, but being a web dev, I even built an open source library for defining your game in a declarative manner, similar to how React does it. Looking back at this, it is also a tell that we had issues with the Unity way of building games (which we should either have embraced or switched engine).

By this time we had reached a point where we were both growing tired of Unity and its tech. Frustration was also growing since, even though the game was playable, it was very hard to explain to the very few friends who had actually been tortured into trying it out. At the same time, we both had a growing interest in learning low-level programming languages, and Odin in particular seemed like a very attractive candidate. With that said, we had some very heated and long discussions on how to proceed. The anxiety was brutal, since it felt like such a failure to start over after pouring all that time into the Unity project. At some point I was quite sure that we had reached a dead end and that the project would die. That's when Markus started doing some quick and dirty prototypes in Odin...

From a game design perspective we used some of the concepts from the old project, but we simplified them A LOT. We also made a throwaway prototype written in Odin and Raylib just to validate the concept, threw it up on Itch, and let some friends play it. It still ofc had issues, but we got a much better response than we ever had from the old project. This was of course very motivating, and after that initial phase we decided to pivot and make a new project in Odin. We also landed on using Sokol for integrating with the OS (thanks a bunch to Karl Zylinski and his open source repos for reference on how to set this up).

Here are some decisions we made early that I think have made our project successful. Keep in mind that our game is turn-based though, so some architectural decisions would most likely be different in a real-time game:

  • Separation of data and logic. All content and behaviours of the entities in our game are described in data and then acted upon in the engine.

  • Treat web as a primary platform. We compile the game to wasm and deploy it to our own custom playtest platform via GitHub Actions. This has significantly lowered the bar for inviting playtesters, which has been very valuable for validating the game and where we are heading.

  • Minimal integration surface with Sokol directly. We wanted to be able to easily switch to another way of integrating with the OS, so direct usage of Sokol is very limited and we instead wrap it in our own APIs.

  • Separate game state and visual state. This one is probably the most uncommon choice, and even though it was tough to enforce in the beginning, it has paid off big time as the project has matured. Basically, game state (the logical rules of the game) is stored in one place, while the data for its visual representation is stored separately. For example, a token in the player's hand has a value and a color, which are stored in game state, while visual state copies those values (since they are rendered) but also contains the position, scale, etc. of its rendered representation.

  • Serialization of game state. After each turn we serialize the game state and save it to disk (and send it to our server's analytics endpoint in the deployed web builds). This, combined with the ability to rebuild visual state from game state, makes it possible for us to start playing the game from any point in time in any playtester's run.

  • Playwright for e2e testing. Since we are building for the web, we can use Playwright to e2e test our game! All we needed to do was expose an API for interacting with the game from javascript. This has been so great for our game and is a breath of fresh air compared to Unity.

Here is a very high-level view of the game's architecture on each tick:

  • Input. Reads mouse, keys and touch and turns that into a command, i.e. a user intent like "attack this enemy", "end turn" or "select this token".

  • Commander. The queue the resolver drains every frame. Blocks or holds back certain intents based on the current state of the visuals (animations etc.).

  • Resolver and store. First checks if the command is allowed, and if it is, executes game logic according to the user action. Once processed, the game state is altered and a mutation result is returned and handed over to the next step.

  • Visual. The visual library takes the store and the mutation result and creates a visual entry that gets queued. No visual state has been changed yet, and from here on out, nothing is allowed to read game state. When the queued entry can be processed, we create animation entries that are processed each tick (I won't dive into the details of the animation code here). These animation entries either alter visual state directly (for example spawning a token) or alter a value in visual state over time.

  • Rendering. Draws the visual state through Sokol. Knows nothing about the game logic. It just draws according to the values it gets from visual state.

I could go on and on explaining different things we have implemented (and I might in the future), but I will leave it at that for now. Feel free to ask any questions you have about this setup and the game, and I will try to answer as best I can. Would love to hear how other people are approaching their projects.

The game is now on Steam (consider wishlisting if you like roguelike deckbuilders): https://store.steampowered.com/app/5300900/Starmax/


r/odinlang • • Jul 15 '26

fresh OC

Post image
161 Upvotes

r/odinlang • • Jun 27 '26

Quilt, developed with Odin & Raylib

145 Upvotes

r/odinlang • • Dec 22 '25

My first ever game, a creature-builder roguelike made using Raylib and Odin

145 Upvotes

Making a game in Raylib and Odin has been an absolute blast so far. I genuinely don't think I could've made it this far using anything else, or at least not in just 6 months. I came here to share my new trailer and some thoughts on the tools I used.

I really came to appreciate Raylib for it's simplicity. It allows you to gain deep knowledge about game programming instead of learning engine trivia, which was one of my main goals when I started this project. The code-only approach really lets me get into a flow state inside of my IDE and solve hard game-related problems, whereas I get quite easily distracted and frustrated trying to fiddle with GUI. The game also doesn't use almost any assets, so I don't find the lack of devtools an issue at all.

Odin just makes long solo project, which is usually a major pain in the butt, much more manageable. It's a humble language that takes a lot of simple, but useful concepts and implements them as user-friendly as possible. Essential things like enums, enumerated arrays, unions, switches, comptime load and assert, arenas, the core library and the build system itself all just work. Furthermore, the design lends itself to a procedural, data-oriented paradigm that works well for games. I also like the built-in Raylib bindings.

Anyway, here's the Steam page, if you like what you see, support me by adding to your wishlist!

https://store.steampowered.com/app/4188570/Biovoid


r/odinlang • • Dec 01 '25

Made a new trailer for my Game made with Odin

138 Upvotes

r/odinlang • • Aug 05 '26

BLICK - A video editor written fully in Odin

Thumbnail blickeditor.com
129 Upvotes

r/odinlang • • Nov 27 '25

Odin is the first language I have loved in forever

127 Upvotes

It is so simple. Everything is so easy. All the code makes sense and looks nice. My project doesn't contain a single JSON or TOML file. And you're telling me I can use C libraries?

I have the overwhelming urge to shill Odin. It is so good.

Sorry if you expected a post of substance.


r/odinlang • • May 27 '26

Experimental voxel FPS made with Odin + raylib

120 Upvotes

Hey everyone!

I've been working on a voxel FPS prototype in Odin with raylib, mostly to see how far I can push this setup for a 3D game.

It uses my own renderer r3d on top of raylib.

The latest update adds the first version of the map editor, so I made a short-ish video showing some editing, custom level loading, and gameplay.

The game is still early, but feedback is welcome, especially on the editor workflow, gameplay feel, or any ideas you think could make it better.

If there are any questions, I will answer them!

Itch.io: https://bigfoot71.itch.io/raze-protocol

r3d: https://github.com/Bigfoot71/r3d

r3d-odin: https://github.com/Bigfoot71/r3d-odin


r/odinlang • • Dec 06 '24

I've released a digital book called "Understanding the Odin Programming Language". If you want to learn Odin and demystify low-level programming, then this book is for you!

Thumbnail
odinbook.com
114 Upvotes

r/odinlang • • May 20 '26

I am happy to hear ThePrimeagen say that Odin and Zig are "very, very different languages"

111 Upvotes

A chatter asked how they compare in his stream today (ongoing as I write this) and I found it refreshing to hear.

I don't have anything against Zig, I like it quite a lot- it would probably be my language of choice were Odin not a thing, but it seems to be more or less impossible to read discussions about Odin without comparisons to Zig cropping up.

I've found this to be a tad frustrating because I also feel they're vastly different. I understand why people categorise them similarly, they're both systems languages with aims that roughly sound like "a nicer C with modern features," but I think you can only mistake them as similar if you haven't spent much time with one of them.

It feels like Zig often being mentioned when Odin is discussed connects a bit to what gingerBill said in his Marketing the Odin Programming Language is Weird blog.

Zig really does have the "killer features" that make the merit of a language easy to comprehend, which is something Odin lacks, and it is simple to rattle of those features when drawing comparisons.

In my experience with Odin, the accumulation of quality of life features, things you discover that simply make your life so much easier on the micro-scale, is what makes it such a pleasure to work with.

Those things will rarely mean much to someone who hasn't experienced them first-hand. I think that, rather than any actual lack of value, is one reason that discussions/comparisons often slant in Zig's direction. I've read so many comments from people that say something along the lines of "I just don't get the point of Odin" - which is not something I can say I've seen said about Zig.

So, it is nice to hear someone with an audience emphasise how different they are rather than leaning into comparisons that are unlikely to highlight what it is that Odin offers - even if it was just an offhand response to a viewer!


r/odinlang • • Jul 13 '26

YouTube: I tried Odin and I love it!

Thumbnail
youtube.com
104 Upvotes

r/odinlang • • Sep 09 '26

Try the new Karl2D Playground: You can edit and recompile the Odin code, directly in your browser!

Thumbnail
karl2d.com
100 Upvotes

Technical details: The Odin compiler runs in your browser. Even on your phone! This is enabled by an experimental Odin compiler fork called wodin: https://github.com/karl-zylinski/wodin

wodin has a WASM backend that lets it emit WASM directly, without LLVM. The Playground site runs wodin, which compiles the gameplay code and emits new WASM, which is the run within the browser. Note that wodin's WASM backend is AI generated: It's roughly 20000 lines of C++. Nevertheless, I am flabbergasted that this is even possible.


r/odinlang • • Apr 15 '26

3D Software Renderer in Odin from Scratch (Tutorials)

100 Upvotes

Hi, my name is Marian, and I've spent a year writing a series of tutorials on how to build a 3D software renderer in Odin from scratch, starting with a general overview of the rendering pipeline, then covering the basics, and progressing to Phong shading with multiple lights.

Everything is available on my blog for free, no ads, no paywall, no tricks. You can Buy Me a Coffee, and I'd very much appreciate it, but it's entirely optional.

Links to all 14 parts of the series:

And some examples:

I've also recently built a rigid-body physics engine on top of that, with two types of colliders, box and sphere, featuring raycasting, gravity, friction, bouciness, etc., and I'm currently working on the first part of a new series of tutorials to cover it all.


r/odinlang • • Jan 02 '26

Try my new 2D game creation library! It's fully written in Odin and meant to replace my need for Raylib. It features emscripten-free web builds.

Thumbnail
github.com
99 Upvotes

r/odinlang • • Mar 20 '24

I created "awesome-odin" github repo, to have one place with lists of all odin resources, libraries, bindings, gists, tutorials, and other useful things. Please submit your projects! :)

Thumbnail
github.com
98 Upvotes

r/odinlang • • Jan 02 '26

3D rendering in the terminal from scratch

92 Upvotes

First project using Odin, built entirely from scratch.
I'm really enjoying the language so far

Here's the repo


r/odinlang • • Jul 03 '26

Announcement Announcement

Thumbnail
youtube.com
90 Upvotes

r/odinlang • • Oct 08 '26

In this video I show how the compile times improved with the latest Odin release

Thumbnail
youtube.com
89 Upvotes

r/odinlang • • Aug 18 '26

Horde of one million spheres

89 Upvotes

Forgive the poor recording. It looks and feels super smooth native.


r/odinlang • • Feb 10 '26

R3D - Odin binding now available for my raylib 3D library!

88 Upvotes

r/odinlang • • Jan 16 '26

gingerBill: "I've just merged the non-block IO PR into Odin!!!"

Post image
87 Upvotes