Skip to content

Glide smoothly to a point

Unlike goto, which jumps instantly, glide animates the sprite to a position over a number of seconds.

whenGreenFlag(() => {
glide(1, 100, 50);
});

This slides the sprite to (100, 50) over one second.

  • glide — animate to a position over time