Speaking as one of the devs who actually worked on the original Civ, yes Gandhi tended to nuke you. It was not intentional, but resulted from the fact that Gandhi usually didn't built much of a military, and advanced rapidly in tech. So when you betray your alliance with him and attack, his only recourse was to nuke you.
Wouldn't this be really easy to figure out by poking into the code of Civilization 1? If the threat level is stored as an unsigned integer then the Nuclear Gandhi story is probably true, if it isn't then it probably isn't.
as far as I can tell, you can't tell the type of a variable except for which instructions are executed on it, and even then, finding said instructions is a herculean task of patience. there is no piece of data that says "unsigned integer" other than the source code, which we'll never have access to.
@@AmeshaSpentaArmaiti Still, CIV I is probably small enough that it could be reverse engineered, though needing a lot of patience as you say. Another experiment is just to play the game enough and record whether or not Gandhi is actually much more aggressive than other civs that gets nukes. Should be quite easy to do by anybody who have the time to do it.
@@TheMaginor Yeah, just observing Ghandi's behavior is the best option, and it's so self-evident I don't really know why anyone hasn't actually tried it, yet. Of course, I haven't looked, I'm just assuming.
@Matthew Chenault integer overflow is caused by the CPU not caring what happens to extra bits when an addition exceeds the limits of the variables' chosen size. Dividing by zero is an operation that never terminates, it just goes on forever, so programs crash to avoid locking up the CPU. Neither situation has to do with numbers that don't exist.
At 6:40 , the letter says that even a wraparound wouldn't make Gandhi to be more aggressive than the most aggressive Civs. So there must be a range check somewhere that limits the value to be 1-10.
@@ghostlyninja125 Damn right i'm gonna be knocking on the door of every single flat potentially shown in this video to track down a stranger I saw on youtube.
I played a lot of the original civ. Gandhi nuked me a lot. It got to the point where I would restart if Gandhi was next to me. Yes, I am open to the idea that there wasn't a bug and it was just the fact that Gandhi was the one nuking that made it stand out. However, it wasn't like that many high school kids were playing Civ back then to implant that idea in my mind. Gandhi was a jerk!
I remember digging into it and finding that it wasn't possible in game to trigger an underflow with his threat level. Trying to drop it to 0 would just default to 1. If you forced it into a negative number (memory editor etc.), it could underflow and default to 10 but there was just no way I could find to do that naturally. Another comment pointed out that it was likely due to his civ focusing on tech and not keeping much of a standing army. He'd reach nukes pretty quickly and when forced into aggression would have to rely on them since his military was so weak.
@@possumverde The video itself is a bit misleading, as it somewhat conflates several ideas: that Ghandi used nukes, that Ghandi became hyper-aggressive, that Ghandi became extremely more nuke-happy than all other leaders, and that Ghandi's behavior was specifically due to an overflow caused when Democracy brought India's threat level to a negative value.
@@BainesMkII Those are all components of the same old rumor, and all of them are untrue. Gandhi would not become hyper-aggressive (at least more than any other leader), was not more nuke-happy than other leaders, and did not have a unique aggression score that could overflow after acquiring democracy (in fact, democracy doesn't even affect aggression scores). Everything about the story is untrue. The only true part is that Gandhi could use nukes, like every other civilization. The idea that Gandhi's stats made him focus more on technology and less on military is true, but that's also true of many other world leaders. But I guess when Abraham Lincoln drops a nuke on your city, that isn't as shocking and memorable as when Gandhi does it.
@@EebstertheGreat Did you just debunk not only the rumour but also all theorycrafting around it? Just the fact that you mention that Gandhi might not be more nuke happy than other leaders gives you credibility.
Sid: "I don't want to detract the player's personal experience because in the end it's a story." Chris: *intense thought;* *hundreds of rereads* Chris: "'Stay Civilized'? I think he's trying to tell us it's a story."
I feel like there’s no way to read that email as anything but a “Don’t ruin Santa Clause for your siblings” type of response from Sid. It’s still very cute that he recognizes that this mythology is still valuable though, not bc it’s true, but bc of what it means to people. It’s probably just like they said, Gandhi was equally as violent as other leaders, but it’s just so much more notable for Gandhi to nuke somebody so it stands out more.
Well, seems like we got our answer. Sid Meyer released his memoir, and outright stated it was never the case. Seems like his email wasn't meant to be mysterious, he just didn't want to give away the secret from his book.
That’s funny because I played the game and dealt with the bug. Perhaps it’s avout legacy and not having one of your biggest games have such a gigantic bug in it.
@@MrJPEzra successful people tend to embrace their mistakes as experience Such a bug making the legendary nuclear ghandi would only be the best way to reveal a mistake. A lot of bugs/inentended behaviour gave birth to something great. That's hoe the creeper was invented. That's how combos in fighting games were made (moves getting cancelled); it would be a mistake to celebrate and it'd be a huge waste not to profit from it. Telling the truth about it would be a very hard thing to do brcause it demystifies a mistake that shows features can birth from errors
@@MrJPEzra or maybe you thought it was a bug because you heard the story? Or you misremember after hearing the story? I have played Civ I a lot when I was a kid and I got nuked many times by many different countries. When I heard about the Ghandi bug I was like okay I might just never playes against India or something.
@@MrJPEzra No you didn't. The creator himself and people who worked on it know more about the game than you. Imagine saying you know better than the creator of it.
Meier's response is an embrace of Death of the Author, not wanting to get involved because it's totally counter to his philosophy as a creator and his reasons for making games. He's a true artist. Still, it's hard not to take his comment as confirmation that Nuclear Gandhi is a myth and he doesn't want to be the guy who crushes the dream. His message was coy but I don't think it was neutral.
iirc the original meme for civ 1 included half the civs, so its a case of chinese whispers. afaik Civ 3 was where 'nuclear ghandi' actually was the most agressive of the AI civs, but its been years, im pretty sure CIV 3 was where the OG meme is from, mixed with the civ 1 bug
Fact is Civ 4 was where I first encountered nuclear Ghandi, having not played enough of 3 to really have it come up. Whether it's a programmed in trait, like it is in 6, or simply the perception you receive when the most peaceful leader on earth does nuke you either in a small error or just because the most peaceful leader is programmed to behave exactly like all the other "peaceful" leaders, it is still very much the product of the storytelling of the game. Had any other leader in existence been programmed in the same way, no I don't think we would have noticed or cared. It's the fact that Ghandi, in the context of the coding, is likely a generic name and face for the underlying AI, but because of our preconceptions of Ghandi, it becomes obvious when he does something out of character. I mean, imagine if they had Hitler in the game and he is the most peaceful leader on the map, you WOULD notice. Doesn't matter that Hitler is just a face that goes on an AI that is the same behavior profile as George Washington (ignoring fact that people being judged by the time they existed in is still a mostly common practice) you are going to be critical of everything that's extremely out of character, and it's jarring and it HAS happened with Stalin before but it's a little... less impactful than Hitler. If Chinese leaders become globalist capitalists you'd probably just kind of grin at it realizing that it's just an AI playing with the same levers you have, you Egyptian civ in the modern era with every wonder except the pyramids, dominating the map. Ghandi using nukes is like Hitler sending you gifts and trying to unite the world, it's an extreme. It doesn't matter that Ghandi might have been just as aggressive as any other ruler in the early game, it's when you get to nukes, SUDDENLY, he's out of character for behaving like he has all game.
Fairly certain ‘stay civilized’ is primarily Sid Meier’s catchphrase, I’d be surprised if he doesn’t end every email or piece of text he signs off on with ‘stay civilized.’ Still, that was some amazing investigation work, good job. Too bad nobody you got in contact with didn’t decide to try and look at the original code out of curiosity.
Hah! I worked on Civ4, Civ revolution, Civ5 and civ6 (at the beginning), and Even I thought the myth of the bit flipping was true. Thanks for making this video.
Imagine living your whole life as a peace maker, becoming famous in India and around the world only to be remembered as the dude who nukes without remorse in civilization
Just wait until the kids of all those Gen X Civ players start learning about Gandhi in school, only to have their parents confuse them by complaining about how much he loved using nuclear weapons. "Dad, that's definitely not what my history book says about him..."
There is a way to find a definitive answer. You just need to PEEK at the source code for Civ 1 while it's running. Just find the variable that's the aggression level for Gandhi, and see if it actually overflows or not when the civ gets democracy. It's not like the code is going to change on it's own.
@@hemangchauhan2864 You couldn't look at any human readable code while it runs, but you can track memory addresses and decompile the code. An average programmer would struggle to do it, if they could figure it out at all, but it is possible.
An average programmer wouldn't struggle, unless the quality of programmers has degraded quickly. It'd just take way too long to bother for most of us. But it isn't in and of itself a difficult task, just a time consuming one. @@OriginalPiMan
I've never picked up a Civ game, but it still feels like my heart is being broken. At least from my programming teacher, this story is how integer under/overflow is taught today. When it does come to learning the truth, I feel like it's time to for the community to act as scientists, rather than journalists. Experimentation and/or decompiling the code will eventually lead us to the truth
No harm done in telling a pedagogically relevant non truth when it doesn't affect anyone or anything, it very well might be treated as a hypothetical scenario at this point. Besides I'm certain that it would work wonders to help students remember about the error and the logic behind it. I mean I personally find it hilarious, a world renown character synonymous with uncompromising peace, nuking you out of the blue, it's just really funny somehow, and just because of that I would probably never forget what an integer overflow is.
@@goprev9715 ... with the minor caveat that this journalist and everyone else erroneously calls this overflow when it's actually an underflow, but yeah
I loved how you presented this one! The near film-noir detective vibe seeped through at just the right amount :) And the final message of respecting player imagination is a nice one to see. I hope there's more of you getting 'a bit carried away with that one' in future episodes!
I think the description of this bug as apocryphal is correct. Brian Reynolds' letter seems to largely fit with what I can find elsewhere of the descriptions of how aggressiveness is tabulated. Other civilizations apparently have equal (or lower, when counting all three aggressiveness types) aggressiveness as India, so even if it existed, this could not be an India-specific bug. The bug, as-described, would also rely on some odd programming decisions that, from what I can find of compilers and practices with at-the-time C (what Civ1 was apparently written in), would have been unlikely to occur. While the idea of an underflow bug is common in programming, it wouldn't usually occur with an 8-bit value. In C, "char", "signed char", and "unsigned char" are the only 8-bit data types (proper integers -- "int" and friends -- are all 16-bit), and, for x86 processors at the time, plain old "char" would, with most compilers, apparently result in "signed char". So someone would likely have had to go out of their way to use an "unsigned char" data type for something that, by all accounts I can find, only needs three possible values. (It's entirely possible I'm wrong about some aspect of this, though. I was a baby at the time, and finding detailed documentation on the functioning of 30-year-old toolchains is difficult.)
Yes but using unsigned char was for some time preferred for values that are limited to less than 255, such as cases where enums can be used. Later when memory got cheaper this practice got outdated because a 32-bit processor fetches a 32bit value faster than an 8bit, and when memory became very cheap, speed became more important than capacity.
When compiled without debug features C programs typically don't do any checks on type or over/underflow, since it's incredibly wasteful for what should be the cheapest operations in your program. And C does support using 8-bit ints, it's in the header called, pause for dramatic effect, "stdint." Though I don't anything about 1990s C or if that header even existed back then, I'm willing to bet yes considering how fundemental bytes are.
@@sauyon Even before stdint.h was introduced, programmers often used typedefs to create integer types of known size, like u8, u16, s32, u32, and so on (or sometimes u1, u2, s4, u4, ...). The widespread existence of such typedefs makes this argument much less convincing
Nice video! FYI in case nobody mentioned: When an integer wraps back from -1 all the way to the max value, that's actually called an underflow. Overflow is when it goes the other way (Past max value to min value).
This is such a stunningly produced work of art! I really appreciate your tenacity with looking into this story, despite the lack of clear resolution it is still really interesting.
That was just a beautiful email reply from Sid, he made art that allowed others to enjoy and create their own stories, and dosen't want to play about with that legacy / magic. I'd frame that reply, really classy. Stay Civilized!
For me the stop motion'esque style made it hard to watch, and I checked several times to see that my browser was working correctly XD I think there is to many frames, used at to where it's in between stop motion and video. Love the content though :)
It's much harder to overflow or underflow undetected in modern programming languages due to them having "checked arithmetic" where the program crashes when an overflow or underflow happens, and the numeric datatypes tend to be high precision (millions to trillions of largest possible value) to begin with. Then we have Ethereum smart contracts, where large amount of money is at stake yet their programming language Solidity, in earlier versions, has no overflow check by default and can introduce money-losing security flaws into some smart contracts (but there are bigger sources of security flaws such as recursive calls).
I’m loving this growing genre of UA-cam videos where someone basically just goes completely manic researching one topic to the point of obsession but does it with such sincerity and thoughtfulness that it’s still incredibly compelling viewing
Im not even finished the video but i wanna say the editing in this video is so interesting and i can rly appreciate all ur editing work when you so easily could have just talked to a camera and imported some photos, what a fun watch lol
I was just thinking about the story the other day, and it occured to me that the hardware at the time wouldn't have even used an unsigned integer, as great as the story is to illustrate the overflow problem. You can even run the game in an emulator, and just monitor each variable in memory.
Hats off to Anni once again. It seems like every other episode she’s doing something completely new and interesting with the graphic design and it is awe inspiring to watch. 😍
A lot of comments seem to think some global term of "programmers" would have an easy time to work out if it's true. As a programmer myself I doubt this highly. With the notoriety this bug had, and for how long it's been around, the fact no "programmer" wanted to do this up to this point should give some idea of how "easy" this would be.
This video was AMAZING. I love all the effort that went into its presentation, and your curiousity and charm always shine through. Absolutely love your work mate!
There is no bug, it just seems weird to get nuked by Gandhi, so you're more likely to remember that. It's that simple. Sid and Bruce Shelley briefly addressed this at their GDC Classic Games Postmortem on Civ 1 a few years ago.
Fun fact: Sid is mostly just an executive now, and doesn't work directly on the games anymore. However, he's still a coder at heart, so all Firaxis games are written in an older version of C++ (C++ 11 IIRC) so that if he wants to, he can come in and write some of it himself. I don't know if that's still true, but I have it on good authority that it was a few years ago, and I kind of love it
Had we adopted non-violence as the weapon of the strong, because we realised that it was more effective than any other weapon, in fact the mightiest force in the world, we would have made use of its full potency and not have discarded it as soon as the fight against the British was over or we were in a position to wield conventional weapons. But as I have already said, we adopted it out of our helplessness. If we had the atom bomb, we would have used it against the British. Speech (16 June 1947) as the official date for Indian independence approached (15 August 1947) , as quoted in Mahatma Gandhi : The Last Phase (1958) by Pyarelal Nayyar, p. 326.
The sheer variety of presentation that both of you bring to the table with this channel is staggering. Thank you for yet another great one which I was eager to click on as much for seeing how you chose to present it as for the delightful topic itself. :)
@@TomRyckeboer I'm sorry but you're clearly very ignorant about how stop-motion animation works you can't just "double the framerate" they would have to take twice as many photos and they already took over 1,500 photos so that's *over 3,000 individual photos*
@@TomRyckeboer hey I didn't call you an idiot just ignorant there's an important difference! If you find it unpleasant that's your opinion but this is animated on 5s so *it's not supposed to convey fluid motion.* The stop-motion feel is a deliberate style choice and saying they should spend hundreds of hours doubling the framerate of a ten minute section of a low-budget YT video when the whole point of it is _the story being told_ NOT for it to be an aesthetically pleasing piece of art is just silly. If it really bothers you that much you can either play the video at an increased speed to make it smoother or just listen to the voiceover in the background :)
@@Mrblobbybobby Saying someone is "clearly very ignorant" never comes across well, and it really sounds condescending. I know what kind of stop motion he's going for, but even for that it's just too slow to look good.
This seems like something that could probably be decisively solved with a hex editor on the save files. Just find out how Ghandi's actual value changes over time and if it really does max out at points.
Interestingly, Sid Meier has since confirmed in his memoir that there was no such bug in the original civilization, and that the Nuclear Ghandi story is a myth. See the September 8th Bloomberg articled "Creator of ‘Civilization’ Looks Back at One of the Longest Careers in the Industry" for the original source
@@HMJ66 I'm a big ol nerd too, somehow I have a girlfriend though and she watches it. Basically half the contestants had to go live in a diffirent house for a week and her boyfriend/lover guy was fooling around with other girls while he was away, he got back, she found out, she was unhappy. Reality TV!
I think this is honestly my favourite video from this channel so far and I barely even remembered nuclear Ghandi. Thouroughly enjoyed everything about the video.
I figured someone would have a copy... and someone could read the code and figure out this "easily". I mean there are people who specifically do this for a living for various reasons. That, unlike interviews which can be lies or mistaken, would be able to be recreated and hence proved.
@@GMTK Ha, god damn it. Trying to put out a video on the same day as either one of you is bad enough! Loved the Celeste piece - very impressed that you managed to graph movement the way you did. -Chris
I love seeing Chris go off the deep end in search of answers to the questions (nearly) no one asked! And the look of the video? Brilliant, guys. Just...keep doing what you do.
I used to love civilization, I still love the experience what it gave me for more than 20 years now. Used to love to play with Ghandi and build a massive economy to force my enemies on their knees. Unfortunately with the newest addition to the series, I feel disheartened. It feels, you buy small parts of the game with every new expansion what should have been in the original copy and included in the £60 what you payed for it. It scares me that all great pc game makers are on the path of EA, Blizzard and alike. It scares me, that every new game what brings a new perspective a new idea to the table, are destened to turn on that same path as well. That is the reasin why I've decided I don't give a shit anymore, I will get out of my chair, and start building my own civilization, starting from scratch. So anyone knows how to cut trees? I'm looking for a worker!
what you are talking about around 2:15 is not integer overflow, but integer underflow, as it is a value smaller than can be stored (0) and integer overflow would be if it went over the storable value of, in this example, 255 (not 256, as the 256th number is the 0, it goes 0-255)
I've never thought about how forked up it is that democracy is seen as the final form of a civilisation and how democracies are less likely to go to war with people, despite, you know, all the wars
I mean, if you compare most democracies with most dictatorships, democracies tend to be more peaceful because they have a justification other than "I protect you from evil foreigners". Not to say democracies don't go to war, but especially civil wars are quite a bit rarer.
@@toboterxp8155 sure, but those factors still imply there are no better systems than democracy, which we'd bloody well hope there are given how badly democracy is failing us across the globe. Plus there are more options than democracy and dictatorship.
@@disposable157 I mean, not really? The big problem with governments is corruptibility. Sooner or later someone or some group will try to establish a dictatorship. The only way to avoid that is to make sure everyone can be replaced quickly, and has as little responsability as possible - something that democracy is somewhat optimised for. Though especially the older style of democracy, like in Britain or the US, isn't great at that, which is why they are almost dictatorships these days.
@@toboterxp8155 the anarcho-socialist spectrum of societies have options that don't include governments. I'm not sure I agree about the inevitability of power corrupting people either - that happens a lot, yes, but mostly because we've so far used a lot of systems that insulate the powerful from the consequences of their actions until they push things so far that guillotine blades start getting sharpened. Still, this isn't a political studies video. I just find the assumptions games like Civ make to be interesting. Similarly, in sim city, it makes you zone things into commercial, residential and industrial zones, which is a very strange system to those outside the US and Canada, but is baked into the core of the game. Things that get presented as normal, despite being choices the deva are making are fascinating.
@@disposable157 Well, to achieve internal peace, there needs to be a monopoly of violence. Otherwise factions will at least sometimes solve their problems with conflict and violence, and there's noone to enforce one coherent set of societal rules across the country. So a government is pretty much invetiable, which we can observe both historically and across cultures.
teeeeeechnically that's an integer underflow, not overflow. *My memory banks had been corrupted; integer overflow is certainly the correct term. To prevent this kind of confusion, "integer wraparound" is sometimes used as well. cheers
No it isn't - overflow is absolutely the right word. Underflows have to do with floating point precision and so there's no such thing as integer underflow. I understand why the term got popular but it's certainly not the "technical" one.
Maybe Nucleur Gandhi is just the friends we made along the way.
EndyBendy Or nuclear wastes cities
This comment deserves more recognition.
Until they're gone
Lmao
The important part is that they did confirm that Gandhi was still nuking the shit out of people in Civ 1.
Speaking as one of the devs who actually worked on the original Civ, yes Gandhi tended to nuke you. It was not intentional, but resulted from the fact that Gandhi usually didn't built much of a military, and advanced rapidly in tech. So when you betray your alliance with him and attack, his only recourse was to nuke you.
That's very interesting, and would explain how so many people have recollections of particularly Gandhi nuking them.
@SoapCanMan this guy actually checks out.
i worked on this game. source: bro just trust me
There was a Dev named sandy Petersen who actually worked on civ so I'm leaning more on this kigbt actually be true
@SoapCanMan you realize most people don't actually name their youtube channel after an developer?
Wouldn't this be really easy to figure out by poking into the code of Civilization 1? If the threat level is stored as an unsigned integer then the Nuclear Gandhi story is probably true, if it isn't then it probably isn't.
as far as I can tell, you can't tell the type of a variable except for which instructions are executed on it, and even then, finding said instructions is a herculean task of patience. there is no piece of data that says "unsigned integer" other than the source code, which we'll never have access to.
@@AmeshaSpentaArmaiti Still, CIV I is probably small enough that it could be reverse engineered, though needing a lot of patience as you say. Another experiment is just to play the game enough and record whether or not Gandhi is actually much more aggressive than other civs that gets nukes. Should be quite easy to do by anybody who have the time to do it.
@@TheMaginor Yeah, just observing Ghandi's behavior is the best option, and it's so self-evident I don't really know why anyone hasn't actually tried it, yet. Of course, I haven't looked, I'm just assuming.
@Matthew Chenault integer overflow is caused by the CPU not caring what happens to extra bits when an addition exceeds the limits of the variables' chosen size.
Dividing by zero is an operation that never terminates, it just goes on forever, so programs crash to avoid locking up the CPU. Neither situation has to do with numbers that don't exist.
At 6:40 , the letter says that even a wraparound wouldn't make Gandhi to be more aggressive than the most aggressive Civs. So there must be a range check somewhere that limits the value to be 1-10.
That weird moment when you walk past my flat in your video...
that odd moment when you dox yourself.
id delete ur comment before u get people coming over lmao
@@ghostlyninja125 Damn right i'm gonna be knocking on the door of every single flat potentially shown in this video to track down a stranger I saw on youtube.
*knocks on door* "are you Paul Hayes? No? Aight, sorry."
*Slightly farther away, another knock* "are you Paul Hayes? No? Aight, sorry..."
Wheres your flat im near the red house
Brian Reynolds: I'm 99.99% sure it's not true
Chris: We'll never really know if its true
There is always 0.01%
The only way to really know, is to be 100%
i think that you could get a copy of the old game and play for a while to be sure
I played a lot of the original civ. Gandhi nuked me a lot. It got to the point where I would restart if Gandhi was next to me. Yes, I am open to the idea that there wasn't a bug and it was just the fact that Gandhi was the one nuking that made it stand out.
However, it wasn't like that many high school kids were playing Civ back then to implant that idea in my mind. Gandhi was a jerk!
he may have little military and lots of tech
I remember digging into it and finding that it wasn't possible in game to trigger an underflow with his threat level. Trying to drop it to 0 would just default to 1. If you forced it into a negative number (memory editor etc.), it could underflow and default to 10 but there was just no way I could find to do that naturally.
Another comment pointed out that it was likely due to his civ focusing on tech and not keeping much of a standing army. He'd reach nukes pretty quickly and when forced into aggression would have to rely on them since his military was so weak.
@@possumverde The video itself is a bit misleading, as it somewhat conflates several ideas: that Ghandi used nukes, that Ghandi became hyper-aggressive, that Ghandi became extremely more nuke-happy than all other leaders, and that Ghandi's behavior was specifically due to an overflow caused when Democracy brought India's threat level to a negative value.
@@BainesMkII Those are all components of the same old rumor, and all of them are untrue. Gandhi would not become hyper-aggressive (at least more than any other leader), was not more nuke-happy than other leaders, and did not have a unique aggression score that could overflow after acquiring democracy (in fact, democracy doesn't even affect aggression scores). Everything about the story is untrue. The only true part is that Gandhi could use nukes, like every other civilization.
The idea that Gandhi's stats made him focus more on technology and less on military is true, but that's also true of many other world leaders. But I guess when Abraham Lincoln drops a nuke on your city, that isn't as shocking and memorable as when Gandhi does it.
@@EebstertheGreat Did you just debunk not only the rumour but also all theorycrafting around it?
Just the fact that you mention that Gandhi might not be more nuke happy than other leaders gives you credibility.
Sid: "I don't want to detract the player's personal experience because in the end it's a story."
Chris: *intense thought;* *hundreds of rereads*
Chris: "'Stay Civilized'? I think he's trying to tell us it's a story."
the real Integer Overflow is the friends we made along the way
@@alexroselle You sir, win the internet.
@@alexroselle And all the military units Gandhi doesn't have if another comment in this section is to be believed.
When you think about it, the term Civilization is a very loaded term.
Could have saved himself a lot of time and effort by just Playing the game and initiating Nuclear Gandhi...
I feel like there’s no way to read that email as anything but a “Don’t ruin Santa Clause for your siblings” type of response from Sid. It’s still very cute that he recognizes that this mythology is still valuable though, not bc it’s true, but bc of what it means to people. It’s probably just like they said, Gandhi was equally as violent as other leaders, but it’s just so much more notable for Gandhi to nuke somebody so it stands out more.
Well, seems like we got our answer. Sid Meyer released his memoir, and outright stated it was never the case. Seems like his email wasn't meant to be mysterious, he just didn't want to give away the secret from his book.
"Reality is often disapointing"
That’s funny because I played the game and dealt with the bug. Perhaps it’s avout legacy and not having one of your biggest games have such a gigantic bug in it.
@@MrJPEzra successful people tend to embrace their mistakes as experience
Such a bug making the legendary nuclear ghandi would only be the best way to reveal a mistake. A lot of bugs/inentended behaviour gave birth to something great. That's hoe the creeper was invented. That's how combos in fighting games were made (moves getting cancelled); it would be a mistake to celebrate and it'd be a huge waste not to profit from it.
Telling the truth about it would be a very hard thing to do brcause it demystifies a mistake that shows features can birth from errors
@@MrJPEzra or maybe you thought it was a bug because you heard the story? Or you misremember after hearing the story?
I have played Civ I a lot when I was a kid and I got nuked many times by many different countries. When I heard about the Ghandi bug I was like okay I might just never playes against India or something.
@@MrJPEzra No you didn't. The creator himself and people who worked on it know more about the game than you. Imagine saying you know better than the creator of it.
You can tell B-boy has been doing some deep invastigations from his beard.
Hearted this for 'B-boy'
Meier's response is an embrace of Death of the Author, not wanting to get involved because it's totally counter to his philosophy as a creator and his reasons for making games. He's a true artist.
Still, it's hard not to take his comment as confirmation that Nuclear Gandhi is a myth and he doesn't want to be the guy who crushes the dream. His message was coy but I don't think it was neutral.
iirc the original meme for civ 1 included half the civs, so its a case of chinese whispers.
afaik Civ 3 was where 'nuclear ghandi' actually was the most agressive of the AI civs, but its been years, im pretty sure CIV 3 was where the OG meme is from, mixed with the civ 1 bug
Fact is Civ 4 was where I first encountered nuclear Ghandi, having not played enough of 3 to really have it come up.
Whether it's a programmed in trait, like it is in 6, or simply the perception you receive when the most peaceful leader on earth does nuke you either in a small error or just because the most peaceful leader is programmed to behave exactly like all the other "peaceful" leaders, it is still very much the product of the storytelling of the game.
Had any other leader in existence been programmed in the same way, no I don't think we would have noticed or cared. It's the fact that Ghandi, in the context of the coding, is likely a generic name and face for the underlying AI, but because of our preconceptions of Ghandi, it becomes obvious when he does something out of character.
I mean, imagine if they had Hitler in the game and he is the most peaceful leader on the map, you WOULD notice. Doesn't matter that Hitler is just a face that goes on an AI that is the same behavior profile as George Washington (ignoring fact that people being judged by the time they existed in is still a mostly common practice) you are going to be critical of everything that's extremely out of character, and it's jarring and it HAS happened with Stalin before but it's a little... less impactful than Hitler. If Chinese leaders become globalist capitalists you'd probably just kind of grin at it realizing that it's just an AI playing with the same levers you have, you Egyptian civ in the modern era with every wonder except the pyramids, dominating the map.
Ghandi using nukes is like Hitler sending you gifts and trying to unite the world, it's an extreme. It doesn't matter that Ghandi might have been just as aggressive as any other ruler in the early game, it's when you get to nukes, SUDDENLY, he's out of character for behaving like he has all game.
This was deft a big in civ1
Someone should reverse engineer the game, that's how I thought people started saying that in the first place
Sid Meier confirmed it is a myth
Fairly certain ‘stay civilized’ is primarily Sid Meier’s catchphrase, I’d be surprised if he doesn’t end every email or piece of text he signs off on with ‘stay civilized.’ Still, that was some amazing investigation work, good job. Too bad nobody you got in contact with didn’t decide to try and look at the original code out of curiosity.
Definitely. I instantly thought, "what the hell? Is he overanalyzing the guy's automatic sig?"
90% certain the "obsession" portrayed by the presenter at Sid's closing is tongue-in-cheek.
Do you think he he signs his divorce papers with it ?
Same
@@swaggerdagger8976 that would sounded like he was being passive aggressive lol
Journalist: What do you think of “Sid Meier’s Civilization”?
Gandhi: I think it would be a good idea.
Hah! I worked on Civ4, Civ revolution, Civ5 and civ6 (at the beginning), and Even I thought the myth of the bit flipping was true. Thanks for making this video.
Imagine living your whole life as a peace maker, becoming famous in India and around the world only to be remembered as the dude who nukes without remorse in civilization
Boshua Borman
Who’s to say thats not how he would act if he was in control of Indias current nuclear arsenal...
Just wait until the kids of all those Gen X Civ players start learning about Gandhi in school, only to have their parents confuse them by complaining about how much he loved using nuclear weapons. "Dad, that's definitely not what my history book says about him..."
@@kyrakia5507 The projecting is intense in this comment.
I mean, the reason he has a reputation for nuking everyone is because he is know as a pacifist.
@@keskes1338 Never seen someone use the word "projecting" to call someone ABSOLUTELY BASED. Man, last year was wierd
Unhelpful answer aside, from that letter Sid Meier sounds like a nice mate.
There is a way to find a definitive answer. You just need to PEEK at the source code for Civ 1 while it's running. Just find the variable that's the aggression level for Gandhi, and see if it actually overflows or not when the civ gets democracy.
It's not like the code is going to change on it's own.
Can you do that? Esp. for a DOS game?
@@hemangchauhan2864
You couldn't look at any human readable code while it runs, but you can track memory addresses and decompile the code. An average programmer would struggle to do it, if they could figure it out at all, but it is possible.
Cheat engine maybe?
An average programmer wouldn't struggle, unless the quality of programmers has degraded quickly. It'd just take way too long to bother for most of us. But it isn't in and of itself a difficult task, just a time consuming one. @@OriginalPiMan
You don't even need to look into the code. Just play a bunch of games and compare the behavior. Getting the "right" version might be the bigger issue.
I've never picked up a Civ game, but it still feels like my heart is being broken. At least from my programming teacher, this story is how integer under/overflow is taught today.
When it does come to learning the truth, I feel like it's time to for the community to act as scientists, rather than journalists. Experimentation and/or decompiling the code will eventually lead us to the truth
No harm done in telling a pedagogically relevant non truth when it doesn't affect anyone or anything, it very well might be treated as a hypothetical scenario at this point. Besides I'm certain that it would work wonders to help students remember about the error and the logic behind it. I mean I personally find it hilarious, a world renown character synonymous with uncompromising peace, nuking you out of the blue, it's just really funny somehow, and just because of that I would probably never forget what an integer overflow is.
@@goprev9715 ... with the minor caveat that this journalist and everyone else erroneously calls this overflow when it's actually an underflow, but yeah
I loved how you presented this one! The near film-noir detective vibe seeped through at just the right amount :) And the final message of respecting player imagination is a nice one to see.
I hope there's more of you getting 'a bit carried away with that one' in future episodes!
I think the description of this bug as apocryphal is correct. Brian Reynolds' letter seems to largely fit with what I can find elsewhere of the descriptions of how aggressiveness is tabulated. Other civilizations apparently have equal (or lower, when counting all three aggressiveness types) aggressiveness as India, so even if it existed, this could not be an India-specific bug.
The bug, as-described, would also rely on some odd programming decisions that, from what I can find of compilers and practices with at-the-time C (what Civ1 was apparently written in), would have been unlikely to occur. While the idea of an underflow bug is common in programming, it wouldn't usually occur with an 8-bit value.
In C, "char", "signed char", and "unsigned char" are the only 8-bit data types (proper integers -- "int" and friends -- are all 16-bit), and, for x86 processors at the time, plain old "char" would, with most compilers, apparently result in "signed char". So someone would likely have had to go out of their way to use an "unsigned char" data type for something that, by all accounts I can find, only needs three possible values.
(It's entirely possible I'm wrong about some aspect of this, though. I was a baby at the time, and finding detailed documentation on the functioning of 30-year-old toolchains is difficult.)
Yes but using unsigned char was for some time preferred for values that are limited to less than 255, such as cases where enums can be used. Later when memory got cheaper this practice got outdated because a 32-bit processor fetches a 32bit value faster than an 8bit, and when memory became very cheap, speed became more important than capacity.
When compiled without debug features C programs typically don't do any checks on type or over/underflow, since it's incredibly wasteful for what should be the cheapest operations in your program. And C does support using 8-bit ints, it's in the header called, pause for dramatic effect, "stdint."
Though I don't anything about 1990s C or if that header even existed back then, I'm willing to bet yes considering how fundemental bytes are.
@@AmeshaSpentaArmaiti FWIW stdint came with C99 (in '99) so I guess the answer is "probably not".
MAPS?
@@sauyon Even before stdint.h was introduced, programmers often used typedefs to create integer types of known size, like u8, u16, s32, u32, and so on (or sometimes u1, u2, s4, u4, ...). The widespread existence of such typedefs makes this argument much less convincing
Nice video! FYI in case nobody mentioned: When an integer wraps back from -1 all the way to the max value, that's actually called an underflow. Overflow is when it goes the other way (Past max value to min value).
That's what I thought as well, but I'm no programmer so I wasn't sure.
TIL, thank you
This is such a stunningly produced work of art! I really appreciate your tenacity with looking into this story, despite the lack of clear resolution it is still really interesting.
I think it was answered pretty clearly.
I'm positive he just ends every email like that
"When the legend becomes fact, print the legend."
Ghandi: "When the Nukes become Nukes. Nuke."
I love how he just ignores the whole letter and then somehow still gets the intended meaning from two words
2:10 huh? i think you mean integer underflow
petty details, but its worth noting nonetheless
Yea, and the maximum value wouldn't be 256. It would be 255. There are 256 values in your standard 8bit systems but 0 is included as a value.
Also the maximum value _is_ 255, 256 is the number of uni--
Oh. Huh. Guess I'm late.
@@ccaagg fire in the hole
Just want to call attention to the Door Monster still at 3:08
Was fully expecting you to walk into the ocean with that POV walk at the end.
OCEAN MAN
TAKE ME BY THE HAND
"Stay Civilized."
Perhaps this is referring to a project of his, about civilness, or something that starts with Civ, like civilizations or something.
Deadass, when you started walking out of your house I was like "nooo bro.. he's gonna go find Sid's house, isnt he?"
As a former games journalist the moment you mentioned 2K PR I chuckled and said: "good luck with that". :D
Alternate title: British man recreates 'All the President's Men' while investigating nuclear Gandi
That was just a beautiful email reply from Sid, he made art that allowed others to enjoy and create their own stories, and dosen't want to play about with that legacy / magic. I'd frame that reply, really classy. Stay Civilized!
I really liked the style, but it kinda hurts my eyes watcnig this for a long time :c
Yeah, these aren’t even frames per second anymore, these are seconds per frame.
But speeding up the video does wonders.
@@Sherolox it's stop-motion
@@manaulhoque6507 but it still kinda hurts
@El Ultimo Pibe Piola de Internet cause it like 3 fps
"I wonder what's happening on twitter" famous last words
I was half expecting this investigation to end in a film noir sequence with Chris staring out of a rainy window drinking whiskey.
Good luck finding a rainy window this summer...
It is not Integer overflow, but underflow in this case.
Honestly had to pause and collect myself for that Bratt Holmes reveal, good lord.
Tremendous work, especially from a technical standpoint!
For me the stop motion'esque style made it hard to watch, and I checked several times to see that my browser was working correctly XD
I think there is to many frames, used at to where it's in between stop motion and video.
Love the content though :)
Agreed! Great content, but the choppiness detracts from the video's overall quality.
Honestly looking at the original tweet i took it as "what if this wasn't an BUG but a feature"
I really liked the way the investigation was visualized. Great video.
It's much harder to overflow or underflow undetected in modern programming languages due to them having "checked arithmetic" where the program crashes when an overflow or underflow happens, and the numeric datatypes tend to be high precision (millions to trillions of largest possible value) to begin with.
Then we have Ethereum smart contracts, where large amount of money is at stake yet their programming language Solidity, in earlier versions, has no overflow check by default and can introduce money-losing security flaws into some smart contracts (but there are bigger sources of security flaws such as recursive calls).
I’m loving this growing genre of UA-cam videos where someone basically just goes completely manic researching one topic to the point of obsession but does it with such sincerity and thoughtfulness that it’s still incredibly compelling viewing
I know that the low framerate of the video is a styleistic choice but its super distracting. I wish it was about 50% smoother
Is it so hard to play first Civilization to prove or disprove the myth?
Well from what I’ve heard it’s a rare glitch as India is usually the first to be wiped out in the game
Except that the fact that Ghandi might use nukes wouldn't prove the bug.
@@catlover0000 why not just use cheat engine and track the value?
That would require effort.
@@catlover0000 yeah catlover what if cheat engine
You would think part of the journalism would be to open the game, and play it.
Wild-Eyed conspiracist Chris Bratt is possibly my favourite Chris Bratt. The framing around this story was great!
Im not even finished the video but i wanna say the editing in this video is so interesting and i can rly appreciate all ur editing work when you so easily could have just talked to a camera and imported some photos, what a fun watch lol
Also i only just realized how old this video is LMAO
3:06 Door Monster!
GOOD SPOT. I didn't think anyone would catch that. -Chris
I was just thinking about the story the other day, and it occured to me that the hardware at the time wouldn't have even used an unsigned integer, as great as the story is to illustrate the overflow problem.
You can even run the game in an emulator, and just monitor each variable in memory.
Hats off to Anni once again. It seems like every other episode she’s doing something completely new and interesting with the graphic design and it is awe inspiring to watch. 😍
I bet Sid always ends his mails with "Stay civilised" when talking about Civ.
Why not just play the game and see for yourself? There's got to be a disk kicking around somewhere.
The fact this wasn't addressed once in the video really really really bugged me...
I think you might be able to get the original for free online, check abandonware or any site that deals in older games
A lot of comments seem to think some global term of "programmers" would have an easy time to work out if it's true. As a programmer myself I doubt this highly. With the notoriety this bug had, and for how long it's been around, the fact no "programmer" wanted to do this up to this point should give some idea of how "easy" this would be.
mad respect to Sid what a legend I loved the games he worked on personally nowadays the civ games aren't the same
This video was AMAZING. I love all the effort that went into its presentation, and your curiousity and charm always shine through. Absolutely love your work mate!
This stop motion video is spectacular; can't imagine the time spent on that. Great story, by the way.
Extremely impressed with the amount of work that went into the stop motion on this video!
There is no bug, it just seems weird to get nuked by Gandhi, so you're more likely to remember that. It's that simple. Sid and Bruce Shelley briefly addressed this at their GDC Classic Games Postmortem on Civ 1 a few years ago.
Fun fact: Sid is mostly just an executive now, and doesn't work directly on the games anymore. However, he's still a coder at heart, so all Firaxis games are written in an older version of C++ (C++ 11 IIRC) so that if he wants to, he can come in and write some of it himself. I don't know if that's still true, but I have it on good authority that it was a few years ago, and I kind of love it
Had we adopted non-violence as the weapon of the strong, because we realised that it was more effective than any other weapon, in fact the mightiest force in the world, we would have made use of its full potency and not have discarded it as soon as the fight against the British was over or we were in a position to wield conventional weapons. But as I have already said, we adopted it out of our helplessness. If we had the atom bomb, we would have used it against the British.
Speech (16 June 1947) as the official date for Indian independence approached (15 August 1947) , as quoted in Mahatma Gandhi : The Last Phase (1958) by Pyarelal Nayyar, p. 326.
They wouldn't have used it because they are indian and don't understand white tech.
@@canabiss8297 That's one of the stupidest comments i've read, and i read quite a few if them
How strange to find you in this random videos comments section 2 years after this video released. Anyway I like your videos :)
Imagine breaking into this guys home and seeing that board on the wall
The sheer variety of presentation that both of you bring to the table with this channel is staggering. Thank you for yet another great one which I was eager to click on as much for seeing how you chose to present it as for the delightful topic itself. :)
I love how you two aren't merely content with some great and fun journalism but also are always pushing what you can do with your presentation!
Love the new animation style, great video as always
I think the framerate should be at least doubled, it's just too slow.
@@TomRyckeboer I'm sorry but you're clearly very ignorant about how stop-motion animation works you can't just "double the framerate" they would have to take twice as many photos and they already took over 1,500 photos so that's *over 3,000 individual photos*
@@Mrblobbybobby I'm not an idiot. I know what words mean. I know what "doubling the framerate" entails. This is just not pleasant to watch as it is.
@@TomRyckeboer hey I didn't call you an idiot just ignorant there's an important difference! If you find it unpleasant that's your opinion but this is animated on 5s so *it's not supposed to convey fluid motion.* The stop-motion feel is a deliberate style choice and saying they should spend hundreds of hours doubling the framerate of a ten minute section of a low-budget YT video when the whole point of it is _the story being told_ NOT for it to be an aesthetically pleasing piece of art is just silly.
If it really bothers you that much you can either play the video at an increased speed to make it smoother or just listen to the voiceover in the background :)
@@Mrblobbybobby Saying someone is "clearly very ignorant" never comes across well, and it really sounds condescending. I know what kind of stop motion he's going for, but even for that it's just too slow to look good.
Play Civ 1 and see if Ghandy indeed becomes extremely aggressive. That part should be easy to verify, since it would happen consistently.
i have no idea why this wasn't the first thing he did.
This seems like something that could probably be decisively solved with a hex editor on the save files. Just find out how Ghandi's actual value changes over time and if it really does max out at points.
This is a buffer underflow. An overflow is where you count higher than the byte limit
Interestingly, Sid Meier has since confirmed in his memoir that there was no such bug in the original civilization, and that the Nuclear Ghandi story is a myth. See the September 8th Bloomberg articled "Creator of ‘Civilization’ Looks Back at One of the Longest Careers in the Industry" for the original source
love your method of portraying the message getting larger than it needed to be
You're going to piss off some nerds with that Love Island reference, made me laugh so much though, completely out of nowhere 😂
Nerd here - not pissed off, but thoroughly confused.
@@HMJ66 I'm a big ol nerd too, somehow I have a girlfriend though and she watches it. Basically half the contestants had to go live in a diffirent house for a week and her boyfriend/lover guy was fooling around with other girls while he was away, he got back, she found out, she was unhappy. Reality TV!
This is too good for UA-cam. It reminds me of James Burke's Connections TV show about the history of science from the 1970's. I loved it!
I mean... Can't you just play Civilization and check?
That focus push from Anni at 10:08... *chef's kiss*
Really appreciate you checking both ways on the bike lane. 😘
I think this is honestly my favourite video from this channel so far and I barely even remembered nuclear Ghandi. Thouroughly enjoyed everything about the video.
I figured someone would have a copy... and someone could read the code and figure out this "easily".
I mean there are people who specifically do this for a living for various reasons.
That, unlike interviews which can be lies or mistaken, would be able to be recreated and hence proved.
Great vid, interesting topic and a cool production style! Keep up the good work, I'm a proud Patreon!
A noclip video and a people make games video in one day , is it Christmas 😱
No, you'd also need a new GMTK video for that to be the case.
Game Maker's Toolkit dammit , now you’ve made me feel bad for you leaving you out 😂
Haha, don't worry, I released my video a few minutes after you left your comment ;)
@@GMTK Ha, god damn it. Trying to put out a video on the same day as either one of you is bad enough! Loved the Celeste piece - very impressed that you managed to graph movement the way you did. -Chris
Wow. First time I not skip sponsoring time because I have never seen anyone to do it at last after the core is told. Well done.
The stop motion was great! Shows just how much time, care and effort your put into these videos. Keep up the amazing work.
The sheer amount of effort on display for this video... now that's story-telling!
I love seeing Chris go off the deep end in search of answers to the questions (nearly) no one asked! And the look of the video? Brilliant, guys. Just...keep doing what you do.
I sid-mire the effort that went into this.
When you already have the answer at 6:30 but need to hit the 10 minute mark
I think we're focusing on the wrong part "AS A BUG" stands out far more imo
What a wonderful episode! I love the story told, I love the conspiracy board, I love the animation, I love the humour. Really well done.
“Nuclear Gandhi” isn’t something i expected to be in my recommended, but is something that made me laugh for a minute
This was legitimately amazing, team! I admire you so much for doing the stop motion segment! Brilliant!
Why haven’t you blown up? Your channel is amazing .
I used to love civilization, I still love the experience what it gave me for more than 20 years now. Used to love to play with Ghandi and build a massive economy to force my enemies on their knees. Unfortunately with the newest addition to the series, I feel disheartened. It feels, you buy small parts of the game with every new expansion what should have been in the original copy and included in the £60 what you payed for it. It scares me that all great pc game makers are on the path of EA, Blizzard and alike. It scares me, that every new game what brings a new perspective a new idea to the table, are destened to turn on that same path as well. That is the reasin why I've decided I don't give a shit anymore, I will get out of my chair, and start building my own civilization, starting from scratch. So anyone knows how to cut trees? I'm looking for a worker!
what you are talking about around 2:15 is not integer overflow, but integer underflow, as it is a value smaller than can be stored (0)
and integer overflow would be if it went over the storable value of, in this example, 255 (not 256, as the 256th number is the 0, it goes 0-255)
I've never thought about how forked up it is that democracy is seen as the final form of a civilisation and how democracies are less likely to go to war with people, despite, you know, all the wars
I mean, if you compare most democracies with most dictatorships, democracies tend to be more peaceful because they have a justification other than "I protect you from evil foreigners". Not to say democracies don't go to war, but especially civil wars are quite a bit rarer.
@@toboterxp8155 sure, but those factors still imply there are no better systems than democracy, which we'd bloody well hope there are given how badly democracy is failing us across the globe. Plus there are more options than democracy and dictatorship.
@@disposable157 I mean, not really? The big problem with governments is corruptibility. Sooner or later someone or some group will try to establish a dictatorship. The only way to avoid that is to make sure everyone can be replaced quickly, and has as little responsability as possible - something that democracy is somewhat optimised for. Though especially the older style of democracy, like in Britain or the US, isn't great at that, which is why they are almost dictatorships these days.
@@toboterxp8155 the anarcho-socialist spectrum of societies have options that don't include governments. I'm not sure I agree about the inevitability of power corrupting people either - that happens a lot, yes, but mostly because we've so far used a lot of systems that insulate the powerful from the consequences of their actions until they push things so far that guillotine blades start getting sharpened. Still, this isn't a political studies video. I just find the assumptions games like Civ make to be interesting. Similarly, in sim city, it makes you zone things into commercial, residential and industrial zones, which is a very strange system to those outside the US and Canada, but is baked into the core of the game. Things that get presented as normal, despite being choices the deva are making are fascinating.
@@disposable157 Well, to achieve internal peace, there needs to be a monopoly of violence. Otherwise factions will at least sometimes solve their problems with conflict and violence, and there's noone to enforce one coherent set of societal rules across the country. So a government is pretty much invetiable, which we can observe both historically and across cultures.
i LOVE the stop motion in this
Forget it Chris, it's strategytown
Genuinely though, I think this is my favourite piece from you yet, the story was fascinating and the visuals were straight up gorgeous
yo the style on this video is AMAZING.
Just test the code forhead
Your videos have a really good quality and are always interesting. Good job!
teeeeeechnically that's an integer underflow, not overflow. *My memory banks had been corrupted; integer overflow is certainly the correct term. To prevent this kind of confusion, "integer wraparound" is sometimes used as well. cheers
No it isn't - overflow is absolutely the right word. Underflows have to do with floating point precision and so there's no such thing as integer underflow. I understand why the term got popular but it's certainly not the "technical" one.
@@_j4nw I stand corrected. Cheers
@@_j4nw it's going under though
The framerate gave me a headache. Hope this doesn't become a regular presentation style.