Advocating Go for game development (golang)

Поделиться
HTML-код
  • Опубликовано: 26 июл 2024

Комментарии • 30

  • @anthonygg_
    @anthonygg_ 6 месяцев назад +29

    I cant agree more. I have been saying this for a long time. I'm happy I'm not the only one.

  • @purpasmart_4831
    @purpasmart_4831 3 месяца назад +4

    Go is the true successor to C. It's just so damn simple and easy to write code.

    • @BrentFarris
      @BrentFarris  20 дней назад +1

      It was also partly designed by Ken Thompson, who partly designed C as well while writing Unix. So, there is a link to the similarities.

  • @user-cb3le9oh9p
    @user-cb3le9oh9p 5 месяцев назад +8

    Go is my first deep dive into a compiled language. I'm using it to develop a game (with help from the very nice raylib-go library) and have been very happy with the experience.

  • @0runny
    @0runny Год назад +3

    Thank you for this video. I looked at Go a few years ago and again recently, I noticed that the Go team has been busy working on performance improvements in many areas. My requirements are quite stringent in that I handle large amounts of floating point data and perform numerical computations in parallel. I found Go performance to be poor, however, I think it was my implementation which was creating too many objects and thus stressing the garbage collector. Since then Go has made many improvements, specifically the ability to pool objects so you can reuse them rather than create them from new. Also memory arenas look like a great addition, hopefully the Go team will make it fully available in future versions of Golang. Additionally, there are great analysis tools available to see where objects are allocated on the heap versus the stack. Anyways, thank you for your video. I will definitely re-try Go for my performance heavy application.

  • @Mikenight120
    @Mikenight120 5 месяцев назад +4

    GO MENTIONED💯

  • @dmitrypetrov7902
    @dmitrypetrov7902 Год назад +3

    This is really nice!

  • @savingday
    @savingday 2 месяца назад

    Great insights!

  • @victorjosey8756
    @victorjosey8756 7 месяцев назад +1

    I agree with you 100%

  • @abdlhamidwaziz9164
    @abdlhamidwaziz9164 Год назад +2

    go go go ❤

  • @jamesbutler4334
    @jamesbutler4334 10 месяцев назад +2

    Hi, I was excited by your thoughts about Go for game engines. I have a question for you regarding rts games. A few developers and I have been looking at scaling above 10,000 unit and it occurs to me that Go concurrency model might be effective for that.

  • @amrojjeh
    @amrojjeh 16 дней назад

    Could you elaborate more on the GC? I've heard problems of how Go can "stop the world" to delete all its objects and that can cause serious stutter. Do Unreal and Unity implement their GC differently so that the world is never stopped or is that something which you work around regardless of which GC you use? Thanks!

  • @haze6277
    @haze6277 20 дней назад +1

    I also think that it would be good for game dev, but for my particular usecase it wasn't suited well:
    - i want my game to work on riscv (and not only on linux). And use proprietary llvm build for max perf.
    - golang has only generic riscv support, and i would need to add another target by myself
    - there are not a lot of gamedev libraries, and they often maintained by one person and semi-abandoned (like with c)
    - so i choose bevy, Rust already has my target listed (albeit 3rd tier support), and it actually easy to add one by myself.
    - Or i could use c, but useful libs that i has are maintained often by one person (raylib, flecs, imgui etc)

    • @BrentFarris
      @BrentFarris  20 дней назад

      Indeed! Use the right tool for the job and balance that with what you want to do and the time you wish to invest.

    • @PamellaCardoso-pp5tr
      @PamellaCardoso-pp5tr 15 дней назад

      Or you could use C++ which is the standard language for gamedev in the industry?
      Like... its much easier to find good libraries for the language Unreal Engine 5 relies on... just saying

  • @ashtwenty12
    @ashtwenty12 9 месяцев назад +1

    Any suggestions on leg up frameworks for a game engine? Us fyne just gui stuff?

  • @memsom
    @memsom Год назад +4

    Is your engine available?

    • @BrentFarris
      @BrentFarris  Год назад +6

      Not yet, I've got some go specific stuff to work out after the port that I want to get done first. Just trying to avoid too many irrelevant issues being created. I'm planning on putting it up publicly after though.

  • @mariobroselli3642
    @mariobroselli3642 4 месяца назад

    How is c or Go compared to Elixir or Clojure or Scala?

    • @AtomicalYT
      @AtomicalYT 3 месяца назад +2

      All those languages are functional languages. The issue with that is that functional programming is built on immutability, which means things can't be changed once created. This means you always need to create new memory to update your state which not only takes time but also puts more pressure on the garbage collector.
      Garbage collectors are only as slow as you let them be, and if you constantly create new memory that has to be managed by GC, you let them be very slow.
      Plus, Go compiles to native machine code whilst Elixir, Clojure and Scala run on virtual machines which have much more overhead than a native executable. Whilst BEAM and JVM have JITs that can narrow the gap a lot, native machine code will always be faster. Plus, JITs will also eat up your memory as they have to track a lot of stuff.

    • @mariobroselli3642
      @mariobroselli3642 3 месяца назад

      @@AtomicalYT why is Gleam faster than the other functional lang?

    • @miguelborges7913
      @miguelborges7913 3 месяца назад

      @@mariobroselli3642 Beam is a better VM.

  • @gregandark8571
    @gregandark8571 20 дней назад +1

    "Go is the modernized C"
    Ok, so what about Odin Programming Language?

    • @gregandark8571
      @gregandark8571 20 дней назад

      Also my last question:
      How Go could be seriously praised for being the modernized C if it can't even do inline assembly or stuff like SIMD ???

    • @BrentFarris
      @BrentFarris  20 дней назад

      Go, Odin, Zig, Rust, etc. are all in the same boat. Also, Go can do Assembly, I have a video on how to do SIMD vector operations in Go if you're interested in learning. No, it's not inline directly in the code, but with some tweakes on the compiler, you can get it injected inline.
      Sorry, I'm not into language flame wars, I generally use about 4-5 different languages a week on average. I am not tied to any one language. I think well designed code can be done in any language.

    • @gregandark8571
      @gregandark8571 20 дней назад

      @@BrentFarris
      One moment.
      In the reality if you wish to push Golang further it's native capabilities like doing SIMD, inline assembly etc, then you must include C inside of it.
      In fact i throw Golang in the wastebasket exactly for this reason .........
      So basically saying that Go is like a modern C is completely wrong, at this point Odin which looks very similar to Go can be defined as the true modern C,
      because it's completely independent from it if compared to Golang.

  • @ViolentFury1
    @ViolentFury1 5 месяцев назад

    cringe