project
in
Programming Questions
•
11 months ago
I have been working on some code for a while and I have almost finished but I have 2 small problems. When I run my code the line drawn when you click and drag wont draw on top of the yellow circle, I need some way to fix this, also I was wondering if there was a way to make the line drawn thinker or skinnier?
here is my code:
void setup()
{
size(640, 480);
fill (0);
background(255);
}
void draw()
{
stroke(0);
if(mousePressed)line(pmouseX, pmouseY, mouseX, mouseY);
fill(246, 255, 2);
ellipse (320, 240, 300, 300);
}
void keyPressed() {
background(255);
}
1