Hi. First post; so...hello.
Also, I thought this might be a good place to resolve a question that's been bugging me since I began working with C++. I was told by all my references (mainly a high school teacher (that was actually a volleyball coach, but that's another story....)) that cin.get() and cin.ignore() were usefull as ways to hold the program for the enter key. The problem is that these tools seem to be outliving the usefullness I know them for. What I need is a function that continues the program once the enter key is pressed down, but will not barge through to the next pause if the key remains down. For example:
the preceding code will flash by in the blink of an eye if 'Enter' is held down. I have a notion that the problem is that if enter is held longer than what the keyboard's typematic buffer rate is set to in the bios, a battery of instances of 'Enter' being pressed follows and ruins said code. Is this what's happening? Clearly I'm in over my head, but the book gets so boring sometimes.... Also there's nothing about this in any of my books.Code:Astat=+50; cout<<"HP increases by 50,";cin.ignore(); Astat=+3; cout<<"Strength increases by 3,";cin.ignore(); Astat=+4; cout<<"Defence increases by 4,";cin.ignore();