diff --git a/Driver.cpp b/Driver.cpp index bdace41f..370f10ef 100644 --- a/Driver.cpp +++ b/Driver.cpp @@ -2702,6 +2702,7 @@ bool TController::PrepareEngine() if (AIControllFlag) { // część wykonawcza dla sterowania przez komputer mvOccupied->BatterySwitch( true ); + mvOccupied->Radio = true; if( ( mvControlling->EngineType == TEngineType::DieselElectric ) || ( mvControlling->EngineType == TEngineType::DieselEngine ) ) { mvControlling->OilPumpSwitch( true ); @@ -2945,6 +2946,7 @@ bool TController::ReleaseEngine() { mvOccupied->IncManualBrakeLevel( ManualBrakePosNo ); } // switch off remaining power + mvOccupied->Radio = false; mvOccupied->BatterySwitch( false ); } } diff --git a/McZapkie/MOVER.h b/McZapkie/MOVER.h index 0933f8d8..3c331363 100644 --- a/McZapkie/MOVER.h +++ b/McZapkie/MOVER.h @@ -1034,7 +1034,7 @@ public: start_t BatteryStart = start_t::manual; bool EpFuse = true; /*Czy sa zalavzone baterie*/ bool Signalling = false; /*Czy jest zalaczona sygnalizacja hamowania ostatniego wagonu*/ - bool Radio = true; /*Czy jest zalaczony radiotelefon*/ + bool Radio = false; /*Czy jest zalaczony radiotelefon*/ float NominalBatteryVoltage = 0.f; /*Winger - baterie w elektrykach*/ TDimension Dim; /*wymiary*/ double Cx = 0.0; /*wsp. op. aerodyn.*/ diff --git a/Train.cpp b/Train.cpp index 2891b99e..51c5387d 100644 --- a/Train.cpp +++ b/Train.cpp @@ -590,15 +590,13 @@ dictionary_source *TTrain::GetTrainState() { dict->insert( "manual_brake", ( mvOccupied->ManualBrakePos > 0 ) ); bool const bEP = ( mvControlled->LocHandle->GetCP() > 0.2 ) || ( fEIMParams[ 0 ][ 5 ] > 0.01 ); dict->insert( "dir_brake", bEP ); - bool bPN; + bool bPN { false }; if( ( typeid( *mvOccupied->Hamulec ) == typeid( TLSt ) ) || ( typeid( *mvOccupied->Hamulec ) == typeid( TEStED ) ) ) { TBrake* temp_ham = mvOccupied->Hamulec.get(); bPN = ( static_cast( temp_ham )->GetEDBCP() > 0.2 ); } - else - bPN = false; dict->insert( "indir_brake", bPN ); dict->insert( "brake_delay_flag", mvOccupied->BrakeDelayFlag ); dict->insert( "brake_op_mode_flag", mvOccupied->BrakeOpModeFlag ); diff --git a/application.cpp b/application.cpp index dfe94e29..46ab85d9 100644 --- a/application.cpp +++ b/application.cpp @@ -740,7 +740,8 @@ eu07_application::init_glfw() { monitor = glfwGetPrimaryMonitor(); glfwWindowHint( GLFW_AUTO_ICONIFY, GLFW_FALSE ); - if( Global.iMultisampling > 0 ) { + glfwWindowHint( GLFW_FLOATING, GLFW_FALSE ); + if( ( Global.iMultisampling > 0 ) && ( Global.gfx_skippipeline ) ) { glfwWindowHint( GLFW_SAMPLES, 1 << Global.iMultisampling ); }