I think the answer you want is flushinp().
From the manual page
The flushinp routine throws away any typeahead that has been typed by the user and has not yet been read by the program.
Here is an example that might fit your usage
#include <stdlib.h>
#include <curses.h>
void atexit_cb(void) {
endwin();
}
int main(void)
{
// initialize curses
initscr();
raw();
keypad(stdscr, TRUE);
noecho();
nodelay(stdscr, FALSE);
atexit(atexit_cb);
// show an intro for 3 seconds
for (int i = 0; i < 3; i++) {
mvprintw(i, 0, "...Intro text...");
refresh();
napms(1000);
move(i, 0);
clrtoeol();
}
// flush typeahead
flushinp();
// now get some new input
printw("Press a key...");
echo();
getch();
return 0;
}