I'm looking for something that will allow me to create a simple text adventure game with ascii art. What sort of software layer (or whatever you call it) can I use to do this? i.e. just a text GUI, if that makes any sense.
I'm looking for something that will allow me to create a simple text adventure game with ascii art. What sort of software layer (or whatever you call it) can I use to do this? i.e. just a text GUI, if that makes any sense.
Check out ncurses.
Code:while(!asleep) { sheep++; }
Abstract it. Basically write the function charat(int x, int y, int ch), and implement everything else on top of that. So if you want a box of asterisks, the box drawing function calls charat().
There are some things to consider for charat(). You need to know if you define the width and height of the text area, or you accept what's given to you. You also need to know if you need a synch/flush function to call every frame. (On some platforms this could be completely empty, because the system manages the raster for you).
You also need to consider if you need a initscreen(), closescreen() pair to set up and tear down the system.
I'm the author of MiniBasic: How to write a script interpreter and Basic Algorithms
Visit my website for lots of associated C programming resources.
https://github.com/MalcolmMcLean
BigH nailed it, in his post, above.. You will be creating your program on the text console window, and you will DEFINITELY want a program like curses, or ncurses, (those are slightly different siblings of each other), or conio.h.
Using a console control program, like curses, it's easy to create a rich text based adventure game area, on-screen. You control the location, the basic shapes you want, the color, and in some cases, even the texture, of the ascii char you're printing. There are many design char's in the "extended" ascii range, (which is everything from 127 to 255).
If you don't have an ascii chart with the extended chars, you should
░░░░░░ Download One ░░░░░░
Last edited by Adak; 06-20-2013 at 09:10 AM.