Microsoft Small Basic

Program Listing: KGQ218
TextWindow.Title = "GAME OF STEVE"

Start:

TextWindow.Write ("Hey, bro! What's your name? >")
username = TextWindow.Read ()
uppername = Text.ConvertToUpperCase (username)
TextWindow.WriteLine ("Is your name " + uppername + "? Y/N")
option = TextWindow.Read ()
upperoption = Text.ConvertToUpperCase (option)

QuestionBranch1:

If upperoption = "Y" Then
TextWindow.WriteLine ("Can I call you Steve instead? Y/N")
option = TextWindow.Read ()
upperoption = Text.ConvertToUpperCase (option)

QuestionBranch1a:
If upperoption = "Y" Then
Goto Programstart
ElseIf upperoption = "N" then
TextWindow.WriteLine ("I'll call you Steve anyway.")
TextWindow.Read()
Goto Programstart
Else
TextWindow.WriteLine ("That's not a valid answer!!")
Goto Start
EndIf
ElseIf upperoption = "N" then
TextWindow.WriteLine ("Then fuck off!!")
Goto endprogram
Else
TextWindow.WriteLine ("That's not a valid answer!!")
Goto Start
EndIf

Programstart:

TextWindow.WriteLine ("So, Steve, what's up?")
TextWindow.WriteLine ("We're going to play a game called...")
TextWindow.Read()
TextWindow.ForegroundColor = "red"
TextWindow.WriteLine ("GAME OF STEVE!")
TextWindow.ForegroundColor = "white"
TextWindow.Read()
TextWindow.WriteLine ("The game is simple. You're Steve, a happy man that loves collecting bottle caps.")
TextWindow.WriteLine ("But, your rival... what was his name again?")
TextWindow.Write ("'Give a name to your rival.' >")
rival = TextWindow.Read()
upperrival = Text.ConvertToUpperCase (rival)
TextWindow.Read()
TextWindow.WriteLine ("...oh yes, " + upperrival + "! That was his name.")
TextWindow.Read()
TextWindow.WriteLine (upperrival + " likes to steal all your bottle caps when you're away. Protect your collection at all costs!!")
TextWindow.Read()

xcap = 100
xmonth = 1
xcare = 0

Gamestart:

TextWindow.WriteLine ("So, Steve! It is day " + xmonth + " and you have " + xcap + " bottlecaps!")
TextWindow.Read()
TextWindow.Write ("Do you want to take a [walk], [protect] the collection or [sleep]? >")
answer = TextWindow.Read()
loweranswer = Text.ConvertToLowerCase (answer)

Calculation:

If loweranswer = "walk" Then
xcap = xcap + 6
TextWindow.WriteLine ("You went for a walk and you found 6 bottle caps! How lucky!")
TextWindow.Read()
ElseIf loweranswer = "protect" Then
xcare = xcare + 1
TextWindow.WriteLine ("You protected your collection as if your life depended of it. You grew fonder of your bottlecaps.")
TextWindow.Read()
Elseif loweranswer = "sleep" Then
xcap = xcap - 10
TextWindow.WriteLine ("That piece of shit " + upperrival + " stole 10 bottle caps from your collection!")
TextWindow.Read()
Else
TextWindow.WriteLine ("That's not a valid answer!!")
Goto Gamestart
EndIf

If xcare = "10" Then
TextWindow.WriteLine ("Steve! You grew so fond of your collection, the bottlecap god appeared in front of you!")
TextWindow.Read()
TextWindow.WriteLine ("Steve... Congratulations for protecting the bottle caps... As a reward, I'll present you a thousand bottle caps and kill " + upperrival + " !")
TextWindow.Read()
xcap = xcap + 1000
TextWindow.WriteLine ("Suddenly, 1,000 bottle caps rained from the sky. You now have a shitton of bottle caps!")
TextWindow.Read()
TextWindow.WriteLine ("In the meantime, " + upperrival + " died from a heart attack.")
TextWindow.Read()
Else
TextWindow.WriteLine ("")
EndIf

If xcap > "1000" Then
TextWindow.WriteLine ("Congratulations! You have more than 1,000 bottle caps!")
TextWindow.Read()
TextWindow.WriteLine ("You beat the game!")
TextWindow.Read()
Goto Endprogram
EndIf

If xcap = "0" Then
TextWindow.WriteLine ("You have no bottle caps anymore!")
TextWindow.WriteLine ("You got hurt and collapsed...")
Textwindow.Read()
Goto Gameover
EndIf

If xcap < "0" Then
TextWindow.WriteLine ("You have no bottle caps anymore!")
TextWindow.WriteLine ("You got hurt and collapsed...")
Textwindow.Read()
Goto Gameover
EndIf

xmonth = xmonth + 1

TextWindow.WriteLine ("So, Steve! It is day " + xmonth + " and you have " + xcap + " bottlecaps!")
TextWindow.Read()
TextWindow.Write ("Do you want to take a [walk], [protect] the collection or [sleep]? >")
answer = TextWindow.Read()
loweranswer = Text.ConvertToLowerCase (answer)
Goto Calculation

Gameover:

TextWindow.ForegroundColor = "red"
TextWindow.WriteLine ("GAME OVER")
Textwindow.Read()

Endprogram:

TextWindow.WriteLine ("")