캐릭터 움직이기 |
|||||
---|---|---|---|---|---|
작성자 | 전준기 | 등록일 | 17.07.14 | 조회수 | 57 |
void setup() { size(500,500); } void draw() { background(100); stroke(0); line(mouseX,mouseY-100,mouseX-130,mouseY+90); line(mouseX,mouseY-100,mouseX+130,mouseY+90); line(mouseX-130,mouseY+90,mouseX+130,mouseY+90); fill(255,255,255); rectMode(CENTER); rect(mouseX,mouseY,60,120); fill(0,0,0); ellipseMode(CENTER); ellipse(mouseX,mouseY-80,100,100); fill(255,255,255); ellipseMode(CENTER); ellipse(mouseX,mouseY-80,50,50); fill(0,0,0); ellipseMode(CENTER); ellipse(mouseX,mouseY-80,20,45); fill(255,255,0); rectMode(CENTER); rect(mouseX-70,mouseY,-80,20); rect(mouseX+70,mouseY,80,20); rect(mouseX-17,mouseY+100,25,80); rect(mouseX+17.5,mouseY+100,-25,80); }
|
이전글 | 꿈길 과제 |
---|---|
다음글 | 캐릭터 움직이기 |