RealtimeStyleTransferRuntime/Source/LyraGame/Teams/LyraTeamInfoBase.h

53 lines
1.1 KiB
C
Raw Normal View History

2022-05-23 18:41:30 +00:00
// Copyright Epic Games, Inc. All Rights Reserved.
#pragma once
2022-09-13 07:18:28 +00:00
#include "Engine/EngineTypes.h"
2022-05-23 18:41:30 +00:00
#include "GameFramework/Info.h"
2022-09-13 07:18:28 +00:00
#include "HAL/Platform.h"
2022-05-23 18:41:30 +00:00
#include "System/GameplayTagStack.h"
2022-09-13 07:18:28 +00:00
#include "UObject/UObjectGlobals.h"
2022-05-23 18:41:30 +00:00
#include "LyraTeamInfoBase.generated.h"
class ULyraTeamCreationComponent;
class ULyraTeamSubsystem;
2022-09-13 07:18:28 +00:00
class UObject;
struct FFrame;
2022-05-23 18:41:30 +00:00
UCLASS(Abstract)
class ALyraTeamInfoBase : public AInfo
{
GENERATED_BODY()
public:
ALyraTeamInfoBase(const FObjectInitializer& ObjectInitializer = FObjectInitializer::Get());
int32 GetTeamId() const { return TeamId; }
//~AActor interface
virtual void BeginPlay() override;
virtual void EndPlay(const EEndPlayReason::Type EndPlayReason) override;
//~End of AActor interface
protected:
virtual void RegisterWithTeamSubsystem(ULyraTeamSubsystem* Subsystem);
void TryRegisterWithTeamSubsystem();
private:
void SetTeamId(int32 NewTeamId);
UFUNCTION()
void OnRep_TeamId();
public:
friend ULyraTeamCreationComponent;
UPROPERTY(Replicated)
FGameplayTagStackContainer TeamTags;
private:
UPROPERTY(ReplicatedUsing=OnRep_TeamId)
int32 TeamId;
};