Skip to content

Commit

Permalink
update 1.04
Browse files Browse the repository at this point in the history
  • Loading branch information
cmac994 authored and cmac994 committed Feb 19, 2021
1 parent d159b91 commit 11626d4
Show file tree
Hide file tree
Showing 41 changed files with 18 additions and 118 deletions.
Binary file modified .vs/KerbalWeatherProject/v16/.suo
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file removed GameData/KerbalWeatherProject/Binary/Point/height.bin
Binary file not shown.
Binary file not shown.
Binary file not shown.
114 changes: 0 additions & 114 deletions GameData/KerbalWeatherProject/Localization/en-us.cfg

This file was deleted.

Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
16 changes: 13 additions & 3 deletions KerbalWeatherProject/ModularFI_Registerer.cs
Expand Up @@ -472,6 +472,14 @@ public void UpdateThermodynamicsPreWx(ModularFI.ModularFlightIntegrator fi)
fi.backgroundRadiationTemp = CalculateBackgroundRadiationTemperature(fi.atmosphericTemperature, fi.DensityThermalLerp);
fi.backgroundRadiationTempExposed = CalculateBackgroundRadiationTemperature(fi.externalTemperature, fi.DensityThermalLerp);
}

for (int i = 0; i < fi.PartThermalDataCount; i++)
{
PartThermalData pttd = fi.partThermalDataList[i];
Part part = pttd.part;
part.skinUnexposedExternalTemp = v.externalTemperature;
}

/*else if (!wx_enabled)
{
fi.BaseFIUpdateThermodynamics();
Expand Down Expand Up @@ -508,15 +516,16 @@ public static double CalculateConstantsAtmosphere_CLIMO(ModularFI.ModularFlightI
double air_density = ptd.density;
double air_temperature = ptd.temperature;
double air_pressure = ptd.pressure;
double orig_temp = fi.atmosphericTemperature;

//Set environmental data for current vessel
v.staticPressurekPa = air_pressure / 1000.0;
v.atmDensity = air_density;
v.atmosphericTemperature = air_temperature;
v.speedOfSound = Math.Sqrt(1.4 * (air_pressure / air_density)); //mach is updated in update aero
v.atmosphericTemperature = air_temperature;
v.externalTemperature = Math.Max(air_temperature, fi.CalculateShockTemperature()); //Revision to temp calc from dkvalois
v.externalTemperature = Math.Max(air_temperature, fi.CalculateShockTemperature()); //Revision to temp calc from dkvalois
fi.externalTemperature = v.externalTemperature;
fi.atmosphericTemperature = v.atmosphericTemperature;
return air_temperature;
}

Expand All @@ -528,7 +537,6 @@ public static double CalculateConstantsAtmosphere_WX(ModularFI.ModularFlightInte
double air_density = ptd.density;
double air_temperature = ptd.temperature;
double air_pressure = ptd.pressure;
double orig_temp = fi.atmosphericTemperature;

//Set environmental data for current vessel
v.staticPressurekPa = air_pressure / 1000.0;
Expand All @@ -538,6 +546,8 @@ public static double CalculateConstantsAtmosphere_WX(ModularFI.ModularFlightInte
v.atmosphericTemperature = air_temperature;
v.externalTemperature = Math.Max(air_temperature, fi.CalculateShockTemperature()); //Revision to temp calc from dkvalois
//v.externalTemperature = (air_temperature + (fi.externalTemperature - orig_temp));
fi.externalTemperature = v.externalTemperature;
fi.atmosphericTemperature = v.atmosphericTemperature;
return air_temperature;
}

Expand Down

0 comments on commit 11626d4

Please sign in to comment.