daily pastebin goal
36%
SHARE
TWEET

item.h

nbarber20 Dec 21st, 2018 (edited) 78 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #pragma once
  2.  
  3. #include "CoreMinimal.h"
  4. #include "GameFramework/Actor.h"
  5. #include <Animation/AnimBlueprint.h>
  6. #include <Animation/AnimationAsset.h>
  7. #include <Image.h>
  8. #include <Engine/Texture2D.h>
  9. #include <Curves/CurveFloat.h>
  10. #include <Curves/CurveVector.h>
  11. #include "Item.generated.h"
  12. UENUM(BlueprintType)        //"BlueprintType" is essential to include
  13. enum class EScopeEnum : uint8
  14. {
  15.     SE_IronSight    UMETA(DisplayName = "Iron Sights"),
  16.     SE_RedDot   UMETA(DisplayName = "Red Dot"),
  17.     SE_Scope    UMETA(DisplayName = "Scope")
  18. };
  19. UCLASS(BlueprintType)
  20. class TUNICS_API AItem : public AActor
  21. {
  22.     GENERATED_BODY()
  23.    
  24. public:
  25.     // Sets default values for this actor's properties
  26.     AItem();
  27.     UFUNCTION(BlueprintCallable, Category = Weapon)
  28.         virtual void OnFire();
  29.  
  30.  
  31.  
  32.     UFUNCTION(BlueprintCallable, Category = Weapon)
  33.         virtual void OnReload();
  34.     UFUNCTION(BlueprintCallable, Category = Weapon)
  35.         virtual void OnReloadFinished();
  36.     UFUNCTION(BlueprintCallable, Category = Weapon)
  37.         virtual void OnChambered();
  38.     UFUNCTION(BlueprintCallable, Category = Weapon)
  39.         virtual void OnChamberedFinished();
  40.     UFUNCTION(BlueprintCallable, Category = Weapon)
  41.         UTexture2D* GetIcon();
  42.  
  43.  
  44.  
  45.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Weapon)
  46.     UCurveVector *RecoilCurve;
  47.  
  48.  
  49.     bool IsFiring;
  50.  
  51.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Item)
  52.     bool CanBeDropped = true;
  53.  
  54.  
  55.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Item)
  56.     UTexture2D* Icon;
  57.  
  58.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Item)
  59.     UTexture2D* InventoryImage;
  60.  
  61.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Item)
  62.     int SlotSizeX;
  63.  
  64.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Item)
  65.     int SlotSizeY;
  66.  
  67.  
  68.     UPROPERTY(Replicated, EditAnywhere, BlueprintReadWrite, Category = Item)
  69.     bool CanPickup;
  70.  
  71.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Item)
  72.     int MaxStackSize = 1;
  73.  
  74.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Item)
  75.     int Stack = 1;
  76.  
  77.  
  78.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Animation)
  79.     UAnimBlueprintGeneratedClass* ABP;
  80. protected:
  81.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Animation)
  82.     UAnimationAsset* ChamberAnimation;
  83.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Animation)
  84.     UAnimationAsset* ReloadAnimation;
  85.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Animation)
  86.     UAnimationAsset* FireAnimation;
  87.  
  88.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Animation)
  89.     UAnimationAsset* EmptyIdleAnimation;
  90.  
  91.     //TODO Remove
  92.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Animation)
  93.         UAnimationAsset* EquipAnimation;
  94.     UPROPERTY(EditAnywhere, BlueprintReadWrite, Category = Animation)
  95.         UAnimationAsset* UnEquipAnimation;
  96.     // Called when the game starts or when spawned
  97.     virtual void BeginPlay() override;
  98.  
  99. public:
  100.     // Called every frame
  101.     virtual void Tick(float DeltaTime) override;
  102.  
  103. };
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top