// Activate certain points in research. public void ActivateTierOneRankOne() { if (devil_Controller.GetSins() > 50) { devil_Controller.SpendSins(50); devil_Controller._sinEfficency += 0.1; } }
public IEnumerator SpendSinsNegativeParameterThrowsArguementException() { Devil_Controller devil_Controller = new Devil_Controller(); yield return(null); var startingSins = devil_Controller.GetSins(); devil_Controller.SpendSins(-200f); var endingSins = devil_Controller.GetSins(); Debug.Log($"Starting sins: {startingSins}. Ending Sins: {endingSins}."); Assert.Throws(typeof(System.ArgumentException), new TestDelegate(devil_Controller.SpendSins(-200f))); }
private void SetSinsPrayersText() { if (devil_Controller.isPlayerControlled) { sinsPrayersText.text = "Sins: " + Math.Floor(devil_Controller.GetSins()) + " Million"; } else if (god_Controller.isPlayerControlled) { } else { throw new System.Exception("The player isn't controlling the god or devil class."); } }