// Oleg Petruny proprietary.

#include "Level1.h"

#include "Atmosphere/AtmosphericFog.h"
#include "Components/ExponentialHeightFogComponent.h"
#include "Components/LightComponent.h"
#include "Engine/DirectionalLight.h"
#include "Engine/ExponentialHeightFog.h"
#include "Engine/SkyLight.h"
#include "LevelSequencePlayer.h"

#include "CutsceneManager.h"

void ALevel1::BeginPlay()
{
    ALevelBase::BeginPlay();

    TurnLight(false);
    TurnFog(false);

    CallNextState();
}

void ALevel1::TurnLight(bool show)
{
    if(directLight->GetLightComponent()->IsVisible() != show)
        directLight->GetLightComponent()->SetVisibility(show);
}

void ALevel1::TurnFog(bool show)
{
    if(fog->IsHidden() == show)
    {
        fog->SetActorHiddenInGame(!show);
        fog2->GetComponent()->SetVisibility(show);
    }
}
