Getting started

Editor window

default

You can also edit and read the code found in your project’s HTML and CSS files by clicking on the arrow found near the upper lefthand corner of the editor panel:

And then clicking on the files that are listed:

Functions

Notice the setup() and draw() functions:

See the Pen Example Code by LSU DDEM ( @lsuddem) on CodePen.

https://codepen.io/lsuddem/pen/MGMMXv

See the Pen Example Code by LSU DDEM ( @lsuddem) on CodePen.

https://codepen.io/lsuddem/pen/MGMMXv

  • setup() - runs once
  • draw() - runs over and over at 60 cycles a second

add the console.logs you see here to your code:

See the Pen Example Code by LSU DDEM ( @lsuddem) on CodePen.

https://codepen.io/lsuddem/pen/GGKdaj

Arguments

  • arguements inform functions how to behave
  • In your code, try changing the single number argument found inside the parenthesis for the background() function like this:
background(96);
  • background can take more numbers
  • here they stand for red, green, and blue values
background(96, 110, 220);