The QBasic / QB64 Discussion Forum      Other Subforums, Links and Downloads
 
 

 Return to Index  

Demo Game

September 13 2007 at 2:36 PM
  (Premier Login iorr5t)
Forum Owner

 

A simple game written to illustrate how data can be saved when going from room to room. Written in answer to a question at another forrum:
"How do I load data from notepad (.DAT) into a QB array?"

Recommended: put game in a directory to itself. It generates five files, S0.SVE, S1.SVE, etc.  (OK, so I used SVE, but DAT could be used, too)

To play, start game. You will be the asterisk in an empty room to get practice using the arrow keys.

If you hit a wall, an object will be generated that is your color. You cannot leave a room until all objects that are your color are gone. If you hit an object that IS your color, the object is gone.

Note that the floor is slippery. From time to time, you will slip and not go the way you wanted. So stay away from walls or other objects as much as possible.

When you enter a room, you will see objects of various colors. If you hit an object that is NOT your color, two such objects will take there place, making it difficult to maneauver.

Eventually, all objects of your color will be gone. (There are 4 rooms). When you enter the next room, you will be assigned a new color.

When all objects are gone from every room, then when you exit, you will be congratulated on a win and the game is over.

As I said, not a wonderful game, just some stuff to illustrate saving and restoring using text files.

Mac

P.S.
To exit game because you don't want to play that particular game, use Q (quit).
To exit immediately because the boss is coming, use ESC. The game can be continued.

 



    
This message has been edited by iorr5t on Sep 13, 2007 2:43 PM


 
 Respond to this message   
Response TitleAuthor and Date
The Program (View Thread) on Sep 13
The Program (Version 3.1) (View Thread) on Sep 13
Heh - BP would have liked this game (View Thread) on Sep 13
   * OK, raise your right and swear on the QB Bible: Is that a bug or a 'feature?'Pete on Sep 13
      * As Joshua (War Games) would say "What's the difference?" on Sep 14
         Uh, right. There is no difference on Sep 14
            I won't admit to playing it but "If I did"...Pete on Sep 15
               Yeah, it could use a better reward! on Sep 16
                  My timer idea is not as fiendish...Pete on Sep 16
                     Our ears buzzed, so, we came about ;-). on Sep 16
                        Here's the URL to the program I referenced:Pete on Sep 16
                           Wow Kudos to Kris, this is awesome work :-). on Sep 17
                              give it a try on Sep 18
 Copyright © 1999-2014 Network54. All rights reserved.   Terms of Use   Privacy Statement  

Newbies usually go to www.qbasic.com and click on The QBasic Forum
Forum regulars have their own ways, which include The QBasic Community Forums