Example #1
0
    void Start()
    {
        GameController.OnlineDel += testExe;//

        lineRenderer = GetComponent <LineRenderer>();
        // Controllers
        manualInputControl = GetComponent <ManualInputControl>();
        selectionControl   = GetComponent <SelectionControl>();
        targetControl      = GetComponent <TargetControl>();
        commandControl     = GetComponent <CommandControl>();
        panelControl       = GetComponent <PanelControl>();

        //selectionControl.SetActiveAxis(target, false);
        axisCamera.SetActive(true);


        defaultPosition = target.position;
        target.GetComponent <ClampName>().textPanel.gameObject.SetActive(false);
        target.gameObject.SetActive(false);
        // Initial target

        //Destroy(target.GetComponent<ClampName>().textPanel.gameObject);
        //Destroy(target.gameObject);
        //SetTarget(targetControl.GetTarget(0));
        //selectionControl.SetActiveAxis(targetControl.GetTarget(0), false);


        UpdateTargets(targetControl.GetNames());

        commandsDropdown.AddOptions(commandControl.GetNames());
        CommandsDropdown_IndexChanged(0);
    }
 void Start()
 {
     // Controllers
     manualInputControl = GetComponent <ManualInputControl>();
     // Panels
     manualControlPanel = GetComponent <GameController>().manualControlPanel.GetComponent <Animator>();
     commandsPanel      = GetComponent <GameController>().commandsPanel.GetComponent <Animator>();
     console            = GetComponent <GameController>().console.GetComponent <Animator>();
     syncPanel          = GetComponent <GameController>().syncPanel.GetComponent <Animator>();
     messageLogPanel    = GetComponent <GameController>().messageLogPanel.GetComponent <Animator>();
     positionLogPanel   = GetComponent <GameController>().positionLogPanel.GetComponent <Animator>();
 }
    void Start()
    {
        // Drawing tool
        lineRenderer = GetComponent <LineRenderer>();
        // Controllers
        manualInputControl  = GetComponent <ManualInputControl>();
        selectionControl    = GetComponent <SelectionControl>();
        targetControl       = GetComponent <TargetControl>();
        commandControl      = GetComponent <CommandControl>();
        panelControl        = GetComponent <PanelControl>();
        stateMessageControl = GetComponent <StateMessageControl>();
        cameraControl       = GetComponent <CameraControl>();
        backupFileControl   = GetComponent <BackUpFileControl>();
        effectorFileControl = GetComponent <EffectorFileControl>();

        // Initial config
        cameraControl.SetIsProcessing(true);//
        axisCamera.SetActive(true);

        defaultPosition = target.position;
        target.GetComponent <ClampName>().textPanel.gameObject.SetActive(false);
        target.gameObject.SetActive(false);
        SetTarget(null);
        UpdateTargets(targetControl.GetNames());

        // Get commands names
        commandsDropdown.AddOptions(commandControl.GetNames());
        CommandsDropdown_IndexChanged(0);

        byXYZPRDropdown.AddOptions(new List <string>()
        {
            "X", "Y", "Z", "P", "R"
        });

        // Ports list
        portsDropdown.AddOptions(new List <string>(controller.List_Ports()));

        // Scorbot ER IX version list
        scorbotVersionDropdown.AddOptions(new List <string>()
        {
            "Original"
        });
    }