Unit3 Lesson 14 help

I have a student working on the keyboard input aspect for the interactive card in unit 3 lesson 14 and what she wants to happen is the text to change font when the space bar is pressed but I cant seem to figure it out. Does anyone have an idea?

function draw() {
background(“skyblue”);
stroke(“blue”);
fill(“skyblue”);
rect(125, 15, 190, 26);
noStroke();
fill(“rgb(255, 255, 153)”);
ellipse(200, 450, 400, 400);
textSize(24);
fill(“darkred”);
text(“Have a good day!”, 125, 35);
if (keyDown(“space”)) {
textSize(12);
}
var crab = createSprite(200, 200);
crab.setAnimation(“crab_1”);
drawSprites();
}
Link to the project or level: https://studio.code.org/projects/gamelab/bZACDiw_CnvqBvnEr-XHjDJ0bUnA46W8-lNobTVBv1I
What I expect to happen: text size to change when space bar is down
What actually happens: nothing
What I’ve tried: its already there.

Hi @kayla.armstead,

She’ll want to use the textFont() block with an if statement (or if/else statement) before she has the text written, or else it won’t matter. Otherwise it’s like you hold a red marker to write a sentence, and then someone tells you to pick up the blue marker; the sentence has already been written, so it’s in red.

Check out the sample solution I did here.

Hope that helps! If you need any more assistance please reply on here.

–Michael K.