Haegarr, you're right- the problem was that I was accidentally calling SDL_PumpEvents. Right before I check for the input in main program, there's this little snippet to exit when the user presses X:
//Handle events on the queue
while( SDL_PollEvent( &e ) != 0 ){
//User requests quit
if( e.type == SDL_QUIT ){
quit = true;
}
}
I read online several times that SDL_PollEvent calls SDL_PumpEvents internally, but it completely slipped my mind! Serves me right for purposefully ignoring this from the FAQ:
When posting code (which you should do if the problem is at all code-related), post it verbatim without transcribing or omitted code you believe is relevant as you can easily hide the problem that way.
Anyways, commenting out the above lines worked, so I can detect keyPressed and keyReleased to my heart's content! Of course, that means that you can't quit my program without resorting to the Windows Task Manager, but that's a feature, right? =P I've also changed the delete to delete[]
Thanks to everybody for helping me figure this out!