🐶Introduce yourself! 🐶
katyadee (1232)

Hi everyone!

Use this space to share anything you want to share with our community - your name, where you're from, what you program in, what brought you here... whatever you're comfortable with!

Can't wait to get to know y'all.

💖
Katya

You are viewing a single comment. View All
Coder100 (10490)

api test lel
ok so that isn't even valid syntax, keyPressed(s) takes an argument s, but you aren't even using it...
what you should do instead is:

void keyPressed(){
  if (key.toString() == 'a'){
    fill(0,0,255)
} else {
    fill(255,255,255)
}}

I'm actually surprised you got this to work with semicolons... hm

Coder100 (10490)

api test lel
ok so that isn't even valid syntax, keyPressed(s) takes an argument s, but you aren't even using it...
what you should do instead is:

void keyPressed(){
  if (key.toString() == 'a'){
    fill(0,0,255)
} else {
    fill(255,255,255)
}}

I'm actually surprised you got this to work with semicolons... hm