summaryrefslogtreecommitdiffstats
path: root/core/dive.c
diff options
context:
space:
mode:
Diffstat (limited to 'core/dive.c')
-rw-r--r--core/dive.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/core/dive.c b/core/dive.c
index 6d5ba1dbb..c4f5dd778 100644
--- a/core/dive.c
+++ b/core/dive.c
@@ -3653,9 +3653,8 @@ fraction_t best_o2(depth_t depth, struct dive *dive)
fraction_t best_He(depth_t depth, struct dive *dive)
{
fraction_t fhe;
- int ead = 30000; //this should be user-configurable
int pnarcotic, ambient;
- pnarcotic = depth_to_mbar(ead, dive);
+ pnarcotic = depth_to_mbar(prefs.bestmixead, dive);
ambient = depth_to_mbar(depth.mm, dive);
fhe.permille = (100 - 100 * pnarcotic / ambient) * 10; //use integer arithmetic to round up to nearest percent
if (fhe.permille < 0)