Hello guys, Over the past reasonable amount of practicing time and months, and a long period of practicing my C++ programming skills by use of solving exercises, given in threads and books, I decided that I should give myself a challenge.
So I'm wanting to create a game, It is supposed to be run entirely in
console (Console Application), Pacman. (I'm programming in MS-Windows)
As this is something entirely new, I was hoping for a little heads up or something I should know before I dive right into this project.
Another question I have pondered long enough on, is that how may I be able manipulate input from the user (In this case, through the keyboard) simultaneously, To control Pacman.
I want the action to take place immediately, For example, If the user presses the 'Right Arrow Key' for instance, Then Pacman should immediately turn to the right, and so on. This is something that is really thought provoking and I have not yet come to any conclusion. All I am familiar with in using input from the user is the 'cin' command, and we all know the 'cin' command takes the input from the user only when the 'RETURN' or 'ENTER' key is pressed after the user has typed in his/her desired data.
So please, I would like a heads up here, and also an answer to the problem. Thank you :P
http://www.cplusplus.com/forum/articles/28558/ EDIT: Wow, I was late for several seconds...
No matter what, if you will decide to use console anyway: do not use conio.h / dos.h. They are like undead who still haunt programming community.
If you still want to use console, look for curses library (windows port is pdcurses). It will give you greater control over console, give you ability to intercept keypresses and more.
I don't know if it is possible to make a "console" pacman... mainly under windows...
However I suggest you to take a look at the libraries that can help you developing games (like SDL or others) and possibly multi-platform ones (so with the same source code your game will be buildable not only under windows, but also under linux or other OS supported by the library(ies) )
I cannot help you more becouse I am not skilled enough to try to develop a game like pacman (I am mainly thinking about AI for ghosts)