Using C++, while making a console application is there a way for cin to accept the next character entered and continue without hitting enter?
We just covered screen control in my C++ class and I want to make a console app where you can move a "X" around the screen with the use 开发者_开发技巧of w,a,s,d, but I don't want the user to have to hit enter.
This is not possible with standard C++. You will need a cross-platform library like pdcurses or the conio library (originally from DOS), or a related platform-dependent library.
精彩评论