-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathshapes2.html
More file actions
126 lines (108 loc) · 2.59 KB
/
shapes2.html
File metadata and controls
126 lines (108 loc) · 2.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
<html>
<head>
<script src="https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.5.16/p5.js"></script>
<script>
function setup() {
createCanvas(windowWidth,windowHeight);
background('#EBF5FB');
}
function draw() {
//Camera:
//camera body
fill('#AED6F1');
rect(170,20,200,150);
fill('white');
rect(300,25,50,15);
fill('black');
rect(190,10,30,10);
//camera lens
fill('white');
ellipse(270, 100, 50, 50);
ellipseMode(RADIUS);
fill('#5499C7');
ellipse(270, 100, 40, 40);
ellipseMode(RADIUS);
fill('white');
ellipse(270, 100, 20, 20);
//Car
//head
fill('#85C1E9 ');
arc(420, 260, 80, 60, PI, PI);
fill('#D6EAF8 ');
arc(423, 260, 60, 40, PI, PI);
//body
fill('#3498DB');
rect(320,260,197,60);
//tyre1
ellipseMode(RADIUS);
fill('yellow');
ellipse(360,320,30,30);
ellipseMode(CENTER);
fill('#85C1E9 ');
ellipse(360,320,25,25);
//tyre2
ellipseMode(RADIUS);
fill('yellow');
ellipse(480,320,30,30);
ellipseMode(CENTER);
fill('#85C1E9 ');
ellipse(480,320,25,25);
//Fish
fill('#85C1E9');
triangle(650,150,750,50,750,250);
triangle(750,150,770,100,770,200);
fill('yellow');
ellipse(675, 150, 10, 10);
//robot
//face
fill('#AED6F1');
rect(850,80,200,150); //rectangle
//antennae
fill('yellow');
ellipse(950,40,20,20); //circle
stroke('black');
line(950,50,950,80);
//eyes
ellipseMode(RADIUS);
fill('yellow');
ellipse(900,150,30,30);
ellipseMode(CENTER);
fill('#85C1E9 ');
ellipse(900,150,25,25);
ellipseMode(RADIUS);
fill('yellow');
ellipse(995,150,30,30);
ellipseMode(CENTER);
fill('#85C1E9 ');
ellipse(995,150,25,25);
//mouth
fill('red');
triangle(920,190,980,190,950,220);
//neck
fill('#AED6F1');
rect(930,230,50,20);
//body
fill('#AED6F1');
rect(850,250,200,250);
fill('green');
rect(880,280,50,50);//square
fill('#85C1E9 ');
arc(980, 300, 90, 70, PI, PI );
fill('#D6EAF8 ');
arc(983, 310, 60, 40, PI,PI);
//legs
fill('#AED6F1');
rect(870,500,50,80);
fill('#AED6F1');
rect(975,500,50,80);
//hands
fill('#AED6F1');
rect(800,260,50,150);
fill('#AED6F1');
rect(1050,260,50,150);
}
</script>
</head>
<body>
</body>
</html>