#pragma once #include "CoreMinimal.h" #include "UObject/NoExportTypes.h" #include "Engine/NetSerialization.h" #include "WeaponFireComponent.h" #include "ProjectileLauncherBaseComponent.generated.h" class AProjectileBase; class UItemUpgrade; UCLASS(Abstract, Blueprintable, ClassGroup=Custom, meta=(BlueprintSpawnableComponent)) class UProjectileLauncherBaseComponent : public UWeaponFireComponent { GENERATED_BODY() public: DECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam(FProjectileSpawned, AProjectileBase*, Projectile); UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true)) bool IgnoreCollisionWithSelf; UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true)) bool UseProjectileUpgrades; UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true)) bool UseSpread; UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true)) float VerticalSpread; UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true)) float HorizontalSpread; UPROPERTY(BlueprintAssignable, BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true)) FProjectileSpawned OnProjectileSpawned; protected: UPROPERTY(BlueprintReadWrite, EditAnywhere, Transient, meta=(AllowPrivateAccess=true)) TArray ProjectileUpgrades; UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true)) float ArcStartAngle; UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true)) bool TransferCharacterVelocityToProjectile; UPROPERTY(BlueprintReadWrite, EditAnywhere, meta=(AllowPrivateAccess=true)) bool CameraToMuzzleFireCheck; public: UProjectileLauncherBaseComponent(); protected: UFUNCTION(BlueprintCallable, Reliable, Server) void Server_StopFire(); UFUNCTION(BlueprintCallable, Reliable, Server) void Server_Fire(FVector Origin, FVector_NetQuantizeNormal Direction, FVector_NetQuantizeNormal initialBonusVelocity, AProjectileBase* DormentProjectile, bool notifyClients); UFUNCTION(BlueprintCallable, NetMulticast, Unreliable) void All_ShowHit(); };