You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
SAE/Assets/Mirror/Examples/AdditiveScenes
flavien ANDRE 12324f371f
en attente de pull
3 years ago
..
AnimationControllers en attente de pull 3 years ago
Materials en attente de pull 3 years ago
Prefabs en attente de pull 3 years ago
Scenes en attente de pull 3 years ago
Scripts en attente de pull 3 years ago
AnimationControllers.meta en attente de pull 3 years ago
Materials.meta en attente de pull 3 years ago
Prefabs.meta en attente de pull 3 years ago
README.md en attente de pull 3 years ago
README.md.meta en attente de pull 3 years ago
Scenes.meta en attente de pull 3 years ago
Scripts.meta en attente de pull 3 years ago

README.md

Additive Scenes Example

IMPORTANT: Make sure you have a layer in project settings called Player for this example to work well.

In Build Settings, remove all scenes and add all of the scenes from the Examples\AdditiveScenes\Scenes folder in the following order:

  • MainScene
  • SubScene

Open the MainScene in the Editor and make sure the Sub Scenes list in the Network scene object contains the SubScene scene. This is already setup by default, but if the MainScene was opened and saved before putting the scenes in the Build Settings list, the Sub Scenes list may be cleared accidentally.

File -> Build and Run

Start up to 3 built instances: These will all be client players.

Press Play in the Editor and click Host (Server + Client) in the HUD

  • This will be the host and the 1st player of up to 4. You can also use Server Only if you prefer.

Click Client in the built instances.

  • WASDQE keys to move & turn your player capsule.
  • There are objects in the corners of the scene hidden by Proximity Checkers.
  • The big area in the middle is where the subscene will be loaded when you get near the shelter.
  • There are also networked objects inside the subscene, also with Proximity Checkers.
  • Since subscenes are only loaded for individual clients, other clients that are outside the middle Zone won't see what those in the subscene can see.
  • If you play a built instance as Host or Server and play as client in the editor, you'll see the subscene content load and unload in the hierarchy as you move in and out of the middle Zone.