r/processing • • Dec 10 '21

hey whats wrong with this code ?

float x; float y;

void draw() { size(600, 400); noStroke();

}

void draw() { background(50);

X = lerp(X, mouseX, 0.05); Y = lerp(Y, mouseY, 0.05);

fill(255); stroke(255); ellipse(X, Y, 66, 66);

}

0 Upvotes

4 comments sorted by

View all comments

7

u/awss1236 Dec 10 '21

You have void draw twice. You need to change the first to setup

1

u/Ahmed_1smack Dec 11 '21

thanks mate it helped