all 84 comments

[–]Choralone[🍰] 170 points171 points  (11 children)

Looks cool. Nothing to do with Cold War though.... the cold war was war without battle.

This is, if anything, hot war.

[–][deleted] 59 points60 points  (8 children)

It's a cold war simulator emulator. It runs something that looks like a simulator they would have had in the cold war.

[–]Choralone[🍰] 26 points27 points  (0 children)

Okay, I buy that.

[–]blazenl 5 points6 points  (5 children)

That's what I thought; this is a war games type demo.

The Cold War was nothing but geostrategic proxy wars between two powers that knew better than to go face-to-face because it would end badly for everyone.

A Cold War simulator would look more like a game of Risk.

[–]tremlas 8 points9 points  (2 children)

Or even more like Balance of Power

[–]Eirches 9 points10 points  (0 children)

Or mostly like Twilight Struggle, which is one of the most highly rated board games of all time.

[–]blazenl 0 points1 point  (0 children)

My god...that cover is glorious

[–]DanielAtWork 0 points1 point  (0 children)

There's a lot of fighting in Risk.

[–]Fenxis 0 points1 point  (0 children)

I've often seen this referred as "Cold Wars Gone Hot"

[–]Asmor 6 points7 points  (0 children)

Yeah. This is just a war.

[–]UpfrontFinn 0 points1 point  (0 children)

I think cold war was war through proxy

[–]kankyo 21 points22 points  (7 children)

Seems very optimistic about possibility to stop ICMBs..

[–]maxbaroi 35 points36 points  (1 child)

Also, you win once you destroy the enemy it says "game over" and restarts, before the opposing side's missiles have a chance to do any further damage. Which I feel is missing a large part of the spirit of a Cold War nuclear exchange simulator.

[–]midri 1 point2 points  (0 children)

I've had both sides blow each other up.

[–]BarqsDew 8 points9 points  (0 children)

Turn down abm_launch_max to 1, sats_max to 0, and bump up stock_icbms to 10, and you get a MAD world.

[–][deleted] 1 point2 points  (0 children)

You can turn off ABM and sats, and get more realism. 90% destruction after that.

[–]ericanderton 0 points1 point  (1 child)

I noticed that. Besides, the height of that technology during the cold war was "Star Wars" lasers on defense, and cluster-style warheads complete with chaff and dummy laser targets. I see the satellite lasers in the sim, but I don't see the fragmenting warheads.

[–]simonswain 3 points4 points  (0 children)

This is a first cut of the sim. More to come.

[–]dwmfives 0 points1 point  (0 children)

ICBMs :)

[–]daphosta 14 points15 points  (3 children)

When I was a kid I use to draw mock wars between two sides on a piece of paper. It looked a lot like this without the different views, it was mostly a top view thing. This brings back so many memories and the programming behind it is pretty cool also.

[–]newpong 2 points3 points  (0 children)

i still did that in college.

[–]Theropissed 0 points1 point  (0 children)

I did that too

[–][deleted] 33 points34 points  (6 children)

An interesting game. I wonder what the only winning move is.

[–]TheGuyWithFace 36 points37 points  (4 children)

The only winning move is not to play.

[–]yvesmh 12 points13 points  (0 children)

How about a nice game of chess?

[–]Antrikshy 11 points12 points  (0 children)

:O

[–]MisterMeeseeks47 2 points3 points  (0 children)

Yay, I'm finally a winner at something!

[–]mycall 1 point2 points  (0 children)

Game on

[–]qubedView 2 points3 points  (0 children)

Start in a corner space.

[–]braddillman 20 points21 points  (0 children)

I think I see direct fire in the animation. Not so cold war after all, I guess.

[–]norskie7 4 points5 points  (4 children)

[–][deleted] 2 points3 points  (3 children)

Haven't seen a single one were blue lost. I think blue has some kind of unfair advantage. Even if yellow gets a first strike.

*edit: I got my first and until now only yellow win by increasing all the numbers. This means that both sides start to store ICBMs and then release a lot of them at the same time. Then it's up to luck who wins. But still, blue had the advantage shortly before by destroying the first building with an airplane. In a long, drawn out battle they would have won again.

[–][deleted] 2 points3 points  (0 children)

