RealtimeStyleTransferRuntime/Source/LyraGame/AbilitySystem/Abilities/LyraGameplayAbility_Reset.h

46 lines
1.2 KiB
C
Raw Normal View History

2022-05-23 18:41:30 +00:00
// Copyright Epic Games, Inc. All Rights Reserved.
#pragma once
#include "AbilitySystem/Abilities/LyraGameplayAbility.h"
2022-09-13 07:18:28 +00:00
#include "GameplayAbilitySpec.h"
#include "UObject/UObjectGlobals.h"
2022-05-23 18:41:30 +00:00
#include "LyraGameplayAbility_Reset.generated.h"
2022-09-13 07:18:28 +00:00
class AActor;
class UObject;
struct FGameplayAbilityActorInfo;
struct FGameplayEventData;
2022-05-23 18:41:30 +00:00
/**
* ULyraGameplayAbility_Reset
*
* Gameplay ability used for handling quickly resetting the player back to initial spawn state.
* Ability is activated automatically via the "GameplayEvent.RequestReset" ability trigger tag (server only).
*/
UCLASS()
class LYRAGAME_API ULyraGameplayAbility_Reset : public ULyraGameplayAbility
{
GENERATED_BODY()
public:
ULyraGameplayAbility_Reset(const FObjectInitializer& ObjectInitializer = FObjectInitializer::Get());
protected:
void DoneAddingNativeTags();
virtual void ActivateAbility(const FGameplayAbilitySpecHandle Handle, const FGameplayAbilityActorInfo* ActorInfo, const FGameplayAbilityActivationInfo ActivationInfo, const FGameplayEventData* TriggerEventData) override;
};
USTRUCT(BlueprintType)
struct FLyraPlayerResetMessage
{
GENERATED_BODY()
UPROPERTY(BlueprintReadOnly)
2022-09-13 07:18:28 +00:00
TObjectPtr<AActor> OwnerPlayerState = nullptr;
2022-05-23 18:41:30 +00:00
};