Mortar Pro Plugin  Version 2
Modular Turret Plugin
All Classes Namespaces Functions Variables Enumerations Enumerator Pages
UMortarProTeamComponent Class Reference

#include <MortarProTeamComponent.h>

+ Inheritance diagram for UMortarProTeamComponent:
+ Collaboration diagram for UMortarProTeamComponent:

Public Member Functions

EMortarProAgentAttitude::Type GetAttitude (const uint8 &OtherPlayerTeamID)
 
FMortarProTeamProperties GetTeamInfo () const
 
void ResetTeamInfoRunTimeParameters ()
 
void SetTeamInfo (const FMortarProTeamProperties &DesiredTeam, bool bEmitEvent=true)
 
 UMortarProTeamComponent ()
 

Public Attributes

FMortarProBeginTeamChange BeginTeamChange
 
TSet< uint8 > IgnoreTeamsID
 

Static Public Attributes

static uint8 NeutralTeamID
 

Protected Member Functions

virtual void BeginPlay () override
 

Private Attributes

FMortarProTeamProperties DefaultTeamInfo
 
FMortarProTeamProperties TeamInfo
 

Detailed Description

Actor Component for Assigning Team information to an actor It is Generic That can be assigned to any Actor Each Actor then can have a team id,name and color.

Constructor & Destructor Documentation

◆ UMortarProTeamComponent()

UMortarProTeamComponent::UMortarProTeamComponent ( )

Member Function Documentation

◆ BeginPlay()

virtual void UMortarProTeamComponent::BeginPlay ( )
overrideprotectedvirtual

Called when the game starts or when spawned

◆ GetAttitude()

EMortarProAgentAttitude::Type UMortarProTeamComponent::GetAttitude ( const uint8 &  OtherPlayerTeamID)

Function to Find Attitude of current player and other player and returns the attitude

Parameters
[in]OtherPlayerTeamID- Team ID of Other Player
Returns
Returns Attitude towards each other as enum => Friendly,Neutral,Hostile

◆ GetTeamInfo()

FMortarProTeamProperties UMortarProTeamComponent::GetTeamInfo ( ) const

Returns Current Team Properties

Returns
Structure containing all team related info

◆ ResetTeamInfoRunTimeParameters()

void UMortarProTeamComponent::ResetTeamInfoRunTimeParameters ( )

Resets Team Information to Default

◆ SetTeamInfo()

void UMortarProTeamComponent::SetTeamInfo ( const FMortarProTeamProperties DesiredTeam,
bool  bEmitEvent = true 
)

Sets Information For a team and also BroadCast Event When current Team id is different from desired one

Parameters
[in]DesiredTeamTeam Properties to Set
[in]bEmitEventwhether to emit event for team change or not by default true true - emit event false - don't emit

Member Data Documentation

◆ BeginTeamChange

FMortarProBeginTeamChange UMortarProTeamComponent::BeginTeamChange

Team Change Event That Will be Broadcasted as soon as Team changes from Neutral to Desired Team in SwitchTeam

◆ DefaultTeamInfo

FMortarProTeamProperties UMortarProTeamComponent::DefaultTeamInfo
private

Default Team ID - This is The Team information used after every Respawn. So if a player of Team A dies then it will switch back to the default Team after respawning TeamID - Should Be unique and other than 0 which is neutral. Different TeamID means They are enemies.Same TeamID means they are friends TeamName - Each Team Can have a name which can be used in blueprint for different purposes TeamColor - Color For each Team

◆ IgnoreTeamsID

TSet<uint8> UMortarProTeamComponent::IgnoreTeamsID

Team IDs to consider as neutral

◆ NeutralTeamID

uint8 UMortarProTeamComponent::NeutralTeamID
static

This will be the neutral team id.

◆ TeamInfo

FMortarProTeamProperties UMortarProTeamComponent::TeamInfo
private

Current Team ID - This is The Team information for Current Spawn. TeamID - Should Be unique and other than 0 which is neutral. Different TeamID means They are enemies.Same TeamID means they are friends TeamName - Each Team Can have a name which can be used in blueprint for different purposes TeamColor - Color For each Team


The documentation for this class was generated from the following file: