5#include "Kismet/BlueprintFunctionLibrary.h"
7#include "ModExtensionLibrary.generated.h"
54 uint64 Generation = 0;
94 UFUNCTION(BlueprintCallable, Category =
"Mod|Extension")
97 int32 Priority, const TArray<FString>& Before,
98 const TArray<FString>& After,
float CancelValue,
105 UFUNCTION(BlueprintCallable, Category =
"Mod|Extension")
118 UFUNCTION(BlueprintCallable, Category =
"Mod|Service")
120 const FString& Version, FName Permission, UObject* Instance);
123 UFUNCTION(BlueprintCallable, Category =
"Mod|Service")
135 UFUNCTION(BlueprintCallable, Category =
"Mod|Extension")
137 int64& Context, int64& Object);
143 UFUNCTION(BlueprintCallable, Category =
"Mod|Behavior", meta = (DefaultToSelf =
"Owner"))
148 static MODLOADER_API int32
RegisterModBehavior(UObject& Owner, FName Id, const TCHAR* Signature, FName Function,
156 static
bool FindBehaviorObject(UObject& Owner, FName Alias, FName TypeId,
bool bPlayerProvider, uint64& Context,
169 int32 (*Provide)(
UModInstance&, FName, FName,
const FString&,
const FString&, FName, UObject*);
171 int32 (*RegisterBehavior)(UObject&, FName,
const TCHAR*, FName,
EModExtensionStage, FName);
173 int32 (*ContinueBehavior)(UObject&);
174 bool (*FindObject)(UObject&, FName, FName, bool, uint64&, uint64&);
178 static MODLOADER_API
void SetBridge(
FBridge Bridge);
EModExtensionStage
A game-thread callback stage in the World extension bus.
Definition ModExtensionLibrary.h:18
EModExtensionOperation
A requested modification of one generated Hook value.
Definition ModExtensionLibrary.h:32
@ Observe
Observation only.
Definition ModExtensionLibrary.h:34
DECLARE_DYNAMIC_DELEGATE(FModBehaviorEvent)
Receives a published event on its Mod behavior.
A Mod-owned behavior instance attached to its authorized World.
Definition ModBehavior.h:13
Registers generated extension callbacks for cooked Mod Blueprints.
Definition ModExtensionLibrary.h:76
static MODLOADER_API int32 RegisterModBehavior(UObject &Owner, FName Id, const TCHAR *Signature, FName Function, EModExtensionStage Stage, FName SourceType)
Registers an override against its published behavior contract.
static MODLOADER_API int32 NextModHook(UObject *Owner)
Continues the current wrapping Hook with its existing input.
static MODLOADER_API bool GetModBehaviorSource(UObject &Owner, FName TypeId, const TCHAR *Signature, FModPayloadObject &OutSource)
Borrows the current callback's source through a published World interface.
static MODLOADER_API bool AcquireModService(UModInstance *Owner, FName Id, FName TypeId, const FString &Signature, int64 &Context, int64 &Object)
Acquires a declared service for generated SDK calls.
static int32 BindBehaviorEvent(UModBehavior &Behavior, FName Id, const TCHAR *Signature, FName SourceType, const FModBehaviorEvent &Delegate, FModExtensionToken &Token)
Binds a delegate through the World extension dispatcher.
static MODLOADER_API void WithdrawModService(UModInstance *Owner, FName Id)
Revokes the named service when it is owned by this Mod.
static void UnbindBehaviorEvent(UModBehavior &Behavior, const FModExtensionToken &Token)
Unsubscribes a delegate owned by the behavior.
static MODLOADER_API void UnregisterModExtension(UModInstance *Owner, const FModExtensionToken &Token)
Requests unsubscription on the game thread.
static bool FindBehaviorObject(UObject &Owner, FName Alias, FName TypeId, bool bPlayerProvider, uint64 &Context, uint64 &Object)
Finds an object or player provider allowed by the World policy.
static MODLOADER_API int32 ProvideModService(UModInstance *Owner, FName Id, FName TypeId, const FString &Signature, const FString &Version, FName Permission, UObject *Instance)
Provides a named World service during On Mod Register.
static MODLOADER_API int32 RegisterModExtension(UModInstance *Owner, FName Id, FName Key, FName Function, EModExtensionStage Stage, EModExtensionOperation Operation, int32 Priority, const TArray< FString > &Before, const TArray< FString > &After, float CancelValue, FModExtensionToken &Token)
Registers a synchronous function on the game thread.
A game-thread Mod entry point owned by one game instance.
Definition ModInstance.h:52
Identifies a registration owned by one mod and World.
Definition ModExtensionLibrary.h:48
A read-only object borrowed for one extension callback.
Definition ModExtensionLibrary.h:62
Definition ModExtensionLibrary.h:165