VeriorPies/ParrelSync

Wiki Misleading

Jriles opened this issue · 1 comments

#if UNITY_EDITOR
using UnityEngine;
using ParrelSync;

public class MyMultiplayerTestScript: MonoBehaviour
{
    void Start()
    {
        if (ClonesManager.IsClone()) 
        {
          // This is a clone project, connect to local host
        }
        else  
        { 
          // This is the original project, start server
        }
    }
}
#endif

Should be

#if UNITYEDITOR
using UnityEngine;
using ParrelSync;

public class MyMultiplayerTestScript: MonoBehaviour
{
    void Start()
    {
        if (ClonesManager.IsClone()) 
        {
          // This is a clone project, connect to local host
        }
        else  
        { 
          // This is the original project, start server
        }
    }
}
#endif

At least on my version of unity, 2020.3.17, UNITY_EDITOR didn't work for me and really slowed me down

I arrived at this purely though accident