Level 1 fix

This commit is contained in:
Oleg Petruny 2024-09-26 18:20:17 +02:00
parent 70f24eab32
commit e255fee5e2
11 changed files with 21 additions and 14 deletions

BIN
Content/Levels/Level_1/L_Level1.umap (Stored with Git LFS)

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
Content/Levels/Level_3/L_Level3.umap (Stored with Git LFS)

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -4,8 +4,10 @@
#include "Level1.h" #include "Level1.h"
#include "Atmosphere/AtmosphericFog.h" #include "Atmosphere/AtmosphericFog.h"
#include "Components/ExponentialHeightFogComponent.h"
#include "Components/LightComponent.h" #include "Components/LightComponent.h"
#include "Engine/DirectionalLight.h" #include "Engine/DirectionalLight.h"
#include "Engine/ExponentialHeightFog.h"
#include "Engine/SkyLight.h" #include "Engine/SkyLight.h"
#include "LevelSequencePlayer.h" #include "LevelSequencePlayer.h"
@ -30,5 +32,8 @@ void ALevel1::TurnLight(bool show)
void ALevel1::TurnFog(bool show) void ALevel1::TurnFog(bool show)
{ {
if(fog->IsHidden() == show) if(fog->IsHidden() == show)
{
fog->SetActorHiddenInGame(!show); fog->SetActorHiddenInGame(!show);
fog2->GetComponent()->SetVisibility(show);
}
} }

View File

@ -23,5 +23,7 @@ protected:
TSoftObjectPtr<class ADirectionalLight> directLight; TSoftObjectPtr<class ADirectionalLight> directLight;
UPROPERTY(EditDefaultsOnly) UPROPERTY(EditDefaultsOnly)
TSoftObjectPtr<class AAtmosphericFog> fog; TSoftObjectPtr<class AAtmosphericFog> fog;
UPROPERTY(EditDefaultsOnly)
TSoftObjectPtr<class AExponentialHeightFog> fog2;
}; };