I’m currently learning C++ and so I thought it would be a good idea trying to (re)program some “common” text-based games. (Thinking of Hunt the Wumpus, Guess a (pseudo) random number generated by the computer,…)
However, I can’t find any good sources for such tasks.
- Which text-based games could be “educating” for me to program?
- Do you remember a special game you have programmed (written in C++ preferably), which taught you a lot?
- It would be nice if you could include:
- A general concept of the game
- What aspects of the C++ language programming this game would require/involve
I’m trying to remember some of the fun stuff I did way back when in my high school CS class. They’re not all games but here it goes:
Text based (ASCII) animation – Basically I animated an ASCII dragon coming into the terminal, saying something, and leaving. After “drawing” each frame it was cleared so basically it was a frame-by-frame ASCII animation generator.
Maze – Used Unicode characters in kind of the same concept. I got keyboard input from the arrow keys and redrew your block going through the maze based on your input. Again, clearing the screen after each frame and printing out the text again.
Snake – similar concept as the above but it was a snake game.
Simple chat – this polled a shared text file on a central server in our school (that someone accidentally chmoded 0777) and facilitated basically a really simple chat room.
The beeper – this program became infamous at my school. Up until XP apparently the sound buffer on Windows computers could easily get overloaded by text. Running this caused the computer to beep until you turned it off (and in most instances also caused it to get bogged down so much you had to do a hard reboot). Definitely pissed off the administration of our high school. Plus it’s only a 2-liner.
Anyway, not sure if this helped you get any ideas but just use your imagination. You can have a lot of fun without having to know a lot about programming. Just be creative.