OK, here I am again with another update on that game I’ve been working on.
Lately, it’s been rough. I’ve been trying to balance my deep desire to work on my coding project and my family life. I think I’ve been doing OK, but I’m sure my wife wishes she could have me just a little bit more than she has had me.
If I must say so myself though, I think everything is turning out fairly nicely. Sure, I’m not really focusing on the graphics, so the pictures I’m sharing below shouldn’t be taken too seriously (they are for example purposes only), and I’m not really working on the story of the game yet (I have friends that are helping with that because they’re excited about it), so a lot of what is written in the instructions is bogus and silly, but the underlying code is working really nicely and I have a lot of ideas written down for making it even more efficient and flexible.
Some of the ideas include a more efficient system for handling the doors and linkages between maps (I think I can reduce the lines of code per door by up to 66%), I have to add support for conversations with different responses (the mechanics are all worked out, I just haven’t coded it yet), I have to add support for doors that lock now that my keys are working properly (I had a wonderful moment of genius yesterday where I figured out a simple, elegant way to handle the locking mechanism in code), and I want to explore the idea of having a border-less map system (where the walls around the edges would be unnecessary). Of course, I need to make tons of new maps (and I keep thinking that some kind of cool editor would be fun, for now I use Notepad), I have to do more with the part of the game where you die (we have some good ideas for a heaven/hell situation based on your choices in the game, the tracking system of which does not yet exist in the code, but I think I’m ready to add it), and I want to do a tutorial mode where you are sent on a brief, simple mission just to learn how to play.
Of course, if the actual game play is going to last more than five minutes it would be nice if the user could save their progress. Right now all of the progress information is stored in variables on the web page and all of the information is lost when you reload the page (close your browser, navigate away from the page and back to it, etc.). I know that cookies could help me save the key information and reload it when the page is loaded again, but I’ve never worked with cookies before so it would be a learning experience. I think I will wait until the game is done and playable before getting into that though, because it would be a pain to make changes to the game code that would require the cookie code to change.
Below I am sharing a few screen shots and the entire written portion of the instructions I’ve drafted up (they are more for fun that serious, and they have not been spell checked so have mercy). The version that is pulled up from the game shows the images associated with each ASCII character, but I didn’t want to upload all of them so you could see. If anyone is interested in playing around in my unfinished version (you can’t win because there is no story yet), just let me know and if I feel like it I’ll upload a .zip file with all of the images and .htm files you need to play. Really all you can do is walk around collecting stuff, talking to people (most of whom have nothing to say) and killing things. Most of the doors don’t work and most of the items don’t do anything. If you want to play around with it though, just let me know and I’ll upload it all. Just don’t go stealing my code! 😀
Click on the image to see the full sized version (I am especially proud of my water monster and the two headed dragon, and no, that woman does not have arms).
Help and Instructions
Story and General Instructions
For now, there isn’t much of a story. Just like any other game, you take control of the worthless and expendable life of some poor little man who needs you to tell him what to do all of the time. The rest of the story will become more clear as you play, or it won’t. Either way, it’s a game, not a movie.
This game is controlled entirely through the keyboard (which is impressive considering that most of the original code was written before I incorporated the keyboard controls). For details on which keys do what, see the table below titled “General Keyboard Commands” and the “Items” table as some items have a keyboard command associated with them.
Most spaces in the game can be walked on, some cannot. The “Terrain” table contains details about that. If there is anything you’re curious about, try to step on it and see what happens. Most item, character and enemy interaction is handled this way.
Look over the tables below to learn more details, then get back to playing the game! This screen can be called up any time throughout the game by pressing the “h” key on your keyboard. To return to normal gameplay, press the space bar. Good luck and have fun!
General Keyboard Commands
Key Action h Displays this help file. Can be used at any time during the game. space Function varries based on the situation. If pressed now, it will return you to the game. t Currently, pressing this key causes the rendering code to switch from using image tiles to using ASCII letters and from ASCII to image tiles. arrow keys These are the keys you use to move around. You can press an arrow key once to move one space, or hold one of them down to travel a greater distance. While holding down a directional key you cannot change directions without releasing the key you are already holding down. By standing next to an interactive item, such as an enemy, another character or an item, and pressing the arrow key toward that item you will interact with it. numbers 1-4 These are used in conversation to select your response. Y/N Sometimes, rather than a complicated response, a character will simply ask a yes or no question, in which case you will hit “y” or “n” to respond. F5 Pressing the F5 key refreshes the page and starts everything over completely. Your progress is not saved, though a saving system is being considered. Can only be used during game play, not now.
ASCII Key Name Description a backpack The backpack is used for carrying items. It is required before you can start the game (officially) and carry other items. o small orb The small orb adds a little attack power to your weapon attack power. The orb is carried in the backpack. i c candle The candle is used to light up dark rooms. Some rooms have areas of darkness which the candle can also light up, but only momentarily. The candle is carried in the backpack. # raft Once you have the raft, you can travel over water. The raft is also carried in the backpack. – small stick The small stick is the least effective weapon. Choosing it at the beginning of the game may give you certain advantages however. The backpack is required to carry the small stick. _ big stick The big stick is a little more powerful than the small stick, though less powerful than the sword. The backpack is required to carry the big stick. t basic sword The basic sword is the most powerful weapon you can choose at the beginning of the game, though you may find yourself in a disadvantage sometimes throughout the game should you choose it. The backpack is used to carry the basic sword. / arrows As of right now, arrows don’t do anything. You carry them in your backpack. D bow Currently, the bow just sits there and looks pretty. You carry it in your backpack. ~ w gummi-worm The gummi-worm is carried in the backpack until you need it. Pressing the “w” key causes you to eat one from your inventory and restore health. O big orb The big orb adds even more attack power to your weapon. Requires the backpack. C lucky horseshoe The lucky horseshoe is useless. You carry it in your backpack. l k key The key is required for opening locked doors. You need a backpack to carry them in. An inventory is kept for when you have more than one. B b bomb Bombs blow some things up, but not everything. Use with caution – if you blow one next to another bomb you will get hurt. You carry them in the backpack. * health star Find one of these to restore some health. $ money Collect lots of cash. Mostly just because you never know what you’ll need it for.
ASCII Name Description X wall Walls cannot be stepped on or passed, but some are easy to blow up with a bomb. H/I doors Some doors are locked, others take you random places. Have fun with doors. = bridge/wooden floor Some of the bridge sections may blow up when you use a bomb. Be careful. | railing On occasion you will find a rail that can blow up. It never hurts to check, unless there are other bombs nearby. w water Once you have the raft, you can travel over water. ! tree Some trees can be blown up, but that’s not a very nice thing to do. A/M mountains Mountains cannot be crossed for now, but some funny people often live among them. ^ hill You can walk on these with no problem. P flag I’m not sure what these are for. ‘ grass Feel it between your toes… E darkness You can’t even see yourself in the darkness, you need light. `/./,/: sand For walking in. Not good for eating.
ASCII Name Description @ hero This silly moron doesn’t know how to think for himself and needs you (of all people) to guide him through every little aspect of his meaningless 2-dimensional life. & old man Usually friendly, these people just want to have a word with you. K woman Maybe she needs your help, maybe not. You never know which woman will turn out to be the princess in your life. e basic enemy These are weak, but not the weakest of enemies. The small stick will not kill one alone. s small snake These are among the weakest of all the enemies. Even a smack from a small stick will beat one to death. Q “Q” enemy These are a little more fearsome. You’ll need more than just the sword to take these out. S big snake These are a gamble, even with the sword. Once you’ve got an orb or two though, they’re hardly worth mentioning. Z “Z” enemy These are some of the strongest enemies made so far. F water monster These mysterious enemies are strong, so watch out. N horse monster These are as strong as the “Z” enemies, but harder to find. Y two-headed dragon These ultra-strong enemies are dangerous, and even a few orbs and a sword cannot kill them. You’re going to have to find something else that may be effective against them.