17
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-11-06 02:18:35 +01:00

refactor(sonar): mark unused parameters (cpp:S1172)

Unused names are commented out; parameters used only on some platforms
are marked [[maybe_unused]].
This commit is contained in:
jerrrrycho
2026-10-10 15:18:45 +02:00
parent ad32f1f840
commit 01d2b9bf82
12 changed files with 128 additions and 128 deletions

View File

@@ -1483,7 +1483,7 @@ double TMoverParameters::ComputeMovement(double dt, double dt1, const TTrackShap
// Oblicza przemieszczenie taboru - uproszczona wersja // Oblicza przemieszczenie taboru - uproszczona wersja
// ************************************************************************************************* // *************************************************************************************************
double TMoverParameters::FastComputeMovement(double dt, const TTrackShape &Shape, TTrackParam &Track, TLocation const &NewLoc, TRotation const &NewRot) double TMoverParameters::FastComputeMovement(double dt, const TTrackShape & /*Shape*/, TTrackParam & /*Track*/, TLocation const &NewLoc, TRotation const &NewRot)
{ {
int b; int b;
// T_MoverParameters::FastComputeMovement(dt, Shape, Track, NewLoc, NewRot); // T_MoverParameters::FastComputeMovement(dt, Shape, Track, NewLoc, NewRot);
@@ -1731,7 +1731,7 @@ void TMoverParameters::MainsCheck(double const Deltatime)
} }
} }
void TMoverParameters::LowVoltagePowerCheck(double const Deltatime) void TMoverParameters::LowVoltagePowerCheck(double const /*Deltatime*/)
{ {
auto const lowvoltagepower{Power24vIsAvailable || Power110vIsAvailable}; auto const lowvoltagepower{Power24vIsAvailable || Power110vIsAvailable};
@@ -1756,7 +1756,7 @@ void TMoverParameters::LowVoltagePowerCheck(double const Deltatime)
} }
} }
void TMoverParameters::PowerCouplersCheck(double const Deltatime, coupling const Coupling) void TMoverParameters::PowerCouplersCheck(double const /*Deltatime*/, coupling const Coupling)
{ {
if (Coupling != coupling::highvoltage && Coupling != coupling::power110v && Coupling != coupling::power24v) if (Coupling != coupling::highvoltage && Coupling != coupling::power110v && Coupling != coupling::power24v)
{ {
@@ -2086,7 +2086,7 @@ void TMoverParameters::ConverterCheck(double const Timestep)
}; };
// heating system status check // heating system status check
void TMoverParameters::HeatingCheck(double const Timestep) void TMoverParameters::HeatingCheck(double const /*Timestep*/)
{ {
// update heating devices // update heating devices
@@ -2172,7 +2172,7 @@ void TMoverParameters::HeatingCheck(double const Timestep)
} }
// water pump status check // water pump status check
void TMoverParameters::WaterPumpCheck(double const Timestep) void TMoverParameters::WaterPumpCheck(double const /*Timestep*/)
{ {
// NOTE: breaker override with start type is sm42 specific hack, replace with ability to define the presence of the breaker // NOTE: breaker override with start type is sm42 specific hack, replace with ability to define the presence of the breaker
WaterPump.is_active = true == (Power24vIsAvailable || Power110vIsAvailable) && true == WaterPump.breaker && false == WaterPump.is_disabled && WaterPump.is_active = true == (Power24vIsAvailable || Power110vIsAvailable) && true == WaterPump.breaker && false == WaterPump.is_disabled &&
@@ -2180,7 +2180,7 @@ void TMoverParameters::WaterPumpCheck(double const Timestep)
} }
// water heater status check // water heater status check
void TMoverParameters::WaterHeaterCheck(double const Timestep) void TMoverParameters::WaterHeaterCheck(double const /*Timestep*/)
{ {
WaterHeater.is_active = false == WaterHeater.is_damaged && true == (Power24vIsAvailable || Power110vIsAvailable) && true == WaterHeater.is_enabled && true == WaterHeater.breaker && WaterHeater.is_active = false == WaterHeater.is_damaged && true == (Power24vIsAvailable || Power110vIsAvailable) && true == WaterHeater.is_enabled && true == WaterHeater.breaker &&
@@ -2195,7 +2195,7 @@ void TMoverParameters::WaterHeaterCheck(double const Timestep)
} }
// fuel pump status update // fuel pump status update
void TMoverParameters::FuelPumpCheck(double const Timestep) void TMoverParameters::FuelPumpCheck(double const /*Timestep*/)
{ {
FuelPump.is_active = true == (Power24vIsAvailable || Power110vIsAvailable) && false == FuelPump.is_disabled && FuelPump.is_active = true == (Power24vIsAvailable || Power110vIsAvailable) && false == FuelPump.is_disabled &&
@@ -2294,7 +2294,7 @@ void TMoverParameters::MotorBlowersCheck(double const Timestep)
} }
} }
void TMoverParameters::PantographsCheck(double const Timestep) void TMoverParameters::PantographsCheck(double const /*Timestep*/)
{ {
{ {
@@ -2332,7 +2332,7 @@ void TMoverParameters::PantographsCheck(double const Timestep)
} }
} }
void TMoverParameters::LightsCheck(double const Timestep) void TMoverParameters::LightsCheck(double const /*Timestep*/)
{ {
auto &light{CompartmentLights}; auto &light{CompartmentLights};
@@ -4848,7 +4848,7 @@ void TMoverParameters::UpdateScndPipePressure(double dt)
// yB: 20190906 // yB: 20190906
// Aktualizacja ciśnienia w hamulcu sprezynowym // Aktualizacja ciśnienia w hamulcu sprezynowym
// ************************************************************************************************* // *************************************************************************************************
void TMoverParameters::UpdateSpringBrake(double dt) void TMoverParameters::UpdateSpringBrake(double /*dt*/)
{ {
double BP = SpringBrake.PNBrakeConnection ? BrakePress : 0; double BP = SpringBrake.PNBrakeConnection ? BrakePress : 0;
double MSP = SpringBrake.ShuttOff ? 0 : SpringBrake.MaxSetPressure; double MSP = SpringBrake.ShuttOff ? 0 : SpringBrake.MaxSetPressure;
@@ -5200,7 +5200,7 @@ double TMoverParameters::BrakeForceP(double press, double velocity)
// Q: 20160713 // Q: 20160713
// oblicza siłę na styku koła i szyny // oblicza siłę na styku koła i szyny
// ************************************************************************************************* // *************************************************************************************************
double TMoverParameters::BrakeForce(TTrackParam const &Track) double TMoverParameters::BrakeForce(TTrackParam const & /*Track*/)
{ {
double K{0}; double K{0};
@@ -11776,7 +11776,7 @@ TEngineType TMoverParameters::LoadFIZ_EngineDecode(std::string const &Engine)
// Q: 20160717 // Q: 20160717
// ************************************************************************************************* // *************************************************************************************************
bool TMoverParameters::CheckLocomotiveParameters(bool ReadyFlag, int Dir) bool TMoverParameters::CheckLocomotiveParameters(bool ReadyFlag, int /*Dir*/)
{ {
WriteLog("check locomotive parameters..."); WriteLog("check locomotive parameters...");
int b; int b;

View File

@@ -294,7 +294,7 @@ double TNESt3::GetPF( double const PP, double const dt, double const Vel ) // pr
return dV - dV1; return dV - dV1;
} }
void TNESt3::EStParams( double const i_crc ) // parametry charakterystyczne dla ESt void TNESt3::EStParams( double const /*i_crc*/ ) // parametry charakterystyczne dla ESt
{ {
} }
@@ -331,7 +331,7 @@ double TNESt3::GetCRP()
// return Miedzypoj.P; // return Miedzypoj.P;
} }
void TNESt3::CheckState(double const BCP, double &dV1) // glowny przyrzad rozrzadczy void TNESt3::CheckState(double const BCP, double & /*dV1*/) // glowny przyrzad rozrzadczy
{ {
double const BVP{ BrakeRes->P() }; //-> tu ma byc komora rozprezna double const BVP{ BrakeRes->P() }; //-> tu ma byc komora rozprezna
double const VVP{ ValveRes->P() }; double const VVP{ ValveRes->P() };
@@ -384,7 +384,7 @@ void TNESt3::CheckReleaser(double const dt) // odluzniacz
} }
} }
double TNESt3::CVs(double const BP) // napelniacz sterujacego double TNESt3::CVs(double const /*BP*/) // napelniacz sterujacego
{ {
double const CVP{ CntrlRes->P() }; double const CVP{ CntrlRes->P() };
double const MPP{ Miedzypoj->P() }; double const MPP{ Miedzypoj->P() };

View File

@@ -854,7 +854,7 @@ void TESt::CheckReleaser(double const dt)
/// </summary> /// </summary>
/// <param name="BCP">Brake cylinder (or impulse-chamber) pressure.</param> /// <param name="BCP">Brake cylinder (or impulse-chamber) pressure.</param>
/// <param name="dV1">In/out brake-pipe flow correction (unused in this base impl).</param> /// <param name="dV1">In/out brake-pipe flow correction (unused in this base impl).</param>
void TESt::CheckState(double const BCP, double &dV1) void TESt::CheckState(double const BCP, double & /*dV1*/)
{ {
double const VVP{ValveRes->P()}; double const VVP{ValveRes->P()};
@@ -1086,7 +1086,7 @@ void TESt::Init(double const PP, double const HPP, double const LPP, double cons
/// derived variants and currently a no-op. /// derived variants and currently a no-op.
/// </summary> /// </summary>
/// <param name="i_crc">Characteristic value.</param> /// <param name="i_crc">Characteristic value.</param>
void TESt::EStParams(double const i_crc) {} void TESt::EStParams(double const /*i_crc*/) {}
/// <summary>Returns the control reservoir (ZS) pressure.</summary> /// <summary>Returns the control reservoir (ZS) pressure.</summary>
double TESt::GetCRP() double TESt::GetCRP()
@@ -2502,7 +2502,7 @@ void TKE::CheckReleaser(double const dt)
/// </summary> /// </summary>
/// <param name="BCP">Cylinder (or impulse-chamber) pressure.</param> /// <param name="BCP">Cylinder (or impulse-chamber) pressure.</param>
/// <param name="dV1">In/out brake-pipe flow correction (unused here).</param> /// <param name="dV1">In/out brake-pipe flow correction (unused here).</param>
void TKE::CheckState(double const BCP, double &dV1) void TKE::CheckState(double const BCP, double & /*dV1*/)
{ {
double VVP; double VVP;
double BVP; double BVP;
@@ -2604,7 +2604,7 @@ double TKE::CVs(double const BP)
/// </summary> /// </summary>
/// <param name="BCP">Impulse-chamber pressure.</param> /// <param name="BCP">Impulse-chamber pressure.</param>
/// <returns>Opening coefficient.</returns> /// <returns>Opening coefficient.</returns>
double TKE::BVs(double const BCP) double TKE::BVs(double const /*BCP*/)
{ {
double VVP; double VVP;
double BVP; double BVP;

View File

@@ -87,7 +87,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::batteryoff ); remove_hint( driver_hint::batteryoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->BatteryStart != start_t::manual || mvOccupied->Power24vIsAvailable == true; } ); return mvOccupied->BatteryStart != start_t::manual || mvOccupied->Power24vIsAvailable == true; } );
break; break;
} }
@@ -98,7 +98,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::batteryon ); remove_hint( driver_hint::batteryon );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->BatteryStart != start_t::manual || mvOccupied->Power24vIsAvailable == false; } ); return mvOccupied->BatteryStart != start_t::manual || mvOccupied->Power24vIsAvailable == false; } );
break; break;
} }
@@ -111,7 +111,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::cabdeactivation ); remove_hint( driver_hint::cabdeactivation );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->AutomaticCabActivation || mvOccupied->IsCabMaster(); } ); return mvOccupied->AutomaticCabActivation || mvOccupied->IsCabMaster(); } );
break; break;
} }
@@ -122,7 +122,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::cabactivation ); remove_hint( driver_hint::cabactivation );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->AutomaticCabActivation || (mvOccupied->CabMaster == false && mvOccupied->CabActive == 0); } ); return mvOccupied->AutomaticCabActivation || (mvOccupied->CabMaster == false && mvOccupied->CabActive == 0); } );
break; break;
} }
@@ -134,7 +134,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::radiooff ); remove_hint( driver_hint::radiooff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->Radio == true; } ); return mvOccupied->Radio == true; } );
break; break;
} }
@@ -156,7 +156,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::radioon ); remove_hint( driver_hint::radioon );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->Radio == false; } ); return mvOccupied->Radio == false; } );
break; break;
} }
@@ -168,7 +168,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::oilpumpoff ); remove_hint( driver_hint::oilpumpoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvOccupied->OilPump }; auto const &device { mvOccupied->OilPump };
return device.start_type != start_t::manual || device.is_enabled == true || device.is_active == true || mvOccupied->Mains; } ); return device.start_type != start_t::manual || device.is_enabled == true || device.is_active == true || mvOccupied->Mains; } );
break; break;
@@ -180,7 +180,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::oilpumpon ); remove_hint( driver_hint::oilpumpon );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvOccupied->OilPump }; auto const &device { mvOccupied->OilPump };
return device.start_type != start_t::manual || (device.is_enabled == false && device.is_active == false); } ); return device.start_type != start_t::manual || (device.is_enabled == false && device.is_active == false); } );
break; break;
@@ -193,7 +193,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::fuelpumpoff ); remove_hint( driver_hint::fuelpumpoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvOccupied->FuelPump }; auto const &device { mvOccupied->FuelPump };
return device.start_type != start_t::manual || device.is_enabled == true || device.is_active == true; } ); return device.start_type != start_t::manual || device.is_enabled == true || device.is_active == true; } );
break; break;
@@ -205,7 +205,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::fuelpumpon ); remove_hint( driver_hint::fuelpumpon );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvOccupied->FuelPump }; auto const &device { mvOccupied->FuelPump };
return device.start_type != start_t::manual || (device.is_enabled == false && device.is_active == false); } ); return device.start_type != start_t::manual || (device.is_enabled == false && device.is_active == false); } );
break; break;
@@ -218,7 +218,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::pantographairsourcesetauxiliary ); remove_hint( driver_hint::pantographairsourcesetauxiliary );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvPantographUnit->bPantKurek3 == true; } ); return mvPantographUnit->bPantKurek3 == true; } );
break; break;
} }
@@ -229,7 +229,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::pantographcompressoron ); remove_hint( driver_hint::pantographcompressoron );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvPantographUnit->bPantKurek3 == false; } ); return mvPantographUnit->bPantKurek3 == false; } );
break; break;
} }
@@ -240,7 +240,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::pantographcompressoroff ); remove_hint( driver_hint::pantographcompressoroff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvPantographUnit->PantCompFlag == true; } ); return mvPantographUnit->PantCompFlag == true; } );
break; break;
} }
@@ -251,7 +251,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::pantographcompressoron ); remove_hint( driver_hint::pantographcompressoron );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvPantographUnit->PantCompFlag == false; } ); return mvPantographUnit->PantCompFlag == false; } );
break; break;
} }
@@ -262,7 +262,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::pantographsvalveoff ); remove_hint( driver_hint::pantographsvalveoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvPantographUnit->PantsValve.is_active == true; } ); return mvPantographUnit->PantsValve.is_active == true; } );
break; break;
} }
@@ -285,7 +285,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::frontpantographvalveon ); remove_hint( driver_hint::frontpantographvalveon );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvPantographUnit->Pantographs[end::front].valve.is_active == false; } ); return mvPantographUnit->Pantographs[end::front].valve.is_active == false; } );
break; break;
} }
@@ -308,7 +308,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::rearpantographvalveon ); remove_hint( driver_hint::rearpantographvalveon );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvPantographUnit->Pantographs[end::rear].valve.is_active == false; } ); return mvPantographUnit->Pantographs[end::rear].valve.is_active == false; } );
break; break;
} }
@@ -320,7 +320,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::converteroff ); remove_hint( driver_hint::converteroff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyConverterEnabled == true; } ); return IsAnyConverterEnabled == true; } );
break; break;
} }
@@ -331,7 +331,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::converteron ); remove_hint( driver_hint::converteron );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyConverterExplicitlyEnabled == false; } ); return IsAnyConverterExplicitlyEnabled == false; } );
break; break;
} }
@@ -342,7 +342,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
} }
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->ConverterOverloadRelayStart != start_t::manual || mvOccupied->ConvOvldFlag == false; } ); return mvOccupied->ConverterOverloadRelayStart != start_t::manual || mvOccupied->ConvOvldFlag == false; } );
break; break;
} }
@@ -352,7 +352,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
} }
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->GroundRelayStart != start_t::manual || mvOccupied->GroundRelay == true; } ); return mvOccupied->GroundRelayStart != start_t::manual || mvOccupied->GroundRelay == true; } );
break; break;
} }
@@ -362,7 +362,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
} }
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->FuseFlag == false; } ); return mvOccupied->FuseFlag == false; } );
break; break;
} }
@@ -374,7 +374,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::linebreakeropen ); remove_hint( driver_hint::linebreakeropen );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyLineBreakerOpen == false; } ); return IsAnyLineBreakerOpen == false; } );
break; break;
} }
@@ -385,7 +385,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::linebreakerclose ); remove_hint( driver_hint::linebreakerclose );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
// TBD, TODO: replace with consist-wide flag set true if any line breaker is closed? // TBD, TODO: replace with consist-wide flag set true if any line breaker is closed?
return mvControlling->Mains == false; } ); return mvControlling->Mains == false; } );
break; break;
@@ -398,7 +398,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::compressoroff ); remove_hint( driver_hint::compressoroff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyCompressorEnabled == true; } ); return IsAnyCompressorEnabled == true; } );
break; break;
} }
@@ -409,7 +409,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::compressoron ); remove_hint( driver_hint::compressoron );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyCompressorExplicitlyEnabled == false; } ); return IsAnyCompressorExplicitlyEnabled == false; } );
break; break;
} }
@@ -421,7 +421,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::frontmotorblowersoff ); remove_hint( driver_hint::frontmotorblowersoff );
hint( hint(
Action, Action,
[this]( float const Parameter ) { [this]( float const /*Parameter*/ ) {
auto const &device { mvOccupied->MotorBlowers[ end::front ] }; auto const &device { mvOccupied->MotorBlowers[ end::front ] };
return device.start_type != start_t::manual || (device.is_enabled == true && device.is_disabled == false); } ); return device.start_type != start_t::manual || (device.is_enabled == true && device.is_disabled == false); } );
break; break;
@@ -434,7 +434,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::rearmotorblowersoff ); remove_hint( driver_hint::rearmotorblowersoff );
hint( hint(
Action, Action,
[this]( float const Parameter ) { [this]( float const /*Parameter*/ ) {
auto const &device { mvOccupied->MotorBlowers[ end::rear ] }; auto const &device { mvOccupied->MotorBlowers[ end::rear ] };
return device.start_type != start_t::manual || (device.is_enabled == true && device.is_disabled == false); } ); return device.start_type != start_t::manual || (device.is_enabled == true && device.is_disabled == false); } );
break; break;
@@ -447,7 +447,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::springbrakeoff ); remove_hint( driver_hint::springbrakeoff );
hint( hint(
Action, Action,
[this]( float const Parameter ) { [this]( float const /*Parameter*/ ) {
return mvOccupied->SpringBrake.Activate == true; } ); return mvOccupied->SpringBrake.Activate == true; } );
break; break;
} }
@@ -458,7 +458,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::springbrakeon ); remove_hint( driver_hint::springbrakeon );
hint( hint(
Action, Action,
[this]( float const Parameter ) { [this]( float const /*Parameter*/ ) {
return mvOccupied->SpringBrake.Activate == false; } ); return mvOccupied->SpringBrake.Activate == false; } );
break; break;
} }
@@ -470,7 +470,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::manualbrakoff ); remove_hint( driver_hint::manualbrakoff );
hint( hint(
Action, Action,
[this]( float const Parameter ) { [this]( float const /*Parameter*/ ) {
return mvOccupied->LocalBrake != TLocalBrake::ManualBrake || mvOccupied->MBrake == false || mvOccupied->ManualBrakePos == ManualBrakePosNo; } ); return mvOccupied->LocalBrake != TLocalBrake::ManualBrake || mvOccupied->MBrake == false || mvOccupied->ManualBrakePos == ManualBrakePosNo; } );
break; break;
} }
@@ -481,7 +481,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::manualbrakon ); remove_hint( driver_hint::manualbrakon );
hint( hint(
Action, Action,
[this]( float const Parameter ) { [this]( float const /*Parameter*/ ) {
return mvOccupied->LocalBrake != TLocalBrake::ManualBrake || mvOccupied->MBrake == false || mvOccupied->ManualBrakePos == 0; } ); return mvOccupied->LocalBrake != TLocalBrake::ManualBrake || mvOccupied->MBrake == false || mvOccupied->ManualBrakePos == 0; } );
break; break;
} }
@@ -496,7 +496,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_master_controller_hints(); remove_master_controller_hints();
hint( hint(
Action, Action,
[this]( float const Parameter ) { [this]( float const /*Parameter*/ ) {
return mvControlling->RList[mvControlling->MainCtrlPos].Mn > 0; } ); return mvControlling->RList[mvControlling->MainCtrlPos].Mn > 0; } );
break; break;
} }
@@ -516,7 +516,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_master_controller_hints(); remove_master_controller_hints();
hint( hint(
Action, Action,
[this]( float const Parameter ) { [this]( float const /*Parameter*/ ) {
return mvControlling->RList[mvControlling->MainCtrlPos].Bn < 2; } ); return mvControlling->RList[mvControlling->MainCtrlPos].Bn < 2; } );
break; break;
} }
@@ -527,7 +527,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_master_controller_hints(); remove_master_controller_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvControlling->IsMainCtrlNoPowerPos() && mvControlling->IsScndCtrlNoPowerPos(); } ); return mvControlling->IsMainCtrlNoPowerPos() && mvControlling->IsScndCtrlNoPowerPos(); } );
break; break;
} }
@@ -541,7 +541,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_master_controller_hints(); remove_master_controller_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvControlling->EIMDirectionChangeAllow(); }, return mvControlling->EIMDirectionChangeAllow(); },
static_cast<float>(mvControlling->MainCtrlMaxDirChangePos) ); static_cast<float>(mvControlling->MainCtrlMaxDirChangePos) );
break; break;
@@ -575,7 +575,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
} }
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return AccDesired <= EU07_AI_NOACCELERATION || (false == Ready && false == mvOccupied->ShuntMode) || AccDesired - AbsAccS <= 0.05 || return AccDesired <= EU07_AI_NOACCELERATION || (false == Ready && false == mvOccupied->ShuntMode) || AccDesired - AbsAccS <= 0.05 ||
(mvOccupied->EIMCtrlType > 0 ? mvControlling->eimic_real >= 1.0 : mvControlling->IsScndCtrlMaxPowerPos() && mvControlling->IsMainCtrlMaxPowerPos()); } ); (mvOccupied->EIMCtrlType > 0 ? mvControlling->eimic_real >= 1.0 : mvControlling->IsScndCtrlMaxPowerPos() && mvControlling->IsMainCtrlMaxPowerPos()); } );
break; break;
@@ -589,7 +589,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_master_controller_hints(); remove_master_controller_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return std::abs(mvControlling->Ft) > 30.0 || (OrderCurrentGet() & Disconnect) == 0; } ); return std::abs(mvControlling->Ft) > 30.0 || (OrderCurrentGet() & Disconnect) == 0; } );
break; break;
} }
@@ -601,7 +601,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_master_controller_hints(); remove_master_controller_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvControlling->IsScndCtrlNoPowerPos(); } ); return mvControlling->IsScndCtrlNoPowerPos(); } );
break; break;
} }
@@ -613,7 +613,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::waterpumpoff ); remove_hint( driver_hint::waterpumpoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvControlling->WaterPump }; auto const &device { mvControlling->WaterPump };
return device.start_type != start_t::manual || (device.is_enabled == true && device.is_disabled == false) || device.is_active == true; } ); return device.start_type != start_t::manual || (device.is_enabled == true && device.is_disabled == false) || device.is_active == true; } );
break; break;
@@ -625,7 +625,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::waterpumpon ); remove_hint( driver_hint::waterpumpon );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvControlling->WaterPump }; auto const &device { mvControlling->WaterPump };
return device.start_type != start_t::manual || (device.is_enabled == false && device.is_active == false); } ); return device.start_type != start_t::manual || (device.is_enabled == false && device.is_active == false); } );
break; break;
@@ -637,7 +637,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::waterpumpbreakeroff ); remove_hint( driver_hint::waterpumpbreakeroff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvControlling->WaterPump }; auto const &device { mvControlling->WaterPump };
return device.breaker == true; } ); return device.breaker == true; } );
break; break;
@@ -649,7 +649,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::waterpumpbreakeron ); remove_hint( driver_hint::waterpumpbreakeron );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvControlling->WaterPump }; auto const &device { mvControlling->WaterPump };
return device.breaker == false; } ); return device.breaker == false; } );
break; break;
@@ -661,7 +661,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::waterheateroff ); remove_hint( driver_hint::waterheateroff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvControlling->WaterHeater }; auto const &device { mvControlling->WaterHeater };
return device.is_enabled == true; } ); return device.is_enabled == true; } );
break; break;
@@ -673,7 +673,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::waterheateron ); remove_hint( driver_hint::waterheateron );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvControlling->WaterHeater }; auto const &device { mvControlling->WaterHeater };
return device.is_enabled == false; } ); return device.is_enabled == false; } );
break; break;
@@ -685,7 +685,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::waterheaterbreakeroff ); remove_hint( driver_hint::waterheaterbreakeroff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvControlling->WaterHeater }; auto const &device { mvControlling->WaterHeater };
return device.breaker == true; } ); return device.breaker == true; } );
break; break;
@@ -697,7 +697,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::waterheaterbreakeron ); remove_hint( driver_hint::waterheaterbreakeron );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvControlling->WaterHeater }; auto const &device { mvControlling->WaterHeater };
return device.breaker == false; } ); return device.breaker == false; } );
break; break;
@@ -709,7 +709,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::watercircuitslinkoff ); remove_hint( driver_hint::watercircuitslinkoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvControlling->dizel_heat.auxiliary_water_circuit == false || mvControlling->WaterCircuitsLink == true; } ); return mvControlling->dizel_heat.auxiliary_water_circuit == false || mvControlling->WaterCircuitsLink == true; } );
break; break;
} }
@@ -720,7 +720,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::watercircuitslinkon ); remove_hint( driver_hint::watercircuitslinkon );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvControlling->dizel_heat.auxiliary_water_circuit == false || mvControlling->WaterCircuitsLink == false; } ); return mvControlling->dizel_heat.auxiliary_water_circuit == false || mvControlling->WaterCircuitsLink == false; } );
break; break;
} }
@@ -728,7 +728,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
// NOTE: this action doesn't have AI component // NOTE: this action doesn't have AI component
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return false == IsHeatingTemperatureTooLow; } ); return false == IsHeatingTemperatureTooLow; } );
break; break;
} }
@@ -736,7 +736,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
// NOTE: this action doesn't have AI component // NOTE: this action doesn't have AI component
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvControlling->ScndPipePress > 4.5 || mvControlling->VeselVolume == 0.0; } ); return mvControlling->ScndPipePress > 4.5 || mvControlling->VeselVolume == 0.0; } );
break; break;
} }
@@ -744,7 +744,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
// NOTE: this action doesn't have AI component // NOTE: this action doesn't have AI component
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvPantographUnit->PantPress >= (is_emu() ? (mvPantographUnit->PantPressLockActive ? 4.6 : 2.6) : 4.2); } ); return mvPantographUnit->PantPress >= (is_emu() ? (mvPantographUnit->PantPressLockActive ? 4.6 : 2.6) : 4.2); } );
break; break;
} }
@@ -752,7 +752,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
// NOTE: this action doesn't have AI component // NOTE: this action doesn't have AI component
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return ExchangeTime <= 0; } ); return ExchangeTime <= 0; } );
break; break;
} }
@@ -760,7 +760,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
// NOTE: this action doesn't have AI component // NOTE: this action doesn't have AI component
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAtPassengerStop == false; } ); return IsAtPassengerStop == false; } );
break; break;
} }
@@ -784,7 +784,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_train_brake_hints(); remove_train_brake_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->HandleUnlock == -3 || BrakeCtrlPosition == mvOccupied->HandleUnlock; } ); return mvOccupied->HandleUnlock == -3 || BrakeCtrlPosition == mvOccupied->HandleUnlock; } );
break; break;
} }
@@ -796,7 +796,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_train_brake_hints(); remove_train_brake_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return is_equal(mvOccupied->fBrakeCtrlPos, mvOccupied->Handle->GetPos(bh_RP), 0.2) || (mvOccupied->Handle->Time && mvOccupied->Handle->GetCP() > mvOccupied->HighPipePress - 0.05); } ); return is_equal(mvOccupied->fBrakeCtrlPos, mvOccupied->Handle->GetPos(bh_RP), 0.2) || (mvOccupied->Handle->Time && mvOccupied->Handle->GetCP() > mvOccupied->HighPipePress - 0.05); } );
// return ( BrakeCtrlPosition == gbh_RP ); } ); // return ( BrakeCtrlPosition == gbh_RP ); } );
break; break;
@@ -814,7 +814,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_train_brake_hints(); remove_train_brake_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsConsistBraked /*|| ( ( OrderCurrentGet() & Disconnect ) == 0 ) */; } ); return IsConsistBraked /*|| ( ( OrderCurrentGet() & Disconnect ) == 0 ) */; } );
break; break;
} }
@@ -863,7 +863,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_train_brake_hints(); remove_train_brake_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return Ready && fReady < 0.4 && is_equal(mvOccupied->fBrakeCtrlPos, mvOccupied->Handle->GetPos(bh_RP), 0.2); } ); return Ready && fReady < 0.4 && is_equal(mvOccupied->fBrakeCtrlPos, mvOccupied->Handle->GetPos(bh_RP), 0.2); } );
break; break;
} }
@@ -901,7 +901,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::independentbrakeapply ); remove_hint( driver_hint::independentbrakeapply );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->LocalBrakePosA < 0.05; } ); return mvOccupied->LocalBrakePosA < 0.05; } );
break; break;
} }
@@ -913,7 +913,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_reverser_hints(); remove_reverser_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->DirActive * mvOccupied->CabActive > 0; } ); return mvOccupied->DirActive * mvOccupied->CabActive > 0; } );
break; break;
} }
@@ -924,7 +924,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_reverser_hints(); remove_reverser_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->DirActive * mvOccupied->CabActive < 0; } ); return mvOccupied->DirActive * mvOccupied->CabActive < 0; } );
break; break;
} }
@@ -937,7 +937,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_reverser_hints(); remove_reverser_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return iDirection == iDirectionOrder; } ); return iDirection == iDirectionOrder; } );
break; break;
} }
@@ -948,7 +948,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_reverser_hints(); remove_reverser_hints();
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->DirActive == 0; } ); return mvOccupied->DirActive == 0; } );
break; break;
} }
@@ -960,7 +960,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::sandingoff ); remove_hint( driver_hint::sandingoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvControlling->Sand == 0 || mvControlling->SandDose == true || mvControlling->SlippingWheels == false; } ); return mvControlling->Sand == 0 || mvControlling->SandDose == true || mvControlling->SlippingWheels == false; } );
break; break;
} }
@@ -971,7 +971,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::sandingon ); remove_hint( driver_hint::sandingon );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvControlling->Sand == 0 || mvControlling->SandDose == false; } ); return mvControlling->Sand == 0 || mvControlling->SandDose == false; } );
break; break;
} }
@@ -981,7 +981,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
} }
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvControlling->ASBType != 1 || (mvControlling->Hamulec->GetBrakeStatus() & b_asb) != 0 || mvControlling->SlippingWheels == false; } ); return mvControlling->ASBType != 1 || (mvControlling->Hamulec->GetBrakeStatus() & b_asb) != 0 || mvControlling->SlippingWheels == false; } );
break; break;
} }
@@ -993,7 +993,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::hornoff ); remove_hint( driver_hint::hornoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
// NOTE: we provide slightly larger horn activation window for human driver // NOTE: we provide slightly larger horn activation window for human driver
return fWarningDuration + 5.0 < 0.05 || mvOccupied->WarningSignal != 0; } ); return fWarningDuration + 5.0 < 0.05 || mvOccupied->WarningSignal != 0; } );
break; break;
@@ -1020,7 +1020,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
// TODO: remove other door lock hints // TODO: remove other door lock hints
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->Doors.has_lock == false || mvOccupied->Doors.lock_enabled == true; } ); return mvOccupied->Doors.has_lock == false || mvOccupied->Doors.lock_enabled == true; } );
break; break;
} }
@@ -1032,7 +1032,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::departuresignaloff ); remove_hint( driver_hint::departuresignaloff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->Doors.has_warning == false || mvOccupied->Doors.has_autowarning == true || mvOccupied->DepartureSignal == true || mvOccupied->Vel > 5.0; } ); return mvOccupied->Doors.has_warning == false || mvOccupied->Doors.has_autowarning == true || mvOccupied->DepartureSignal == true || mvOccupied->Vel > 5.0; } );
break; break;
} }
@@ -1043,7 +1043,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::departuresignalon ); remove_hint( driver_hint::departuresignalon );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->Doors.has_warning == false || mvOccupied->Doors.has_autowarning == true || mvOccupied->DepartureSignal == false; } ); return mvOccupied->Doors.has_warning == false || mvOccupied->Doors.has_autowarning == true || mvOccupied->DepartureSignal == false; } );
break; break;
} }
@@ -1056,7 +1056,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::doorrightclose ); remove_hint( driver_hint::doorrightclose );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyDoorOpen[side::right] == true; } ); return IsAnyDoorOpen[side::right] == true; } );
break; break;
} }
@@ -1068,7 +1068,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::doorrightopen ); remove_hint( driver_hint::doorrightopen );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyDoorOpen[side::right] == false; } ); return IsAnyDoorOpen[side::right] == false; } );
break; break;
} }
@@ -1080,7 +1080,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::doorleftclose ); remove_hint( driver_hint::doorleftclose );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyDoorOpen[side::left] == true; } ); return IsAnyDoorOpen[side::left] == true; } );
break; break;
} }
@@ -1092,7 +1092,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::doorleftopen ); remove_hint( driver_hint::doorleftopen );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyDoorOpen[side::left] == false; } ); return IsAnyDoorOpen[side::left] == false; } );
break; break;
} }
@@ -1103,7 +1103,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::doorrightpermitoff ); remove_hint( driver_hint::doorrightpermitoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyDoorPermitActive[side::right] == true; } ); return IsAnyDoorPermitActive[side::right] == true; } );
break; break;
} }
@@ -1114,7 +1114,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::doorrightpermiton ); remove_hint( driver_hint::doorrightpermiton );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyDoorPermitActive[side::right] == false; } ); return IsAnyDoorPermitActive[side::right] == false; } );
break; break;
} }
@@ -1125,7 +1125,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::doorleftpermitoff ); remove_hint( driver_hint::doorleftpermitoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyDoorPermitActive[side::left] == true; } ); return IsAnyDoorPermitActive[side::left] == true; } );
break; break;
} }
@@ -1136,7 +1136,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::doorleftpermiton ); remove_hint( driver_hint::doorleftpermiton );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return IsAnyDoorPermitActive[side::left] == false; } ); return IsAnyDoorPermitActive[side::left] == false; } );
break; break;
} }
@@ -1149,7 +1149,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::consistlightsoff ); remove_hint( driver_hint::consistlightsoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvOccupied->CompartmentLights }; auto const &device { mvOccupied->CompartmentLights };
return Global.fLuminance * ConsistShade > 0.40 || device.start_type != start_t::manual || (device.is_enabled == true && device.is_disabled == false) || device.is_active == true; } ); return Global.fLuminance * ConsistShade > 0.40 || device.start_type != start_t::manual || (device.is_enabled == true && device.is_disabled == false) || device.is_active == true; } );
break; break;
@@ -1162,7 +1162,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::consistlightson ); remove_hint( driver_hint::consistlightson );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const &device { mvOccupied->CompartmentLights }; auto const &device { mvOccupied->CompartmentLights };
return Global.fLuminance * ConsistShade < 0.35 || device.start_type != start_t::manual || (device.is_enabled == false && device.is_active == false); } ); return Global.fLuminance * ConsistShade < 0.35 || device.start_type != start_t::manual || (device.is_enabled == false && device.is_active == false); } );
break; break;
@@ -1175,7 +1175,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::consistheatingoff ); remove_hint( driver_hint::consistheatingoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->HeatingAllow == true; } ); return mvOccupied->HeatingAllow == true; } );
break; break;
} }
@@ -1186,7 +1186,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::consistheatingon ); remove_hint( driver_hint::consistheatingon );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return mvOccupied->HeatingAllow == false; } ); return mvOccupied->HeatingAllow == false; } );
break; break;
} }
@@ -1198,7 +1198,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
} }
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return !mvOccupied->SecuritySystem.is_vigilance_blinking(); } ); return !mvOccupied->SecuritySystem.is_vigilance_blinking(); } );
break; break;
} }
@@ -1209,7 +1209,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
} }
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return !mvOccupied->SecuritySystem.is_cabsignal_blinking(); } ); return !mvOccupied->SecuritySystem.is_cabsignal_blinking(); } );
break; break;
} }
@@ -1246,7 +1246,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::lightsoff ); remove_hint( driver_hint::lightsoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return pVehicles[end::front]->has_signal_pc1_on(); } ); return pVehicles[end::front]->has_signal_pc1_on(); } );
break; break;
} }
@@ -1259,7 +1259,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::lightsoff ); remove_hint( driver_hint::lightsoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return pVehicles[end::front]->has_signal_pc2_on(); } ); return pVehicles[end::front]->has_signal_pc2_on(); } );
break; break;
} }
@@ -1276,7 +1276,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::lightsoff ); remove_hint( driver_hint::lightsoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const activeend { mvOccupied->CabActive >= 0 ? end::front : end::rear }; auto const activeend { mvOccupied->CabActive >= 0 ? end::front : end::rear };
auto const consistfront { mvOccupied->DirActive >= 0 ? end::front : end::rear }; auto const consistfront { mvOccupied->DirActive >= 0 ? end::front : end::rear };
return pVehicles[consistfront]->has_signal_on(activeend, light::headlight_right) && pVehicles[1 - consistfront]->has_signal_on(1 - activeend, light::headlight_left); } ); return pVehicles[consistfront]->has_signal_on(activeend, light::headlight_right) && pVehicles[1 - consistfront]->has_signal_on(1 - activeend, light::headlight_left); } );
@@ -1291,7 +1291,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::lightsoff ); remove_hint( driver_hint::lightsoff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return pVehicles[end::rear]->has_signal_pc5_on(); } ); return pVehicles[end::rear]->has_signal_pc5_on(); } );
break; break;
} }
@@ -1305,7 +1305,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::headcodetb1 ); remove_hint( driver_hint::headcodetb1 );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
auto const activeend { mvOccupied->CabActive >= 0 ? end::front : end::rear }; auto const activeend { mvOccupied->CabActive >= 0 ? end::front : end::rear };
auto const consistfront { mvOccupied->DirActive >= 0 ? end::front : end::rear }; auto const consistfront { mvOccupied->DirActive >= 0 ? end::front : end::rear };
return pVehicles[consistfront]->has_signal_on(activeend, 0) && pVehicles[1 - consistfront]->has_signal_on(1 - activeend, 0); } ); return pVehicles[consistfront]->has_signal_on(activeend, 0) && pVehicles[1 - consistfront]->has_signal_on(1 - activeend, 0); } );
@@ -1319,7 +1319,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::releaseroff ); remove_hint( driver_hint::releaseroff );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return true == mvOccupied->Hamulec->Releaser(); } ); return true == mvOccupied->Hamulec->Releaser(); } );
break; break;
} }
@@ -1330,7 +1330,7 @@ TController::cue_action( driver_hint const Action, float const Actionparameter )
remove_hint( driver_hint::releaseron ); remove_hint( driver_hint::releaseron );
hint( hint(
Action, Action,
[this](float const Parameter) { [this](float const /*Parameter*/) {
return false == mvOccupied->Hamulec->Releaser(); } ); return false == mvOccupied->Hamulec->Releaser(); } );
break; break;
} }

