G1R AngelScript
Scripting reference for the Gothic 1 Remake
Loading...
Searching...
No Matches
UGothicAIGroup Class Reference

Subclass to define your own kind of groups. Each character can be in multiple groups in the same time. The UAIGroupStatus object allows to share information between the characters of the group. This is helpful whenever more than two character need to interact with each other for a while. More...

Public Member Functions

Functions
void HandleMemberJoined (AGothicCharacter Character)
 Called when a group member dropped unconscious.
void DebugDrawGroup (float32 LifeTimeSeconds) const
 Outputs 3D debug drawing to show where the group is.
void DisplayImGui (AGothicCharacter ContextCharacter)
 Display debugging information for the given character.
TArray< AGothicCharacter > GetConsciousJoinedCharacters () const
 Returns all joined characters who are neither dead nor defeated.
FBox GetGroupBoundingBox () const
 Computes the bounding box of all characters that have joined this group.
FVector GetGroupCenterLocation () const
 Returns the average position of all characters that have joined this group.
TArray< AActor > GetGroupTargets () const
TArray< AGothicCharacter > GetJoinedCharactersWithTags (FGameplayTagContainer Included, FGameplayTagContainer Excluded) const
 Returns all joined characters who match the given tag containers.
void HandleMemberDied (AGothicCharacter Character)
 Called when a group member died.
UCharacterAIState GetMemberAIStateByClass (const AGothicCharacter Member, TSubclassOf< UCharacterAIState > StateClass) const
void HandleMemberLeft (AGothicCharacter Character)
 Called when a group member dropped unconscious.
void HandleMemberUnconscious (AGothicCharacter Character)
 Called when a group member dropped unconscious.
bool HasCharacterJoinedGroup (AGothicCharacter Character) const
 Returns true if the given character has joined this group.
bool IsCharacterAllowedToJoin (AGothicCharacter Character)
 Return whether the given character is allowed to join this group.
void MakeCharacterJoinGroup (AGothicCharacter Character)
 Adds the given character to this group. Does not check if it's allowed to do so.
void MakeCharacterLeaveGroup (AGothicCharacter Character)
 Removes the given character from this group.
Public Member Functions inherited from UObject
bool MarkPackageDirty () const
void RemoveFromRoot ()
bool GetIsRooted () const
bool IsTransient () const
bool Modify (bool bAlwaysMarkDirty=true)
void SetTransactional (bool bTransactional)
bool IsSupportedForNetworking () const
UClass GetClass () const
UObject GetOuter () const
UObject GetTypedOuter (TSubclassOf< UObject > Target) const
 Traverses the outer chain searching for the next object of a certain type.
UPackage GetOutermost () const
UPackage GetPackage () const
void AddToRoot ()
UWorld GetWorld () const
FName GetName () const
FString GetFullName (const UObject StopOuter=nullptr) const
FString GetPathName (const UObject StopOuter=nullptr) const
bool IsA (const UClass Class) const
 Returns true if this object is of the specified type, or a child of that type.
void SaveConfig ()
void LoadConfig ()
void ReloadConfig ()
void CopyScriptPropertiesFrom (const UObject OtherObject)
void opCast (?&Address) const
FString ToString () const

Static Public Member Functions

Static Functions
static UClass StaticClass ()
static TArray< UGothicAIGroup > GetAllActiveGroupsOfClass (TSubclassOf< UGothicAIGroup > GroupClass)
 Return whether the given character is allowed to join this group.
Static Public Member Functions inherited from UObject
static UClass StaticClass ()

Public Attributes

GothicAIGroup
TArray< AGothicCharacter > JoinedCharacters
 Characters that have joined this group.
TArray< FGameplayAttribute > ListenToAttributeChangesOf
 Call the HandleMemberAttributeChanged function whenever a characters attribute was changed.
FGameplayTagContainer OwnedTagsToAddToMembers
 These tags will be added to all Members as OwnedTags.
Variables
const FBox GroupBoundingBox
 Computes the bounding box of all characters that have joined this group.
const FVector GroupCenterLocation
 Returns the average position of all characters that have joined this group.
const TArray< AActor > GroupTargets
const TArray< AGothicCharacter > ConsciousJoinedCharacters
 Returns all joined characters who are neither dead nor defeated.
