Init commit
This commit is contained in:
parent
8bd653d363
commit
8c138fe3fe
7 changed files with 30 additions and 8 deletions
|
|
@ -24,8 +24,8 @@ void game_loop()
|
|||
stats_init(&stats);
|
||||
|
||||
while (break_flag)
|
||||
{
|
||||
if (state == GAMEOVER || state == EXIT_STATE)
|
||||
{
|
||||
if (state == GAMEOVER || state == EXIT_STATE || state == FILE_ERROR_STATE)
|
||||
break_flag = FALSE;
|
||||
|
||||
sigact(get_signal(signal), &state, &stats, &map, &frog);
|
||||
|
|
@ -33,4 +33,11 @@ void game_loop()
|
|||
if (state == MOVING || state == START)
|
||||
signal = GET_USER_INPUT;
|
||||
}
|
||||
|
||||
if (state == FILE_ERROR_STATE)
|
||||
{
|
||||
print_levelerror();
|
||||
nodelay(stdscr, FALSE);
|
||||
getch();
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue