38 lines
1.1 KiB
C++
Executable file
38 lines
1.1 KiB
C++
Executable file
#pragma once
|
|
#include "CoreMinimal.h"
|
|
#include "Components/SceneComponent.h"
|
|
#include "MovedIntoSomethingDelegate.h"
|
|
#include "BobbingComponent.generated.h"
|
|
|
|
class AActor;
|
|
|
|
UCLASS(Blueprintable, ClassGroup=Custom, meta=(BlueprintSpawnableComponent))
|
|
class UBobbingComponent : public USceneComponent {
|
|
GENERATED_BODY()
|
|
public:
|
|
UPROPERTY(BlueprintAssignable, BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true))
|
|
FMovedIntoSomething OnMovedIntoSomethingEvent;
|
|
|
|
protected:
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, Transient, meta=(AllowPrivateAccess=true))
|
|
AActor* OwnerActor;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true))
|
|
bool DoOrientationChecks;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true))
|
|
float BobSpeed;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true))
|
|
float BobSize;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true))
|
|
float OrentationChecksPerSecond;
|
|
|
|
public:
|
|
UBobbingComponent();
|
|
UFUNCTION(BlueprintCallable)
|
|
void SetOwner(AActor* AActor);
|
|
|
|
};
|
|
|