Day one was a few hours trying to set the groundwork for what the application will be (a server client thing with a lot of bells and whistles) and about 2 and a half hours trying (and failing) to make an echo server in Odin.

"But wait!" you interject, That's preposterous! An echo server is like 10-30 lines of code! The hello world of network connectivity functions!" And you would be right, if not for the fact that I am really bent on using nonblocking IO. Due to the way that io works in Odin (to my understanding), the default networking library (that is otherwise perfect for this) can't be used. Similarly the Linux server connections don't work. So I spent a lot of time just implementing a version of the example echo server with linux syscalls.

The problem with that is that I didn't understand how to return elements from the syscalls for a while, and just assumed that it returned what I wanted. In reality, intrinsics.syscall(syscode, args .. ) actually returns a POINTER to the value. Which is obvious when looking at the source code for return_errno inside sys/linux, if I had bothered to check sooner.

It just occurred to me that I could probably just use the net library, figure out the underlying code for initializing the socket, and make a nonblocking io version, rather then directly calling the kernel for everything. Ah well, it's given me a lot to think about.

So! The point is, I suppose, I should stop dragging my heels and read the example/source code whenever I get stuck, at least in a timed environment like this one. Although since there isn't any nonblocking io code for Odin that might prove a problem. Anyway, tomorrow I'll put the networking to the side and try implementing a 100% local version of things. After all, I've heard that you should always implement local multiplayer before trying networked stuff. (It may be a different design space with different restrictions but cut me some slack I need a lead!)

TL/DR: Due to stubbornly trying to implement networking first, in a way not entirely natural to the language I'm working in, and an amount of hubris inversely proportional to my skill, today was a bust aside from some application design.

ADDENDUM: I went back to the project, and realized that due to having such a wide scope(and staying up late), it was hard to get a grasp on the problem space. Code skeleton and a more solid understanding of the abstract should help here.

This project is being streamed live on my youtube channel: https://www.youtube.com/@TekniMiasmata