'F' → Fullscreen
Copy the template-game folder and rename the copy to 1-02-signal. Open main.lua inside it and press Run.

A window opens. Press Escape to close it — that is what love.keypressed in the template is for. You will do this dozens of times today.
The text is drawn at (400, 300), which is the middle of the window — but the text is not centered. That coordinate is where its top left corner goes.
Delete the love.graphics.print line, leaving the box empty, and put a rectangle in it instead:
function love.draw() love.graphics.rectangle("fill", 350, 130, 100, 340)endRun it. A white rectangle. Now change the four numbers one at a time, running after each change, until you can say out loud what each one does.
love.keypressed alone. It is below love.draw and it is how you close the window. Delete it and you will be reaching for the mouse all period.Add one line above the rectangle:
function love.draw() love.graphics.setColor(0.6, 0.6, 0.6) love.graphics.rectangle("fill", 350, 130, 100, 340)endGray, because 0.6 of all three is a bit more than half of white. Try (1, 0, 0) and (0, 0, 1) before you move on.
Add a circle, in its own color:
function love.draw() love.graphics.setColor(0.6, 0.6, 0.6) love.graphics.rectangle("fill", 350, 130, 100, 340)
love.graphics.setColor(0.9, 0.2, 0.2) love.graphics.circle("fill", 400, 190, 35)endThen add the other two. The three centers are 190, 300 and 410 down, all at x = 400:
function love.draw() love.graphics.setColor(0.6, 0.6, 0.6) love.graphics.rectangle("fill", 350, 130, 100, 340)
love.graphics.setColor(0.9, 0.2, 0.2) love.graphics.circle("fill", 400, 190, 35)
love.graphics.setColor(0.9, 0.8, 0.2) love.graphics.circle("fill", 400, 300, 35)
love.graphics.setColor(0.2, 0.8, 0.3) love.graphics.circle("fill", 400, 410, 35)end
Change the gray line to the numbers you would find on any color website:
love.graphics.setColor(128, 128, 128)
The circles did not disappear. They are still being drawn. Work out why you cannot see them, write it on your sheet, and put the line back.
No error message, no crash, nothing in the terminal. This is the kind of bug you have to reason about instead of read about.
Copy 1-02-signal to 1-02-scene and draw something of your own out of rectangles and circles — a snowman, a robot, a flag, a face. Anything with at least six shapes and three colors.
1-02-signal opens a window and closes on EscapeAnswer the following questions before submitting your work.
love.draw, but it ran anyway. Say what you think is calling it, and how often.Submit the required files to the appropriate dropbox.