补全Rogue侧边HUD与局内结算反馈提示

This commit is contained in:
2026-04-24 20:02:43 +08:00
parent bbaa89e21d
commit 8ee470b059
5 changed files with 272 additions and 45 deletions
+28 -13
View File
@@ -145,30 +145,45 @@ LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
}
break;
case WM_TIMER:
if (wParam == GAME_TIMER_ID &&
currentScreen == SCREEN_PLAYING &&
!suspendFlag &&
!gameOverFlag)
if (wParam == GAME_TIMER_ID)
{
if (CanMoveDown())
bool shouldRefresh = false;
if (feedbackState.visibleTicks > 0)
{
MoveDown();
feedbackState.visibleTicks--;
shouldRefresh = true;
}
else
if (currentScreen == SCREEN_PLAYING &&
!suspendFlag &&
!gameOverFlag)
{
Fixing();
if (CanMoveDown())
{
MoveDown();
}
else
{
Fixing();
if (!gameOverFlag)
{
DeleteLines();
}
}
if (!gameOverFlag)
{
DeleteLines();
ComputeTarget();
}
shouldRefresh = true;
}
if (!gameOverFlag)
if (shouldRefresh)
{
ComputeTarget();
InvalidateRect(hWnd, nullptr, FALSE);
}
InvalidateRect(hWnd, nullptr, FALSE);
}
break;
case WM_SIZE: