xxxxxxxxxx
87
var rotx = 0;
var roty = 0;
var surface;
var eye;
var un;
var map;
var z=-500
var x=0
var y=0
function setup() {
createCanvas(400, 400, WEBGL);
surface=loadImage("eye p5.jpg")
eye=loadImage("IMG_4763.PNG")
un= loadImage("un.png")
map=loadImage("map.jpeg")
font = loadFont("Akronim-Regular[1].ttf");
textFont(font);
textSize(60);
textAlign(CENTER);
}
function draw() {
background(0)
noStroke()
fill(255,255,255);
text("OBEY THE CUBE", 0, -125);
fill(random(255), random(255), random(255));
//ambientLight(mouseX,mouseY,400,-mouseX)
//fill(255)
sphere(20)
rotateX(rotx);
rotateY(roty);
box(70);
rotate(rotx);
rotate(roty);
translate(0, 100);
texture(surface)
box(100);
translate(0, -200);
texture(eye)
box(100);
translate(-90,0)
translate(100, 0);
fill(0);
texture(map)
translate(0,0,z)
sphere(500);
rotx = rotx + 0.02;
roty = roty + 0.02;
translate(0, 100);
fill(255, 255, 255,20);
//texture(map)
//sphere(50);
rotate(0.1)
translate(-70,0)
texture(un)
sphere(20)
translate(140,0)
texture(eye)
sphere(20)
translate(0,0)
ellipse(0,0,0,0)
cone()
z=z-0.5
x=x+0.5
//if(z<-50)
}