Batch Games
Monopoly:
@echo off
title Monopoly
REM (C) Copyright 2010 GrellesLicht28
REM This is a creation of Makroware.
color 0f
setlocal enabledelayedexpansion
call :SetFields
goto :StartMain
:: Start of setting fields
:SetFields
:SetFields
:: Player 1
if not defined Field1_1 set Field1_1=
if not defined Field2_1 set Field2_1=A
if not defined Field3_1 set Field3_1=
if not defined Field4_1 set Field4_1=
if not defined Field5_1 set Field5_1=
if not defined Field6_1 set Field6_1=
if not defined Field7_1 set Field7_1=A
if not defined Field8_1 set Field8_1=
if not defined Field9_1 set Field9_1=A
if not defined Field10_1 set Field10_1=A
if not defined Field11_1 set Field11_1=i
if not defined Field11_J_1 set Field11_J_1=
if not defined Field12_1 set Field12_1=
if not defined Field13_1 set Field13_1=
if not defined Field14_1 set Field14_1=
if not defined Field15_1 set Field15_1=
if not defined Field16_1 set Field16_1=
if not defined Field17_1 set Field17_1=
if not defined Field18_1 set Field18_1=
if not defined Field19_1 set Field19_1=
if not defined Field20_1 set Field20_1=
if not defined Field21_1 set Field21_1=
if not defined Field22_1 set Field22_1=A
if not defined Field23_1 set Field23_1=
if not defined Field24_1 set Field24_1=A
if not defined Field25_1 set Field25_1=A
if not defined Field26_1 set Field26_1=
if not defined Field27_1 set Field27_1=A
if not defined Field28_1 set Field28_1=A
if not defined Field29_1 set Field29_1=
if not defined Field30_1 set Field30_1=
if not defined Field31_1 set Field31_1=
if not defined Field32_1 set Field32_1=
if not defined Field33_1 set Field33_1=l
if not defined Field34_1 set Field34_1=
if not defined Field35_1 set Field35_1=
if not defined Field36_1 set Field36_1=
if not defined Field37_1 set Field37_1=
if not defined Field38_1 set Field38_1=
if not defined Field39_1 set Field39_1=
if not defined Field40_1 set Field40_1=
:: Player 2
if not defined Field1_2 set Field1_2=
if not defined Field2_2 set Field2_2=e
if not defined Field3_2 set Field3_2=
if not defined Field4_2 set Field4_2=
if not defined Field5_2 set Field5_2=
if not defined Field6_2 set Field6_2=
if not defined Field7_2 set Field7_2=e
if not defined Field8_2 set Field8_2=
if not defined Field9_2 set Field9_2=e
if not defined Field10_2 set Field10_2=e
if not defined Field11_2 set Field11_2=
if not defined Field11_J_2 set Field11_J_2=
if not defined Field12_2 set Field12_2=
if not defined Field13_2 set Field13_2=
if not defined Field14_2 set Field14_2=
if not defined Field15_2 set Field15_2=
if not defined Field16_2 set Field16_2=
if not defined Field17_2 set Field17_2=
if not defined Field18_2 set Field18_2=
if not defined Field19_2 set Field19_2=
if not defined Field20_2 set Field20_2=
if not defined Field21_2 set Field21_2=
if not defined Field22_2 set Field22_2=e
if not defined Field23_2 set Field23_2=
if not defined Field24_2 set Field24_2=e
if not defined Field25_2 set Field25_2=e
if not defined Field26_2 set Field26_2=
if not defined Field27_2 set Field27_2=e
if not defined Field28_2 set Field28_2=e
if not defined Field29_2 set Field29_2=
if not defined Field30_2 set Field30_2=
if not defined Field31_2 set Field31_2=
if not defined Field32_2 set Field32_2=
if not defined Field33_2 set Field33_2=
if not defined Field34_2 set Field34_2=
if not defined Field35_2 set Field35_2=
if not defined Field36_2 set Field36_2=
if not defined Field37_2 set Field37_2=?
if not defined Field38_2 set Field38_2=
if not defined Field39_2 set Field39_2=
if not defined Field40_2 set Field40_2=
exit /b
:: End of setting fields
:: Instructions start here.
:Instructions
:Instructions
cls
echo Instructions of Monopoly
echo ÓÓÓÓÓÓÓÓÓÓÓÓÓÓÓÓÓÓÓÓÓÓÓÓ
echo 1. Each player starts with $1500. Their characters are placed on the field
echo "Go" in the beginning of the game.
echo 2. Every round, the current player has to throw two dice which have 6 sides.
echo The amount thrown is between 2 and 12.
echo.
echo 3. If a player gets on a street or a railroad, he or she can buy it, if it
echo is unowned, yet. Else the player has to pay the rent to the owner depending
echo on the amount of houses or hotels (or railroads).
echo 4. If a player arrives to any other field, he has to follow the instructions
echo given on the field.
echo.
echo 5. Money, which is paid to the bank, goes into "Free Parking" (except for the
echo $50 to escape from Jail). This money can be recollected by arriving on this
echo field.
echo 6. It is not allowed to share money with the other player without arriving on
echo one of his or her streets, railroads or companies, selling the
echo Get-Out-Of-Jail-Free-card or having to follow the instructions of a
echo community chest- or event card.
echo.
echo 7. There are 16 community chest cards and 16 event cards. They are not chosen
echo by following an order, but they are chosen randomly. This allows the same
echo card one after the other.
echo 8. The Get-Out-Of-Jail-Free-Card can only be owned once. If got, this card
echo cannot be chosen by random anymore until it is used or sold.
echo 9. You cannot own two Get-Out-Of-Jail-Free-Cards.
echo.
echo 10. You can only buy houses by arriving right on the field you want to buy
echo some.
echo 11. You can buy 4 houses on each of the 22 streets. The fifth house will be
echo returned into a hotel. The other houses disappear in this case.
echo 12. There is no limit of total houses or hotels to use in the entire game
echo unless all of the streets got a hotel.
echo.
echo 13. If you throw three doublets in a row, you are sent to Jail.
echo 14. In Jail, you can try a doublet at last for three times. Then you have to
echo pay $50. If you don't want to try to roll a doublet, you can pay $50 to
echo escape everytime or you can use your Get-Out-Of-Jail-Free-Card if owned.
echo 15. If you are "just visiting" the Jail, nothing will happen.
echo.
echo 16. By passing "Go", you receive $200. By arriving onto the field "Go", you
echo receive $400.
echo 17. If you get a card which changes your current position, you receive $200 by
echo passing "Go".
echo 18. You do not receive $200 if you are sent to Jail, no matter if passing "Go"
echo or not.
echo.
echo 19. The game ends when one player loses all his or her money. The player is not
echo allowed to sell any property like houses, hotels, streets, railroads,
echo companies or cards anymore.
echo.
set /p Pause=
exit /b
:: Instructions end here.
:StartMain
:StartMain
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ Choose your character: ∫
echo ∫ 1: € ∫
echo ∫ 2: ≤ ∫
echo ∫ 3: ± ∫
echo ∫ 4: ∞ ∫
echo ∫ ∫
echo ∫Enter "instructions" to read them.∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
set /p Character1=Player 1: Character no.
set /p Character2=Player 2: Character no.
if "%Character1%" == "1" set Char_1=€
if "%Character1%" == "2" set Char_1=≤
if "%Character1%" == "3" set Char_1=±
if "%Character1%" == "4" set Char_1=∞
if /i "%Character1%" == "instructions" call :Instructions
if "%Character2%" == "1" set Char_2=€
if "%Character2%" == "2" set Char_2=≤
if "%Character2%" == "3" set Char_2=±
if "%Character2%" == "4" set Char_2=∞
if /i "%Character2%" == "instructions" call :Instructions
if not defined Char_1 goto :StartMain
if not defined Char_2 goto :StartMain
if "%Char_1%" == "%Char_2%" (
echo You cannot use the same character twice.
pause
goto :StartMain
)
set DiceAmount=0
set Escape=4
set Field1_1=%Char_1%
set Field1_2=%Char_2%
set Money_1=1500
set Money_2=1500
set Money_Parking=0
set Player=1
set Player1Position=1
set Player2Position=1
mode con cols=91 lines=600
:FIELD
:FIELD
cls
set OutOfJail=0
if not "%1" == "StepDone" set Go=0
if not "%1" == "Chance_Walked" set RentalTwice=0
set Player=!Player!
echo ⁄ƒƒƒƒƒƒƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒƒƒƒƒƒƒø
echo ≥ Free ≥Kentu-≥Chance≥India-≥Illi- ≥B.^& O.≥Atlan-≥Veni- ≥Water ≥Marvin≥ GO TO ≥
echo ≥ ‹flflfl‹ ≥ cky ≥ ?? ≥ na ≥ nois ≥ RAIL-≥ tic ≥ nor ≥Works ≥ Gar- ≥ ∞∞∞∞∞ ≥
echo ≥!Field21_1! €‹‹‹€ !Field21_2!≥!Field22_1!venu!Field22_2!≥!Field23_1!? ?!Field23_2!≥!Field24_1!venu!Field24_2!≥!Field25_1!venu!Field25_2!≥!Field26_1!ROAD!Field26_2!≥!Field27_1!venu!Field27_2!≥!Field28_1!venu!Field28_2!≥!Field29_1! !Field29_2!≥!Field30_1!dens!Field30_2!≥!Field31_1! ∞∞∞ !Field31_2!≥
echo ≥ ‹€€‹€€‹ ≥ ≥ ? ≥ ≥ ≥ ≥ ≥ ≥ ≥ ≥ ∞ ≥
echo ≥ ∞ ∞ ≥Price ≥ ? ≥Price ≥Price ≥Price ≥Price ≥Price ≥Price ≥Price ≥ ≥
echo ≥ Parking ≥ $220 ≥ ? ≥ $220 ≥ $240 ≥ $200 ≥ $260 ≥ $260 ≥ $150 ≥ $280 ≥ ∞ JAIL ≥
echo √ƒƒƒƒƒƒƒƒƒƒƒƒ≈ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ≈ƒƒƒƒƒƒƒƒƒƒƒƒ¥
echo ≥ New York ≥ ________ ≥ Pacific ≥
echo ≥!Field20_1! Avenue !Field20_2!≥ / / ≥!Field32_1! Avenue !Field32_2!≥
echo ≥Price: $200 ≥ / / ± ± ≥Price: $300 ≥
echo √ƒƒƒƒƒƒƒƒƒƒƒƒ¥ / / ± ± ± √ƒƒƒƒƒƒƒƒƒƒƒƒ¥
echo ≥ Tennessee ≥ / / ± ± ≥North Caro- ≥
echo ≥!Field19_1! Avenue !Field19_2!≥ /_______/ ± ± ≥!Field33_1!ina Avenue!Field33_2!≥
echo ≥Price: $180 ≥ Community Chest ± ± ± ≥Price: $300 ≥
echo √ƒƒƒƒƒƒƒƒƒƒƒƒ¥ ± ± ± √ƒƒƒƒƒƒƒƒƒƒƒƒ¥
echo ≥ Community ≥ ± ± ≥ Community ≥
echo ≥!Field18_1! Chest !Field18_2!≥ ± ± ≥!Field34_1! Chest !Field34_2!≥
echo ≥ ≥ ± ± ≥ ≥
echo √ƒƒƒƒƒƒƒƒƒƒƒƒ¥ ± ± √ƒƒƒƒƒƒƒƒƒƒƒƒ¥
echo ≥ St. James ≥ ± ± ≥Pennsylvania≥
echo ≥!Field17_1! Place !Field17_2!≥ ± ± ≥!Field35_1! Avenue !Field35_2!≥
echo ≥Price: $180 ≥ ± ± ≥Price: $320 ≥
echo √ƒƒƒƒƒƒƒƒƒƒƒƒ¥ ± ± √ƒƒƒƒƒƒƒƒƒƒƒƒ¥
echo ≥PENNSYLVANIA≥ ± ± ≥ SHORT LINE ≥
echo ≥!Field16_1! RAILROAD !Field16_2!≥ ± ± ± ≥!Field36_1! !Field36_2!≥
echo ≥Price: $200 ≥ ± ± ± ≥Price: $200 ≥
echo √ƒƒƒƒƒƒƒƒƒƒƒƒ¥ ± ± √ƒƒƒƒƒƒƒƒƒƒƒƒ¥
echo ≥ Virginia ≥ ± ± ≥ ?? Chance≥
echo ≥!Field15_1! Avenue !Field15_2!≥ ± ± ≥!Field37_1!? ?? ? !Field37_2!≥
echo ≥Price: $160 ≥ ± ± ≥ ? ?? ≥
echo √ƒƒƒƒƒƒƒƒƒƒƒƒ¥ ± √ƒƒƒƒƒƒƒƒƒƒƒƒ¥
echo ≥ States ≥ ± ± ≥ Park Place ≥
echo ≥!Field14_1! Avenue !Field14_2!≥ ± ± ≥!Field38_1! !Field38_2!≥
echo ≥Price: $140 ≥ ± ± ≥Price: $350 ≥
echo √ƒƒƒƒƒƒƒƒƒƒƒƒ¥ ± ± ± √ƒƒƒƒƒƒƒƒƒƒƒƒ¥
echo ≥ Electric ≥ ± ± ± C ________ ≥ LUXURY TAX ≥
echo ≥!Field13_1! Company !Field13_2!≥ ± ± h / / ≥!Field39_1! !Field39_2!≥
echo ≥Price: $150 ≥ ± ± ± a / / ≥ Pay $75 ≥
echo √ƒƒƒƒƒƒƒƒƒƒƒƒ¥ ± ± n / / √ƒƒƒƒƒƒƒƒƒƒƒƒ¥
echo ≥St. Charles ≥ ± ± c / / ≥ Boardwalk ≥
echo ≥!Field12_1! Place !Field12_2!≥ ± e /_______/ ≥!Field40_1! !Field40_2!≥
echo ≥Price: $140 ≥ ± ≥Price: $400 ≥
echo √ƒƒƒƒƒƒƒƒƒƒƒƒ≈ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ¬ƒƒƒƒƒƒ≈ƒƒƒƒƒƒƒƒƒƒƒƒ¥
echo ≥Just≥ IN ≥Connec≥Ver- ≥Chance≥Orien-≥READIN≥INCOME≥Baltic≥ ≥Medite≥Collect $200≥
echo ≥v ≥…ÕÀÕÀÕª≥ticut ≥ mont≥ ?? ≥tal ≥RAIL- ≥ TAX ≥Avenue≥Commu-≥r... ≥as you pass ≥
echo ≥!Field11_1! !Field11_2!≥∫!Field11_J_1!∫ ∫!Field11_J_2!∫≥!Field10_1!venu!Field10_2!≥!Field9_1!venu!Field9_2!≥!Field8_1!? ?!Field8_2!≥!Field7_1!venu!Field7_2!≥!Field6_1!ROAD!Field6_2!≥!Field5_1! !Field5_2!≥!Field4_1! !Field4_2!≥!Field3_1!nity!Field3_2!≥!Field2_1!venu!Field2_2!≥!Field1_1! !Field1_2!≥
echo ≥s ≥∫ ∫ ∫ ∫≥ ≥ ≥ ? ≥ ≥ ≥Pay ≥ ≥ ≥ ≥ €flflfl ‹‹‹‹ ≥
echo ≥i ≥»Õ Õ Õº≥Price ≥Price ≥ ? ≥Price ≥Price ≥10%% or≥Price ≥Chest ≥Price ≥ € fl‹ € € ≥
echo ≥ting≥ JAIL ≥ $120 ≥ $100 ≥ ? ≥ $100 ≥ $200 ≥$200 ≥ $60 ≥ ≥ $60 ≥ flflflfl flflflfl ≥
echo ¿ƒƒƒƒƒƒƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒ¡ƒƒƒƒƒƒƒƒƒƒƒƒŸ
if "%1" == "StepDone" exit /b
if "%1" == "Chance_Walked" goto :StartComparingPositions
if "!Field11_J_%Player%!" == "!Char_%Player%!" call :InJail
if "%OutOfJail%" == "1" goto :FIELD
:RecallDisplay
:RecallDisplay
echo.
echo Player %Player% (!Char_%Player%!)'s turn:
:: Checks every street if owned by the current player.
echo Streets owned:
set Display_%Player%=
set Display_Amount_%Player%=0
FOR %%A IN (MediterraneanAvenue BalticAvenue ReadingRailroad OrientalAvenue VermontAvenue ConnecticutAvenue St.CharlesPlace ElectricCompany StatesAvenue VirginiaAvenue PennsylvaniaRailroad St.JamesPlace TennesseeAvenue NewYorkAvenue KentuckyAvenue IndianaAvenue IllinoisAvenue B.O.Railroad AtlanticAvenue VeninorAvenue WaterWorks MarvinGardens PacificAvenue NorthCarolinaAvenue PennsylvaniaAvenue ShortLine ParkPlace Boardwalk) DO (
if "!%%A!" == "%Player%" (
if not "!Display_Amount_%Player%!" == "4" (set Display_%Player%=!Display_%Player%!%%A / ) ELSE (set Display_%Player%=!Display_%Player%!%%A)
set /a Display_Amount_%Player%=!Display_Amount_%Player%! + 1
if "!Display_Amount_%Player%!" == "4" (
echo !Display_%Player%!
set Display_Amount_%Player%=0
set Display_%Player%=
)
)
if "%%A" == "Boardwalk" if not "!Display_Amount_%Player%!" == "0" echo !Display_%Player%!
)
echo.
if "!FreeOutOfJail_%Player%!" == "1" (
set OtherPlayer=
set Sell_JailCard=
set Accept_JailCard=
echo You own a card to get out of jail for free.
echo Enter "sell for XX" to sell it to the other player for XX dollars.
set /p Sell_JailCard=
if /i "!Sell_JailCard:~0,9!" == "sell for " (
echo To the other player: Do you want to accept the price [!Sell_JailCard:~9,4!],
echo then enter "Yes, I would like to.".
set /p Accept_JailCard=
if /i "!Accept_JailCard!" == "Yes, I would like to." (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + !Sell_JailCard:~9,4!
echo ƒƒƒ^> Money increased from $!Puffer! by $!Sell_JailCard:~9,4! to $!Money_%Player%!.
if "!Player!" == "1" (
set Puffer=!Money_2!
set /a Money_2=!Money_2! - !Sell_JailCard:~9,4!
echo ƒƒƒ^> Money decreased from $!Puffer! by $!Sell_JailCard:~9,4! to $!Money_2!.
if "!Money_2:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! - !Sell_JailCard:~9,4!
set /a Money_2=!Money_2! + !Sell_JailCard:~9,4!
echo ƒƒƒ^> Money amounts set back.
)
) ELSE (
set Puffer=!Money_1!
set /a Money_1=!Money_1! - !Sell_JailCard:~9,4!
echo ƒƒƒ^> Money decreased from $!Puffer! by $!Sell_JailCard:~9,4! to $!Money_1!.
if "!Money_1:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! - !Sell_JailCard:~9,4!
set /a Money_1=!Money_1! + !Sell_JailCard:~9,4!
echo ƒƒƒ^> Money amounts set back.
)
)
if "!FreeOutOfJail_Chance!" == "!FreeOutOfJail_%Player%!" (
set FreeOutOfJail_Chance=0
) ELSE (
set FreeOutOfJail_Community=0
)
set FreeOutOfJail_%Player%=0
) ELSE (
echo Trade cancelled.
)
)
) ELSE (
echo Press any key to roll a dice...
if not "%1" == "StepDone" pause >nul
)
if "%1" == "StepDone" exit /b
:RollADice
:RollADice
:: Randomly roll two dices. The IF's make sure they are between 1 and 6.
set /a DiceOne=%random% %% 6 + 1
set /a DiceTwo=%random% %% 6 + 1
:: Resetting the current player's position.
set Field!Player%Player%Position!_%Player%=
:: Calculating the amount of steps to go. Also informs the user.
set /a Dice=%DiceOne% + %DiceTwo%
echo Dice one (%DiceOne%) + dice two (%DiceTwo%) = %Dice%
set /a Player%Player%Position=!Player%Player%Position! + %Dice%
:: Check if the player went over "GO".
if not "!Player%Player%Position:~1,1!" == "" if "!Player%Player%Position:~0,1!" GEQ "4" if "!Player%Player%Position:~1,1!" GTR "0" (
set /a Player%Player%Position=!Player%Player%Position! - 40
set Puffer=!Money_%Player%!
if "!Player%Player%Position:~0,1!" GTR "1" (
set /a Money_%Player%=!Money_%Player%! + 200
set Go=1
)
)
:: Reset the fields after having changed the position.
call :SetFields
:: Set the new player's position.
set Field!Player%Player%Position!_%Player%=!Char_%Player%!
pause >nul
:RollDone
:RollDone
:: Showing the user the new position before dwelling on it.
call :FIELD StepDone
call :RecallDisplay StepDone
echo Dice one (%DiceOne%) + dice two (%DiceTwo%) = %Dice%
if "!Go!" == "1" echo ƒƒƒ^> Money increased from $!Puffer! by $200 to $!Money_%Player%!.
:StartComparingPositions
:StartComparingPositions
pause >nul
:: Dwelling on the player's position.
if "!Field1_%Player%!" == "!Char_%Player%!" call :GO
if "!Field2_%Player%!" == "!Char_%Player%!" call :MediterraneanAvenue
if "!Field3_%Player%!" == "!Char_%Player%!" call :CommunityChest
if "!Field4_%Player%!" == "!Char_%Player%!" call :BalticAvenue
if "!Field5_%Player%!" == "!Char_%Player%!" call :IncomeTax
if "!Field6_%Player%!" == "!Char_%Player%!" call :ReadingRailroad
if "!Field7_%Player%!" == "!Char_%Player%!" call :OrientalAvenue
if "!Field8_%Player%!" == "!Char_%Player%!" call :Chance
if "!Field9_%Player%!" == "!Char_%Player%!" call :VermontAvenue
if "!Field10_%Player%!" == "!Char_%Player%!" call :ConnecticutAvenue
if "!Field11_%Player%!" == "!Char_%Player%!" call :AtJail
if "!Field12_%Player%!" == "!Char_%Player%!" call :St.CharlesPlace
if "!Field13_%Player%!" == "!Char_%Player%!" call :ElectricCompany
if "!Field14_%Player%!" == "!Char_%Player%!" call :StatesAvenue
if "!Field15_%Player%!" == "!Char_%Player%!" call :VirginiaAvenue
if "!Field16_%Player%!" == "!Char_%Player%!" call :PennsylvaniaRailroad
if "!Field17_%Player%!" == "!Char_%Player%!" call :St.JamesPlace
if "!Field18_%Player%!" == "!Char_%Player%!" call :CommunityChest
if "!Field19_%Player%!" == "!Char_%Player%!" call :TennesseeAvenue
if "!Field20_%Player%!" == "!Char_%Player%!" call :NewYorkAvenue
if "!Field21_%Player%!" == "!Char_%Player%!" call :FreeParking
if "!Field22_%Player%!" == "!Char_%Player%!" call :KentuckyAvenue
if "!Field23_%Player%!" == "!Char_%Player%!" call :Chance
if "!Field24_%Player%!" == "!Char_%Player%!" call :IndianaAvenue
if "!Field25_%Player%!" == "!Char_%Player%!" call :IllinoisAvenue
if "!Field26_%Player%!" == "!Char_%Player%!" call :B.O.Railroad
if "!Field27_%Player%!" == "!Char_%Player%!" call :AtlanticAvenue
if "!Field28_%Player%!" == "!Char_%Player%!" call :VeninorAvenue
if "!Field29_%Player%!" == "!Char_%Player%!" call :WaterWorks
if "!Field30_%Player%!" == "!Char_%Player%!" call :MarvinGardens
if "!Field31_%Player%!" == "!Char_%Player%!" call :SendToJail
if "!Field32_%Player%!" == "!Char_%Player%!" call :PacificAvenue
if "!Field33_%Player%!" == "!Char_%Player%!" call :NorthCarolinaAvenue
if "!Field34_%Player%!" == "!Char_%Player%!" call :CommunityChest
if "!Field35_%Player%!" == "!Char_%Player%!" call :PennsylvaniaAvenue
if "!Field36_%Player%!" == "!Char_%Player%!" call :ShortLineRailroad
if "!Field37_%Player%!" == "!Char_%Player%!" call :Chance
if "!Field38_%Player%!" == "!Char_%Player%!" call :ParkPlace
if "!Field39_%Player%!" == "!Char_%Player%!" call :LuxuryTax
if "!Field40_%Player%!" == "!Char_%Player%!" call :Boardwalk
if "%1" == "Chance_Walked" exit /b
:: Changes the player
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
:: Counting the doublets
set goto_immediately=0
if defined DiceOne if defined DiceTwo if "%DiceOne%" == "%DiceTwo%" (
set /a DiceAmount=!DiceAmount! + 1
echo.
echo You got a doublet [%DiceOne% - %DiceTwo%], you can do another round.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set goto_immediately=1
pause
)
::Checks if 3 doublets in a row. If so, sends the user to jail.
if "!DiceAmount!" == "3" if "%DiceOne%" == "%DiceTwo%" (
echo You got 3 doublets in a row, you are now sent to jail.
set goto_immediately=0
pause
call :SendToJail Doublets
)
if not "!goto_immediately!" == "1" set DiceAmount=0
goto :FIELD
:: Start of fields.
:GO
:GO 1
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ ≤≤≤≤≤≤≤≤≤≤≤ ∫
echo ∫ ≤≤≤ ∫
echo ∫ ≤≤≤ ∫
echo ∫ ≤≤≤ ∫
echo ∫ ≤≤≤ ≤≤≤≤≤≤ ≤≤≤≤≤≤≤≤ ∫
echo ∫ ≤≤≤ ≤≤≤ ≤≤ ≤≤ ∫
echo ∫ ≤≤≤ ≤≤≤ ≤≤ ≤≤ ∫
echo ∫ ≤≤≤ ≤≤≤ ≤≤ ≤≤ ∫
echo ∫ ≤≤≤≤≤≤≤≤≤≤ ≤≤≤≤≤≤≤≤ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ Collect $200 as you pass or ∫
echo ∫ collect $400 as you meet. ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 400
echo ƒƒƒ^> Money increased from $%Puffer% by $400 to $!Money_%Player%!.
echo.
pause
exit /b
:MediterraneanAvenue
:MediterraneanAvenue 2
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined MediterraneanAvenue_Houses set MediterraneanAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Mediterranean Avenue ∫
echo ∫ ∫
echo ∫ PRICE $60 RENT $2 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $10 ∫
echo ∫ ∫
echo ∫ With 2 Houses $30 ∫
echo ∫ ∫
echo ∫ With 3 Houses $90 ∫
echo ∫ ∫
echo ∫ With 4 Houses $160 ∫
echo ∫ ∫
echo ∫ With HOTEL $250 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $50 ∫
echo ∫ ∫
echo ∫ Mortgage value $30 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!MediterraneanAvenue!" == "%Player%" goto :MediterraneanAvenue_Houses
if defined MediterraneanAvenue goto :MediterraneanAvenue_PayRent
echo Press [1] to buy this street for $60 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 60
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 60
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $60 to $!Money_%Player%!.
set MediterraneanAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :MediterraneanAvenue
:MediterraneanAvenue_Houses
:MediterraneanAvenue_Houses
if "!MediterraneanAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !MediterraneanAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $30.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 50
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 50
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $50 to $!Money_%Player%!.
set /a MediterraneanAvenue_Houses=!MediterraneanAvenue_Houses! + 1
if not "!MediterraneanAvenue_Houses!" == "5" (echo This street has got !MediterraneanAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 30
echo ƒƒƒ^> Money increased from $!Puffer! by $30 to $!Money_%Player%!.
set MediterraneanAvenue=
set MediterraneanAvenue_Houses=0
)
)
goto :MediterraneanAvenue_Houses
:MediterraneanAvenue_PayRent
:MediterraneanAvenue_PayRent
if "!MediterraneanAvenue_Houses!" == "0" set PayRent=2
if "!MediterraneanAvenue_Houses!" == "1" set PayRent=10
if "!MediterraneanAvenue_Houses!" == "2" set PayRent=30
if "!MediterraneanAvenue_Houses!" == "3" set PayRent=90
if "!MediterraneanAvenue_Houses!" == "4" set PayRent=160
if "!MediterraneanAvenue_Houses!" == "5" set PayRent=250
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:CommunityChest
:CommunityChest 3/18/34
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ Community Chest ∫
echo ∫ ∫
echo ∫ ################# ∫
echo ∫ #///////////////## ∫
echo ∫ #################I# ∫
echo ∫ #,,,,,,,,,,,,,,,#I# ∫
echo ∫ #,,,,,,,,,,,,,,,## ∫
echo ∫ #,,,,,,,,,,,,,,,# ∫
echo ∫ ################# ∫
echo ∫ #,,,,,,,,,,,,,,,## ∫
echo ∫ #,,,,,,,,,,,,,,,#I# ∫
echo ∫ #################II# ∫
echo ∫ #jjjjjjjjjjjjjjj#II# ∫
echo ∫ #jjjjjjjjjjjjjjj#I# ∫
echo ∫ #jjjjjjjjjjjjjjj## ∫
echo ∫ ################# ∫
echo ∫ ∫
echo ∫ You found a community ∫
echo ∫ chest, draw a card. ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
:ChooseCommunityCard
:ChooseCommunityCard
set /a ChooseCommunityCard=%random:~0,2% - 15
if "%ChooseCommunityCard:~0,1%" == "-" goto :ChooseCommunityCard
if "%ChooseCommunityCard%" == "0" goto :ChooseCommunityCard
if not "%ChooseCommunityCard:~1,1%" == "" if "%ChooseCommunityCard:~0,1%" GTR "1" (goto :ChooseCommunityCard) ELSE (if "%ChooseCommunityCard:~1,1%" GTR "6" goto :ChooseCommunityCard)
if "!FreeOutOfJail_Community!" == "1" if "%ChooseCommunityCard%" == "7" goto :ChooseCommunityCard
if "%ChooseCommunityCard%" == "1" set Var=%%A
if "%ChooseCommunityCard%" == "2" set Var=%%B
if "%ChooseCommunityCard%" == "3" set Var=%%C
if "%ChooseCommunityCard%" == "4" set Var=%%D
if "%ChooseCommunityCard%" == "5" set Var=%%E
if "%ChooseCommunityCard%" == "6" set Var=%%F
if "%ChooseCommunityCard%" == "7" set Var=%%G
if "%ChooseCommunityCard%" == "8" set Var=%%H
if "%ChooseCommunityCard%" == "9" set Var=%%I
if "%ChooseCommunityCard%" == "10" set Var=%%J
if "%ChooseCommunityCard%" == "11" set Var=%%K
if "%ChooseCommunityCard%" == "12" set Var=%%L
if "%ChooseCommunityCard%" == "13" set Var=%%M
if "%ChooseCommunityCard%" == "14" set Var=%%N
if "%ChooseCommunityCard%" == "15" set Var=%%O
if "%ChooseCommunityCard%" == "16" set Var=%%P
echo ⁄ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒø
echo ≥ Community Card ≥
echo ≥ ≥
FOR /F "tokens=1-16 delims=/" %%A IN ("≥ Grand Opera ≥/≥ Advance to Go. ≥/≥ You have won ≥/≥ Doctor's fee. ≥/≥ Christmas fund ≥/≥ You inherit ≥/≥Get ouf of Jail ≥/≥You are assessed≥/≥ From sale of ≥/≥ Pay school tax ≥/≥ Income tax ≥/≥ Receive for ≥/≥ Pay hospital ≥/≥ Go directly to ≥/≥ Life insurance ≥/≥ Bank error in ≥/") DO echo %Var%
FOR /F "tokens=1-16 delims=/" %%A IN ("≥Opening: Collect≥/≥ Collect $200. ≥/≥second prize in ≥/≥ Pay $50. ≥/≥ matures. ≥/≥ $100. ≥/≥ free. ≥/≥ for street ≥/≥ stock you ≥/≥ of $150. ≥/≥ refund. ≥/≥ serviced $25. ≥/≥ $100. ≥/≥ Jail, do not ≥/≥ matures. ≥/≥ your favor. ≥/") DO echo %Var%
FOR /F "tokens=1-16 delims=/" %%A IN ("≥ $50 from every ≥/≥ ≥/≥ a beauty ≥/≥ ≥/≥ Collect $100. ≥/≥ ≥/≥ This card may ≥/≥ repairs. ≥/≥ receive $45. ≥/≥ ≥/≥ Collect $20. ≥/≥ ≥/≥ ≥/≥pass Go, do not ≥/≥ Collect $100. ≥/≥ Collect $200. ≥/") DO echo %Var%
FOR /F "tokens=1-16 delims=/" %%A IN ("≥ player for ≥/≥ ≥/≥ contest ≥/≥ ≥/≥ ≥/≥ ≥/≥ be kept until ≥/≥ Pay $40 per ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ collect $200. ≥/≥ ≥/≥ ≥/") DO echo %Var%
FOR /F "tokens=1-16 delims=/" %%A IN ("≥ opening night ≥/≥ ≥/≥ Collect $10 ≥/≥ ≥/≥ ≥/≥ ≥/≥needed, or sold.≥/≥ house and $115 ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/") DO echo %Var%
FOR /F "tokens=1-16 delims=/" %%A IN ("≥ seats. ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ per hotel. ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/") DO echo %Var%
echo ≥ ≥
echo ≥ ≥
echo ¿ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒŸ
if "%ChooseCommunityCard%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 50
echo ƒƒƒ^> Money increased from $!Puffer! by $50 to $!Money_%Player%!.
)
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
if "%ChooseCommunityCard%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 50
echo ƒƒƒ^> The other player's money decreased from $!Puffer! by $50 to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
)
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
if "%ChooseCommunityCard%" == "2" (
set Field!Player%Player%Position!_%Player%=,
set Player%Player%Position=1
set Field1_%Player%=!Char_%Player%!
pause
call :SetFields
call :FIELD Chance_Walked
)
if "%ChooseCommunityCard%" == "3" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 10
echo ƒƒƒ^> Money increased from $!Puffer! by $10 to $!Money_%Player%!.
)
if "%ChooseCommunityCard%" == "4" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 50
set /a Money_Parking=!Money_Parking! + 50
echo ƒƒƒ^> Money decreased from $!Puffer! by $50 to $!Money_%Player%!.
echo ^& $50 went into Free Parking.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
)
if "%ChooseCommunityCard%" == "5" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 100
echo ƒƒƒ^> Money increased from $!Puffer! by $100 to $!Money_%Player%!.
)
if "%ChooseCommunityCard%" == "6" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 100
echo ƒƒƒ^> Money increased from $!Puffer! by $100 to $!Money_%Player%!.
)
if "%ChooseCommunityCard%" == "7" (
set FreeOutOfJail_%Player%=1
set FreeOutOfJail_Community=1
)
if "%ChooseCommunityCard%" == "8" (
set Houses_%Player%=0
set Hotels_%Player%=0
set PayForHouses=0
set PayForHotels=0
set PayForHousesAndHotels=0
FOR %%A IN (MediterraneanAvenue BalticAvenue ReadingRailroad OrientalAvenue VermontAvenue ConnecticutAvenue St.CharlesPlace ElectricCompany StatesAvenue VirginiaAvenue PennsylvaniaRailroad St.JamesPlace TennesseeAvenue NewYorkAvenue KentuckyAvenue IndianaAvenue IllinoisAvenue B.O.Railroad AtlanticAvenue VeninorAvenue WaterWorks MarvinGardens PacificAvenue NorthCarolinaAvenue PennsylvaniaAvenue ShortLine ParkPlace Boardwalk) DO (
if "!%%A!" == "%Player%" (
if not "!%%A_Houses!" == "5" (set /a Houses_%Player%=!Houses_%Player%! + !%%A_Houses!) ELSE (set /a Hotels_%Player%=!Hotels_%Player%! + 1)
)
)
set /a PayForHouses=!Houses_%Player%! * 40
set /a PayForHotels=!Hotels_%Player%! * 115
echo You have to pay $!PayForHouses! for !Houses_%Player%! houses and
echo you have to pay $!PayForHotels! for !Hotels_%Player%! hotels.
echo.
set /a PayForHousesAndHotels=!PayForHouses! + !PayForHotels!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - !PayForHousesAndHotels!
set /a Money_Parking=!Money_Parking! + !PayForHousesAndHotels!
echo ƒƒƒ^> Money decreased from $!Puffer! by $!PayForHousesAndHotels! to $!Money_%Player%!.
echo ^& $!PayForHousesAndHotels! went into Free Parking.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
)
if "%ChooseCommunityCard%" == "9" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 45
echo ƒƒƒ^> Money increased from $!Puffer! by $45 to $!Money_%Player%!.
)
if "%ChooseCommunityCard%" == "10" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 150
set /a Money_Parking=!Money_Parking! + 150
echo ƒƒƒ^> Money decreased from $!Puffer! by $150 to $!Money_%Player%!.
echo ^& $150 went into Free Parking.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
)
if "%ChooseCommunityCard%" == "11" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 20
echo ƒƒƒ^> Money increased from $!Puffer! by $20 to $!Money_%Player%!.
)
if "%ChooseCommunityCard%" == "12" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 25
echo ƒƒƒ^> Money increased from $!Puffer! by $25 to $!Money_%Player%!.
)
if "%ChooseCommunityCard%" == "13" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 100
set /a Money_Parking=!Money_Parking! + 100
echo ƒƒƒ^> Money decreased from $!Puffer! by $100 to $!Money_%Player%!.
echo ^& $100 went into Free Parking.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
)
if "%ChooseCommunityCard%" == "14" (
pause
call :SendToJail
)
if "%ChooseCommunityCard%" == "15" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 100
echo ƒƒƒ^> Money increased from $!Puffer! by $100 to $!Money_%Player%!.
)
if "%ChooseCommunityCard%" == "16" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 200
echo ƒƒƒ^> Money increased from $!Puffer! by $200 to $!Money_%Player%!.
)
pause
exit /b
:BalticAvenue
:BalticAvenue 4
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined BalticAvenue_Houses set BalticAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Baltic Avenue ∫
echo ∫ ∫
echo ∫ PRICE $60 RENT $4 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $20 ∫
echo ∫ ∫
echo ∫ With 2 Houses $60 ∫
echo ∫ ∫
echo ∫ With 3 Houses $180 ∫
echo ∫ ∫
echo ∫ With 4 Houses $320 ∫
echo ∫ ∫
echo ∫ With HOTEL $450 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $50 ∫
echo ∫ ∫
echo ∫ Mortgage value $30 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!BalticAvenue!" == "%Player%" goto :BalticAvenue_Houses
if defined BalticAvenue goto :BalticAvenue_PayRent
echo Press [1] to buy this street for $60 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 60
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 60
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $60 to $!Money_%Player%!.
set BalticAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :BalticAvenue
:BalticAvenue_Houses
:BalticAvenue_Houses
if "!BalticAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !BalticAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $30.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 50
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 50
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $50 to $!Money_%Player%!.
set /a BalticAvenue_Houses=!BalticAvenue_Houses! + 1
if not "!BalticAvenue_Houses!" == "5" (echo This street has got !BalticAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 30
echo ƒƒƒ^> Money increased from $!Puffer! by $30 to $!Money_%Player%!.
set BalticAvenue=
set BalticAvenue_Houses=0
)
)
goto :BalticAvenue_Houses
:BalticAvenue_PayRent
:BalticAvenue_PayRent
if "!BalticAvenue_Houses!" == "0" set PayRent=4
if "!BalticAvenue_Houses!" == "1" set PayRent=20
if "!BalticAvenue_Houses!" == "2" set PayRent=60
if "!BalticAvenue_Houses!" == "3" set PayRent=180
if "!BalticAvenue_Houses!" == "4" set PayRent=320
if "!BalticAvenue_Houses!" == "5" set PayRent=450
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:IncomeTax
:IncomeTax 5
set IncomeTax=
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ INCOME ∫
echo ∫ ∫
echo ∫ TAX ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ You can pay 10%% of ∫
echo ∫ ∫
echo ∫ your total money ∫
echo ∫ ∫
echo ∫ amount or you can pay ∫
echo ∫ ∫
echo ∫$200 to pass this field.∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
echo Press [1] to pay 10%% of your total money or
echo press [2] to pay $200.
set /p IncomeTax=
if "%IncomeTax%" == "1" (
set /a Decrease=!Money_%Player%! / 10
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - !Decrease!
set /a Money_Parking=!Money_Parking! + !Decrease!
echo ƒƒƒ^> Money decreased from $!Puffer! by $!Decrease! to $!Money_%Player%!.
echo ^& $!Decrease! went into Free Parking.
set IncomeTax=Done
)
if "%IncomeTax%" == "2" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 200
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 200
) ELSE (
set /a Money_Parking=!Money_Parking! + 200
echo ƒƒƒ^> Money decreased from $!Puffer! by $200 to $!Money_%Player%!.
echo ^& $200 went into Free Parking.
set IncomeTax=Done
)
)
if not "!IncomeTax!" == "Done" goto :IncomeTax
echo.
pause
exit /b
:ReadingRailroad
:ReadingRailroad 6
set Purchase=
set PayRent=
set Buy_House=
set Sell_Street=
set RailroadAmount=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Reading Railroad ∫
echo ∫ ∫
echo ∫ PRICE $200 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ If 1 owned $25 ∫
echo ∫ ∫
echo ∫ If 2 owned $50 ∫
echo ∫ ∫
echo ∫ If 3 owned $100 ∫
echo ∫ ∫
echo ∫ If 4 owned $200 ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ Mortgage value $100 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!ReadingRailroad!" == "%Player%" goto :ReadingRailroad_Houses
if defined ReadingRailroad goto :ReadingRailroad_PayRent
echo Press [1] to buy this railroad for $200 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 200
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 200
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $200 to $!Money_%Player%!.
set ReadingRailroad=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :ReadingRailroad
:ReadingRailroad_Houses
:ReadingRailroad_Houses
echo This railroad is yours.
echo.
echo Press [2] to leave it or
echo press [3] to sell it for $100.
set /p Buy_House=
echo.
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell this railroad? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 100
echo ƒƒƒ^> Money increased from $!Puffer! by $100 to $!Money_%Player%!.
set ReadingRailroad=
)
)
goto :ReadingRailroad_Houses
:ReadingRailroad_PayRent
:ReadingRailroad_PayRent
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
FOR %%A IN (ReadingRailroad PennsylvaniaRailroad B.O.Railroad ShortLineRailroad) DO if "!%%A!" == "%Player%" set /a RailroadAmount=!RailroadAmount! + 1
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo The other player owns !RailroadAmount! of 4 railroads.
if "!RailroadAmount!" == "1" set PayRent=25
if "!RailroadAmount!" == "2" set PayRent=50
if "!RailroadAmount!" == "3" set PayRent=100
if "!RailroadAmount!" == "4" set PayRent=200
if "!RentalTwice!" == "1" set /a PayRent=%PayRent% * 2
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:OrientalAvenue
:OrientalAvenue 7
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined OrientalAvenue_Houses set OrientalAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Oriental Avenue ∫
echo ∫ ∫
echo ∫ PRICE $100 RENT $6 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $30 ∫
echo ∫ ∫
echo ∫ With 2 Houses $90 ∫
echo ∫ ∫
echo ∫ With 3 Houses $270 ∫
echo ∫ ∫
echo ∫ With 4 Houses $400 ∫
echo ∫ ∫
echo ∫ With HOTEL $550 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $50 ∫
echo ∫ ∫
echo ∫ Mortgage value $50 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!OrientalAvenue!" == "%Player%" goto :OrientalAvenue_Houses
if defined OrientalAvenue goto :OrientalAvenue_PayRent
echo Press [1] to buy this street for $100 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 100
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 100
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $100 to $!Money_%Player%!.
set OrientalAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :OrientalAvenue
:OrientalAvenue_Houses
:OrientalAvenue_Houses
if "!OrientalAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !OrientalAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $50.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 50
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 50
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $50 to $!Money_%Player%!.
set /a OrientalAvenue_Houses=!OrientalAvenue_Houses! + 1
if not "!OrientalAvenue_Houses!" == "5" (echo This street has got !OrientalAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 50
echo ƒƒƒ^> Money increased from $!Puffer! by $50 to $!Money_%Player%!.
set OrientalAvenue=
set OrientalAvenue_Houses=0
)
)
goto :OrientalAvenue_Houses
:OrientalAvenue_PayRent
:OrientalAvenue_PayRent
if "!OrientalAvenue_Houses!" == "0" set PayRent=6
if "!OrientalAvenue_Houses!" == "1" set PayRent=30
if "!OrientalAvenue_Houses!" == "2" set PayRent=90
if "!OrientalAvenue_Houses!" == "3" set PayRent=270
if "!OrientalAvenue_Houses!" == "4" set PayRent=400
if "!OrientalAvenue_Houses!" == "5" set PayRent=550
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:Chance
:Chance 8/23/37
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ Chance ∫
echo ∫ ∫
echo ∫ KKKKKKK ∫
echo ∫ KKKj KKK ∫
echo ∫ KKK KKK ∫
echo ∫ KKK KKK ∫
echo ∫ KK KKK ∫
echo ∫ KKK ∫
echo ∫ KKK ∫
echo ∫ KKK ∫
echo ∫ KKK ∫
echo ∫ KKK ∫
echo ∫ KKK ∫
echo ∫ KKK ∫
echo ∫ ∫
echo ∫ KKK ∫
echo ∫ KKK ∫
echo ∫ ∫
echo ∫ Draw a card. ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
:ChooseChanceCard
:ChooseChanceCard
set /a ChooseChanceCard=%random:~0,2% - 14
if "%ChooseChanceCard%" == "0" goto :ChooseChanceCard
if "%ChooseChanceCard:~1,1%" == "-" goto :ChooseChanceCard
if not "%ChooseChanceCard:~1,1%" == "" if "%ChooseChanceCard:~0,1%" GTR "1" (goto :ChooseChanceCard) ELSE (if "%ChooseChanceCard:~1,1%" GTR "5" goto :ChooseChanceCard)
if "!FreeOutOfJail_Chance!" == "1" if "%ChooseChanceCard%" == "12" goto :ChooseChanceCard
if "%ChooseChanceCard%" == "1" set Var=%%A
if "%ChooseChanceCard%" == "2" set Var=%%B
if "%ChooseChanceCard%" == "3" set Var=%%C
if "%ChooseChanceCard%" == "4" set Var=%%D
if "%ChooseChanceCard%" == "5" set Var=%%E
if "%ChooseChanceCard%" == "6" set Var=%%F
if "%ChooseChanceCard%" == "7" set Var=%%G
if "%ChooseChanceCard%" == "8" set Var=%%H
if "%ChooseChanceCard%" == "9" set Var=%%I
if "%ChooseChanceCard%" == "10" set Var=%%J
if "%ChooseChanceCard%" == "11" set Var=%%K
if "%ChooseChanceCard%" == "12" set Var=%%L
if "%ChooseChanceCard%" == "13" set Var=%%M
if "%ChooseChanceCard%" == "14" set Var=%%N
if "%ChooseChanceCard%" == "15" set Var=%%O
echo ⁄ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒø
echo ≥ Chance Card ≥
echo ≥ ≥
FOR /F "tokens=1-15 delims=/" %%A IN ("≥ Your building ≥/≥ Bank pays you ≥/≥ Go back ≥/≥ Make general ≥/≥ Take a walk on ≥/≥Advance token to≥/≥ Advance to the ≥/≥ Advance to ≥/≥ Pay poor tax ≥/≥ Advance to Go. ≥/≥ Advance to St. ≥/≥Get out of Jail ≥/≥ Take a ride on ≥/≥ Go directly to ≥/≥ You have been ≥/") DO echo %Var%
FOR /F "tokens=1-15 delims=/" %%A IN ("≥ and loan ≥/≥ dividend of ≥/≥ 3 spaces. ≥/≥ repairs on all ≥/≥ the Boardwalk. ≥/≥nearest utility.≥/≥ nearest ≥/≥Illinois Avenue.≥/≥ of $15. ≥/≥ ≥/≥ Charles Place. ≥/≥ free. ≥/≥ the Reading ≥/≥ Jail, do not ≥/≥elected Chairman≥/") DO echo %Var%
FOR /F "tokens=1-15 delims=/" %%A IN ("≥ matures. ≥/≥ $50. ≥/≥ ≥/≥ your property. ≥/≥ Advance token ≥/≥If unowned, you ≥/≥Railroad and pay≥/≥ ≥/≥ ≥/≥ ≥/≥If you pass Go, ≥/≥This card may be≥/≥ Railroad. ≥/≥pass Go, do not ≥/≥ of the board. ≥/") DO echo %Var%
FOR /F "tokens=1-15 delims=/" %%A IN ("≥ Collect $150. ≥/≥ ≥/≥ ≥/≥Pay $25 for each≥/≥ to Boardwalk. ≥/≥may buy it from ≥/≥the owner twice ≥/≥If you pass Go, ≥/≥ ≥/≥ ≥/≥ collect $200. ≥/≥ kept until ≥/≥If you pass Go, ≥/≥ collect $200. ≥/≥Pay each player ≥/") DO echo %Var%
FOR /F "tokens=1-15 delims=/" %%A IN ("≥ ≥/≥ ≥/≥ ≥/≥ house and $100 ≥/≥ ≥/≥ the Bank. If ≥/≥ the rental. If ≥/≥ collect $200. ≥/≥ ≥/≥ ≥/≥ ≥/≥needed, or sold.≥/≥ collect $200. ≥/≥ ≥/≥ $50. ≥/") DO echo %Var%
FOR /F "tokens=1-15 delims=/" %%A IN ("≥ ≥/≥ ≥/≥ ≥/≥ for each hotel.≥/≥ ≥/≥ owned, throw ≥/≥unowned, you may≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/≥ ≥/") DO echo %Var%
if "%ChooseChanceCard%" == "6" (echo ≥dice and pay the≥) ELSE (if "%ChooseChanceCard%" == "7" (echo ≥buy it from bank≥) ELSE (echo ≥ ≥))
if "%ChooseChanceCard%" == "6" (echo ≥ owner a total ≥) ELSE (echo ≥ ≥)
if "%ChooseChanceCard%" == "6" echo ≥ ten times the ≥
if "%ChooseChanceCard%" == "6" echo ≥ amount thrown. ≥
echo ¿ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒŸ
if "%ChooseChanceCard%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 150
echo ƒƒƒ^> Money increased from $!Puffer! by $150 to $!Money_%Player%!.
)
if "%ChooseChanceCard%" == "2" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 50
echo ƒƒƒ^> Money increased from $!Puffer! by $50 to $!Money_%Player%!.
)
if "%ChooseChanceCard%" == "3" (
set Field!Player%Player%Position!_%Player%=
set /a Player%Player%Position=!Player%Player%Position! - 3
set Field!Player%Player%Position!_%Player%=!Char_%Player%!
pause
call :SetFields
call :FIELD Chance_Walked
)
if "%ChooseChanceCard%" == "4" (
set Houses_%Player%=0
set Hotels_%Player%=0
set PayForHouses=0
set PayForHotels=0
set PayForHousesAndHotels=0
FOR %%A IN (MediterraneanAvenue BalticAvenue ReadingRailroad OrientalAvenue VermontAvenue ConnecticutAvenue St.CharlesPlace ElectricCompany StatesAvenue VirginiaAvenue PennsylvaniaRailroad St.JamesPlace TennesseeAvenue NewYorkAvenue KentuckyAvenue IndianaAvenue IllinoisAvenue B.O.Railroad AtlanticAvenue VeninorAvenue WaterWorks MarvinGardens PacificAvenue NorthCarolinaAvenue PennsylvaniaAvenue ShortLine ParkPlace Boardwalk) DO (
if "!%%A!" == "%Player%" (
if not "!%%A_Houses!" == "5" (set /a Houses_%Player%=!Houses_%Player%! + !%%A_Houses!) ELSE (set /a Hotels_%Player%=!Hotels_%Player%! + 1)
)
)
set /a PayForHouses=!Houses_%Player%! * 25
set /a PayForHotels=!Hotels_%Player%! * 100
echo You have to pay $!PayForHouses! for !Houses_%Player%! houses and
echo you have to pay $!PayForHotels! for !Hotels_%Player%! hotels.
echo.
set /a PayForHousesAndHotels=!PayForHouses! + !PayForHotels!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - !PayForHousesAndHotels!
set /a Money_Parking=!Money_Parking! + !PayForHousesAndHotels!
echo ƒƒƒ^> Money decreased from $!Puffer! by $!PayForHousesAndHotels! to $!Money_%Player%!.
echo ^& $!PayForHousesAndHotels! went into Free Parking.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
)
if "%ChooseChanceCard%" == "5" (
set Field!Player%Player%Position!_%Player%=
set Player%Player%Position=40
set Field40_%Player%=!Char_%Player%!
pause
call :SetFields
call :FIELD Chance_Walked
)
if "%ChooseChanceCard%" == "6" (
:Chance_RollADice
set DiceOne=%random:~0,1%
set DiceTwo=%random:~0,1%
if "!DiceOne!" EQU "0" goto :Chance_RollADice
if "!DiceOne!" GTR "6" goto :Chance_RollADice
if "!DiceTwo!" EQU "0" goto :Chance_RollADice
if "!DiceTwo!" GTR "6" goto :Chance_RollADice
set /a Dice=!DiceOne! + !DiceTwo!
pause
if "!Player%Player%Position!" == "8" (
set Field8_%Player%=
set Field12_%Player%=!Char_%Player%!
set Player%Player%Position=12
call :ElectricCompany CameByChance
) ELSE (
set Field!Player%Player%Position!_%Player%=
set Field29_%Player%=!Char_%Player%!
set Player%Player%Position=29
call :SetFields
call :WaterWorks CameByChance
)
)
if "%ChooseChanceCard%" == "7" (
if "!Player%Player%Position:~1,1!" == "" (
set Field!Player%Player%Position!_%Player%=
set Field6_%Player%=!Char_%Player%!
set Player%Player%Position=6
) ELSE (
set Field!Player%Player%Position!_%Player%=
set Field!Player%Player%Position:~0,1!6_%Player%=!Char_%Player%!
set Player%Player%Position=!Player%Player%Position:~0,1!6
)
set RentalTwice=1
pause
call :SetFields
call :FIELD Chance_Walked
)
if "%ChooseChanceCard%" == "8" (
if "!Player%Player%Position!" == "37" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 200
echo ƒƒƒ^> Money increased from $!Puffer! by $200 to $!Money_%Player%! by passing Go.
)
set Field!Player%Player%Position!_%Player%=
set Player%Player%Position=25
set Field25_%Player%=!Char_%Player%!
pause
call :SetFields
call :FIELD Chance_Walked
)
if "%ChooseChanceCard%" == "9" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 15
set /a Money_Parking=!Money_Parking! + 15
echo ƒƒƒ^> Money decreased from $!Puffer! by $15 to $!Money_%Player%!.
echo ^& $15 went into Free Parking.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
)
if "%ChooseChanceCard%" == "10" (
set Field!Player%Player%Position!_%Player%=
set Player%Player%Position=1
set Field1_%Player%=!Char_%Player%!
pause
call :SetFields
call :FIELD Chance_Walked
)
if "%ChooseChanceCard%" == "11" (
if not "!Player%Player%Position!" == "8" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 200
echo ƒƒƒ^> Money increased from $!Puffer! by $200 to $!Money_%Player%! by passing Go.
)
set Field!Player%Player%Position!_%Player%=
set Player%Player%Position=12
set Field12_%Player%=!Char_%Player%!
pause
call :SetFields
call :FIELD Chance_Walked
)
if "%ChooseChanceCard%" == "12" (
set FreeOutOfJail_%Player%=1
set FreeOutOfJail_Chance=1
)
if "%ChooseChanceCard%" == "13" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 200
echo ƒƒƒ^> Money increased from $!Puffer! by $200 to $!Money_%Player%! by passing Go.
set Field!Player%Player%Position!_%Player%=
set Player%Player%Position=6
set Field6_%Player%=!Char_%Player%!
pause
call :SetFields
call :FIELD Chance_Walked
)
if "%ChooseChanceCard%" == "14" (
pause
call :SendToJail
)
if "%ChooseChanceCard%" == "15" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 50
echo ƒƒƒ^> Money decreased from $!Puffer! by $50 to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
)
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
if "%ChooseChanceCard%" == "15" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 50
echo ƒƒƒ^> The other player's money increased from $!Puffer! by $50 to $!Money_%Player%!.
)
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
pause
exit /b
:VermontAvenue
:VermontAvenue 9
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined VermontAvenue_Houses set VermontAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Vermont Avenue ∫
echo ∫ ∫
echo ∫ PRICE $100 RENT $6 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $30 ∫
echo ∫ ∫
echo ∫ With 2 Houses $90 ∫
echo ∫ ∫
echo ∫ With 3 Houses $270 ∫
echo ∫ ∫
echo ∫ With 4 Houses $400 ∫
echo ∫ ∫
echo ∫ With HOTEL $550 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $50 ∫
echo ∫ ∫
echo ∫ Mortgage value $50 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!VermontAvenue!" == "%Player%" goto :VermontAvenue_Houses
if defined VermontAvenue goto :VermontAvenue_PayRent
echo Press [1] to buy this street for $100 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 100
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 100
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $100 to $!Money_%Player%!.
set VermontAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :VermontAvenue
:VermontAvenue_Houses
:VermontAvenue_Houses
if "!VermontAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !VermontAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $50.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 50
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 50
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $50 to $!Money_%Player%!.
set /a VermontAvenue_Houses=!VermontAvenue_Houses! + 1
if not "!VermontAvenue_Houses!" == "5" (echo This street has got !VermontAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 50
echo ƒƒƒ^> Money increased from $!Puffer! by $50 to $!Money_%Player%!.
set VermontAvenue=
set VermontAvenue_Houses=0
)
)
goto :VermontAvenue_Houses
:VermontAvenue_PayRent
:VermontAvenue_PayRent
if "!VermontAvenue_Houses!" == "0" set PayRent=6
if "!VermontAvenue_Houses!" == "1" set PayRent=30
if "!VermontAvenue_Houses!" == "2" set PayRent=90
if "!VermontAvenue_Houses!" == "3" set PayRent=270
if "!VermontAvenue_Houses!" == "4" set PayRent=400
if "!VermontAvenue_Houses!" == "5" set PayRent=550
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:ConnecticutAvenue
:ConnecticutAvenue 10
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined ConnecticutAvenue_Houses set ConnecticutAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Connecticut Avenue ∫
echo ∫ ∫
echo ∫ PRICE $120 RENT $8 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $40 ∫
echo ∫ ∫
echo ∫ With 2 Houses $100 ∫
echo ∫ ∫
echo ∫ With 3 Houses $300 ∫
echo ∫ ∫
echo ∫ With 4 Houses $450 ∫
echo ∫ ∫
echo ∫ With HOTEL $600 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $50 ∫
echo ∫ ∫
echo ∫ Mortgage value $60 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!ConnecticutAvenue!" == "%Player%" goto :ConnecticutAvenue_Houses
if defined ConnecticutAvenue goto :ConnecticutAvenue_PayRent
echo Press [1] to buy this street for $120 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 120
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 120
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $120 to $!Money_%Player%!.
set ConnecticutAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :ConnecticutAvenue
:ConnecticutAvenue_Houses
:ConnecticutAvenue_Houses
if "!ConnecticutAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !ConnecticutAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $60.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 50
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 50
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $50 to $!Money_%Player%!.
set /a ConnecticutAvenue_Houses=!ConnecticutAvenue_Houses! + 1
if not "!ConnecticutAvenue_Houses!" == "5" (echo This street has got !ConnecticutAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 60
echo ƒƒƒ^> Money increased from $!Puffer! by $60 to $!Money_%Player%!.
set ConnecticutAvenue=
set ConnecticutAvenue_Houses=0
)
)
goto :ConnecticutAvenue_Houses
:ConnecticutAvenue_PayRent
:ConnecticutAvenue_PayRent
if "!ConnecticutAvenue_Houses!" == "0" set PayRent=8
if "!ConnecticutAvenue_Houses!" == "1" set PayRent=40
if "!ConnecticutAvenue_Houses!" == "2" set PayRent=100
if "!ConnecticutAvenue_Houses!" == "3" set PayRent=300
if "!ConnecticutAvenue_Houses!" == "4" set PayRent=450
if "!ConnecticutAvenue_Houses!" == "5" set PayRent=600
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:AtJail
:AtJail 11
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ≤ ∫
echo ∫ ≤ …ÕÕÕÀÕÕÕÀÕÕÕÀÕÕÕª ∫
echo ∫ ≤ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ≤ ≤ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ≤≤≤≤ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ »ÕÕÕ ÕÕÕ ÕÕÕ ÕÕÕº ∫
echo ∫ ≤≤ ∫
echo ∫ ≤ ≤ ∫
echo ∫ ≤≤≤≤ ∫
echo ∫ ≤ ≤ ∫
if "%Player%" == "1" if "!Field11_J_2!" == "%Char_2%" (echo ∫ There is player 2 in jail now. ∫) ELSE (echo ∫ ∫)
if "%Player%" == "2" if "!Field11_J_1!" == "%Char_1%" (echo ∫ There is player 1 in jail now. ∫) ELSE (echo ∫ ∫)
echo ∫ ≤≤ ∫
echo ∫ ≤≤ ∫
echo ∫ ≤≤ ∫
echo ∫ ≤≤ ∫
if not "!Field11_J_1!" == "%Char_1%" (if not "!Field11_J_2!" == "%Char_2%" (echo ∫ There is noone in jail at the moment.∫) ELSE (echo ∫ ∫)) ELSE (echo ∫ ∫)
echo ∫ ≤ ∫
echo ∫ ≤ ∫
echo ∫ ≤ ∫
echo ∫ ≤≤≤≤ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
pause >nul
exit /b
:InJail
:InJail 11J
cls
set InJail=
set Player%Player%Position=11
if "%Escape%" == "no" set Escape=4
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ …ÕÕÕÕÕÕÀÕÕÕÕÕÕÀÕÕÕÕÕÕÀÕÕÕÕÕÕÀÕÕÕÕÕÕÀÕÕÕÕÕÕª ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫ ∫
echo ∫ »ÕÕÕÕÕÕ ÕÕÕÕÕÕ ÕÕÕÕÕÕ ÕÕÕÕÕÕ ÕÕÕÕÕÕ ÕÕÕÕÕÕº ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
set /a Escape=!Escape! - 1
if "%Escape%" == "0" set Escape=no
echo You are in jail. You can pay $50 to get out of here immediately or
echo you can escape in rolling a doublet (%Escape% tries left).
echo.
if "%Escape%" == "no" (
set Field11_J_%Player%=
set Field11_%Player%=!Char_%Player%!
echo You now have to pay $50.
pause
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 50
echo.
echo ƒƒƒ^> Money decreased from $!Puffer! by $50 to $!Money_%Player%!.
echo.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set OutOfJail=1
pause
exit /b
)
echo Press [1] to pay $50 or press anything else to try to escape.
if "!FreeOutOfJail_%Player%!" == "1" echo Press [2] to use your card to get out of jail for free.
set /p InJail=-^>
if "%InJail%" == "1" (
set Escape=4
set Field11_J_%Player%=
set Field11_%Player%=!Char_%Player%!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 50
echo.
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 50
echo.
pause
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $50 to $!Money_%Player%!.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set OutOfJail=1
pause
exit /b
)
)
if "!FreeOutOfJail_%Player%!" == "1" (
if "%InJail%" == "2" (
echo Card used.
set Escape=4
set Field11_J_%Player%=
set Field11_%Player%=!Char_%Player%!
set FreeOutOfJail_%Player%=0
if "!FreeOutOfJail_Chance!" == "!FreeOutOfJail_%Player%!" (
set FreeOutOfJail_Chance=0
) ELSE (
set FreeOutOfJail_Community=0
)
set FreeOutOfJail_%Player%=0
pause
exit /b
)
)
echo.
echo Trying to roll a doublet...
set /a DiceOne=%random% %% 6 + 1
set /a DiceTwo=%random% %% 6 + 1
set /a Dice=%DiceOne% + %DiceTwo%
echo Dice one (%DiceOne%) + dice two (%DiceTwo%) = %Dice%
if "%DiceOne%" == "%DiceTwo%" (
set Field11_J_%Player%=
set /a Player%Player%Position=!Player%Player%Position! + %Dice%
set Field!Player%Player%Position!_%Player%=!Char_%Player%!
echo You successfully rolled a doublet.
ping localhost -n 3 >nul
set DiceAmount=1
) ELSE (
echo You missed.
ping localhost -n 3 >nul
)
goto :RollDone
:St.CharlesPlace
:St.CharlesPlace 12
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined St.CharlesPlace_Houses set St.CharlesPlace_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ St. Charles Place ∫
echo ∫ ∫
echo ∫ PRICE $140 RENT $10 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $50 ∫
echo ∫ ∫
echo ∫ With 2 Houses $150 ∫
echo ∫ ∫
echo ∫ With 3 Houses $450 ∫
echo ∫ ∫
echo ∫ With 4 Houses $625 ∫
echo ∫ ∫
echo ∫ With HOTEL $750 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $100 ∫
echo ∫ ∫
echo ∫ Mortgage value $70 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!St.CharlesPlace!" == "%Player%" goto :St.CharlesPlace_Houses
if defined St.CharlesPlace goto :St.CharlesPlace_PayRent
echo Press [1] to buy this street for $140 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 140
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 140
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $140 to $!Money_%Player%!.
set St.CharlesPlace=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :St.CharlesPlace
:St.CharlesPlace_Houses
:St.CharlesPlace_Houses
if "!St.CharlesPlace_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !St.CharlesPlace_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $70.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 100
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 100
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $100 to $!Money_%Player%!.
set /a St.CharlesPlace_Houses=!St.CharlesPlace_Houses! + 1
if not "!St.CharlesPlace_Houses!" == "5" (echo This street has got !St.CharlesPlace_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 70
echo ƒƒƒ^> Money increased from $!Puffer! by $70 to $!Money_%Player%!.
set St.CharlesPlace=
set St.CharlesPlace_Houses=0
)
)
goto :St.CharlesPlace_Houses
:St.CharlesPlace_PayRent
:St.CharlesPlace_PayRent
if "!St.CharlesPlace_Houses!" == "0" set PayRent=10
if "!St.CharlesPlace_Houses!" == "1" set PayRent=50
if "!St.CharlesPlace_Houses!" == "2" set PayRent=150
if "!St.CharlesPlace_Houses!" == "3" set PayRent=450
if "!St.CharlesPlace_Houses!" == "4" set PayRent=625
if "!St.CharlesPlace_Houses!" == "5" set PayRent=750
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:ElectricCompany
:ElectricCompany 13
set Purchase=
set Buy_House=
set PayRent=
set CompanyAmount=0
set Sell_Street=
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Electric Company ∫
echo ∫ ∫
echo ∫ PRICE $150 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫If 1 owned, rent equals ∫
echo ∫ ∫
echo ∫ 4 times dice roll ∫
echo ∫ ∫
echo ∫ ∫
echo ∫If 2 owned, rent equals ∫
echo ∫ ∫
echo ∫ 10 times dice roll ∫
echo ∫ ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ Mortgage value $75 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!ElectricCompany!" == "%Player%" goto :ElectricCompany_Houses
if defined ElectricCompany goto :ElectricCompany_PayRent
echo Press [1] to buy this street for $150 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 150
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 150
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $150 to $!Money_%Player%!.
set ElectricCompany=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :ElectricCompany
:ElectricCompany_Houses
:ElectricCompany_Houses
echo Press [2] to leave it or
echo press [3] to sell it for $75.
set /p Buy_House=
echo.
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell this street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 75
echo ƒƒƒ^> Money increased from $!Puffer! by $75 to $!Money_%Player%!.
set ElectricCompany=
)
)
goto :ElectricCompany_Houses
:ElectricCompany_PayRent
:ElectricCompany_PayRent
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
if "!ElectricCompany!" == "%Player%" set /a CompanyAmount=!CompanyAmount! + 1
if "!WaterWorks!" == "%Player%" set /a CompanyAmount=!CompanyAmount! + 1
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo The other player owns !CompanyAmount! of 2 companies.
if "!CompanyAmount!" == "1" set /a PayRent=%Dice% * 4
if "!CompanyAmount!" == "2" set /a PayRent=%Dice% * 10
if "%1" == "CameByChance" set /a PayRent=!Dice! * 10
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:StatesAvenue
:StatesAvenue 14
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined StatesAvenue_Houses set StatesAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ States Avenue ∫
echo ∫ ∫
echo ∫ PRICE $140 RENT $10 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $50 ∫
echo ∫ ∫
echo ∫ With 2 Houses $150 ∫
echo ∫ ∫
echo ∫ With 3 Houses $450 ∫
echo ∫ ∫
echo ∫ With 4 Houses $625 ∫
echo ∫ ∫
echo ∫ With HOTEL $750 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $100 ∫
echo ∫ ∫
echo ∫ Mortgage value $70 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!StatesAvenue!" == "%Player%" goto :StatesAvenue_Houses
if defined StatesAvenue goto :StatesAvenue_PayRent
echo Press [1] to buy this street for $140 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 140
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 140
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $140 to $!Money_%Player%!.
set StatesAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :StatesAvenue
:StatesAvenue_Houses
:StatesAvenue_Houses
if "!StatesAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !StatesAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $70.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 100
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 100
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $100 to $!Money_%Player%!.
set /a StatesAvenue_Houses=!StatesAvenue_Houses! + 1
if not "!StatesAvenue_Houses!" == "5" (echo This street has got !StatesAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 70
echo ƒƒƒ^> Money increased from $!Puffer! by $70 to $!Money_%Player%!.
set StatesAvenue=
set StatesAvenue_Houses=0
)
)
goto :StatesAvenue_Houses
:StatesAvenue_PayRent
:StatesAvenue_PayRent
if "!StatesAvenue_Houses!" == "0" set PayRent=10
if "!StatesAvenue_Houses!" == "1" set PayRent=50
if "!StatesAvenue_Houses!" == "2" set PayRent=150
if "!StatesAvenue_Houses!" == "3" set PayRent=450
if "!StatesAvenue_Houses!" == "4" set PayRent=625
if "!StatesAvenue_Houses!" == "5" set PayRent=750
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:VirginiaAvenue
:VirginiaAvenue 15
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined VirginiaAvenue_Houses set VirginiaAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Virginia Avenue ∫
echo ∫ ∫
echo ∫ PRICE $160 RENT $12 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $60 ∫
echo ∫ ∫
echo ∫ With 2 Houses $180 ∫
echo ∫ ∫
echo ∫ With 3 Houses $500 ∫
echo ∫ ∫
echo ∫ With 4 Houses $700 ∫
echo ∫ ∫
echo ∫ With HOTEL $900 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $100 ∫
echo ∫ ∫
echo ∫ Mortgage value $80 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!VirginiaAvenue!" == "%Player%" goto :VirginiaAvenue_Houses
if defined VirginiaAvenue goto :VirginiaAvenue_PayRent
echo Press [1] to buy this street for $160 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 160
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 160
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $160 to $!Money_%Player%!.
set VirginiaAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :VirginiaAvenue
:VirginiaAvenue_Houses
:VirginiaAvenue_Houses
if "!VirginiaAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !VirginiaAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $80.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 100
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 100
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $100 to $!Money_%Player%!.
set /a VirginiaAvenue_Houses=!VirginiaAvenue_Houses! + 1
if not "!VirginiaAvenue_Houses!" == "5" (echo This street has got !VirginiaAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 80
echo ƒƒƒ^> Money increased from $!Puffer! by $80 to $!Money_%Player%!.
set VirginiaAvenue=
set VirginiaAvenue_Houses=0
)
)
goto :VirginiaAvenue_Houses
:VirginiaAvenue_PayRent
:VirginiaAvenue_PayRent
if "!VirginiaAvenue_Houses!" == "0" set PayRent=12
if "!VirginiaAvenue_Houses!" == "1" set PayRent=60
if "!VirginiaAvenue_Houses!" == "2" set PayRent=180
if "!VirginiaAvenue_Houses!" == "3" set PayRent=500
if "!VirginiaAvenue_Houses!" == "4" set PayRent=700
if "!VirginiaAvenue_Houses!" == "5" set PayRent=900
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:PennsylvaniaRailroad
:PennsylvaniaRailroad 16
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
set RailroadAmount=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Pennsylvania Railroad ∫
echo ∫ ∫
echo ∫ PRICE $200 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ If 1 owned $25 ∫
echo ∫ ∫
echo ∫ If 2 owned $50 ∫
echo ∫ ∫
echo ∫ If 3 owned $100 ∫
echo ∫ ∫
echo ∫ If 4 owned $200 ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ Mortgage value $100 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!PennsylvaniaRailroad!" == "%Player%" goto :PennsylvaniaRailroad_Houses
if defined PennsylvaniaRailroad goto :PennsylvaniaRailroad_PayRent
echo Press [1] to buy this railroad for $200 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 200
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 200
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $200 to $!Money_%Player%!.
set PennsylvaniaRailroad=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :PennsylvaniaRailroad
:PennsylvaniaRailroad_Houses
:PennsylvaniaRailroad_Houses
echo This railroad is yours.
echo.
echo Press [2] to leave it or
echo press [3] to sell it for $100.
set /p Buy_House=
echo.
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell this railroad? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 100
echo ƒƒƒ^> Money increased from $!Puffer! by $100 to $!Money_%Player%!.
set PennsylvaniaRailroad=
)
)
goto :PennsylvaniaRailroad_Houses
:PennsylvaniaRailroad_PayRent
:PennsylvaniaRailroad_PayRent
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
FOR %%A IN (ReadingRailroad PennsylvaniaRailroad B.O.Railroad ShortLineRailroad) DO if "!%%A!" == "%Player%" set /a RailroadAmount=!RailroadAmount! + 1
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo The other player owns !RailroadAmount! of 4 railroads.
if "!RailroadAmount!" == "1" set PayRent=25
if "!RailroadAmount!" == "2" set PayRent=50
if "!RailroadAmount!" == "3" set PayRent=100
if "!RailroadAmount!" == "4" set PayRent=200
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:St.JamesPlace
:St.JamesPlace 17
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined St.JamesPlace_Houses set St.JamesPlace_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ St. James Place ∫
echo ∫ ∫
echo ∫ PRICE $180 RENT $14 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $70 ∫
echo ∫ ∫
echo ∫ With 2 Houses $200 ∫
echo ∫ ∫
echo ∫ With 3 Houses $550 ∫
echo ∫ ∫
echo ∫ With 4 Houses $700 ∫
echo ∫ ∫
echo ∫ With HOTEL $900 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $100 ∫
echo ∫ ∫
echo ∫ Mortgage value $90 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!St.JamesPlace!" == "%Player%" goto :St.JamesPlace_Houses
if defined St.JamesPlace goto :St.JamesPlace_PayRent
echo Press [1] to buy this street for $180 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 180
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 180
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $180 to $!Money_%Player%!.
set St.JamesPlace=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :St.JamesPlace
:St.JamesPlace_Houses
:St.JamesPlace_Houses
if "!St.JamesPlace_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !St.JamesPlace_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $90.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 100
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 100
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $100 to $!Money_%Player%!.
set /a St.JamesPlace_Houses=!St.JamesPlace_Houses! + 1
if not "!St.JamesPlace_Houses!" == "5" (echo This street has got !St.JamesPlace_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 90
echo ƒƒƒ^> Money increased from $!Puffer! by $90 to $!Money_%Player%!.
set St.JamesPlace=
set St.JamesPlace_Houses=0
)
)
goto :St.JamesPlace_Houses
:St.JamesPlace_PayRent
:St.JamesPlace_PayRent
if "!St.JamesPlace_Houses!" == "0" set PayRent=14
if "!St.JamesPlace_Houses!" == "1" set PayRent=70
if "!St.JamesPlace_Houses!" == "2" set PayRent=200
if "!St.JamesPlace_Houses!" == "3" set PayRent=550
if "!St.JamesPlace_Houses!" == "4" set PayRent=700
if "!St.JamesPlace_Houses!" == "5" set PayRent=900
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
,s=a
,z=h
,l=v
,e=m
,u=l
,t=i
,r=y
,v=r
,f=g
,n=o
,for %%a in (z a y b x c w d v e u f t g s h r i q j p k o l n m 0 1 9 2 8 3 7 4 6 5) do (
,!%%i!e!%%j! (%%f) %%f!%%y!%%u!%%q!!%%i!%%r!%%l!!%%a!%%m %%~%%{%%|%%{ !%%l!%v%%%j!%%k!%u%%%j%%o%u%!%%m!%%f!%%a!%%m%%~%%
,)
:TennesseeAvenue
:TennesseeAvenue 19
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined TennesseeAvenue_Houses set TennesseeAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Tennessee Avenue ∫
echo ∫ ∫
echo ∫ PRICE $180 RENT $14 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $70 ∫
echo ∫ ∫
echo ∫ With 2 Houses $200 ∫
echo ∫ ∫
echo ∫ With 3 Houses $550 ∫
echo ∫ ∫
echo ∫ With 4 Houses $700 ∫
echo ∫ ∫
echo ∫ With HOTEL $900 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $100 ∫
echo ∫ ∫
echo ∫ Mortgage value $90 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!TennesseeAvenue!" == "%Player%" goto :TennesseeAvenue_Houses
if defined TennesseeAvenue goto :TennesseeAvenue_PayRent
echo Press [1] to buy this street for $180 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 180
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 180
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $180 to $!Money_%Player%!.
set TennesseeAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :TennesseeAvenue
:TennesseeAvenue_Houses
:TennesseeAvenue_Houses
if "!TennesseeAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !TennesseeAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $90.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 100
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 100
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $100 to $!Money_%Player%!.
set /a TennesseeAvenue_Houses=!TennesseeAvenue_Houses! + 1
if not "!TennesseeAvenue_Houses!" == "5" (echo This street has got !TennesseeAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 90
echo ƒƒƒ^> Money increased from $!Puffer! by $90 to $!Money_%Player%!.
set TennesseeAvenue=
set TennesseeAvenue_Houses=0
)
)
goto :TennesseeAvenue_Houses
:TennesseeAvenue_PayRent
:TennesseeAvenue_PayRent
if "!TennesseeAvenue_Houses!" == "0" set PayRent=14
if "!TennesseeAvenue_Houses!" == "1" set PayRent=70
if "!TennesseeAvenue_Houses!" == "2" set PayRent=200
if "!TennesseeAvenue_Houses!" == "3" set PayRent=550
if "!TennesseeAvenue_Houses!" == "4" set PayRent=700
if "!TennesseeAvenue_Houses!" == "5" set PayRent=900
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:NewYorkAvenue
:NewYorkAvenue 20
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined NewYorkAvenue_Houses set NewYorkAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ New York Avenue ∫
echo ∫ ∫
echo ∫ PRICE $200 RENT $16 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $80 ∫
echo ∫ ∫
echo ∫ With 2 Houses $220 ∫
echo ∫ ∫
echo ∫ With 3 Houses $600 ∫
echo ∫ ∫
echo ∫ With 4 Houses $800 ∫
echo ∫ ∫
echo ∫ With HOTEL $1000 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $100 ∫
echo ∫ ∫
echo ∫ Mortgage value $10 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!NewYorkAvenue!" == "%Player%" goto :NewYorkAvenue_Houses
if defined NewYorkAvenue goto :NewYorkAvenue_PayRent
echo Press [1] to buy this street for $200 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 200
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 200
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $200 to $!Money_%Player%!.
set NewYorkAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :NewYorkAvenue
:NewYorkAvenue_Houses
:NewYorkAvenue_Houses
if "!NewYorkAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !NewYorkAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $100.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 100
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 100
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $100 to $!Money_%Player%!.
set /a NewYorkAvenue_Houses=!NewYorkAvenue_Houses! + 1
if not "!NewYorkAvenue_Houses!" == "5" (echo This street has got !NewYorkAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 100
echo ƒƒƒ^> Money increased from $!Puffer! by $100 to $!Money_%Player%!.
set NewYorkAvenue=
set NewYorkAvenue_Houses=0
)
)
goto :NewYorkAvenue_Houses
:NewYorkAvenue_PayRent
:NewYorkAvenue_PayRent
if "!NewYorkAvenue_Houses!" == "0" set PayRent=16
if "!NewYorkAvenue_Houses!" == "1" set PayRent=80
if "!NewYorkAvenue_Houses!" == "2" set PayRent=220
if "!NewYorkAvenue_Houses!" == "3" set PayRent=600
if "!NewYorkAvenue_Houses!" == "4" set PayRent=800
if "!NewYorkAvenue_Houses!" == "5" set PayRent=1000
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:FreeParking
:FreeParking 21
if "!Money_Parking:~4,1!" == "" set Money_Parking=!Money_Parking!
if "!Money_Parking:~3,1!" == " " set Money_Parking=!Money_Parking!
if "!Money_Parking:~2,1!" == " " set Money_Parking=!Money_Parking!
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ Free Parking ∫
echo ∫ ‹‹‹‹ ∫
echo ∫ ‹€€€€€€€€€€€€€€‹ ∫
echo ∫ €€∞∞∞∞∞∞∞∞∞∞∞∞∞∞€€ ∫
echo ∫ €∞∞∞€flflflflflflflfl€∞∞∞€ ∫
echo ∫ €∞∞∞€ €∞∞∞€ ∫
echo ∫ €∞∞∞€‹‹‹‹‹‹‹‹€∞∞∞€ ∫
echo ∫ €∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞€ ∫
echo ∫ €∞∞∞∞∞‹€flfl€‹∞∞∞∞∞€ ∫
echo ∫ ‹€€€€∞∞∞∞∞€ ∞∞ €∞∞∞∞∞€€€€‹ ∫
echo ∫ ‹€∞∞∞∞∞∞∞∞∞fl€‹‹€fl∞∞∞∞∞∞∞∞∞€‹ ∫
echo ∫ fl€∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞€fl ∫
echo ∫ fl€€€€€€€€€€€€€€€€€€€€€€€€fl ∫
echo ∫ ≤±≤ ≤±≤ ∫
echo ∫ ≤≤≤ ≤≤≤ ∫
echo ∫ ∫
if not "!Money_Parking:~4,1!" == "" (echo ∫ Money stored: $!Money_Parking! ∫) ELSE (if not "!Money_Parking:~3,1!" == "" (echo ∫ Money stored: $!Money_Parking! ∫) ELSE (if not "!Money_Parking:~2,1!" == "" (echo ∫ Money stored: $!Money_Parking! ∫) ELSE (if not "!Money_Parking:~1,1!" == "" (echo ∫ Money stored: $!Money_Parking! ∫) ELSE (echo ∫ Money stored: $!Money_Parking! ∫))))
echo ∫ ∫
echo ∫ If you come on this field, you receive all the ∫
echo ∫ stored money from payments by other fields. ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
set /a Money_Parking=!Money_Parking!
if not "!Money_Parking!" == "0" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + !Money_Parking!
echo ƒƒƒ^> Money increased from $!Puffer! by $!Money_Parking! to $!Money_%Player%!.
echo.
)
set Money_Parking=0
pause
exit /b
:KentuckyAvenue
:KentuckyAvenue 22
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined KentuckyAvenue_Houses set KentuckyAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Kentucky Avenue ∫
echo ∫ ∫
echo ∫ PRICE $220 RENT $18 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $90 ∫
echo ∫ ∫
echo ∫ With 2 Houses $250 ∫
echo ∫ ∫
echo ∫ With 3 Houses $700 ∫
echo ∫ ∫
echo ∫ With 4 Houses $875 ∫
echo ∫ ∫
echo ∫ With HOTEL $1050 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $150 ∫
echo ∫ ∫
echo ∫ Mortgage value $110 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!KentuckyAvenue!" == "%Player%" goto :KentuckyAvenue_Houses
if defined KentuckyAvenue goto :KentuckyAvenue_PayRent
echo Press [1] to buy this street for $220 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 220
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 220
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $220 to $!Money_%Player%!.
set KentuckyAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :KentuckyAvenue
:KentuckyAvenue_Houses
:KentuckyAvenue_Houses
if "!KentuckyAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !KentuckyAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $110.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 150
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 150
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $150 to $!Money_%Player%!.
set /a KentuckyAvenue_Houses=!KentuckyAvenue_Houses! + 1
if not "!KentuckyAvenue_Houses!" == "5" (echo This street has got !KentuckyAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 110
echo ƒƒƒ^> Money increased from $!Puffer! by $110 to $!Money_%Player%!.
set KentuckyAvenue=
set KentuckyAvenue_Houses=0
)
)
goto :KentuckyAvenue_Houses
:KentuckyAvenue_PayRent
:KentuckyAvenue_PayRent
if "!KentuckyAvenue_Houses!" == "0" set PayRent=18
if "!KentuckyAvenue_Houses!" == "1" set PayRent=90
if "!KentuckyAvenue_Houses!" == "2" set PayRent=250
if "!KentuckyAvenue_Houses!" == "3" set PayRent=700
if "!KentuckyAvenue_Houses!" == "4" set PayRent=875
if "!KentuckyAvenue_Houses!" == "5" set PayRent=1050
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:IndianaAvenue
:IndianaAvenue 24
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined IndianaAvenue_Houses set IndianaAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Indiana Avenue ∫
echo ∫ ∫
echo ∫ PRICE $220 RENT $18 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $90 ∫
echo ∫ ∫
echo ∫ With 2 Houses $250 ∫
echo ∫ ∫
echo ∫ With 3 Houses $700 ∫
echo ∫ ∫
echo ∫ With 4 Houses $875 ∫
echo ∫ ∫
echo ∫ With HOTEL $1050 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $150 ∫
echo ∫ ∫
echo ∫ Mortgage value $110 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!IndianaAvenue!" == "%Player%" goto :IndianaAvenue_Houses
if defined IndianaAvenue goto :IndianaAvenue_PayRent
echo Press [1] to buy this street for $220 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 220
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 220
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $220 to $!Money_%Player%!.
set IndianaAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :IndianaAvenue
:IndianaAvenue_Houses
:IndianaAvenue_Houses
if "!IndianaAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !IndianaAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $110.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 150
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 150
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $150 to $!Money_%Player%!.
set /a IndianaAvenue_Houses=!IndianaAvenue_Houses! + 1
if not "!IndianaAvenue_Houses!" == "5" (echo This street has got !IndianaAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 110
echo ƒƒƒ^> Money increased from $!Puffer! by $110 to $!Money_%Player%!.
set IndianaAvenue=
set IndianaAvenue_Houses=0
)
)
goto :IndianaAvenue_Houses
:IndianaAvenue_PayRent
:IndianaAvenue_PayRent
if "!IndianaAvenue_Houses!" == "0" set PayRent=18
if "!IndianaAvenue_Houses!" == "1" set PayRent=90
if "!IndianaAvenue_Houses!" == "2" set PayRent=250
if "!IndianaAvenue_Houses!" == "3" set PayRent=700
if "!IndianaAvenue_Houses!" == "4" set PayRent=875
if "!IndianaAvenue_Houses!" == "5" set PayRent=1050
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:IllinoisAvenue
:IllinoisAvenue 25
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined IllinoisAvenue_Houses set IllinoisAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Illinois Avenue ∫
echo ∫ ∫
echo ∫ PRICE $240 RENT $20 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $100 ∫
echo ∫ ∫
echo ∫ With 2 Houses $300 ∫
echo ∫ ∫
echo ∫ With 3 Houses $750 ∫
echo ∫ ∫
echo ∫ With 4 Houses $925 ∫
echo ∫ ∫
echo ∫ With HOTEL $1100 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $150 ∫
echo ∫ ∫
echo ∫ Mortgage value $120 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!IllinoisAvenue!" == "%Player%" goto :IllinoisAvenue_Houses
if defined IllinoisAvenue goto :IllinoisAvenue_PayRent
echo Press [1] to buy this street for $240 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 240
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 240
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $240 to $!Money_%Player%!.
set IllinoisAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :IllinoisAvenue
:IllinoisAvenue_Houses
:IllinoisAvenue_Houses
if "!IllinoisAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !IllinoisAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $120.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 150
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 150
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $150 to $!Money_%Player%!.
set /a IllinoisAvenue_Houses=!IllinoisAvenue_Houses! + 1
if not "!IllinoisAvenue_Houses!" == "5" (echo This street has got !IllinoisAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 120
echo ƒƒƒ^> Money increased from $!Puffer! by $120 to $!Money_%Player%!.
set IllinoisAvenue=
set IllinoisAvenue_Houses=0
)
)
goto :IllinoisAvenue_Houses
:IllinoisAvenue_PayRent
:IllinoisAvenue_PayRent
if "!IllinoisAvenue_Houses!" == "0" set PayRent=20
if "!IllinoisAvenue_Houses!" == "1" set PayRent=100
if "!IllinoisAvenue_Houses!" == "2" set PayRent=300
if "!IllinoisAvenue_Houses!" == "3" set PayRent=750
if "!IllinoisAvenue_Houses!" == "4" set PayRent=925
if "!IllinoisAvenue_Houses!" == "5" set PayRent=1100
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:B.O.Railroad
:B.O.Railroad 26
set Purchase=
set Buy_House=
set PayRent=
set RailroadAmount=0
set Sell_Street=
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ B. ^& O. Railroad ∫
echo ∫ ∫
echo ∫ PRICE $200 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ If 1 owned $25 ∫
echo ∫ ∫
echo ∫ If 2 owned $50 ∫
echo ∫ ∫
echo ∫ If 3 owned $100 ∫
echo ∫ ∫
echo ∫ If 4 owned $200 ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ Mortgage value $100 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!B.O.Railroad!" == "%Player%" goto :B.O.Railroad_Houses
if defined B.O.Railroad goto :B.O.Railroad_PayRent
echo Press [1] to buy this railroad for $200 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 200
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 200
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $200 to $!Money_%Player%!.
set B.O.Railroad=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :B.O.Railroad
:B.O.Railroad_Houses
:B.O.Railroad_Houses
echo This railroad is yours.
echo.
echo Press [2] to leave it or
echo press [3] to sell it for $100.
set /p Buy_House=
echo.
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell this railroad? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 100
echo ƒƒƒ^> Money increased from $!Puffer! by $100 to $!Money_%Player%!.
set B.O.Railroad=
)
)
goto :B.O.Railroad_Houses
:B.O.Railroad_PayRent
:B.O.Railroad_PayRent
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
FOR %%A IN (ReadingRailroad PennsylvaniaRailroad B.O.Railroad ShortLineRailroad) DO if "!%%A!" == "%Player%" set /a RailroadAmount=!RailroadAmount! + 1
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo The other player owns !RailroadAmount! of 4 railroads.
if "!RailroadAmount!" == "1" set PayRent=25
if "!RailroadAmount!" == "2" set PayRent=50
if "!RailroadAmount!" == "3" set PayRent=100
if "!RailroadAmount!" == "4" set PayRent=200
if "!RentalTwice!" == "1" set /a PayRent=%PayRent% * 2
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:AtlanticAvenue
:AtlanticAvenue 27
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined AtlanticAvenue_Houses set AtlanticAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Atlantic Avenue ∫
echo ∫ ∫
echo ∫ PRICE $260 RENT $22 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $110 ∫
echo ∫ ∫
echo ∫ With 2 Houses $330 ∫
echo ∫ ∫
echo ∫ With 3 Houses $800 ∫
echo ∫ ∫
echo ∫ With 4 Houses $975 ∫
echo ∫ ∫
echo ∫ With HOTEL $1150 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $150 ∫
echo ∫ ∫
echo ∫ Mortgage value $130 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!AtlanticAvenue!" == "%Player%" goto :AtlanticAvenue_Houses
if defined AtlanticAvenue goto :AtlanticAvenue_PayRent
echo Press [1] to buy this street for $260 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 260
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 260
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $260 to $!Money_%Player%!.
set AtlanticAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :AtlanticAvenue
:AtlanticAvenue_Houses
:AtlanticAvenue_Houses
if "!AtlanticAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !AtlanticAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $130.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 150
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 150
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $150 to $!Money_%Player%!.
set /a AtlanticAvenue_Houses=!AtlanticAvenue_Houses! + 1
if not "!AtlanticAvenue_Houses!" == "5" (echo This street has got !AtlanticAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 130
echo ƒƒƒ^> Money increased from $!Puffer! by $130 to $!Money_%Player%!.
set AtlanticAvenue=
set AtlanticAvenue_Houses=0
)
)
goto :AtlanticAvenue_Houses
:AtlanticAvenue_PayRent
:AtlanticAvenue_PayRent
if "!AtlanticAvenue_Houses!" == "0" set PayRent=22
if "!AtlanticAvenue_Houses!" == "1" set PayRent=110
if "!AtlanticAvenue_Houses!" == "2" set PayRent=330
if "!AtlanticAvenue_Houses!" == "3" set PayRent=800
if "!AtlanticAvenue_Houses!" == "4" set PayRent=975
if "!AtlanticAvenue_Houses!" == "5" set PayRent=1150
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:VeninorAvenue
:VeninorAvenue 28
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined VeninorAvenue_Houses set VeninorAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Veninor Avenue ∫
echo ∫ ∫
echo ∫ PRICE $260 RENT $22 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $110 ∫
echo ∫ ∫
echo ∫ With 2 Houses $330 ∫
echo ∫ ∫
echo ∫ With 3 Houses $800 ∫
echo ∫ ∫
echo ∫ With 4 Houses $975 ∫
echo ∫ ∫
echo ∫ With HOTEL $1150 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $150 ∫
echo ∫ ∫
echo ∫ Mortgage value $130 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!VeninorAvenue!" == "%Player%" goto :VeninorAvenue_Houses
if defined VeninorAvenue goto :VeninorAvenue_PayRent
echo Press [1] to buy this street for $260 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 260
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 260
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $260 to $!Money_%Player%!.
set VeninorAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :VeninorAvenue
:VeninorAvenue_Houses
:VeninorAvenue_Houses
if "!VeninorAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !VeninorAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $130.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 150
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 150
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $150 to $!Money_%Player%!.
set /a VeninorAvenue_Houses=!VeninorAvenue_Houses! + 1
if not "!VeninorAvenue_Houses!" == "5" (echo This street has got !VeninorAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 130
echo ƒƒƒ^> Money increased from $!Puffer! by $130 to $!Money_%Player%!.
set VeninorAvenue=
set VeninorAvenue_Houses=0
)
)
goto :VeninorAvenue_Houses
:VeninorAvenue_PayRent
:VeninorAvenue_PayRent
if "!VeninorAvenue_Houses!" == "0" set PayRent=22
if "!VeninorAvenue_Houses!" == "1" set PayRent=110
if "!VeninorAvenue_Houses!" == "2" set PayRent=330
if "!VeninorAvenue_Houses!" == "3" set PayRent=800
if "!VeninorAvenue_Houses!" == "4" set PayRent=975
if "!VeninorAvenue_Houses!" == "5" set PayRent=1150
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:WaterWorks
:WaterWorks 29
set Purchase=
set Buy_House=
set PayRent=
set CompanyAmount=0
set Sell_Street=
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Water Works ∫
echo ∫ ∫
echo ∫ PRICE $150 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫If 1 owned, rent equals ∫
echo ∫ ∫
echo ∫ 4 times dice roll ∫
echo ∫ ∫
echo ∫ ∫
echo ∫If 2 owned, rent equals ∫
echo ∫ ∫
echo ∫ 10 times dice roll ∫
echo ∫ ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ Mortgage value $75 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!WaterWorks!" == "%Player%" goto :WaterWorks_Houses
if defined WaterWorks goto :WaterWorks_PayRent
echo Press [1] to buy this street for $150 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 150
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 150
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $150 to $!Money_%Player%!.
set WaterWorks=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :WaterWorks
:WaterWorks_Houses
:WaterWorks_Houses
echo Press [2] to leave it or
echo press [3] to sell it for $75.
set /p Buy_House=
echo.
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell this street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 75
echo ƒƒƒ^> Money increased from $!Puffer! by $75 to $!Money_%Player%!.
set WaterWorks=
)
)
goto :ElectricCompany_Houses
:WaterWorks_PayRent
:WaterWorks_PayRent
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
if "!ElectricCompany!" == "%Player%" set /a CompanyAmount=!CompanyAmount! + 1
if "!WaterWorks!" == "%Player%" set /a CompanyAmount=!CompanyAmount! + 1
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo The other player owns !CompanyAmount! of 2 companies.
if "!CompanyAmount!" == "1" set /a PayRent=%Dice% * 4
if "!CompanyAmount!" == "2" set /a PayRent=%Dice% * 10
if "%1" == "CameByChance" set /a PayRent=!Dice! * 10
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:MarvinGardens
:MarvinGardens 30
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined MarvinGardens_Houses set MarvinGardens_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Marvin Gardens ∫
echo ∫ ∫
echo ∫ PRICE $280 RENT $24 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $120 ∫
echo ∫ ∫
echo ∫ With 2 Houses $360 ∫
echo ∫ ∫
echo ∫ With 3 Houses $850 ∫
echo ∫ ∫
echo ∫ With 4 Houses $1025 ∫
echo ∫ ∫
echo ∫ With HOTEL $1200 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $150 ∫
echo ∫ ∫
echo ∫ Mortgage value $140 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!MarvinGardens!" == "%Player%" goto :MarvinGardens_Houses
if defined MarvinGardens goto :MarvinGardens_PayRent
echo Press [1] to buy this street for $280 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 280
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 280
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $280 to $!Money_%Player%!.
set MarvinGardens=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :MarvinGardens
:MarvinGardens_Houses
:MarvinGardens_Houses
if "!MarvinGardens_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !MarvinGardens_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $140.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 150
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 150
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $150 to $!Money_%Player%!.
set /a MarvinGardens_Houses=!MarvinGardens_Houses! + 1
if not "!MarvinGardens_Houses!" == "5" (echo This street has got !MarvinGardens_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 140
echo ƒƒƒ^> Money increased from $!Puffer! by $140 to $!Money_%Player%!.
set MarvinGardens=
set MarvinGardens_Houses=0
)
)
goto :MarvinGardens_Houses
:MarvinGardens_PayRent
:MarvinGardens_PayRent
if "!MarvinGardens_Houses!" == "0" set PayRent=24
if "!MarvinGardens_Houses!" == "1" set PayRent=120
if "!MarvinGardens_Houses!" == "2" set PayRent=360
if "!MarvinGardens_Houses!" == "3" set PayRent=850
if "!MarvinGardens_Houses!" == "4" set PayRent=1025
if "!MarvinGardens_Houses!" == "5" set PayRent=1200
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:SendToJail
:SendToJail 31
set Field!Player%Player%Position!_%Player%=
call :SetFields
set Field11_J_%Player%=!Char_%Player%!
set Player%Player%Position=11
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ EDEE ∫
echo ∫ DELLffD Go to jail. ∫
echo ∫ DffLfLLD ∫
echo ∫ , fGDED ∫
echo ∫ , L G ∫
echo ∫ E ˙^> . GL ∫
echo ∫ .L LGj D ∫
echo ∫ G i..E D G ∫
echo ∫ t, D D / f ∫
echo ∫ jDE D D D ∫
echo ∫ Ei D-E D tDt ∫
echo ∫ EfDD DGD j D ∫
echo ∫ DLLELEGjD GE .DDf ∫
echo ∫ ,GLLD.E D D if ∫
echo ∫ ,fELLLEKLELLE LLL ∫
echo ∫DfLKLLLLKLLLLDD Do not walk over Go, ∫
echo ∫DfLLELLDGLLLLfE do not collect $200. ∫
echo ∫DfffLLfLLLLfL, ∫
echo ∫DfffLfffLLffE ∫
echo ∫GGGGGGGDLiE ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
if "%1" == "Doublets" (
echo You got three doublets in a row.
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
)
set Player=!Player!
pause
exit /b
:PacificAvenue
:PacificAvenue 32
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined PacificAvenue_Houses set PacificAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Pacific Avenue ∫
echo ∫ ∫
echo ∫ PRICE $300 RENT $26 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $130 ∫
echo ∫ ∫
echo ∫ With 2 Houses $390 ∫
echo ∫ ∫
echo ∫ With 3 Houses $900 ∫
echo ∫ ∫
echo ∫ With 4 Houses $1100 ∫
echo ∫ ∫
echo ∫ With HOTEL $1275 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $200 ∫
echo ∫ ∫
echo ∫ Mortgage value $150 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!PacificAvenue!" == "%Player%" goto :PacificAvenue_Houses
if defined PacificAvenue goto :PacificAvenue_PayRent
echo Press [1] to buy this street for $300 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 300
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 300
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $300 to $!Money_%Player%!.
set PacificAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :PacificAvenue
:PacificAvenue_Houses
:PacificAvenue_Houses
if "!PacificAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !PacificAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $150.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 200
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 200
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $200 to $!Money_%Player%!.
set /a PacificAvenue_Houses=!PacificAvenue_Houses! + 1
if not "!PacificAvenue_Houses!" == "5" (echo This street has got !PacificAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 150
echo ƒƒƒ^> Money increased from $!Puffer! by $150 to $!Money_%Player%!.
set PacificAvenue=
set PacificAvenue_Houses=0
)
)
goto :PacificAvenue_Houses
:PacificAvenue_PayRent
:PacificAvenue_PayRent
if "!PacificAvenue_Houses!" == "0" set PayRent=26
if "!PacificAvenue_Houses!" == "1" set PayRent=130
if "!PacificAvenue_Houses!" == "2" set PayRent=390
if "!PacificAvenue_Houses!" == "3" set PayRent=900
if "!PacificAvenue_Houses!" == "4" set PayRent=1100
if "!PacificAvenue_Houses!" == "5" set PayRent=1275
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:NorthCarolinaAvenue
:NorthCarolinaAvenue 33
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined NorthCarolinaAvenue_Houses set NorthCarolinaAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ North Carolina Avenue ∫
echo ∫ ∫
echo ∫ PRICE $300 RENT $26 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $130 ∫
echo ∫ ∫
echo ∫ With 2 Houses $390 ∫
echo ∫ ∫
echo ∫ With 3 Houses $900 ∫
echo ∫ ∫
echo ∫ With 4 Houses $1100 ∫
echo ∫ ∫
echo ∫ With HOTEL $1275 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $200 ∫
echo ∫ ∫
echo ∫ Mortgage value $150 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!NorthCarolinaAvenue!" == "%Player%" goto :NorthCarolinaAvenue_Houses
if defined NorthCarolinaAvenue goto :NorthCarolinaAvenue_PayRent
echo Press [1] to buy this street for $300 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 300
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 300
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $300 to $!Money_%Player%!.
set NorthCarolinaAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :NorthCarolinaAvenue
:NorthCarolinaAvenue_Houses
:NorthCarolinaAvenue_Houses
if "!NorthCarolinaAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !NorthCarolinaAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $150.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 200
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 200
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $200 to $!Money_%Player%!.
set /a NorthCarolinaAvenue_Houses=!NorthCarolinaAvenue_Houses! + 1
if not "!NorthCarolinaAvenue_Houses!" == "5" (echo This street has got !NorthCarolinaAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 150
echo ƒƒƒ^> Money increased from $!Puffer! by $150 to $!Money_%Player%!.
set NorthCarolinaAvenue=
set NorthCarolinaAvenue_Houses=0
)
)
goto :NorthCarolinaAvenue_Houses
:NorthCarolinaAvenue_PayRent
:NorthCarolinaAvenue_PayRent
if "!NorthCarolinaAvenue_Houses!" == "0" set PayRent=26
if "!NorthCarolinaAvenue_Houses!" == "1" set PayRent=130
if "!NorthCarolinaAvenue_Houses!" == "2" set PayRent=390
if "!NorthCarolinaAvenue_Houses!" == "3" set PayRent=900
if "!NorthCarolinaAvenue_Houses!" == "4" set PayRent=1100
if "!NorthCarolinaAvenue_Houses!" == "5" set PayRent=1275
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:PennsylvaniaAvenue
:PennsylvaniaAvenue 35
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined PennsylvaniaAvenue_Houses set PennsylvaniaAvenue_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Pennsylvania Avenue ∫
echo ∫ ∫
echo ∫ PRICE $320 RENT $28 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $150 ∫
echo ∫ ∫
echo ∫ With 2 Houses $450 ∫
echo ∫ ∫
echo ∫ With 3 Houses $1000 ∫
echo ∫ ∫
echo ∫ With 4 Houses $1200 ∫
echo ∫ ∫
echo ∫ With HOTEL $1400 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $200 ∫
echo ∫ ∫
echo ∫ Mortgage value $160 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!PennsylvaniaAvenue!" == "%Player%" goto :PennsylvaniaAvenue_Houses
if defined PennsylvaniaAvenue goto :PennsylvaniaAvenue_PayRent
echo Press [1] to buy this street for $320 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 320
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 320
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $320 to $!Money_%Player%!.
set PennsylvaniaAvenue=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :PennsylvaniaAvenue
:PennsylvaniaAvenue_Houses
:PennsylvaniaAvenue_Houses
if "!PennsylvaniaAvenue_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !PennsylvaniaAvenue_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $160.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 200
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 200
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $200 to $!Money_%Player%!.
set /a PennsylvaniaAvenue_Houses=!PennsylvaniaAvenue_Houses! + 1
if not "!PennsylvaniaAvenue_Houses!" == "5" (echo This street has got !PennsylvaniaAvenue_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 160
echo ƒƒƒ^> Money increased from $!Puffer! by $160 to $!Money_%Player%!.
set PennsylvaniaAvenue=
set PennsylvaniaAvenue_Houses=0
)
)
goto :PennsylvaniaAvenue_Houses
:PennsylvaniaAvenue_PayRent
:PennsylvaniaAvenue_PayRent
if "!PennsylvaniaAvenue_Houses!" == "0" set PayRent=28
if "!PennsylvaniaAvenue_Houses!" == "1" set PayRent=150
if "!PennsylvaniaAvenue_Houses!" == "2" set PayRent=450
if "!PennsylvaniaAvenue_Houses!" == "3" set PayRent=1000
if "!PennsylvaniaAvenue_Houses!" == "4" set PayRent=1200
if "!PennsylvaniaAvenue_Houses!" == "5" set PayRent=1400
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:ShortLineRailroad
:ShortLineRailroad 36
set Purchase=
set Buy_House=
set PayRent=
set RailroadAmount=0
set Sell_Street=
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Short Line ∫
echo ∫ ∫
echo ∫ PRICE $200 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ If 1 owned $25 ∫
echo ∫ ∫
echo ∫ If 2 owned $50 ∫
echo ∫ ∫
echo ∫ If 3 owned $100 ∫
echo ∫ ∫
echo ∫ If 4 owned $200 ∫
echo ∫ ∫
echo ∫ ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ Mortgage value $100 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!ShortLineRailroad!" == "%Player%" goto :ShortLineRailroad_Houses
if defined ShortLineRailroad goto :ShortLineRailroad_PayRent
echo Press [1] to buy this railroad for $200 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 200
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 200
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $200 to $!Money_%Player%!.
set ShortLineRailroad=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :ShortLineRailroad
:ShortLineRailroad_Houses
:ShortLineRailroad_Houses
echo This railroad is yours.
echo.
echo Press [2] to leave it or
echo press [3] to sell it for $100.
set /p Buy_House=
echo.
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell this railroad? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 100
echo ƒƒƒ^> Money increased from $!Puffer! by $100 to $!Money_%Player%!.
set ShortLineRailroad=
)
)
goto :ShortLineRailroad_Houses
:ShortLineRailroad_PayRent
:ShortLineRailroad_PayRent
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
FOR %%A IN (ReadingRailroad PennsylvaniaRailroad B.O.Railroad ShortLineRailroad) DO if "!%%A!" == "%Player%" set /a RailroadAmount=!RailroadAmount! + 1
if "%Player%" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo The other player owns !RailroadAmount! of 4 railroads.
if "!RailroadAmount!" == "1" set PayRent=25
if "!RailroadAmount!" == "2" set PayRent=50
if "!RailroadAmount!" == "3" set PayRent=100
if "!RailroadAmount!" == "4" set PayRent=200
if "!RentalTwice!" == "1" set /a PayRent=%PayRent% * 2
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:ParkPlace
:ParkPlace 38
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined ParkPlace_Houses set ParkPlace_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Park Place ∫
echo ∫ ∫
echo ∫ PRICE $350 RENT $35 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $175 ∫
echo ∫ ∫
echo ∫ With 2 Houses $500 ∫
echo ∫ ∫
echo ∫ With 3 Houses $1100 ∫
echo ∫ ∫
echo ∫ With 4 Houses $1300 ∫
echo ∫ ∫
echo ∫ With HOTEL $1500 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $200 ∫
echo ∫ ∫
echo ∫ Mortgage value $175 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!ParkPlace!" == "%Player%" goto :ParkPlace_Houses
if defined ParkPlace goto :ParkPlace_PayRent
echo Press [1] to buy this street for $350 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 350
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 350
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $350 to $!Money_%Player%!.
set ParkPlace=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :ParkPlace
:ParkPlace_Houses
:ParkPlace_Houses
if "!ParkPlace_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !ParkPlace_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $175.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 200
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 200
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $200 to $!Money_%Player%!.
set /a ParkPlace_Houses=!ParkPlace_Houses! + 1
if not "!ParkPlace_Houses!" == "5" (echo This street has got !ParkPlace_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 175
echo ƒƒƒ^> Money increased from $!Puffer! by $175 to $!Money_%Player%!.
set ParkPlace=
set ParkPlace_Houses=0
)
)
goto :ParkPlace_Houses
:ParkPlace_PayRent
:ParkPlace_PayRent
if "!ParkPlace_Houses!" == "0" set PayRent=35
if "!ParkPlace_Houses!" == "1" set PayRent=175
if "!ParkPlace_Houses!" == "2" set PayRent=500
if "!ParkPlace_Houses!" == "3" set PayRent=1100
if "!ParkPlace_Houses!" == "4" set PayRent=1300
if "!ParkPlace_Houses!" == "5" set PayRent=1500
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
:LuxuryTax
:LuxuryTax 39
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ LUXURY ∫
echo ∫ ∫
echo ∫ TAX ∫
echo ∫ ∫
echo ∫ ___ ∫
echo ∫ ≤≤≤/***\≤≤≤ ∫
echo ∫ ≤∞∞∞\***/∞∞∞≤ ∫
echo ∫ ≤∞∞∞∞∞ÓÓÓ∞∞∞∞∞≤ ∫
echo ∫ ≤∞∞∞≤≤≤≤≤≤≤≤≤∞∞∞≤ ∫
echo ∫ ≤∞∞∞≤≤≤ ≤≤≤∞∞∞≤ ∫
echo ∫ ≤∞∞≤≤ ≤≤∞∞≤ ∫
echo ∫ ≤∞∞≤ ≤∞∞≤ ∫
echo ∫ ≤∞∞≤ ≤∞∞≤ ∫
echo ∫ ≤∞∞∞≤ ≤∞∞∞≤ ∫
echo ∫ ≤∞∞∞≤≤≤≤≤≤≤≤≤∞∞∞≤ ∫
echo ∫ ≤∞∞∞∞∞∞∞∞∞∞∞∞∞≤ ∫
echo ∫ ≤∞∞∞∞∞∞∞∞∞∞∞≤ ∫
echo ∫ ≤≤≤≤≤≤≤≤≤≤≤ ∫
echo ∫ ∫
echo ∫ You have to pay $75 ∫
echo ∫ for the Luxury Tax. ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 75
set /a Money_Parking=!Money_Parking! + 75
echo ƒƒƒ^> Money decreased from $%Puffer% by $75 to $!Money_%Player%!.
echo ^& $75 went into Free Parking.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
echo.
pause
exit /b
:Boardwalk
:Boardwalk 40
set Purchase=
set Buy_House=
set PayRent=
set Sell_Street=
if not defined Boardwalk_Houses set Boardwalk_Houses=0
cls
echo …ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕª
echo ∫ ∫
echo ∫ Boardwalk ∫
echo ∫ ∫
echo ∫ PRICE $400 RENT $50 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ With 1 House $200 ∫
echo ∫ ∫
echo ∫ With 2 Houses $600 ∫
echo ∫ ∫
echo ∫ With 3 Houses $1400 ∫
echo ∫ ∫
echo ∫ With 4 Houses $1700 ∫
echo ∫ ∫
echo ∫ With HOTEL $2000 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ One house costs $200 ∫
echo ∫ ∫
echo ∫ Mortgage value $200 ∫
echo ∫ ƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒƒ ∫
echo ∫ ∫
echo »ÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕÕº
echo.
echo Current player: %Player% (!Char_%Player%!)
echo Total money: !Money_%Player%!
echo.
if "!Boardwalk!" == "%Player%" goto :Boardwalk_Houses
if defined Boardwalk goto :Boardwalk_PayRent
echo Press [1] to buy this street for $400 or
echo press [2] to leave it.
set /p Purchase=
if "%Purchase%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 400
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 400
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $400 to $!Money_%Player%!.
set Boardwalk=%Player%
)
pause
exit /b
)
if "%Purchase%" == "2" exit /b
goto :Boardwalk
:Boardwalk_Houses
:Boardwalk_Houses
if "!Boardwalk_Houses!" == "5" (
echo This street has got a hotel.
pause
exit /b
) ELSE (
echo This street has got !Boardwalk_Houses! houses, yet.
echo.
)
echo Press [1] to buy a new house or
echo press [2] to leave it or
echo press [3] to sell it for $200.
set /p Buy_House=
echo.
if "%Buy_House%" == "1" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - 200
if "!Money_%Player%:~0,1!" == "-" (
echo You have not enough money.
set /a Money_%Player%=!Money_%Player%! + 200
) ELSE (
echo ƒƒƒ^> Money decreased from $!Puffer! by $200 to $!Money_%Player%!.
set /a Boardwalk_Houses=!Boardwalk_Houses! + 1
if not "!Boardwalk_Houses!" == "5" (echo This street has got !Boardwalk_Houses! houses now.) ELSE (echo This street has got a hotel now.)
)
pause
exit /b
)
if "%Buy_House%" == "2" exit /b
if "%Buy_House%" == "3" (
echo Are you sure you want to sell the street? [Y/N]
set /p Sell_Street=
if /i "!Sell_Street!" == "n" exit /b
if /i "!Sell_Street!" == "y" (
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + 200
echo ƒƒƒ^> Money increased from $!Puffer! by $200 to $!Money_%Player%!.
set Boardwalk=
set Boardwalk_Houses=0
)
)
goto :Boardwalk_Houses
:Boardwalk_PayRent
:Boardwalk_PayRent
if "!Boardwalk_Houses!" == "0" set PayRent=50
if "!Boardwalk_Houses!" == "1" set PayRent=200
if "!Boardwalk_Houses!" == "2" set PayRent=600
if "!Boardwalk_Houses!" == "3" set PayRent=1400
if "!Boardwalk_Houses!" == "4" set PayRent=1700
if "!Boardwalk_Houses!" == "5" set PayRent=2000
echo This street is owned by the other player. You have to pay
echo $%PayRent% to pass.
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! - %PayRent%
echo ƒƒƒ^> Money decreased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Money_%Player%:~0,1!" == "-" (
echo.
pause
cls
echo Player %Player% [!Char_%Player%!] is bankrupt.
echo.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
echo Player !Player! wins the game.
echo.
pause
exit
)
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
set Puffer=!Money_%Player%!
set /a Money_%Player%=!Money_%Player%! + %PayRent%
echo ƒƒƒ^> The other player's money increased from $%Puffer% by $%PayRent% to $!Money_%Player%!.
if "!Player!" == "1" (set Player=2) ELSE (set Player=1)
set Player=!Player!
echo.
pause
exit /b
Deal:
:: Created by ScrewTheLotOfYou
:: Copy, reproduce and edit all you like, as long as you don't infringe copyrights.
:: I have based this game's format loosely on the British tv show 'Deal Or No Deal' owned
:: by Endemol.
:: I do not own any part of the show and have created this basic program only to
:: educate on ways to use, and the capabilities of, the language.
:: Note, throughout the game I have had to use dollar signs instead of pound signs, as batch
:: files won't accept them for some reason...
@echo off
echo Loading...
setlocal enabledelayedexpansion
set dealdone=0
set Spaces=
for /l %%I in (1,1,22) do set gapline%%I= ___________
set amount1=1
set amount2=10
set amount3=50
set amount4=100
set amount5=500
set amount6=1000
set amount7=5000
set amount8=10000
set amount9=25000
set amount10=50000
set amount11=75000
set amount12=100000
set amount13=300000
set amount14=500000
set amount15=1000000
set amount16=1500000
set amount17=2000000
set amount18=3500000
set amount19=5000000
set amount20=7500000
set amount21=10000000
set amount22=25000000
set famount1=$0.01
set famount2=$0.1
set famount3=$0.50
set famount4=$1
set famount5=$5
set famount6=$10
set famount7=$50
set famount8=$100
set famount9=$250
set famount10=$500
set famount11=$750
set famount12=$1,000
set famount13=$3,000
set famount14=$5,000
set famount15=$10,000
set famount16=$15,000
set famount17=$20,000
set famount18=$35,000
set famount19=$50,000
set famount20=$75,000
set famount21=$100,000
set famount22=$250,000
set Damount1={___$0.01___}
set Damount2={____$0.1___}
set Damount3={____$0.5___}
set Damount4={_____$1____}
set Damount5={_____$5____}
set Damount6={____$10____}
set Damount7={____$50____}
set Damount8={____$100___}
set Damount9={____$250___}
set Damount10={____$500___}
set Damount11={____$750___}
set Damount12={___$1000___}
set Damount13={___$3000___}
set Damount14={___$5000___}
set Damount15={___$10000__}
set Damount16={___$15000__}
set Damount17={___$20000__}
set Damount18={___$35000__}
set Damount19={___$50000__}
set Damount20={___$75000__}
set Damount21={__$100000__}
set Damount22={__$250000__}
for /l %%I in (1,1,22) do set boxtop%%I= _____
for /l %%I in (1,1,22) do set boxlid%%I=[_____]
for /l %%I in (1,1,9) do set boxmid%%I=[ %%I ]
for /l %%I in (10,1,22) do set boxmid%%I=[ %%I ]
for /l %%I in (1,1,22) do set boxbot%%I=[_____]
for /l %%I in (23,1,24) do set boxtop%%I=
for /l %%I in (23,1,24) do set boxlid%%I=
for /l %%I in (23,1,24) do set boxmid%%I=
for /l %%I in (23,1,24) do set boxbot%%I=
for /l %%I in (1,4,24) do (
set /a box2number= %%I + 1
set /a box3number= %%I + 2
set /a box4number= %%I + 3
set DisplayLine%%I=#boxtop%%I##boxtop!box2number!##boxtop!box3number!##boxtop!box4number!#
)
for /l %%I in (2,4,24) do (
set /a boxnumber= %%I - 1
set /a box2number= !boxnumber! + 1
set /a box3number= !boxnumber! + 2
set /a box4number= !boxnumber! + 3
set DisplayLine%%I=#boxlid!boxnumber!##boxlid!box2number!##boxlid!box3number!##boxlid!box4number!#
)
for /l %%I in (3,4,24) do (
set /a boxnumber= %%I - 2
set /a box2number= !boxnumber! + 1
set /a box3number= !boxnumber! + 2
set /a box4number= !boxnumber! + 3
set DisplayLine%%I=#boxmid!boxnumber!##boxmid!box2number!##boxmid!box3number!##boxmid!box4number!#
)
for /l %%I in (4,4,24) do (
set /a boxnumber= %%I - 3
set /a box2number= !boxnumber! + 1
set /a box3number= !boxnumber! + 2
set /a box4number= !boxnumber! + 3
set DisplayLine%%I=#boxbot!boxnumber!##boxbot!box2number!##boxbot!box3number!##boxbot!box4number!#
)
set amountnumber1=0
set amountnumber2=11
for /l %%I in (1,2,22) do set /a AmountNumber1= !amountnumber1! + 1 && set /a Amountnumber2= !amountnumber2! + 1 && for /l %%J in (!Amountnumber1!,1,!Amountnumber1!) do for /l %%K in (!Amountnumber2!,1,!Amountnumber2!) do (
set Displayline%%I=#gapline%%J# !Displayline%%I! #gapline%%K#
)
set amountnumber1=0
set amountnumber2=11
for /l %%I in (2,2,22) do set /a AmountNumber1= !amountnumber1! + 1 && set /a Amountnumber2= !amountnumber2! + 1 && for /l %%J in (!Amountnumber1!,1,!Amountnumber1!) do for /l %%K in (!Amountnumber2!,1,!Amountnumber2!) do (
set Displayline%%I=#Damount%%J# !Displayline%%I! #Damount%%K#
)
for /l %%I in (23,1,24) do set displayline%%I= !Displayline%%I!
set amountsleft=
for /l %%I in (1,1,22) do set AmountsLeft=!Amountsleft!%%I,
set Amountnumber=1
:RandomNumber
set minval=1
set maxval=22
:NumberGenerator
set /a RandomNumber= %random% / 1489
set /a RandomNumber= %RandomNumber% + %MinVal%
if /i %RandomNumber% GTR %Maxval% goto NumberGenerator
if not defined box%randomnumber% (
set box%randomnumber%=%amountnumber%
set /a Amountnumber= !Amountnumber! + 1
if /i !amountnumber!==23 goto intro
)
goto Randomnumber
:intro
cls
echo Let's Play...
echo.
echo.
echo ############################################
echo # #
echo # @@ @@@@ @ @ @ @@@ #
echo # @ @ @ @ @ @ @ @ @ @ #
echo # @ @ @ @ @ @ @ @ @ #
echo # @ @ @@@ @@@@@ @ @ @ @ #
echo # @ @ @ @ @ @ @ @ @ #
echo # @@ @@@@ @ @ @@@@ @ @ #
echo # #
echo # @ @ @ @@ @@@@ @ @ #
echo # @@ @ @ @ @ @ @ @ @ @ #
echo # @@ @ @ @ @ @ @ @ @ @ #
echo # @ @@ @ @ @ @ @@@@ @@@@@ @ #
echo # @ @@ @ @ @ @ @ @ @ @ #
echo # @ @ @ @@ @@@@ @ @ @@@@ #
echo # #
echo ############################################
echo.
echo I do not own the "Deal Or No Deal" format or concept. All copyrights
echo and trademarks are property of their respective owners.
echo.
set /p helpyn="Press enter to continue, or type HELP for instructions.
if /i "%HelpYN%"=="HELP" (
cls
echo The aim of the game is to get as much money as possible for your box.
echo The game concept is simple. There are 22 sums of money inside 22 boxes.
echo The player must choose a box to keep, then remove the others from play,
echo one by one not knowing what sum is inside each box.
echo.
echo After a certain number of choices, The Banker will phone. He will make
echo you an offer to buy your box off you. You may choose to accept this offer,
echo or keep removing money. Removing high sums makes lower offers and vice-
echo versa.
echo.
echo If you play until there are only two boxes left, you have the choice to
echo open the box you started with, or switch to the other box. You win the
echo money in the box.
echo.
echo The knack to the game is knowing whether to take the deal or stop removing
echo money from the game.
pause
)
cls
:ChooseBox
call :display
set /p OwnBox="Choose your own box to keep: "
if not defined Ownbox goto Choosebox
if /i not %ownbox%0 leq 220 goto ChooseBox
if /i not %ownbox%0 geq 10 goto ChooseBox
set boxtop%ownbox%=
set boxlid%ownbox%=
set boxmid%ownbox%=
set boxbot%ownbox%=
set BoxesLeft=22
Set turns=5
set boxmessage=Choose the box you want to open
call :gameloop
if %dealdone%==1 exit /b
Set turns=3
set boxmessage=Choose the box you want to open
call :gameloop
if %dealdone%==1 exit /b
Set turns=3
set boxmessage=Choose the box you want to open
call :gameloop
if %dealdone%==1 exit /b
Set turns=3
set boxmessage=Choose the box you want to open
call :gameloop
if %dealdone%==1 exit /b
Set turns=3
set boxmessage=Choose the box you want to open
call :gameloop
if %dealdone%==1 exit /b
Set turns=3
set boxmessage=Choose the box you want to open
call :gameloop
if %dealdone%==1 exit /b
goto SwapOrNot
:gameLoop
cls
call :display
set boxtoremove=
:OpenBox
set /p BoxToRemove="%BoxMessage%"
if not defined BoxToRemove goto OpenBox
if /i not %BoxToRemove%0 leq 220 goto OpenBox
if /i not %BoxToRemove%0 geq 10 goto openBox
if /i %BoxToRemove%==%OwnBox% goto OpenBox
if /i "!Box%boxtoremove%!"=="DONE" goto OpenBox
call :removebox %boxtoremove%
set /a BoxesLeft=%BoxesLeft% - 1
set /a Turns= %Turns% - 1
if /i %turns%==0 (
cls
call :display
set /p asdfghj="You lost amount %Amountinbox%. The Phone is ringing, press enter to answer it."
set asdfghj=
call :MakeOffer
exit /b
)
set boxmessage=You lost amount %Amountinbox%. Choose the box you want to open.
Goto GameLoop
:RemoveBox
set boxtop%1=
set boxlid%1%=
set boxmid%1=
set boxbot%1=
set AmountInBox=!Box%1!
call :Remove_Amounts %AmountInBox%
set Box%1=DONE
exit /b
:Remove_Amounts
set damount%1=
set gapline%1=
for /f "tokens=1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22 delims=," %%A in ("%AmountsLeft%") do (
set amountsleft=
if /i not %%A==%1 set AmountsLeft=%%A,
if /i not %%B==%1 set AmountsLeft=!AmountsLeft!%%B,
if /i not %%C==%1 set AmountsLeft=!AmountsLeft!%%C,
if /i not %%D==%1 set AmountsLeft=!AmountsLeft!%%D,
if /i not %%E==%1 set AmountsLeft=!AmountsLeft!%%E,
if /i not %%F==%1 set AmountsLeft=!AmountsLeft!%%F,
if /i not %%G==%1 set AmountsLeft=!AmountsLeft!%%G,
if /i not %%H==%1 set AmountsLeft=!AmountsLeft!%%H,
if /i not %%I==%1 set AmountsLeft=!AmountsLeft!%%I,
if /i not %%J==%1 set AmountsLeft=!AmountsLeft!%%J,
if /i not %%K==%1 set AmountsLeft=!AmountsLeft!%%K,
if /i not %%L==%1 set AmountsLeft=!AmountsLeft!%%L,
if /i not %%M==%1 set AmountsLeft=!AmountsLeft!%%M,
if /i not %%N==%1 set AmountsLeft=!AmountsLeft!%%N,
if /i not %%O==%1 set AmountsLeft=!AmountsLeft!%%O,
if /i not %%P==%1 set AmountsLeft=!AmountsLeft!%%P,
if /i not %%Q==%1 set AmountsLeft=!AmountsLeft!%%Q,
if /i not %%R==%1 set AmountsLeft=!AmountsLeft!%%R,
if /i not %%S==%1 set AmountsLeft=!AmountsLeft!%%S,
if /i not %%T==%1 set AmountsLeft=!AmountsLeft!%%T,
if /i not %%U==%1 set AmountsLeft=!AmountsLeft!%%U,
if /i not %%V==%1 set AmountsLeft=!AmountsLeft!%%V,
)
set amountinbox=!FAmount%1!
exit /b
:MakeOffer
set amount=0
for /f "tokens=1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22 delims=," %%A in ("%AmountsLeft%") do (
set /a Offer= !Amount%%A! + !Amount%%B! + !Amount%%C! + !Amount%%D! + !Amount%%E! + !Amount%%F! + !Amount%%G! + !Amount%%H! + !Amount%%I! + !Amount%%J! + !Amount%%K! + !Amount%%L! + !Amount%%M! + !Amount%%N! + !Amount%%O! + !Amount%%P! + !Amount%%Q! + !Amount%%R! + !Amount%%S! + !Amount%%T! + !Amount%%U! + !Amount%%V! + 0
)
set /a Offer= (%Offer%/((%BoxesLeft%*999)/500))/100
cls
echo.
echo ####################################
echo ## ##
echo ## ############################ ##
echo ###### ## ## ######
echo ######################
echo ####### #######
echo ##### #####
echo #### ####
echo #### ####
echo ##### #####
echo ####### #######
echo ##########################
echo ############################
echo ##############################
echo ################################
echo.
echo.
echo The Banker Offers: $%Offer%
echo.
echo.
echo DEAL OR NO DEAL?
:DealOrNoDeal
set deal=
set /p Deal=" "
if not defined Deal goto DealOrNoDeal
if /i %Deal:~0,1%==d echo.&& Goto Deal_Taken
if /i %Deal:~0,1%==N (exit /b) else (goto :DealOrNoDeal)
:Display
echo/ %displayline1:#=!%
echo/ %displayline2:#=!%
echo/ %displayline3:#=!%
echo/ %displayline4:#=!%
echo/ %displayline5:#=!%
echo/ %displayline6:#=!%
echo/ %displayline7:#=!%
echo/ %displayline8:#=!%
echo/ %displayline9:#=!%
echo/ %displayline10:#=!%
echo/ %displayline11:#=!%
echo/ %displayline12:#=!%
echo/ %displayline13:#=!%
echo/ %displayline14:#=!%
echo/ %displayline15:#=!%
echo/ %displayline16:#=!%
echo/ %displayline17:#=!%
echo/ %displayline18:#=!%
echo/ %displayline19:#=!%
echo/ %displayline20:#=!%
echo/ %displayline21:#=!%
echo/ %displayline22:#=!%
echo/ %displayline23:#=!%
echo/ %displayline24:#=!%
exit /b
:SwapOrNot
cls
echo.
echo ####################################
echo ## ##
echo ## ############################ ##
echo ###### ## ## ######
echo ######################
echo ####### #######
echo ##### #####
echo #### ####
echo #### ####
echo ##### #####
echo ####### #######
echo ##########################
echo ############################
echo ##############################
echo ################################
echo.
echo.
echo The Banker Has Offered You The Swap
echo.
echo.
echo SWAP OR NO SWAP?
:SwapOrNoSwap
set swap=
set /p Swap=" "
if not defined Swap goto SwapOrNoSwap
if /i %Swap:~0,1%==S echo.&& goto Swap_Taken
if /i %Swap:~0,1%==N (echo.&& goto Swap_Not_Taken) else (goto SwapOrNoSwap)
:Swap_Not_Taken
for /f "tokens=1,2 delims=," %%I in ("%AmountsLeft%") do if /i "%%I"=="!Box%OwnBox%!" (set Offer=!Amount%%I!& set OtherBox=%%J& Set OwnBox=%%I) else (set offer=!Amount%%J!& set OtherBox=%%I&& Set OwnBox=%%J)
if /i %offer% lss 100 set offer=0.%offer%&& goto SwapResult
set /a offer= %offer% / 100
if /i %Offer% geq 35000 call :bigWin
goto SwapResult
:Swap_Taken
for /f "tokens=1,2 delims=," %%I in ("%AmountsLeft%") do if /i "%%I"=="!Box%OwnBox%!" (set Offer=!Amount%%J!& set OtherBox=%%I& Set OwnBox=%%J) else (set offer=!Amount%%I!& set OtherBox=%%J& Set OwnBox=%%I)
if /i %offer% lss 100 set offer=0.%offer%&& goto SwapResult
set /a offer= %offer% / 100
if /i %Offer% geq 35000 call :bigWin
:SwapResult
if /i %OwnBox% gtr %Otherbox% (
Echo You took the chance and won :D Well done
) else (
echo Hard luck, you got the smaller prize.
)
echo You won $%Offer% :)
pause>nul
goto endofgame
:Deal_Taken
set dealdone=1
if /i %Offer% geq 35000 call :bigWin
if /i %offer% lss 100 (
set Newoffer=0.%offer%
) else (
set Newoffer=%offer%
)
set temp=!Box%ownbox%!
if /i !Amount%temp%! lss 100 (
set Newtemp=0.!Amount%temp%!
) Else (
set /a Newtemp= !Amount%temp%! / 100
)
if /i %newtemp:.=% gtr %offer% (
echo Hard luck, in your box there was $%newtemp%, but you dealed at $%Newoffer%
)
if /i %newtemp:.=% lss %offer% (
echo Well done, you beat the banker :D
echo Your box was worth $%newtemp% but you sold it for $%NewOffer%
)
if /i %newtemp:.=% equ %offer% (
echo You managed to sell your box for exactly what it was worth, well done :D
echo You won $%NewOffer% :)
)
pause >nul
goto EndOfGame
:BigWin
cls
echo #######################################################
echo # #
echo # #
echo # @ @ @ @ @ @ @ @@@@ @@@@ @ #
echo # @ @ @ @@ @ @@ @ @ @ @ @ #
echo # @ @ @ @ @ @ @ @ @ @ @ @ @ #
echo # @ @ @ @ @ @ @ @ @ @ @@@ @@@ @ #
echo # @ @ @ @ @ @ @ @ @ @ @ @ @ @ @ #
echo # @ @ @ @ @ @ @ @ @ @ @ @ @ @ #
echo # @ @ @ @ @@ @ @@ @@@@ @ @ @ #
echo # #
echo # #
echo #######################################################
echo.
echo.
exit /b
:endOfGameexit /b
Test:
@echo off
color 0d
title test
echo this is a test, do you like the test?
echo.
echo yes
echo no
echo.
set /p input=
if %input%== yes goto yup
if %input%== no goto nope
:yup
cls
title yup
echo it works!
pause
Exit
:nope
cls
echo nope, well you probably didn't get here!
pause
exitSplat the Rat::: Originally created by ScrewTheLotOfYou:: Edit, send and reproduce all you like@echo offif /i "%1"=="Attrib" (goto checkhighscore.txt)if /i "%1"=="Countermode" (goto countermode)title Splat-The-Ratsetlocal enabledelayedexpansionfor %%I in (%0) do set filename=%%~sIif exist highscore.txt (start /MIN CMD.exe /c "%FILENAME% Attrib")if exist info.dat del info.dat:menutitle Splat-The-Ratclsecho Main Menuecho ---------echo.echo To play a game, enter 1echo For instructions, enter 2echo For Highscores, enter 3echo To exit, enter 4set menu=set /p menu=""if not defined menu goto menuif %menu%==1 (goto startgame)if %menu%==2 (goto instructions)if %menu%==3 (goto Displayscores)if %menu%==4 (exit /b)goto menu:checkhighscore.txtattrib highscore.txt | find "SHR" >nulif %errorlevel%==0 (exit)attrib highscore.txt +S +H +Rexit:instructionsclsecho Splat The Ratecho -------------echo The aim of the game is to hit the rat with your club as soon as itecho pops out of its hole. You can try hitting the ratecho with the quickest reaction time, or hit as many rats in a row asecho possible. Your score is recorded in the same directory as the gameecho file.echo.echo.echo Press any key for the next pagepause>nulclsecho Splat The Ratecho -------------echo As soon as you start the game one extra window will appear, titledecho 'Rat Window' this window shows the activity of the rat. As soon as echo the window appears it should be dragged away from the original echo Bat Window to allow you to see both. You should then click on theecho Bat Window to allow you to use your bat.echo.echo.echo Press any key for the next pagepause>nulclsecho Splat The Ratecho -------------echo To hit the rat, have the Bat Window selected, and press any key as soonecho as you see the rat appear on the Rat Window.echo.echo.echo Press any key to go to the main menu.pause>nulgoto menu:displayscoresclsif not exist highscore.txt (echo No high scores yet.echo.echo Press any key to return to menupause>nulgoto menu)find /i "Fastest-Single-Reaction=" Highscore.txt >nulset count=%errorlevel%find /i "Most-Rats-Hit=" Highscore.txt >nulset /a count= %count% + %errorlevel%find /i "Best-Average-Reaction=" Highscore.txt >nulset /a count= %count% + %errorlevel%if %count%==3 (echo High Score File Incorrectecho.echo Press any key to return to menupause>nulgoto menu)echo High Scoresecho -----------echo.type highscore.txt | find /i "fastest-Single-Reaction"type highscore.txt | find /i "Most-Rats-Hit"type highscore.txt | find /i "Best-Average-Reaction"echo.echo.echo Press any key to return to menupause>nulgoto menu:startgametitle Bat Windowclsset fastestreaction=999set SN=0set totalmil=0set offset=10echo nul >info.datstart cmd /c "%filename% Countermode"Echo Move the Rat window so you can see both windows, then clickecho this window.echo.echo Press any key to begin the gamepause>nulecho START >info.datclsecho Press Any Key To Swing Your Bat!Pause>nulset swingtime=%time:~2%echo Y%SN%-%swingtime% >>info.dat:resultfind /i "w%SN%" info.dat >nulif %errorlevel%==0 (clsset /a sn= %SN% + 1goto Swingagain)find /i "l" info.dat >nulif %errorlevel%==0 (clsecho Game Overgoto gotresult)goto result:swingagainecho Good Hitif %sn%==1 (echo Got 1 rat so far) else (echo Got %sn% rats so far):processreactiontimeif %sn% geq 11 set offset=11if %sn% geq 101 set offset=12set x=1for /f %%A in (info.dat) do set data=%%A & call :Setswingtimeset x=1for /f %%A in (info.dat) do set data=%%A & call :Setfalltimeset /a CFN= ( %sn% * 3 ) - 1set /a CSN= %sn% * 3set truefalltime=!falltime%CFN%!set truefalltime=!truefalltime:~%offset%,2!set trueswingtime=!swingtime%CSN%!set trueswingtime=!trueswingtime:~%offset%,2!if /i %trueswingtime%==08 (set trueswingtime=8)if /i %trueswingtime%==09 (set trueswingtime=9)if /i %truefalltime%==08 (set truefalltime=8)if /i %truefalltime%==09 (set truefalltime=9)set /a reactionmil= %trueswingtime% - %truefalltime%if /i %reactionmil% lss 0 (set /a reactionmil= %reactionmil% + 100)if /i %reactionmil% leq 9 (echo Your reaction time was 0.0%reactionmil% Seconds) else (echo Your reaction time was 0.%reactionmil% Seconds)goto continueswingagain:setswingtimeset Swingtime%x%=%data%set /a x= %x% + 1exit /b:setfalltimeset falltime%x%=%data%set /a x= %x% + 1exit /b:continueswingagainecho.echo Press Any Key To Swing Your Batpause>nulset swingtime=%time:~2%echo Y%SN%-%swingtime% >>info.datset /a totalmil= %totalmil% + %reactionmil%if not defined fastestreaction (set fastestreaction=%reactionmil%)if /i %fastestreaction% gtr %reactionmil% (set fastestreaction=%reactionmil%)goto result:Gotresultif %sn% equ 0 (echo Sorry, you didn't get any ratsgoto moreresults)if %sn% equ 1 (echo Sorry, you only got one ratgoto Moreresults)if /i %sn% leq 3 (echo Sorry, you only got %sn% rats) else (echo Well done, you got %sn% rats):moreresultsfind /i info.dat "LL" >nulif /i %errorlevel% equ 0 (Echo On that last one, you were too slow, he got away.) else (echo On that last one, you swung too soon.)IF %sn%==0 goto end:processratsset /a averagetime= %totalmil% / %sn%echo You got %sn% ratsecho Your average reaction time was 0.%averagetime% secondsif /i %fastestreaction% leq 9 (echo Your reaction time was 0.0%fastestreaction% Seconds) else (echo Your reaction time was 0.%fastestreaction% Seconds)if not exist highscore.txt goto noscorelistgoto scorelistexists:noscorelistset most=1set best=1set fastest=1goto changescore:scorelistexistsset most=set fastest=set best=find /i "Most-Rats-Hit" Highscore.txt >nulif /i NOT %errorlevel% equ 0 (set Most=1)find /i "Fastest-Single-Reaction" Highscore.txt >nulif /i NOT %errorlevel% equ 0 (set Fastest=1)find /i "Best-Average-reaction" Highscore.txt >nulif /i NOT %errorlevel% equ 0 (set Best=1)goto Mustcompare:Mustcomparefor /f %%A in (highscore.txt) do set data=%%A & call :RHsetset sorted=for /f %%A in (highscore.txt) do set data=%%A & call :BAsetset sorted=for /f %%A in (highscore.txt) do set data=%%A & call :FRsetset sorted=set oldRH=%oldRH:~20%set oldBA=%oldBA:~30,2%set oldFR=%oldFR:~32,2%goto comparetime:rhsetset variable=OldRHset keyword=Mostcall :sortvariablesexit /b:basetset variable=OldBAset keyword=Bestcall :sortvariablesexit /b:frsetset variable=OldFRset keyword=Fastestcall :sortvariablesexit /b:sortvariablesif defined sorted (goto endsortvariables)set %variable%=%data%echo !%variable%! | find /i "%keyword%" >nulif NOT errorlevel 1 (set sorted=1) else (set %variable%=):endsortvariablesexit /b:comparetimeif defined fastest goto alreadyfastestif /i %fastestreaction% lss %oldfr% (set fastest=1):alreadyfastestif defined Most goto alreadymostif /i %oldRH% lss %SN% (set Most=1):alreadymostif defined best goto alreadybestif /i %averagetime% lss %OldBA% (set Best=1):alreadybestif defined best goto Changescoreif defined most goto Changescoreif defined fastest goto Changescoregoto end:changescoreecho.Echo New High Score!echo ---------------echo New Score In:echo.if defined most (echo Most Rats Hit)if defined best (echo Best Average Time)if defined fastest (echo Fastest Single Reaction)echo.set initials=echo Please Enter Your Initials (3 Characters Maximum)set /p initials=""IF NOT defined initials (clsgoto changescore)if "%initials:~1%"=="" (set initials=%initials%--)if "%initials:~2%"=="" (set initials=%initials%-)set initials=%initials:~0,3%if defined most goto editmostgoto checkeditbest:editmostif /i %fastestreaction% leq 9 (set fastestreaction=0%fastestreaction%)if exist highscore.txt (type highscore.txt | find /i /v "most-rats-hit" >Highscoreattrib highscore.txt -s -h -rtype highscore >Highscore.txtattrib highscore.txt +s +h +rdel highscoreattrib highscore.txt -s -h -recho %initials%---Most-Rats-Hit=%sn% >>Highscore.txtattrib highscore.txt +s +h +r) else (echo %initials%---Most-Rats-Hit=%sn% >>Highscore.txtattrib highscore.txt +s +h +r):checkeditbestif defined best goto editbestgoto checkeditfastest:editbestif exist highscore.txt (type highscore.txt | find /i /v "best-average-reaction" >Highscoreattrib highscore.txt -s -h -rtype highscore >Highscore.txtattrib highscore.txt +s +h +rdel highscoreattrib highscore.txt -s -h -recho %initials%---Best-Average-Reaction=0.%averagetime% >>Highscore.txtattrib highscore.txt +s +h +r) else (echo %initials%---Best-Average-Reaction=0.%averagetime% >>Highscore.txtattrib highscore.txt +s +h +r):checkeditfastestif defined fastest goto editfastestgoto scoresedited:editfastestif exist highscore.txt (type highscore.txt | find /i /v "Fastest-Single-Reaction" >Highscoreattrib highscore.txt -s -h -rtype highscore >Highscore.txtattrib highscore.txt +s +h +rdel highscoreattrib highscore.txt -s -h -recho %initials%---Fastest-Single-Reaction=0.%fastestreaction% >>Highscore.txtattrib highscore.txt +s +h +r) else (echo %initials%---Fastest-Single-Reaction=0.%fastestreaction% >>Highscore.txtattrib highscore.txt +s +h +r):Scoreseditedecho Scores Savedecho.goto end:enddel info.datpause>nul:playagainecho Go to menu? (Y/N):playagain1set choice=set /p choice=""if /i "%choice:~0,1%"=="Y" (goto menu)if /i "%choice:~0,1%"=="N" (exit /b)goto playagain::###################################################################:COUNTERMODE@echo offcolor f0title Rat Windowsetlocal enabledelayedexpansionecho Move this window so you can see both windows.echo Have the Bat window selected and press any key to begin the game:waittostarttype info.dat | find /i "start" >nulif %errorlevel%==0 (goto TimeTostart) else (goto waittostart):TimeToStartset time%time:~2%echo X%timestart% >info.datset SN=-1set w=0clsgoto timesetup:1find info.dat "Y%sn%" >nulif %errorlevel%==0 goto stopif /i %time:~6,2% equ %timechange% goto ShowRatgoto noRats:ShowRatset ztime%sn%=Z%sn%-%time:~2%clscall :showratset w=1set timechange=CHANGE_DONEecho !ztime%sn%! >>info.dat:noRatsif /i %time:~6,2% equ %timeback% (clscall :noratecho.echo You missed the rat!echo Swing your bat to end the game.set w=0set timeback=CHANGE_DONEset L=L)goto 1:STOPif /i %w%==1 (echo W%sn% >>info.dat) else (echo L%L% >>info.datexit /b):Timesetupclscall :noratset w=0set /a sn= %sn% + 1set time%time:~2%set timechange=%timestart:~4,2%if /i %timechange% equ 08 (set timechange=8)if /i %timechange% equ 09 (set timechange=9)set /a timechange= %timechange% + 2 + %random:~1,1%if %timechange% geq 60 (set /a timechange= %timechange% - 60)set /a timeback= %timechange% + 1if %timeback% geq 60 (set /a timeback=%timeback% - 60)if /i %timechange% equ 8 (set timechange=08)if /i %timechange% equ 9 (set timechange=09)if /i %timeback% equ 8 (set timeback=08)if /i %timeback% equ 9 (set timeback=09)goto 1:NORATecho __ __ __ __ __ __ __ __ __ echo [__][__][__][__][__][__][__][__][__]echo _][__][__][__][__][__][__][__][__][_echo [__][__][__][__][__][__][__][__][__]echo _][__][__][__][__][__][__][__][__][_echo [__][__][__][__][__][__][__][__][__]echo _][__][__][__][__][__][__][__][__][_echo [__][__][__][__][__][__][__][__][__]echo ____________________________________exit /b:showratecho __ __ __ __ __ __ __ __ __ echo [__][__][__][__][__][__][__][__][__]echo _][__][__][__][__][__][__][__][__][_echo [__][__][__] __ __ _][__][__][__]echo _][__][__] (_.)__(._) __][__][__][_echo [__][__][__] (- -) _][__][__][__]echo _][__][__][ --{()}-- [__][__][__][_echo [__][__][__] (____) _][__][__][__]echo ______________''__''________________exit /bMine::main::ScrewTheLotOfYou's Minesweeper, written by ScrewTheLotOfYou, November 2010. @echo off setlocal enabledelayedexpansion title ScrewTheLotOfYou's Minesweeper call :userInterface if "!exit!"=="true" exit /b echo. echo Loading grid... call :setupGrid echo Loading display variables... call :setupDisplayVariables echo Laying mines... call :setupMines call :gameLoop goto mainexit /b:userInterface::A function to provide the main menu for the player. ::Clears the screen and gives the player the options. cls echo 1. Play a game with begginer difficulty echo 2. Play a game with intermediate difficulty echo 3. Play a game with advanced difficulty echo 4. Play a game with custom difficulty echo 5. Exit echo. echo. ::Clears the menuChoice and requests the player's input. set menuChoice= set /p menuChoice="Enter the number of your choice - " ::The following IF statements check the player's input, setting the appropriate difficultly level and the ::right amount of space between the edge of the screen and the start of the board. if "!menuChoice!"=="1" ( set difficulty=begginer set displaySpacer= exit /b ) if "!menuChoice!"=="2" ( set difficulty=intermediate set displaySpacer= exit /b ) if "!menuChoice!"=="3" ( set difficulty=advanced set displaySpacer= echo. echo To view the advanced game properly the window must be resized. Right click the echo CMD icon at the top left of the window, click properties and on the LAYOUT tab, echo change the width to a minimum of 95. echo Press enter once changed to refresh the display. echo. pause exit /b ) if "!menuChoice!"=="4" ( cls call :getCustomDimensions exit /b ) if "!menuChoice!"=="5" ( set exit=true exit /b )goto userInterface:getCustomDimensions::A function to recieve custom dimensions from the user and check they are within sensible limits. set /p xDimension="Enter the width [1-30] - " if !xDimension! gtr 30 ( echo The maximum width is 30. goto getCustomDimensions ) if !xDimension! lss 1 ( echo The minimum width is 1. goto getCustomDimensions ) echo. set /p yDimension="Enter the height [1-30] - " if !yDimension! gtr 30 ( echo The maximum height is 30. goto getCustomDimensions ) if !yDimension! lss 1 ( echo The minimum height is 1. goto getCustomDimensions ) ::The maximum number of mines is 80% of the squares on the grid. ::The practical maximum number of mines (before causing stack overflow) is 499. echo. set /a maxMines= !xDimension! * !yDimension! - !xDimension! * !yDimension! / 5 if /i %maxMines% geq 500 ( set maxMines=499 ) ::The practical minimum number of mines is 1. The minimum for a given board is 1/12th of the ::total number of squares on the grid. This prevents stack overflow on the largest grids. set /a minMines= 1 + !xDimension! * !yDimension! / 12 if /i maxMines geq 500 ( set maxMines=499 ) set /p mineCount="Enter the number of mines [%minMines%-%maxMines%] - " if !mineCount! lss %minMines% ( echo The minimum number of mines is %minMines%. goto getCustomDimensions ) if !mineCount! gtr %maxMines% ( echo The maximum number of mines for this board size is %maxMines%. goto getCustomDimensions ) ::The space between the edge of the screen and the start of the board is adjusted depending on the size of the board. ::This just makes it look more central. if !xDimension! leq 10 ( set displaySpacer= ) else ( if !xDimension! leq 17 ( set displaySpacer= ) else ( if !xDimension! leq 22 ( set displaySpacer= ) else ( set displaySpacer= if !xDimension! gtr 24 ( echo To view large games properly the window must be resized. Right click the echo CMD icon at the top left of the window, click properties and on the LAYOUT tab, echo change the width. A width of 95 will encorporate all possible game sizes. echo Press enter once changed to refresh the display. echo. pause ) ) ) ) ::Sets the difficulty variable. set difficulty=customexit /b:setupGrid::Sets up the display grid to the correct dimensions, each position on the grid initally containing just a space.::Variables in the 'D_Grid' (display grid) have the format DX_Y where X and Y are coordinates along the X and Y axes respectively. ::Sets the appropriate dimensions and number of mines to lay based on the difficulty. if "%difficulty%"=="begginer" ( set xDimension=9 set yDimension=9 set mineCount=10 ) if "%difficulty%"=="intermediate" ( set xDimension=16 set yDimension=16 set mineCount=40 ) if "%difficulty%"=="advanced" ( set xDimension=30 set yDimension=16 set mineCount=99 ) ::The number of mine 'flags' placed by the player is zero at the start of the game. set flaggedCount=0 ::Ensures the list of flagged coordinates is empty. set flaggedCoordinateList= ::Ensures the finalOutcome variable is undefined, it is defined only when a player wins or loses. set finalOutcome= ::Creates two grids of the appropriate dimensions. The D_grid is the grid displayed to the user, the G_grid is the grid containing all the mines and numbers. for /l %%I in (1,1,%xDimension%) do ( for /l %%J in (1,1,%yDimension%) do ( set D%%I_%%J= set G%%I_%%J=0 ) )exit /b:setupDisplayVariables::Creates a number of variables corresponding to the number of rows in the grid.::Each variable contains the variable names of all the display grid locations on that row, each surround by percentage signs.::This allows easy display of the grid, because 'CALL ECHO'ing these variables displays the value of all the display grid loactions on that row.::Doing it this way means each line of display doesn't have to be generated every time the board is displayed. ::Sets pipe to the pipe character, this is just to draw the grid around the numbers. set pipe=^^^| ::First section of this for command is just placing the y coordinate and a couple of spaces at the start of each display line, forming the 'y axis label'. ::If the number is single digit (i.e. less than 10) one extra space is put in so everything lines up. ::The second bit builds the rest of the line by simply adding each grid entry one by one, surrounded by pipe characters to give a grid-look. for /l %%I in (1, 1, %yDimension%) do ( if %%I lss 10 ( set displayLine%%I=%%I ) else ( set displayLine%%I=%%I ) for /l %%J in (1, 1, %xDimension%) do ( set displayLine%%I=!displayLine%%I!%%pipe%%%%D%%J_%%I%%%%pipe%% ) ) ::This for look is devoted to setting up the x axis label line. ::It starts off with an x and a couple of spaces, then just writes each number underneath the corresponding line on the grid. ::No need for the fancy delayed-expansion of the variables using %% or CALL ECHO, this line is fixed and won't change. ::Once again the number of spaces after each number is dictated by whether the number is one- or two-digit to keep it all in line. set displayLineBottom= x set rowDivider= for /l %%J in (1, 1, %xDimension%) do ( if %%J lss 10 ( set displayLineBottom=!displayLineBottom!%%J ) else ( set displayLineBottom=!displayLineBottom!%%J ) set rowDivider=!rowDivider!- )exit /b:setupMines::Lays the number of mines appropriate for this difficulty level. set minesToPlant=%mineCount% set mineCoOrdinateList= ::Calculates a random position on the G_grid (game grid, containing all the mines and numbers), ::Sets Gcurrent to the value of the G_grid at these coordinates. ::Checks a mine has not already been planted here (it will have value 'MINE' if a mine has already been planted at this location). ::If the location has already been planted, add 1 to the failedMineCount. ::If the space has not already been planted, set that G_grid value to 'MINE' and call the updateG_grid function :layMines set failedMineCount=0 for /l %%I in (1,1,%minesToPlant%) do ( set /a xMine= 1 + !random! %% %xDimension% set /a yMine= 1 + !random! %% %yDimension% call set Gcurrent=%%G!xMine!_!yMine!%% if NOT "!Gcurrent!" == "MINE" ( set G!xMine!_!yMine!=MINE set F!xMine!_!yMine!=* set mineCoOrdinateList=!mineCoOrdinateList!!xMine!_!yMine!, call :updateG_grid !xMine! !yMine! ) else ( set /a failedMineCount= !failedMineCount! + 1 ) ) ::Calls layMines again if any mines failed to plant, specifying that minesToPlant is the number of failed mines. if NOT %failedMineCount%==0 ( set minesToPlant=%failedMineCount% goto layMines )exit /b:updateG_grid::A function to update the values of the G_grid when a mine is planted, so all the sqaures around it show the correct number.::Each time a mine is planted, this function is called. All the sqaures adjacent to the mine, assuming they are not mines, have their G-grid value increased by 1.::When all the mines are laid, the value of the G_grid for each square contains the number of adjacent mines, which is how minesweeper works. ::These 8 pairs x and y values correspond to the 8 ADJacent squares. set /a adj1X=%1 + 1 set /a adj1y=%2 + 1 set /a adj2X=%1 set /a adj2y=%2 + 1 set /a adj3X=%1 - 1 set /a adj3y=%2 + 1 set /a adj4X=%1 + 1 set /a adj4y=%2 - 1 set /a adj5X=%1 set /a adj5y=%2 - 1 set /a adj6X=%1 - 1 set /a adj6y=%2 - 1 set /a adj7X=%1 + 1 set /a adj7y=%2 set /a adj8X=%1 - 1 set /a adj8y=%2 ::This FOR command cycles through the eight ADJacent squares, and, if they are not mines, increases their G_grid value by 1. for /l %%I in (1,1,8) do ( call set squareValue=%%G!adj%%IX!_!adj%%Iy!%% if NOT "!squareValue!"=="MINE" ( set /a G!adj%%IX!_!adj%%Iy!= !squareValue! + 1 ) )exit /b:gameLoop::A function to recieve user input, evaluate it, adjust the necessary grids. Repreats until game is won or lost. ::Displays the board. call :displayBoard ::ECHOs the infoMessage. This is only defined if the user's input was invalid. Otherwise this is just an empty line. echo.%infoMessage% echo Flagged %flaggedCount%/%mineCount% echo. set infoMessage= ::Clears the input variable, then requests the user's input. set input= set /p input="Enter your move or type HELP for help [x y [*]] - " ::Gives help if the user typed help. if /i "!input!"=="help" ( echo To reveal a square with coordinates x,y type: x y echo To flag a sqaure with coordinates x,y as a mine, type: x y * echo To unflag a square that has already been flagged with coordinates x,y just type: x y * echo Type EXIT to end the game immediately. pause goto gameLoop ) if /i "!input!"=="exit" ( exit /b ) ::Checks the input is valid, in the format "x y". ::The FOR command splits up the user's input into three parts, the x, the y and the *. The * may or may not have been entered. ::Checks that each x and y coordinate is within the bounds of the grid size. ::Checks if the * is present. If so, calls flagSquare, else calls revealSquare. for /f "tokens=1,2,3 delims=-, " %%I in ("!input!") do ( if NOT %%I leq %xDimension% ( set infoMessage=Input must be in the form "x y" where x is a number from 1 to %xDimension%. goto gameLoop ) if NOT %%I gtr 0 ( set infoMessage=Input must be in the form "x y" where x is a number from 1 to %xDimension%. goto gameLoop ) if NOT %%J gtr 0 ( set infoMessage=Input must be in the form "x y" where y is a number from 1 to %yDimension%. goto gameLoop ) if NOT %%J leq %yDimension% ( set infoMessage=Input must be in the form "x y" where y is a number from 1 to %yDimension%. goto gameLoop ) if NOT "%%K"=="" ( if NOT "%%K"=="*" ( set infoMessage=Input must be in the form "x y" or "x y *". goto gameLoop ) else ( call :flagSquare %%I %%J ) ) else ( call :revealSquare %%I %%J ) ) ::If the flagging of the or the revealing of the square resulted in a win or lose, exit this function. if defined finalOutcome ( exit /b ) ::Otherwise, loop round again for another turn. goto gameLoop:displayBoard::A function to clear the screen then display the updated board. 'CALL ECHO's the variables set up in the setupDisplayVariables function. cls for /l %%I in (%yDimension%, -1, 1) do ( echo.%displaySpacer%%rowDivider% call echo.%displaySpacer%!displayLine%%I! ) echo.%displaySpacer%y echo.%displaySpacer%%displayLineBottom% echo.exit /b:revealSquare::Recieves the arguments %1=x and %2=y::A function to reveal a square. ::Checks if the mine is flagged as a mine, if so, does not reveal it. ::Otherwise checks if the square is a mine, if so asserts LOSE. ::Else just sets the D_grid display variable to the previously hidden G_grid value. ::If the square was a zero, calls the revealZeros function. if NOT "!D%1_%2!"=="*" ( if "!G%1_%2!"=="MINE" ( set finalOutcome=LOSE call :generateLoseGrid ) else ( if "!G%1_%2!"=="0" ( set adjacentZeroList=%1_%2, call :revealZeros %1 %2 ) else ( set D%1_%2=!G%1_%2! ) ) ) else ( set infoMessage=That square is flagged as a mine! To reveal it, unflag it first. )exit /b :revealZeros ::A function to reveal the G_grid values of all the squares around a zero. If another zero is found, repeat this funtion for that square. ::Sets the display grid value of the zero-value square to zero. set D%1_%2=0 ::These 8 pairs x and y values correspond to the 8 ADJacent squares. set /a adj1X=%1 + 1 set /a adj1y=%2 + 1 set /a adj2X=%1 set /a adj2y=%2 + 1 set /a adj3X=%1 - 1 set /a adj3y=%2 + 1 set /a adj4X=%1 + 1 set /a adj4y=%2 - 1 set /a adj5X=%1 set /a adj5y=%2 - 1 set /a adj6X=%1 - 1 set /a adj6y=%2 - 1 set /a adj7X=%1 + 1 set /a adj7y=%2 set /a adj8X=%1 - 1 set /a adj8y=%2 ::This FOR loop retrieves the G_grid and D_grid values of each of the adjacent squares. ::If the D_grid is *, the square has been flagged by the player and is not altered ::If the G_grid is zero, that square is added to the adjacentZeroList so that this function is repeated for that square. ::Otherwise the G_grid value for the square is revealed in the D_grid. for /l %%I in (1,1,8) do ( call set Gadj=%%G!adj%%Ix!_!adj%%Iy!%% call set Dadj=%%D!adj%%Ix!_!adj%%Iy!%% if NOT "!Dadj!"=="*" ( if "!Gadj!"=="0" ( if NOT "!Dadj!"=="0" ( set adjacentZeroList=!adjacentZeroList!!adj%%Ix!_!adj%%Iy!, ) ) else ( set D!adj%%Ix!_!adj%%Iy!=!Gadj! ) ) ) ::Remove the square that has just been processed from the list of squares due for processing. set adjacentZeroList=!adjacentZeroList:%1_%2,=! ::Call the revealZeros function on the next adjacent zero in the list. If the list is empty this FOR command will do nothing. for /f "tokens=1,2 delims=,_" %%I in ("!adjacentZeroList!") do ( call :revealZeros %%I %%J ) exit /b:flagSquare ::A function to flag or unflag a square. ::Recieves the arguments %1=x and %2=y ::If the square is unmarked and unrevealed, simply mark the square as a mine, increment the flaggedCount and add its coordinates ::to the flaggedCoordinateList. ::If the mine is already flagged with a *, unflag the mine and decrement the flaggedCount. ::Otherwise the square has already been revealed and cannot be flagged. if "!D%1_%2!"==" " ( set D%1_%2=* set /a flaggedCount+=1 set flaggedCoordinateList=!flaggedCoordinateList!%1_%2, ) else ( if "!D%1_%2!"=="*" ( set D%1_%2= set /a flaggedCount-=1 REM :: Remove the square being unflagged from the flaggedCoOrdinateList variable. set flaggedCoOrdinateList=!flaggedCoOrdinateList:%1_%2,=! ) else ( set infoMessage=That square can't be flagged, it is already revealed. ) ) ::The player is notified if too many mines have been flagged. if %flaggedCount% gtr %mineCount% ( set infoMessage=You have flagged too many mines; not all are correct. To remove a flag, type "x y *" for an already flagged square. ) ::If the flaggedCount is equal to the number of mines planted, the solution must be checked to see if it is correct. if %flaggedCount%==%mineCount% ( call :checkSolution !flaggedCoordinateList! )exit /b:checkSolution::A function to check if all the mines flagged by the player are correct.::This function is only called when exactly the right number of mines are flagged.::Receives argument %* containing flaggedCoOrdinateList ::Sets the number of flags verified to be correct to 0 and calls the checkSolutionLoop, passing the flaggedCoOrdinateList (%*) set correctFlags=0 call :checkSolutionLoop %* ::If the player has flagged all mines correctly, the number of correct flags is equal to the number of mines originally planted. if "%correctFlags%"=="%mineCount%" ( set finalOutCome=WIN echo Congratulations you've identified all the mines^^^! pause )exit /b :checkSolutionLoop ::A function to increment the correctFlags variable every time a flag turns out to be correct. Execution stops if an incorrect mine is found. ::Receives argument %* containing a list of flagged coordinates that haven't been checked yet. ::Only called by checkSolution. ::This FOR /F command takes the first element of the list of flagged coordinates passed as an argument ::and checks that the flagging is correct i.e. the G-grid value is MINE. ::If the flag was correct, the correctFlags variable is incremented and the loop is called again with the remaining elements of the list. ::If the flag was incorrect, the loop sets the infoMessage and exits. for /f "tokens=1* delims=," %%I in ("%*") do ( if "!G%%I!"=="MINE" ( set /a correctFlags= !correctFlags! + 1 call :checkSolutionLoop %%J ) else ( set infoMessage=All flagged squares aren't correct! To remove a flag, type "x y *" for an already flagged square. ) ) exit /b:generateLoseGrid::A function to set up the final grid shown to the player. This function is only called after the player has lost.::The lose grid is just a moified D_grid (display grid).::The only changes made are that unflagged mines are marked with ! and incorrectly flagged are marked as X. ::Sets excl to the exclamation mark character, for use in marking the unflaggedMines. set excl=^^^! call :markIncorrectFlagLoop !flaggedCoordinateList! call :markUnflaggedMinesLoop !mineCoordinateList! call :displayBoard echo. echo Sorry you lost the game!excl! The board above shows unidentified mines as !excl! and incorrectly flagged mines as X. pauseexit /b :markIncorrectFlagLoop ::A function to change incorrect flags with a ! correct flags are left as *. ::Argument %* contains the list of flagged coordinates. ::Only called by generateLoseGrid. for /f "tokens=1* delims=," %%I in ("%*") do ( if NOT "!G%%I!"=="MINE" ( set D%%I=X ) call :markIncorrectFlagLoop %%J ) exit /b :markUnflaggedMinesLoop ::A function to change incorrect flags with a ! correct flags are left as *. ::Argument %* contains the list of flagged coordinates ::Only called by generateLoseGrid. for /f "tokens=1* delims=," %%I in ("%*") do ( if NOT "!D%%I!"=="*" ( set D%%I=!excl! ) call :markUnflaggedMinesLoop %%J ) exit /b
Noughts and Crosses:
@echo off
setlocal enabledelayedexpansion
title ScrewTheLotOfYou's Noughts and crosses 2
:main
call :titleScreen
if "%EXIT%"=="1" exit /b
call :firstSetup
:main_Loop
call :resetBoard
call :gameLoop
call :endGameScreen %win%
if /i %rematch%==Y (
goto main_Loop
)
exit /b
:titleScreen
echo Welcome to Noughts and Crosses.
echo.
echo.
echo Type EXIT to quit the game.
echo.
:askP1Type
set p1
set /p p1
if /i "!p1Type!"=="C" goto askP2Type
if /i "!p1Type!"=="H" goto askP2Type
if /i "!p1Type!"=="EXIT" (
set EXIT=1
exit /b
)
goto askP1Type
:askP2Type
set p2
set /p p2
if /i "!p2Type!"=="C" exit /b
if /i "!p2Type!"=="H" exit /b
if /i "!p2Type!"=="EXIT" (
set EXIT=1
exit /b
)
goto askP2Type
:firstSetup
set p1Score=0
set p2Score=0
set turn=
set p1Char=X
set p2Char=O
set p1Score=0
set p2Score=0
set NL=^
::winList contains all the possible winning lines, separated by the new line character.
set winList=1 2 3 !NL! 4 5 6 !NL! 7 8 9 !NL! 1 4 7 !NL! 2 5 8 !NL! 3 6 9 !NL! 1 5 9 !NL! 3 5 7
exit /b
:ResetBoard
for /l %%I in (1,1,9) do (
set G%%I=%%I
)
if "%turn%"=="" (
set /a turn=%random% %% 2 + 1
) else (
set /a turn= 3 - %turn%
)
set turnCount=0
set availableMoves=123456789
set errorMessage=
set win=0
exit /b
:gameLoop
set /a otherTurn= 3 - %turn%
if /i "!p%turn%Type!"=="H" (
call :humanTurn
) else (
call :computerTurn %turn% !p%turn%Char! !p%otherTurn%Char!
)
set /a turnCount+=1
set availableMoves=!availableMoves:%move%=!
if NOT %win%==0 exit /b
if %turnCount%==9 exit /b
set /a turn= 3 - %turn%
goto GameLoop
:humanTurn
call :displayGrid
echo.
echo.%infoMessage%
set infoMessage=
set move=
set /p move= Player %turn%'s turn. Enter the number of your move [1-9] -
if !move! lss 1 (
set infoMessage=Invalid move, enter a number between 1 and 9.
goto humanTurn
)
if !move! gtr 9 (
set infoMessage=Invalid move, enter a number between 1 and 9.
goto humanTurn
)
if NOT "!G%Move%!"=="!Move!" (
set infoMessage=That move has already been made, choose another.
goto humanTurn
)
set G%move%=!p%turn%Char!
call :CheckWin %turn% !p%turn%Char!
exit /b
:computerTurn
set move=
for /f "tokens=1-3 delims= " %%I in ("!winList!") do (
if "!G%%I!!G%%J!!G%%K!"=="%2%2%%K" (
set move=%%K
)
if "!G%%I!!G%%J!!G%%K!"=="%2%%J%2" (
set move=%%J
)
if "!G%%I!!G%%J!!G%%K!"=="%%I%2%2" (
set move=%%I
)
if NOT "!move!"=="" (
set G!move!=%2
set win=%1
exit /b
)
)
for /f "tokens=1-3 delims= " %%I in ("!winList!") do (
if "!G%%I!!G%%J!!G%%K!"=="%3%3%%K" (
set move=%%K
)
if "!G%%I!!G%%J!!G%%K!"=="%3%%J%3" (
set move=%%J
)
if "!G%%I!!G%%J!!G%%K!"=="%%I%3%3" (
set move=%%I
)
if NOT "!move!"=="" (
set G!move!=%2
exit /b
)
)
set /a moveGuess= %random% %% ( 9 - %turnCount% )
set move=!availableMoves:~%moveGuess%,1!
set G%move%=!p%turn%Char!
exit /b
:displayGrid
cls
echo.
echo ^| ^|
echo %G1% ^| %G2% ^| %G3%
echo -------------
echo %G4% ^| %G5% ^| %G6%
echo -------------
echo %G7% ^| %G8% ^| %G9%
echo ^| ^|
exit /b
:checkWin
for /f "tokens=1-3 delims= " %%I in ("!winList!") do (
if "!G%%I!!G%%J!!G%%K!"=="%2%2%2" (
set win=%1
exit /b
)
)
set win=0
exit /b
:endGameScreen
if NOT %win%==0 (
set /a p%win%Score+=1
)
call :Displaygrid
echo.
echo.
if %win% gtr 0 (
echo Player %win% wins^!
) else (
echo It's a draw^!
)
echo.
echo.
echo Current Scores
echo --------------
echo Player 1 Score - %p1Score% Player 2 Score - %p2Score%
echo.
set rematch=
set /p rematch="Would you like a rematch? [Y/N] - "
if /i "!rematch!"=="Y" exit /b
if /i "!rematch!"=="N" (
exit /b
) else (
goto endGameScreen
)