Search Unity

Question Handling spawned objects in big worlds [MLAPI]

Discussion in 'Multiplayer' started by Lazy_Evaluation, Oct 21, 2021.

  1. Lazy_Evaluation

    Lazy_Evaluation

    Joined:
    Nov 16, 2019
    Posts:
    16
    Hello guys! How does MLAPI handles spawning only objects close to the player? Let's take as an example a survival with a very big map or infinite world, or an open world. The server obviously has to spawn in itself all the objects of all the players, to handle their data and events, but the players should spawn only nearby objects and entities. However, the .Spawn() method on networkObjects spawns the objects for everyone. So, what's the correct way to handle that situation?