Rewrite absurd implementation of lxCrosshairWidget to use FAnchors instead
This commit is contained in:
@@ -55,30 +55,44 @@ public:
|
||||
UFUNCTION(BlueprintCallable, Category = "Luprex|Miscellaneous")
|
||||
int64 GetPlayerId();
|
||||
|
||||
UFUNCTION(BlueprintCallable, meta = (WorldContext = "context"),Category = "Luprex|Look-At Detection")
|
||||
static void SetLookAt(UObject *context, const FHitResult &hit) { FromContext(context)->CurrentLookAt = hit; }
|
||||
UFUNCTION(BlueprintCallable, meta = (WorldContext = "Context"), Category = "Luprex|Look-At Detection")
|
||||
static void SetLookAt(const UObject *Context, const FHitResult &hit) { FromContext(Context)->CurrentLookAt = hit; }
|
||||
|
||||
UFUNCTION(BlueprintPure, meta = (WorldContext = "context"),Category = "Luprex|Look-At Detection")
|
||||
static const FHitResult &GetLookAt(UObject *context) { return FromContext(context)->CurrentLookAt; }
|
||||
UFUNCTION(BlueprintPure, meta = (WorldContext = "Context"),Category = "Luprex|Look-At Detection")
|
||||
static const FHitResult &GetLookAt(const UObject *Context) { return FromContext(Context)->CurrentLookAt; }
|
||||
|
||||
UFUNCTION(BlueprintPure, meta = (WorldContext = "context"),Category = "Luprex|Look-At Detection")
|
||||
static const AActor *GetLookAtActor(UObject *context) { return FromContext(context)->CurrentLookAt.GetActor(); }
|
||||
UFUNCTION(BlueprintPure, meta = (WorldContext = "Context"),Category = "Luprex|Look-At Detection")
|
||||
static const AActor *GetLookAtActor(const UObject *Context) { return FromContext(Context)->CurrentLookAt.GetActor(); }
|
||||
|
||||
UFUNCTION(BlueprintPure, meta = (WorldContext = "context"),Category = "Luprex|Look-At Detection")
|
||||
static const FHitResult &GetPreviousLookAt(UObject *context) { return FromContext(context)->PreviousLookAt; }
|
||||
UFUNCTION(BlueprintPure, meta = (WorldContext = "Context"),Category = "Luprex|Look-At Detection")
|
||||
static const FHitResult &GetPreviousLookAt(const UObject *Context) { return FromContext(Context)->PreviousLookAt; }
|
||||
|
||||
UFUNCTION(BlueprintPure, meta = (WorldContext = "context"),Category = "Luprex|Look-At Detection")
|
||||
static const AActor *GetPreviousLookAtActor(UObject *context) { return FromContext(context)->PreviousLookAt.GetActor(); }
|
||||
UFUNCTION(BlueprintPure, meta = (WorldContext = "Context"),Category = "Luprex|Look-At Detection")
|
||||
static const AActor *GetPreviousLookAtActor(const UObject *Context) { return FromContext(Context)->PreviousLookAt.GetActor(); }
|
||||
|
||||
UFUNCTION(BlueprintPure, meta = (WorldContext = "context"),Category = "Luprex|Look-At Detection")
|
||||
static bool IsLookAtChanged(UObject *context);
|
||||
UFUNCTION(BlueprintPure, meta = (WorldContext = "Context"),Category = "Luprex|Look-At Detection")
|
||||
static bool IsLookAtChanged(const UObject *Context);
|
||||
|
||||
UFUNCTION(BlueprintCallable, meta = (WorldContext = "Context"), Category = "Luprex|Look-At Detection")
|
||||
static void SetLookAtWidget(const UObject *Context, UUserWidget *Widget, int ZOrder = 100);
|
||||
|
||||
UFUNCTION(BlueprintCallable, meta = (WorldContext = "Context"), Category = "Luprex|Look-At Detection")
|
||||
static UUserWidget *GetLookAtWidget(const UObject *Context) { return FromContext(Context)->LookAtWidget; }
|
||||
|
||||
UFUNCTION(BlueprintCallable, meta = (WorldContext = "Context"), Category = "Luprex|Look-At Detection")
|
||||
static void ClearLookAtWidget(const UObject *Context);
|
||||
|
||||
//
|
||||
// Look-At Related Events
|
||||
//
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent, Category = "Luprex|Look-At Detection")
|
||||
void CalculateLookAt(APlayerController *PlayerController);
|
||||
|
||||
UFUNCTION(BlueprintImplementableEvent, Category = "Luprex|Look-At Detection")
|
||||
void LookAtChanged();
|
||||
|
||||
|
||||
// Assemble a lua call. To call into lua:
|
||||
//
|
||||
// * Use LuaCallBegin
|
||||
@@ -127,8 +141,8 @@ public:
|
||||
// to update luprex sockets and update luprex itself.
|
||||
virtual uint32 Run() override;
|
||||
|
||||
// Get the current Luprex Game Mode Base, given a context object.
|
||||
static ALuprexGameModeBase *FromContext(const UObject *context);
|
||||
// Get the current Luprex Game Mode Base, given a Context object.
|
||||
static ALuprexGameModeBase *FromContext(const UObject *Context);
|
||||
|
||||
// Asset Lookup by Name.
|
||||
UPROPERTY()
|
||||
@@ -145,6 +159,9 @@ public:
|
||||
UPROPERTY()
|
||||
FHitResult CurrentLookAt;
|
||||
|
||||
UPROPERTY()
|
||||
UUserWidget *LookAtWidget;
|
||||
|
||||
// The sensitivity level at which a log message triggers a debugger breakpoint.
|
||||
UPROPERTY(EditAnywhere, Category="Debugging Tools")
|
||||
ElxLogVerbosity BreakToDebuggerLogVerbosity;
|
||||
|
||||
Reference in New Issue
Block a user