Shiqi Ouyang
1 min readSep 27, 2017
def setup():
size(500,500)
background(59,160,56)
stroke(255,255,255)
strokeWeight(4)

global moods
moods = [‘happy’, ‘meh’, ‘sad’, ‘sick’]
# mood = “happy”

def draw():

#this is where the face is
faceRadius=170
faceXposition=250
faceYposition=125
#this is where the eyes are
eyeRadius=40
eyeYPosition = 100
leftEyeXPosition = 210
rightEyeXPosition = 290
#this is where the mouth is
mouthWidth=80
mouthHeight = 20
mouthX = 210
mouthY = 150
myFacemood=’normal’

#this is where we define our color variables
mouthColorHighlight = color(255,255, 0)
mouthColorUnHighlighted = color(0, 0, 0)

#this is where I draw the shapes of the face
fill(0,0,0)
ellipse(faceXposition, faceYposition, faceRadius, faceRadius)
if mousePressed:
fill(255,216,0)
ellipse(leftEyeXPosition, eyeYPosition, eyeRadius, eyeRadius)
else:
fill(255,0,0)
ellipse(leftEyeXPosition, eyeYPosition, eyeRadius, eyeRadius*0.5)

if mousePressed:
fill(255,216,0)
ellipse(rightEyeXPosition, eyeYPosition, eyeRadius, eyeRadius)
else:
fill(255,0,0)
ellipse(rightEyeXPosition, eyeYPosition, eyeRadius, eyeRadius*0.5)

if mousePressed:
fill(mouthColorHighlight)
rect(mouthX+30, mouthY-25, mouthWidth*0.2, mouthHeight*3.5)
else:
fill(mouthColorUnHighlighted)
rect(mouthX, mouthY, mouthWidth, mouthHeight)

Funny face….