this post was submitted on 19 Aug 2026
795 points (99.4% liked)

AntiTrumpAlliance

1785 readers
1245 users here now

About

An alliance among all who oppose Donald Trump's actions, positions, cabinet, supporters, policies, or motives. This alliance includes anyone from the left or the right; anyone from any religion or lack thereof; anyone from any country or state; any man, woman or child.

Rules

-No pro-Trump posts or comments

-No off topic posts

-Be civil

-No trolling

-Follow Lemmy terms of service

Social Media

Discord

Reddit

Other Communities

!desantisthreatensusa@lemmy.world

!antifascism@midwest.social

!politicus@kbin.social

founded 2 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] thanevim@lemmy.world 40 points 2 days ago (3 children)

I wonder if the teams behind games like Civilization are taking notes on all this. I like to imagine some of these headlines were tossed around in board meetings a decade+ ago, and turned down cause they were "too outlandish, no one would actually do" them

[–] DrPop@lemmy.world 2 points 1 day ago

I play Total War 3 Kingdoms and this is very much a problem. Managing supplies is so important for sieges. Sometimes you have to have a relief army for prolonged ones. If we knew we didn't have enough apples in that region did they set up anything or did they bank on Iran rolling over?

[–] InternetCitizen2@lemmy.world 13 points 1 day ago

This already happens in civ. Its the I forgot to upgrade this unit problem.

[–] Lemminary@lemmy.world 3 points 1 day ago (1 children)

With Ghandi going nuclear at every chance, I think they totally knew.

[–] okamiueru@lemmy.world 10 points 1 day ago* (last edited 1 day ago) (2 children)

(Might be something everyone knows) The Nuclear Ghandi thing was a unsigned integer issue. His "war mongering" value reached zero, and lowering once more made it wrap around to max value and turn him into a lunatic.

[–] ShinkanTrain@lemmy.ml 7 points 1 day ago* (last edited 1 day ago) (2 children)

This is probably one of the most shared pieces game lore, but it isn't actually true! Sid Meier himself explained in his memoirs.

Civ 1 only has three aggresion levels, and Gandhi always stayed at the lowest one, like many others leaders. A programmer might have to correct me here, but the language the game was written in (C) doesn't even have unsigned integers by default.

The myth probably spread out because it's a fun story, and being nuked by Gandhi is just a funny memorable thing that stuck with people. I haven't verified this, but he also has the Scientific trait, which means he's likely to reach the nuclear tech before other Civs.

[–] okamiueru@lemmy.world 2 points 1 day ago

Seem that you are indeed right! Thanks for clearing that up!

To quote the relevant parts:

... It’s the fact that none of it is true. The overflow error never happened at all. It is true that Gandhi would—eventually—use nukes when India was at war, just like any civilization in the game, and at the time this did strike a lot of players as odd. [...] Since all leaders used the same basic diplomacy script [...] But at no point did a democratic score change, or any value approaching 255, come into it. That kind of bug comes from something called unsigned characters, which are [...] not something I used for the leader traits. Brian Reynolds wrote Civ II in C++, and he didn’t use them, either. [...] Gandhi’s military aggressiveness score remained at 1 throughout the game. [...]

[–] boonhet@lemmy.zip 1 points 1 day ago (1 children)

Pretty sure C has had unsigned ints from the start, but who knows what data type they actually used. It was the 90s so using small data types where possible was common, aggression could've been a short, a char, etc. Also I think C programmers like using enums and that's a valid use case for enum (low, med, high)

[–] ShinkanTrain@lemmy.ml 1 points 1 day ago (1 children)

Does it assume int is signed if you don't specify?

[–] bitchkat@lemmy.world 2 points 1 day ago

In c or c++ 'int" is signed.

[–] Knock_Knock_Lemmy_In@lemmy.world 3 points 1 day ago (1 children)
[–] Amir@lemmy.ml 5 points 1 day ago (1 children)

This phenomenon is called integer overflow.

Underflow, but close enough

[–] okamiueru@lemmy.world 5 points 1 day ago* (last edited 1 day ago)

I don't think it's wrong to call it integer overflow, as that covers wrap around in either direction. I don't think there is any mention of "integer underflow" in any IEEE standard.

There is however mention of arithmetic underflow, but that relates to a precision issue with floating point numbers, and not negative wrap around. (See IEEE 754).

It's still understood what one might mean by integer underflow. But if anything, I'd say it's a further specification of a type of integer overflow, and certainly not a necessary distinction.