Building a 2D Platformer Game with Godot. Part 3

<p>Previously, in&nbsp;<a href="https://carlosmv.hashnode.dev/building-a-2d-platformer-game-with-godot-part-1" rel="noopener ugc nofollow" target="_blank">part 1</a>&nbsp;of this series, we learned how to create a Godot project and add scenes and nodes. In&nbsp;<a href="https://carlosmv.hashnode.dev/building-a-2d-platformer-game-with-godot-part-2" rel="noopener ugc nofollow" target="_blank">part 2</a>&nbsp;of this series, we learned how to add animation to the player node.</p> <p>In this article, we will add a background to our game.</p> <p>This is going to be a very short article, just focusing on adding background to our game.</p> <p>First, create a new scene, and name it &ldquo;Background&rdquo;.</p> <p>We create a node, and select &ldquo;ParallaxBackground&rdquo;.</p> <p><img alt="" src="https://miro.medium.com/v2/resize:fit:770/0*cMMnY0Y5580DZS7P" style="height:574px; width:700px" /></p> <p>As the&nbsp;<a href="https://docs.godotengine.org/en/stable/classes/class_parallaxbackground.html" rel="noopener ugc nofollow" target="_blank">documentation</a>&nbsp;says,&nbsp;<code>ParallaxBackground</code>&nbsp;uses one or more&nbsp;<code>ParallaxLayer</code>&nbsp;child nodes to create a parallax effect. Each ParallaxLayer can move at a different speed using&nbsp;<code>ParallaxLayer.motion_offset</code>. This creates an illusion of depth in a 2D game. If not used with a Camera2D, you must manually calculate the scroll_offset.</p> <p><a href="https://medium.com/@carlosmarcano2704/building-a-2d-platformer-game-with-godot-part-3-d97b04622b54"><strong>Website</strong></a></p>