{"id":125,"date":"2026-05-26T14:02:52","date_gmt":"2026-05-26T14:02:52","guid":{"rendered":"https:\/\/theroyalscode.com\/students\/c_jones\/?p=125"},"modified":"2026-05-26T14:02:52","modified_gmt":"2026-05-26T14:02:52","slug":"free-friday-4-24-26-2","status":"publish","type":"post","link":"https:\/\/theroyalscode.com\/students\/c_jones\/2026\/05\/26\/free-friday-4-24-26-2\/","title":{"rendered":"Free Friday 4\/24\/26"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">Today in class I worked on a Cookie Clicker\u2011style game using Python<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>wn = turtle.Screen()\nwn.bgcolor(\"black\")\nwn.register_shape(\"cookie.gif\")\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>This sets up the game window andapplies a black background.<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>clicks = 0\npen.write(f\"Clicks: {clicks}\", align=\"center\", font=(\"Courier New\", 32, \"normal\"))\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>This initializes the click counter and displays the current score<\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>def clicked(x, y):\n    global clicks\n    clicks += 1\n    pen.clear()\n    pen.write(f\"Clicks: {clicks}\", align=\"center\", font=(\"Courier New\", 32, \"normal\"))\n<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><strong>This runs every time the cookie is clicked increasing the score<\/strong>.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"979\" height=\"863\" src=\"https:\/\/theroyalscode.com\/students\/c_jones\/wp-content\/uploads\/2026\/05\/image-2.png\" alt=\"\" class=\"wp-image-126\" srcset=\"https:\/\/theroyalscode.com\/students\/c_jones\/wp-content\/uploads\/2026\/05\/image-2.png 979w, https:\/\/theroyalscode.com\/students\/c_jones\/wp-content\/uploads\/2026\/05\/image-2-300x264.png 300w, https:\/\/theroyalscode.com\/students\/c_jones\/wp-content\/uploads\/2026\/05\/image-2-768x677.png 768w\" sizes=\"auto, (max-width: 979px) 100vw, 979px\" \/><\/figure>\n","protected":false},"excerpt":{"rendered":"<p>Today in class I worked on a Cookie Clicker\u2011style game using Python This sets up the game window<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-125","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/theroyalscode.com\/students\/c_jones\/wp-json\/wp\/v2\/posts\/125","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/theroyalscode.com\/students\/c_jones\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/theroyalscode.com\/students\/c_jones\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/theroyalscode.com\/students\/c_jones\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/theroyalscode.com\/students\/c_jones\/wp-json\/wp\/v2\/comments?post=125"}],"version-history":[{"count":1,"href":"https:\/\/theroyalscode.com\/students\/c_jones\/wp-json\/wp\/v2\/posts\/125\/revisions"}],"predecessor-version":[{"id":127,"href":"https:\/\/theroyalscode.com\/students\/c_jones\/wp-json\/wp\/v2\/posts\/125\/revisions\/127"}],"wp:attachment":[{"href":"https:\/\/theroyalscode.com\/students\/c_jones\/wp-json\/wp\/v2\/media?parent=125"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/theroyalscode.com\/students\/c_jones\/wp-json\/wp\/v2\/categories?post=125"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/theroyalscode.com\/students\/c_jones\/wp-json\/wp\/v2\/tags?post=125"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}