# Events

## Canvas&#x20;

### When Canvas Loads

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MABW-iDNOBs_HTDwEdD%2F-MABXHB3DhD2pxLYICuI%2Fevnt_loads.png?alt=media\&token=0cdf8e50-ab47-4d4d-b7ad-f02af0cf0d88)

&#x20;Program an action after the canvas loads.

### When Canvas Touched

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MABW-iDNOBs_HTDwEdD%2F-MABXP4m9HtbESq2mzqR%2Fevnt_down.png?alt=media\&token=84dd4d4d-4ebe-45d4-be48-b5161996ead6)

Program an action when the user touches the canvas

## Sprites

Please note, that for the sprite events, event handlers can be configured to work with an entire type of sprite or just with one specific sprite.&#x20;

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MABW-iDNOBs_HTDwEdD%2F-MABZNeNMhOl2DRYRSjg%2Ftypes_explained.png?alt=media\&token=3b9e0fe2-8d0e-48da-bc67-ba5b8a741b68)

### Sprite Clicked&#x20;

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MABW-iDNOBs_HTDwEdD%2F-MABYVLX_PIEmBQqacWB%2Fevnt_clicked.png?alt=media\&token=88b8fb61-8501-407c-aa77-46d59ef7e835)

This event triggers when the sprite is clicked.

### Collision with Sprite&#x20;

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MABW-iDNOBs_HTDwEdD%2F-MABYbQdlei-aaYbrql3%2Fevnt_collide_sprite.png?alt=media\&token=168e730e-6fc3-4de8-9218-7e552c697648)

This event triggers when the two sprites collide.

### Collision with Edge&#x20;

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MABW-iDNOBs_HTDwEdD%2F-MABYmHESFe2vZv-mpcS%2Fevnt_collide_edge.png?alt=media\&token=3da3cf41-cf1f-4fc5-8cfc-5949f7aa63fb)

This event triggers when the sprite collides with the edge.

### Sprite Dropped

![](https://689802330-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LAn5scXl2uqUJUOqkJo%2F-MABW-iDNOBs_HTDwEdD%2F-MABYuy1oXPvBSVvER8J%2Fevnt_dropped.png?alt=media\&token=c3c85c43-6923-46ff-9031-3c6e051eb669)

This event triggers when the user stops dragging the sprite.

##
