Game Development Reference
In-Depth Information
Objective complete - mini debriefing
Basically, what we have done here is create a Background object and the Level object, and
set each platform that attached Box Collider 2D and Polygon Collider 2D , which we will
use to check the collision and make our player walkable on the platform. We also set the
Order in Layer in the Sprite Renderer component to get the correct depth from the back-
ground to foreground, as shown in the following diagram:
We also adjust and remove the vertices of Polygon Collider 2D by holding the Shift or
Ctrl / command key. Then, we create the Edge object that uses a different Physics2D Materi-
al from the platform object, which is used to prevent our player from getting stuck on the
platform's edge.
Search WWH ::




Custom Search