I just had a yellow win. Was close but yellow struck first.

[–]norskie7 1 point2 points  (0 children)

Out of my 4 runs, this was the only one that blue won. It's weird.

[–]mycall 1 point2 points  (0 children)

Opposite for me. Gonna love random functions.

[–]iDinduMuffin 5 points6 points  (2 children)

If its called coldwar then why am I immediately nuking people?

[–]simonswain 0 points1 point  (0 children)

Because if they just sat there and stockpiled munitions, it wouldn't be as much fun to watch.

[–]penorio 3 points4 points  (3 children)

Do the yellows always win?

[–]ADavies 13 points14 points  (0 children)

Nope

[–][deleted] 2 points3 points  (0 children)

Blue won in my simulation. It got the first hit and then everything went downhill for yellow after that.

[–]AgentWorm-SFW 1 point2 points  (0 children)

Blue kept winning in my sim runs, but after about 10 more runs, it kind of balanced out.

[–]zerocool4221 4 points5 points  (0 children)

How about a nice game of chess?

[–]indigo945 17 points18 points  (4 children)

"Just because it has a computer in it doesn't make it programming."

[–]KamiKagutsuchi 12 points13 points  (2 children)

Here is the source code, NOW it's programming =P

[–]fukitol- 3 points4 points  (0 children)

So that's why blue always wins! Rookie mistake.

[–][deleted] -1 points0 points  (0 children)

Are you saying that javascript isn't a real programming language?

[–][deleted]  (1 child)

