Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- boolean isGold;
- int a=0;
- void setup(){
- size (1200,900);
- background(100,0,0);
- noStroke();
- fill(85,54,33);
- rect(575,600,50,300);
- fill(0,100,0);
- triangle(600,300,400,700,800,700);
- isGold=true;
- }
- void mousePressed(){
- if (mousePressed){
- if (isGold){
- fill(232,190,50);
- ellipse(mouseX,mouseY,25,25);
- isGold=false;
- }
- else{
- fill(193,193,193);
- ellipse(mouseX,mouseY,25,25);
- isGold=true;
- }}}
- void draw(){
- a=a+1;
- fill(255);
- ellipse(random(0,width), a,3,3);
- if (a > 900){
- a=0;
- }}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement