Programming Languages

Поділитися
Вставка
  • Опубліковано 26 бер 2024
  • I talk about the three programming languages I used to make all of my video games: C, C++, and C#. Overall, C++ is the best and most useful, but C# is the easiest to learn.
  • Ігри

КОМЕНТАРІ • 269

  • @miyuzakisuzuki4780
    @miyuzakisuzuki4780 Місяць тому +76

    C++ will make your best friend your worst enemy. Good thing you're in there to be the middle man.

    • @happykanye
      @happykanye Місяць тому

      modern c++ is supposedly fine, or so i've heard from a friend at Google.

  • @Anubis1101
    @Anubis1101 Місяць тому +18

    I love C++ for the opposite reason as most people (or the ones I hear stereotypically associated with the language), that I can just write things C-style most of the time, and use the extra features and tools as needed. I LOVE making my own functions and methods for things.
    One of my first major self-imposed projects was figuring out how to accurately 'bit-shift' a float (so that it divides or multiplies the value by powers of 2). It was challenging, but so much fun, and taught me so much about the language.

    • @Anubis1101
      @Anubis1101 Місяць тому +6

      Optimization is still an ongoing issue, and programmers must be ever-vigilant in testing their code. I think that goes for all languages though, not just C++.
      Just recently, I discovered that std::cout has an optimization issue where consecutively passing multiple inputs on the same line with

  • @FumeiYuusha
    @FumeiYuusha Місяць тому +28

    I'm glad I stuck with C++ through Uni and over the years of working. I had a lot of peer pressure to switch to Java, C#, Python and Rust nowadays, but C++ just feels right for me. I don't know how else to describe it, but C++ is just the language that comes to me naturally when I write code.

    • @DagothDaddy
      @DagothDaddy Місяць тому +4

      God you wouldn't think of programming as a field with alot of peer pressure but it is. I entered college just as C# blew up and I had so many people from classmates to professors and even a guidance counselor up my ass about prioritizing it over things I already had a handle on like C,C++ and rust.

    • @hypnos4754
      @hypnos4754 Місяць тому +1

      I feel the same way. The syntax is intuitive and the way things work makes sense to me. This doesn’t seem to be the norm though. Most people I know feel the opposite about it. C++ is what made me enjoy programming.

    • @2Fast4Youtube
      @2Fast4Youtube Місяць тому +2

      If you do a lot of videogame development, you'll be probably interested in Jai.
      (Is not out yet, but is made by someone like you who never switched to any other language than c++)

    • @JohnTyree
      @JohnTyree 26 днів тому

      This is probably because you learned with it and haven't really used much else. Everyone's "native" language feels right to them, but that doesn't mean French is better or worse than German, even in France.

    • @FumeiYuusha
      @FumeiYuusha 26 днів тому

      @@JohnTyree That is an interesting theory, and I'm sure there is some merit to it. I would count myself as an exception though. I know 4 spoken languages and I'm currently learning a 5th. My favorite is not my native one, nor my second learned language.
      As for programming languages, I learned and used several other languages too, among them Ruby, Python, Java, Rust, Bash Scripting, Perl, C#, Assembly Code and other scripting languages made for specific applications. You are right in the fact that I used C/C++ the most, but I did learn programming in BASIC and Pascal, C/C++ only came into picture 2 years into my programming journey. My reasons are perhaps more unique to my own situation.
      I do not disagree with your statement though, I am sure a lot of people have the reason you stated, but it's definitely not mine.

  • @Garouwerks
    @Garouwerks Місяць тому +37

    Hello Mr. Cain,
    I've been watching you since TKMantis had you on his channel. You have been one of the warmest, most kind, professionals I have had the joy to watch and learn from. I am now 54 a wife and mother of 2 who has been playing games for decades. I have had a lot of time to see games grow, and change, and I find it fascinating how close to the truth (to being On the Nose)many of the 'future games' are. I have been curious for years how all of you creators get that close to the truth in Our reality. Just how do you 1) come up with the ideas for the story of the game? 2) What things in current life help you come up with the future in the games? , and 3) Do you have some crystal ball (joke)?! Some of the things that happen in the Fallout series have insanely happen in real life. The real question is: do you ever feel surprise or shock, or anything; when ideas you came up with for a game and put in the game, become real?? Does that ever affect you?
    Thank you for doing these video's and being such an amazing person. I really look forward to hearing from you and learning about the industry. Much thanks!
    Sincerely,
    Nichole.

    • @jpzarde8734
      @jpzarde8734 Місяць тому +3

      I’m not a Mr. Cain or really a qualified enough author to answer these questions, but feel inclined to do so anyway. Please forgive me
      1. I find the nature of ideas and inspiration to be like flashes of lightning. Sometimes they show up at just the right time, other times they take forever to appear. Either way, you need to be ready to do something when they show.
      In terms of storytelling, having knowledge in story structure / format can help, but isn’t a hard requirement. All I know for sure is once you’ve read Aristotle’s Poetics, you’ve read every story ever conceived on this planet.
      2. I think- based on what little I know, storytelling as a whole can be boiled down to answering a what-if question, and trying to answer it honestly. No matter what genre or medium, be it sci-fi or fantasy, video games, movies or books, the best / most accurate to life stories always have some kind of universal truth to them.
      What if the world got blown up by nukes? (An unlikely but not impossible future.) Life would probably go on. Humanity’s nature, though scarred, probably wouldn’t be all that different from life before the bombs fell. Their capacity for war will never change. That’s the world of Fallout in a nutshell. What if the world was threatened by a war perpetrated by a dark force? Say WWII? Every nation would react differently, but ultimately it’ll be the unseen, smallest masses of the human race who would win the war in the name of good, and pay the ultimate price in doing so. That’s lord of the rings.
      Sci-fi is neat because while most fictional stories ask “what if ‘x’ was real,” (like what if goblins were real,) Sci-fi specifically tackles what if ‘x’ in our reality was real, and more often then not it’s related to a developing technology that is very much closing in on becoming tangible by the day, if not the hour. Such as artificial intelligence, for example.
      I think in terms of storytelling being akin to having a magic crystal ball, sc-fi comes closest to predicting what our future could be like. Every other genre tends to be more about the nature of humanity, and more often than not is a morale lesson on how to be a good person.
      Everything else save for the message in your story is spectacle. The big battles, the drama, the mutant monsters, the retro future aesthetic, the occasional over the top wackiness, whatever. Everyone listens to a story for the spectacle, and they stay for the message / universal truth. (Or because you’re the author writing the story, that is also a possibility.) ((But that’s probably because they know what kind of spectacle you like to write into your story!!!)) You as an author get complete dominion over what kind of spectacle you want your world’s story to have, because chances are if you like to see lots of action and / or drama in your story, floating cars and mutant monsters or what not, someone else will too.
      Apply your story’s message / world to the spectacle you wanna portray and that’s how you get desolate retro future cities, or elves- dwarves, humanity and hobbits banding together to stave off the impossibly powerful forces of Sauron.
      I’m kinda shocked myself that AI has come so far- far enough to potentially replace the art / writing industry as a whole, but I’m hopeful that means art will become more of a social skill rather than a specialized commercial industry. Art has the potential to enrich everyone’s lives, and if everyone knows how to make art, (IE learns how to make it by hand and not with an AI,) the more lives there are to enrich.
      I hope you got something out of reading this :)

  • @sealsharp
    @sealsharp Місяць тому +26

    I can do all three of Tims languages. Learned them in the same order.
    Learning C and C++ was pretty useful for working with C#. Tims example of C# being slow for image processing is one of these cases where a little bit of unsafe code could have saved the day.

    • @mandisaw
      @mandisaw Місяць тому +11

      One of the things I like about Unity - lets me code gameplay in a high-level language, while the engine uses C++ for graphics & better runtime performance. Most games you see with performance issues aren't really about the language (or even the engine), it's just poorly-written & architected - or no one listened to the technical artists & QA team.

    • @Me__Myself__and__I
      @Me__Myself__and__I Місяць тому +4

      Interestingly learning Pascal, particularly Delphi is far more relevant to C# than C or C++. C# and the .NET platform are actually based on Borland Delphi (Microsoft had to pay $$$ to license patents) and the architect of C# was the architect of Delphi (Anders Hejlsberg). I had worked in all 3 before C# and Delphi was, by far, the most relevant. In fact, C# is for the most part a vastly improved Delphi (though I still miss sets and visual form inheritance).
      C# became faster and more efficient over time. Plus there are ways of doing certain things faster. Image processing was slow in the beginning, I don't remember what I was doing but I remember trying to do image processing and it was a massive pain. But later versions provided more options. Plus, as you mention, it is always possible to code time critical capabilities in unsafe code. Though I'm not sure if you can do that with platforms like Unity. For most things C# is the best language that exists today, it started off good but they have expanded on and added to it numerous times and now its quite awesome. They have a habit of taking the best parts of other languages and adding them into C# in really good and useful ways. Its sort of the melting pot for the best of all languages now.

  • @YourMom-rg5jk
    @YourMom-rg5jk Місяць тому +25

    one of the most sane tech related comment sections I've seen on youtube in a while

  • @NotSionnix
    @NotSionnix Місяць тому +6

    I think this video really highlights just how much bad coding practices there are in the industry and that learning how to write "good" code with appropriate standards is something that doesn't get talked about a lot.
    I think it would be very interesting to see a video talking about good coding practices, how to write readable code for you and for others, how to make things simple and reduce complexity when necessary, and common "bad" practices you've seen over the years. Cheers!

    • @Me__Myself__and__I
      @Me__Myself__and__I Місяць тому +4

      Good programming practices, discipline and learning to write readable & maintainable are hugely important. Unfortunately they are also EXTREMELY time consuming to learn and become good at. I think most of my code was complete crap even at the 20,000 hour of coding experience mark. It probably took me until 40,000 to start getting decent at it. My code worked and was considered good by others during that time, but I set very high standards for myself and my code. I spent a lot of time thinking about this stuff and carefully analyzing how the code I wrote turned out and performed and then intentionally finding better ways to do things. Writing code is fairly easy, writing GOOD, high quality code that performs well, is easily modifiable, is readable and maintainable is extremely difficult and takes a long time to learn. Wanting to learn this is a darn good path to be on. The best way to truly learn it is to meticulously pay attention to and analyze the code you write and how it turns out. Figure out which things are difficult to go back and modify a year or two later. Which code performs and scales well and which don't. Etc.

  • @8Paul7
    @8Paul7 Місяць тому +222

    Hi Tim, it's us, everyone.

    • @Jaqinta
      @Jaqinta Місяць тому +2

      waited him soo much for this topic soo excited ! watching now ! :)

    • @bruhvistan9001
      @bruhvistan9001 Місяць тому +4

      Hello everyone, it's us, we.

    • @sentendo7647
      @sentendo7647 Місяць тому +9

      this joke is getting old

    • @itsange02
      @itsange02 Місяць тому +10

      @@sentendo7647ur mom is getting old

    • @insertoyouroemail
      @insertoyouroemail Місяць тому +2

      @@itsange02no u

  • @Plachno85
    @Plachno85 Місяць тому +3

    This is the video I’ve been waiting for!! Awesome insight into languages and your experiences. Thank you for the upload, Tim!

  • @MyCodingDiarie
    @MyCodingDiarie Місяць тому +3

    You're changing lives with your content. Keep inspiring!

  • @xecreth7211
    @xecreth7211 Місяць тому

    Just found your channel while searching for design videos and its awesome tyty

  • @MyCodingDiarie
    @MyCodingDiarie Місяць тому +1

    Your videos always make my day. Keep shining!

  • @1985rbaek
    @1985rbaek Місяць тому

    Hi Tim thanks for the video and the games through the years.

  • @mrhammer1179
    @mrhammer1179 Місяць тому +2

    I've been a CS student for about 3 years and now am getting into game development, many of these videos have given me inspiration. It has been a slow start due to my workload, as well as the job search but I am hoping it'll speed up over the summer.
    Thank you for all the fun videos!

    • @mrhammer1179
      @mrhammer1179 Місяць тому +1

      Also I tend to agree that C++ is the most useful, I prefer it over the other languages I've used.

  • @iswordlogici7760
    @iswordlogici7760 Місяць тому +3

    All of these videos you make about programming really has me wanting to learn.

    • @Me__Myself__and__I
      @Me__Myself__and__I Місяць тому

      If you want to learn for fun by all means. I personally love programming. However, if you want to learn as a future career path - uh not so sure anymore. AI is going to put a LOT of software developers out of jobs. Within a decade it may make it completely irrelevant as a career. FYI

  • @DarthChillash
    @DarthChillash Місяць тому

    Thanks! I was asking myself this same question, but in the end I decided to focus on learning C for my first PC game. My goal is to make my own "engine" anyway. The person who actually helped me decide this was John Romero who said how they never re-used the code from the previous game because when you are making the next one you are smarter and more experienced and you will do it better this time.

  • @DamianReloaded
    @DamianReloaded Місяць тому

    Jason Turner's channel is a good source for staying up to date with everything c plus plus related.

  • @CallousCoder
    @CallousCoder Місяць тому +2

    The good ole days when we wrote assembly and then moved to C, what a happy moment. Then to C++ which took some of the tedium from C++ away.

  • @Queso2469
    @Queso2469 Місяць тому +8

    I'm glad C# has matured a ton in the past decade that has made it way more pleasant to use. My biggest annoyances in working in Unity are all terrible API decisions made by Unity themselves. It's now an extremely pleasant and performant language that I don't have to babysit, on top of an engine that I have to fight a lot :P

    • @Me__Myself__and__I
      @Me__Myself__and__I Місяць тому +2

      C# has been an excellent language for quiet a long time. I only recently started using it in Unity and from what I understand Unity was always lagging behind and was using Mono and not .NET proper. Development in Visual Studio against .NET has been fantastic for many years. Like I said I've only been using Unity recently, so if it was substantially worse before I'm very glad they've fixed and improved that. Its a great language but its only one piece of many that must all work together in a platform.

  • @Tailmonsterfriend
    @Tailmonsterfriend Місяць тому +29

    I FEEL SO VALIDATED! I had a very similar language journey (Basic -> Assembly -> Pascal -> C -> Javascript -> (sea of mostly academic languages in college) -> Java -> C++ -> C#), and C++ is the one I felt I had the best combination of "powerful features" and "really fast." I think any programmer worth their salt can do great things in (almost) any language, but there definitely are differences in how much you can squeeze out of each one, performance-wise.
    Which reminds me, I really should learn Rust.

    • @sub-harmonik
      @sub-harmonik Місяць тому +4

      I'm waiting for zig to become stable

    • @arson5304
      @arson5304 Місяць тому +1

      if you love powerful features and runtime performance, oh boy you're gonna fall in love with rust

    • @archeogeek315
      @archeogeek315 24 дні тому +1

      All man who understand Assembly deserve respect.

    • @Noxfrolic
      @Noxfrolic 23 дні тому

      I've gone from C/C++-> C# / JAVA -> C# -> Typescript + Python --> Go > Rust, Powershell or Typescript depending what I'm working with.
      Typescript is the best general purpose language today in my opinion. Not so much because it's good at anything, but because you can use it for everything meaning even small teams can help eachother and share resourses regardless of what they work on. Powershell is just a part of Azure these days, I'm doing it because our operations guys can't, but it's really just because it works so well in Azure runbooks and I'm getting tasks I probably shouldn't.
      Rust is basically C/C++ that you can write after a week with no sleep... and you get to be part of a cult!
      I don't think there are any bad languages. I prefer Rust these days, but it's mostly because everytime I'm doing C# or Java I feel like what I'm doing would be so much easier in Go and at least with Rust you get performance.

  • @GypsumGeneration
    @GypsumGeneration Місяць тому

    Thanks for sharing, Tim.

  • @DreamsStreamChannel
    @DreamsStreamChannel Місяць тому +3

    On the topic of learning which language first, I think that depends a lot on learning style and environment. When I went to college for making games they started us on primarily C, then moved to C++. Not knowing anything about programming it was a lot to wrap my head around. But as we had instructors, TA's, and supporting resources it went well. Ever since, if I needed to pick up other languages for a project it hasn't been super tough.
    Whereas I have heard other programmers say that it was difficult to work the other direction from Java/C# to C++ or C. But if you are learning primarily on your own, it may be easier to work with a higher level language at first. Learning C/C++ there were some errors that would have been an absolute nightmare if I didn't have that academic setting to ask questions in.

    • @1985rbaek
      @1985rbaek Місяць тому

      I would tend to agree. C is best to learn first, then go towards a language with the features you want like C++.
      While performance is important, this is not the main reason for learning C first. I argue it a little different, as an electronics engineer, I have worked with quite a few different computing platforms, including GPUs and FPGAs, and frankenstein combinations of each like APUs and SoCs. What they all have in common despite their very different architectures and compute models are a c-style syntax. This helps you in concentrating about learning the capabilities of these platforms rather than using a lot of time trying to learn syntax instead.
      Some of the higher abstraction languages like Java and C# does seem to hide the nature of the underlying platform away from the user, so people get stuck in the "Java"-way or the "C#"-way of doing stuff, and can be hard to unlearn.

  • @StavrosNikolaou
    @StavrosNikolaou Місяць тому

    That is such a fascinating journey. I started in the 90s with visual basic and then moved to C, C++, (just a smidge of) assembly, Java, Python, Python, Python,.., back to C++ and have only toyed with C#.
    Learning new languages is so fun (when you have the time to do so properly and experiment).
    Having written for so long in languages that force you to explicitly manage memory how do you feel with newer languages like C++ and C# that offer much more convenient primitives (smart pointers etc)?
    Thanks again for the great video. Keep the technical ones coming 😊

  • @valethemajor
    @valethemajor Місяць тому +1

    The simplicity reasons behind your preference toward C are the same that made me choose GO - forced to write simple and readable code with no wild tricks. I can always come back to my code and read it just fine. Cannot say the same about my JS days where I was also learning functional programming lol....

  • @gregorymifsud5389
    @gregorymifsud5389 Місяць тому +16

    multiple class or nested inheritance can most definitely make your life a living hell

    • @downstream0114
      @downstream0114 Місяць тому +5

      I realized it was problematic when copying the way other people had done ridiculously deep class structures. I'm quite happy making "wide" code. Composition over inheritance.

    • @Me__Myself__and__I
      @Me__Myself__and__I Місяць тому +1

      Or it can incredibly simplify an architecture and add make a system much easier and cheaper to maintain due to modularity and expandability. A good, skilled software architect can do amazing things with a good OOP language like C# that deliver a lot of significant benefits. But it does take knowledge and skill that require an investment of time to learn.

    • @gregorymifsud5389
      @gregorymifsud5389 Місяць тому

      @@Me__Myself__and__IIndeed

    • @darkengine5931
      @darkengine5931 Місяць тому

      @@Me__Myself__and__I A general difficulty I tend to find with OOP specifically in the context of game design is that even moderately complex game rules tend to want to work towards the leakiest abstractions.
      Consider just implementing D&D rules. We often have rules like this attack temporarily drains one level from the creature that is attacked, this potion/spell heals this much HP, this spell does this much damage with this much area unless we're indoors or underwater or it's raining in which case it does something else, etc (hundreds of pages worth of such rules).
      Such a rulebook actually lends itself to a very straightforward procedural design with functions that mutate data. Or slightly less straightforward but still straightforward, as a functional design inputting data and outputting new data. It doesn't lend itself to a straightforward object-oriented design since with the thousands of inter-object interactions that result in mutations, it constantly raises the question of what modifies what. If objects only modify themselves for the least leaky of abstractions, we still end up working quickly towards a lot of monolithic objects with countless methods or fewer methods but then getting about as leaky as the worst getter/setter interface designs.

  • @Tetramir1
    @Tetramir1 Місяць тому +1

    the part about optimizer bug is funny. I've only been working professionally as a programmer for 6 years. But in that short period, all the bugs I remember that happened only in optimized build happened because debug builds would init memory to 0, or things like that. So nowadays my first reflex in release build isn't to check the compiled code, and always to look for uninitialized memory or something similar.

  • @neonneon892
    @neonneon892 Місяць тому +10

    I unfortunately went and learned Rust before C++, and all the times I've attempted C++ afterwards have been full of "wow, this is so much nicer in Rust". Gotta get over that one day though, chances are that there will be a ton of C++ to maintain in whatever game programming job I end up in.

    • @Kroogles
      @Kroogles Місяць тому +3

      I've been coding for over 20 years and I've personally known dozens of engineers. You are literally the only person I have ever seen who thinks C++ is "much nicer" than Rust. More power to you, of course, but passersby should definitely do their own investigation. For my part, I couldn't disagree more.

    • @neonneon892
      @neonneon892 Місяць тому +9

      @@Kroogles Sorry, still haven't found one, I think you misread a word! I definitely prefer Rust over C++ :)

    • @Kroogles
      @Kroogles Місяць тому +4

      ​@@neonneon892 I did misread, my apologies! I was deeply confused by what I incorrectly thought to be your position.

    • @simulacrumgames
      @simulacrumgames Місяць тому +1

      @@Kroogles I almost misread your comment and I was about to be like who have you been working with?!

  • @Me__Myself__and__I
    @Me__Myself__and__I Місяць тому

    Dude. I started in BASIC on an Atari 400 (quickly upgraded to an 800). Then BASIC on a Apple II, C64, C128 and finally landed in Turbo Pascal 4 on an IBM PC-XT as my first procedural & compiled language in high school. Started learning machine code on the Atari so I could poke instructions into memory then taught myself assembly language somewhere in there to do graphics programming. This might be part of the reason I tend to agree with your perspective.
    I kinda feel sorry for newer developers coming up and learning in modern days. I knew pretty much everything there was to know about the Atari 800, which is why I moved on to other systems. It was possible because the Atari 800 ecosystem was tiny in comparison to what modern computers can do. Now its inconceivable that a single programmer could learn 100% of even a single development environment (such as Visual Studio) because they are so broad.
    It was also easy and fun to learn in that environment but also taught discipline because 16K of memory and a slow CPU is very limiting. A lot of newer developers have no clue about writing efficient code and many don't even consider performance or resource usage when coding. They are wasteful because on their development computer they have lots of RAM and CPU. But then in production scaling issues arise because nearly everyone's code is inefficient and the whole thing at scale becomes a resource hog. Which would also apply to game backend developers (particularly for things like MMOs). But in general game devs are probably one of the few areas in programming where efficiency and performance still matter.
    Anyway, I really think there was great benefit in learning to program in a tiny ecosystem under extreme constraints that no one I'm aware of benefits from anymore.

  • @Woodythehobo
    @Woodythehobo Місяць тому +3

    Another great vid. For me: I used Unity C# for many years until I finally got fed up of the engine. Often their 1st party modules would be half-baked or outright broken. Felt like you had to use marketplace addons to fill in the gaps, which added to project bloat and load times. Engine patches would randomly break my projects and cause new bugs. They removed/altered features I used such as GI. Tutorials online are mostly outdated and unusable. Outdated docs. Terrible licensing decisions was the final nail in the coffin. Frustrating. Then FINALLY moved to Unreal 5 when 5.1 launched, it was unbelievably refreshing. Hardly any bugs. Core engine ton of features. C++ isn’t too bad to learn vs C#. Blueprints visual scripting is incredibly solid for rapid prototyping. Old tutorials still work with very minor adjustments. Great performance. Awesome built in features like nanite, lumen, metahumans, quixel megascan etc. Fair licensing. Overall Unreal is a joy to use, which IS important for hobbyists because we want to enjoy it!

    • @Anubis1101
      @Anubis1101 Місяць тому

      Yea the pricing fiasco gave me the push I needed to finally break away from it, and I'm glad I did.

    • @fsharplove
      @fsharplove Місяць тому

      Does Unity still using a very old version of C# ? Last time I checked they were using a very old mono base version while Godot was offering the latest one.

  • @dominikdalek
    @dominikdalek Місяць тому +1

    Weird Tim didn't mention exceptions causing a lot of problems on consoles before it was possible to completely disable them in various libraries (including STL). As for the image processing in C# - you had to copy raw data out in those days and work with that. Working on abstractions provided in standard library (Image/Bitmap/Graphics) had massive performance penalties.

  • @Posenpaul
    @Posenpaul Місяць тому +1

    I also started with BASIC back in the 80's as a child. :)
    I was only a hobby programmer from the 80s to 2021, but in 2021 I decided to skip my "normal" job and work as a full time programmer and now working full time as a software and web developer. Best decision I ever made about my carrer.
    I learned a lot of languages in my 30 years hobby and it helps me today in my fulltime job. I personally think that often programmers get used to one language, one engine, one framework, one library, then like it and they don't want to change anything, but for me it's different, all these things are only tools and I will pick the best tool for the job I have to do.
    That's programming to me, not to be good in C or Pascal or Java, it's about I'm a good programmer in any language/engine/framework/lib and I will pick the best for the job I have to do. Like a mechanic who picks the right tool to fix an engine.
    Programming languages are just tools and we as programmers use them. That's the way I like to see it.

    • @Me__Myself__and__I
      @Me__Myself__and__I Місяць тому +1

      How did you possibly learn coding in the 80s and then not end up as a professional programmer in the 90s? There were so few people who knew how to code in the late 80s / early 90s. If you knew how to code, even a little, you were practically forced into it. I used to get paid to clean up (aka re-write) tons of custom software systems that were written by accountants because a lot of accountants apparently liked to fiddle with technical stuff and coding and thus were often tasked with writing software for the business. Anyway, glad you're having fun now. Unfortunately AI will probably put most of us out of work in less than a decade. Enjoy it while it lasts.

    • @Posenpaul
      @Posenpaul Місяць тому +1

      @@Me__Myself__and__I Because I had also other interest and I wrote I quit my other job for programming, but I never said I didn't like it. It was the best decision, because I like programming even more, but my old job was ok and also fun for over 20 years.
      And regarding the AI if it happens then I will try a third job or maybe go back in my old job or try something completely new. We will see.

  • @sushestvobezvolnoe
    @sushestvobezvolnoe Місяць тому +18

    C# is pretty well optimized and fast nowadays. But since it doesn't force to optimize usually the end result is worse. Imho, but i would rather use C# than C++ with STD.

    • @Validifyed
      @Validifyed Місяць тому +7

      C# is a pretty huge language. Many of the more functional and syntactically rich parts of the language (that I love, and use all the time) are also pretty slow. (Probably because they're trying to do as the functional languages do, but on mutable data).
      It's my favorite language because of its versatility. If I want to prototype something out real quick, it will let me do that. If I've run a profiler and need to come back and optimize, it will let me do that too.

    • @sealsharp
      @sealsharp Місяць тому +5

      Sadly, the mono runtime inside unity is the slowest way to execute C#. They are working on replacing that thing with CoreCLR ( fascinating blogposts about that) which is so much faster, but it's really not that simple because of the native-managed-interop.

    • @simulacrumgames
      @simulacrumgames Місяць тому +2

      Modern C++ can look so ridiculous and unintuitive nowadays. I really do like C#, and C++ isn't bad by any means (especially in the right hands), but if I could just have C with proper lambda functions... 😍

  • @Valiblename
    @Valiblename Місяць тому +5

    I started with C# as well in Unity and definitely made the mistake to abuse the update function a lot
    Last year tried Godot and i like it because it guides you to use the publisher/subscriber pattern with it's signals

    • @Validifyed
      @Validifyed Місяць тому +4

      Sadly the one thing missing from godots signal system is input handling. There are signals for HID inputs, but it lacks the signal granularity of the 2019 updated unity input manager system, which uses generated code files to assign signals per input action type and per binding.
      As a result, most Godot documentation seems to include input queried in the process function.

  • @developerdeveloper67
    @developerdeveloper67 Місяць тому +5

    Hi Tim! Thank you for taking my question! So happy to watch this video. lol Surprised by how much you know, more than you often let off. But that is kinda obvious, since you have been making games from scratch in C for most of your career, you can only know well what you are doing. About the subject of the video: what can I say, more than I already said in dozens of comments here in your channel, well, I prefer C! I think most of the functionality of the C++ language is not really that necessary, and the C++ compiler is significantly slower than C's. Aside from that in non-practical secondary issue, I also I think there is a certain snobbish attitude in the C++ community online that is a bit like: "you have to do 'modern C++' or you are not a 'proper' C++ programmer", that is a bit off-putting to me. Again, thanks for the video! :)

    • @Me__Myself__and__I
      @Me__Myself__and__I Місяць тому

      In general C is harder to understand and more costly to maintain. It also allows undisciplined developers to write some truly obnoxious code that ends up being impossible for anyone else to comprehend or maintain. C++ and C# result in code that is easier to maintain, more modular (easier to adapt) and easier to figure out/read. Game development is a niche where certain things (raw performance & efficiency plus low-level hardware access) often outweigh many other factors. Game code doesn't need to be maintained and modified over time the way most other systems do. Once a game has shipped its code is mostly static except for bug fixes and the occasional tweak. In these areas for most software development purposes C# is by far the winner. But it really depends on what is being done and the constraints of the work. Writing low-level device drivers favors C or C++. Building a complex enterprise application that needs to be supported and modified over many years by multiple developers favors C#.

  • @dreamingacacia
    @dreamingacacia Місяць тому

    since I'm using unreal, I guess I'd learn c++ sometime in the future. At first I was considering c++ and python, but what you've said make sense.

  • @SknCommonLisper
    @SknCommonLisper Місяць тому

    What's your opinion on (common) LISP? With (modern) common Lisp (specifically; the SBCL Compiler) you get code that rivals C's performance (and in some cases, surpasses it, such as with recursion or linked-list manipulation).
    To paint a bit of a picture. Common Lisp is both an compiled and interperted language (repl runs in 3 steps, with running compiled code last, which also allow for things like macros that alter functions entierly pre-runtime). So you get the 'best of both worlds' kind of scenario, this allow for things like debuging, or making code-changes at the same time as a game is running, without needing to re-compile it (as you can recompile the code immediately while the game is running, the repl will just start reading the new compiled code instead).
    Basically, you can do with CL natively, what you'd use a script language for, with no performance drawback.
    --
    Obviously, CL isn't a popular langauge in general, doubly so for games, so game-resources for it is bascially nil (We do have wrappers for SDL1.2 and 2.#, also openGL, but yeah, you generally need to get comfortable with CFFI for game-dev with CL).

  • @ignotlichitikus9314
    @ignotlichitikus9314 Місяць тому

    interesting that STL didn't come with the source code, makes me wonder how they were provided back then,
    currently the entire STL is implemented in headers and we have access to all of its code, still can be hard to debug but the addition of static_asserts, concepts and proper tooling like the one provided by the latest visual studio we have much better experience debugging
    was expecting one of the reasons to not use STL was that they use standard allocators, with some work this could be partially solved by using std::allocator,
    most likely the same issue would be present with a custom implementation of these containers
    pretty cool how you used so many languages in a professional setting, I imagine you had to learn many things on the fly since many of these languages keep getting updated,
    C++ is still my favorite choice

  • @theultimateevil3430
    @theultimateevil3430 Місяць тому

    Compiler bugs are real! Just last year, I've had a bug in clang where the compiler wrongly optimized out a branch in a very trivial piece of code. Sometimes, -O0 is still a solution.

  • @DogeOfWar
    @DogeOfWar Місяць тому

    Hi Tim, can you (or maybe you already do?) have a video or blog detailing your experience using the Source engine with Vampire the Masquerade: Bloodlines? From what I read from other people at Troika they said it was groundbreaking at the time but it also took a while to learn.

  • @temdisponivel
    @temdisponivel Місяць тому

    Hi Tim. I have a question for you: I'm about to become a tech director for a small company (12 people, 7 engineers). The company uses off-the-shelf engines (Unity/Unreal). I would love you if you could talk about what makes a good/bad tech director, the do's and don't's, etc. Thanks for all the content you've put out, it's fantastic!

  • @souluss
    @souluss Місяць тому +1

    Me, a Scala programmer refusing to touch anything lower level, hearing that "you can do so much in c++": O.O

    • @pyepye-io4vu
      @pyepye-io4vu Місяць тому

      C++ can actually be as high-level as Scala.
      Also, give Scala Native a try! That's what I'm doing right now.

  • @armchair.9664
    @armchair.9664 Місяць тому +2

    I work in the embedded software industry, and my impression of C++ is the exact same. Developers LOVE to over-complicate things with C++ and end up writing a whole lot of code that "shuffles papers around on the desk" rather than doing anything useful.

    • @Anubis1101
      @Anubis1101 Місяць тому

      Many of the issues I've seen regarding bugs and bad practices can be traced back to poor teaching, both in learning and in the workplace. Too many programmers don't seem to care about efficient and maintainable code. Part of it might be the excessive ballooning of web development over software development during the pandemic, and performance isn't as important there.

  • @jakubpustulka6160
    @jakubpustulka6160 Місяць тому

    Hi Tim Love your Channel. In relation to the amount of work programmers do we all suffer from back pain...Any recomendations for a healthier lifestyle as a programmer or anything like that?
    Cheers

  • @arda7an
    @arda7an Місяць тому

    Hey Tim, great video as always.
    The audio is not that great though, it's actually been a problem for a while now. I think there's quite a fair amount of clipping going on and everything just sounds so extremely compressed and distorted, so yeah, just wanted to point that out :D

  • @bugothecatplays7864
    @bugothecatplays7864 24 дні тому

    I end up starting a project in C++ and mostly writing C like code. I have an aversion of using every new feature possible, so unless I find a good use of something C++ specific, I'll stick to the most simple C-like code to solve the problem at hand.

  • @Yorick257
    @Yorick257 Місяць тому +1

    I feel called out and ashamed. But also hopeful, because it means that I still have so much to learn and master. I work with embedded systems, so the speed and the size are still somewhat relevant

  • @minibubblegum5108
    @minibubblegum5108 Місяць тому +1

    My path rn, used to use c sharp in unity, currently using cpp in godot.

  • @greebly6011
    @greebly6011 Місяць тому

    I'm a novice programmer, I hear a lot of talk about super badass programmers wanting to be able to modify their engine or open source software but I would like to hear an actual example. When it comes to STL it makes sense, because when it was new there were problems with it that you would just need to fix and those are small enough things and concepts it shouldn't be too hard to work on. But I cannot fathom doing something like that on an unknown and bloated / possibly overcomplicated game engine like Unreal; maybe its because I just don't know how Unreal works well enough. I would love for someone with the experience to explain a specific thing they've changed about an engine (not inhouse) that they've modified and how that went.

  • @wesp5
    @wesp5 Місяць тому +5

    Hi Tim, what do you think about Python? I know you were not involved a lot in Bloodlines, but if it wasn't for the fact that the Python scripts, that kept the whole game together, were only compiled when the game started and were available as clear text in the game files, that made something like the Unofficial Patch possible in the first place!

    • @PointReflex
      @PointReflex Місяць тому +1

      That was very handy for lil idiot me when the crash at the end of the Society of Leopold mission happened in an age without home internet access, which forced me to kinda learn Python by "translating" the plain code from the game files and build a fix-enstein that allowed me to continue playing the game (I was at that level of Bloodlines-adiction). Side note, I saved the "fix" in a CD and went to upload it into the internet at a Cybercafe just to realize that your Unofficial Patch was a thing... did both kicked myself in the nuts and saved your patch in a DVD and ran back home.
      Anyhow the overall point is that since you have mentioned the game, I will be reinstalling it.

  • @lovyNOM
    @lovyNOM Місяць тому +2

    what do you think about Zig? It's meant as a modern substitute for C

  • @chocolate_maned_wolf
    @chocolate_maned_wolf Місяць тому

    Have you tried the new c++23 stuff? The template constraints are insanely powerful

  • @dziuaftermidnight
    @dziuaftermidnight Місяць тому

    C is the best option for me. When I use a tool, I like to be 100% familiar with it, and that is basically impossible with C++. That's why I always prefer on using C, especially when collaborating with people (since you can't really impose limitations on what language and STL features is somebody using when coding).

  • @muzboz
    @muzboz Місяць тому

    Are you interested in the ATARI 400 MINI at all? Seems like a really cute device for those who started out coding on the Atari range of home PCs. :D
    It's a small emulator/console (coming soon), comes with 25 built-in games, but also lets you run your own from USB, and outputs to HDMI, and supports programming in Basic, and an external keyboard. Very cute! :D

  • @TheirSavior
    @TheirSavior Місяць тому +1

    You mentioned your experience with inheritance being abused. I'm sure there are other examples of projects where code works, but is hard to read, resulting in consequences later. Do you have any more experiences like that?
    If so, did these moments lead you to follow a system that keeps code maintainability in check?

  • @jamesrivettcarnac
    @jamesrivettcarnac Місяць тому +1

    4:11 well. That explains some things 😝

  • @Jaqinta
    @Jaqinta Місяць тому

    Hello Mr Tim Cain ;
    I watched almost all of your videos and i'm one of your admirers (obviously :) ) If i had a chance to get your answer from one of my questions this is the one i really and really would like to know your opinion about .
    The question is , In your video you mentioned that Fallout 1 game engine is based on C and i just wondering how you guys managed simple actions needed for Fallout game is running ? I heard that from some software programmer correct me if it's wrong or not :) he says that suppose that there is one action you need to do soo you decided to program it with C programming language , in C programming language , you almost have to write your code one particular way soo if the person knows C and knows the problem then everyone can read the code behind it because it's easly readable . But in C++ , you can use multiple of approaches from that action soo you can write it in soo many ways even that coding in c++ seems easier than c programming language but if the original c++ coder is not available to show that code , the original programmer should make their code as clean as possible in order to make it easier to read from other c++ programmers .
    Thanks again for this amazing video :)
    Sincerely Jaqinta .

  • @SpirosKography
    @SpirosKography Місяць тому +2

    Truth is, C++ needs very good class documentation, especially if inheritance and overloading are widely used.
    Writing C++ classes and not writing the proper documentation for/in them, quickly leads to pain.

    • @theultimateevil3430
      @theultimateevil3430 Місяць тому

      Shouldn't code be documentation by itself? What's the point in a programming language if we can just properly document assembly?

    • @IlIlllIIIllIIlIIlII
      @IlIlllIIIllIIlIIlII Місяць тому +1

      @@theultimateevil3430 the purpose of documentation is to tell the user of an interface how to use it, without requiring them to parse the entire implementation to understand how it works. Good programming interfaces should function as a black box-- try making that completely "self documenting" and you end up with 50-character function and parameter names.
      "just read the source" is not a valid defense of obscure interface design.

  • @KidLudens
    @KidLudens Місяць тому +2

    Would having a better understanding of C help us think differently and make better decisions when coding in C++? I'm wondering if it's worth learning C if it will help make us smarter C++ programmers, and avoid complicating our code by unnecessarily relying on too many features of C++. If so, I would definitely learn C!

    • @jonteguy
      @jonteguy Місяць тому +3

      It probably will. But I think just learning C++ from C++11 and onward will also do that.
      But honestly as long as you really delve into the memory management of cpp you should be fine. You should never use things you don't know what they are actually doing behind the scenes because that will dim your undertanding of the language.

    • @KidLudens
      @KidLudens Місяць тому

      @@jonteguy Yeah for sure, I think doing something but not really understanding why it works will cause major headaches in the future, so I'm trying my best to fully grasp all that I can. I use cpp daily, and you're right, the memory management side of it seems to be where a lot of the complexity resides. Thank you for the response! :)

    • @sub-harmonik
      @sub-harmonik Місяць тому +2

      using c might help understand what happens internally more I think. Because you have to move and allocate all the memory yourself, it's that much less abstracted.
      Plus when you only use the very small set of features that have clear analogs in machine code it might make you ask 'how is that implemented internally' when you come across a more complex feature in c++ like lambdas or coroutines or stl data structures.

    • @KidLudens
      @KidLudens Місяць тому

      @@sub-harmonik Yeah, that makes a lot of sense. I do currently use lambdas, and it's true that I really only have a high level understanding of how they work. I'm more familiar with the syntax and how to create one, but I honestly couldn't explain to someone what they're really doing deep down in the code. Ok cool! I think I'll spend the next few months learning C for a few hours each evening. Who knows, I may have a few "Aha!" moments in the future while using cpp because I understand something a bit deeper! Thanks for the reply!

  • @twotamatos
    @twotamatos Місяць тому

    Yah I’m learning python I started by learning a bit of coding for a Pokémon fan game but then found u can use it for so much else I’m very optimistic if u go to the proper school, have the correct friends or even the right initiative u don’t even need to be a mathematician it looks super complex and computer science is but it is the foundation of so many things you can do so much with code cuz u know how websites r made n what not. That’s where u start seeing how hacking comes into play in fallout awful mini game that intimidates people from taking science XD but yah it won’t be what I specialize in but for a few things like site design game developing it is gonna be a mile stone I gotta get past. I’m really lucky my dad did a lot of computer stuff back in the day cuz he gave me some great genes I just picked up scripts oh it’s in the name like we read the code off a script right n then we change a few variables and it runs a scripted event in some instances but that’s where I never thought I could have the aptitude to do this but u my good sir are one of the sole inspirations if you have a passion just flat out knowing most computer scientist only have 4-10 years of training and now that u found ur interest u can learn it n that’s a really powerful thing man idk if I could have stayed on that path without hearing a dev like you say that simple phrase if u want to get into it now is the time more then any god how the tools have been developed and they r still improving everyday evolution in like 5-10 years at a time in motion

  • @fedeykin22
    @fedeykin22 Місяць тому

    Hello Tim. I am curious if you would share your experience with "common" architectures in games like MVVVM, MVC, Three Tier Model etc.
    Is there one or more of these architectures that you would recommend. Also I am curious about your experience with writing unit tests and integration tests. Is there time to do it? is it prioritized? Should it be prioritezed?
    best Regards Jakob Arndal

  • @struggopuggo
    @struggopuggo Місяць тому +1

    I'm curious to see if Rust will be used for game development.

  • @Ramiobomb
    @Ramiobomb 19 днів тому

    TBH, I'd wish we'd hear some words about Python and maybe compare it to C#. Also using Unreal, have to tried the Blueprint system?

  • @samcrater7296
    @samcrater7296 Місяць тому +2

    Tim, at 6:00-6:30 it sounds like you are suggesting that we look through -O3'd assembly and try to not only find the bug but figure out which compiler optimization it was a part of. Could you expound on that? That seems highly infeasible for anything but a small amount of code.

    • @CainOnGames
      @CainOnGames  Місяць тому +6

      You can compile with different optimization flags to find out which optimization is causing the issue. And you can compile with pragmas to find out exactly what part of the code is being optimized incorrectly. Both of those actions are fine.
      But then yes, I recommend looking at the assembly output of that particular section of code created with the optimization flag to find out WHY the error is happening. Once you know why, you are prepared to avoid the issue in the future.

  • @kaendor
    @kaendor Місяць тому +6

    Hi, given what you said about your prefered langages, I would strongly suggest to you to have a look if you have the time to Rust. Its stricter than C++, as close to the metal as C but can do high level abstraction too without worrying about abusing inheritance because there is none. There is however no engine as mature as unity or unreal but a nice one ECS oriented called Bevy is really promising ans open source.
    Thanks for your videos !

    • @gardian06_85
      @gardian06_85 Місяць тому

      for games the Borrow Checker is the best and worst thing about Rust. and your "full compiled" blob size is massive unless you take the extra steps and "remake" each crate into your own codebase.
      Rust may be a lot better when they get a more fully featured "STD like" implementation (just rolling the 20-30 most used crates, and having them be "nearly" pre-compiled) where the program doesn't have to do 20 imports, and make a devils deal decision for which async implementation to use.
      there are still some things like "Linked List is impossible" and for all the "safety" Rust claims when there is a issue it hits hard, and can be destructive; the current "Borrow Checked Lifetime to Static" means the developer can 'skill issue' themselves into global static singleton.

  • @jthemagicrobot3960
    @jthemagicrobot3960 14 днів тому

    Wow I remember some of these languages

  • @JavierBonnemaison
    @JavierBonnemaison Місяць тому

    I asked about refactoring in a previous video (particularly making sure that the code is understandable without tacit knowledge). Is it not common practice in your experience?

  • @EuSouDallai
    @EuSouDallai Місяць тому

    Such a great video, Tim! As a developer, I wonder how difficult is to write my own engine. I'm pretty sure that is a very hard task. How do I even start creating something like a game engine?

    • @mandisaw
      @mandisaw Місяць тому +1

      The issue is less the complexity as the time/skillset. It can take years to craft a decent game engine for some specific use-case/genre. You'd have to learn to manage all the parts, incl graphics, sound, input, networking, scripting, design & editing-tools, asset import & build pipeline, etc. And you'd want to do that in such a way that you'll be able to run on your platform(s) of choice, even as it/they also develop & evolve (see Tim's vid from yesterday). You wouldn't even get started on your game until *after* the engine was mostly done.
      So the question that's generally asked is, "do you want to [learn to] build a game - or do you want to build an engine?" Because practically speaking, you'll really only get through one or the other.

    • @developerdeveloper67
      @developerdeveloper67 Місяць тому

      Yes, it is very complex, and on top of that, there is a some, difficult for most, math you have to learn and get really used to: trigonometry and linear algebra, that is of course if you want to make 3D games from scratch. To start you should learn C, or C and then C++ if you want to learn C++. Then you should learn OpenGL, the best source today, the one that most people recommend is LearnOpenGL the website, look it up google, youtube don't let us post links.

  • @Me__Myself__and__I
    @Me__Myself__and__I Місяць тому

    Hey Tim, I'm curious which compiler were you using in the 2000s that had such buggy optimization? There used to be a rather large quality difference between compilers. Intel's compilers were some of the best for optimization. Microsoft compilers were some of the worst for almost everything. Microsoft's compilers were so bad the code often had to be written for a specific version of the compiler because MS couldn't be bothered with backwards compatibility. Borland's compilers were very good, not quite a good at optimizing as Intel's but decently good optimization while being very stable and highly compatible. In fact, most Borland developers had command line switches where they could compile in Microsoft mode for any version of most Microsoft compilers. So they even compiled code written for MS compilers way better than the Microsoft compilers could do.
    Another thing to consider though is that optimization in the late 90s / early 2000s became much more difficult. Intel processors were adding a bunch of new features and capabilities like branch prediction and caches to improve performance. Optimizing for those was quite difficult compared to older and simpler CPUs and it took awhile for compiler developers to get good at such optimizations. Plus some CPUs started adding new instruction sets that were much faster for certain operations but, of course, not all CPUs had those capabilities so now the code had to either be compiled for certain CPUs or be smart enough to swap out sections of the code depending on what CPU the code was running on.
    I don't think there is as much of a gap these days. Microsoft has thankfully cleaned up their mess quite well when they moved to .NET (and hired away all the best talent from Borland - which is probably why they improved).

  • @slowfuse
    @slowfuse Місяць тому

    7:52 maybe it will call the base function MAYBE it wont. Ahh a fellow programmer...

  • @1Tasteless
    @1Tasteless Місяць тому +3

    C# was my first language. Definitely very easy to get started with.

  • @ULTRAOutdoorsman
    @ULTRAOutdoorsman Місяць тому

    Every day Tim Cain gets closer to being Stephen McKinley Henderson

  • @10bokaj
    @10bokaj Місяць тому

    Have you tried the C/C++ replacement langs, like JAI, ZIg, Odin, Rust?

  • @jamesrivettcarnac
    @jamesrivettcarnac Місяць тому +1

    6:34 that this surprised you speaks very highly of the engineers you worked with prior to this.
    Cause i have met programmers who dont believe that functions are a good thing and cyclomatic complexity scores are a challenge.
    And thats not hyperbolic. The said that to me as their boss as justification for the code they were writing.

    • @Anubis1101
      @Anubis1101 Місяць тому

      Yea I've seen some REALLY weird takes since diving into programming. The whole Clean Code style guide thing is wild when you try to think about it in practical use, but more than a few programmers still swear by it.

  • @shnargru
    @shnargru 25 днів тому

    I'm really curious, what kind of SDLC works well with game development? Agile and Extreme Programming works great with business applications, but what works well for games?

  • @charliek5964
    @charliek5964 Місяць тому +1

    Hey Tim. Have you ever worked with Python? We're workshopping adding it to my chemistry course for data processing. Just wondering if you have any tips or tricks (especially for teaching/learning Python).

    • @mandisaw
      @mandisaw Місяць тому

      Python has kind of taken the place of Fortran as the go-to for teaching code to scientists / (non-CS) science students. Lot of free cloud-notebook tools for a classroom or research lab setting, and a fair number of tutorials and case studies from colleges that have set it up. Not sure what country you're in, but I know for Google, they have their Python teacher-training resources online, and forums for researchers & educators (K-12 & higher ed) you can request access to. I believe AWS and Microsoft have their own communities, just don't know those as well.

    • @mandisaw
      @mandisaw Місяць тому +1

      You might find some use in resources put out by the big university systems as well, like MIT OpenCourseware and the R1 State universities.

  • @CSCI4X
    @CSCI4X 29 днів тому

    Modern C++ is way nicer than old C++, it's really fun to program in.

  • @EdgarVerona
    @EdgarVerona Місяць тому +4

    Agreed 100% about C++, and I would add "egregious use of template metaprogramming" and "code generating macros" to ways in which C++ features can be abused to create utterly unreadable code.

  • @renaigh
    @renaigh Місяць тому +11

    C-tier video

  • @gilgamecha
    @gilgamecha Місяць тому

    Tim I wonder what you think of go (golang)? Like a clean modern back to basics C.

    • @bionic_batman
      @bionic_batman Місяць тому +2

      I doubt he would be interested in it considering that Go is mostly only suitable for writing server side for multiplayer games
      I really love Go but it is nearly impossible to write a program that uses graphic card in pure Go without any C bindings

    • @gilgamecha
      @gilgamecha Місяць тому

      @@bionic_batman fair point

  • @zupcis
    @zupcis Місяць тому

    Hi, Tim. I was wondering about your opinion about current active rpg game developers like bethesda, larian, inexile, obsidian, bioware? Do you see any other rising stars, that will make the future of rpg genre?

    • @zupcis
      @zupcis Місяць тому

      Sorry forget about code project red and piranha bytes

  • @michaelvicente5365
    @michaelvicente5365 Місяць тому

    Hey Tim, what do you think about neural network AI NPCs? A lot of people (I think you included and josh sawyer) have mentioned it's the "future" of gaming, but I can't help but feel sad when I think about games I like if they were not written by actual writers. Good human writing is part of what makes the dialogues interesting to me, because they have a soul and, most importantly, a purpose. I feel like companies like Ubisoft are pushing AI like crazy because they want to overwhelm the player with content over quality, and I personally hate this idea. I know some NPCs are simple and repeat things (arrow in the knee style) but I actually don't think it's a bad thing. I'd rather have 5 interesting NPCs to focus on in a town, with interesting dialogues than have long generic conversations with everybody, wasting my time. Some dialogues in Fallout games made me laugh, smile, angry and part of me knows that it's because they're written with a mind behind them, not a mashup of data.

  • @IlIlllIIIllIIlIIlII
    @IlIlllIIIllIIlIIlII Місяць тому

    I think C would be about 10x easier for beginners if there were separate symbols for pointer declaration and dereferencing. The fact that you use the same symbol for turning a type into a pointer and turning a pointer back into a plain type is pretty insane.

    • @pyepye-io4vu
      @pyepye-io4vu Місяць тому

      The same symbol does make some sense.
      In the declaration: int *p; this means "*p is the int"
      In dereferencing: *p = 5; this means "the int *p is set to 5"
      Try to think of *p as "one thing" rather than two separate things.
      Unfortunately all 3 of these are valid in C: int* p, int * p, int *p.
      Initially I wanted to think of it as "int*" because I thought of that as "the type of p".
      But that's not the intuition for which it was designed.
      It was definitely designed for the intuition that "*p is the int".
      Then there are two different symbols: & for referencing (get the address of a value), and * for dereferencing (get the value of an address).

  • @MrJballn
    @MrJballn Місяць тому

    To frame the question, there were a large number of designers and programmers working in the industry that had worked with you/under your philosophy at studios you'd left (and studios you'd yet to join) that made games that still "feel" like other Tim games. Is there a level of tribalism in the industry that results in emerging developers identifying strongly with a certain power player or paradigm, or is it more the upshot of lingering culture changes you'd effected on an institutional basis that just happened to stick with them?

  • @TommyHanusa
    @TommyHanusa Місяць тому

    How would you modify assembly in a program as a part of a CI/CD pipeline? is it that consistent? I feel like even if I knew the fix I would get chewed out by lead for doing that since I'm introducing a manual (and error prone because I might forget) process into making a build. Personally I can understand not bothering to learn or figure out a solution that doesn't work well with your processes (although I think its always good to have more options to solve problems).

    • @mandisaw
      @mandisaw Місяць тому

      I don't think Tim's advocating for modifying the output assembly code, more like using that as a debugging tool. Essentially start from there and backtrack to where the problem lies. Even if the problem turns out to be in the compiler/build-command, that's something that could be amended/updated in your CI/CD pipeline.

    • @mandisaw
      @mandisaw Місяць тому

      As for getting chewed out by the lead for solving a problem - generally you'd have already discussed the priorities (this vs something else) and be working on this with your lead's blessing. But that's in a team with a good working-relationship, which admittedly isn't the case everywhere.

    • @TommyHanusa
      @TommyHanusa Місяць тому

      @@mandisaw I was assuming Tim was modifying the output assembly (which isn't something I would normally expect, but he did say he had done work in assembly before). but using a pragma to turn off optimization or just not using certain optimization flags in your code would (I would think, i don't work in c++ daily) be the maintainable way to work around this issue.

    • @mandisaw
      @mandisaw Місяць тому

      @@TommyHanusa IIRC his whole point was not to just workaround it by turning off -O flags, but to actually uncover & address the cause. Looking over the machine code was the means to achieve that.

    • @TommyHanusa
      @TommyHanusa Місяць тому +1

      @@mandisaw Well, I am exaggerating when I say I would get chewed out; it would be more like I would have a long conversation about why what I did doesn't work when a simple "don't do that" would suffice. Personally and currently I have a great working relationship with my leads and leadership (and that is in no small part due to the work my leads put into maintaining that relationship... and some institutional trauma from that not always being the case). And while I can see a team prioritize 'making it work' over 'making it maintainable' I'm pretty confident that should be an exception rather than the rule. I find that in software development you can really be too smart for your (teams) own good. If the seniors are writing code the juniors can't work in and maintain, you are basically making tech-debt. I think most teams would prefer to optimize code for maintainability rather than for performance and that's mostly the right choice given the power of modern computer hardware.

  • @TheKorath
    @TheKorath Місяць тому

    If you did write in a low level language again like C/C++ would you write your own libraries or would you use something like SDL?

  • @ClintChocolateChip
    @ClintChocolateChip Місяць тому

    Hi, Tim! May I ask your opinions on using tools like Unity to make games?

    • @CainOnGames
      @CainOnGames  Місяць тому

      Game Engines
      ua-cam.com/video/Iw3bCdIvAj0/v-deo.html

  • @HexY------
    @HexY------ Місяць тому

    Tim please make c++ programing videos please 🙏🥺❤️

  • @philbertius
    @philbertius Місяць тому +4

    JVM (Java and Kotlin) doesn’t support C# structs, but it’s caught up to C++ performance due to Just-In-Time compilation. And you can abuse sun.misc.Unsafe for straight up memory management and pointer manipulation. Anything you need SIMD/AVX vectorization for you can do in C++ and invoke with JNI.
    As an indie I value my own time more than absolutely best theoretical performance, so it’s definitely going to be more modern languages for me. But the fundamentals are always important, even more so when the language itself doesn’t respect them! (Looking at you, Python!)

    • @mandisaw
      @mandisaw Місяць тому +2

      "Value my own time more" This! Indie or AAA, games or business software, labor is ultimately the costliest resource. A modest amount of performance-minded coding, with decent project architecture, is warranted, but IMExp even on mobile, the engine & OS do a good-enough job for most scenarios.
      I do think anyone wanting to work in software should learn C as a matter of course. Some principles are just easier to teach & learn in C, like memory-management and pointers, data structures (arrays, queues, vectors, etc), values vs reference, etc. There are also good, unfilled jobs in embedded systems and true high-performance, mission-critical domains (e.g. NASA/space, defense, healthcare) where C is still king.

  • @riz5571
    @riz5571 Місяць тому +1

    Hi Tim, software engineer (not in the gaming space) of 10+ years.
    I'm not that familiar with C# and definitely don't have any preference/bias towards it.
    Do you think the issues were due to C# or how Unity utilised it? I would assume that Unity would parse (or compile) C# and then pick up the bits it needed to be scripted for the engine - which I'd imagine could introduce its own overhead and issues.
    I might be wrong and wondering what you think?
    Also, another question.
    I've been a big proponent throughout my career (and when conducting interviews) that people should understand the fundamentals. I very often see candidates (or new employees) being very proficient in the tools yet when something goes wrong coming to a standstill.
    A specific example may be that someone can use the requests python library but doesn't understand any of the underlying calls (HTTP spec, C socks and beyond).
    I try to question if I'm interviewing but have push back from colleagues/superiors. But if I'm not interviewing, these candidates are being employed often.
    Thanks again for your uploads, content and consistency 😊

    • @riz5571
      @riz5571 Місяць тому +2

      Apologies there's not much of a question there.
      I suppose my main issue (especially in the current climate) is people wanting to get things done without understanding any of the underlying tech/code/os etc.
      And then you see the abundance of learning material on the Web which feels only designed to teach the surface level without any understanding of the core.
      I've also spoken with many uni graduates in the UK who have gone through a similar learning experience.
      I never went to university, was an apprentice from 17. And therefore was always part of some sort of software team in every role going forward.
      Wondering your thoughts on this, even if in the game context. I understand it's relatively
      easy to learn how to use an off the shelf engine, but I'd presume the same applies if one gets stuck and then doesn't understand grasp the core concepts/tech (as you've touched upon in this and previous vid).

    • @honaleri
      @honaleri Місяць тому +2

      Colleges don't teach competency, at least not in America. Most American schools do not test for or care about a person's competency.
      They are rigidly designed around a getting over mindset, from elementary school up to college. They test and see if learning. markers have past, but do little to see if people comprehend anything.
      Give a person a test sheet and they'll fill in the blanks all correct. Ask them without paper to explain what something is or why it works, they will stutter and guess and collapse.
      Because they don't have competency, they have mostly basic sight based reflex to the data. Like being able to know a Chinese character reads "love" but not being able to write it from scratch without seeing it.
      They aren't being trained to push beyond the basics of sight based reflexive reasoning. They can't reasons from scratch.
      It's a pervasive American problem.
      Because our school system was designed to get as many kids to pass as possible, not to ensure as many understand as needed.

    • @mandisaw
      @mandisaw Місяць тому

      Re: C# & Unity - Early .NET compilers were kind of crap, which wasn't an issue for enterprise apps (desktop & server-side), but became more apparent when mobile & games came into the ecosystem. Microsoft has improved the compiler performance and C# itself considerably, however Unity is still using an older .NET runtime/standard (Mono) for maximum cross-platform compatibility.
      They are in the process of updating it to a version (CoreCLR) that will theoretically allow them to meet & keep up with modern .NET standards, while keeping their cross-platform nature (the engine's core strength). But it's a long-term project that they're a couple years into already.
      Keep in mind that the above only really applies to developer code and managed libraries - the engine itself uses native C++ on most platforms and devs can always write/use C++ plugins for stuff that needs that performance, like physics or netcode.

    • @riz5571
      @riz5571 Місяць тому +1

      @mandisaw thanks, appreciate the reply. I was curious and not fancying digging into that world myself right now!

    • @mandisaw
      @mandisaw Місяць тому

      @@riz5571 Sure! Re: newer programmers - Unfortunately this is a common issue across tech (and not just in the US, @honaleri). Lot of components IMExp. First, few people genuinely value education - not students & parents, and not employers. They see HS/college as a route to social & economic opportunities - which it is! - but few have any patience or preference for learning itself. So corners get cut, people focus more on getting into the "right" school by name/rep vs a genuinely rigorous program, cheating abounds, and employers for their part are left to rely on poor substitutes like leetcode and narrow recruitment pools.
      Schools feed the problem in some [bad] cases - tech-career programs boost enrollment, and don't have the same infrastructure overhead as say, chem or bio. You can mostly get by with the same computer labs & Wi-Fi network that you'd already have. But I have seen/heard of some truly shoddy curricula, either grossly outdated, or missing fundamentals, or lacking in practical hands-on work like group/term projects. Don't get me started on "game design" or "IT support" programs.
      Math/innumeracy plays a part too. Some well-meaning schools rip out all the "hard math" from the curriculum, or offer with- & without-math variants. So you can get CS grads who know how to use Mathf.Sin[e] or Vector3, but have no idea what those words actually mean, or how to know which ones are eating your performance.

  • @polygonpanda
    @polygonpanda Місяць тому

    I'm confused by the idea that a C++ template library wouldn't come with source code, since template functions are written in header files and compiled at compile time using template replacement it seems they must expose their implementations.

  • @troyhumphreys9952
    @troyhumphreys9952 Місяць тому

    "idiot for not using c++" can you imagine how incredibly wrong that publisher was.

  • @adam.maqavoy
    @adam.maqavoy 18 днів тому

    *5 Ads* - Just To-Watch
    1 UA-cam clip?

  • @dos350
    @dos350 Місяць тому +1

    cpp the goat

  • @herogibson
    @herogibson 16 днів тому

    Logo ftw

  • @formbi
    @formbi Місяць тому +1

    the best programming languages are Lisps
    8:54 ah, nonfree sotware is so wonderful

  • @StellarHarbour
    @StellarHarbour Місяць тому

    If we aren't limited only to C++/C/C#, what would your choice be then?

  • @entorwellian
    @entorwellian Місяць тому

    Yo Tim, what is a quaternion?

  • @kirglow4639
    @kirglow4639 Місяць тому +1

    Thanks Tim! It's fascinating to see your programming language journey and I relate a lot with your sentiments about programmers and being careful around inheritance / operator overloading. Someone may've already asked, but have you tried Rust? Thanks again for knowledge sharing

  • @sahilmishra2945
    @sahilmishra2945 Місяць тому

    hi Tim, everyone, it's me Sahil

  • @arcan762
    @arcan762 Місяць тому +2

    6:55 I see this one a lot too, I call it "technical masturbation"

    • @mandisaw
      @mandisaw Місяць тому

      Perl is both the best & worst language for this LOL It did teach me regexp though, so for that I'll always have a fond memory of Perl.