O'Reilly logo

HoloLens Beginner’s Guide by Jason Odom

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Filling in the blanks

In this section, we will finally make sure that our network code can understand our object by spawning it with network-friendly code. Instead of turning our skee object on or off based on certain conditions, we will spawn it into the game using the PrefabSpawnManager.

The PrefabSpawnManager class takes a Prefab and converts it into data types that can easily be translated across a network. This makes for a far more efficient use of objects:

To begin, click on that Add Component button shown in the preceding screenshot. Scroll down to New Script, type SyncSpawnSkee in the box, make sure that C Sharp is selected, and click ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required