Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function setup() {
- createCanvas(800, 700);
- ellipseMode(CENTER);
- background(50, 55, 100);
- for(var numberofstars = 0;numberofstars <= 100; numberofstars++){
- stroke(500);
- fill(255, 204, 0)
- ellipse(random(length, width), random(length, width), 5, 5)
- }
- }
- // x15, y+100, scale 0.5
- function draw() {
- scale(0.50)
- Lyra(570,790);
- UrsaMinor(1155,745);
- Bootes(285, 250);
- Gemini(420, 130);
- push();
- scale(2)
- Moon(550, 150)
- pop();
- }
- //240,116
- function Lyra(x,y) {
- fill(255, 204, 0);
- stroke(300);
- line(x-40, y-16, x-40, y+28);
- ellipse(x-40, y-16, 10, 10);
- line(x-40, y-16, x, y);
- push();
- fill('magenta')
- ellipse(x, y, 15, 15);
- pop();
- line(x, y, x-40, y+28);
- ellipse(x-40, y+28, 8, 8);
- line(x-40, y+28, x-80, y+34);
- ellipse(x-80, y+34, 8, 8);
- line(x-80, y+34, x-110, y+119);
- ellipse(x-110, y+119, 8, 8);
- line(x-110, y+119, x-70, y+114);
- ellipse(x-70, y+114, 8, 8);
- line(x-70, y+114, x-40, y+28);
- }
- //350, 100
- function UrsaMinor(u,m) {
- fill(255, 204, 0);
- stroke(300);
- push();
- fill('magenta');
- ellipse(u, m, 15, 15);
- pop();
- line(u, m, u-30, m+40);
- ellipse(u-30, m+40, 8, 8);
- line(u-30, m+40, u-40, m+80);
- ellipse(u-40, m+80, 8, 8);
- line(u-40, m+80, u-30, m+120);
- ellipse(u-30, m+120, 8, 8);
- line(u-30, m+120, u+10, m+140);
- ellipse(u+10, m+140, 8, 8);
- line(u+10, m+140, u-5, m+170);
- ellipse(u-5, m+170, 8,8);
- line(u-5, m+170, u-50, m+150);
- ellipse(u-50, m+150, 8, 8);
- line(u-50, m+150, u-30, m+120);
- }
- //540,215
- function Bootes(a,b) {
- fill(255, 204, 0);
- stroke(300);
- ellipse(a-90, b-115, 8, 8);
- line(a-90, b-115, a-110, b-65);
- ellipse(a-110, b-65, 8, 8);
- line(a-35, b-105, a-90, b-115);
- ellipse(a-35, b-105, 8, 8);
- line(a-50, b-30, a-110, b-65);
- ellipse(a-50, b-30, 8, 8);
- line(a-35, b-105, a-30, b-60);
- ellipse(a-30, b-60, 8, 8);
- line(a-30, b-60, a, b);
- push();
- fill('magenta')
- ellipse(a, b, 15, 15);
- pop();
- line(a-50, b-30, a, b);
- ellipse(a-20, b+35, 5, 5);
- line(a, b, a-20, b+35);
- ellipse(a+40, b-10, 8, 8);
- line(a+40, b-10, a, b);
- ellipse(a+55, b+5, 5, 5);
- line(a+55, b+5, a+40, b-10);
- }
- //630,100
- function Gemini(c,p) {
- push();
- fill('magenta');
- ellipse(c, p, 15, 15);
- pop();
- line(c, p, c+20, p+20);
- ellipse(c+20, p+20, 5, 5);
- line(c+20, p+20, c, p+45);
- ellipse(c, p+45, 5, 5);
- line(c+20, p+20, c+50, p+70);
- ellipse(c+50, p+70, 5, 5);
- line(c+50, p+70, c+60, p+115);
- ellipse(c+60, p+115, 5, 5);
- line(c+60, p+115, c+140, p+140);
- ellipse(c+85, p+80, 5, 5);
- line(c+85, p+80, c+140, p+105);
- ellipse(c+140, p+105, 5, 5);
- line(c+50, p+70, c+85, p+80);
- ellipse(c+140, p+140, 5, 5);
- //630, 100
- line(c+20, p+20, c+40, p+20);
- ellipse(c+40, p+20, 5, 5);
- line(c+30, p-20, c+70, p+5);
- line(c+40, p+20, c+70, p+5);
- ellipse(c+70, p+5, 5, 5);
- line(c+70, p+5, c+110, p-15);
- ellipse(c+110, p-15, 5, 5);
- push();
- fill('magenta');
- ellipse(c+30, p-20, 15, 15);
- pop();
- line(c+70, p+5, c+115, p+35);
- ellipse(c+115, p+35, 5, 5);
- line(c+115, p+35, c+135, p+85);
- ellipse(c+135, p+85, 5, 5);
- line(c+115, p+35, c+140, p+55);
- ellipse(c+140, p+55, 5, 5);
- line(c+140, p+55, c+160, p+60);
- ellipse(c+160, p+60, 5, 5);
- line(c+160, p+60, c+180, p+60);
- ellipse(c+180, p+60, 5, 5);
- }
- //75, 125
- function Moon(d,e) {
- push();
- strokeWeight(2);
- ellipse(d, e, 100, 100);
- push();
- fill(265, 214, 170);
- ellipse(d-20, e-20, 40, 30);
- ellipse(d+30, e+10, 20, 30);
- ellipse(d-5, e+10, 20, 25);
- ellipse(d-20, e+30, 30, 25);
- ellipse(d+10, e+30, 15, 15);
- pop();
- pop();
- }
Add Comment
Please, Sign In to add comment