{"id":53,"date":"2025-11-14T15:01:33","date_gmt":"2025-11-14T15:01:33","guid":{"rendered":"https:\/\/theroyalscode.com\/students\/d_torres\/?p=53"},"modified":"2025-11-14T15:01:33","modified_gmt":"2025-11-14T15:01:33","slug":"free-friday-11142025","status":"publish","type":"post","link":"https:\/\/theroyalscode.com\/students\/d_torres\/2025\/11\/14\/free-friday-11142025\/","title":{"rendered":"free friday 11\\14\\2025"},"content":{"rendered":"\n<p>Today i worked a new game well im trying its Tetris i only got a little done which is this <\/p>\n\n\n\n<p><\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>import pygame<\/p>\n\n\n\n<p># Game size<\/p>\n\n\n\n<p>COLUMNS = 10<\/p>\n\n\n\n<p>ROWS = 20<\/p>\n\n\n\n<p>CELL_SIZE = 40<\/p>\n\n\n\n<p>GAME_WIDTH, GAME_HEIGHT = COLUMNS * CELL_SIZE, ROWS * CELL_SIZE<\/p>\n\n\n\n<p># side bar size<\/p>\n\n\n\n<p>SIDEBAR_WIDTH = 200<\/p>\n\n\n\n<p>PREVIEW_HEIGHT_FRACTION = 0.7<\/p>\n\n\n\n<p>SCORE_HEIGHT_FRACTION = 1 &#8211; PREVIEW_HEIGHT_FRACTION<\/p>\n\n\n\n<p>1 # window<\/p>\n\n\n\n<p>PADDING = 20<\/p>\n\n\n\n<p>WINDOW_WIDTH = GAME_WIDTH + SIDEBAR_WIDTH + PADDING * 3<\/p>\n\n\n\n<p>WINDOW_HEIGHT = GAME_HEIGHT + PADDING * 2<\/p>\n\n\n\n<p># game behaviour<\/p>\n\n\n\n<p>UPDATE_START_SPEED = 800<\/p>\n\n\n\n<p>MOVE_WAIT_TIME = 200<\/p>\n\n\n\n<p>ROTATE_WAIT_TIME = 200<\/p>\n\n\n\n<p>BLOCK_OFFSET = pygame. Vector2(COLUMNS \/\/ 2, -1)<\/p>\n\n\n\n<p># Colors<\/p>\n\n\n\n<p>YELLOW = &#8216;#f1e60d&#8217;<\/p>\n\n\n\n<p>RED = #6<\/p>\n\n\n\n<p>this is for the timer and to make the game appear i really like this game so i hope it comes out good <\/p>\n","protected":false},"excerpt":{"rendered":"<p>Today i worked a new game well im trying its Tetris i only got a little done which is this [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"","ast-site-content-layout":"default","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"","adv-header-id-meta":"","stick-header-meta":"","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"footnotes":""},"categories":[1],"tags":[],"class_list":["post-53","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/theroyalscode.com\/students\/d_torres\/wp-json\/wp\/v2\/posts\/53","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/theroyalscode.com\/students\/d_torres\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/theroyalscode.com\/students\/d_torres\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/theroyalscode.com\/students\/d_torres\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/theroyalscode.com\/students\/d_torres\/wp-json\/wp\/v2\/comments?post=53"}],"version-history":[{"count":1,"href":"https:\/\/theroyalscode.com\/students\/d_torres\/wp-json\/wp\/v2\/posts\/53\/revisions"}],"predecessor-version":[{"id":54,"href":"https:\/\/theroyalscode.com\/students\/d_torres\/wp-json\/wp\/v2\/posts\/53\/revisions\/54"}],"wp:attachment":[{"href":"https:\/\/theroyalscode.com\/students\/d_torres\/wp-json\/wp\/v2\/media?parent=53"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/theroyalscode.com\/students\/d_torres\/wp-json\/wp\/v2\/categories?post=53"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/theroyalscode.com\/students\/d_torres\/wp-json\/wp\/v2\/tags?post=53"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}