dump_valve( false ),
brake_left( 0.0 ),
brake_right( 0.0 ),
+ copilot_brake_left( 0.0 ),
+ copilot_brake_right( 0.0 ),
brake_parking( 0.0 ),
steering( 0.0 ),
gear_down( true ),
set_augmentation( ALL_ENGINES, false );
set_reverser( ALL_ENGINES, false );
set_water_injection( ALL_ENGINES, false );
- set_condition( ALL_ENGINES, 0 );
+ set_condition( ALL_ENGINES, 1.0 );
throttle_idle = true;
set_fuel_selector( ALL_TANKS, true );
dump_valve = false;
water_injection[engine] = false;
nitrous_injection[engine] = false;
cowl_flaps_norm[engine] = 0.0;
- condition[engine] = 0;
+ condition[engine] = 1.0;
}
- brake_left = brake_right = brake_parking = 0.0;
+ brake_left = brake_right
+ = copilot_brake_left = copilot_brake_right
+ = brake_parking = 0.0;
for ( int wheel = 0; wheel < MAX_WHEELS; wheel++ ) {
alternate_extension[wheel] = false;
}
&FGControls::set_cowl_flaps_norm);
fgSetArchivable(name);
- snprintf(name, MAX_NAME_LEN, "/controls/engines/engine[%d]/feather", index);
+ snprintf(name, MAX_NAME_LEN,
+ "/controls/engines/engine[%d]/propeller-feather", index);
fgTie(name, this, index,
&FGControls::get_feather, &FGControls::set_feather);
fgSetArchivable(name);
&FGControls::set_brake_right);
fgSetArchivable("/controls/gear/brake-right");
+ fgTie("/controls/gear/copilot-brake-left", this,
+ &FGControls::get_copilot_brake_left,
+ &FGControls::set_copilot_brake_left);
+ fgSetArchivable("/controls/gear/copilot-brake-left");
+
+ fgTie("/controls/gear/copilot-brake-right", this,
+ &FGControls::get_copilot_brake_right,
+ &FGControls::set_copilot_brake_right);
+ fgSetArchivable("/controls/gear/copilot-brake-right");
+
fgTie("/controls/gear/brake-parking", this,
&FGControls::get_brake_parking,
&FGControls::set_brake_parking);
snprintf(name, MAX_NAME_LEN,
"/controls/engines/engine[%d]/cowl-flaps-norm", index);
fgUntie(name);
- snprintf(name, MAX_NAME_LEN, "/controls/engines/engine[%d]/feather", index);
+ snprintf(name, MAX_NAME_LEN,
+ "/controls/engines/engine[%d]/propeller-feather", index);
fgUntie(name);
snprintf(name, MAX_NAME_LEN,
"/controls/engines/engine[%d]/ignition", index);
}
void
-FGControls::set_condition( int engine, int val )
+FGControls::set_condition( int engine, double val )
{
if ( engine == ALL_ENGINES ) {
for ( int i = 0; i < MAX_ENGINES; i++ ) {
condition[i] = val;
- CLAMP( &condition[i], 0, 3 );
}
} else {
if ( (engine >= 0) && (engine < MAX_ENGINES) ) {
condition[engine] = val;
- CLAMP( &condition[engine], 0, 3 );
}
}
}
CLAMP( &brake_right, 0.0, 1.0 );
}
+void
+FGControls::set_copilot_brake_left( double pos )
+{
+ copilot_brake_left = pos;
+ CLAMP(&brake_left, 0.0, 1.0);
+}
+
+void
+FGControls::set_copilot_brake_right( double pos )
+{
+ copilot_brake_right = pos;
+ CLAMP(&brake_right, 0.0, 1.0);
+}
+
void
FGControls::set_brake_parking( double pos )
{