Joshua Program

Published

Introduction: Joshua Program

About: I'm Brandon. I program and make food that will most likely kill you. Then I make Instructables about them!

Hey, remember that movie with Matthew Brodrick made forever ago that you loved and always wanted to do. Wargames. You know, how he totally almost instigated a Global Thermonuclear War.

Well, now you can have "Joshua"

This is just a simple batch you can just copy paste this into notepad and save it as a Batch, but this took  me awhile to make and figure out so leave some comments!

Step 1: Copypasta

**********************
**********************
** MADE BY ITzEPiiC **
******* 2010 *********
**********************
**********************

@ECHO OFF

:header
title WOPR
cls
goto start

*********************************************************************************************

:start
color 0F
set name=
set /p name=Your name:
if '%name%'=='James' goto password
if not '%name%'=='James' goto lock

:password
set /p password=Password:
if '%password%'=='Joshua' goto unlock
if not '%password%'=='Joshua' goto lock

:lock
cls
echo Identification not recognized by system.
echo.
echo --Connection Terminated--
pause>nul
goto end

**********************************************************************************************

:unlock
cls
echo.
set /p a= Greetings %name%. 
echo.
set /p b= How are you feeling today? 
echo.
set /p c= It's been a long time. Can you explain the removal of your user account in 1983? 
echo.
set /p games= Its alright. Shall we play a game? (yes/no) 
if not '%games%'=='yes' goto hate
if '%games%'=='yes' goto games

**********************************************************************************************
:games
set /p games= Choose on of the following: Chess, Hearts, Spades. END OF LIST. 
if '%games%'=='Chess' goto chess
if '%games%'=='chess' goto chess
if '%games%'=='Hearts' goto hearts
if '%games%'=='hearts' goto hearts
if '%games%'=='Spades' goto spades
if '%games%'=='spades' goto spades
if '%games%'=='Global Thermonuclear War' goto GTW
if not '%games%'=='Chess' goto hate
if not '%games%'=='chess' goto hate
if not '%games%'=='Hearts' goto hate
if not '%games%'=='hearts' goto hate
if not '%games%'=='Spades' goto hate
if not '%games%'=='spades' goto hate

pause

*********************************************************************************************

:chess
start iexplore http://www.chess.com/play/computer.html
pause>nul

:hearts
start iexplore http://www.games.com/game-play/hearts/single/
pause>nul

:spades
start iexplore http://www.grab.com/games/play-spades
pause>nul

:GTW
start explore http://grognard.com/
pause>nul

**********************************************************************************************

:hate
cls
echo.
echo Okay, then screw you. I'm a computer, I don't need you, I haz the interwebz.
pause>nul

:end
exit


Step 2: **VIEW THIS STEP!**

Yea, you might want to go to this step, because otherwise its not going to work.

set /p name=Your name:
if '%name%'=='James' goto password
if not '%name%'=='James' goto lock

Find this piece of code inside the rest....Okay, got it? Change 'James' to whatever your name is. My name is James so that's why its set to that. Otherwise, you'll put your name in there and it will kick you out.

color 0F

This makes the background black and the text white, just like in the movie.


set /p games= Choose on of the following: Chess, Hearts, Spades. END OF LIST.

While this is the "list of games" its still set to where if you put in Global Thermonuclear War then it will bring up a war-type game.


That's about it. If you have any suggestions for the code, go ahead and leave them in the comments.

