1.membuat jam sederhana
*salin teks dibawa ini kenotepad
@echo off
Title praysi
color b
cls
: Clock
cls
echo Current Date: %date%
echo ________________
echo | Waktu berjalan |
echo________________
echo Current Time: %time%
goto Clock
*simpan dengan format bat
2.membuat angka matrix
*salin teks dibawa ini kenotepad
color 02
@echo off
:mat
echo %random%%random%%random%%random%%ramdom%%random%%random%%ramdom%
goto mat
*simpan dengan format bat
3.membuat kuis
*salin teks dibawa ini kenotepad
@echo off
color b3
:menu
cls
echo Hallo Selamat Bermain Di Game Sederhana Ini
echo 1) Mulai!
echo 2) Cara Main
echo 3) Keluar
set /p number=
if %number% == 1 goto Mulai!
if %number% == 2 goto Cara Main
if %number% == 3 goto Keluar
:Mulai!
cls
echo Siapa Nama Kamu ?
set /p name=
echo Halo %name%!
echo Apakah Kamu Akan Mulai Game Ini ? (y/n)
set /p start=
if %start% == y goto level1
if %start% == n goto menu
goto Mulai!
:cara main
cls
echo Kamu Hanya Akan Diberikan Jawaban Yang Mudah. Kamu Harus Menjawabnya Dengan Soal Ganda.
echo Soalnya Terbagi Jadi 4 Pilihan. Mau Ke Menu ? (y/n)
set /p menugoto=
if %menugoto% == y goto menu
if %menugoto% == n goto exit
goto cara main
:keluar
cls
echo Apa Kamu Yakin Mau Keluar Dari Game Ini ? (y/n)
set /p keluargoto=
if %keluargoto% == y goto exit
if %keluargoto% == n goto menu
goto keluar
:level1
cls
echo Level 1.
echo Kenapa Ban Motor Bisa ( Meledak ) ?
echo a) Karna Digerogotin Tikus
echo b) Karna Nginjek Paku
echo c) Karna Nginjek rumput
echo d) Karna Lupa Pompa Ban
set /p answer1=
if %answer1% == a goto wrong1
if %answer1% == b goto correct1
if %answer1% == c goto wrong1
if %answer1% == d goto wrong1
goto level1
:correct1
echo Mau lanjut Ke Level Selanjutnya ? (y/n)
set /p NL1=
if %NL1% == y goto level2
if %NL1% == n goto menu
goto correct1
:Wrong1
Echo Kamu Salah. Mau Ulang Game (y/n)
set /p WA1=
if %WA1% == y goto level1
if %WA1% == n goto menu
goto wrong1
:level2
cls
echo Level 2.
echo berapa 30+40-20 ?
echo a) 50
echo b) 100
echo c) 60
echo d) 30
set /p aa=
if %aa% == a goto correct2
if %aa% == b goto wrong2
if %aa% == c goto wrong2
if %aa% == d goto wrong2
goto level2
:correct2
echo Mau lanjut Ke Level Selanjutnya ? (y/n)
set /p NL1=
if %NL1% == y goto level3
if %NL1% == n goto menu
goto correct2
:wrong2
cls
echo, Kamu Salah. Mau Ulang Game ? (y/n)
set/p retry=
if %retry% == y goto level1
if %retry% == n goto exit
goto wrong2
:level3
cls
echo Level 3.
echo Siapa Yang Sedang Main Game Ini ?
echo a) Saya
echo b) Virus Komputer
echo c) jokowi
echo d) Justin Bieber
set /p aa=
if %aa% == a goto correct3
if %aa% == b goto wrong3
if %aa% == c goto wrong3
if %aa% == d goto wrong3
goto level3
:correct3
echo Beneran Mau Ke Level Selanjutnya ? (y/n)
set /p NL1=
if %NL1% == y goto level4
if %NL1% == n goto menu
goto correct4
:wrong3
cls
echo maaf, Kamu Salah. Mau Ulang Game ? (y/n)
set/p retry=
if %retry% == y goto level2
if %retry% == n goto exit
goto wrong3
:level4
cls
echo Level 4.
echo berapa 1x1?
echo a) 1
echo b) 2
echo c) 3
echo d) 4
set /p aa=
if %aa% == a goto correct4
if %aa% == b goto wrong4
if %aa% == c goto wrong4
if %aa% == d goto wrong4
goto level4
:correct4
echo Beneran Mau Lanjut Ke level Selanjutnya ? (y/n)
set /p NL1=
if %NL1% == y goto level5
if %NL1% == n goto menu
goto correct4
:wrong4
cls
echo Maaf, Kamu Salah lagi. Mau Ulang ? (y/n)
set/p retry=
if %retry% == y goto level4
if %retry% == n goto exit
goto wrong4
:level5
cls
echo Level 5.
echo benda apa yang tidak mempunyai roda?
echo a)laptop
echo b)motor
echo c)pesawat
echo d)sepeda
set /p answer5=
if %answer5% == a goto correct5
if %answer5% == b goto wrong5
if %answer5% == c goto wrong5
if %answer5% == c goto wrong5
goto level5
:correct5
echo Cius Mau Lanjut Ke Level Selanjutnya ? (y/n)
set/p NL1=
if %NL1% == y goto level6
if %NL1% == n goto menu
goto correct1
:wrong5
cls
echo Bego, Kamu Salah. Mau Ulang Game ? (y/n)
set/p retry=
if %retry% == y goto level5
if %retry% == n goto exit
goto wrong5
:level6
cls
echo Level 6.
echo Berapa Hasil Dari 2573+9988 ?
echo a)Dua Belas Ribu Lima Ratus Enam Puluh Satu
echo b)12.561
echo c)Twelve Thousand Five Hundred Sixty One
echo d)9988+2573
set /p aa=
if %aa% == a goto correct6
if %aa% == b goto correct6
if %aa% == c goto correct6
if %aa% == d goto correct6
goto level6
:correct6
echo Cius Kamu Mau Lanjut Ke Level Selanjutnya ? (y/n)
set/p NL1=
if %NL1% == y goto level7
if %NL1% == n goto menu
goto correct7
:wrong6
cls
echo Santay BOSS. Gak Akan Salah. Tekan Y Aja. (y/n)
set/p retry=
if %retry% == y goto level7
if %retry% == n goto exit
goto wrong7
:level7
cls
echo apa itu nasi goreng?
echo a)tempat
echo b)hewan
echo c)Makanan
echo d)seseorang
set/p answer7=
if %answer7% == a goto wrong7
if %answer7% == b goto wrong7
if %answer7% == c goto correct7
if %answer7% == d goto wrong7
goto level7
:correct7
echo hore kamu menang selamat
echo 1) main menu
set/p NL1=
if %NL1% == 1 goto menu
goto correct7
:wrong7
cls
echo Kamu Salah. Mau Ulang Game ? (y/n)
set/p retry=
if %retry% == y goto level7
if %retry% == n goto exit
goto wrong7
*simpan dengan format bat
Tidak ada komentar:
Posting Komentar