기본적으로 저는 세계를 창조 할 수있는 게임을 개발하고 있습니다. 그것은 매우 새롭고 약 30 분 동안 계속 작업 해 왔습니다. 타사 외부 프로그램은 cmdmenusel 및 CHOICE입니다. 바위 장면 (: 바위)에서 펼치기를 클릭하면 빠른 메시지와 충돌합니다. 내 코드에 무엇이 잘못되었는지 보도록 도와 주시겠습니까?: rocks 장면이 잘못되어 충돌합니다. 배치 코드에 어떤 문제가 있습니까?
@echo off
title Develop a World
cd z
:: Not a fully developed program.
:: Do not distribute.
:: (C) Copyright Bextem 2016 - Present
:love
cls
color D
echo There is nothing but love.
cmdMenuSel f870 "Grow"
if %ERRORLEVEL% == 1 goto hope
goto love
:hope
cls
color E
echo There is love and hope.
cmdMenuSel f870 "Grow"
if %ERRORLEVEL% == 1 goto start
goto hope
:start
cls
color F
echo With love and hope, there is a start.
cmdMenuSel f870 "Grow"
if %ERRORLEVEL% == 1 goto rocks
goto start
:rocks
cls
color 8
echo There are rocks in your land.
cmdMenuSel f870 "Grow"
if %ERRORLEVEL% == 1 goto mountain
goto rocks
:mountains
cls
color 8
echo There is a mountain.
echo.
type mountain.txt
echo.
cmdMenuSel f870 "Expand"
if %ERRORLEVEL% == 1 goto manymts
goto mountains
:manymts
cls
color 8
echo There are caves and mountains.
echo.
type mt.txt
cmdMenuSel f870 "Crumble" "Grow"
if %ERRORLEVEL% == 1 goto earth
if %ERRORLEVEL% == 2 goto stone
goto manymts
:stone
echo There is nothing but stone.
echo Press any key to undo your mistake.
pause >nul
goto manymts
:earth
cls
color 6
echo There is dirt and mountains.
cmdMenuSel f870 "Water" "Shine"
if %ERRORLEVEL% == 1 goto earthwater
if %ERRORLEVEL% == 2 goto earthshine
goto earth
:earthwater
cls
color 61
echo There is moist soil and mountains.
cmdMenuSel f870 "Shine" "Water"
if %ERRORLEVEL% == 1 goto earthwatershine
if %ERRORLEVEL% == 2 goto floodearth1
goto earthwater
:earthshine
cls
color 16
echo There is hot soil and mountains.
cmdMenuSel f870 "Water" "Shine"
if %ERRORLEVEL% == 1 goto earthwatershine
if %ERRORLEVEL% == 2 goto droughtearth1
goto earthshine
:floodearth1
cls
color 2
echo Your world has flooded.
echo Press any key to undo your mistake.
pause >nul
goto earthwater
:droughtearth2
cls
color 6
echo The world burns from the sun.
echo Press any key to undo your mistake.
pause >nul
goto earthshine
:earthwatershine
cls
color A2
echo The soil is floroushing.
cmdMenuSel f870 "Grow" "Plant"
if %ERRORLEVEL% == 1 goto dirtpile
goto earthwatershine
:dirtpile
cls
color 6
echo There is a pile of dirt and mountains
echo +1 more.
cmdMenuSel f870 "Grow Dirt" "Grow Mountains" "Inventory"
if %ERRORLEVEL% == 1 goto dirtpilehuge
if %ERRORLEVEL% == 2 goto stone
if %ERRORLEVEL% == 3 goto Inventory
goto dirtpile
:Inventory
echo PLAYER'S INVENTORY (PAGE 1)
echo You have:
echo Loves: %love%
echo Hopes: %hope%
echo Starts: %start%
echo Rocks: %rocks%
echo Mountains: %mountains%
echo Caves: %caves%
echo Soil: %soil%
:startgame
set love=0
set hope=0
set start=0
set rocks=0
set mountain=0
set caves=0
set soil=0
set humans=0
goto love
다음 도움말 항목을 생각하십시오 /stackoverflow.com/help/mcve)! – aschipfl
배치 파일을 디버깅하기위한 힌트 : 배치 파일에서'@echo off'를 제거하고 저장하십시오. 명령 프롬프트 창을 열어 하나 이상의 배치 파일을 실행 한 후 창을 __keep __keep에 띄우려면'/ K' 옵션과 함께 cmd.exe를 시작하고 전체 경로를 큰 따옴표로 묶은 배치 파일의 이름을 입력 한 다음 RETURN을 눌러 실행하십시오. 사전 처리 후에 실행 된 명령 행을 볼 수 있습니다. 또한 일괄 해석 종료를 유발하는 레이블을 찾을 수 없다는 오류 메시지가 표시됩니다. 배치 파일을 더블 클릭하면 결과적으로 __close__에 대해'/ C' 옵션과 함께'cmd.exe'가 실행됩니다. – Mofi