Adjust day/night cycle logic and lighting parameters (#1705)

Increased minimum light level and updated sun shadow directions for smoother transitions. Changed light curve calculation to use cosine, adjusted day detection threshold, and added a console command to check current light level. Renamed and fixed logic in CP14IsNight rule. Updated map and prototype files to use new ambient light colors and ensure consistency.
This commit is contained in:
Red
2025-08-25 02:03:24 +03:00
committed by GitHub
parent aa6aa252d3
commit 0a3bd9baba
7 changed files with 55 additions and 12 deletions

View File

@@ -124,7 +124,9 @@ public abstract class SharedLightCycleSystem : EntitySystem
float exponent,
float phase = 0)
{
var sen = MathF.Pow(MathF.Sin((MathF.PI * (phase + x)) / waveLength), exponent);
//var sen = MathF.Pow(MathF.Sin((MathF.PI * (phase + x)) / waveLength), exponent);
var sen = MathF.Pow(MathF.Cos((MathF.PI * (phase + x)) / waveLength), exponent); //CP14 edited light curve calculation
return (crest - shift) * sen + shift;
}
}