Important Notes For Using This Gitbook

Some things to keep in mind as you code along.

Although the code and files will always be up-to-date, the gifs might not be.

If and when Unity releases a new version update, or updates package versions, we will update the code in this gitbook to properly implement the changes, and we will also update the branches of our repo as well (links are always found at bottom of each section of this gitbook).

This means that the code and instructions in this gitbook will always "work" for the specified Unity/packages version.

However unlike the code, we won't be able to re-upload all of the gifs to stay current because then we'd have to rebuild the project from scratch each time Unity or a package updates and screen-record each and every step, and that seems like a full-time job. Instead of spending our time re-uploading gifs, we think that we can better serve the Mixed Reality (XR) community by focusing on building more tools for XR developers rather than making gifs pixel-perfect.

Rule of thumb: always trust the code snippet itself, when following instructions throughout the gitbook; do not fixate on the code within the gif! Why? Because the code in the gif might be old, and it might not be the exact same in the snippet. Trust the code snippet and instructions, not that in the gif! The reason why we included the gifs at all is to provide some comfort in demonstrating that we make the files as described by the instructions; again, the gifs are not meant to be the source of truth.

However, if a new Unity/package update creates a wildly different flow and the gifs start to become debilitatingly misleading, then we will absolutely update them to not throw anyone off. But otherwise, we will just stay focused on updating the instructions and code.

For example, in the middle of us writing this gitbook, DOTS NetCode was updated structurally, so we removed a "GhostCollection" workflow. The workflow would have still worked, but it would not serve the purpose of informing you of the latest-and-greatest. But, always: trust the code snippet and instructions, not the gif!

If you have any questions or comments at all, please join our Discord and let us know. If you are confused while coding along to this gitbook, there are probably also other people who are confused. Let's work together to make it more clear for everyone.

We create most of the external files in Visual Studio Code, our editor of choice

We find that creating files outside of Unity causes less errors with preview packages. Our editor of choice is Visual Studio Code.

One recurring issue we find is that when we create a file by right-clicking in Unity and selecting "Create," Unity sometimes has a tough time updating after the fact, which leads to it spitting out errors and then us needing to "Reimport All" assets.

Accordingly, you'll notice in our gifs that the approach we take to create a file, is to generally (1) duplicate an existing file in VSCode, (2) rename it to the name described in the instructions, then (3) update it with the code snippet.

In the beginning of the gitbook we use the "right-click and select Create" approach to creating files to help illustrate different concepts, but again, it is error-prone, so that's why you'll see that later on in the gitbook we switch to almost exclusively creating new files outside of the Unity Editor.

Poke around! Try stuff out!

Unity ECS is tough. It's hard to wrap your head around in the beginning, so we encourage you to run little experiments throughout the code-along (i.e. by changing Components or Systems) and seeing how the project reacts.

If you find yourself coding along with this gitbook and wondering "what would happen if I changed this to..." then go ahead and change it and see what happens!

Don't be scared to try and implement different things; we provide a link to the branch of the completed code state at the end of each page, so you should feel comfortable taking some risks without fear that you'll screw up your code.

Last updated