Created
September 29, 2017 15:14
-
-
Save aurelianonava/2141c54ac025e82174c6ab823d176ca0 to your computer and use it in GitHub Desktop.
[add your bin description] // source http://jsbin.com/nefewiy
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <head> | |
| <meta name="description" content="[add your bin description]"> | |
| <Title> Project 2 - More on function point(); </Title> | |
| <script data-require="p5.js@*" data-semver="0.5.7" src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.5.7/p5.min.js"></script> | |
| <link rel="stylesheet" href="style.css" /> | |
| <script src="script.js"></script> | |
| </head> | |
| <body> | |
| <h1>Ellipse Rotation Project Issue #</h1> | |
| <h3>Working with conditional statements: <em>if() {}</em> </h3> | |
| <h6>Snapshot #15</h6> | |
| Note: You will be required to start producing explanations for all the main parts of your code. | |
| I suggest doing this on a Google Doc that you can submmit. | |
| together with the program code and/or url. | |
| <script id="jsbin-javascript"> | |
| //variables | |
| var x, y; | |
| x = 25; | |
| y = 25; | |
| //setup function | |
| function setup() { | |
| canvas = createCanvas(480, 120); | |
| background(0, 200, 250); | |
| } | |
| //draw function | |
| function draw() { | |
| background(0, 200, 250); | |
| strokeWeight(3) | |
| point(x+=1, y); | |
| if(x > 240) { | |
| x = 0; | |
| } | |
| } | |
| </script> | |
| <script id="jsbin-source-javascript" type="text/javascript"> | |
| //variables | |
| var x, y; | |
| x = 25; | |
| y = 25; | |
| //setup function | |
| function setup() { | |
| canvas = createCanvas(480, 120); | |
| background(0, 200, 250); | |
| } | |
| //draw function | |
| function draw() { | |
| background(0, 200, 250); | |
| strokeWeight(3) | |
| point(x+=1, y); | |
| if(x > 240) { | |
| x = 0; | |
| } | |
| }</script></body> | |
| </html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //variables | |
| var x, y; | |
| x = 25; | |
| y = 25; | |
| //setup function | |
| function setup() { | |
| canvas = createCanvas(480, 120); | |
| background(0, 200, 250); | |
| } | |
| //draw function | |
| function draw() { | |
| background(0, 200, 250); | |
| strokeWeight(3) | |
| point(x+=1, y); | |
| if(x > 240) { | |
| x = 0; | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment