{"id":10913,"date":"2000-01-05T23:39:00","date_gmt":"2000-01-05T21:39:00","guid":{"rendered":"https:\/\/i-dentist.ro\/bricks-game\/"},"modified":"2026-03-21T18:02:31","modified_gmt":"2026-03-21T16:02:31","slug":"bricks-game","status":"publish","type":"post","link":"https:\/\/i-dentist.ro\/en\/bricks-game\/","title":{"rendered":"Bricks game"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-post\" data-elementor-id=\"10913\" class=\"elementor elementor-10913 elementor-8783\" data-elementor-post-type=\"post\">\n\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-048d0bc elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"048d0bc\" data-element_type=\"section\" data-e-type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-70b3a11\" data-id=\"70b3a11\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-eb52562 elementor-widget elementor-widget-html\" data-id=\"eb52562\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<!DOCTYPE html>\r\n<html lang=\"en\">\r\n<head>\r\n    <meta charset=\"UTF-8\">\r\n    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">\r\n    <title>Bricks Game<\/title>\r\n    <style>\r\n        body {\r\n            text-align: center;\r\n            background-color: #000;\r\n            color: white;\r\n            touch-action: manipulation;\r\n        }\r\n        canvas {\r\n            background: #222;\r\n            display: block;\r\n            margin: auto;\r\n        }\r\n        .controls {\r\n            display: flex;\r\n            justify-content: center;\r\n            margin-top: 10px;\r\n        }\r\n        .btn {\r\n            padding: 15px;\r\n            margin: 5px;\r\n            font-size: 18px;\r\n            cursor: pointer;\r\n            border: none;\r\n            background-color: #007BFF;\r\n            color: white;\r\n            border-radius: 5px;\r\n        }\r\n    <\/style>\r\n<\/head>\r\n<body>\r\n    <h1>Bricks Game<\/h1>\r\n    <canvas id=\"gameCanvas\" width=\"400\" height=\"500\"><\/canvas>\r\n    <button class=\"btn\" id=\"startBtn\">Start Game<\/button>\r\n    <div class=\"controls\">\r\n        <button class=\"btn\" id=\"leftBtn\">Left<\/button>\r\n        <button class=\"btn\" id=\"rightBtn\">Right<\/button>\r\n    <\/div>\r\n    <script>\r\n        const canvas = document.getElementById(\"gameCanvas\");\r\n        const ctx = canvas.getContext(\"2d\");\r\n        let gameRunning = false;\r\n\r\n        const paddle = {\r\n            x: 150,\r\n            y: 460,\r\n            width: 100,\r\n            height: 10,\r\n            speed: 20,\r\n            color: \"blue\"\r\n        };\r\n        \r\n        const ball = {\r\n            x: 200,\r\n            y: 250,\r\n            radius: 8,\r\n            dx: 4,\r\n            dy: -4,\r\n            color: \"red\"\r\n        };\r\n        \r\n        const bricks = [];\r\n        const rows = 5;\r\n        const cols = 7;\r\n        const brickWidth = 50;\r\n        const brickHeight = 20;\r\n        const padding = 10;\r\n        \r\n        for (let r = 0; r < rows; r++) {\r\n            for (let c = 0; c < cols; c++) {\r\n                bricks.push({ x: c * (brickWidth + padding) + 30, y: r * (brickHeight + padding) + 30, width: brickWidth, height: brickHeight, destroyed: false });\r\n            }\r\n        }\r\n        \r\n        function drawPaddle() {\r\n            ctx.fillStyle = paddle.color;\r\n            ctx.fillRect(paddle.x, paddle.y, paddle.width, paddle.height);\r\n        }\r\n        \r\n        function drawBall() {\r\n            ctx.fillStyle = ball.color;\r\n            ctx.beginPath();\r\n            ctx.arc(ball.x, ball.y, ball.radius, 0, Math.PI * 2);\r\n            ctx.fill();\r\n            ctx.closePath();\r\n        }\r\n        \r\n        function drawBricks() {\r\n            bricks.forEach(brick => {\r\n                if (!brick.destroyed) {\r\n                    ctx.fillStyle = \"yellow\";\r\n                    ctx.fillRect(brick.x, brick.y, brick.width, brick.height);\r\n                }\r\n            });\r\n        }\r\n        \r\n        function update() {\r\n            if (!gameRunning) return;\r\n            \r\n            ball.x += ball.dx;\r\n            ball.y += ball.dy;\r\n            \r\n            if (ball.x - ball.radius < 0 || ball.x + ball.radius > canvas.width) {\r\n                ball.dx *= -1;\r\n            }\r\n            if (ball.y - ball.radius < 0) {\r\n                ball.dy *= -1;\r\n            }\r\n            \r\n            if (ball.y + ball.radius > paddle.y && ball.x > paddle.x && ball.x < paddle.x + paddle.width) {\r\n                ball.dy *= -1;\r\n            }\r\n            \r\n            if (ball.y + ball.radius > canvas.height) {\r\n                alert(\"Game Over!\");\r\n                document.location.reload();\r\n            }\r\n            \r\n            bricks.forEach(brick => {\r\n                if (!brick.destroyed && ball.x > brick.x && ball.x < brick.x + brick.width && ball.y > brick.y && ball.y < brick.y + brick.height) {\r\n                    brick.destroyed = true;\r\n                    ball.dy *= -1;\r\n                }\r\n            });\r\n        }\r\n        \r\n        function draw() {\r\n            ctx.clearRect(0, 0, canvas.width, canvas.height);\r\n            drawPaddle();\r\n            drawBall();\r\n            drawBricks();\r\n        }\r\n        \r\n        function gameLoop() {\r\n            update();\r\n            draw();\r\n            if (gameRunning) {\r\n                requestAnimationFrame(gameLoop);\r\n            }\r\n        }\r\n        \r\n        document.getElementById(\"startBtn\").addEventListener(\"click\", () => {\r\n            if (!gameRunning) {\r\n                gameRunning = true;\r\n                gameLoop();\r\n            }\r\n        });\r\n        \r\n        document.addEventListener(\"keydown\", (event) => {\r\n            if (event.key === \"ArrowLeft\" && paddle.x > 0) {\r\n                paddle.x -= paddle.speed;\r\n            }\r\n            if (event.key === \"ArrowRight\" && paddle.x + paddle.width < canvas.width) {\r\n                paddle.x += paddle.speed;\r\n            }\r\n        });\r\n        \r\n        document.getElementById(\"leftBtn\").addEventListener(\"touchstart\", () => {\r\n            if (paddle.x > 0) paddle.x -= paddle.speed;\r\n        });\r\n        \r\n        document.getElementById(\"rightBtn\").addEventListener(\"touchstart\", () => {\r\n            if (paddle.x + paddle.width < canvas.width) paddle.x += paddle.speed;\r\n        });\r\n    <\/script>\r\n<\/body>\r\n<\/html>\r\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>Bricks Game Bricks Game Start Game Left Right<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_exactmetrics_skip_tracking":false,"postBodyCss":"","postBodyMargin":[],"postBodyPadding":[],"postBodyBackground":{"backgroundType":"classic","gradient":""},"footnotes":""},"categories":[145],"tags":[],"class_list":["post-10913","post","type-post","status-publish","format-standard","hentry","category-games"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.8 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Bricks game - Clinica stomatologic\u0103 iDentist - Dr.Marcu<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/i-dentist.ro\/en\/bricks-game\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Bricks game - Clinica stomatologic\u0103 iDentist - Dr.Marcu\" \/>\n<meta property=\"og:description\" content=\"Bricks Game Bricks Game Start Game Left Right\" \/>\n<meta property=\"og:url\" content=\"https:\/\/i-dentist.ro\/en\/bricks-game\/\" \/>\n<meta property=\"og:site_name\" content=\"Clinica stomatologic\u0103 iDentist - Dr.Marcu\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/clinicaidentist\" \/>\n<meta property=\"article:published_time\" content=\"2000-01-05T21:39:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-03-21T16:02:31+00:00\" \/>\n<meta name=\"author\" content=\"Adi\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Adi\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/bricks-game\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/bricks-game\\\/\"},\"author\":{\"name\":\"Adi\",\"@id\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/#\\\/schema\\\/person\\\/07735249bd6e345dbfb56e96e446a33f\"},\"headline\":\"Bricks game\",\"datePublished\":\"2000-01-05T21:39:00+00:00\",\"dateModified\":\"2026-03-21T16:02:31+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/bricks-game\\\/\"},\"wordCount\":10,\"articleSection\":[\"Games\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/bricks-game\\\/\",\"url\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/bricks-game\\\/\",\"name\":\"Bricks game - Clinica stomatologic\u0103 iDentist - Dr.Marcu\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/#website\"},\"datePublished\":\"2000-01-05T21:39:00+00:00\",\"dateModified\":\"2026-03-21T16:02:31+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/#\\\/schema\\\/person\\\/07735249bd6e345dbfb56e96e446a33f\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/bricks-game\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/i-dentist.ro\\\/en\\\/bricks-game\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/bricks-game\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Prima pagin\u0103\",\"item\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Bricks game\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/#website\",\"url\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/\",\"name\":\"Clinica stomatologic\u0103 iDentist - Dr.Marcu\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/#\\\/schema\\\/person\\\/07735249bd6e345dbfb56e96e446a33f\",\"name\":\"Adi\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f840822760a13a4da92e430dccb75636c3ade1ac9f1b5875baa287a9442a52f5?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f840822760a13a4da92e430dccb75636c3ade1ac9f1b5875baa287a9442a52f5?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/f840822760a13a4da92e430dccb75636c3ade1ac9f1b5875baa287a9442a52f5?s=96&d=mm&r=g\",\"caption\":\"Adi\"},\"url\":\"https:\\\/\\\/i-dentist.ro\\\/en\\\/author\\\/adi\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Bricks game - Clinica stomatologic\u0103 iDentist - Dr.Marcu","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/i-dentist.ro\/en\/bricks-game\/","og_locale":"en_US","og_type":"article","og_title":"Bricks game - Clinica stomatologic\u0103 iDentist - Dr.Marcu","og_description":"Bricks Game Bricks Game Start Game Left Right","og_url":"https:\/\/i-dentist.ro\/en\/bricks-game\/","og_site_name":"Clinica stomatologic\u0103 iDentist - Dr.Marcu","article_publisher":"https:\/\/www.facebook.com\/clinicaidentist","article_published_time":"2000-01-05T21:39:00+00:00","article_modified_time":"2026-03-21T16:02:31+00:00","author":"Adi","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Adi"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/i-dentist.ro\/en\/bricks-game\/#article","isPartOf":{"@id":"https:\/\/i-dentist.ro\/en\/bricks-game\/"},"author":{"name":"Adi","@id":"https:\/\/i-dentist.ro\/en\/#\/schema\/person\/07735249bd6e345dbfb56e96e446a33f"},"headline":"Bricks game","datePublished":"2000-01-05T21:39:00+00:00","dateModified":"2026-03-21T16:02:31+00:00","mainEntityOfPage":{"@id":"https:\/\/i-dentist.ro\/en\/bricks-game\/"},"wordCount":10,"articleSection":["Games"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/i-dentist.ro\/en\/bricks-game\/","url":"https:\/\/i-dentist.ro\/en\/bricks-game\/","name":"Bricks game - Clinica stomatologic\u0103 iDentist - Dr.Marcu","isPartOf":{"@id":"https:\/\/i-dentist.ro\/en\/#website"},"datePublished":"2000-01-05T21:39:00+00:00","dateModified":"2026-03-21T16:02:31+00:00","author":{"@id":"https:\/\/i-dentist.ro\/en\/#\/schema\/person\/07735249bd6e345dbfb56e96e446a33f"},"breadcrumb":{"@id":"https:\/\/i-dentist.ro\/en\/bricks-game\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/i-dentist.ro\/en\/bricks-game\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/i-dentist.ro\/en\/bricks-game\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Prima pagin\u0103","item":"https:\/\/i-dentist.ro\/en\/"},{"@type":"ListItem","position":2,"name":"Bricks game"}]},{"@type":"WebSite","@id":"https:\/\/i-dentist.ro\/en\/#website","url":"https:\/\/i-dentist.ro\/en\/","name":"Clinica stomatologic\u0103 iDentist - Dr.Marcu","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/i-dentist.ro\/en\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/i-dentist.ro\/en\/#\/schema\/person\/07735249bd6e345dbfb56e96e446a33f","name":"Adi","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/f840822760a13a4da92e430dccb75636c3ade1ac9f1b5875baa287a9442a52f5?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/f840822760a13a4da92e430dccb75636c3ade1ac9f1b5875baa287a9442a52f5?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/f840822760a13a4da92e430dccb75636c3ade1ac9f1b5875baa287a9442a52f5?s=96&d=mm&r=g","caption":"Adi"},"url":"https:\/\/i-dentist.ro\/en\/author\/adi\/"}]}},"_links":{"self":[{"href":"https:\/\/i-dentist.ro\/en\/wp-json\/wp\/v2\/posts\/10913","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/i-dentist.ro\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/i-dentist.ro\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/i-dentist.ro\/en\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/i-dentist.ro\/en\/wp-json\/wp\/v2\/comments?post=10913"}],"version-history":[{"count":1,"href":"https:\/\/i-dentist.ro\/en\/wp-json\/wp\/v2\/posts\/10913\/revisions"}],"predecessor-version":[{"id":10914,"href":"https:\/\/i-dentist.ro\/en\/wp-json\/wp\/v2\/posts\/10913\/revisions\/10914"}],"wp:attachment":[{"href":"https:\/\/i-dentist.ro\/en\/wp-json\/wp\/v2\/media?parent=10913"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/i-dentist.ro\/en\/wp-json\/wp\/v2\/categories?post=10913"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/i-dentist.ro\/en\/wp-json\/wp\/v2\/tags?post=10913"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}