Skip to main content


Programmers of Reddit, what was your best bug-turned-feature experience?


  1. I created a random name generating function for NPCs in my game. It would load a list of phonemes from a file, like "reg" or "kud", or "bal" or "pid" or "mi", or "bo", etc. There were hundreds of them. And then it would randomly string a name together like a kid playing with lego. You'd get cool things like "Balreg" or "Judlo", "Mepesh", etc. But I didn't want any swears accidentally popping up, so I made another file of all the most common swear words. "fuck", "shit", "cunt", "whore", "cock", etc, and set it up to make sure the name did not contain any of the swear strings. Guess what happened when I accidentally set it to chose from the swear list instead of the phonemes list. "Hello. My name is Cockshit Buttskank." My inner 9-year-old had a field day.
    — thudly

  2. I was writing software for an insurance company, and one of the first things I did was create a dummy insurance rate to test the UI. Then I spent months on the maths to calculate insurance rates for every conceivable coverage according to industry standards. After I left, they switched my code back to that dummy variable and offered coverage at a flat rate.
    — wolf_on_the_fold

  3. I was building this digital guitar thing as a project in college. We only had a couple of inputs on our microcontroller, but we wanted to have dozens of buttons (6 strings x however many different notes there are per string). I came up with this design that was basically a string of resistors that you could short out at various points, and then we just programmed the microcontroller to read the voltage and figure out which note it was. It was really cool, but when I showed it to the TA, he told me it wouldn't work because if you press two buttons at the same time, it would only recognize the lowest resistance button in the chain. That's when my partner, who was in a band and played guitar, explained that on a real guitar, it plays whatever note you are holding against the fret furthest down the neck board thing - so I accidentally made a circuit that behaved exactly like a real guitar. If you press another note further up the neck, it doesn't matter. We could get rid of the software part that had to figure out which note to play if you are pressing two button, because the analog side of the system would ignore the button press the same way as a real guitar. It was triumphant.
    — nalc



  4. I worked for a place once that had a very complex website that ran off VBScript. There was a section of code in it that said "do not remove this comment, or the site stops working." It seemed impossible, so I decided to try it out in the dev environment, and sure as shit, removing that comment caused a startup error in the application. Putting the comment back (with any text) resolved it. To this day, I still don't know why that happened.
    — CodeMonkey24

  5. Still a beginner to programming and game design, but I was making a local multiplayer spaceship shooter game and I accidentally made the guns rate of fire increase over time. It led to me implementing a sudden death mode where if one player hasn’t killed the other by the time the round ends, both players will gain extreme rate of fire.
    — hpl2000

  6. I had a computer graphics project when I was a student where I had to recreate a navigable 3D labyrinth using raycasting. So, I had finished it a bit in advance and we had the right to do some bonuses to go over the maximum mark of 20 out of 20 (although additional points were quite difficult to get). So I started implementing stuff, little by little, everything went well until the moment where I tried to implement transparency in my labyrinth walls. I came up with a solution where the ray wouldn't stop at the first encountered wall and then would do a weighted average of the color of all the subsequent encountered walls. So I write the code, compile it successfully, run it and... Random blinking colors. Random blinking colors everywhere. I try moving my character a little, the walls turn into that weird tunnel looking effect (remember the Windows XP bug when you moved a window while your computer froze? Exactly that but moving with blinking colors). I try to analyze the problem, turns out it was because I also applied the transparency in my clear color (the background), so the color of a pixel would be dependent on the color of that same pixel two frames before (I had implemented double buffering to avoid tearing, which definitely made the effect cooler). Now, I could've fixed the bug and implemented transparency like I envisioned it. But I didn't. Instead, I implemented a switch that would enable/disable the effect, and sold it as a "LSD mode" during my project presentation. Majored with 31 out of 20 points on that project.
    — satouru



  7. When cats in Dwarf Fortress would get drunk from walking on spilt beer and then trying to clean themselves. Also, they'd get alcohol poisoning and die.
    — Pagan-za

  8. Once decided to turn the gravity down to 50% and the jump power to 200% on this platformer I was screwing around with. The character was a tank, so I decided to roll with it and made Rubber Tank. The only level in the game was fucking unbeatable though.
    — EpicAura99

  9. Obviously not mine, but Ghandi being a warmongering nuclear terrorist in the Civilization series came about as the result of a bug.
    — EverythingIsNine



  10. When programming a game for my group project, whenever an enemy was killed, it would fill the energy bar that was used for bullets. But we never programmed it to do that, we intended for there to be drops that players could pick up but after fiddling with it, I just gave to okay to remove the drop and make it so players would have to kill enemies to get energy back, with there being a basic weapon that doesn't use energy at all. In the end it made the game better because players were forced to interact with the enemies more in order to make meaningful progress, but we never figured out why it did that
    — lChickendoodlesl

  11. I'm not responsible for this, but when [Spacewar](https://en.wikipedia.org/wiki/Spacewar!) came out, a bug caused ships to randomly teleport to other parts of the screen. A fix was difficult, so this was explained as that they had inadvertently interacted with a black hole.
    — wuop

  12. A utility I wrote was printing out the refund amount as negative. I noticed this after they had been using it for a while and fixed it. Users complained about the change the next day...
    — Dubanx



  13. I didn't program this specific part, but I was a part of a group where this happened. It was a group project during the first year at university. And the other programmer in my group decided to do something with shaders (I don't remember what it was for), which at the time was way above what we were being thought. And it worked just fine on his computer (we all had the same laptop) but not any other members'. It turned that that he had an older Nvidia driver, where there was a bug where the thing that he had worked on worked just fine (I never understood what it was). But that bug was fixed in a later driver, and while it caused the shader to not work correctly anymore, it did technically fix the bug that caused it to work in the first place. We had to keep being on that specific driver for a week or so until a proper fix could be done, in order to not slow down the rest of the project.
    — Axeran

  14. Really this should be game devs, not programmers. Bugs in software don't become features, they become a week of nightmarish misery.
    — EthicMeta