Untitled
unknown
plain_text
16 days ago
833 B
2
Indexable
Never
#ifndef GAME_H #define GAME_H #include <SFML/Graphics.hpp> #include "Tetromino.h" #include "Score.h" class Game { public: Game(); void run(); private: void processEvents(); void update(); void render(); void resetGame(); void checkLines(); sf::RenderWindow window; sf::Texture t1, t2, t3; sf::Sprite s, frame; sf::RectangleShape background; sf::Font font; sf::Text scoreText, highScoreText, text1, text2, gameOverText, playAgainText; sf::RectangleShape gridLines[230]; sf::RectangleShape playfieldBoundary, nextTetrominoBoundary, scoreBoundary, highScoreBoundary; int field[23][10] = { 0 }; Tetromino currentTetromino, nextTetromino; // Thêm nextTetromino vào đây Score score; float timer, delay; bool gameOver; sf::Clock clock; }; #endif
Leave a Comment