mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-28 05:00:20 +00:00
Planner: fix incorrect gas change event
We stored the He permille instead of the He percentage. But for most casual testing this was hidden by the previous bug. Reported-by: Robert C. Helling <helling@atdotde.de> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
8527720794
commit
ac38aa0243
1 changed files with 1 additions and 1 deletions
|
@ -294,7 +294,7 @@ struct dive *create_dive_from_plan(struct diveplan *diveplan)
|
|||
int planhe = (he + 5) / 10 * 10;
|
||||
int value;
|
||||
add_gas(dive, plano2, planhe);
|
||||
value = (plano2 / 10) | (planhe << 16);
|
||||
value = (plano2 / 10) | ((planhe / 10) << 16);
|
||||
add_event(dc, lasttime, 25, 0, value, "gaschange"); // SAMPLE_EVENT_GASCHANGE2
|
||||
oldo2 = o2; oldhe = he;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue