Sprites

Mithat Konar

February 29, 2016

Sprites

Download starter project

Basic template


  

Run | Raw code

Sprite creation

Adding a sprite to the canvas


  

Run | Raw code | Differences

Moving sprites

Moving the sprite a little each frame


  

Run | Raw code | Differences

Stop at the edge


  

Run | Raw code | Differences

Bouncing off an edge


  

Run | Raw code | Differences

Bouncing off both edges


  

Run | Raw code | Differences

Bouncing off both edges (improved)


  

Run | Raw code | Differences