Why my enemy doesn't work?

I haven’t posted anything about p5js on those 3 links! They’re about Pjs: :dizzy_face:
ProcessingJS.org/reference/

Sorry @GoToLoop i’m still new to processing :neutral_face:

I tried to change the code to this form

/ * @pjs preload = “myimage.jpg”; * /

void setup ()
{
size (200,200);
noLoop ();
}

void draw ()
{
background (255);
PImage im = loadImage (“myimage.jpg”);
image (im, 50.50, 100100);
}

but I don’t know if I did well

it’s no longer the same error

here it is

Please, assets are supposed to be loaded before draw() starts!
Loading stuff @ 60 FPS is calamitous!

I’ve got this 1: “Uncaught ReferenceError: amarelo is not defined”

Please, always state which error you’ve got and, if possible, where it has occurred!

This is the statement which will throw that error later:
PImage im = loadImage(" amarelo1.png ");

There’s no way this String w/ lotsa spaces and tabs can possibly work: " amarelo1.png "

Also, is everything called im now?!

It doesn’t seem you can figure it out just w/ my lousy clues.

This is what I did to your previous sketch (before your attempt changes now) to make it work online:

Move this directive comment to the top of your sketch:
/* @pjs preload= "Background.png,caixa3.png,amarelo1.png,plastico2.png"; */

Change hist.add(pos.copy()); to hist.add(pos.get());