回复 26# bailong360
不要他的框只是要他的内容...
以下是图
我试试看了怎么改不到....有错吗?- @Echo Off 2>nul 3>nul
- setlocal enabledelayedexpansion
- echo.
- Set /P Player1=请输入玩家1姓名:
- Set /P Player2=请输入玩家2姓名:
- echo.
- :Start
- Set /A N+=1
- Set .%N%=
- >nul Set .9||Goto Start
- :Loop
- Set /P Turn=请玩家1 ^<%Player1%^> 落子:
- Set ..%Turn%&&Goto :Eof
- Set .%Turn%=O
- Set ..%Turn%=0
- Set "_%.1%%.2%%.3%=0"
- Set "_%.4%%.5%%.6%=0"
- Set "_%.7%%.8%%.9%=0"
- Set "_%.1%%.4%%.7%=0"
- Set "_%.2%%.5%%.8%=0"
- Set "_%.3%%.6%%.9%=0"
- Set "_%.1%%.5%%.9%=0"
- Set "_%.3%%.5%%.7%=0"
- :begin
- set num=!1!!2!!3!!4!!5!!6!!7!!8!!9!
- set num=%num:~,-1%
- echo player 1 %playerA% move ^<%num%^>:
- set /p t=
- set %t%=
- goto begin2
- goto p
- echo.
- >nul Set _OOO&&(Echo 玩家1 ^<%Player1%^> 胜利&Pause&Goto :Eof)
- Set /P Turn=请玩家2 ^<%Player2%^> 落子:
- Set ..%Turn%&&Goto :Eof
- Set .%Turn%=X
- Set ..%Turn%=0
- Set "_%.1%%.2%%.3%=0"
- Set "_%.4%%.5%%.6%=0"
- Set "_%.7%%.8%%.9%=0"
- Set "_%.1%%.4%%.7%=0"
- Set "_%.2%%.5%%.8%=0"
- Set "_%.3%%.6%%.9%=0"
- Set "_%.1%%.5%%.9%=0"
- Set "_%.3%%.5%%.7%=0"
- :begin2
- set num=!1!!2!!3!!4!!5!!6!!7!!8!!9!
- set num=%num:~,-1%
- echo player 2 %playerB% move ^<%num%^>:
- set /p t=
- set %t%=
- goto begin
- goto p
- >nul Set _XXX&&(Echo 玩家2 ^<%Player2%^> 胜利&Pause&Goto :Eof)
- Goto Loop
- :p
- pause
复制代码
|