comparison src/p2_deco.c @ 641:1212d39c9f6f

3.14 beta work
author heinrichsweikamp
date Sat, 21 Nov 2020 17:46:29 +0100
parents 8c1f1f334275
children 1e695355dfc4
comparison
equal deleted inserted replaced
640:8c1f1f334275 641:1212d39c9f6f
1573 // 1573 //
1574 // Return value is TRUE if a better gas is available 1574 // Return value is TRUE if a better gas is available
1575 // 1575 //
1576 static unsigned char gas_find_best(void) 1576 static unsigned char gas_find_best(void)
1577 { 1577 {
1578 overlay unsigned char switch_depth = 255; 1578 overlay unsigned char switch_depth = sim_gas_current_depth;
1579 overlay unsigned char switch_gas = 0; 1579 overlay unsigned char switch_gas = 0;
1580 1580
1581 1581
1582 // loop over all gases to find the shallowest one below or at current depth 1582 // loop over all gases to find the shallowest one below or at current depth
1583 for( j = 0; j < NUM_GAS; ++j ) 1583 for( j = 0; j < NUM_GAS; ++j )