Skip to content

Commit

Permalink
fix: fix crash in soul cairn
Browse files Browse the repository at this point in the history
  • Loading branch information
TheRiverwoodModder committed Mar 28, 2024
1 parent 9e57885 commit 6480a69
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.21)

project(
CommunityShaders
VERSION 0.8.6
VERSION 0.8.7
LANGUAGES CXX
)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[Info]
Version = 1-0-0
Version = 1-0-1
2 changes: 1 addition & 1 deletion src/Features/WetnessEffects.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ void WetnessEffects::Draw(const RE::BSShader* shader, const uint32_t)
lastWeatherID = lastWeather->GetFormID();
CalculateWetness(lastWeather, sky, seconds, lastWeatherWetnessDepth, lastWeatherPuddleDepth);
// If it was raining, wait to transition until precipitation ends, otherwise use the current weather's fade in
if (lastWeather->data.flags.any(RE::TESWeather::WeatherDataFlag::kRainy)) {
if (lastWeather->precipitationData && lastWeather->data.flags.any(RE::TESWeather::WeatherDataFlag::kRainy)) {
float rainDensity = lastWeather->precipitationData->data[static_cast<int>(RE::BGSShaderParticleGeometryData::DataID::kParticleDensity)].f;
float rainGravity = lastWeather->precipitationData->data[static_cast<int>(RE::BGSShaderParticleGeometryData::DataID::kGravityVelocity)].f;
lastWeatherRaining = std::clamp(((rainDensity * rainGravity) / AVERAGE_RAIN_VOLUME), MIN_RAINDROP_CHANCE_MULTIPLIER, MAX_RAINDROP_CHANCE_MULTIPLIER);
Expand Down

0 comments on commit 6480a69

Please sign in to comment.