public void NewController()
    {
        ControllerSettings newControl    = new ControllerSettings(NEW_CONTROLLER_NAME, ControlType.Fader, AddressType.CC, ValueRange.SevenBit, DefaultValueType.Min, MIDIChannel.All, CurveType.Linear);
        GameObject         newController = SpawnController(newControl);

        if (newController != null)
        {
            newControl.SetPosition(newController.transform.GetSiblingIndex());
        }
    }
    void SpawnDefaultControllers()
    {
        Debug.Log("Spawning Defaults");
        NukeControllers();
        controllers = new List <ControllerSettings>();

        for (int i = 0; i < defaultControllers.Length; i++)
        {
            ControllerSettings c = new ControllerSettings(defaultControllers[i]);
            c.SetPosition(i);
            controllers.Add(c);
        }

        SpawnControllers(true);
    }
Пример #3
0
 public void SetPosition()
 {
     controllerConfig.SetPosition(controlObjectTransform.GetSiblingIndex());
 }