[Solved] Pause Function

Whether you're a newbie or an experienced programmer, any questions, help, or just talk of any language will be welcomed here.

Moderator: Coders of Rage

User avatar
Ginto8
ES Beta Backer
ES Beta Backer
Posts: 1064
Joined: Tue Jan 06, 2009 4:12 pm
Programming Language of Choice: C/C++, Java

Re: [Solved] Pause Function

Post by Ginto8 »

ok... I'm surprised no one else has thought of this:

Code: Select all

#include <conio.h>

int main()
{
...
    getch();
...
}
Note that it only works on windows, but it is exactly the kind of thing you're looking for zodiac
Quit procrastinating and make something awesome.
Ducky wrote:Give a man some wood, he'll be warm for the night. Put him on fire and he'll be warm for the rest of his life.
User avatar
zodiac976
Chaos Rift Regular
Chaos Rift Regular
Posts: 156
Joined: Thu Jun 18, 2009 10:03 am
Current Project: Booklet & Text RPG
Favorite Gaming Platforms: PC, PS3, PSP
Programming Language of Choice: C++
Location: AL
Contact:

Re: [Solved] Pause Function

Post by zodiac976 »

Ginto8 wrote:ok... I'm surprised no one else has thought of this:

Code: Select all

#include <conio.h>

int main()
{
...
    getch();
...
}
Note that it only works on windows, but it is exactly the kind of thing you're looking for zodiac
Actually I did post that but you can't use getch() like that
the compiler will say to use _getch(); under the conio.h
but I believe that is not a C++ standard so I don't think
I will use it :/.
Post Reply