Category:Locations

Gets a x position and y position from the mouse location on the display.

Clicking on the pin icon on the right of the blocks highlights the display and enables setting a sprite to be created at (or jump to) an exact location. Once the location is chosen, the block will display the x and y position of the center of the sprite.

Examples

The location picker makes it easy to place the sprites in locations that match the background.

Parameters

NameDescription
location The x and y positions of the mouse on the display

Tips

  • The display area is 400 pixels x 400 pixels and the upper left corner is (0,0).

Found a bug in the documentation? Let us know at documentation@code.org