Sei sulla pagina 1di 13

Textos

Desafio Mis comidas favoritas.

Código:
textSize(30);
fill(8, 0, 0);
text ("My favorite foods", 0, 50);

textSize(20);
fill(8,0,0);
text("*Pizza", 0, 80);
text("*hotdog", 0, 100);
text("*hamburguer", 0, 120);
Rastreador del Ratón

Codigo:

fill(255, 0, 255);

draw = function() {
background(255, 255, 255);
ellipse(mouseX, mouseY, 12, 12);
var coordenadas = mouseX+","+mouseY;
text(coordenadas, mouseX, mouseY);
};
Diseño de anuncio

Codigo:

fill(3, 30, 30);


background(40, 92, 22);
textSize(30);
text("SPORT EXTREME!", 50, 30);
textSize(15);
fill(255, 0, 0);
text("AMAMOS EL DEPORTE!", 80, 300);
textSize(20);
text("TENEMOS LOS MEJORES PRODUCTOS", 10, 320);
textSize(30);
text("CALIDAD PROFESIONAL", 0, 350);

image(getImage("avatars/avatar-team"), 100,130);
image(getImage("cute/Star"), 10,10);
image(getImage("cute/TreeUgly"),300,250);
var ball = 10;
draw = function() {
ellipse(ball, 100, 20 , 20 );
ball = ball+ 10;
};
Evaluación

Esperando evaluación
Funciones:
Desafío: Di tu nombre

Codigo:
var nombre = function (){
var textX = random(0, 300);
var textY = random(0, 300);
var yourName = "Jonnathan";

fill(255, 0, 0);
textSize(30);
text("Hiiii, " + yourName, textX, textY);
};
nombre ();
nombre ();
nombre ();
nombre ();
Topos en los agujeros

Codigo:
var drawMole = function(moleX , moleY) {

noStroke();
fill(125, 93, 43);
ellipse(moleX, moleY, 60, 60); // face
fill(255, 237, 209);
ellipse(moleX, moleY+10, 33, 28);
fill(0, 0, 0);
ellipse(moleX-10, moleY-15, 10, 10); // eyes
ellipse(moleX+10, moleY-15, 10, 10);
ellipse(moleX, moleY-5, 10, 10); // nose
ellipse(moleX, moleY+10, 20, 5); // mouth
};

background(52, 168, 83); // green grass


fill(0, 0, 0);
ellipse(200, 200, 100, 30); // holes!
ellipse(70, 119, 100, 30);
ellipse(300, 60, 100, 30);
ellipse(297, 350, 100, 30);
drawMole(200,200);
drawMole(70,100);
drawMole(300,60);
drawMole(300,350);
Desafío: Calculadora

Codigo:
var add = function(num1, num2) {
return num1 + num2;
};
var subtract = function(num1, num2) {
return num1 - num2;
};
var multiply = function(num1, num2) {
return num1 * num2;
};
var divide = function(num1, num2) {
return num1 / num2;
};

fill(255, 0, 0);
text("15 + 3 is " + add(15, 3), 10, 20);
text("15 - 3 is " + subtract(15, 3), 10, 50);
text("15 * 3 is " + multiply(15, 3), 10, 80);
text("15 / 3 is " + divide(15, 3), 10, 110);

text("8 + 4 is " + add(8, 4), 10, 170);


text("8 - 4 is " + subtract(8, 4), 10, 200);
text("8 * 4 is " + multiply(8, 4), 10, 230);
text("8 / 4 is " + divide(8, 4), 10, 260);
Proyecto pecera #1

Proyecto pecera#2
Proyecto pecera#3

Codigo:
background(89, 216, 255);

var centerX = 200;


var centerY = 100;
var bodyLength = 118;
var bodyHeight = 74;
var bodyColor = color(162, 0, 255);

var drawFish = function (centerX, centerY, bodyLength, bodyHeight, bodyColor){


noStroke();
fill(bodyColor);
// body
ellipse(centerX, centerY, bodyLength, bodyHeight);
// tail
var tailWidth = bodyLength/4;
var tailHeight = bodyHeight/2;
triangle(centerX-bodyLength/2, centerY,
centerX-bodyLength/2-tailWidth, centerY-tailHeight,
centerX-bodyLength/2-tailWidth, centerY+tailHeight);
// eye
fill(33, 33, 33);
ellipse(centerX+bodyLength/4, centerY, bodyHeight/5, bodyHeight/5);
};

drawFish(100,100,30,29, color(215, 0, 235));


drawFish(225,225,99,29, color(255, 131, 23));
drawFish(300,131,57,52, color(102, 133, 45));
drawFish(52,301,57,111, color(13, 5, 255));
drawFish(275,301,59,58, color(255, 5, 5));

mouseClicked = function(){
drawFish(mouseX, mouseY, 20,20);
};

var drawBubbles = function (){


var bubX = random(50,343);
var bubY = random (30,345);
var bubW = random (10,50);
var bubH = bubW;
fill(255, 255, 255);
ellipse(bubX, bubY, bubW, bubH);

};

drawBubbles();
drawBubbles();
drawBubbles();
drawBubbles();
drawBubbles();
drawBubbles();
drawBubbles();

Evaluación
Esperando Evaluación
Circuitos en Tinkercad (operadores Electricos)

Tabla

Operador símbolo

Pila
Baterías de pilas

Cruce de cables con conexión

Cruce de cables sin conexión

Regleta de conexión

Lámpara o bombilla

Diodos led

Motor eléctrico y reductora

Timbre o zumbador

Resistencia

Pulsador abierto

Pulsador cerrado

Interruptor abierto

Interruptor cerrado

Conmutador

Fusible
Circuito

Ingreso a página o plataformas

Khan Academy usuario: jhonatancamiloguerra376@gmail.com


Contraseña: jhonatancamilo123456789

Tinkercad usuario: jhonatancamiloguerra376@gmail.com


Contraseña: jhonatancamilo123456789

Potrebbero piacerti anche