Jump to content

Building a Text Based RPG, I need your help!

Jack.EXE

So far the language is batch.

@[member=Echo] offtitle RPGcolor aset /a x=4set /a y=4cls:homecolor aset UsrLn=xxxset /p UsrLn=if “%UsrLn%”==Describe goto Describeif “%UsrLn%”==Lock goto Lockif “%UsrLn%== North goto Northif “%UsrLn%== South goto Southif “%UsrLn%== East goto Eastif “%UsrLn%== West goto Westecho Command Invalid!goto home:Northif “%y%”=0 color cif “%y%”=0 echo A Magical Barrier Prevents You From Traveling Further!if “%y%”=0 pauseif “%y%”=0 goto homeset /a y = %y% - 1goto location:Southif “%y%”=9 color cif “%y%”=9 echo A Magical Barrier Prevents You From Traveling Further!if “%y%”=9 pauseif “%y%”=9 goto homeset /a y = %y% + 1goto location:Eastif “%x%”=9 color cif “%x%”=9 echo A Magical Barrier Prevents You From Traveling Further!if “%x%”=9 pauseif “%x%”=9 goto homeset /a x = %x% + 1goto location:Westif “%x%”=0 color cif “%x%”=0 echo A Magical Barrier Prevents You From Traveling Further!if “%x%”=0 pauseif “%x%”=0 goto homeset /a x = %x% - 1goto location:Lockset /p Obj=Lock Onto:if “%Obj%”==”%obj1%”if “%Obj%”=="%obj2%"if “%Obj%”=="%obj3%':Describe:Locationclsgoto home

Really, what I need is help creating an array of 81 locations, from (0,0) to (9,9)

 

Example code of a location:

if "%x%"==4 if "%y%"==4 set Desc = You find yourself at a mysterious campsite in a clearing of trees. There is a %Obj1%, a %Obj2%, and a %Obj3% here.if "%x%"==4 if "%y%"==4 set Obj1 = Campfireif "%x%"==4 if "%y%"==4 set Obj2 = Tentif "%x%"==4 if "%y%"==4 set Obj3 = knifeecho %Desc%

Please leave Obj3 variable blank. This will be reserved for future use. (enemies, allies, tools or weapons)

 

This is nowhere near done, but the addition of scenery would be very useful in knowing how to continue the program.

Link to comment
Share on other sites

Link to post
Share on other sites

I have done it in java. the trick is to make choices that lead back to the same point.

Good luck, Have fun, Build PC, and have a last gen console for use once a year. I should answer most of the time between 9 to 3 PST

NightHawk 3.0: R7 5700x @, B550A vision D, H105, 2x32gb Oloy 3600, Sapphire RX 6700XT  Nitro+, Corsair RM750X, 500 gb 850 evo, 2tb rocket and 5tb Toshiba x300, 2x 6TB WD Black W10 all in a 750D airflow.
GF PC: (nighthawk 2.0): R7 2700x, B450m vision D, 4x8gb Geli 2933, Strix GTX970, CX650M RGB, Obsidian 350D

Skunkworks: R5 3500U, 16gb, 500gb Adata XPG 6000 lite, Vega 8. HP probook G455R G6 Ubuntu 20. LTS

Condor (MC server): 6600K, z170m plus, 16gb corsair vengeance LPX, samsung 750 evo, EVGA BR 450.

Spirt  (NAS) ASUS Z9PR-D12, 2x E5 2620V2, 8x4gb, 24 3tb HDD. F80 800gb cache, trueNAS, 2x12disk raid Z3 stripped

PSU Tier List      Motherboard Tier List     SSD Tier List     How to get PC parts cheap    HP probook 445R G6 review

 

"Stupidity is like trying to find a limit of a constant. You are never truly smart in something, just less stupid."

Camera Gear: X-S10, 16-80 F4, 60D, 24-105 F4, 50mm F1.4, Helios44-m, 2 Cos-11D lavs

Link to comment
Share on other sites

Link to post
Share on other sites

I have done it in java. the trick is to make choices that lead back to the same point.

really, I'm just thinking of making it open world "do whatever the crap"

no storyline, just explore, fight monsters, ect.

 

Hell, I'll even add the ability to marry one, just to reference this comedic gold.

cxOTWSE.png

Link to comment
Share on other sites

Link to post
Share on other sites

If by scenery you mean graphics, batch files can't do that. If you mean ASCII characters or whatever, you have to do that manually. 

 

