79 lines
2.2 KiB
C++
79 lines
2.2 KiB
C++
#pragma once
|
|
#include "SkillTreeState.h"
|
|
#include "PlayerSetupState.generated.h"
|
|
|
|
// Properties belonging to a character class
|
|
USTRUCT()
|
|
struct FCharacterClassProperty
|
|
{
|
|
GENERATED_BODY()
|
|
public:
|
|
UPROPERTY(BlueprintReadOnly, EditAnywhere)
|
|
FString name;
|
|
UPROPERTY(BlueprintReadOnly, EditAnywhere)
|
|
class UAbilityInfo* basicAttack;
|
|
UPROPERTY(BlueprintReadOnly, EditAnywhere)
|
|
TArray<TSubclassOf<class AItemBase>> classItems;
|
|
|
|
// Class Specific Curves, if these are not set the character defaults are used
|
|
UPROPERTY(BlueprintReadOnly, EditAnywhere)
|
|
UCurveFloat* healthCurve;
|
|
UPROPERTY(BlueprintReadOnly, EditAnywhere)
|
|
UCurveFloat* manaCurve;
|
|
UPROPERTY(BlueprintReadOnly, EditAnywhere)
|
|
UCurveFloat* armorCurve;
|
|
UPROPERTY(BlueprintReadOnly, EditAnywhere)
|
|
UCurveFloat* attackSpeedCurve;
|
|
};
|
|
|
|
// A data asset that provides a list of character classes
|
|
UCLASS()
|
|
class UCharacterClassPropertySet : public UDataAsset
|
|
{
|
|
GENERATED_BODY()
|
|
public:
|
|
UPROPERTY(BlueprintReadOnly, EditAnywhere)
|
|
TArray<FCharacterClassProperty> classes;
|
|
|
|
UFUNCTION(BlueprintCallable, Category = "Character Class")
|
|
FCharacterClassProperty GetCharacterClass(int32 classID) const;
|
|
};
|
|
|
|
// Setings for character bone scales
|
|
USTRUCT(BlueprintType)
|
|
struct FCharacterCustomization
|
|
{
|
|
GENERATED_BODY()
|
|
|
|
public:
|
|
UPROPERTY(BlueprintReadWrite, Category = "Save")
|
|
float overallScale = 1.0f;
|
|
UPROPERTY(BlueprintReadWrite, Category = "Save")
|
|
float headScale = 1.0f;
|
|
UPROPERTY(BlueprintReadWrite, Category = "Save")
|
|
float torsoScale = 1.0f;
|
|
UPROPERTY(BlueprintReadWrite, Category = "Save")
|
|
float leftArmScale = 1.0f;
|
|
UPROPERTY(BlueprintReadWrite, Category = "Save")
|
|
float rightArmScale = 1.0f;
|
|
UPROPERTY(BlueprintReadWrite, Category = "Save")
|
|
float legThicknessYScale = 1.0f;
|
|
UPROPERTY(BlueprintReadWrite, Category = "Save")
|
|
float legThicknessZScale = 1.0f;
|
|
|
|
};
|
|
|
|
// All player settings, from the lobby
|
|
// this includes selected skill set and character customizations
|
|
USTRUCT()
|
|
struct FPlayerSetupState
|
|
{
|
|
GENERATED_BODY()
|
|
public:
|
|
UPROPERTY()
|
|
FSkillTreeState skills;
|
|
UPROPERTY()
|
|
FCharacterCustomization customizations;
|
|
UPROPERTY()
|
|
int32 characterClass;
|
|
}; |