View File

@@ -34,7 +34,7 @@ TTranscripts::AddLine( std::string const &txt, float show, float hide, bool it )
// dodanie tekstów, długość dźwięku, czy istotne // dodanie tekstów, długość dźwięku, czy istotne
void void
TTranscripts::Add( std::string const &txt, bool backgorund ) { TTranscripts::Add( std::string const &txt, bool /*backgorund*/ ) {
if( true == txt.empty() ) { return; } if( true == txt.empty() ) { return; }

View File

@@ -867,7 +867,7 @@ sound_source::empty() const {
// returns true if the source is emitting any sound // returns true if the source is emitting any sound
bool bool
sound_source::is_playing( bool const Includesoundends ) const { sound_source::is_playing( bool const /*Includesoundends*/ ) const {
auto isplaying { sound(sound_id::begin).playing > 0 || sound(sound_id::main).playing > 0 }; auto isplaying { sound(sound_id::begin).playing > 0 || sound(sound_id::main).playing > 0 };
if( false == isplaying if( false == isplaying

View File

@@ -133,7 +133,7 @@ mouse_slider::release() {
} }
void void
mouse_slider::on_move( double const Mousex, double const Mousey ) { mouse_slider::on_move( double const /*Mousex*/, double const Mousey ) {
auto const controlsize { Global.window_size.y * EU07_CONTROLLER_MOUSESLIDERSIZE }; auto const controlsize { Global.window_size.y * EU07_CONTROLLER_MOUSESLIDERSIZE };
auto const controledge { Global.window_size.y * 0.5 + controlsize * 0.5 }; auto const controledge { Global.window_size.y * 0.5 + controlsize * 0.5 };
@@ -276,7 +276,7 @@ drivermouse_input::move( double Mousex, double Mousey ) {
} }
void void
drivermouse_input::scroll( double const Xoffset, double const Yoffset ) { drivermouse_input::scroll( double const /*Xoffset*/, double const Yoffset ) {
if( Global.ctrlState ) { if( Global.ctrlState ) {
// ctrl + scroll wheel adjusts fov // ctrl + scroll wheel adjusts fov

View File

@@ -32,7 +32,7 @@ namespace multiplayer {
std::uint32_t const EU07_MESSAGEHEADER { MAKE_ID4( 'E','U','0','7' ) }; std::uint32_t const EU07_MESSAGEHEADER { MAKE_ID4( 'E','U','0','7' ) };
void void
Navigate(std::string const &ClassName, UINT Msg, WPARAM wParam, LPARAM lParam) { Navigate([[maybe_unused]] std::string const &ClassName, [[maybe_unused]] UINT Msg, [[maybe_unused]] WPARAM wParam, [[maybe_unused]] LPARAM lParam) {
#ifdef _WIN32 #ifdef _WIN32
// wysłanie komunikatu do sterującego // wysłanie komunikatu do sterującego
HWND h = FindWindow(ClassName.c_str(), 0); // można by to zapamiętać HWND h = FindWindow(ClassName.c_str(), 0); // można by to zapamiętać
@@ -198,7 +198,7 @@ OnCommandGet(multiplayer::DaneRozkaz *pRozkaz)
} }
void void
WyslijEvent(const std::string &e, const std::string &d) WyslijEvent([[maybe_unused]] const std::string &e, [[maybe_unused]] const std::string &d)
{ // Ra: jeszcze do wyczyszczenia { // Ra: jeszcze do wyczyszczenia
#ifdef _WIN32 #ifdef _WIN32
DaneRozkaz r; DaneRozkaz r;
@@ -219,7 +219,7 @@ WyslijEvent(const std::string &e, const std::string &d)
} }
void void
WyslijUszkodzenia(const std::string &t, char fl) WyslijUszkodzenia([[maybe_unused]] const std::string &t, [[maybe_unused]] char fl)
{ // wysłanie informacji w postaci pojedynczego tekstu { // wysłanie informacji w postaci pojedynczego tekstu
#ifdef _WIN32 #ifdef _WIN32
DaneRozkaz r; DaneRozkaz r;
@@ -239,7 +239,7 @@ WyslijUszkodzenia(const std::string &t, char fl)
} }
void void
WyslijString(const std::string &t, int n) WyslijString([[maybe_unused]] const std::string &t, [[maybe_unused]] int n)
{ // wysłanie informacji w postaci pojedynczego tekstu { // wysłanie informacji w postaci pojedynczego tekstu
#ifdef _WIN32 #ifdef _WIN32
DaneRozkaz r; DaneRozkaz r;
@@ -264,7 +264,7 @@ WyslijWolny(const std::string &t)
} }
void void
WyslijNamiary(TDynamicObject const *Vehicle) WyslijNamiary([[maybe_unused]] TDynamicObject const *Vehicle)
{ // wysłanie informacji o pojeździe - (float), długość ramki będzie zwiększana w miarę potrzeby { // wysłanie informacji o pojeździe - (float), długość ramki będzie zwiększana w miarę potrzeby
#ifdef _WIN32 #ifdef _WIN32
DaneRozkaz r; DaneRozkaz r;
@@ -395,7 +395,7 @@ WyslijObsadzone()
} }
void void
WyslijParam(int nr, int fl) WyslijParam([[maybe_unused]] int nr, [[maybe_unused]] int fl)
{ // wysłanie parametrów symulacji w ramce (nr) z flagami (fl) { // wysłanie parametrów symulacji w ramce (nr) z flagami (fl)
#ifdef _WIN32 #ifdef _WIN32
DaneRozkaz r; DaneRozkaz r;

View File

@@ -79,7 +79,7 @@ void network::connection::catch_up()
send_messages(messages); send_messages(messages);
} }
void network::connection::send_complete(std::shared_ptr<std::string> buf) void network::connection::send_complete(std::shared_ptr<std::string> /*buf*/)
{ {
if (!is_client && state == CATCHING_UP) { if (!is_client && state == CATCHING_UP) {
catch_up(); catch_up();

View File

@@ -17,7 +17,7 @@ void texture_window_fb_resize(GLFWwindow *win, int w, int h)
texwindow->notify_window_fb_size(win, w, h); texwindow->notify_window_fb_size(win, w, h);
} }
void texture_window_mouse_button(GLFWwindow *win, int button, int action, int mods) void texture_window_mouse_button(GLFWwindow *win, int button, int action, int /*mods*/)
{ {
python_screen_viewer *texwindow = (python_screen_viewer*)glfwGetWindowUserPointer(win); python_screen_viewer *texwindow = (python_screen_viewer*)glfwGetWindowUserPointer(win);
texwindow->notify_click(win, button, action); texwindow->notify_click(win, button, action);

View File

@@ -206,14 +206,14 @@ void ErrorLog(const char* str, logtype type)
} }
void Error(const std::string &asMessage, bool box) void Error(const std::string &asMessage, bool /*box*/)
{ {
// if (box) // if (box)
// MessageBox(NULL, asMessage.c_str(), string("EU07 " + Global.asRelease).c_str(), MB_OK); // MessageBox(NULL, asMessage.c_str(), string("EU07 " + Global.asRelease).c_str(), MB_OK);
ErrorLog(asMessage.c_str()); ErrorLog(asMessage.c_str());
} }
void Error(const char *&asMessage, bool box) void Error(const char *&asMessage, bool /*box*/)
{ {
// if (box) // if (box)
// MessageBox(NULL, asMessage, string("EU07 " + Global.asRelease).c_str(), MB_OK); // MessageBox(NULL, asMessage, string("EU07 " + Global.asRelease).c_str(), MB_OK);

View File

@@ -6072,7 +6072,7 @@ void TTrain::OnCommand_redmarkerdisablerearright(TTrain *Train, command_data con
} }
} }
void TTrain::OnCommand_redmarkerstoggle(TTrain *Train, command_data const &Command) void TTrain::OnCommand_redmarkerstoggle(TTrain * /*Train*/, command_data const &Command)
{ {
if (true == Command.freefly && Command.action == GLFW_PRESS) if (true == Command.freefly && Command.action == GLFW_PRESS)
@@ -6098,7 +6098,7 @@ void TTrain::OnCommand_redmarkerstoggle(TTrain *Train, command_data const &Comma
} }
} }
void TTrain::OnCommand_endsignalstoggle(TTrain *Train, command_data const &Command) void TTrain::OnCommand_endsignalstoggle(TTrain * /*Train*/, command_data const &Command)
{ {
if (true == Command.freefly && Command.action == GLFW_PRESS) if (true == Command.freefly && Command.action == GLFW_PRESS)
@@ -7793,7 +7793,7 @@ void TTrain::OnCommand_nearestcarcouplingdisconnect(TTrain *Train, command_data
} }
} }
void TTrain::OnCommand_nearestcarcoupleradapterattach(TTrain *Train, command_data const &Command) void TTrain::OnCommand_nearestcarcoupleradapterattach(TTrain * /*Train*/, command_data const &Command)
{ {
if (true == Command.freefly && Command.action == GLFW_PRESS) if (true == Command.freefly && Command.action == GLFW_PRESS)
@@ -7812,7 +7812,7 @@ void TTrain::OnCommand_nearestcarcoupleradapterattach(TTrain *Train, command_dat
} }
} }
void TTrain::OnCommand_nearestcarcoupleradapterremove(TTrain *Train, command_data const &Command) void TTrain::OnCommand_nearestcarcoupleradapterremove(TTrain * /*Train*/, command_data const &Command)
{ {
if (true == Command.freefly && Command.action == GLFW_PRESS) if (true == Command.freefly && Command.action == GLFW_PRESS)