{"id":74262,"date":"2022-10-11T08:40:34","date_gmt":"2022-10-11T12:40:34","guid":{"rendered":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/?p=74262"},"modified":"2022-10-11T09:29:42","modified_gmt":"2022-10-11T13:29:42","slug":"project-6","status":"publish","type":"post","link":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/2022\/10\/11\/project-6\/","title":{"rendered":"Project 6"},"content":{"rendered":"<!DOCTYPE html PUBLIC \"-\/\/W3C\/\/DTD HTML 4.0 Transitional\/\/EN\" \"http:\/\/www.w3.org\/TR\/REC-html40\/loose.dtd\">\n<html><body><p>My clock is made up of a few planets that orbit each other. One representing the hours, another the minutes, and the last representing seconds. <\/p>\n\n\n\n<div class=\"wp-block-file\"><a class=\"p5_sketch_link\" data-height=\"400\" data-width=\"400\" id=\"wp-block-file--media-8097cf2f-26e7-41c9-82cd-2b67c259866d\" href=\"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-content\/uploads\/2022\/10\/sketch-106.js\">sketch<\/a><a href=\"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-content\/uploads\/2022\/10\/sketch-106.js\" class=\"wp-block-file__button\" download=\"\" aria-describedby=\"wp-block-file--media-8097cf2f-26e7-41c9-82cd-2b67c259866d\">Download<\/a><iframe src=\"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-content\/plugins\/p5-embedder\/p5_iframe.html\" class=\"p5_exampleFrame\" width=\"400\" height=\"400\"><\/iframe><pre class=\"language-javascript\"><code class=\"p5_editor language-javascript\">\n\/\/dvargas David vargas\nvar starX=[] \/\/x position of stars\nvar starY=[]\/\/y position of stars\nvar starB=[]\/\/brightness value of stars\nvar hourV = {x:0,y:0,diam:50,c:'orange'} \/\/array w\/values for orange (hours) circle\nvar minuteV = {x:0,y:0,diam:30,c:'lightgreen'}\/\/array w\/ values for green (minutes) circle\nvar secondV = {x:0,y:0,diam:10,c:'lightblue'} \/\/array w\/ values for blue (seconds) circle\nvar orbitV ={hX:300,hY:300,mX:0,mY:0,sX:0,sY:0,hD:180,mD:150,sD:75} \/\/array w\/ values for 'orbit rings'\nvar noiseOffset=0 \/\/perlin noise offset\n\n\n\nfunction setup() {\n    createCanvas(600, 600);\n    background(255);\n    for (var i=0;i&lt;80;i++){ \/\/creates random stars\n        starX[i]=random(0,width)\n        starY[i]=random(0,height)\n    }\n\n}\n\nfunction draw() {\n  background(0);\n  var theTime=currentTime() \/\/the time represented by a value between 0 & 12\n\n  for(var i=0;<\/code><\/pre><\/div><\/body><\/html>\n","protected":false},"excerpt":{"rendered":"<p>My clock is made up of a few planets that orbit each other. One representing the hours, another the minutes, and the last representing seconds. sketchDownload \/\/dvargas David vargas var starX=[] \/\/x position of stars var starY=[]\/\/y position of stars var starB=[]\/\/brightness value of stars var hourV = {x:0,y:0,diam:50,c:&#8217;orange&#8217;} \/\/array w\/values for orange (hours) circle &hellip; <a href=\"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/2022\/10\/11\/project-6\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Project 6&#8221;<\/span><\/a><\/p>\n","protected":false},"author":767,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[106,55],"tags":[],"_links":{"self":[{"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-json\/wp\/v2\/posts\/74262"}],"collection":[{"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-json\/wp\/v2\/users\/767"}],"replies":[{"embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-json\/wp\/v2\/comments?post=74262"}],"version-history":[{"count":3,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-json\/wp\/v2\/posts\/74262\/revisions"}],"predecessor-version":[{"id":74269,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-json\/wp\/v2\/posts\/74262\/revisions\/74269"}],"wp:attachment":[{"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-json\/wp\/v2\/media?parent=74262"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-json\/wp\/v2\/categories?post=74262"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/courses.ideate.cmu.edu\/15-104\/f2022\/wp-json\/wp\/v2\/tags?post=74262"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}