public BodypartClass(bodyPartsSlot body, int num, healthStatus status, float currHP, EquipmentClass slot, List <EquipmentClass> slot2) { bodySlot = body; numOfSecSlot = num; currHealthStats = status; currHealth = currHP; priSlot = slot; secSlot = slot2; }
public BodypartClass() { //DEFAULT bodySlot = bodyPartsSlot.none; numOfSecSlot = -999; currHealthStats = healthStatus.none; currHealth = 1.0f; priSlot = null; secSlot = null; }
internal string calcStatus() { string[] status = Enum.GetNames(typeof(healthStatus)); healthStatus s = 0; if (health.currentLevel == health.normalLevel) { s = healthStatus.Untouched; } else if (health.currentLevel > 0.9 * health.normalLevel) { s = healthStatus.Scratched; } else if (health.currentLevel > .75 * health.normalLevel) { s = healthStatus.Bruised; } else if (health.currentLevel > .50 * health.normalLevel) { s = healthStatus.Scarred; } else if (health.currentLevel > .20 * health.normalLevel) { s = healthStatus.Severe; } else if (health.currentLevel > 0) { s = healthStatus.Critical; } return(status[(int)s]); }