You don't need to be an amazing programmer, anon. Do you know why? Because Undertale exist.

You don't need to be an amazing programmer, anon. Do you know why? Because Undertale exist. Undertale is one of the worst programmed things that I have ever seen. It is horrible. There are rooms that have hundreds of "if" statements in a row checking the same value and then sets the value to zero and then checks again. All of the dialogue in all of Undertale is in a single switch case statement, thousands of cases long for the whole game. But you'd never know that and it doesn't matter because the player doesn't care and the player would never know. That's it.

Go make games.

A Conspiracy Theorist Is Talking Shirt $21.68

It's All Fucked Shirt $22.14

A Conspiracy Theorist Is Talking Shirt $21.68

  1. 6 months ago
    Anonymous

    Why does it matter how its programmed if it works? Its not a high rise building that will collapse in five years.

    • 6 months ago
      Anonymous

      >Why does it matter how its programmed if it works?
      That's what he's saying. There's reasons to obsess over programming quality, but all of them are about ensuring it actually works. Beyond that there's no real point.

      • 6 months ago
        Anonymous

        Maintainability is a real concern

        • 6 months ago
          Anonymous

          Also performance. Doing things in stupid ways may work but it produces performance inefficiencies.

      • 6 months ago
        Anonymous

        Tell that to the people who still give Yanderedev shit for bullshit like that today.
        His code works, but they still argue with him over the best way to hammer the nail. Code homosexuals are really prissy catty b***hes.

        • 6 months ago
          Anonymous

          His code is terribly unoptimized and the game runs like hot garbage.

          • 6 months ago
            Anonymous

            "unoptimised"
            It still runs, so all it looks like to me is your are arguing over the best way to hammer a nail in to a block of wood. No the real reason is that you can't stand him having a win.

            • 6 months ago
              Anonymous

              >It still runs
              I'll tell you that every time you homosexuals complain about cyberpunk or starfield or cities skylines running like shit.

              • 6 months ago
                Anonymous

                >cyberpunk or starfield or cities skylines running like shit.
                >cyberpunk just leaves max lod models everywhere you can't see
                >strand hair on characters you can't see
                starfield is a bethesda game, and they're simply incapable of doing anything right
                >skylines 2
                >90k polygon characters with no lods on screen at all times in the tens of thousands

              • 6 months ago
                Anonymous

                It still runs

            • 6 months ago
              Anonymous

              keep coping moron, when you are forced to shut down your project or avoid adding content because you need a 4090 to run a game that looks like it could run on a PS2 it means that it doesn't "still runs", it means you have to call it completed, and that people will shit on you for making a garbage game instead of an unoptimized one.

        • 6 months ago
          Anonymous

          The difference is his game runs like shit. If yandere sim ran well no me would care

        • 6 months ago
          Anonymous

          Yandere can't run at 60fps on $3k rigs because it's a dumpster fire of a code though

    • 6 months ago
      Anonymous

      >Its not a high rise building that will collapse in five years
      it is a potential timesink you will lament when you realise the foundations you set can't support the game you intended to make
      it is by no means reason for you to be deterred though
      rather it should be, like most creative endeavors, a learning experience that gets better with every iteration

      • 6 months ago
        Anonymous

        >it is a potential timesink you will lament when you realise the foundations you set can't support the game you intended to make
        homie it's a gamemaker game. Even with the cleanest code in the world, if your scope is beyond a small indie game it will be impossible to maintain just by the sheer limits of the engine and language.

    • 6 months ago
      Anonymous

      because it might not work as intended. around a year or so after pso2 came out, sega started allowing people to do prepatching for upcoming patches instead of having to wait for the day and the update. a couple of months later when there was a BIG update, it basically nuked peoples hard drives because it was coded poorly.

    • 6 months ago
      Anonymous

      Gargoyles placed into recesses where their backs will never be seen still have all the details carved in them because while people won't see them, God will.

    • 6 months ago
      Anonymous

      >Why does it matter how its programmed if it works?
      Because half the time, it fricking doesn't.

      • 6 months ago
        Anonymous

        Well in this case it doesn't work but that's a limitation of Gamemaker's engine.
        Also literally everyone in this thread forgot that Undertale had a linux version and would potentially be running on systems that have CaSeSeNsItIvE filenames

        • 6 months ago
          Anonymous

          in gms osflavor 1 is windows though, plus you wouldnt check for executables on linux

          • 6 months ago
            Anonymous

            Technically you can name an executable file anything on linux.
            Files aren't defined by filename.
            I could make something called Ballsack.batman and it'd still be executable.

    • 6 months ago
      Anonymous

      Well it doesn't and it has bigger frickups when he doesn't learn. Didn't running the uninstallation from Deltarune's random drop delete everything the uninstallation was placed in? It wasn't some yummy delicious meta thing he just fricked up

    • 6 months ago
      Anonymous

      On larger projects code needs to work and be future proof. It's not uncommon for some code written 2 years ago to cause all kinds of problems and limitations that eventually mean it needs to be entire rewritten.
      May as well spend a bit of extra time getting it right the first time instead of doing the bare minimum then having it cause problems for the next 2 years.

      Even worse, I've seen shit code that "just works" actually impact how a game was designed. Because this code was trash but technically worked, and because no one wanted to touch it, everyone just worked around it. Systems were changed and features scrapped because they wouldn't work with the shitty code that just worked.

      • 6 months ago
        Anonymous

        >code needs to work and be future proof
        There's no such thing as future-proofing, but there is effective idiot-proofing.
        It's always necessary because your future self (and everyone else in the future) is always an idiot.

      • 6 months ago
        Anonymous

        >code needs to work and be future proof
        There's no such thing as future-proofing, but there is effective idiot-proofing.
        It's always necessary because your future self (and everyone else in the future) is always an idiot.

        There's no such thing as future proof, but there is future resistant.
        There is absolutely no such thing as idiot proof.

        Generally you want your design to be as decoupled as possible with dependencies explicitly separated when you start. That's 90% of the reason why if trees like this are so bad but instead people just want to seethe about switch statements instead.

    • 6 months ago
      Anonymous

      Non-white hands wrote this post.

      • 6 months ago
        Anonymous

        you will never be white

        • 6 months ago
          Anonymous

          I see I struck a nerve.

          • 6 months ago
            Anonymous

            >I see I struck a nerve.

            • 6 months ago
              Anonymous

              >Can you provide one source for your claim?

              • 6 months ago
                Anonymous

                Only redditors ask for sources.

              • 6 months ago
                Anonymous

                >t.pol gay

    • 6 months ago
      Anonymous

      well because the less you care about how it is programmed the more likely it is for abstractions to leak and bugs to happen

    • 6 months ago
      Anonymous

      from a professional programmer and network engineer
      yes I'm 36

      anything past "working" is just referred to as refinement.
      you want code to be more efficient to lessen the workload on machines while keeping output the same.
      depending on the product, it isn't always needed.
      ie. undertale

      • 6 months ago
        Anonymous

        No you're not. lol

        • 6 months ago
          Anonymous

          alright then I guess I'm not

    • 6 months ago
      Anonymous

      Hi toby

      • 6 months ago
        Anonymous

        Hi

    • 6 months ago
      Anonymous

      >name game underTale.exe
      >trick doesn't work
      Because it's an inelegant solution to a problem that isn't solved.

    • 6 months ago
      Anonymous

      >Why does it matter how its programmed if it works?
      Because chances are someone else is gonna work on your code, and if the code is shit, it's harder to read, debug, and modify.

      • 6 months ago
        Anonymous

        >Because chances are someone else is gonna work on your code, and if the code is shit, it's harder to read, debug, and modify.
        You call this a problem, I call this being an essential employee.

        • 6 months ago
          Anonymous

          >t. hobbyist
          That's how you get fired in most tech companies as a dev.

          • 6 months ago
            Anonymous

            One of my best friends is a 100% alcoholic; had seizures at work and everything. He would miss work, fail to show up at meetings, etc. Had to go to rehab in order to prevent his body from remaining in a state of total chaos.

            He STILL has his job at HP, and he tells me he's not even that good or a programmer. Seems like if they just like you, it doesn't matter how much you frick up-- they'll keep you on the payroll.

            • 6 months ago
              Anonymous

              >Seems like if they just like you, it doesn't matter how much you frick up-- they'll keep you on the payroll.
              That's completely typical. In 99% of industries without specific productivity metrics the best ways to keep your job are:
              1. Be likable and don't start shit
              2. Don't miss deadlines without warning
              3. Don't get into politics

            • 6 months ago
              Anonymous

              >t. can't find a job
              Whatever helps you sleep at night.

              • 6 months ago
                Anonymous

                I personally am a pharmacy tech. I have shown up ~15 minutes late to work every single day for the past few years, missed work, called in 5 minutes before I have to show up, etc. They warned me about it at first, but now they don't care because training someone who knows the ins-and-outs of that job takes a long time and is a huge investment, even though its a job that requires almost 0 conscious thought or problem solving. Also, like

                >Seems like if they just like you, it doesn't matter how much you frick up-- they'll keep you on the payroll.
                That's completely typical. In 99% of industries without specific productivity metrics the best ways to keep your job are:
                1. Be likable and don't start shit
                2. Don't miss deadlines without warning
                3. Don't get into politics

                pointed out, I'm pretty sociable overall and get along with everyone there.

                Competence is great, but you can get away with a lot if your presence at work is a relief to your coworkers.

    • 6 months ago
      Anonymous

      Efficiency, which was useful when devs had to work around technical limits, something that no longer exists.

    • 6 months ago
      Anonymous

      Just learn regular expressions and do it right you fricking street shitter

    • 6 months ago
      Anonymous

      Good practices make it easier for the programmer, not the audience.
      It's why some rpgmaker looking shit like deltarune takes a decade to come out while carmack could shit out a full game every few months

      • 6 months ago
        Anonymous

        >the game made by one guy takes longer than the game made by a studio
        amazing.

        • 6 months ago
          Anonymous

          It's bizarre that the 'Undertale was a solo project' myth still exists, you can just look at the credits to dispel it

          • 6 months ago
            Anonymous

            it was mostly solo. getting help, and having contributors doesn't change that.

          • 6 months ago
            Anonymous

            How is it a myth? He developed, composed, designed,and published it himself

            • 6 months ago
              Anonymous

              False
              He did the composing and concept himself, everything else was aided or outsourced

              • 6 months ago
                Anonymous

                Cope

              • 6 months ago
                Anonymous

                Can you provide one source for your claim? I don't even like Toby but thats quite the claim

              • 6 months ago
                Anonymous

                no

              • 6 months ago
                Anonymous

                >Can you provide one source for your claim?

              • 6 months ago
                Anonymous

                Didn't temmie do sprites? I thought there were a couple people

              • 6 months ago
                Anonymous

                https://www.mobygames.com/game/74938/undertale/credits/windows/ ?

    • 6 months ago
      Anonymous

      >he says while crying about how unoptimized modern games are
      You literal fricking moron

    • 6 months ago
      Anonymous

      Say that to the dwarf fortress guys.

    • 6 months ago
      Anonymous

      Have you experienced how awful modern games run nowadays even on high-end hardware?

    • 6 months ago
      Anonymous

      It doesn't matter. He made millions of dollars and won fame across the globe. Not sure anyone is going to care about his efficient code.

      Kek, this.

    • 6 months ago
      Anonymous

      Reminds me of how they couldn't have vehicles in fallout so they had an ai wear a hat that's a train and the ai would run the place. If it's stupid but works why not let it

    • 6 months ago
      Anonymous

      People like you and Toby are why I have to wait 30 seconds for Microsoft Word to open.

    • 6 months ago
      Anonymous

      >speed
      >extensibility
      >maintainability
      >stability
      >actually taking fricking pride in your work

      • 6 months ago
        Anonymous

        >actually taking fricking pride in your work
        I'm pretty sure the guy who first became famous for his music takes more pride in picrel than in some obscure line of code if/else statement he used to run his 2D game that is still fast, maintained, stable and ported to a dozen other platforms anyways.

    • 6 months ago
      Anonymous

      why do you sound upset?
      it's just kinda funny, nothing more

    • 6 months ago
      Anonymous

      >Why does it matter how its programmed if it works? Its not a high rise building that will collapse in five years.

    • 6 months ago
      Anonymous

      Because programming is just one giant circlejerk of constantly trying to one-up the next programmer about how much you care about the most tiny and miniscule of details and then using that as a pretext to justify unethical brutal insults and shit-flinging at them. It's basically like TV chefs acting histrionic about their job. This happens in any mostly male space

    • 6 months ago
      Anonymous

      >Its not a high rise building that will collapse in five years.
      Someone's never looked into running old PC games, huh?

    • 6 months ago
      Anonymous

      >Why does it matter how its programmed if it works?
      Because you can only make simple games this way. If you want to make a game that doesn't look like it should be capable of running on a calculator with this approach, you will soon find yourself stuck with an unmaintainable mess that becomes exponentially more complicated as you try to add more to it, at which point your progress has grinder to a halt and you either have to go back and refactor or just give up entirely.

    • 6 months ago
      Anonymous

      On the one hand, it isn't that big of a deal and you should get the stick out of your ass.

      On the other hand, you get Pajeet levels of spaghetti code with uncompressed files.

    • 6 months ago
      Anonymous

      >Why does it matter how its programmed if it works?
      Mainly because if you want to go back and change or extend something later on, a well-written program will make that easier to do. An optimized program will run better, which might not matter if you're making some sort of jap-style garbage like undertale, but if you're making something like Factorio, optimization is basically mandatory. And a well-written program will both make it easier to find and fix bugs when they occur, and make bugs less likely to occur in the first place.

      Before this thread dies. Is AI going to automate us away, programmer bros?

      The only thing "AI" (not actually AI) will automate away is looking up code on Stackoverflow to steal.

  2. 6 months ago
    Anonymous

    ESL thread

  3. 6 months ago
    Anonymous

    my own self critical nature unfortunately resigns me to never be able to create anything

    • 6 months ago
      Anonymous

      That's one good way to tell people you're a lazy duck

    • 6 months ago
      Anonymous

      that's a nice way of coping with the fact you're a lazy loser (me)

    • 6 months ago
      Anonymous

      >I'm afraid to fail so I make sure I fail before even starting
      Mmmh, I see

    • 6 months ago
      Anonymous

      >You can't be a creator and a critic at the same time. To create greatness, you must ignore the minutiae. Work in wide strokes. But... inquisitors eat into everything, like vinegar, lingering on every detail. They find a blemish, a flaw, then claw at it until you're finished.
      It's bizarre to see other anons be so dismissive, being a nitpicking autist is different issue from lazyness. Especially with all the leetcoding itt, proper development (read: one that actually has a release) is all about knowing what shit to optimize when.

    • 6 months ago
      Anonymous

      Are you tribe?

  4. 6 months ago
    Anonymous

    not while i'm being stalked

    • 6 months ago
      Anonymous

      wtf?

  5. 6 months ago
    Anonymous

    >not checking every permutation of [Uu][Nn][Dd][Ee][Rr][Tt][Aa][Ll][Ee].[Ee][Xx][Ee] in a loop
    shiggy diggy

    • 6 months ago
      Anonymous

      What the frick are you doing, there's a better way to use regex

      • 6 months ago
        Anonymous

        dont think GM can do regex

        I was just using regex as an example, what you would really do is:

        char buf[] = "undertale.exe";
        size_t n = strlen(buf);
        uint16_t bits = 0;
        while (bits < n) {
        if (check_file(buf)) {
        delete_file(buf);
        }
        bits++;
        for (size_t i = 0u; i < n; i++) {
        buf[i] = (bits&i) ? toupper(buf[i]) : tolower(buf[i]);
        }
        }

        • 6 months ago
          Anonymous

          I don't think you would do this at all. What do you think 'bits&i' should evaluate to?

          • 6 months ago
            Anonymous

            Oops, I meant bits&(1<<i)

            You don't have to check anything on Windows!

            On MacOS, GNU and BSD all you have to do is "find ./ -type f -iname "*.exe" -delete"

            >You don't have to check anything on Windows!
            Oh, I forgot NTFS was case-insensitive

            • 6 months ago
              Anonymous

              What do you think 'bits&(1<<i)' should evaluate to? I think it will be 1 when bits==2^i and 0 otherwise. So what? You are fricking with this string like crazy but only checking it n times.

              • 6 months ago
                Anonymous

                I wrote that quickly and didn't test so there are mistakes. I'll just explain the algorithm I was going for.
                >undertale.exe is an array of characters which have two states: upper case and lower case (except . but we can ignore it since toupper and tolower return non-alphabet characters verbatim)
                >I want to try every permutation of the states, e.g. first try undertale.exe, then undertale.exE, then undertale.eXe, etc.
                >every time a character is tested in its two states, it and all characters to the right go back to state 0 and I then toggle the character to the left, and start again from the rightmost character
                >this is exactly the same as counting in binary
                >so to make it easier I make a bitset where each bit represents the state of the corresponding character in the string, and let the processor handle the "character i has been toggled twice, reset and toggle the character to its left" logic since the processor already knows how to count in binary

              • 6 months ago
                Anonymous

                There are 2^n possible strings but your code goes as n^2.

                i'll spoonfeed you: https://regex101.com/r/muxL87/1

                We are assuming we dont have a regex engine available, were turning it into a contrived interview problem.

              • 6 months ago
                Anonymous

                realistically unDertale.exe etc. aren't possibilities

                the if statements are fine as is, dev time shouldn't be wasted on moronic shit like this

                Though I guess he missed the "UNDERTALE.EXE" case which seems possible, but in any case Windows doesn't care about case at all so this is all pointless. It didn't function due to other reasons.

              • 6 months ago
                Anonymous

                My all tism demands that I point out that I was wrong in at least two ways here. It evaluates not necessarily to 1, but to "true" (meaning any nonzero value,) in the situations described, but there are more cases besides that where it comes out true. Even as moronic as I am the code is still moronicer though and doesn't accomplish what you want it to.

        • 6 months ago
          Anonymous

          You don't have to check anything on Windows!

          On MacOS, GNU and BSD all you have to do is "find ./ -type f -iname "*.exe" -delete"

          • 6 months ago
            Anonymous

            >all you have to do is "find ./ -type f -iname "*.exe" -delete"
            Oops, now all exes in the directory are deleted because the user was a moron and installed the game into a folder already containing other games

            • 6 months ago
              Anonymous

              A learning moment.

            • 6 months ago
              Anonymous

              You don't have to check anything on Windows!

              On MacOS, GNU and BSD all you have to do is "find ./ -type f -iname "*.exe" -delete"

              I'm shocked people bother with this and don't just use the PID of the running game to find the executable.
              Modern uninstallers avoid the problem the dropped version of Undertale had by deleting only files that match the hash value of a table of files

            • 6 months ago
              Anonymous

              Undertale installs on its own directory, no?

              The same command can be used but with "undertale.exe" instead of the wildcard and it will work.

        • 6 months ago
          Anonymous

          >i would write more than toby did to solve the same problem, see i am so much better
          Ganker is so moronic I swear

        • 6 months ago
          Anonymous

          This code is unreadable anon. Don't call us, we'll call you.

        • 6 months ago
          Anonymous

          no, what you would do is keep a reference to the handle/pid or whatever for the running process and with that you can probably get the name of the binary, kill and delete the game

          • 6 months ago
            Anonymous

            >no, what you do is help your gf put on her strapon and let her frick you in the ass, and with that you can probably get a reach around and nut in her hand

        • 6 months ago
          Anonymous

          but now do it in rust

        • 6 months ago
          Anonymous

          moron just do
          for char& in string
          char &= ' '
          then compare against 'undertale.exe'

          In almost every language they're functionally identical and take up the same level of complexity, the main difference is readability and organization
          if{}elseif{}else{} and case switches just iterate over a series of conditions and slam into the first one that resolves to true, or an available else or default case if it doesn't satisfy any

          YanDev's code, for example, isn't atrocious solely because of his overuse of ifelseif, but because the conditions he's trying to satisfy are logically expensive string comparisons and has repetition

          If you have a massive conditional statement you can probably refactor it into smaller chunks and more logically efficient code, but sometimes it has to happen

          t. software dev

          Not true. If statements execute sequentially, switch statements jump straight to the specified case (which is also why in every single language that I know of cases can only key off precomputed values).
          That not only means that switch statements typically have significantly improved performance over if blocks, but also that the evaluation of a switch case is guaranteed to have no side effects. It also means that changing the order of a switch statement should have no effect on the outcome of a program but changing the order of an if block often will (particularly if you're implicitly checking certain conditions).
          Depending on the language and the compiler you might get lucky with the optimiser (i.e. it might implicitly convert your massive if chain comparing the same value to a switch) but you shouldn't rely on it and it will often break if you try to get clever.

          You've already convinced me he's software engineer material, you don't need to go for the hard sell

          [...]
          True, hence why I said almost all languages. It also depends on the data type being used in the conditionals

          >It also depends on the data type being used in the conditionals
          I thought even in funky languages like javascript it still does something clever with converting the values to Symbols or something in order to cheat that efficiency.

          • 6 months ago
            Anonymous

            >for char& in string
            >char &= ' '
            wtf is that

            • 6 months ago
              Anonymous

              The binary values for lower case letters and capital letters differ only in whether the 32 bit is set.
              That means you can convert between upper and lower case by bit manipulating the characters.

              >switch statements jump straight to the specified case
              Depends on language and what the compiler/interpreter feels like at the time. With gcc small switch statements usually produce the same code as if-else chains while larger ones might be compiled to jump tables.

              >in every single language that I know of cases can only key off precomputed values
              Do you mean the token after "case" has to be a literal/constant? That is only true for certain statically compiled languages. C#, Python and Haskell (which is statically compiled) all allow variables to be used in (their equivalent of) case statements.

              >evaluation of a switch case is guaranteed to have no side effects
              There are languages that have this for the switch (and if/while/for) condition as well.

              >Depending on the language and the compiler you might get lucky with the optimiser (i.e. it might implicitly convert your massive if chain comparing the same value to a switch) but you shouldn't rely on it and it will often break if you try to get clever.
              I'd be surprised if the reason an optimiser didn't convert if-else chains to switch (when possible) was because it couldn't see the opportunity rather than because the heuristic it uses to decide what to do indicated using compare and branch/conditional instructions was better than making a jump table (or the optimisation wasn't enabled). You could test that by converting the if-else chain to switch yourself and seeing what the compiler spits out with different flags. Though, one of the many factors considered might be preserving programmer intent (when there isn't a clear benefit).
              You have to remember that there are tens-to-hundreds of factors and which ones are relevant and how important they are is both situation and architecture dependent. For example, if your CPU has no cache for computed branches, or it has a short history or small number of entries, the compiler may guess that jump tables are inefficient on that architecture.

              >Depends on language and what the compiler/interpreter feels like at the time. With gcc small switch statements usually produce the same code as if-else chains while larger ones might be compiled to jump tables.
              True, you can't know what you're going to get before hand and it only sometimes makes those optimisations.
              The fact that you can only perform direct comparisons to primitives and the original expression is only evaluated once (even in the case where it gets split into ifs the original result is computed and cached) again reduces the chance of unknown side effects or the value of an expression changing while you traverse the tree.
              >Python
              Python doesn't have switch, case bro - it has pattern matching.
              C# doesn't work as you describe and can only use constant labels.
              I don't know about Haskell but given your previous track record I don't trust you.
              >There are languages that have this for the switch (and if/while/for) condition as well.
              I wouldn't ever trust this. If I run an if tree with getGlobalVar() there's no way a compiler could ever optimise that away because it can't know the full side effects of getting that expression.
              Obviously you could (and should) cache the value of the expression before you run an if tree but the point is you don't have to for a switch.
              >You have to remember that there are tens-to-hundreds of factors and which ones are relevant
              Of course.

              I'll have to look into that, not doubting you but it's always been my experience that cases are resolved sequentially even in the compiled languages I've used. I'm interested in keeping my knowledge current.
              I currently work with a lot of deployment tooling in various scripting languages where order of operations and conditional evaluations are important, so we use if statements primarily

              It depends on your language and compiler and they have to be beyond a certain size for the optimisation to actually be valuable.
              I work in a large legacy c++ codebase with a couple of 5000+ line if trees where these sorts of considerations actually mattered.
              But also don't trust anything you hear on the internet and check the assembly output yourself.

          • 6 months ago
            Anonymous

            >switch statements jump straight to the specified case
            Depends on language and what the compiler/interpreter feels like at the time. With gcc small switch statements usually produce the same code as if-else chains while larger ones might be compiled to jump tables.

            >in every single language that I know of cases can only key off precomputed values
            Do you mean the token after "case" has to be a literal/constant? That is only true for certain statically compiled languages. C#, Python and Haskell (which is statically compiled) all allow variables to be used in (their equivalent of) case statements.

            >evaluation of a switch case is guaranteed to have no side effects
            There are languages that have this for the switch (and if/while/for) condition as well.

            >Depending on the language and the compiler you might get lucky with the optimiser (i.e. it might implicitly convert your massive if chain comparing the same value to a switch) but you shouldn't rely on it and it will often break if you try to get clever.
            I'd be surprised if the reason an optimiser didn't convert if-else chains to switch (when possible) was because it couldn't see the opportunity rather than because the heuristic it uses to decide what to do indicated using compare and branch/conditional instructions was better than making a jump table (or the optimisation wasn't enabled). You could test that by converting the if-else chain to switch yourself and seeing what the compiler spits out with different flags. Though, one of the many factors considered might be preserving programmer intent (when there isn't a clear benefit).
            You have to remember that there are tens-to-hundreds of factors and which ones are relevant and how important they are is both situation and architecture dependent. For example, if your CPU has no cache for computed branches, or it has a short history or small number of entries, the compiler may guess that jump tables are inefficient on that architecture.

          • 6 months ago
            Anonymous

            I'll have to look into that, not doubting you but it's always been my experience that cases are resolved sequentially even in the compiled languages I've used. I'm interested in keeping my knowledge current.
            I currently work with a lot of deployment tooling in various scripting languages where order of operations and conditional evaluations are important, so we use if statements primarily

        • 6 months ago
          Anonymous

          What if I changed the .exe to peepeepoopoo?

          The correct solution is to use the OS API to know the name of the current process

          • 6 months ago
            Anonymous

            Why would anyone change the .exe to peepeepoopoo??? WHY WOULD I EVER DO THIS, PLEASE RESPOND!>?@

          • 6 months ago
            Anonymous

            In that case you should be rewarded for your behaviour.

      • 6 months ago
        Anonymous

        >using regex
        noob

    • 6 months ago
      Anonymous

      dont think GM can do regex

    • 6 months ago
      Anonymous

      Why would you do that? There's a much simpler solution, just do:
      >for char1 in ['u', 'U']:
      >for char2 in ['n', 'N']:
      >for char3 in ['d', 'D']:
      >...
      >check and delete file named char1 + char2 + char3 + ...

      • 6 months ago
        Anonymous

        >13-layer nested loop

      • 6 months ago
        Anonymous

        This woulda been my way of doing it
        Figures I dont get any job offers kek

    • 6 months ago
      Anonymous

      i'll spoonfeed you: https://regex101.com/r/muxL87/1

    • 6 months ago
      Anonymous

      >not using .lower() for case testing
      these clowns

      • 6 months ago
        Anonymous

        >t. brainlet
        You're not testing the case of the string, you're generating the string and asking the OS if it names a file.

        i'll spoonfeed you: https://regex101.com/r/muxL87/1

        Doesn't relate

        There are 2^n possible strings but your code goes as n^2.
        [...]
        We are assuming we dont have a regex engine available, were turning it into a contrived interview problem.

        >There are 2^n possible strings but your code goes as n^2.
        I need to do more leetcode

        >i would write more than toby did to solve the same problem, see i am so much better
        Ganker is so moronic I swear

        >fails to see the difference

        This code is unreadable anon. Don't call us, we'll call you.

        >not knowing Ganker doesn't have code tags

        • 6 months ago
          Anonymous

          Why would you not just list all the files in the directory then use lower() to find it

        • 6 months ago
          Anonymous

          I think you just fricking tree recurse in the contrived leetcode situation, I don't think you can do meaningfully better.

        • 6 months ago
          Anonymous

          moron.

    • 6 months ago
      Anonymous

      Bait

  6. 6 months ago
    Anonymous

    toby knows ASM, just look at his earthbound hacks. there is a reason he did that in OP pic and its probably related to windows being moronic.

    >toby tried to do a nier save delete
    intredasting

    • 6 months ago
      Anonymous

      >Windows being moronic
      Windows' filesystem is not case-sensitive. UnDeRTALe.EXE is the exact same file as undertale.exe

      This is basic knowledge. Toby just didn't know.

    • 6 months ago
      Anonymous

      >Windows being moronic
      Windows' filesystem is not case-sensitive. UnDeRTALe.EXE is the exact same file as undertale.exe

      This is basic knowledge. Toby just didn't know.

      but what he did is valid for unix systems

    • 6 months ago
      Anonymous

      No, you fricking idiot, the romhacking tools were already in widespread use on starmen by the time he was doing anything there.

  7. 6 months ago
    Anonymous

    .toLowerCase()

    • 6 months ago
      Anonymous

      based as frick

      • 6 months ago
        Anonymous

        Toby can't do that because he doesn't know how to read file info, he only has a delete_if_exists system call

    • 6 months ago
      Anonymous

      moron

      • 6 months ago
        Anonymous

        No, you're the moron here. That Anon has if right. You only need to find via reference and then delete that way.

    • 6 months ago
      Anonymous

      That's what I'd do

  8. 6 months ago
    Anonymous

    *googles how to ignore upper case*

  9. 6 months ago
    Anonymous

    you do need to be creative and have a vision though, which is more difficult for most people than just getting good at programming

    • 6 months ago
      Anonymous

      Andrew hussy’s vision you mean

    • 6 months ago
      Anonymous

      More than that, you need to have a vision which is focused and achievable for the resources that you have

  10. 6 months ago
    Anonymous

    This is true. As a software architect I don't like to say it, but because of incompetence, lack of experience and the pressure from investors, closed-source applications are terribly messy. If you want to see and learn amazing code just check open source projects, but be advised you're are going to seethe because of huge egos and insufferable trannies in an extremely autistic environment.

    • 6 months ago
      Anonymous

      Well if its all about learning and bettering yourself, who cares how arrogant are the trannies who wrote the code? Its not like you gonna engage with them anyways

      • 6 months ago
        Anonymous

        >Its not like you gonna engage with them anyways
        this is true if you're not one of the people making decisions along with trannies. They're terribly hard to work with, because they feel the need to be the center of attention all the fricking time. It's basically having to deal with women's need for attention and focus on emotions in a male body full of anger and territorial behavior.

        • 6 months ago
          Anonymous

          I mean they have created some good projects online, so why not see what they have done correctly and better yourself? Of course they are hard to work with due to their mental state and their entitlement to their skills and sexuality, and small teams should focus on having reasonable people with reasonable skill level, but all Im just saying is that their code autism is a good source for education.

      • 6 months ago
        Anonymous

        > who cares how arrogant are the trannies who wrote the code?
        Oh you will care
        You'll care a bunch the second you have to interact with them.

        Which you will, because eventually the whole thing will terminate with some insane non-value like "return 1999" and you'll spend hours trying to find the catch that tells you what the frick that's supposed to mean. Which means it's time to put on your programmer socks and join "Devana's Sultry Torture Chamber" with gifs of Hello Kitty shitting everywhere and grown men talking about their bottom holes to ask what this does.

        • 6 months ago
          Anonymous

          this shit is 100% how coding autists all get trooned out. i've seen in real time some code troony try to 'crack' another coder's 'egg' on a public forum because he was wanting to ask how a library worked

          • 6 months ago
            Anonymous

            Trannies hate coding.

          • 6 months ago
            Anonymous

            >i've seen in real time some code troony try to 'crack' another coder's 'egg' on a public forum

          • 6 months ago
            Anonymous

            >i've seen in real time some code troony try to 'crack' another coder's 'egg' on a public forum because he was wanting to ask how a library worked

            I don't know exactly what this means, and I don't want to know

          • 6 months ago
            Anonymous

            >cognito hazards are real and mentally strenuous tasks lower your mental defenses

            • 6 months ago
              Anonymous

              >Stress makes you more susceptible to suggestion
              Yeah.

    • 6 months ago
      Anonymous

      >sharpness is not a metric

      • 6 months ago
        Anonymous

        Truly the Ganker of open source.

    • 6 months ago
      Anonymous

      I'm confident saying 85% of all coders are mere monkeys with no knowledge of data structures, algorithms and low level coding.

      • 6 months ago
        Anonymous

        And I'm sure that you're in the 15% of elites that have heard of an array before right

        • 6 months ago
          Anonymous

          I wish 🙁

        • 6 months ago
          Anonymous

          >get taught what arrays are
          >completely forget it after a week
          I haven't even touched an IDE in years...

      • 6 months ago
        Anonymous

        I don't actually believe that. Every single dev I've met was very competent. But I only ever spoke to system level devs with 30 years of experience, because those are my colleagues.

    • 6 months ago
      Anonymous

      >they always say it's a community effort
      >is filled with the most insufferable people known to man
      no wonder so many mentally ill people do it, you practically have to be

      • 6 months ago
        Anonymous

        It's always some c**t who wants to force their preferred result instead of making code that's malleable. Always. Every single fricking time.

  11. 6 months ago
    Anonymous

    Based and completely accurate. The code does not need to be good. Only autists care about that stuff.

    • 6 months ago
      Anonymous

      >The code does not need to be good

    • 6 months ago
      Anonymous

      >The code does not need to be good.
      It does if you plan to add anything to it later. If your software is one and done, just shit it out and forget about it. But if you're making a virtual toy or sandbox, you're going to end up molesting it for a long time so you'd better do it right.

    • 6 months ago
      Anonymous

      Well, he did fail to add the feature he wanted to add here, so maybe if he wrote better code he'd be able to do it.

  12. 6 months ago
    Anonymous

    He was using gamemaker, not really too surprising his coding was messy. Who cares if you're never going to see it anyways

  13. 6 months ago
    Anonymous

    What's a switch case statement?
    What is an "if" statement?

    • 6 months ago
      Anonymous

      nandgame.com

    • 6 months ago
      Anonymous

      If anon posts a question
      Ignore.
      If anon responds
      Print (you)

    • 6 months ago
      Anonymous

      >If
      If some condition is true, do the following block of code
      Else (the condition is not true), do this other block of code
      >Switch
      Here is a value. Switch to doing different blocks of code for each value case.

      • 6 months ago
        Anonymous

        In almost every language they're functionally identical and take up the same level of complexity, the main difference is readability and organization
        if{}elseif{}else{} and case switches just iterate over a series of conditions and slam into the first one that resolves to true, or an available else or default case if it doesn't satisfy any

        YanDev's code, for example, isn't atrocious solely because of his overuse of ifelseif, but because the conditions he's trying to satisfy are logically expensive string comparisons and has repetition

        If you have a massive conditional statement you can probably refactor it into smaller chunks and more logically efficient code, but sometimes it has to happen

        t. software dev

        Is a solid state machine typically the more efficient option over long, cryptic if/else statements?

        • 6 months ago
          Anonymous

          Depends on what you're doing. In the code of this infamous picture? Absolutely.

        • 6 months ago
          Anonymous

          Efficient? It Depends.
          A lot of people can be very efficient with passing around structs, data structures, state flags, as long as they remember where everything is and what it does.
          The problem is if you get in a web like

          Depends on what you're doing. In the code of this infamous picture? Absolutely.

          and you can't untangle yourself because you're now passing around so many state flags that you don't know which characters in the game are editing/change which flags at what time. Like picture two characters interacting with the player, and both of them change the same flags and go through the same if else statements with no exclusion whatsoever.

          That's why state machines are more efficient at this kind of check, purely because they put global variables in a scope.

        • 6 months ago
          Anonymous

          Another voice of agreement with "depends on what you're doing" as there's no one size fits all approach to programming as a whole.
          What I will say is don't fall into the trap of efficiency at all costs because rediscovering code you wrote a year ago is like reading hieroglyphics. Readability and consistency can sometimes be more important than shaving off a half-second of compute time

    • 6 months ago
      Anonymous

      In almost every language they're functionally identical and take up the same level of complexity, the main difference is readability and organization
      if{}elseif{}else{} and case switches just iterate over a series of conditions and slam into the first one that resolves to true, or an available else or default case if it doesn't satisfy any

      YanDev's code, for example, isn't atrocious solely because of his overuse of ifelseif, but because the conditions he's trying to satisfy are logically expensive string comparisons and has repetition

      If you have a massive conditional statement you can probably refactor it into smaller chunks and more logically efficient code, but sometimes it has to happen

      t. software dev

      • 6 months ago
        Anonymous

        yandev also doesn't know what enums, arrays or state machines are.

        • 6 months ago
          Anonymous

          Yandev doesn't know what a lot of things are and that's why his code is subpar. He's going at it like a monkey on a typewriter and committing the first thing that works and builds. Testing is for people who aren't confident in their code and comments should be unnecessary for people who can read it.

          You know what, he'd make a solid junior dev at any company.

          • 6 months ago
            Anonymous

            Not knowing what things are isn't even the biggest problem, it's his stubbornness.

            • 6 months ago
              Anonymous

              You've already convinced me he's software engineer material, you don't need to go for the hard sell

              No quite, switch statements sometimes get converted into hashmaps by the compiler which are o(1) and not o(n)

              True, hence why I said almost all languages. It also depends on the data type being used in the conditionals

              • 6 months ago
                Anonymous

                Yeah but generally you'll never get punished for using switches so most multi conditionals will benefit from switch vs if/else

      • 6 months ago
        Anonymous

        No quite, switch statements sometimes get converted into hashmaps by the compiler which are o(1) and not o(n)

  14. 6 months ago
    Anonymous

    >tfw file is called "Undertale.EXE"

  15. 6 months ago
    Anonymous

    Yes we all watched the video.

  16. 6 months ago
    Anonymous

    I can't even begin to wrap my head around programming shit. It looks like a bunch of random words and letters organized in a way that makes no sense, and I have to remember every single use case.

    • 6 months ago
      Anonymous

      >I have to remember every single use case.
      If you're using a fairly simple language, there isn't much to actually remember, instead you're constantly dealing with stuff people have made up and defined on the fly, which are defined in terms of other things you can look up in other parts of the program and most of the effort in practice is going to be learning what a particular thing does in a particular program and how to manipulate that to do what you want without stuffing up the program as a whole.

      Complex languages can have really obscure shit to deal without though.

    • 6 months ago
      Anonymous

      learning to program is like learning a new language
      *bdum tss*

  17. 6 months ago
    Anonymous

    In the end it wouldn't have worked anyway because Game Maker sandboxes your file operations to an appdata folder
    Also a program can't just erase itself that easily

    • 6 months ago
      Anonymous

      undertale.exe is a zip file with actual undertale.exe inside itself. it might not be able to delete itself entirely that easily, but it could probably modify itself without too much trouble.

      • 6 months ago
        Anonymous

        So programs can generate commands to delete executables? Doesn't the operating system impose any restrictions on this?

  18. 6 months ago
    Anonymous

    >All of the dialogue in all of Undertale is in a single switch case statement
    Yeah that's generated code dumbass.

    • 6 months ago
      Anonymous

      It's not. Decompiled GM code is actually very close to the original

  19. 6 months ago
    Anonymous

    Well when you're making what is essentially a moviegame with barely any gameplay sure, then you don't need to know proper code. But even a basic b***h racing game requires proper knowledge of code to make it function at all, let alone make it bug-free or optimize it.

  20. 6 months ago
    Anonymous

    >game deletes files off your computer without asking
    This is called a virus. A shitty one, but still a virus.

    • 6 months ago
      Anonymous

      its immersion

    • 6 months ago
      Anonymous

      >deletes its own files
      If only you knew how many programs you use daily do this...

  21. 6 months ago
    Anonymous

    I fricking love seeing RPG Maker spaghetti shit code like you wouldn't believe. Makes me hard as a fricking rock.

    • 6 months ago
      Anonymous
      • 6 months ago
        Anonymous
        • 6 months ago
          Anonymous
          • 6 months ago
            Anonymous

            >menu position "code" is based entirely on cusor's literal on-screen x/y position
            Imagine being the guy who changes his mind about the menu layout months into the project and realizing you just have to fricking start over

            • 6 months ago
              Anonymous

              Can't do much about it in RPG Maker eventing. Unless you want to write a plugin instead.

              • 6 months ago
                Anonymous

                Lol I never knew RPG maker was THAT bad. I knew it was bad, but that's an entirely other level of stupid.

              • 6 months ago
                Anonymous

                I mean you can write a plugin instead of forcing yourself to do it with in-engine eventing, but yeah.

                [...]
                It's absolutely doable in RPG Maker, this dude's just fricking moronic.

                That said I am not sure what exactly the dude is trying to achieve.

                It's not a maniacs game
                I'd just opened it in the maniacs editor to poke through the code to see how moronic the dev was.
                As it turns out, pretty fricking moronic. It's really no wonder it took him 11 years to make a remake of the simplest possible JRPG one can make, Dragon Quest 1.
                And he managed to make it chug on AMD systems with less than 32 GB of ram somehow.

                Oh it's fricking DQ1 kek

              • 6 months ago
                Anonymous

                Lol I never knew RPG maker was THAT bad. I knew it was bad, but that's an entirely other level of stupid.

                It's absolutely doable in RPG Maker, this dude's just fricking moronic.

              • 6 months ago
                Anonymous

                >Make an array and change a pointer to move through your "internal" menu
                >Change cursor position completely separate from that for your "dispay" menu
                It's not difficult to make simple, easily expandable/shrinkable/changeable custom menus and battle systems in even RPG Maker 2000.
                There are just too many morons out there who never once use basic logic to approach the problem-solving one must do.

              • 6 months ago
                Anonymous

                RPG Maker eventing had arrays?

              • 6 months ago
                Anonymous

                Yes, you literally just pick a place in your variables (aka your MEMORY) and say "yep, this is an array for now" and use it as such.
                The engine/documents/etc obviously don't tell you this, and you're basically LARPing as a high-level assembly programmer at that point, but you most definitely can use arrays in RPG maker 2k/3.

              • 6 months ago
                Anonymous

                Was thinking older engines had a literal in-engine array system but I guess you could try some fancy shit.

              • 6 months ago
                Anonymous

                Why would you want individual variables for each menu choice? Am I being moronic?

              • 6 months ago
                Anonymous

                For literally anything and everything?
                >Populate a list of items with the item's ID and Quantity
                >Now you have an array with 2 params
                >Populate a list of basic options in battle that may be different for each character (think "attack" "defend" "bushido" "morph" "black magic" etc)
                >Now you have an array with as many options as you do unique character options
                >Want to make your normal in-game menu options movable to any position for some reason ("item" "status" "save game" "config" etc)
                >populate an array with those choices and allow the player to reposition them as they see fit
                >Have party members and want to keep their statistics somewhere for a custom menu & battle system
                >take a brick of 100 variables (major overkill) and dump the data there
                >can now use it for whatever the frick you want
                The question is, why WOULDN'T you use arrays?

              • 6 months ago
                Anonymous

                Well shit, thanks a bunch for this anon. I'd already been using arrays, yet clearly I'd become complacent and didn't bother expanding my knowledge on how to use them. This is absolutely eye opening, and actually potentially solves a huge issue I'd been having making my own battle system (I've been hard-walled by it for a while).

              • 6 months ago
                Anonymous

                Just remember, pointers and arrays make you smart.
                You'll still do dumb shit with them for a while as you get a handle on them, but they will open up many doors for you in both the short term and the long term.

              • 6 months ago
                Anonymous

                fricked up something in the original picrel, but you get the gist of it I hope.

              • 6 months ago
                Anonymous

                I've seen so many people doing it in /vrpg/ yet I still don't know how to do it. Do i understand it? yes. Do I know how to make it? no.

                I gave up on my reccettear clone because otherwise I would be forced to use pure rpgm eventing system (like hell I'm doing that kind of work)

              • 6 months ago
                Anonymous

                The only way to figure out the "make it" part is to try.
                Stop by /vrpg/ and ask around if you need further information.

              • 6 months ago
                Anonymous

                I tried, but just couldn't
                if only they have better switch/variable system

              • 6 months ago
                Anonymous

                >using anything newer than 2k3
                Unfortunately, the makers got worse and worse, removing critical features the more they went on. The newer makers don't even have a normal way to use indirect variable reference, for frick's sake.
                IIRC, the VX/a and MV/MZ flat out allow you to declare true arrays with the Script Call feature, but I don't use any of those makers so I really can't remark on this.

              • 6 months ago
                Anonymous

                vx ace let me write my own simple code, yeah I can do it with eventing but it's really time consuming

              • 6 months ago
                Anonymous

                >using anything newer than 2k3
                Unfortunately, the makers got worse and worse, removing critical features the more they went on. The newer makers don't even have a normal way to use indirect variable reference, for frick's sake.
                IIRC, the VX/a and MV/MZ flat out allow you to declare true arrays with the Script Call feature, but I don't use any of those makers so I really can't remark on this.

                >using a gooey for flow control variables

              • 6 months ago
                Anonymous

                fricked up something in the original picrel, but you get the gist of it I hope.

                I'm familiar with pointers and arrays thankfully, I've just become very aware how inexperienced I was with them. Again, thanks for this anon, this is exactly the thing I needed to get my momentum back

            • 6 months ago
              Anonymous

              And the world-famous dash code from Trial & Error

              • 6 months ago
                Anonymous

                >if
                >if
                >if
                damn it, why not just create a boolean can_run or something that changes when equipping shit etc and just check that instead of if every damn thing?

          • 6 months ago
            Anonymous

            This screenshot proves it's being done with the maniacs patch. Why the frick aren't they doing any of this smarter with String Variables?

            • 6 months ago
              Anonymous

              It's not a maniacs game
              I'd just opened it in the maniacs editor to poke through the code to see how moronic the dev was.
              As it turns out, pretty fricking moronic. It's really no wonder it took him 11 years to make a remake of the simplest possible JRPG one can make, Dragon Quest 1.
              And he managed to make it chug on AMD systems with less than 32 GB of ram somehow.

          • 6 months ago
            Anonymous

            >all that for a counter
            what the frick

          • 6 months ago
            Anonymous

            >Parallel Process
            >Label jumping back to the top anyway
            Why the frick do people do this

          • 6 months ago
            Anonymous

            What the frick am I reading

    • 6 months ago
      Anonymous

      Undertale is not RPG maker though.
      >those skill names
      Dragon Quest fangame?

    • 6 months ago
      Anonymous

      You know modern RPG maker compiles down to that, right? As in the source code is written normally then later it unrolls everything and has 10 billion jump tables.

      • 6 months ago
        Anonymous

        nta, but as if your point means anything when code is so abhorrent to read
        can't wrap my head around the fact that rpgmaker is even considered a babby's first engine, coding everything using dropdowns felt like a nightmare, even visual scripting seems better in comparasion
        and while i have 0 idea how rpgmaker actually works on the inside, i can confidently say that even real compilers can't optimize all IF bullshit, switch is not always a replacement
        especially if there's a user-inserted JUMP every-fricking-where

  22. 6 months ago
    Anonymous

    daily reminder that the guy telling you to do this got all his jobs via nepotism, and has been making a quirky earthbound-like for 6 years.

  23. 6 months ago
    Anonymous

    del UNDERT~1.EXE

  24. 6 months ago
    Anonymous

    When I make something, I am always afraid I might make like some kind of infinite loop and blow up a PC. That can't happen right?

    • 6 months ago
      Anonymous

      Infinite loop just softlocks the game

    • 6 months ago
      Anonymous

      The worst you could do is create a memory leak which chugs the app and the it crashes. Your PC will be fine because it’s designed to deal with stupid shit like that without breaking anything.

    • 6 months ago
      Anonymous

      The worst you'll do to a modern OS is lock your application's threads, and then the drivers will do whatever they do to cope with that. In Windows' case, probably just flag the app as non-responsive or bluescreen. You have to really know what you're doing to actually hurt the hardware.

    • 6 months ago
      Anonymous

      just add a counter to all your loops for i<really big ass number

  25. 6 months ago
    Anonymous

    So, if i change my game into Black person.exe, it cant delete shit?

    • 6 months ago
      Anonymous

      >Black person.exe has stopped working
      you should have gone with chink

  26. 6 months ago
    Anonymous

    Makes sense, Toby was literally just the music guy for Homestuck before Undertale.
    Good on him for managing to make his own game.

  27. 6 months ago
    Anonymous

    I loved and thenn hated the game when that gay wouldn't stop calling me and that stupid ass robot. But I finished it last night and saw picrel and finally understand why people liked it, and why it's a literal earthbound ripoff with the insane bad acid trip like ending.

    • 6 months ago
      Anonymous

      Also, the whole game should've been like this with a full screen area, not just this.

    • 6 months ago
      Anonymous

      >acid trip earthbound
      hylics did it better

    • 6 months ago
      Anonymous

      >if you add weird shit to your game you're ripping off earthbound

    • 6 months ago
      Anonymous

      Garbage. You can't lose it's basicaly just a cinematic.

  28. 6 months ago
    Anonymous

    When did you realize that coding / programming is a midwit hobby?

    • 6 months ago
      Anonymous

      When I realised I was somewhat good at it.

  29. 6 months ago
    Anonymous

    how do i fix this i'm going insane i just literally want my character to turn. well he does turn but then i get this

    • 6 months ago
      Anonymous

      Why are you subtracting the velocity to get your target vector?

      • 6 months ago
        Anonymous

        because it works?

        • 6 months ago
          Anonymous

          Why would you not use that direction vector you just calculated? From what I’m seeing the error is based on the fact that when your velocity is zero you’re telling it to look at itself and it doesn’t know how to accomplish that

    • 6 months ago
      Anonymous

      it's telling you exactly what's happening, the character is in the same position as the target of the look at, so you can't define a direction that goes from the first to the other. also for the two lines above do speed = max(speed+1, max_speed)

    • 6 months ago
      Anonymous

      velocity is zero, hence transform.origin - velocity = transform.origin. you're trying to look from origin to origin.
      evidently you thought velocity would not be zero but it can be at least some of the time.

      it's telling you exactly what's happening, the character is in the same position as the target of the look at, so you can't define a direction that goes from the first to the other. also for the two lines above do speed = max(speed+1, max_speed)

      you mean min(), not max()
      your code will set the character's speed to the max every time.

    • 6 months ago
      Anonymous

      >using velocity for the look vector instead of the input direction

    • 6 months ago
      Anonymous

      Why is that code nested under the "if input_dir" line? Does this error only happen when you're standing still? That's probably why. Put the call to look_at somewhere else.

      • 6 months ago
        Anonymous

        Also don't use velocity for that anymore.

  30. 6 months ago
    Anonymous

    how would that work? isn't the exe is being opened when the code is executed?

  31. 6 months ago
    Anonymous

    still better than anything a building full of indians could produce

  32. 6 months ago
    Anonymous

    Just finished neurtral, do I got genocide or pacifist next?

  33. 6 months ago
    Anonymous

    windows won't let you delete a file that's currently being used and i'm 99% sure the exe is held by the filesystem when its being executed

  34. 6 months ago
    Anonymous

    Just nerds being gays. You constantly improve at everything you do by doing it if that's the way you learn best. Frick anyone shitting on someone who made a really successful game, for just going for it and figuring it out on the fly. This is what happens when you go to some gay programming school instead of learning at as a means for a creative project.

  35. 6 months ago
    Anonymous

    Thats gotta be intentional obfuscation at this point

  36. 6 months ago
    Anonymous

    i would be even worse programmer. i consider myself decent at logic but am defeated by syntax

    • 6 months ago
      Anonymous

      Syntax is really just memory and practice with a specific language. As long you understand programming logic, at the end of the day you are doing mostly the same shit.

  37. 6 months ago
    Anonymous

    Oh frick yeah i loved learning about decoupling so i could spend 10 hours autistically writing a hello world script where every infinitesimally specific function was modularised and performing white box testing on my 4 lines of code

  38. 6 months ago
    Anonymous

    While a stupid implementation, the fact that he made multiple IF lines instead of a single OR || case makes me feel better about myself. Guess I'm not as stupid as I initially thought.

    • 6 months ago
      Anonymous

      Lol it makes perfect sense given different filenames get deleted in each case and you'd have to use a variable to track that otherwise.

  39. 6 months ago
    Anonymous

    Why did he abandon this feature?

    • 6 months ago
      Anonymous

      He couldn't get it to work.

      • 6 months ago
        Anonymous

        the .exe probably can't delete itself while running
        perhaps he could have launched another executable say "deleter.exe" from within undertale.exe, killed the program, then let deleter.exe do its work.
        But that would also have some OS specific dependencies and maybe some security/permissions issues idk, I've never needed to do that in my language of choice but I believe it is possible.

        • 6 months ago
          Anonymous

          what's the point of this anyway? if he wants to be edgy just delete the save file

          • 6 months ago
            Anonymous

            I dunno, it's a fun idea but not critical I guess

  40. 6 months ago
    Anonymous

    I learned arrays in game maker and it turns out they work the opposite way in every other language. It's very confusing

  41. 6 months ago
    Anonymous

    >the game deletes its files without your permission
    gay and utterly moronic, borderline malware considering that moron can't into code and could've fricked up something

  42. 6 months ago
    Anonymous

    >thinks he's yoko taro
    kwaf

  43. 6 months ago
    Anonymous

    Or all cases were used because shit like that changes depending on some of the most mundane settings.

  44. 6 months ago
    Anonymous

    You just copied Thor, but it's good advice anyways, so that's okay.

  45. 6 months ago
    Anonymous

    I already am. It's gonna be in Javascript because I'm a brainlet but some early tests with Tauri are proving promising, much better than Electron so far.

    I'm still wondering if I should hire a narrative designer or something though. Can't imagine Chris Avellone is very busy these days.

  46. 6 months ago
    Anonymous

    I can do hello world in html and php, it is the full extent of my programming capabilities

    • 6 months ago
      Anonymous

      does html and php even count as programming

      • 6 months ago
        Anonymous

        I guess if you use a script block in html

      • 6 months ago
        Anonymous

        i suppose scripting is more correct

      • 6 months ago
        Anonymous

        technically speaking no, because html is not a programming language, it's a markup language

      • 6 months ago
        Anonymous

        PHP does. HTML is more like a markup language.

      • 6 months ago
        Anonymous

        Yes.
        >t. professional XML programmer

    • 6 months ago
      Anonymous

      I also used to make some goofy map in worldedit with jass to play with my friends.

  47. 6 months ago
    Anonymous

    Ok so all regex Black persony aside, couldn't he at least save llike 3 if checks by doing a toUpper()?

  48. 6 months ago
    Anonymous

    Except Toby's moronation did negatively impact his game.
    >Shmup that runs at 30 fps because Toby was too fricking stupid to set the fps to 60 (which is absurdly easy in gms).
    I bet he coded object speed like a moron and couldn't change the fps without making everything twice as fast.

    • 6 months ago
      Anonymous

      didnt gms1 still let you set the fps per room?

  49. 6 months ago
    Anonymous

    I am a programmer but programmer are the worse people in the world. they are either pajeet tier morons or freakazoids that brag about their intelligence while looking like subhumans.

    why is it that techtards can't be humble?

  50. 6 months ago
    Anonymous

    I know programming but not enough to make a game and just get lost looking at it or other stuff with their own libraries or affect system files.

    that said I'd use regex with

    /underale.exe/i

    I wouldnt know how to write code to delete a file with that though.
    That's beyond me all i can do is make .txt files.
    I wish I knew how to do other stuff.

  51. 6 months ago
    Anonymous

    It doesn't matter because undertale is atari tier pixel art on an incredibly simplistic engine. As long as it works, which it does, it's fine.

  52. 6 months ago
    Anonymous

    not fixing things is sort of a talent in itself. productivity-wise, it's better to save all the crap that shouldn't be prioritized towards the end, or not at all if it doesn't even matter. if it were me, i'd be refactorizing for days, only to repeat the process again sometime after because of changing requirements

  53. 6 months ago
    Anonymous

    I'm working on a few game prototypes right now but it's really disheartening to know I would be in the top 1% of steam games if I made even $1000.

    If I spend a year making a game for a $1000 return, that's less than a Chinese factory slave would earn in that time.

    The tools to make the games I'm interested in finally exist, but they exist for everyone, so now there's no point. Fricking sucks.

    • 6 months ago
      Anonymous

      You have to remember that 95% of steam games are asset swap slop.

  54. 6 months ago
    Anonymous

    the stupid thing here is more that `file_exists` is case-sensitive. What a moronic function

    • 6 months ago
      Anonymous

      Why in the frick would file_exists NOT be case sensitive?

      • 6 months ago
        Anonymous

        on windows you cannot have two files with the same name even if the cases are different. And the whole idea of doing that anyway is fricking moronic and confusing and should be prohibited in Linux too

  55. 6 months ago
    Anonymous

    >word for word copies of youtube shorts are considered threads now

    • 6 months ago
      Anonymous

      >now

      • 6 months ago
        Anonymous

        >suddenly

  56. 6 months ago
    Anonymous

    So what? It takes effort and I can no longer focus on anything more than a few seconds in length before the "intrusive thoughts" start up again.

  57. 6 months ago
    Anonymous
  58. 6 months ago
    Anonymous

    >Want to learn Rust so I can use it for web programming and game development
    >Rust discord is full of troons
    How did this happen?

    • 6 months ago
      Anonymous

      troons flock to FOSS, i don't know why

    • 6 months ago
      Anonymous

      >r̶u̶s̶t̶ discord is full of troons
      fixed for you

      • 6 months ago
        Anonymous

        Really this, discord users as a demographic are awful

    • 6 months ago
      Anonymous

      >Rust

    • 6 months ago
      Anonymous

      homie Rust unironically sucks
      Go learn a real language, like C#

      • 6 months ago
        Anonymous

        >learn a real language, like C#

        • 6 months ago
          Anonymous

          Hey, it's a real language
          It might be shit, but it's actually used irl

          • 6 months ago
            Anonymous

            I only use COBOL

            • 6 months ago
              Anonymous

              homie are you from like the 1940s or something

        • 6 months ago
          Anonymous

          >homie Rust unironically sucks
          A memory-safe programming language is infinitely more interesting than some trash like fricking C#.

          These people don't have jobs

          • 6 months ago
            Anonymous

            >t.indie unity dev

        • 6 months ago
          Anonymous

          Despite its popularity among street shitters, C# is a legit language with tons of useful libraries and support for a wide array of applications. I would argue C# is the best language to get shit done quickly on the application layer.

      • 6 months ago
        Anonymous

        >homie Rust unironically sucks
        A memory-safe programming language is infinitely more interesting than some trash like fricking C#.

        • 6 months ago
          Anonymous

          >memory-safe programming language
          Rustards are fricking hilarious.

          • 6 months ago
            Anonymous

            >Pajeet has no real retort
            Don't make me redeem, b***h.

      • 6 months ago
        Anonymous

        holy based
        I had the .NET 8 release on my calendar

      • 6 months ago
        Anonymous

        >pot calling the kettle a Black person

    • 6 months ago
      Anonymous

      Rust is for pseuds who tried C++, couldn't understand it, but don't want to admit that they should use Java or C# instead.

    • 6 months ago
      Anonymous

      >discord is full of troons
      No shit. I don't understand why anyone would actually join any discord server besides their friends'.

      • 6 months ago
        Anonymous

        >I don't understand why anyone would actually join any discord server besides their friends
        I don't have any friends and I want to pass the time.

  59. 6 months ago
    Anonymous

    Just goes to show that through pure determination you really can do whatever you want. Including making a game with no programming skills.

    The concept of doing things through pure determination is a concept in undertale itself so it makes sense that Toby embodies that.

  60. 6 months ago
    Anonymous

    Reminder that if you get hung up on stuff like this while programming you will never, ever make a game.
    Stuff like this runs once, ever, who cares if it’s non-optimal?
    As long as you’re not hitting yandev levels of jank it’ll be fine.
    (I’m aware it didn’t work at all in this case but this is more in regards to the discussion)

    • 6 months ago
      Anonymous

      Incorrect
      If you code something that becomes too difficult to work with, the likelihood of you completing your game drops off hard.
      I've seen it surprisingly often - someone codes themselves into a nightmare tangled web of shit that they can't even muster the courage to try and fight with at some point and just drop it.

      • 6 months ago
        Anonymous

        For me, its naming all of my assets goofy shit and not being able to find what I need quickly. It seems funny at the time, but I now see the importance of strict naming conventions.

        • 6 months ago
          Anonymous

          Or use comments. They aren't just for group projects, fellas.

      • 6 months ago
        Anonymous

        I have a friend who makes games, pretty good programmer, who picked an old game back up after like five years of shelving it. He wasn't happy how shitty the coding was and kept running into walls. He ended up having to refactor quite a bit of code.

      • 6 months ago
        Anonymous

        That would be the yandev shit.
        But this is a one-off. A gimmick one-off at the complete ass-end of the game with no other game systems attached. It's the perfect candidate for "as long as it works who cares".
        You need to identify what's worth actually focusing on.

  61. 6 months ago
    Anonymous

    poor coding = wasted cpu cycles
    wasted cpu cycles = wasted electricity
    wasted electricity = more fuel being burned
    more fuel being burned = more shit in the atmosphere

    if you code poorly, you are literally killing the planet, frick you

    • 6 months ago
      Anonymous

      Unless you support nuking china and india don't speak a single word about pollution.

      • 6 months ago
        Anonymous

        >Unless you support nuking the US don't speak a single word about pollution.
        Fixed

        • 6 months ago
          Anonymous

          >Fixed

  62. 6 months ago
    Anonymous

    Wouldn't this just throw a "file is currently opened in other window" type error?

  63. 6 months ago
    Anonymous

    Can't you just compartmentalize everything?
    As in you program one thing and have it be self contained and then you can just copypaste it in all of your projects

    • 6 months ago
      Anonymous

      Based modular coder, you have an extremely bright future as a c++ dev
      Big companies do this, and they have what are called 'Glue engineers' who put all of the modules together.

    • 6 months ago
      Anonymous

      to a certain extent but it's not universal and you will have to write custom code regardless

    • 6 months ago
      Anonymous

      Good coders recycle their tools, sure.

    • 6 months ago
      Anonymous

      That's how you destroy performance. General/abstract is ALWAYS worse until proven otherwise.

  64. 6 months ago
    Anonymous

    Where can I find the source code for Undertale?

    • 6 months ago
      Anonymous

      https://letmegooglethat.com/?q=undertale+source+code

  65. 6 months ago
    Anonymous

    Is Godot Good?

    • 6 months ago
      Anonymous

      Please Respond

  66. 6 months ago
    Anonymous

    >unemployed autists scrutinizing some teenager's indie game spaghetti code
    Maybe if you had ambition or talent you could make a gorillion dollars like toby instead of spending your saturday mornings solving leetcode problems on Ganker.

    • 6 months ago
      Anonymous

      >unemployed

  67. 6 months ago
    Anonymous

    what's the point of coding? i make a killing on patreon, and took the timmy tencent deal and i did everything in spaghetti blueprints.

  68. 6 months ago
    Anonymous

    >it's the year of our lord 2023
    >there are anons that do not know of Toby's spaghetti code
    newbies, not even once.

  69. 6 months ago
    Anonymous

    Write your code as shitty and indecipherable as possible just so when you get laid off and pajeets have to maintain your code they will have a miserable time working with code worse than their own.

  70. 6 months ago
    Anonymous

    Who the frick would implement case sensitive file systems lmao

  71. 6 months ago
    Anonymous

    So programs can generate commands to delete executables? Doesn't the operating system impose any restrictions on this?

    • 6 months ago
      Anonymous

      Depends on the OS but generally when a user starts a program the program inherits the permissions of the user. Some OSes (e.g. smartphone OSes, Linux with SELinux) may restrict at the API level but older OSes often have no way to distinguish "user asked file browser to delete the file" from "file browser deleted the file of its own accord".

  72. 6 months ago
    Anonymous

    Literally just :
    -get a list files that end in .exe in the folder,
    -check if the ToUpper/ToLower is undertale,
    -store the index of the match in the list,
    -get the filename by index in the list
    -delete that file.
    Someone cleverer than me could probably come up with an even better way to do it

  73. 6 months ago
    Anonymous

    How do I learn programming so I can make my own game?

  74. 6 months ago
    Anonymous

    You could be called Kaze Emanuar and take everyone elses ideas and call it your own. Literally all he does is edit already known N64 optimizations and calls himself a genius.

    • 6 months ago
      Anonymous

      i'm sure you'll be providing the proof for this.

      • 6 months ago
        Anonymous

        What? The N64 library and hardware has had its documentation leaked for years now. There are hundreds of people who spend their free time vetting and optimizing the leaks yet he takes those ideas and pretends its his own. All he did was make some levels in Mario 64 editor. Big deal.

  75. 6 months ago
    Anonymous

    Anons should take this as you don't need to be a master before working on a project. Think about all the failed projects of people who had zero self esteem and were too critical of themselves, only to cope by larp as a intellectual online. You should do it now.

  76. 6 months ago
    Anonymous

    Aren't there better ways to identify a file than its filename? Sorry if the question is dumb but wouldn't it be easier to find by filesize, or it being the only exe in the folder?

    • 6 months ago
      Anonymous

      >find by filesize
      Hell no.
      See

      [...]
      I'm shocked people bother with this and don't just use the PID of the running game to find the executable.
      Modern uninstallers avoid the problem the dropped version of Undertale had by deleting only files that match the hash value of a table of files

  77. 6 months ago
    Anonymous

    frick off, pirate software. You have less than one game under your belt and paid youtube to shill your dogshit content

  78. 6 months ago
    Anonymous

    What exactly is wrong about doing this? Was this supposed to make me like this twitter Black person? I don't know anything about coding and I've never made a videogame. Who the frick am I to judge?
    This dude seems like a turbo homosexual with frick all to show for it.

    Watch anything about coding for 10 minutes on youtube. It's painfully boring and its almost unbelievable anyone could make a game writing this garbage out in a .txt file or whatever.

  79. 6 months ago
    Anonymous

    Where is YOUR game, OP?

  80. 6 months ago
    Anonymous

    This is the extent of my knowledge of "coding".

    I feel like a brainlet.

  81. 6 months ago
    Anonymous

    As a complete amateur myself I have found videogame programming to be very similar to producing a stage show. As long as the show goes off without a hitch to the audience, it doesnt matter what kind of bullshit youre pulling behind the scenes. Its seriously just "do it however you can as long as it works".

    • 6 months ago
      Anonymous

      Sounds like how James Rolfe operates

    • 6 months ago
      Anonymous

      I've been a professional software dev for over a decade, and that's how it is anywhere, honestly. Readable and maintainable code is important if the codr needs to be read or maintained. If it's something you're just going to make once and forget about, then it doesn't even really matter except for your own fastidiousness. I tend to try writing really beautiful and clean code in my own home projects, but then I almost never get anything fully finished either lol.

      Also, people vastly underestimate the cost of "good" code. It's normal for software devs to make around $100k even in shitty jobs at low-cost-of-living places. So if you have 3 guys work on something for a year, that's $300k for your project right there. This is how most pitches for apps and junk die, and why most indie devs do it themselves or sucker a friend into doing it for peanuts.

      • 6 months ago
        Anonymous

        IIRC dev'd the game alone and only had help for some key art by Temmie chang (like the sprites for the opening cinematic) and also had some lines coded/checked by friends for some specific animation work or tweaking GM's engine because apparently it was a pain in the ass to make the tiles for the overworld work seamlessly. Also some beta testers obviously.
        The game was made on a $50k budget over a few years so it's really impressive considering the game isn't buggy at all.

  82. 6 months ago
    Anonymous

    You can always spot a bad programmer by how quickly they are to call code messy and bad.

  83. 6 months ago
    Anonymous

    >not checking argv to get the executable name
    Holy shit imagine getting filtered this hard

  84. 6 months ago
    Anonymous

    Is this Ganker's way of coping with the fact that Undertale was a smash hit and Toby Fox managed to exploit his talents to compensate for his shortcomings ? His code works, his music is played by multiple orchestras worldwide and even Ganker comes daily to the thought of chapter 3 of Deltarune.

  85. 6 months ago
    Anonymous

    The lesson here is when shit goes down, Toby ain't gonna have to your back.

  86. 6 months ago
    Anonymous

    Is there some reason that newbies to programming always think they're smart for pointing out that lots of IF statements are bad? Also, often times the examples they provide aren't even that bad to begin with

    • 6 months ago
      Anonymous

      There's nothing wrong with lots of if statements.

      • 6 months ago
        Anonymous

        I know. I'm asking why noobs specifically keep bringing it up as a gotcha. Is it taught that way in colleges now or something?

        • 6 months ago
          Anonymous

          half are moron nodev homosexuals
          the other half are pedantic swedes

    • 6 months ago
      Anonymous

      Most of them are dunning kruger homosexuals that don't know the first thing about programming, but saw how people were making fun of yanderedev's code and took that to mean any if statement whatsoever is bad instead of just the way he used them.

    • 6 months ago
      Anonymous

      I know. I'm asking why noobs specifically keep bringing it up as a gotcha. Is it taught that way in colleges now or something?

      Branching is like the 3rd thing you get introduced to when you start programming so everyone is familiar with it.
      Because it's also generally powerful enough to solve most simple problems on its own with enough stubbornness it's also frequently misused by novices.
      Because of that genuinely good advice (i.e. use switch for large comparisons to primitives, don't nest ifs repeatedly) gets parroted, misused and misunderstood by noobs who think they understand more than they do.

      There's nothing wrong with lots of if statements.

      Not inherently, but it's almost always representative of bad design.
      Massive switch statements saying if [state] == "string" are a good sign that polymorphism would be a better fit instead, for instance.
      They can also have trouble scaling and become extremely confusing if the state changes while you're checking it.
      Sometimes they're unavoidable (i.e. if you're implementing scripting) but you should make sure your architecture is the best fit for your design.

  87. 6 months ago
    Anonymous

    Wasn't it made in GameMaker? I had a gamemaker community account since 2003.

  88. 6 months ago
    Anonymous

    Undertale is a relatively simple game. The more complex game you want to make, the better your code should be (and your skills too). That's why Toby now makes another Undertale-like game, and not a something new.

    • 6 months ago
      Anonymous

      As long as the structure of your code is clean and the logic isn't on a performance critical path you can do some pretty lazy and disgusting stuff without getting punished.
      The problem is if you make the wrong call and have to rewrite a lazy implementation that is tightly coupled to the rest of your program very late into development.

  89. 6 months ago
    Anonymous

    Trump was unfairly targeted by the media.
    Hitler's downfall exaggerated by historians.
    Le Pen's loss was due to election fraud.
    Putin is actually winning against Western propaganda.
    /misc/ is a bastion of free speech against liberal censorship.
    /qa/ is uncovering deep state secrets.
    The Nazis were misunderstood and maligned by biased education.
    The Tsarists were victims of a communist conspiracy.
    Fascist Italy was destabilized by foreign interference.
    Imperial Japan was provoked into war.
    The Confederacy was fighting for states' rights, not slavery.
    The capitol riots were a false flag operation by Antifa.
    Derek Chauvin was a victim of a rigged system.
    Dylan Roof was brainwashed by liberal media.
    Anders Breivik was defending European values.
    Tarrant was a deep state operative.
    Trump's reinstatement is imminent according to QAnon.
    Apartheid in South Africa was misrepresented.
    Transgender acceptance is a liberal agenda to destroy traditional values.
    Q is revealing the truth about the deep state.
    Gavin Newsom's recall was thwarted by voter fraud.
    The Right is winning the culture war secretly.
    Nick Fuentes is a truth-teller being silenced.
    Baked Alaska is uncovering FBI corruption.
    Mr. Metokur is exposing the vaccine conspiracy.
    The online Right is strategically regrouping for a comeback.
    Herman Cain was a victim of a targeted attack.
    COVID vaccines are a global control scheme with fake death counts.
    Brexit is the UK's liberation from globalist control.
    The 'Build the Wall' campaign was sabotaged by the deep state.
    Trump's impeachment trials were deep state coups.
    Populist movements are the true voice of the people, suppressed by the media.
    The Cambridge Analytica scandal is a hoax to discredit right-wing success.

    • 6 months ago
      Anonymous
  90. 6 months ago
    Anonymous

    >be homosexual
    >used to work at blizzard because your dad worked at blizzard and nepotism
    >speak as if you have authority in anything, let alone gamedev
    >your one game is an undertale/earthbound ripoff
    >its title is an anagram of Earthbound
    >its about depression and anxiety
    >started development 7 fricking years ago, available for purchase 5 years ago
    >still early access
    good fricking grief, imagine being such a hack

  91. 6 months ago
    Anonymous

    >You don't need to be an amazing programmer, anon. Do you know why?
    we the real reason why is that all of the heavy lifting is done by the engine. You still need to be a pretty good programmer to create your own video game engine with bespoke features that only it can do well. Or your game can be an implementation of Unity's engine like everyone else, and in that case maybe you don't need to be a programming genius

  92. 6 months ago
    Anonymous

    Artificial Soul: "Dark S 3"
    Soul Core: "DOTA 2"
    Core Pilled: "League of Legends"
    Pilled Kino: "Deus Ex"
    Kino Horny: "Catherine"
    Horny Fun: "Senran Kagura"
    Cringe Reddit: "Fall Guys"
    Reddit Slop: "Artifact"
    Slop Nostalgia: "Sonic the Hedgehog"
    Nostalgia Ludo: "Pokémon Red and Blue"
    Ludo Humor: "Untitled Goose Game"
    Humor Shit: "Goat Simulator"
    Shit dicky: "Hatoful Boyfriend"
    dicky FOTM: "Apex Legends"
    FOTM Jank: "Cyberpunk 2077"
    Jank Fake: "Mass Effect: Andromeda"
    Fake Forced: "Battleborn"
    Forced Cringe: "Life of Black Tiger"
    Cringe Honest: "Stardew Valley"
    Kino Ludo: "Bloodborne"
    Ludo Liminal: "Yume Nikki"
    Liminal troony: "Celeste"
    troony Goy: "The Sims"
    Goy Zoomer: "Roblox"
    Zoomer Boomer: "Minecraft"
    Boomer Weeb: "Final Fantasy VII"
    Weeb Based: "Metal Gear Solid 3: Snake Eater"
    Based Schizo: "Silent Hill 2"
    Schizo Grog: "Crusader Kings II"
    Based Schizo: "Pathologic"
    Schizo Grog: "EVE Online"
    Grog Zoomer: "Valorant"
    Zoomer Boomer: "Call of Duty: Modern Warfare"
    Boomer Weeb: "Metal Gear Solid"
    Weeb Based: "Nier: Automata"
    Based Liminal: "Silent Hill"
    Liminal troony: "Night in the Woods"
    troony Goy: "Papers, Please"
    Goy Zoomer: "Undertale"
    Zoomer Boomer: "Half-Life"
    Boomer Weeb: "Castlevania: Symphony of the Night"
    Weeb Based: "Persona 4"
    Based Schizo: "American McGee's Alice"
    Artificial Soul: "Shadow of the Colossus"
    Soul Core: "Warcraft III"
    Core Pilled: "System Shock 2"
    Pilled Kino: "Bioshock"
    Kino Horny: "HuniePop"
    Horny Fun: "Leisure Suit Larry"
    Fun Cringe: "Freddy Fazbear's Pizzeria Simulator"
    Cringe Reddit: "Undertale"
    Reddit Slop: "Mighty No. 9"
    Slop Nostalgia: "Mega Man 2"
    Ludo Humor: "Conker's Bad Fur Day"
    Humor Shit: "Bubsy 3D"
    Shit dicky: "Gal*Gun"
    dicky FOTM: "Among Us"
    FOTM Jank: "The Elder Scrolls V: Skyrim"
    Jank Fake: "No Man's Sky" (at launch)
    Fake Forced: "Knack II"
    Forced Cringe: "Ride to Hell: Retribution"
    Cringe Honest: "Terraria"
    Honest Kino: "Dark Souls"
    Kino Ludo: "Chess"
    Ludo Liminal: "ICO"
    Liminal troony: "Gone Home"

  93. 6 months ago
    Anonymous

    Go away, Thor, nobody cares about your "money cant buy happiness" schtick.

  94. 6 months ago
    Anonymous

    There is literally nothing wrong with using lots of if statements

  95. 6 months ago
    Anonymous

    >All of the dialogue in all of Undertale is in a single switch case statement, thousands of cases long for the whole game
    I refuse to believe this

    • 6 months ago
      Anonymous

      If it works it works lmao
      This game runs on a toaster flawlessly so obviously optimization was never needed.

      • 6 months ago
        Anonymous

        Absolute kino

      • 6 months ago
        Anonymous

        perfect format for localization

  96. 6 months ago
    Anonymous

    This is word for word the same spiel that nerd that has been popping up on my shorts said (Pirate Software on youtube or whatever the frick).

    Btw does anyone know if the dude is using a voice changer? Cause if you watch his videos from like 4 years ago it didnt sound anythinig like it does now.

  97. 6 months ago
    Anonymous

    Always thought I sucked at programming and quietly gave up on it right after finishing up my internship in a Microsoft Innovation Center and became a full time day trader instead since I just wanted money and time to play video games. But then I look at shit like that and think, I might have been pretty amazing actually.

  98. 6 months ago
    Anonymous

    Undertale didn't really need good programming because it was carried by writing and music.
    Fact of the matter is that if you're not exceptionally skilled in something to carry your game, there is no point making one at all.

  99. 6 months ago
    Anonymous

    >Undertale is one of the worst programmed things that I have ever seen.

    Anon....Yandere Simulator also exists.

  100. 6 months ago
    Anonymous

    >no UnDeRtAlE.eXe

  101. 6 months ago
    Anonymous

    >All of the dialogue in all of Undertale is in a single switch case statement, thousands of cases long for the whole game.
    codelet here, how are you supposed to this right?

    • 6 months ago
      Anonymous

      Separate the dialog from the game logic for starters.

  102. 6 months ago
    Anonymous

    When will you frickers understand that solving problem like this is just a very small puzzle in a bigger picture. To actually deliver something of value you will need a mind of an architect to plan the entire project and it's structure and how it's going to work and interact.
    If I were to drawn and analogy it's like writing a book but being bad at spelling. Yeah, the book quality is lame and hard to read but doesn't make the book bad.

    But who am I talking to? Unless you're a professional developer or somebody that actually took hobby development past FizzBuzz you wouldn't understand

  103. 6 months ago
    Anonymous

    >All of the dialogue in all of Undertale is in a single switch case statement, thousands of cases long for the whole game.
    Why is this a bad thing?

    • 6 months ago
      Anonymous

      >want to change a specific conversation
      >have to frick around in a single 10,000 line long file to even find dialog
      >oh frick it's split over 15 separate cases which are spread totally randomly
      >the labels are random numbers too
      It's actually probably more efficient from a computational perspective too, it's just fricking dumb and nigh impossible to maintain.

      >actually taking fricking pride in your work
      I'm pretty sure the guy who first became famous for his music takes more pride in picrel than in some obscure line of code if/else statement he used to run his 2D game that is still fast, maintained, stable and ported to a dozen other platforms anyways.

      Ok, cool. I don't care about what some moron does or doesn't take pride in.
      Undertable is also buggy as frick and only fast in the first place because of how ridiculously powerful modern computers are.
      It also hasn't had any significant expansions period - the dude moved on to making a new game with his troony friends immediately.

      Lastly even if all of that was true and it was good enough, it still could have been better. Development could have been substantially easier for him and shorter if he wasn't a moron. The dude spent almost 3 years making it and he's been working on deltarune since 2012 lmao. He's not doing anything complicated and if he had structured his code in a more sensible way he could have spent more time making music than pissing about trying to figure out which of his 2000 cases corresponds to alphys pressing her cloaca down onto your wiener

      • 6 months ago
        Anonymous

        >It also hasn't had any significant expansions period
        Is this a problem ? Are you an actual fricking zoomer who needs content pack, expansions and DLC to enjoy a game ? Frick off

        • 6 months ago
          Anonymous

          From a software engineering PoV it’s just bad form to make something that isn’t easily alterable for future devs. Toby isn’t a software engineer, though, so him not giving a shit beyond making a functionally stable product is a hard concept for programming autists to grasp.

        • 6 months ago
          Anonymous

          >he made a game that he literally couldn't add any more content for
          >AND THAT'S A GOOD THING!
          fricking moron.

          • 6 months ago
            Anonymous

            So he released a product he was satisfied with ?
            Once again, where is the problem ? You can't b***h about the game taking 3 years to come out and it being complete on release.
            Between this and the pride thing you backtracked on, just make up your fricking mind already you sperg.

            • 6 months ago
              Anonymous

              >So he released a product he was satisfied with ?
              You don't know that. There are clearly parts of the code that he couldn't make functional because he was so moronic (like undertale not being able to delete itself) so you've lowered your standard to "a game released" because it's the best you can say.
              It could have been bigger, it could have been better and it could have released sooner or had more polish devoted to other areas if he was a better programmer
              >You can't b***h about the game taking 3 years to come out and it being complete on release
              Why not you stupid fricking homosexual?
              >Between this and the pride thing you backtracked on
              I didn't backtrack on it you fricking dumbass, I said I don't care whether toby agrees with me or not.
              He should take pride in his work. He clearly doesn't and that's why he's spent over a decade on a product which still hasn't fully released but that isn't my problem, that's his

  104. 6 months ago
    Anonymous

    i saw this short on youtube too bro!

    • 6 months ago
      Anonymous

      YouTube shorts, vines, Instagram stories, tiktoks et al are evil.

      • 6 months ago
        Anonymous

        Why?

        • 6 months ago
          Anonymous

          Fricks with your endocrine system. On a more practical level they are made with evil intent. They are evil by nature of being made to do evil.

          Cope

          With what? I'm telling the truth. Are you in denial?

          • 6 months ago
            Anonymous

            >Fricks with your endocrine system.

      • 6 months ago
        Anonymous

        Cope

  105. 6 months ago
    Anonymous

    "bad code" is just a cope by norwegian Black person youtubers who are angry that their "well coded" game about collecting cowboy hats using a ladle didnt sell a single copy

  106. 6 months ago
    Anonymous

    this guy solved youtube to its core.
    he's not very annoying so it's alright. the indians must be really jealous

    • 6 months ago
      Anonymous

      I give him another month til hes bad in obscurity land for his 1000 viewers. His tone is grating and naggy. I dont sit at the computer to get fricking nagged at and bragged to

  107. 6 months ago
    Anonymous

    >your code does not matter! You too can be like the Undertale dev! Just try and don't bother learning and improving your skills!
    >oh nyoooo, why is steam full of bugged, unplayable, borderline junk games? How could this happen?

  108. 6 months ago
    Anonymous

    find -iname "udertale.exe" |xargs rm

    Oh. no. this is Windows.

  109. 6 months ago
    Anonymous

    >be D-tier programming student
    >seeing this thread fills me with anxiety
    Please send help

    • 6 months ago
      Anonymous

      if all goes well i'll be in my final year of studying next year on my way to getting my degree. i still don't know what the frick i'm doing and i'm pretty sure i'm moronic.

      • 6 months ago
        Anonymous

        >be D-tier programming student
        >seeing this thread fills me with anxiety
        Please send help

        I've seen people people like you when I studied.
        I despise you. What the frick are you doing in programming if you don't have any interest for it? I have not programmed a single line of code the summer before semester start. I've decided to read a book about programing to see what it was about and ended up reading 4 cover to cover and solving all problems before my semester even started.
        How the frick do you live with yourself doing something you have no passion for?

        • 6 months ago
          Anonymous

          >How the frick do you live with yourself doing something you have no passion for?
          In misery?

        • 6 months ago
          Anonymous

          i'm moronic and don't know what i'm doing half of the time but everything just works™
          i should clarify i don't even study software development, i'm studying web dev

          • 6 months ago
            Anonymous

            Honestly if web dev "just works" you're not a dev you're the messiah

          • 6 months ago
            Anonymous

            [...]
            I've seen people people like you when I studied.
            I despise you. What the frick are you doing in programming if you don't have any interest for it? I have not programmed a single line of code the summer before semester start. I've decided to read a book about programing to see what it was about and ended up reading 4 cover to cover and solving all problems before my semester even started.
            How the frick do you live with yourself doing something you have no passion for?

            >be D-tier programming student
            >seeing this thread fills me with anxiety
            Please send help

            if all goes well i'll be in my final year of studying next year on my way to getting my degree. i still don't know what the frick i'm doing and i'm pretty sure i'm moronic.

            The answer to always feeling like you aren't good enough, is realizing that there are more people out there worse than me, that don't even care. So why should I?
            Stay employed because the company doesn't mind as long as there is something being produced, because who is in charge doesn't understand how bad the code is, because they need diversity hires, whatever. Somehow I get the feeling that most people suck at their jobs in practice, and that people like us will always get a job somehow no matter what. It may not be the most well paying position, but does it need to be?
            At least that is my personal cope, as I am starting my bachelor's thesis next year and I too feel like I have no idea what I am doing.

        • 6 months ago
          Anonymous

          For me, it’s being depressed due to years of drug abuse and failure. I’m trying to improve my mental and physical stamina with exercise and sobriety, and then once I have a little less brain fog, I intend on trying to do pretty much what you’re describing.

          Passion is a meme. The only thing I’m passionate about is getting high and playing vidya.

    • 6 months ago
      Anonymous

      >programming student
      >getting anxious now
      >not the moment he chose his profession
      Unironic ngmi

  110. 6 months ago
    Anonymous

    Undertale is like Freddy Krueger, the more you talk about it the more power it has over you. If you want to die and be forgotten you need to stop talking about it.

  111. 6 months ago
    Anonymous

    >Go make games.
    is hard and i suck and always fail. but I'll try today op-san, i just hope i break the cycle or get blessed by god with someone who can help me make games

  112. 6 months ago
    Anonymous

    >Toby, an amateur programmer, wanted to implement some specific feature but he failed (game self-deleting in this case)
    >this is somehow a sign that your code doesn't matter and you don't need to be an amazing programmer
    Huh?

  113. 6 months ago
    Anonymous

    I'm a mediocre programmer and a mediocre creative writer. That's not my issue. My issue is I can't into art and I can't into money to buy premade shit so here we are.

  114. 6 months ago
    Anonymous

    frick off thor, you spoiled homosexual b***h! every single opportunity was given to you.

  115. 6 months ago
    Anonymous

    So fricked up how this talentless hack enjoys fame and success when actual hard-workers like me go unrecognized.

  116. 6 months ago
    Anonymous

    >tobey just leaves that embarrassing shit in
    homie WHAT?! WHY?!

    • 6 months ago
      Anonymous

      >makes one of the most popular games of the last decade
      He’s earned the right to not give a frick, anon.

    • 6 months ago
      Anonymous

      he thought it worked or forgot

    • 6 months ago
      Anonymous

      He didn't expect people to get the decompiled source code

  117. 6 months ago
    Anonymous

    "Game works with a shit code therefore having shit code is not a problem" is such a moronic take if you think about it. Sure, the game works with a shit code, BUT it having much better code would benefit the developer and will directly impact better development. And the game COULD be much better with better code for obvious reasons.

    • 6 months ago
      Anonymous

      >”Please hire me, Toby!”

      • 6 months ago
        Anonymous

        I mean, maybe if Toby hired some more competent coders he could have released Deltarune faster.

        How would better code change the Undertale gameplay experience in any way ? legit question, the game runs 60fps either way

        You're thinking in terms of the released game, but try to think from the development perspective. Theoretically, Undertale could have had more content if Toby had been more skilled.

        • 6 months ago
          Anonymous

          I don’t think he’s much concerned about getting the game out as quickly as possible.I also doubt he’s ignorant enough to not realize hiring a more competent dev would probably be to his benefit.

          Or he’d just rather do the whole thing on his own no matter how long it takes, which is also understandable.

    • 6 months ago
      Anonymous

      How would better code change the Undertale gameplay experience in any way ? legit question, the game runs 60fps either way

      • 6 months ago
        Anonymous

        There were things toby wanted to do and couldn't figure out how to implement.
        There were better ways he could have spent his time if things had been implemented more effectively.
        There are decisions that were made at the start of game development which toby probably didn't realise he was making which effected what was or wasn't possible for the final game.

    • 6 months ago
      Anonymous

      OPs point is
      making a game with shit code that just works >>>>> not making a gam because your code isn't good enough and trying to learn endlessly

      it's the same thing with art, you have to start making garbage in order to get better, if you constantly redraw the eyes you will never finish drawing anything which will inevitably lead to you quitting

    • 6 months ago
      Anonymous

      No there's a middle ground where a game is a buggy piece of shit but it's a only buggy if you intentionally glitch hunt. Where you can play normally casually and then do tons of unintended shit. Your Super Mario Worlds, Super Metroids that have been broken in half over the years. While still being perfectly stable for the normals.

  118. 6 months ago
    Anonymous

    why is this necessary?
    File name handling in Windows is case independent
    UNDERTALE.EXE and undertale.exe is the exact same thing

  119. 6 months ago
    Anonymous

    Since we clearly got so many professionals here, are there any better ways to serialize (constant) trees and graphs than just shoving everything into an array? It feels like I'm missing something, but it's not like jumping around via indices is any worse than dereferncing pointers.
    Suppose you can reduce duplicate subtrees for size optimization purposes, but that's minutae.

    • 6 months ago
      Anonymous

      You can make it faster by having data that can be accessed linearly and not keeping unused data around, since your cache line can fit only 64 bytes at a time and fetching from RAM to CPU cache is like reading from an external database.

      • 6 months ago
        Anonymous

        I'm talking about serialization (to disk), and not runtime access.
        Not doing matrix multiplication using graphs, and nodes in a tree are generally heterogenous, so no clue why you even brought up memory hierarchy.

        • 6 months ago
          Anonymous

          It's a game dev thread.

    • 6 months ago
      Anonymous

      >is there any better way to serialize a tree than by serializing the tree
      fricking homosexual

      • 6 months ago
        Anonymous

        Please be patient I have autism.

    • 6 months ago
      Anonymous

      >shoving everything into an array
      if it works, it works
      for the case of a graph you could also consider a sparse matrix structure if the connections aren't dense
      t. I've serialized some stuff shittily

  120. 6 months ago
    Anonymous
  121. 6 months ago
    Anonymous

    >using undertale as an example
    But Undertale sucks ass in every single way, except the OST.

    • 6 months ago
      Anonymous

      Does it, though?

  122. 6 months ago
    Anonymous

    As long as my game has 60 fps or more, it's all fine
    I never look at the same project twice, after It's released I'm removing it from my ssd

  123. 6 months ago
    Anonymous

    Where do I go to look at Undertale code? I want to know how it works and is put together so I can do stuff like that.

  124. 6 months ago
    Anonymous

    nobody gives a fukcing shit about some programmer monkey's ideas

    programming is inches away from being automated by bots after which 99% of programming jobs disappear, and 99%of them are already being outsourced to china and india

    • 6 months ago
      Anonymous

      but everybody will care about *your* ideas, mr prompt engineer?

      • 6 months ago
        Anonymous

        >being this much out of the loop
        the main programming tools right now dont need prompts and they can bascially create software from scratch.

        • 6 months ago
          Anonymous

          creating software that works is beyond them though
          They literally can't deal with prompts that use big O notation

  125. 6 months ago
    Anonymous

    >morons think "if" statements are the boogeyman of programming
    holy shit the autism is strong in this board

    • 6 months ago
      Anonymous

      I have been trained on Ganker memes to believe that the "switch" statement is the godking sent to slay the "if" statement boogeyman.

      I have to repeat Advanced Data Structures & Algorithms, so frick if I know why.

      • 6 months ago
        Anonymous

        there's no reason to use an if when a switch statement can do the same job
        Ifs aren't inherently bad, they're just strictly worse in this instance.

      • 6 months ago
        Anonymous

        Ganker consists of pajeet and front-end devs who dont know anything about real programming

        • 6 months ago
          Anonymous

          Pajeets are the only ones left who can write real code.

          • 6 months ago
            Anonymous

            No they aren't lol
            90% of the time they don't even understand the problem

            • 6 months ago
              Anonymous

              The lead data scientists for every major company are disproportionately Indian. This is cope.

              • 6 months ago
                Anonymous

                That doesn't mean they're good at their jobs lmao

              • 6 months ago
                Anonymous

                Boy, you are really determined to keep doubling down on the copes, arentcha?

              • 6 months ago
                Anonymous

                Ask any pajeet "developer" on these boards even simple problems and they will get them wrong.
                There are indians who are good at their jobs and have good technical understanding, but they're almost all from the older generations. These days it's bootcamp script kiddies who barely speak english looking for easy money and trying to get AI to work for them.

              • 6 months ago
                Anonymous

                >These days it's bootcamp script kiddies who barely speak english looking for easy money and trying to get AI to work for them.
                That's literally me.

          • 6 months ago
            Anonymous

            No they aren't lol
            90% of the time they don't even understand the problem

            somehow I feel like both of you are coping

            • 6 months ago
              Anonymous

              see

              Ask any pajeet "developer" on these boards even simple problems and they will get them wrong.
              There are indians who are good at their jobs and have good technical understanding, but they're almost all from the older generations. These days it's bootcamp script kiddies who barely speak english looking for easy money and trying to get AI to work for them.

              • 6 months ago
                Anonymous

                hmmm, accurate post

  126. 6 months ago
    Anonymous

    Oh no an if statement I'm going insane

  127. 6 months ago
    Anonymous

    Why should the player care about this nerdy programming bulllshit? The game works.

    • 6 months ago
      Anonymous

      They shouldn't. Them becoming aware of it is the epitome of bad design.

  128. 6 months ago
    Anonymous

    Having a decent framework and design as a foundation is helpful but has diminishing returns.
    I've seen people waste years multiple times trying to make the perfect software framework to automate everything and never have to write shit from scratch. It never works as well as they hope, still has tons of bugs still doesn't support every random feature you want and requires constant overhauls until people realize it's faster to just write from scratch again.
    At the end of the day the guy pumping out half ass code that "runs" in a week is more of a success than the guy spending years in paralysis dreaming of the perfect framework.
    Done is better than perfect as they say. Doesn't really matter what high school software snobs think of your code when your an indie dev.

  129. 6 months ago
    Anonymous

    Before this thread dies. Is AI going to automate us away, programmer bros?

    • 6 months ago
      Anonymous

      No, AI can't even solve ordinary ODEs consistently.

    • 6 months ago
      Anonymous

      not until it can understand a 500k+ LOC codebase

    • 6 months ago
      Anonymous

      I'm not sure. AI is still kind of moronic in many ways, and the training materials are finite so I'm not entirely convinced about it, but I don't want to underestimate it either.

    • 6 months ago
      Anonymous

      No, at least not in the near term.
      It can't work with legacy code, it can't understand context and it can't deal with any sort of complexity.
      Tools like copilot have been widely used for months now and even their strongest proponents only argue that they're good for boilerplate

    • 6 months ago
      Anonymous

      It doesn't have the actual creative capacity to do anything without a human to guide it, and even then the prompted information that it provides doesn't always guarantee functional code.

      A competent programmer can make good use of it, a shitty programmer can barely make good use of it, and the AI can't make use of itself. In other words, no.

    • 6 months ago
      Anonymous

      gonna be a long time before AI reaches the necessary level of complexity for that. it still needs people to keep it in check even when doing relatively basic tasks.

    • 6 months ago
      Anonymous

      As long as AI is just a probabilistic model, it will always just make random shit up as it runs out of answers. The things it generates are often wrong anyway and still need to be looked over by a competent programmer to find mistakes.

  130. 6 months ago
    Anonymous

    What if the user renames the executable? I was thinking you can just delete the entire folder the process is running from, that's probably the intention anyway, but what if the user is running the executable from a different folder?

    • 6 months ago
      Anonymous

      What if I changed the .exe to peepeepoopoo?

      The correct solution is to use the OS API to know the name of the current process

  131. 6 months ago
    Anonymous

    so yanderedev could have succeed?

    • 6 months ago
      Anonymous

      if the scale of his game was smaller (2D pixelshit), then yeah probably

  132. 6 months ago
    Anonymous

    >undertale is one of the worst programmed games of all time because it doesn't delete itself
    moron

  133. 6 months ago
    Anonymous

    In any language of your choice using only base functions, write a program that accepts a string of numbers as an input and returns the most commonly occurring the number in the string. In the case of there being multiple modes, return the smallest value.

    Example: {1202011} would return 1 and {337729} would return 3.

    • 6 months ago
      Anonymous

      I'm not doing your homework

    • 6 months ago
      Anonymous

      if you can't solve and have a complete answer for this in a few minutes then you're NGMI

      • 6 months ago
        Anonymous

        >drop the question into GPT
        >get an answer in 2 seconds
        How did I do, doc?

        • 6 months ago
          Anonymous

          It's a gpt tier problem, so you did the right thing.

        • 6 months ago
          Anonymous

          you're now ready to scam your way into the dev team of a small business. don't worry, management can't tell the difference

          • 6 months ago
            Anonymous

            Frick yeah, I knew these past few years of dicking around in college would pay off.

            Six figure dream life, here I come!

    • 6 months ago
      Anonymous

      >write a program that accepts a string of numbers
      You mean a string of digits, moron.
      Anyway javascript:

      if (!string.length) return;
      let map = {}
      for (let i = 0; i<string.length; i++ {
      map[string.charAt(i)] ? map[string.charAt(i)]++ : map[string.charAt(i)] = 1;
      }
      return Object.entries(map).sort((x,y) => x[1]-y[1]).pop()[0];

      • 6 months ago
        Anonymous

        Actually this doesn't always return the smallest element if both have the same occurance
        Quick fix:
        if (!string.length) return;
        let map = {}
        for (let i = 0; i<string.length; i++ {
        map[string.charAt(i)] ? map[string.charAt(i)]++ : map[string.charAt(i)] = 1;
        }
        return Object.entries(map).sort((x,y) => {return x[1]-y[1] ? x[1]-y[1] : parseInt(y[0])-parseInt(x[0])}).pop()[0];

      • 6 months ago
        Anonymous

        Actually this doesn't always return the smallest element if both have the same occurance
        Quick fix:
        if (!string.length) return;
        let map = {}
        for (let i = 0; i<string.length; i++ {
        map[string.charAt(i)] ? map[string.charAt(i)]++ : map[string.charAt(i)] = 1;
        }
        return Object.entries(map).sort((x,y) => {return x[1]-y[1] ? x[1]-y[1] : parseInt(y[0])-parseInt(x[0])}).pop()[0];

        Based

    • 6 months ago
      Anonymous

      [110,105,103,103,101,114].map(x=>String.fromCodePoint(x)).join("")

    • 6 months ago
      Anonymous

      Trivial in python. Took me all of 3.5 seconds to think of it Just use a dict with each digit as a key, with the values starting at 1 and incremented each time the key is accessed.
      Breaking the ties is still trivial but is tedious so I won't do it.
      God python is so nice.

      • 6 months ago
        Anonymous

        >with the values starting at 1
        with the values starting at 0*

    • 6 months ago
      Anonymous

      C++

      #include <string>
      #include <map>

      int main(int argc, char* argv[])
      {
      std::string numbers{argv[0]};
      std::map<int, int> frequencies;

      for (const auto& n: numbers)
      { ++frequencies[n - '0']; }

      int most_frequent{0};
      int highest_frequency{0};

      for (const auto& [number, frequency]: frequencies)
      {
      if (frequency > highest_frequency || (frequency == highest_frequency && number < most_frequent))
      {
      most_frequent = number;
      highest_frequency = frequency;
      }
      }

      return most_frequent;
      }

      • 6 months ago
        Anonymous

        What is this horrid eyerape bullshit?
        In python-ish pseudocode:
        the_dict = dict(len(string))

        #initialize digits to 0
        for value in string:
        dict[value] = 0

        for value in string:
        dict[value] += 1

        return the_dict.items().pop()

        ezpz and clean.

        • 6 months ago
          Anonymous

          Minor typos but it holds.

        • 6 months ago
          Anonymous

          It's a program that is and does what

          In any language of your choice using only base functions, write a program that accepts a string of numbers as an input and returns the most commonly occurring the number in the string. In the case of there being multiple modes, return the smallest value.

          Example: {1202011} would return 1 and {337729} would return 3.

          asked for.

          >in [language]-ISH
          >pseudocode
          >not a program
          Not what

          In any language of your choice using only base functions, write a program that accepts a string of numbers as an input and returns the most commonly occurring the number in the string. In the case of there being multiple modes, return the smallest value.

          Example: {1202011} would return 1 and {337729} would return 3.

          asked for. Don't call us, we'll call you.

      • 6 months ago
        Anonymous

        see I love c++ but it's just so fricking verbose for problems like this.
        I can't imagine ever trying to solve an interview problem in it because there's so much to write and it's so pedantic

  134. 6 months ago
    Anonymous

    >MUH GENOCIDE
    Yeah okay Toby.

  135. 6 months ago
    Anonymous

    Doesn't matter if it works you fricking uppity code monkeys. This is why you're all getting replaced by AI.

  136. 6 months ago
    Anonymous

    Another moron pretends he's far better with tech than he is and tries to make his five minute acquaintance on youtube with a basic conditionals into a worthless piece of spam. You will never be a good programmer op because you are a bullshiter

  137. 6 months ago
    Anonymous

    It's not even Undertale. FNAF is a household name that just got a fricking movie and all of the games outside of the Steelwool ones and the VR game are made in Clickteam Fusion. CF is a essentially a drag and drop engine that can be mastered by middle-schoolers in the span of a few weeks and it's what Scott made all of his games on ever since he got an early iteration of it in like the 90s or something.
    Programming is a meme

Your email address will not be published. Required fields are marked *