Example #1
0
    public void IncrementProgress(int a_amount = 1)
    {
        // Adds a_amount to the ritual contribution
        ritualContribution += a_amount;

        // Updates the progress bar
        if (ritualContribution >= 50)
        {
            ritualBar.value   = ritualBar.maxValue;
            hasFinishedRitual = true;
            Debug.Log(player.ToString() + " player has completed their ritual!");
        }
        ritualBar.value = ritualContribution;

        // Updates GameManager
        GameManager.instance.IncrementProgress(a_amount);
    }
 public void SetControllerID(XboxController controllerID)
 {
     this.CurrentController = controllerID;
     Debug.Log(controllerID.ToString());
 }