Ive spend the past 20 minuites googling every way i could ask this question and found nothing.
Basically i want to use a case statement to decide what level of pain the player has experienced. I want to do this through a case statment
switch (Damage)
{
case (Damage < 75):
Debug.Log("SmallDMG");
break;
case (Damage >= 75 && Damage < 125):
Debug.Log("Average");
break;
case (Damage >= 125 && Damage <= 750):
Debug.Log("Painfull!");
break;
case (Damage >750):
Debug.Log("MEGA DAMAGE");
break;
}
This way it completely ignores the case statement
switch (Damage)
{
case (<75):
Debug.Log("SmallDMG");
break;
case (>=75 && <125):
Debug.Log("Average");
break;
case (>= 125 && <= 750):
Debug.Log("Painfull!");
break;
case (>750):
Debug.Log("MEGA DAMAGE");
break;
}
And this way it just takes a dump...
How could i do this without making a cluster of if statements, as i understand a case statement is more efficient for multiple comparisons such as this.