level 1
南城十五
楼主
//left red
int x = 120;
int y = 330;
int w = 255;
int h = 25;
void setup(){
size(760,825);
smooth();
sstrokeWeight(2);
}
void draw(){
background(250);
if((mouseX>x)&&(mouseX<x+w)&&
(mouseY>y)&&(mouseY<y+h)){
fill(154,133,240);
}else{
fill(229,111,125);
}
rect(x,y,w,h);
triangle(100,343,120,330,120,355);
fill(255,255,255);
textSize(15);
text("Asia",335,347);
fill(0,0,0);
textSize(15);
text("62%",60,347);
}
//middle
//big cicrle
fill(129,92,74);
ellipse(380,290,50,50);
//small cicrle
noStroke();
fill(240,193,39);
ellipse(380,290,28,28);
//gunzi
fill(129,92,74);
rect(375,313,11,500);
想做一个指示牌,鼠标放上去就变颜色,但是出现错误。
周五就交作业了,求求大家救命!!!!!!!!!!!

2018年11月21日 08点11分
1
int x = 120;
int y = 330;
int w = 255;
int h = 25;
void setup(){
size(760,825);
smooth();
sstrokeWeight(2);
}
void draw(){
background(250);
if((mouseX>x)&&(mouseX<x+w)&&
(mouseY>y)&&(mouseY<y+h)){
fill(154,133,240);
}else{
fill(229,111,125);
}
rect(x,y,w,h);
triangle(100,343,120,330,120,355);
fill(255,255,255);
textSize(15);
text("Asia",335,347);
fill(0,0,0);
textSize(15);
text("62%",60,347);
}
//middle
//big cicrle
fill(129,92,74);
ellipse(380,290,50,50);
//small cicrle
noStroke();
fill(240,193,39);
ellipse(380,290,28,28);
//gunzi
fill(129,92,74);
rect(375,313,11,500);
想做一个指示牌,鼠标放上去就变颜色,但是出现错误。
周五就交作业了,求求大家救命!!!!!!!!!!!