Here's a resource that may help you with the arrays: http://superuser.com/questions/191224/populating-array-in-dos-batch-script

 

Still though, google before you ask. 

 

I do not mean graphics, I mean a basic description of the surroundings.

Link to comment
Share on other sites

Link to post
Share on other sites

I do not mean graphics, I mean a basic description of the surroundings.

Just stuff that in the array. 

Link to comment
Share on other sites

Link to post
Share on other sites

Just stuff that in the array. 

I am already aware of the code. I'm just asking for some creative pools.

 

I'd like help coming up with 80 unique locations.

Link to comment
Share on other sites

Link to post
Share on other sites

a cave with lots of holes in the ground, a wooded forest 

Good luck, Have fun, Build PC, and have a last gen console for use once a year. I should answer most of the time between 9 to 3 PST

NightHawk 3.0: R7 5700x @, B550A vision D, H105, 2x32gb Oloy 3600, Sapphire RX 6700XT  Nitro+, Corsair RM750X, 500 gb 850 evo, 2tb rocket and 5tb Toshiba x300, 2x 6TB WD Black W10 all in a 750D airflow.
GF PC: (nighthawk 2.0): R7 2700x, B450m vision D, 4x8gb Geli 2933, Strix GTX970, CX650M RGB, Obsidian 350D

Skunkworks: R5 3500U, 16gb, 500gb Adata XPG 6000 lite, Vega 8. HP probook G455R G6 Ubuntu 20. LTS

Condor (MC server): 6600K, z170m plus, 16gb corsair vengeance LPX, samsung 750 evo, EVGA BR 450.

Spirt  (NAS) ASUS Z9PR-D12, 2x E5 2620V2, 8x4gb, 24 3tb HDD. F80 800gb cache, trueNAS, 2x12disk raid Z3 stripped

PSU Tier List      Motherboard Tier List     SSD Tier List     How to get PC parts cheap    HP probook 445R G6 review

 

"Stupidity is like trying to find a limit of a constant. You are never truly smart in something, just less stupid."

Camera Gear: X-S10, 16-80 F4, 60D, 24-105 F4, 50mm F1.4, Helios44-m, 2 Cos-11D lavs

Link to comment
Share on other sites

Link to post
Share on other sites

I am already aware of the code. I'm just asking for some creative pools.

 

I'd like help coming up with 80 unique locations.

Oooohhhhhh. Well. That clarifies things. Well, I'm not creative, but there are alot of location generators out there. For example: http://writers-den.pantomimepony.co.uk/writers-locations.php

If you want to fill 80 fields of that, I suggest you do it yourself: I'm not trying to be rude, but I doubt anyone here will fill those out.

 

Anyway, here's one:

if "%x%"==5 if "%y%"==4 set Desc = A row of pickets and dead bodies indicate a battle has been fought here. There is are %Obj1%, some %Obj2%, and a %Obj3% here.if "%x%"==5 if "%y%"==4 set Obj1 = Picketsif "%x%"==5 if "%y%"==4 set Obj2 = Gold Coinsif "%x%"==5 if "%y%"==4 set Obj3 = knifeecho %Desc%

Also, I'm not sure if batch supports this, but I think you can just bundle this under one IF statement. It's way more efficient and practical. I'm curious; why would you make variables for each item if they're just being written out in desc?  Are you planning to use them elsewhere? 

Link to comment
Share on other sites

Link to post
Share on other sites

Oooohhhhhh. Well. That clarifies things. Well, I'm not creative, but there are alot of location generators out there. For example: http://writers-den.pantomimepony.co.uk/writers-locations.php

If you want to fill 80 fields of that, I suggest you do it yourself: I'm not trying to be rude, but I doubt anyone here will fill those out.

Anyway, here's one:

if "%x%"==5 if "%y%"==4 set Desc = A row of pickets and dead bodies indicate a battle has been fought here. There is are %Obj1%, some %Obj2%, and a %Obj3% here.if "%x%"==5 if "%y%"==4 set Obj1 = Picketsif "%x%"==5 if "%y%"==4 set Obj2 = Gold Coinsif "%x%"==5 if "%y%"==4 set Obj3 = knifeecho %Desc%
Also, I'm not sure if batch supports this, but I think you can just bundle this under one IF statement. It's way more efficient and practical. I'm curious; why would you make variables for each item if they're just being written out in desc? Are you planning to use them elsewhere?

Yep

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

×