engine/calculators/source/AlcoholCalculator.cpp
// A creature is drunk if its BAC is greater than 0.08...
A creature is drunk if its BAC is greater than 0.08
A creature is drunk if its BAC is greater than 0 . 08
bool AlcoholCalculator::is_drunk(CreaturePtr creature)
{
  bool drunk = false;
  if (creature)
  {
    float bac = creature->get_blood().get_blood_alcohol_content();
    if (bac > DRUNK_BAC_THRESHOLD)
    { 
      drunk = true;
    }
  }
  return drunk;
}
bool AlcoholCalculator :: is_drunk ( CreaturePtr creature ) { bool drunk = false ; if ( creature ) { float bac = creature -> get_blood ( ) . get_blood_alcohol_content ( ) ; if ( bac > DRUNK_BAC_THRESHOLD ) { drunk = true ; } } return drunk ; }
A creature is drunk if its BAC is greater than 0.08...
A creature is drunk if its BAC is greater than 0 . 08 ...