r/odinlang • u/concerbed • 16h ago
Windows installer for the Odin Programming Language + MSVC and Windows SDK (by Karl Zylinski)
r/odinlang • u/concerbed • 16h ago
r/odinlang • u/DarekBomb411 • 23m ago
Hello, this is a half rant post and a half question post. I am a bit new to all this "low level programming" stuff. I first tried to learn zig, but it's problem is the same one that this post describes, taken to an extreme. I then tried Go and it was better but it still had the same exact problem, and I found its whole package model to be very annoying, and I wanted to try manual memory management. So I am now trying out odin, but it too falls short in one crucial area that so many others do as well. Eventually I got so fed up with this seemingly easily solvable problem that here I am, making a post just to shit on half of all programming languages in existence, as they all have it.
The problem is a lack of useful tutorials to help people learn.
To demonstrate, let's take me trying to learn zig as an example:
I then decide that Go might be a nice language. I hear people talk about it:
I then move on and try out Odin, as apparently its similar to Go:
As you can see, I am a bit upset just in general. I can and have made a 16 bit computer by hand out of logic gates (in a logic simulator, i dont got money for breadboards) but cannot make a simple flappy bird clone because apparently no one knows how to teach people anything. This is bullshit. I'm done. I quit. I'm deleting my flappy bird. Was pretty shitty anyway.
The moral of the story is simple: People who are great at a subject cannot teach it for the life of them, and people bad at a subject are amazing at teaching it. Almost none can do both.
So that brings me onto my final point: can anyone prove me wrong? Does literally anyone know of a tutorial/guide for odin (well maybe others but I preferred odin the most out of these three) that truly does start from the basics without assuming I know X Y or Z ahead of time? (because clearly I don't)
Maybe this is just a skill issue on my part, and I'm just a bit dumb. Maybe I'm not. I don't know. That is why I made this post.
Thanks
r/odinlang • u/Lucky-Space6065 • 8d ago
Running on an odin and open gl engine.
r/odinlang • u/Tolasmond • 7d ago
Scanned Card Cutter finds the cards on a scan, lets you check and adjust each one with a live preview, and saves every card as a PNG with transparent rounded corners. It can also remove the moiré pattern that printed halftone dots leave on a scan.
It is a small desktop app written in Odin with raylib, and it builds with only what ships with Odin. It runs on Linux, Windows and macOS (untested).
r/odinlang • u/marianpekar • 8d ago
It took a bit longer than usual. I wanted to have Part VII done by the end of October, but life got in the way :).
r/odinlang • u/y0shii3 • 8d ago
I have been curious about learning Odin lately, and reading through the docs, I cannot find anything about initializing constant variables with runtime values. It seems like :: only works at compile time, and if you assign from a runtime value with :=, the variable is always mutable? Doesn't that slow you down sometimes, not having a way to know that a variable isn't modified without checking through the whole scope? Or have I just not read the docs right?
r/odinlang • u/c0gster • 9d ago
Hello, I am very new to Odin, and I first wanted to get my editor (vscodium/vs code) to properly warn me about errors, provide suggestions for stuff, tell me what arguments functions take in, etc etc.
I installed the language server from https://github.com/DanielGavin/ols and also the VS Code "Odin Language" extension by DanielGavin. Initially it seemed to work, but it seemed to only update its analysis and suggestions of the code when I saved the file which is extremely annoying.
I did some research (aka asking chatgpt how to do it because usually its way faster than reddit and I wanted to get on with my day dont judge me) and found that I needed to create an ols.json file in my project root and put this in it:
{
"collections": [
{
"name": "core",
"path": "/path-to-odin-folder/core"
},
{
"name": "vendor",
"path": "/path-to-odin-folder/vendor"
}
],
"enable_checker_only_saved": false,
"enable_checker_on_change": true,
"checker_on_change_delay": 400
}And it seems to work! It updates immediately without me needing to save the file.
However, creating this ols.json for every single project I open is pretty annoying, considering that I probably won't have it do anything else besides this one specific thing. I wasn't able to find any answer online on how to get this to work without each project having an individual ols.json file, so I came here to ask how I can do it.
Thanks
r/odinlang • u/Additional_Name_706 • 12d ago
A few months ago, I posted this:
not a fluid sim, not ecs : r/odinlang
So, I'm just here for a little progress update.
I've made a lot of improvements to the core engine but the majority of the codebase is now gameplay scripting...
The playtest is open, if you'd like to try it.
r/odinlang • u/Inevitable_Stock2807 • 13d ago
Hello guys, what is the best practices to handle error in Odin? Is Go-style is the best way if err != nil but Odin doesn't allow shadowing variable.
note: Sorry my for my poor English and thank you.
r/odinlang • u/gruntastics • 14d ago
r/odinlang • u/DarthBheed • 18d ago
Eski is a single-node in-memory store with an Odin engine that speaks RESP, so Redis clients connect unchanged: the full single-node command surface including streams, geo, ACLs, persistence and Lua scripting with Functions, minus replication, Sentinel and Cluster. Apache-2.0, one static binary.
r/odinlang • u/itnufc • 17d ago
r/odinlang • u/KarlZylinski • 20d ago
Highlights: Mipmap support and texture wrapping settings. Tested with Odin dev-2026-11
Karl2D is a library for creating 2D video games. It has few dependencies (tries to stay in Odin land) and emscripten-free web build support.
r/odinlang • u/Similar_Place6762 • 23d ago
r/odinlang • u/bbcalado • 23d ago
After using Odin for some time, I discovered the odin doc command, that turns any odin file or package into a documentation view. This is a very useful tool during development for me, and i am pretty sure this was inspired by Golang's go doc, which is also a great tool. But, in my humble opinion, Odin's tool was lacking a few things.
First off, the output formatting. I simply do not like how it looks, it's very difficult for me to read because there is too much indentation and info.
For example, if you run odin doc core:strings, you get this:
package strings
A `string` builder, as well as procedures to manipulate `UTF-8` encoded strings.
procedures
_intern_get_entry :: proc(m: ^Intern, text: string, loc := #caller_location) -> (new_entry: ^Intern_Entry, err: runtime.Allocator_Error) {...} /* 33!3390 */
Internal function to lookup whether the text string exists in the map, returns the entry
Sets and allocates the entry if it wasn't set yet
*Allocate using the Intern's Allocator (First time string is seen only)*
Inputs:
- m: A pointer to the Intern struct
- text: The string to be looked up or interned
- loc: The caller location for debugging purposes (default: `#caller_location`)
Returns:
- new_entry: The interned cstring
- err: An allocator error if one occured, `nil` otherwise
ascii_set_contains :: proc(as: Ascii_Set, c: byte) -> (res: bool) {...} /* 34!1122 */
Determines if a given char is contained within an Ascii_Set.
Inputs:
- as: The Ascii_Set to search.
- c: The char to check for in the Ascii_Set.
Returns:
- res: A boolean indicating if the byte is contained in the Ascii_Set (true) or not (false).
...Of course, you can run odin doc -short core:strings, which outputs this:
package strings
A `string` builder, as well as procedures to manipulate `UTF-8` encoded strings.
procedures
_intern_get_entry :: proc(m: ^Intern, text: string, loc := #caller_location) -> (new_entry: ^Intern_Entry, err: runtime.Allocator_Error) {...} /* 33!3390 */
ascii_set_contains :: proc(as: Ascii_Set, c: byte) -> (res: bool) {...} /* 34!1122 */
ascii_set_make :: proc(chars: string) -> (as: Ascii_Set, ok: bool) {...} /* 34!639 */
builder_cap :: proc(b: Builder) -> (res: int) {...} /* 36!9132 */
builder_destroy :: proc(b: ^Builder) {...} /* 36!5973 */
builder_from_bytes :: proc(backing: []byte) -> (res: Builder) {...} /* 36!7088 */
builder_from_bytes :: proc(backing: []byte) -> (res: Builder) {...} /* 36!7088 */
builder_grow :: proc(b: ^Builder, cap: int) {...} /* 36!6223 */
builder_init_len :: proc(b: ^Builder, len: int, allocator := context.allocator, loc := #caller_location) -> (res: ^Builder, err: runtime.Allocator_Error) {...} /* 36!3838 */
builder_init_len_cap :: proc(b: ^Builder, len, cap: int, allocator := context.allocator, loc := #caller_location) -> (res: ^Builder, This looks better, but i still don't like it.
So, i decided to change a few things in the compiler and now, if i run odin doc core:strings, it outputs like this:
package strings
A `string` builder, as well as procedures to manipulate `UTF-8` encoded strings.
[procedures]
_intern_get_entry :: proc(m: ^Intern, text: string, loc := #caller_location) -> (new_entry: ^Intern_Entry, err: runtime.Allocator_Error)
ascii_set_contains :: proc(as: Ascii_Set, c: byte) -> (res: bool)
ascii_set_make :: proc(chars: string) -> (as: Ascii_Set, ok: bool)
builder_cap :: proc(b: Builder) -> (res: int)
builder_destroy :: proc(b: ^Builder)
builder_from_bytes :: proc(backing: []byte) -> (res: Builder)
builder_from_bytes :: proc(backing: []byte) -> (res: Builder)
builder_grow :: proc(b: ^Builder, cap: int)
builder_init_len :: proc(b: ^Builder, len: int, allocator := context.allocator, loc := #caller_location) -> (res: ^Builder, err: runtime.Allocator_Error)
builder_init_len_cap :: proc(b: ^Builder, len, cap: int, allocator := context.allocator, loc := #caller_location) -> (res: ^Builder, err: runtime.Allocator_Error)
builder_init_none :: proc(b: ^Builder, allocator := context.allocator, loc := #caller_location) -> (res: ^Builder, err: runtime.Allocator_Error)
builder_len :: proc(b: Builder) -> (res: int)
builder_make_len :: proc(len: int, allocator := context.allocator, loc := #caller_location) -> (res: Builder, err: runtime.Allocator_Error)
builder_make_len_cap :: proc(len, cap: int, allocator := context.allocator, loc := #caller_location) -> (res: Builder, err: runtime.Allocator_Error)
builder_make_none :: proc(allocator := context.allocator, loc := #caller_location) -> (res: Builder, err: runtime.Allocator_Error)
builder_replace :: proc(b: ^Builder, old, new: string, n: int, loc := #caller_location) -> (replaced: int, err: runtime.Allocator_Error)I decided to indent the symbols (procedure names) according to largest symbol on the AST list and removed the tabs that cause that indentation. I also removed the function location info at the end. Now i actually find the results satisfactory.
It doesn't stop there, on the Golang side, you can search for specific symbols in the package and see an isolated documentation view for it by typing go doc os.Stat for example. So i decided to implement the same thing in Odin
Now, when i run something like odin doc core:strings.clone, it shows this:
package strings
clone :: proc(s: string, allocator := context.allocator, loc := #caller_location) -> (res: string, err: runtime.Allocator_Error)
Clones a string
*Allocates Using Provided Allocator*
Inputs:
- s: The string to be cloned
- allocator: (default: context.allocator)
- loc: The caller location for debugging purposes (default: #caller_location)
Returns:
- res: The cloned string
- err: An optional allocator error if one occured, `nil` otherwiseThis works for any kind of symbols including types, constants, variables, proc groups...
I was actually pretty proud about this, although, the code is still rough and need some organization
But i was curious about the people from this sub. Is this actually useful for you? Do you think this improves your Odin experience?
r/odinlang • u/Minute_Ambassador751 • 24d ago
Been working on hnoss for a while: an immediate-mode TUI library, no C, no ncurses, just Odin. Would love your feedback!
r/odinlang • u/emonshr • 25d ago
Anyone doing odin with tauri? Any native odin equivalent? (just jealous of tauri)
Please share your experience if you are using Skald too.
(I wasn't talking about embedding chromium with some custom solution)
r/odinlang • u/sqruitwart • 26d ago
I love odin and would like to continue with it as my language of choice. I managed to implement in one afternoon what took me a week in C++ (mostly fighting RAII magic).
One thing I miss are variadic parameter packs and tuples. Tuples exist as function return types and structs can be unpacked, but they cannot be used otherwise to be passed as generics - I do not understand why and can only find very old reddit posts on this topic.
I managed to hack tuples together by using codegen and structs like Tuple_0, Tuple_1, etc that have generic fields + a monster proc for compile-time indexing, but it gets tedious to work with.
Does anyone know any replacements / implementations of a heterogeneous collection of data types for odin I can take a look at?
r/odinlang • u/Morphon • 26d ago
Cross-posting this here. I'm learning the language through puzzles. Mods, feel free to delete if this kind of thing isn't useful for the sub.
Odin has been fun to learn so far. Way, way outside my comfort zone - but having a blast just the same.
r/odinlang • u/KarlZylinski • 28d ago
The previous release happened just before the Karl2D jam. That was almost half a year ago! That jam gave me sooo much good feedback. In this release you can see a lot of that work. Thank you everyone for trying my library, for the feedback and for the pull requests! Highlights:
get_typed_runes)r/odinlang • u/Tolasmond • 29d ago
zelbyn is a data-driven binary file reader written in Odin. It decodes a file with a Kaitai Struct .ksy schema and writes the decoded tree to stdout, as a text dump or as JSON. Also supports Odin code generation.
r/odinlang • u/TinyPixelDev • Oct 24 '26
I just released my game made with my custom engine made with odin, and I really want feedback to fix and improve my game dev skills, I know the game design is simple and nothing new, but still its a good test. any feedback or bug reports is really appreciated. thanks
r/odinlang • u/KarlZylinski • Oct 23 '26
I think this is my final re-design of the Karl2D Audio API. This design is optimized for the most common case. It's easy to play one-off sound effects using `play_audio_stream`. You can play the same clip many times simultaneously.
Audio streams (music) now have their own API that is easier to use.
There is also a `Sound` API. You make a `Sound` using `create_sound` which you feed an `Audio_Clip`. Sounds are essentially audio clips that remember their settings between playbacks, and you can change the settings while the sound is playing. Many people don't need that because `play_audio_clip` can be fed settings to use for the duration of the playback. Only if you need to modify the settings while playback is happening do you need the `Sound` API.
`Sound`s, `Audio_Clip`s and `Audio_Stream`s all live as `Audio_Voice`s in the mixer. This is why one clip can be played many times simultaneously: It's several audio voices that all look at the same clip.