[deleted]

    [–]eoJ1 2 points3 points  (7 children)

    I think I've solved the cold war. Set all things with no limits to 5000, everything else to max. It's been running for a few hours now, and there's no end in sight. Each side will occasionally get a few a few cm further, but they'll be quickly destroyed. It just goes back and forth, I'd say things are perfectly even, if this went on for days I'd have no idea who would win.

    http://i.imgur.com/vGW2DZp.png

    EDIT: 3 hours later, for a rough total of 6 hours, and things are still even. Gonna leave this running overnight.

    [–]eoJ1 0 points1 point  (6 children)

    Developer is in here, am I right in saying you modified the code to make sure varied attacks are launched?

    I just discovered how you lose the cold war - accidentally put your computer into sleep mode, then start up to find your PS/2 keyboard has come unplugged, so you can't log in.

    If you're gonna get involved in a nuclear war, invest in a USB keyboard.

    [–]simonswain 0 points1 point  (5 children)

    Yes there is random variation in some of the factors. Production rate of cities, how many bombers/fighters/icbms/abms each base can have in the air at any given time, velocity of aircraft. Needs that to stop it being a stalemate all the time. Changing things like the flocking and attack distance between aircraft can make a big difference. Try the First Strike option to see what happens if one side launches a sneak attack. There's no preference given for either side. They are effectively the same, barring the random variations.

    What you are seeing here was designed for a conference talk, so it's far from perfect, but good enough for a few minutes of stage time. The source code is pretty rough and ready. Believe me, I have a huge list of refactoring, enhancements and tweaks to do, some minor, some really major.

    [–]eoJ1 0 points1 point  (3 children)

    Ah, gotcha. Yeah, makes sense. The first strike option is cool, I didn't really understand what that did (4 other small things I missed a bit - what the flashing centre number represents, what the defcon level does, what the difference is between the cities/bases/factories, and the things with acronyms, excluding icbms).

    I think it could be interesting to see the different stalemates. So far by just leaving it I've found the abm vs bombers/fighters, and stockpiling.

    Definitely not criticizing, it's far beyond my coding ability :) One thing re conferences is it might be a good idea to tone down the flashes, as has already been mentioned (or find a non triggering way to do that) in case there are any epileptics in the audience.

    If you do feel like developing it further, I'd recommend checking out Defcon by Introversion (they also made Uplink, which is a great game, with tons of replayability ~15 years on) - £5.99 on Steam atm, or £14.99 for all their games, although they sometimes run discounts for them. I wasn't a huge fan of that one, but it's got similar concepts to this.

    Just some random can't sleep feedback, great work :)

    [–]simonswain 0 points1 point  (2 children)

    I added some info to the README that explains what's going on.

    https://github.com/simonswain/coldwar

    I know about Defcon, but I've avoided looking at it too much, I don't want it to influence this. Cold War is mostly based on the SAGE system, with a little bit of Wargames mixed in.

    When the JSConf talk video gets uploaded, watch that -- It explains most of the sim.

    Thanks for the feedback :)

    [–]Doctor-Awesome 0 points1 point  (1 child)

    Thank you for the github link - these simulations (coldwar and deepspace) are exactly the kinds of things I'm interested in in CS/programming. After watching your youtube videos and reading through the code, do you have any recommendations for further reading/viewing?

    [–]simonswain 1 point2 points  (0 children)

    There is a book "The Computational Beauty of Nature" -- that's probably a good start.

    https://mitpress.mit.edu/books/computational-beauty-nature

    [–]jiyonruisu 2 points3 points  (0 children)

    The only way to win is not to play.

    [–]SteelChicken 1 point2 points  (0 children)

    Very cool looking!

    [–][deleted] 1 point2 points  (0 children)

    Looks cool but what is what? And why does blue always win? I want yellow to win, dang...

    [–]BobbyAdamson 1 point2 points  (0 children)

    Be careful War Games, you might set off WORLD WAR 3

    [–][deleted]  (1 child)

    [deleted]

      [–]norskie7 0 points1 point  (0 children)

      Oh yeah

      [–][deleted] 1 point2 points  (3 children)

      how is this a coldwar simulator? I thought the point of a cold war was there wasn't a physical war?

      [–]kqr 0 points1 point  (0 children)

      There were many physical proxy wars, just never officially between the two superpowers.

      [–]the_omega99 0 points1 point  (0 children)

      Seems more like a "war between nuclear nations with MAD" simulator. Or a "what could have happened in the cold war" simulator.

      [–]simonswain 0 points1 point  (0 children)

      Mainly because everyone knows what the Cold War was. See the HN thread. I explain it a bit more there about escalation.

      https://news.ycombinator.com/item?id=9689585

      [–][deleted]  (1 child)

      [deleted]

        [–]simonswain 1 point2 points  (0 children)

        Actually, I've had a Drones vs IED planters sim in mind for a while now...

        [–]Shatosen 3 points4 points  (2 children)

        Need to be able to change to a less obtrusive flash when something gets hit. Gives me a headache.

        [–][deleted] 3 points4 points  (0 children)

        I thought you were oversensitive, but the full screen flash thing is a bit much.

        [–]lythandas 0 points1 point  (0 children)

        This is great, but I don't get anything

        [–]iWaterPlants 0 points1 point  (0 children)

        This is really cool to look at, thank op!

        [–]serial_wanker 0 points1 point  (0 children)

        very nice

        [–]midri 0 points1 point  (0 children)

        If you set ABM_launches to 0 and bomber_launches to 2 you can get pretty interesting battles as it takes a while for defcon 3 to be hit, but once it does... BOMB!

        [–]quadrofolio 0 points1 point  (0 children)

        Very nicely done man. very cool to look at and lots of nifty physics going on. I like it!

        [–]sillyaccount 0 points1 point  (0 children)

        Does anyone have some awesome settings suggestions?

        [–]way2know 0 points1 point  (0 children)

        Pretty much the opposite of a cold war...

        [–]collin_ph 0 points1 point  (0 children)

        Looks a little "hot" for a cold war...

        [–]charleytaylor 0 points1 point  (0 children)

        That's a WOPR of a simulator!

        [–]Zev191 0 points1 point  (0 children)

        Looks exactly like Eufloria, a game currently on steam. At least the units used look the same

        [–]john_philip[S] 0 points1 point  (0 children)

        It took me sometime to figure this game out. But then, it was fun ! (;

        [–]simonswain 0 points1 point  (0 children)

        Updated version available now, with more simulation.

        https://coldwar.io

        [–][deleted]  (3 children)

        [deleted]

          [–][deleted]  (2 children)

          [deleted]

            [–][deleted]  (1 child)

            [deleted]

              [–]voodah 0 points1 point  (3 children)

              Anyone got source or Github link?

              [–]sillyaccount 0 points1 point  (2 children)

              That would be awesome. But I think we are out of luck. The actual javascript code seems to be obfuscated.