54 lines
1.7 KiB
C++
Executable file
54 lines
1.7 KiB
C++
Executable file
#pragma once
|
|
#include "CoreMinimal.h"
|
|
#include "AmmoDrivenWeapon.h"
|
|
#include "BeltDrivenWeapon.generated.h"
|
|
|
|
class UAudioComponent;
|
|
class UCurveFloat;
|
|
class USoundCue;
|
|
|
|
UCLASS(Abstract, Blueprintable)
|
|
class ABeltDrivenWeapon : public AAmmoDrivenWeapon {
|
|
GENERATED_BODY()
|
|
public:
|
|
protected:
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, Instanced, Transient, meta=(AllowPrivateAccess=true))
|
|
UAudioComponent* BarrelAudio;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true))
|
|
USoundCue* BarrelSound;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true))
|
|
float BarrelFadeIn;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true))
|
|
float BarrelFadeOut;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true))
|
|
UCurveFloat* BarrelPitchCurve;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true))
|
|
float BarrelSpinUpTime;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true))
|
|
float BarrelSpinDownTime;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, Transient, meta=(AllowPrivateAccess=true))
|
|
float CurrentSpinRate;
|
|
|
|
UPROPERTY(BlueprintReadWrite, EditAnywhere, Replicated, Transient, meta=(AllowPrivateAccess=true))
|
|
bool Simulate_SpinBarrel;
|
|
|
|
public:
|
|
ABeltDrivenWeapon();
|
|
virtual void GetLifetimeReplicatedProps(TArray<FLifetimeProperty>& OutLifetimeProps) const override;
|
|
|
|
protected:
|
|
UFUNCTION(BlueprintCallable, Reliable, Server)
|
|
void Server_StopBarrel();
|
|
|
|
UFUNCTION(BlueprintCallable, Reliable, Server)
|
|
void Server_StartBarrel();
|
|
|
|
};
|
|
|