File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed
Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -671,7 +671,6 @@ public void Update()
671671 Status . TyreAngularSpeed [ 3 ] = encodedTyreAngularSpeed ;
672672 Status . EngineRpm = ( ushort ) MathUtils . Lerp ( EntryCar . AiIdleEngineRpm , EntryCar . AiMaxEngineRpm , CurrentSpeed / _configuration . Extra . AiParams . MaxSpeedMs ) ;
673673 Status . StatusFlag = GetLights ( _configuration . Extra . AiParams . EnableDaytimeLights , _weatherManager . CurrentSunPosition , _randomTwilight )
674- | CarStatusFlags . HighBeamsOff
675674 | ( _sessionManager . ServerTimeMilliseconds < _stoppedForCollisionUntil || CurrentSpeed < 20 / 3.6f ? CarStatusFlags . HazardsOn : 0 )
676675 | ( CurrentSpeed == 0 || Acceleration < 0 ? CarStatusFlags . BrakeLightsOn : 0 )
677676 | ( _stoppedForObstacle && _sessionManager . ServerTimeMilliseconds > _obstacleHonkStart && _sessionManager . ServerTimeMilliseconds < _obstacleHonkEnd ? CarStatusFlags . Horn : 0 )
@@ -698,8 +697,9 @@ private static CarStatusFlags GetWiperSpeed(float rainIntensity)
698697
699698 private static CarStatusFlags GetLights ( bool daytimeLights , SunPosition ? sunPosition , double twilight )
700699 {
701- if ( daytimeLights || sunPosition == null ) return CarStatusFlags . LightsOn ;
700+ const CarStatusFlags lightFlags = CarStatusFlags . LightsOn | CarStatusFlags . HighBeamsOff ;
701+ if ( daytimeLights || sunPosition == null ) return lightFlags ;
702702
703- return sunPosition . Value . Altitude < twilight ? CarStatusFlags . LightsOn : 0 ;
703+ return sunPosition . Value . Altitude < twilight ? lightFlags : 0 ;
704704 }
705705}
You can’t perform that action at this time.
0 commit comments