remove log

This commit is contained in:
Rorikstr | Rust Dev 2025-09-29 19:55:33 +03:00
parent 0f2d03526e
commit e58a842a43
3 changed files with 25 additions and 19254 deletions

1
.gitignore vendored
View file

@ -57,3 +57,4 @@ src/.gpskip
ginpee.toml
src/ginpee.toml
.vscode/launch.json
src/tetris.log

View file

@ -54,28 +54,32 @@ GameInfo_t updateCurrentState() {
LOG_FUNCTION_START("updateCurrentState", "");
GameState_t* state = get_game_state();
switch (state->state) {
case Init:
do_init();
break;
case Spawn:
do_spawn();
break;
case Move:
do_move();
break;
case Moving:
do_moving();
break;
case Attaching:
do_attaching();
break;
case GameOver:
do_gameover();
break;
// Обновляем логику игры только если игра не на паузе (кроме GameOver)
if (!state->info->pause || state->state == GameOver) {
switch (state->state) {
case Init:
do_init();
break;
case Spawn:
do_spawn();
break;
case Move:
do_move();
break;
case Moving:
do_moving();
break;
case Attaching:
do_attaching();
break;
case GameOver:
do_gameover();
break;
}
}
// Копируем state->field в info->field
// Подготовка данных для отображения
for (int i = 0; i < FIELD_HEIGHT; i++) {
for (int j = 0; j < FIELD_WIDTH; j++) {
state->info->field[i][j] = state->field[i][j];
@ -103,8 +107,6 @@ GameInfo_t updateCurrentState() {
}
}
state->info->pause = 0;
LOG_FUNCTION_END("updateCurrentState", "score=%d, level=%d, state=%d",
state->info->score, state->info->level, state->state);

File diff suppressed because it is too large Load diff