15 votes

Moving my game project from C to Odin language

6 comments

  1. akselmo
    Link
    Hi there, another blogpost from me, wanted to go over in a rambly blogpost about my experience on moving my C game project to Odin. Feel free to ask me further questions and if they feel like...

    Hi there, another blogpost from me, wanted to go over in a rambly blogpost about my experience on moving my C game project to Odin. Feel free to ask me further questions and if they feel like something I could add to the blog, I will. :)

    7 votes
  2. [2]
    jmpavlec
    Link
    Nice post, been quite a while since I programmed in C. Were there any performance differences after building in Odin? Also you have a todo in your readme about linking to this blog post:...

    Nice post, been quite a while since I programmed in C. Were there any performance differences after building in Odin?

    Also you have a todo in your readme about linking to this blog post: https://codeberg.org/akselmo/artificial-rage

    TODO: Link here a blogpost about this whole C to Odin codebase movement

    7 votes
    1. akselmo
      Link Parent
      No performance impact as far as I know. Might be even better perf due to better dependency management. Also thanks for reminding me, will fix that ASAP lol.

      No performance impact as far as I know. Might be even better perf due to better dependency management.

      Also thanks for reminding me, will fix that ASAP lol.

      4 votes
  3. [3]
    Tuaam
    Link
    This is one thing I can get behind, besides the simplicity of building a program. I understand that Headers are essential in C due to how the language works but they're very cumbersome when you're...

    When it comes to removing unnecessary cruft, one of the biggest things that made me happy was lack of header files.

    This is one thing I can get behind, besides the simplicity of building a program. I understand that Headers are essential in C due to how the language works but they're very cumbersome when you're working with dozens of different functions where you need to update the header file and then the associated source file. And you can run into dependency hell very quickly if you're not using ifndef to structure your headers.

    4 votes
    1. [2]
      akselmo
      Link Parent
      I believe in C and C++, header files could be auto generated by the compiler most of the time.

      I believe in C and C++, header files could be auto generated by the compiler most of the time.

      3 votes
      1. drannex
        Link Parent
        They could also be automatically appended to the metadata on the object output, or even, a specified endpoint in the object itself to expose the available bindings.

        They could also be automatically appended to the metadata on the object output, or even, a specified endpoint in the object itself to expose the available bindings.

        1 vote