Skip to content

Commit 2bff4b9

Browse files
committed
fix: moved template method implementation to header file
1 parent 0ad7748 commit 2bff4b9

File tree

3 files changed

+7
-15
lines changed

3 files changed

+7
-15
lines changed

Source/Immutable/Private/Immutable/ImmutableSubsystem.cpp

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -56,16 +56,6 @@ void UImmutableSubsystem::Deinitialize()
5656
Super::Deinitialize();
5757
}
5858

59-
template <class UserClass>
60-
#if (ENGINE_MAJOR_VERSION >= 5 && ENGINE_MINOR_VERSION >= 1)
61-
void UImmutableSubsystem::WhenReady(UserClass* Object, typename FImmutableSubsystemReadyDelegate::FDelegate::TMethodPtr<UserClass> Func)
62-
#else
63-
void UImmutableSubsystem::WhenReady(UserClass* Object, typename FImmutableSubsystemReadyDelegate::FDelegate::TUObjectMethodDelegate<UserClass>::FMethodPtr Func)
64-
#endif
65-
{
66-
OnReady.AddUObject(Object, Func);
67-
}
68-
6959
void UImmutableSubsystem::OnBridgeReady()
7060
{
7161
// When the bridge is ready our subsystem is ready to be used by game code.

Source/Immutable/Public/Immutable/ImmutableRequests.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#pragma once
22

3+
#include "ImmutableDataTypes.h"
34

45
#include "ImmutableRequests.generated.h"
56

@@ -48,7 +49,7 @@ struct IMMUTABLE_API FImxBatchNftTransferRequest
4849
GENERATED_BODY()
4950

5051
UPROPERTY()
51-
TArray<FNftTransferDetails> nftTransferDetails;
52+
TArray<struct FNftTransferDetails> nftTransferDetails;
5253

5354
FString ToJsonString() const;
5455
};

Source/Immutable/Public/Immutable/ImmutableSubsystem.h

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,16 +31,17 @@ class IMMUTABLE_API UImmutableSubsystem : public UGameInstanceSubsystem
3131

3232
bool IsReady() const { return bIsReady; }
3333

34-
// FOnGameViewportTick& OnGameViewportTick() { return GameViewportTickEvent; }
35-
3634
// Execute a delegate when the subsystem is ready (i.e.: when the browser is
3735
// running and the Immutable SDK game bridge has loaded).
3836
template <class UserClass>
3937
#if (ENGINE_MAJOR_VERSION >= 5 && ENGINE_MINOR_VERSION >= 1)
40-
void WhenReady(UserClass* Object, typename FImmutableSubsystemReadyDelegate::FDelegate::TMethodPtr<UserClass> Func);
38+
void WhenReady(UserClass* Object, typename FImmutableSubsystemReadyDelegate::FDelegate::TMethodPtr<UserClass> Func)
4139
#else
42-
void WhenReady(UserClass* Object, typename FImmutableSubsystemReadyDelegate::FDelegate::TUObjectMethodDelegate<UserClass>::FMethodPtr Func);
40+
void WhenReady(UserClass* Object, typename FImmutableSubsystemReadyDelegate::FDelegate::TUObjectMethodDelegate<UserClass>::FMethodPtr Func)
4341
#endif
42+
{
43+
OnReady.AddUObject(Object, Func);
44+
}
4445

4546
private:
4647
UPROPERTY()

0 commit comments

Comments
 (0)