 	canvas.height = size + spacing
 	
 	draw_emoji(ctx, emoji, canvas.width/2, canvas.height/2, size)
-	
+
+emoji = make_random_emoji()
+
 gui = new dat.GUI()
-gui.add(emoji.mouth, 'smile', -1, +1).name('Smile')
-gui.add(emoji.mouth, 'open').name('Open')
-# gui.add(emoji.mouth, 'tongue', {
-# 	"(Inside mouth)": 0,
-# 	"Out downwards": 1,
-# 	"Out upwards": -1,
-# 	"Out downwards less": 0.5,
-# 	"Out upwards less": -0.5,
-# }) # doesn't work, it gives strings
-# gui.add(emoji.mouth, 'tongue', {min: -1, max: 1, step: 0.5}) # doesn't work, it's treated as a dropdown
-gui.add(emoji.mouth, 'tongue', -1, +1).step(0.5)
-gui.add(emoji.eyes.left, 'type', {"Open": "open", "Wink": "wink"}).name('Left Eye')
-gui.add(emoji.eyes.right, 'type', {"Open": "open", "Wink": "wink"}).name('Right Eye')
+mouth_folder = gui.addFolder('Mouth')
+mouth_folder.add(emoji.mouth, 'smile', -1, +1).name('Smile')
+mouth_folder.add(emoji.mouth, 'open').name('Open')
+mouth_folder.add(emoji.mouth, 'tongue', -1, +1).step(0.5)
+eyes_folder = gui.addFolder('Eyes')
+eyes_folder.add(emoji.eyes.left, 'type', {"Open": "open", "Wink": "wink"}).name('Left Eye')
+eyes_folder.add(emoji.eyes.left, 'offset_x', -1, 1).name('Left Eye X')
+eyes_folder.add(emoji.eyes.left, 'offset_y', -1, 1).name('Left Eye Y')
+eyes_folder.add(emoji.eyes.right, 'type', {"Open": "open", "Wink": "wink"}).name('Right Eye')
+eyes_folder.add(emoji.eyes.right, 'offset_x', -1, 1).name('Right Eye X')
+eyes_folder.add(emoji.eyes.right, 'offset_y', -1, 1).name('Right Eye Y')
+
 
 
 canvas = document.createElement("canvas")



make_random_emoji = ->
	random_eye = ->
		type: if Math.random() < 0.3 then "wink" else "open"
	eyes:
		left: random_eye()
		right: random_eye()

canvas.height = size + spacing

animate ->
	ctx.clearRect(0, 0, canvas.width, canvas.height)
	draw_emoji(ctx, emoji, canvas.width/2, canvas.height/2, size)

