Why can't i create my class after i declare a variable with it?

<

Ball ball;

class Ball {
  
}

I swear this code worked in processing 4.1.1 or maybe 4.0b7 cause that was how the tutorial worked(well the class is in a different file but processing reads it like tht so it does not matter) can someone tell me what changed, please

I this the entire Sketch?

I think that you need setup and draw to run it.

Also, I think you can’t save the Sketch with a name that is also a class name. So save it as Ball1 or BallExample

3 Likes

Hi

1 Like

main pde and the pde with the class must be in the same folder

so, processing does something?

Do you receive an error message or what happens?

1 Like

there is also a small robot exhibition in a shopping mall in Salamanca (for your nephews)

1 Like