# Motion

## Speed&#x20;

### Set Speed To&#x20;

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABbNLCkmkb75wJfF9j%2Fmov_set_speed_to.png?alt=media\&token=05cad410-e82a-4c19-8e98-0bbf254bc537)

Set the X or Y value for the sprite's speed to a particular value.

### Change Speed By&#x20;

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABbXV-bi1DnseowqsB%2Fmov_set_speed_to2.png?alt=media\&token=a50aa7eb-b211-4294-858d-96bf55214a54)

Change the X or Y value for the sprite's speed by a specific amount.

### Get Speed&#x20;

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABbq1Qpo_GF5F3fKmN%2Fmov_get_speed.png?alt=media\&token=53c15210-e4f8-4d14-ab2a-55f6098ca016)

Get the X or Y value for the sprite's speed.

###

### Set Velocity

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABbyixfWcsHBbElDyb%2Fmov_set_speed.png?alt=media\&token=5dbd2865-7376-43d2-8396-67c80b584d48)

Set or change the sprite's velocity, by a given amount, in the pointing or moving direction.

## Position&#x20;

### Move Sprite To

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABcGToVFK75i9R1eIg%2Fmov_move_to.png?alt=media\&token=e3ffb6cd-fbe3-4ad8-86fe-8fb213ca56c5)

Move the sprite to the x and y location specified in the block

### Set Sprite Position

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABca40VDesXSA7iY6w%2Fmov_set_coord.png?alt=media\&token=ca2cc347-18cd-45ea-b889-7b00de807297)

Set the sprite's X, Y, Z or Angle value to a specific position.

Change the sprites X, Y, Z or Angle value by a given amount.

**Note**: Sprite angle is measured in degrees, so should be a value between 0 and 360.&#x20;

### Get Sprite Position

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABcwfhgI4Yd5DZ_wIm%2Fmov_get_coord.png?alt=media\&token=e261e28f-dc7c-4199-a6fb-7bf2dd7b08c7)

Get the sprite's current X, Y, Z or Angle value.

**Note**: Sprite angle is measured in degrees, so should be a value between 0 and 360

## Pointer

### Get Pointer Value

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABi6aWncOqQ0eZB0Iz%2Fmov_pointer.png?alt=media\&token=085c045a-2fb4-4363-ac72-57a40162263a)

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABi8fUe-U2IZOR3Myq%2Fmov_pointer2.png?alt=media\&token=301c5a4e-74eb-4b45-9918-3864f17718ce)

Get the X, Y, or Angle of the where the user tapped on the canvas

## Behavior

On the canvas, it's possible to make a sprite either draggable or to have it fixed in position.

Similarly, it's possible for other sprites to pass through a sprite, or it can be made impassable.&#x20;

Finally, if a sprite is moving, it's possible to programatically cause it to stop moving.&#x20;

### Set Draggable or Passable&#x20;

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABiY0QramOw-TbZMCP%2Fmov_set_draggable.png?alt=media\&token=29479268-a112-477a-9546-dd9ddebdbc14)

Set the draggability or passability of the sprit

### Get Draggable or Passable

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABj6A6rTza8GGAlTiI%2Fmov_get_draggable.png?alt=media\&token=aa6bab02-1a8a-4617-84e8-f40186b28c79)

Get draggability of the sprite

### Stop All Sprites

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MAB_XO-bfOXgODJbWqz%2F-MABjHA0ksFB-362fv06%2Fmov_stop_sprites.png?alt=media\&token=9d29b4da-b8cb-4c13-b3c5-a2c02f704080)

Stop all sprites that are moving.

## Examples

### Move Sprite to Pointer

When the user clicks on the canvas these blocks will move the `Sprite1` to the location that was touched.&#x20;

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MDFjplR1ug2ybHsrKps%2F-MDFk3tmpb10h8taV6lg%2Fmove_sprite_to.png?alt=media\&token=edc63f3f-86ec-4f07-8d52-cb139de38d7e)
