Esempio n. 1
0
    /// <summary>
    /// Called every step of the program to listen to input commands for various features
    /// </summary>
    public override void Update()
    {
        //If the reset button is held down after a certain amount of time, then go into change spawnpoint mode (reset spawnpoint feature)
        //Otherwise, reset the robot normally (quick reset feature)
        if (!activeRobot.IsResetting)
        {
            if (Input.GetKeyDown(KeyCode.U))
            {
                LoadRobot(robotPath);
            }
            if (Input.GetKeyDown(KeyCode.Y))
            {
                SwitchActiveRobot();
            }
        }

        // Toggles between the different camera states if the camera toggle button is pressed
        if ((InputControl.GetButtonDown(Controls.buttons[0].cameraToggle)))
        {
            if (dynamicCameraObject.activeSelf && DynamicCamera.MovingEnabled)
            {
                dynamicCamera.ToggleCameraState(dynamicCamera.cameraState);
            }
        }

        // Switches to replay mode
        if (!activeRobot.IsResetting && Input.GetKeyDown(KeyCode.Tab))
        {
            contactPoints.Add(null);
            StateMachine.Instance.PushState(new ReplayState(fieldPath, robotPath, contactPoints, Trackers));
        }

        UpdateTrackers();
    }
Esempio n. 2
0
 public void AddDay(DayInTheMarket day)
 {
     queue365.Add(day);
     queue180.Add(day);
     queue90.Add(day);
     queue30.Add(day);
     queue10.Add(day);
     queue5.Add(day);
     if (day.MarketDate.Month == 1)
     {
         int sw = 2;
     }
     if (day.MarketDate.Month == 2)
     {
         int ssw = 2;
     }
     int s = 1;
 }
Esempio n. 3
0
 public void AddItem(PowerUp newItem)
 {
     items.Add(newItem);
 }