// Fill out your copyright notice in the Description page of Project Settings. #pragma once #include "CoreMinimal.h" #include "GameFramework/Actor.h" #include "Engine/DirectionalLight.h" #include "Components/DirectionalLightComponent.h" #include "Engine/SkyLight.h" #include "Components/SkyLightComponent.h" #include "Engine/ExponentialHeightFog.h" #include #include "Components/ExponentialHeightFogComponent.h" #include #include "NiagaraComponent.h" #include "Kismet/GameplayStatics.h" #include "GameFramework/Pawn.h" #include "Components/SceneComponent.h" #include "WheatherSystem.generated.h" /** Please add a class description */ UCLASS(Blueprintable, BlueprintType) class NESIANDMYPROJECT_API AWheatherSystem : public AActor { GENERATED_BODY() public: // Sets default values for this actor's properties AWheatherSystem(); protected: // Called when the game starts or when spawned virtual void BeginPlay() override; public: // Called every frame virtual void Tick(float DeltaTime) override; public: /** Please add a variable description */ UPROPERTY(BlueprintReadOnly, VisibleAnywhere, Category = "Components") TObjectPtr RainComponent; /** Please add a variable description */ UPROPERTY(BlueprintReadOnly, VisibleAnywhere, Category = "Components") TObjectPtr SnowComponent; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditInstanceOnly, Category = "Standard") TObjectPtr Sun; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditInstanceOnly, Category = "Standard") TObjectPtr Moon; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditInstanceOnly, Category = "Standard") TObjectPtr SkyLight; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditInstanceOnly, Category = "Standard") TObjectPtr SkyAtmosphere; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditInstanceOnly, Category = "Standard") TObjectPtr Fog; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "Standard") double CurrentTime; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "Standard") double DayLengthMiutes; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditDefaultsOnly, Category = "Standard") TObjectPtr DayCurve; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditDefaultsOnly, Category = "Standard") double OneHoure; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditDefaultsOnly, Category = "Standard") TObjectPtr SunlightItensity; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditDefaultsOnly, Category = "Standard") TObjectPtr SkylightIntensity; /** Please add a variable description */ UPROPERTY(BlueprintReadWrite, EditDefaultsOnly, Category = "Standard") TObjectPtr WeatherTypeCurve; UPROPERTY(BlueprintReadWrite, EditDefaultsOnly, Category = "Standard") TObjectPtr FogTimelineCurve; UPROPERTY(BlueprintReadWrite, EditDefaultsOnly, Category = "Standard") TObjectPtr RainTimelineCurve; UPROPERTY(BlueprintReadWrite, EditDefaultsOnly, Category = "Standard") TObjectPtr SnowTimelineCurve; UPROPERTY(BlueprintReadWrite, EditDefaultsOnly, Category = "Standard") TObjectPtr FogHeightFalloffCurve; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "Standard") bool bFog = false; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "Standard") bool bRain = false; UPROPERTY(BlueprintReadWrite, EditAnywhere, Category = "Standard") bool bSnow = false; private: void UpdateWeather(); void UpdateRain(); void UpdateSnow(); void UpdateFog(); float MaxSnow = 0.0; float MaxRain = 0.0; };