xxxxxxxxxx
86
function preload(){
img = loadImage('paper-texture.jpg');
}
function setup() {
createCanvas(400, 400);
}
function draw() {
blendMode(BLEND);
background(220);
strokeWeight(5)
fill(255, 0 , 0);
rect(0, 0, 200, 400);
fill(0, 0 , 255);
rect(200, 0, 200, 400);
push();
translate(100, 0);
for (m = 0; m < 3; m++) {
for (n = 0; n < 160; n++)
imSad(random, random);
}
pop();
for (i = 0; i < 5; i++) {
for (j = 0; j < 150; j++)
imExasperated(random, random);
}
for (k = 0; k < 2; k++) {
for (l = 0; l < 2; l++)
imHappy(random, random);
}
frameRate(1);
blendMode(LIGHTEST);
image(img, 0, 0, width, height);
}
function imExasperated(a, b) {
let swearWords = ["fuck!", "dammit!", "damn!", "shit!", "ass!", "god damn it!", "damn it!", "motherfucker!", "crap!", "fucking hell!", "damn it all to hell!"];
let randSwears = (random(swearWords));
let randSwearsX = (random(0, width / 2));
let randSwearsY = (random(0, height));
let randSize = (floor(random(12, 25)));
let randSwearsFill = (color(floor(random(122, 255)), 0, 0));
textAlign(RIGHT);
stroke(255, 0, 0);
fill(randSwearsFill);
textSize(randSize);
text(randSwears, randSwearsX, randSwearsY);
}
function imHappy(c, d) {
let happyWords = ["everything's gonna be okay!", "nothing will ever \n be wrong again!", "i'm great!", "i'm the shit!", "things are gonna \n stay this way!", "i love everything!", "everything's fine!", "hell yeah!", "bad times? \n what are those?"];
let randHappy = (random(happyWords));
let randHappyX = (random(width * .25 , width * .75));
let randHappyY = (random(0, height));
let randHappySize = (floor(random(8, 10)));
let randHappyFill = (color(0, floor(random(122, 255)), 0));
textAlign(CENTER);
stroke(0, 255, 0);
fill(randHappyFill);
textSize(randHappySize);
text(randHappy, randHappyX, randHappyY);
}
function imSad(e, f) {
let sadWords = ["i'm the worst!", "everything will \n be bad forever!", "i'm a piece of crap!", "i'm shitty!", "things are gonna \n stay this way!", "i hate everything!", "everything's awful!", "i should die!", "good times? \n what are those?"];
let randSad = (random(sadWords));
let randSadX = (random(0, width / 2));
let randSadY = (random(0, height));
let randSadSize = (floor(random(12, 30)));
let randSadFill = (color(0, 0, floor(random(122, 255))));
textAlign(LEFT);
stroke(0, 0, 255);
fill(randSadFill);
textSize(randSadSize);
text(randSad, randSadX, randSadY);
}