{"id":27439016,"url":"https://github.com/gabrielmaida/block-smasher","last_synced_at":"2026-05-17T09:45:55.455Z","repository":{"id":286034314,"uuid":"960143949","full_name":"GabrielMaida/Block-Smasher","owner":"GabrielMaida","description":"Simple game made with LOVE2D for learning purposes","archived":false,"fork":false,"pushed_at":"2025-07-03T22:19:18.000Z","size":13550,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-14T19:36:42.082Z","etag":null,"topics":["game","love2d","lua"],"latest_commit_sha":null,"homepage":"","language":"Lua","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/GabrielMaida.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-04-03T23:45:39.000Z","updated_at":"2025-07-03T22:19:21.000Z","dependencies_parsed_at":"2025-04-14T21:31:28.915Z","dependency_job_id":"4d4419b5-8c13-4bb9-a13e-079dc5e8710b","html_url":"https://github.com/GabrielMaida/Block-Smasher","commit_stats":null,"previous_names":["gabrielmaida/block-smasher"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/GabrielMaida/Block-Smasher","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GabrielMaida%2FBlock-Smasher","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GabrielMaida%2FBlock-Smasher/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GabrielMaida%2FBlock-Smasher/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GabrielMaida%2FBlock-Smasher/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/GabrielMaida","download_url":"https://codeload.github.com/GabrielMaida/Block-Smasher/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GabrielMaida%2FBlock-Smasher/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279020653,"owners_count":26086898,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-14T02:00:06.444Z","response_time":60,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["game","love2d","lua"],"created_at":"2025-04-14T21:18:18.659Z","updated_at":"2026-05-17T09:45:55.444Z","avatar_url":"https://github.com/GabrielMaida.png","language":"Lua","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Block Smasher\n\nA brick-breaker game made in **Lua** with the **LÖVE** framework.\n\n**Developed by:** [Gabriel Antônio Maida](https://github.com/GabrielMaida)\n\n**Assets by:** [Bhernardo Ramos Vieira](https://github.com/bhernardo17)\n\n**_UNICESUSC - 2025_**\n\n**_Florianópolis, Santa Catarina_**\n\n---\n\n## 1. Concept\n\n**Block Smasher** is a reimagining of the classic brick-breaker game, developed with a focus on creating a fun and visually pleasing arcade experience. The player controls a paddle at the bottom of the screen to bounce a ball and destroy all the blocks at the top.\n\n---\n\n## 2. Technologies\n\n-   **Language:** [Lua](https://www.lua.org/)\n-   **Framework:** [LÖVE2D](https://love2d.org/)\n\n---\n\n## 3. How to Run\n\n### Requirements\n\n-   [LÖVE2D](https://love2d.org/) (version 11.5 or higher)\n-   [Lua](https://www.lua.org/)\n\n### Steps\n\n1.  **Clone the repository:**\n    ```bash\n    git clone https://github.com/GabrielMaida/Block-Smasher\n    cd Block-Smasher\n    ```\n\n2.  **Run the game:**\n    With LÖVE installed, simply run the following command in the project root:\n    ```bash\n    love .\n    ```\n\n---\n\n## 4. Requirements\n\nThe project requirements are divided into functional and non-functional, detailing the main expected features of the game.\n\n### 4.1 Functional Requirements\n\n1.  **Paddle Movement:** Allows the player to move the paddle horizontally (using the keyboard arrows `←`/`→` or `A`/`D`) to intercept the ball.\n2.  **Ball Launch:** After a start timer (3 seconds), the ball is launched at an initial angle, directed towards the blocks.\n3.  **Ball Collision:** The ball must bounce off when colliding with the paddle, walls, or blocks.\n4.  **Block Destruction:** When a ball hits a block, it is destroyed.\n5.  **Win and Loss Conditions:** The game ends and displays a victory message (\"Victory!\") when all blocks are destroyed, or a game over message (\"Game Over!\") if the ball passes the paddle.\n6.  **Start Menu:** The game must feature a start menu with interactive buttons (\"Start Game\", \"Exit Game\").\n\n### 4.2 Non-Functional Requirements\n\n-   **Performance:** The game must run smoothly with a fast response time.\n-   **Modularity:** The code must be modular to easily support new implementations.\n-   **Usability:** The interface must be simple and intuitive, with visual and auditory feedback.\n-   **Code Clarity:** The code must follow good programming practices to facilitate maintenance.\n\n---\n\n## 5. Use Cases\n\n### Case 1: Paddle Movement\n\n-   **Actor:** Player\n-   **Description:** The player moves the paddle horizontally using the keyboard arrows (`←`/`→`) or keys (`A`/`D`) to intercept the ball.\n\n### Case 2: Ball Launch\n\n-   **Actor:** System\n-   **Description:** After the 3-second timer, the ball is automatically launched at an initial angle.\n\n### Case 3: Player Victory/Loss\n\n-   **Actor:** Player\n-   **Description:** Upon destroying all blocks, the game displays a \"Victory!\" message. If the ball goes off the bottom of the screen, the game displays \"Game Over!\". In both cases, the player has the option to play again or exit.\n\n---\n\n## 6. Folder Structure\n\n```bash\nBlock-Smasher/\n├── assets/         # Contains images, sounds, and music\n├── main.lua        # Contains the main source code\n├── conf.lua        # LÖVE configuration file\n├── .gitignore\n├── LICENSE\n└── README.md\n```\n\n---\n\n## 7. Code Structure\n\nThe game is centered around a `Game` object that functions as a state machine, managing the menu, game, victory, and loss screens.\n\n```lua\n-- Main object that manages the game state\nGame = {\n    state = \"menu\", -- States: \"menu\", \"game\"\n    winorlose = nil, -- Victory (1) or loss (0) screens\n\n    start = function() end,      -- Starts a new game\n    gameover = function() end,   -- Activates the game over screen\n    victory = function() end,    -- Activates the victory screen\n    menu = function() end        -- Returns to the main menu\n}\n\n-- Main LÖVE functions\nfunction love.load() end         -- Loads assets and initializes variables\nfunction love.update(dt) end     -- Updates game logic\nfunction love.draw() end         -- Draws elements on the screen\nfunction love.mousepressed(x, y, button) end -- Handles mouse clicks\n```\n\n---\n\n## 8. Game Loop\n\nThe game flow is divided into states, ensuring that the logic and rendering of each screen are independent.\n\n-   **`love.load()`**: Loads all resources and prepares the initial game state (menu).\n-   **`love.update(dt)`**: Checks the current state (`Game.state`) and calls the corresponding update function (`UpdateMenu`, `UpdateGame`).\n-   **`love.draw()`**: Based on the state, draws the appropriate screen (`DrawMenu`, `DrawGame`) and the victory/loss screens.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgabrielmaida%2Fblock-smasher","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgabrielmaida%2Fblock-smasher","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgabrielmaida%2Fblock-smasher/lists"}