Qbasicnews.com

Full Version: Text Adventure!
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14
I've got to say though, I'm not that advanced in checking for key words in strings. Most, if not all, of the text adventures I make just check to see if the string is a certain word or group of words.

Ok, to start off the text adventure, we need a storyline or at least some idea of what the user will be going through...
If you need help with a text parser, I wrote a tutorial in QBE #16 on how to make a good general purpose one. It should help you out in finding keywords in strings.
GOTO isn't bad programming except when it's used to create "spaghetti code." It can be quite useful- I use it all the time.
In every programming class I've taken "GOTO" has been considered bad programming unless it is used for displaying errors or for getting out of complicated loops or ifs, nothing more.
Yeah, they took it out of Java!

I have the right to GOTO!!! Bring it back!
Anyway, so what should this text adventure be about?
Set in the North Pole, a group of Elves has left Santa's Factory for the South Pole. Santa will give you a series of challenges to complete. You will sometimes be assisted by polar bear guards, who take frequent swigs of Coca-Cola®, and opposed by commando penguins. There are teleporters in certain locations of the cities, disguised as street lamps.

It's a start, anyway.
I figured the main character would, upon hearing a clatter, go up a skylight in the bathroom to the roof and enter Santa's sleigh while the reindeer and elf were occupied with a Monopoly game. Then he would be ferried to the North Pole and jump out into the garage, where he would be apprehended and brought before Santa.
Cool! So to speak. I like it.
Yeah, nice job. Ok, next question...how do you want to structure the programming? Do you want to make a bunch of locations using gosubs (what I'm accustomed to) or what?
Quote:Yeah, nice job. Ok, next question...how do you want to structure the programming? Do you want to make a bunch of locations using gosubs (what I'm accustomed to) or what?

May I suggest we have each area (or area chunk) in an individual file to be called when needed? I'm sure that's going to involve POKE and PEEK, which I've been wanting to learn for a while.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14