|
G1R AngelScript
Scripting reference for the Gothic 1 Remake
|
@class UTargetingSubsystem More...
Public Member Functions | |
Targeting System | Async Request | |
| void | RemoveAsyncTargetingRequestWithHandle (FTargetingRequestHandle &TargetingHandle) |
| Method to remove an async targeting request with a given targeting handle. | |
| FTargetingRequestHandle | StartAsyncTargetingRequest (const UTargetingPreset TargetingPreset, FTargetingSourceContext InSourceContext, FTargetingRequestDynamicDelegate CompletionDynamicDelegate=FTargetingRequestDynamicDelegate()) |
| Method to queue an async targeting request based on a gameplay targeting preset. | |
Targeting System | Instant Request | |
| void | ExecuteTargetingRequest (const UTargetingPreset TargetingPreset, FTargetingSourceContext InSourceContext, FTargetingRequestDynamicDelegate CompletionDynamicDelegate=FTargetingRequestDynamicDelegate()) |
| Method to execute an immediate targeting request based on a gameplay targeting preset. | |
Targeting System | Targeting Results | |
| void | GetTargetingResultsActors (FTargetingRequestHandle TargetingHandle, TArray< AActor > &Targets) const |
| Method to get the actor targets from a given targeting request handle. | |
| void | GetTargetingResults (FTargetingRequestHandle TargetingHandle, TArray< FHitResult > &OutTargets) const |
| Helper method to get the set of hit results for a given targeting handle. | |
Targeting System | Targeting Types | |
| FTargetingSourceContext | GetTargetingSourceContext (FTargetingRequestHandle TargetingHandle) const |
| Returns the targeting source context for the targeting request handle. | |
| 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 | |
Targeting System | Data Stores | |
| static void | OverrideCollisionQueryTaskData (FTargetingRequestHandle TargetingHandle, FCollisionQueryTaskData CollisionQueryDataOverride) |
| Function that lets you set a data store from a certain Targeting Handle to add some Collision Query Param Overrides. | |
Static Functions | |
| static UTargetingSubsystem | Get () |
| static UClass | StaticClass () |
| Static Public Member Functions inherited from UGameInstanceSubsystem | |
| static UClass | StaticClass () |
| Static Public Member Functions inherited from USubsystem | |
| static UClass | StaticClass () |
| Static Public Member Functions inherited from UObject | |
| static UClass | StaticClass () |
Additional Inherited Members | |
| 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 |
@class UTargetingSubsystem
The Targeting Subsystem is the entry point for users to initiate targeting requests.
The entry point to the system is the target request handle. The handle is used to interface with the targeting data stores. Data stores are templated classes around generic data structs that the system and tasks use to accomplish a targeting request.
The targeting system has 3 mandatory data stores and 1 required for async targeting request. These data stores are required to be set up before the system can properly run a targeting request. The mandatory 3 data stores are FTargetingRequestData, FTargetingTaskSet, and FTargetingSourceContext. FTargetingAsyncTaskData is implicitly setup when an async targeting request is initiated.
Users can do all the pieces manually in C++ by setting up the required data stores themselves, or, to have it a bit more automated, the user can use the APIs that utilize UTargetingPreset data asset.
For immediate targeting requests users will call the Execute methods. These functions perform all the tasks till completion. The system will not go latent.
For async targeting requests users will call the Start Async methods. The system will queue up a targeting request and as each task is processed the system can run through all the tasks to completion or stop processing until the next frame while it waits for a task to complete.
Note about Targeting Handles, when a targeting handle is created it will not implicitly release the handle. It is up to the creator to either grab a Async Task Data or Immediate Task Data and set a flag indicating the system should do it for them after the callback fires, or it is up to the user to release the handle when they are done with it.
| void ExecuteTargetingRequest | ( | const UTargetingPreset | TargetingPreset, |
| FTargetingSourceContext | InSourceContext, | ||
| FTargetingRequestDynamicDelegate | CompletionDynamicDelegate = FTargetingRequestDynamicDelegate ( ) ) |
Method to execute an immediate targeting request based on a gameplay targeting preset.
|
static |
| void GetTargetingResults | ( | FTargetingRequestHandle | TargetingHandle, |
| TArray< FHitResult > & | OutTargets ) const |
Helper method to get the set of hit results for a given targeting handle.
| void GetTargetingResultsActors | ( | FTargetingRequestHandle | TargetingHandle, |
| TArray< AActor > & | Targets ) const |
Method to get the actor targets from a given targeting request handle.
| FTargetingSourceContext GetTargetingSourceContext | ( | FTargetingRequestHandle | TargetingHandle | ) | const |
Returns the targeting source context for the targeting request handle.
|
static |
Function that lets you set a data store from a certain Targeting Handle to add some Collision Query Param Overrides.
| void RemoveAsyncTargetingRequestWithHandle | ( | FTargetingRequestHandle & | TargetingHandle | ) |
Method to remove an async targeting request with a given targeting handle.
| FTargetingRequestHandle StartAsyncTargetingRequest | ( | const UTargetingPreset | TargetingPreset, |
| FTargetingSourceContext | InSourceContext, | ||
| FTargetingRequestDynamicDelegate | CompletionDynamicDelegate = FTargetingRequestDynamicDelegate ( ) ) |
Method to queue an async targeting request based on a gameplay targeting preset.
|
static |