Public Attributes inherited from UObject
const UClass Class
const UObject Outer
const UPackage Outermost
const UPackage Package
const UWorld World
const FName Name
const bool IsRooted

Detailed Description

Subclass to define your own kind of groups. Each character can be in multiple groups in the same time. The UAIGroupStatus object allows to share information between the characters of the group. This is helpful whenever more than two character need to interact with each other for a while.

Example:

  • Fighting as a pack
  • Standing in a queue

Subclass this to add your own groups and information!

Member Function Documentation

◆ DebugDrawGroup()

void DebugDrawGroup ( float32 LifeTimeSeconds) const

Outputs 3D debug drawing to show where the group is.

◆ DisplayImGui()

void DisplayImGui ( AGothicCharacter ContextCharacter)

Display debugging information for the given character.

◆ GetAllActiveGroupsOfClass()

TArray< UGothicAIGroup > GetAllActiveGroupsOfClass ( TSubclassOf< UGothicAIGroup > GroupClass)
static

Return whether the given character is allowed to join this group.

◆ GetConsciousJoinedCharacters()

TArray< AGothicCharacter > GetConsciousJoinedCharacters ( ) const

Returns all joined characters who are neither dead nor defeated.

◆ GetGroupBoundingBox()

FBox GetGroupBoundingBox ( ) const

Computes the bounding box of all characters that have joined this group.

◆ GetGroupCenterLocation()

FVector GetGroupCenterLocation ( ) const

Returns the average position of all characters that have joined this group.

◆ GetGroupTargets()

TArray< AActor > GetGroupTargets ( ) const

◆ GetJoinedCharactersWithTags()

TArray< AGothicCharacter > GetJoinedCharactersWithTags ( FGameplayTagContainer Included,
FGameplayTagContainer Excluded ) const

Returns all joined characters who match the given tag containers.

◆ GetMemberAIStateByClass()

UCharacterAIState GetMemberAIStateByClass ( const AGothicCharacter Member,
TSubclassOf< UCharacterAIState > StateClass ) const

◆ HandleMemberDied()

void HandleMemberDied ( AGothicCharacter Character)

Called when a group member died.

◆ HandleMemberJoined()

void HandleMemberJoined ( AGothicCharacter Character)

Called when a group member dropped unconscious.

◆ HandleMemberLeft()

void HandleMemberLeft ( AGothicCharacter Character)

Called when a group member dropped unconscious.

◆ HandleMemberUnconscious()

void HandleMemberUnconscious ( AGothicCharacter Character)

Called when a group member dropped unconscious.

◆ HasCharacterJoinedGroup()

bool HasCharacterJoinedGroup ( AGothicCharacter Character) const

Returns true if the given character has joined this group.

◆ IsCharacterAllowedToJoin()

bool IsCharacterAllowedToJoin ( AGothicCharacter Character)

Return whether the given character is allowed to join this group.

◆ MakeCharacterJoinGroup()

void MakeCharacterJoinGroup ( AGothicCharacter Character)

Adds the given character to this group. Does not check if it's allowed to do so.

◆ MakeCharacterLeaveGroup()

void MakeCharacterLeaveGroup ( AGothicCharacter Character)

Removes the given character from this group.

◆ StaticClass()

UClass StaticClass ( )
static

Member Data Documentation

◆ ConsciousJoinedCharacters

const TArray<AGothicCharacter> ConsciousJoinedCharacters

Returns all joined characters who are neither dead nor defeated.

◆ GroupBoundingBox

const FBox GroupBoundingBox

Computes the bounding box of all characters that have joined this group.

◆ GroupCenterLocation

const FVector GroupCenterLocation

Returns the average position of all characters that have joined this group.

◆ GroupTargets

const TArray<AActor> GroupTargets

◆ JoinedCharacters

TArray<AGothicCharacter> JoinedCharacters

Characters that have joined this group.

◆ ListenToAttributeChangesOf

TArray<FGameplayAttribute> ListenToAttributeChangesOf

Call the HandleMemberAttributeChanged function whenever a characters attribute was changed.

◆ OwnedTagsToAddToMembers

FGameplayTagContainer OwnedTagsToAddToMembers

These tags will be added to all Members as OwnedTags.