예제 #1
0
    // Start is called before the first frame update
    private IEnumerator Start()
    {
        studioReceiver = new StudioReceiver();
        studioReceiver.receivePortNumber = receivePort;
        studioReceiver.Initialize();
        studioReceiver.StartListening();
        studioReceiver.onStudioDataReceived += StudioReceiver_onStudioDataReceived;

        if (actorPrefab != null)
        {
            actors = new PrefabInstancer <string, Actor>(actorPrefab, this.transform);
        }

        if (propPrefab != null)
        {
            props = new PrefabInstancer <string, Prop>(propPrefab, this.transform);
        }

        yield return(null);

        if (actorOverrides.Count == 0)
        {
            Debug.Log("No custom characters found. Will generate scene from default ones");
        }
    }
예제 #2
0
        // Start is called before the first frame update
        void Start()
        {
            // Destroy children before PrefabInstancer creates the pool
            prefabContainer.DestroyChildren();

            rows = new PrefabInstancer <string, InputHierarchyRow>(rowPrefab, prefabContainer, 3);
        }