// added lines to all the brush statements, then reversed code to have each colour coming from different direction //variables - drawing, then making the brush bigger if shift plus colour key //declaring variables float brushstroke; float bigBrushstroke; int r = 255; int g = 255; int b = 255; int a = 80; void brush() { if (mousePressed == true) { cursor(CROSS); stroke(random(0,155)); strokeWeight(brushstroke *.1); line(pmouseX ,pmouseY ,constrain(mouseX, 0 , 0) , constrain(mouseY, 0, height)); } else { cursor(HAND); } //bring in the Red Colour when R or r is pressed if (keyPressed){ if (key == 'r') { cursor(CROSS); colorMode(RGB); stroke(r,0,0,a); strokeWeight(10); strokeWeight(brushstroke *.1); line(pmouseX ,pmouseY ,constrain(mouseX, width , width) , constrain(mouseY, 0, height)); } } //end red //bring in the BIG Red Stroke when SHIFT R or r is pressed if (keyPressed){ if (key == 'R') { cursor(CROSS); colorMode(RGB); stroke(r,0,0,a); strokeWeight(brushstroke *.4); line(pmouseX ,pmouseY ,constrain(mouseX, width , width) , constrain(mouseY, 0, height)); } } //end BIG red //bring in the Green Colour when G or g is pressed if (keyPressed){ if (key == 'g') { cursor(CROSS); colorMode(RGB); stroke(0,g,0,a); strokeWeight(brushstroke *.1); line(pmouseX ,pmouseY ,constrain(mouseX, 0 , width) , constrain(mouseY, 0, 0)); } }// end green //bring in the BIG Green Stroke when SHIFT G or r is pressed if (keyPressed){ if (key == 'G') { cursor(CROSS); colorMode(RGB); stroke(0,g,0,a); strokeWeight(brushstroke *.4); line(pmouseX ,pmouseY ,constrain(mouseX, 0 , width) , constrain(mouseY, 0, 0)); } } //end BIG Green //bring in the Blue Colour when B or b is pressed if (keyPressed){ if (key == 'b') { cursor(CROSS); colorMode(RGB); stroke(0,0,b,a); strokeWeight(brushstroke *.1); line(pmouseX ,pmouseY ,constrain(mouseX, 0, height) , constrain(mouseY, height, width)); } }// end blue //bring in the BIG Blue Stroke when SHIFT B or r is pressed if (keyPressed){ if (key == 'B') { cursor(CROSS); colorMode(RGB); stroke(0,0,b,a); strokeWeight(brushstroke *.4); line(pmouseX ,pmouseY ,constrain(mouseX, 0, height) , constrain(mouseY, height, width)); } } //end BIG Blue } //end brush()