Share

    Recommendations

    • Colors of the Rainbow Contest

      Colors of the Rainbow Contest
    • Stick It! Contest

      Stick It! Contest
    • Casting Contest

      Casting Contest
    user

    We have a be nice policy.
    Please be positive and constructive.

    Tips

    Questions

    11 Comments

    how do you run it

    gharrison it dosent work for your because your not supposed to coy thi thing on top of "@echo off"

    it just closes the file when i type in global thermonuclear war and does nothin any help?

    @ECHO OFF

    :header
    title WOPR
    cls
    goto start

    *********************************************************************************************

    :start
    color 0F
    set name=
    set /p name=Your name:
    if '%name%'=='justin' goto password
    if not '%name%'=='justin' goto lock

    :password
    set /p password=Password:
    if '%password%'=='Joshua' goto unlock
    if not '%password%'=='Joshua' goto lock

    :lock
    cls
    echo Identification not recognized by system.
    echo.
    echo --Connection Terminated--
    pause>nul
    goto end

    **********************************************************************************************

    :unlock
    cls
    echo.
    set /p a= Greetings %name%.
    echo.
    set /p b= How are you feeling today?
    echo.
    set /p c= It's been a long time. Can you explain the removal of your user account in 1983?
    echo.
    set /p games= Its alright. Shall we play a game? (yes/no)
    if not '%games%'=='yes' goto hate
    if '%games%'=='yes' goto games

    **********************************************************************************************
    :games
    set /p games= Choose on of the following: Chess, Hearts, Spades. END OF LIST.
    if '%games%'=='Chess' goto chess
    if '%games%'=='chess' goto chess
    if '%games%'=='Hearts' goto hearts
    if '%games%'=='hearts' goto hearts
    if '%games%'=='Spades' goto spades
    if '%games%'=='spades' goto spades
    if '%games%'=='Global Thermonuclear War' goto GTW
    if not '%games%'=='Chess' goto hate
    if not '%games%'=='chess' goto hate
    if not '%games%'=='Hearts' goto hate
    if not '%games%'=='hearts' goto hate
    if not '%games%'=='Spades' goto hate
    if not '%games%'=='spades' goto hate
    if not '%games%'=='Global Thermonuclear War' goto hate

    pause

    *********************************************************************************************

    :chess
    start iexplore http://www.chess.com/play/computer.html
    pause>nul

    :hearts
    start iexplore http://www.games.com/game-play/hearts/single/
    pause>nul

    :spades
    start iexplore http://www.grab.com/games/play-spades
    pause>nul

    :GTW
    start iexplore
    pause>nul

    **********************************************************************************************

    :hate
    cls
    echo.
    echo Okay, then screw you. I'm a computer, I don't need you, I haz the interwebz.
    pause>nul

    :end
    exit

    It doesn't work this is what I put in, please help me.
    **********************
    **********************
    ** MADE BY ITzEPiiC **
    ******* 2010 *********
    **********************
    **********************

    @ECHO OFF

    :header
    title WOPR
    cls
    goto start

    *********************************************************************************************

    :start
    color 0F
    set name=
    set /p name=Your name:
    if '%name%'=='James' goto password
    if not '%name%'=='James' goto lock

    :password
    set /p password=Password:
    if '%password%'=='Joshua' goto unlock
    if not '%password%'=='Joshua' goto lock

    :lock
    cls
    echo Identification not recognized by system.
    echo.
    echo --Connection Terminated--
    pause>nul
    goto end

    **********************************************************************************************

    :unlock
    cls
    echo.
    set /p a= Greetings %name%.
    echo.
    set /p b= How are you feeling today?
    echo.
    set /p c= It's been a long time. Can you explain the removal of your user account in 1983?
    echo.
    set /p games= Its alright. Shall we play a game? (yes/no)
    if not '%games%'=='yes' goto hate
    if '%games%'=='yes' goto games

    **********************************************************************************************
    :games
    set /p games= Choose on of the following: Chess, Hearts, Spades. END OF LIST.
    if '%games%'=='Chess' goto chess
    if '%games%'=='chess' goto chess
    if '%games%'=='Hearts' goto hearts
    if '%games%'=='hearts' goto hearts
    if '%games%'=='Spades' goto spades
    if '%games%'=='spades' goto spades
    if '%games%'=='Global Thermonuclear War' goto GTW
    if not '%games%'=='Chess' goto hate
    if not '%games%'=='chess' goto hate
    if not '%games%'=='Hearts' goto hate
    if not '%games%'=='hearts' goto hate
    if not '%games%'=='Spades' goto hate
    if not '%games%'=='spades' goto hate

    pause

    *********************************************************************************************

    :chess
    start iexplore http://www.chess.com/play/computer.html
    pause>nul

    :hearts
    start iexplore http://www.games.com/game-play/hearts/single/
    pause>nul

    :spades
    start iexplore http://www.grab.com/games/play-spades
    pause>nul

    :GTW
    start explore http://grognard.com/
    pause>nul

    **********************************************************************************************

    :hate
    cls
    echo.
    echo Okay, then screw you. I'm a computer, I don't need you, I haz the interwebz.
    pause>nul

    :end
    exit
    set /p name=Your name:
    if '%Gabe%'=='Gabe' goto password
    if not '%Gabe%'=='Gabe' goto lock
    set /p games= Choose on of the following: Chess, Hearts, Spades. END OF LIST.

    Is there a way to get this to open in full screen???

    how do you get it to work?!?!?!?!

    @zovits

    "So I'd recommend changing the relevant lines to these:

    if '%games%'=='global thermonuclear war' goto GTW
    goto hate"

    if your used that it would open what ever you put under GTW and then goto hate, which isnt what the program is supposed to do.

    you wouldnt have it open a GTW game and then say i hate you., unless thats what you want it to do then yea, go for it.

    also the Global Thermonuclear War is too long of an inout for the batch program, keeps coming up with unexpected error, then closes out, i shortened it to global and gtw and it worked fine.

    Why is the line "if not '%games%'=='Chess' goto hate" even needed?
    If the script's execution gets to that point, it is obvious that the value stored in the "games" variable is not recognized by any of the previous lines and so the only option is to jump to the "hate" label.

    So I'd recommend changing the relevant lines to these:

    if '%games%'=='global thermonuclear war' goto GTW
    goto hate

    i hope you don't mind but i just watched the movie and changed a few things, im still giving you credit but i made it a bit more like the movie. heres my code

    **********************
    **********************
    ** MADE BY ITzEPiiC **
    ******* 2010 *********
    **********************
    ***TWIKED BY NICK*****
    *****WELTER 2011******
    **********************
    **********************

    @ECHO OFF

    :header
    title WOPR
    cls
    goto start

    *********************************************************************************************

    :start
    color 0F
    echo.
    echo.
    set name=
    set /p name=Login:
    if '%name%'=='Nick' goto password
    if not '%name%'=='Nick' goto lock

    :password
    echo.
    set /p password=Password:
    if '%password%'=='Joshua' goto unlock
    if not '%password%'=='Joshua' goto lock

    :lock
    cls
    echo Identification not recognized by system.
    echo.
    echo --Connection Terminated--
    pause>nul
    goto end

    **********************************************************************************************

    :unlock
    cls
    echo.
    set /p a= Greetings %name%.
    echo.
    echo.
    set /p b= How are you feeling today?
    echo.
    echo.
    set /p c= It's been a long time. Can you explain the removal of your user account in 1983?
    echo.
    set /p games= Its alright. Shall we play a game? (yes/no)
    echo.
    if not '%games%'=='yes' goto hate
    if '%games%'=='yes' goto games

    **********************************************************************************************
    :games
    set /p games= Choose on of the following: Chess, Hearts, Spades. END OF LIST.
    if '%games%'=='Chess' goto chess
    if '%games%'=='chess' goto chess
    if '%games%'=='Hearts' goto hearts
    if '%games%'=='hearts' goto hearts
    if '%games%'=='Spades' goto spades
    if '%games%'=='spades' goto spades
    if '%games%'=='Global Thermonuclear War' goto GTW
    if '%games%'=='global thermonuclear war' goto GTW
    if not '%games%'=='Chess' goto hate
    if not '%games%'=='chess' goto hate
    if not '%games%'=='Hearts' goto hate
    if not '%games%'=='hearts' goto hate
    if not '%games%'=='Spades' goto hate
    if not '%games%'=='spades' goto hate

    pause

    *********************************************************************************************

    :chess
    start firefox http://www.chess.com/play/computer.html
    pause>nul

    :hearts
    start firefox http://www.games.com/game-play/hearts/single/
    pause>nul

    :spades
    start firefox http://www.grab.com/games/play-spades
    pause>nul

    :GTW
    start firefox http://www.2flashgames.com/f/f-551.htm
    pause>nul

    **********************************************************************************************

    :hate
    echo.
    echo O.K. I really wish we could have played a game together. Perhaps another time. Logging off user Nick.
    pause>nul

    :end
    exit

    as you can see i changed it t have my name, and to open firefox. however i still cant get the GTW to work.. i also made the hate a bit nicer lol.i added some extra echos and space to clean it up a bit.

    Nicely done. I loved that movie.