fy">}
} _ iScore ++; (g_iScore gt;=g_iLvlup [g_iInc]) g_iInc ++; (szScore, TEXT ( Tetris Score:% d /% d lvl% d ), g_iScore, g_iLvlup [g_iInc] , (g_iInc + 1));// Оновлюємо рахунок (g_hwnd, szScore);
}
} while (bLineFill);
}
//-----------------------------------------------------------------------------------------OnTimer(HWND hwnd, UINT id)
{(IsImpact ())
{(g_flag == true)
{
SaveGame ();
g_flag=false;
} (g_hwnd, (UINT) NULL); (); (); (); (IsImpact ())
{(g_hwnd, (UINT) NULL); (NULL, TEXT ( Game Over. ), TEXT ( Exit ), MB_OK);
} Repaint () ;;
} (); (g_pPozFigure.y lt; VERTICAL_LINE) g_pPozFigure.y ++; (); ();
}
//-----------------------------------------------------------------------------------------MoveRight()
{tms=0; maxim=0; (int c1=0; c1 lt; 4; c1 ++)
{(int c2=0; c2 lt; 4; c2 ++)
{(g_bFigure [c1] [c2] == TRUE) tms=c1;
}=max (maxim, tms);=0;
} ++; (); (g_pPozFigure.x lt; HORIZONTAL_LINE-maxim) g_pPozFigure.x ++; (); ();
}
//-----------------------------------------------------------------------------------------MoveLeft()
{(); (g_pPozFigure.x gt; 0) g_pPozFigure.x -; (); ();
}
//-----------------------------------------------------------------------------------------MoveDown()
{(IsImpact ()) return; (); (g_pPozFigure.y lt; VERTICAL_LINE) g_pPozFigure.y ++; (); ();
}
//-----------------------------------------------------------------------------------------OverRight()
{tms=0; maxim=0; (int c1=0; c1 lt; 4; c1 ++)
{(int c2=0; c2 lt; 4; c2 ++)
{(g_bFigure [c2] [c1] == TRUE) tms=c2;
}=max (maxim, tms);=0;
} ((g_pPozFigure.x + maxim) gt;=HORIZONTAL_LINE)
{x=HORIZONTAL_LINE-g_pPozFigure.x; ++;=x; _pPozFigure.x-=maxim;
}
}
//-----------------------------------------------------------------------------------------Rotate()
{(); (g_iFigure)
{:( g_bFigure [1] [0] == TRUE)
{( amp; g_bFigure [0] [0]); (int c=0; c lt; 4; c ++)
g_bFigure [0] [c]=TRUE;
}
{( amp; g_bFigure [0] [0]); (int c=0; c lt; 4; c ++) _ bFigure [c] [0]=TRUE;
} (); cube: return;
} [4] [4]; (int c1=0; c1 lt; 4; c1 ++) (int c2=0; c2 lt; 4; c2 ++) [c1] [c2]=FALSE; ( int j=2, c=0; j gt;=0; j--, c ++) (int i=0; i lt; 3; i ++) [c] [i]=g_bFigure [i] [j]; left=1 ; (int c1=0; c1 lt; 4; c1 ++)
{(tmpFigur [0] [c1])
{= 0; break;
}
} ( amp; g_bFigure [0] [0]);
(int f=0; f lt; 3; f ++) (int d=0; d lt; 3; d ++)
{_ bFigure [f] [d]=tmpFigur [f + left] [d];
}
();
}
//-----------------------------------------------------------------------------------------OnKeyDown(HWND hwnd, UINT vk, BOOL fDown, int cRepeat, UINT flags)
{(vk)
{VK_RIGHT :() ;; VK_LEFT :() ;; VK_DOWN :() ;; VK_UP: (); (); () ;;
}
}
//-----------------------------------------------------------------------------------------OnCommand(HWND hwnd, int id, HWND hwndCtl, UINT codeNotify)
{szScore [100]; (id)
{ID_MENU_NEW_GAME:
{(); _ iInc=0; _iScore=0; (szScore, TEXT ( Tetris Score:% d /% d lvl% d ), g_iScore, g_iLvlup [g_iInc], (int (g_iScore/g_iLvlup [g_iInc])));
SetWindowText (g_hwnd, szScore) ;;
} ID_MENU_SAVE:
{_ flag=true; (g_hwnd, (UINT) NULL); (NULL, TEXT ( Game Saved. ), TEXT ( Continue ), MB_OK); (g_hwnd, (UINT) NULL, Speed ??(g_iScore), NULL) ;;
} ID_MENU_LOAD:
{(); () ;;
} ID_MENU_EXIT:
{(TRUE) ;;
...