HTML and CSS Reference
In-Depth Information
This is because of how we see things in the perspecive view. In the digital world, we call this
parallax scrolling.
Therefore, when we are moving game objects around, we can make use of the speed
differences to create an illusion of depth.
In our game, the background is something far away in space. The movement of the
background should move much slower than the player's running speed.
The normal speed is 50. We can set the background movement speed to be 1/10 of
the normal speed:
object in the foreground
reference
object in the foreground
object in the foreground
object in the background
object in the background
object in the background
When the camera moves, objects in the foreground move
relatively faster than the ones in the background.
 
Search WWH ::




Custom Search