Download code float col = 0.1; PVector mouse = new PVector(mouseX,mouseY); void setup(){ size(1100,700,P3D); background(255); smooth(8); } void draw(){ translate(150,-50); stroke(0,20); if (mousePressed==true){ curve(); } } void curve(){ noFill(); beginShape(); PVector mouse = new PVector(mouseX,mouseY); vertex(mouse.x+250, mouse.y+200); bezierVertex(mouse.x/20+100, mouse.y/20+200, mouse.x+142, mouse.y+294.0, mouse.x +142.47238, mouse.y+294.0); bezierVertex(mouse.x/2+400, mouse.y/2+150, mouse.y, mouse.x, mouse.x/10-100, mouse.y/10+100); bezierVertex(mouse.x+18.0, mouse.y*2, mouse.x, mouse.y, mouse.x, mouse.y); endShape(); }