Jump to content

Project Binary (Batch RPG)

Jack.EXE

I've decided to make a text based RPG, coded entirely in batch, I'm calling it Binary, as there only two options to each scenario,(presented in a question) Yes and no.

 

Every decision will put you closer to one of the two end results: Live in heaven, or burn in hell.

 

 

basically, I'm planning to make a large diamond shaped tree, where the number of parallel questions increase as you come closer to the middle of your life, and the number will start to shrink as you come closer to your death.

 

Death points are scattered throughout as well.

 

life is not black and white, but it is Binary

 

Note: this project is only going to worked on in my free time, as such, it may take a while to finish.

Link to comment
Share on other sites

Link to post
Share on other sites

Sounds interesting and not too hard, altough I've never programmed in Batch.

Link to comment
Share on other sites

Link to post
Share on other sites

an entire if then else tree

You don't actually need an huge amount of if/else.  Batch is pretty powerful...e.g.

echo offgoto:1REM Only the first case gets to call goto:end because all the calls will eventually be returned...so end will pauseREM takes 3 parameters, text to display, the "yes" response goto, and "no" response goto:mainTextFuncSET /P ANSWER="%1 (Y/N)?"if /i {%ANSWER%}=={y} (goto:%2)if /i {%ANSWER%}=={yes} (goto:%2) goto:%3:1call:mainTextFunc "You see a cliff do you jump? " endBad 2goto:end:2call:mainTextFunc "You decided not to jump but you see a nice apple tree do you eat the apples" 3 4goto:endNoPause:3echo. "You ate the nice apple in the middle of winter...you got food poisoning"goto:endNoPause:4call:mainTextFunc "You see a car do you hitchhike?" endGood endBadgoto:endNoPause:endGoodecho. "You have lived a long life"goto:endNoPause:endBadecho. "You have died early"goto:endNoPause:endpause:endNoPause

That way only 3 lines are needed for each branch

0b10111010 10101101 11110000 00001101

Link to comment
Share on other sites

Link to post
Share on other sites

You don't actually need an huge amount of if/else.  Batch is pretty powerful...e.g.

That way only 3 lines are needed for each branch

 

awesome.

 

Also, if people would be so kind, I need ideas for all the scenarios, please leave them in the form of a Y/N question, as that's the basis of the whole thing.

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×