mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-11-08 00:47:56 +01:00
Prevent overcharge by AI - count how long each vehicle is being under higher pressure
This commit is contained in:
@@ -1648,6 +1648,7 @@ class TMoverParameters
|
||||
double Handle_OverloadPressureDecrease = 0.002; // predkosc spadku cisnienia przy asymilacji
|
||||
/*max. cisnienie w cyl. ham., stala proporcjonalnosci p-K*/
|
||||
double HighPipePress = 0.0;
|
||||
double PipeOverchargeTime = 0.0; // [s]
|
||||
double LowPipePress = 0.0;
|
||||
double DeltaPipePress = 0.0;
|
||||
/*max. i min. robocze cisnienie w przewodzie glownym oraz roznica miedzy nimi*/
|
||||
|
||||
@@ -4790,6 +4790,8 @@ void TMoverParameters::UpdatePipePressure(double dt)
|
||||
|
||||
if (CompressedVolume < 0.0)
|
||||
CompressedVolume = 0.0;
|
||||
|
||||
PipeOverchargeTime = ( PipePress > HighPipePress + 0.2 ? PipeOverchargeTime + dt : 0.0 );
|
||||
}
|
||||
|
||||
// *************************************************************************************************
|
||||
|
||||
Reference in New Issue
Block a user