<aside> <img src="/icons/reorder_gray.svg" alt="/icons/reorder_gray.svg" width="40px" /> Navigation
</aside>
Shaders, Effects, Optimization
The subworld is a mini-location inside the world, not connected directly to a mainland. Subworld can be visually represented like for example a separate island, a cave, an interior of the building, etc.
In the template, the subworld is used as a tent interior.
The easiest way to start working on the subworld is using a premade subworld prefab called [Subworld Placeholder] located in the Assets/Project Files/Game/Prefabs/Level
folder.
Drag into the world scene and name accordingly.
Additionally, the prefab can be unpacked. Now subworld is ready for customization.
Locate somewhere Subworld Entrance object to be able to enter a subworld, the prefab is located in the Assets/Project Files/Game/Prefabs/Level
folder. It can be inside the building (check the example in the Tent) or simply on the ground (an example is the entrance to the cave).
All subworld elements should be located inside an object with Subworld Behavior and NavMeshSurface components.
Subworld Behavior fields:
Subworld Exit - this special object has a trigger that will teleport the player from the subworld to the main world. The player will be spawned near the point that was used to enter the subworld. Subworld requires at least one, so the player can return to the mainland.
Prefab is located in the Assets/Project Files/Game/Prefabs/Level
folder, you can customize its appearance by replacing graphics located inside the Visuals object. You can also adjust the collider size, to increase or decrease the trigger area.
The Subworld Exit script has only 2 variables.
<aside> <img src="/icons/info-alternate_blue.svg" alt="/icons/info-alternate_blue.svg" width="40px" /> You can customize the subworld similarly to the world: add land, buildings, resources, helpers, enemies, etc.
</aside>