From 80c77bf3d91c000070cd36299e3f824292fdad28 Mon Sep 17 00:00:00 2001 From: Yermek Garifullanov <150758974+YermekG@users.noreply.github.com> Date: Tue, 8 Oct 2024 20:00:47 +1300 Subject: [PATCH] feat: minor improvements (#140) * fix: fixed minor issues * fix: compile issues with header file inclusion --- Source/Immutable/Private/Immutable/ImtblBlui.cpp | 6 +++++- .../Public/Immutable/Actions/ImtblBlueprintAsyncAction.h | 4 ++-- Source/Immutable/Public/Immutable/ImmutableDataTypes.h | 2 +- Source/Immutable/Public/Immutable/ImmutableSubsystem.h | 6 +++--- 4 files changed, 11 insertions(+), 7 deletions(-) diff --git a/Source/Immutable/Private/Immutable/ImtblBlui.cpp b/Source/Immutable/Private/Immutable/ImtblBlui.cpp index 7a346ad..8b085f4 100644 --- a/Source/Immutable/Private/Immutable/ImtblBlui.cpp +++ b/Source/Immutable/Private/Immutable/ImtblBlui.cpp @@ -93,7 +93,11 @@ void UImtblBlui::Init() BluEye->bEnabled = true; IMTBL_LOG("Events subscribed") - BluEye->Init(); + if (!BluEye->Init()) + { + IMTBL_ERR("BluEye is not initialised") + return; + } IMTBL_LOG("BluEye Initialised") // We're attempting to replicate the process that Unreal's WebBrowser diff --git a/Source/Immutable/Public/Immutable/Actions/ImtblBlueprintAsyncAction.h b/Source/Immutable/Public/Immutable/Actions/ImtblBlueprintAsyncAction.h index 0389420..7f8d919 100644 --- a/Source/Immutable/Public/Immutable/Actions/ImtblBlueprintAsyncAction.h +++ b/Source/Immutable/Public/Immutable/Actions/ImtblBlueprintAsyncAction.h @@ -2,7 +2,7 @@ #pragma once -#include "CoreMinimal.h" +#include "Immutable/ImmutableSubsystem.h" #include "Kismet/BlueprintAsyncActionBase.h" #include "ImtblBlueprintAsyncAction.generated.h" @@ -20,5 +20,5 @@ class IMMUTABLE_API UImtblBlueprintAsyncAction : public UBlueprintAsyncActionBas UObject* WorldContextObject; // Get subsystem - class UImmutableSubsystem* GetSubsystem() const; + UImmutableSubsystem* GetSubsystem() const; }; diff --git a/Source/Immutable/Public/Immutable/ImmutableDataTypes.h b/Source/Immutable/Public/Immutable/ImmutableDataTypes.h index 46a0b54..768f9c2 100644 --- a/Source/Immutable/Public/Immutable/ImmutableDataTypes.h +++ b/Source/Immutable/Public/Immutable/ImmutableDataTypes.h @@ -100,7 +100,7 @@ struct FImtblUserProfile }; USTRUCT() -struct FImmutablePassportZkEvmRequestAccountsData +struct IMMUTABLE_API FImmutablePassportZkEvmRequestAccountsData { GENERATED_BODY() diff --git a/Source/Immutable/Public/Immutable/ImmutableSubsystem.h b/Source/Immutable/Public/Immutable/ImmutableSubsystem.h index 2a9a32a..d0d4693 100644 --- a/Source/Immutable/Public/Immutable/ImmutableSubsystem.h +++ b/Source/Immutable/Public/Immutable/ImmutableSubsystem.h @@ -2,7 +2,7 @@ #pragma once -#include "CoreMinimal.h" +#include "ImmutablePassport.h" #include "Subsystems/GameInstanceSubsystem.h" // clang-format off #include "ImmutableSubsystem.generated.h" @@ -22,7 +22,7 @@ class IMMUTABLE_API UImmutableSubsystem : public UGameInstanceSubsystem virtual void Initialize(FSubsystemCollectionBase& Collection) override; virtual void Deinitialize() override; - TWeakObjectPtr GetPassport() const + TWeakObjectPtr GetPassport() const { return MakeWeakObjectPtr(Passport); } @@ -56,7 +56,7 @@ class IMMUTABLE_API UImmutableSubsystem : public UGameInstanceSubsystem class UImtblBlui* ImtblBlui = nullptr; UPROPERTY() - class UImmutablePassport* Passport = nullptr; + UImmutablePassport* Passport = nullptr; bool bHasSetupGameBridge = false; bool bIsReady = false;