private void Start() { const bool NOT_CONNECTED = false; _connectionIndicator.DisplayStatus(NOT_CONNECTED); var args = new[] { RemoteAgentActivator.VERBOSE_ACTIVATION_ARGUMENT_ARG }; _host = RemoteAgentActivator.TryActivate(args); _host.OnConnectionChanged += _connectionIndicator.DisplayStatus; }
public void SetUp() { var rootGO = new GameObject("rootGo"); var canvasGO = new GameObject("Canvas", typeof(Canvas)); canvasGO.transform.SetParent(rootGO.transform); var canvas = canvasGO.GetComponent <Canvas>(); canvas.referencePixelsPerUnit = 100; GameObject eventSystemGO = new GameObject("EventSystem", typeof(EventSystem)); eventSystemGO.transform.SetParent(rootGO.transform); GameObject testButtonGO = new GameObject("TestButton", typeof(RectTransform), typeof(Button)); testButtonGO.transform.SetParent(canvasGO.transform); _agent = new RemoteUnityAgentHost(); _rootGO = rootGO; }