Skip to content

Commit 1b50717

Browse files
authored
Support v7 Account Abstraction (#35)
Introduces an EntryPoint parameter to the smart wallet creation flow across C++, Blueprint, and K2Node interfaces. Updates the Thirdweb native bindings, async task, handle, and node logic to support specifying an entry point contract when creating a smart wallet. Closes BLD-12 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added support for specifying an "EntryPoint" when creating a smart wallet, available as an advanced option in relevant wallet creation interfaces. * **Bug Fixes** * None. * **Other Updates** * Updated underlying binary libraries for all supported platforms to newer versions. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
1 parent d9c68c5 commit 1b50717

File tree

14 files changed

+51
-27
lines changed

14 files changed

+51
-27
lines changed
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
version https://git-lfs.github.com/spec/v1
2-
oid sha256:e060a9a85ddbcf516ff145274a1078d5e2831b38da86f3f06bcb79c0c17fa5f5
3-
size 90101708
2+
oid sha256:b4a86ab50091595341ad09c1b7444e301b841cc563bdd49c099e8b9f0c5298ee
3+
size 90295496
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
version https://git-lfs.github.com/spec/v1
2-
oid sha256:08b0e2326d039b37bf43a974d71938637cf9046c9727db67e60abf34702e2655
3-
size 60908448
2+
oid sha256:24c8435e0800a406aa2b98844fb3d5e965b818eadebd04175eceb92d4b7d5848
3+
size 61038216
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
version https://git-lfs.github.com/spec/v1
2-
oid sha256:08b0e2326d039b37bf43a974d71938637cf9046c9727db67e60abf34702e2655
3-
size 60908448
2+
oid sha256:24c8435e0800a406aa2b98844fb3d5e965b818eadebd04175eceb92d4b7d5848
3+
size 61038216
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
version https://git-lfs.github.com/spec/v1
2-
oid sha256:7b07c08e98ebee619bbe748db696d183758bebad4ccb05fbde9eb7bda9f787d4
3-
size 93167880
2+
oid sha256:dab9d37bb5f57f9d87ffd33f77cfdd48ae1d1ad1111800e9bbbeb941e8046df8
3+
size 93401358
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
version https://git-lfs.github.com/spec/v1
2-
oid sha256:0aaf37728278a2e7585294be6d39d38ab5b69ba04f6de158420122d4bd640a48
3-
size 92229694
2+
oid sha256:3342709533c62476386dff58ffe69078a4de667b09a4ac21f730b13cced26bfa
3+
size 92446652
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
version https://git-lfs.github.com/spec/v1
2-
oid sha256:580c5df5378c664e65a79b0233424a326672e0dc5b7d019d5ff478ed789f94f3
3-
size 122069736
2+
oid sha256:ea2625e4ecb1b50ac269caf3322cdf27d99db528cf854c0915af89af1ab7e1be
3+
size 122366264
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
version https://git-lfs.github.com/spec/v1
2-
oid sha256:5fc1a193b2de0035535b7ad396c4bad63fc63f734334d731571512b8a613b812
3-
size 95165930
2+
oid sha256:f18455208814da13616c679cd9dac43e169f13fe4f3d86f4f4d5d78d25948041
3+
size 95517218

Source/Thirdweb/Private/AsyncTasks/Wallets/InApp/Create/AsyncTaskThirdwebCreateSmartWallet.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ void UAsyncTaskThirdwebCreateSmartWallet::Activate()
1414
bGasless,
1515
Factory,
1616
AccountOverride,
17+
EntryPoint,
1718
BIND_UOBJECT_DELEGATE(FSmartWalletHandle::FCreateSmartWalletDelegate, HandleResponse),
1819
BIND_UOBJECT_DELEGATE(FStringDelegate, HandleFailed)
1920
);

Source/Thirdweb/Private/Wallets/ThirdwebSmartWalletHandle.cpp

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ void FSmartWalletHandle::Create(const FInAppWalletHandle& InInAppWallet,
4040
const bool bGasless,
4141
const FString& Factory,
4242
const FString& AccountOverride,
43+
const FString& EntryPoint,
4344
const FCreateSmartWalletDelegate& SuccessDelegate,
4445
const FStringDelegate& ErrorDelegate)
4546
{
@@ -54,7 +55,7 @@ void FSmartWalletHandle::Create(const FInAppWalletHandle& InInAppWallet,
5455
return;
5556
}
5657

57-
UE::Tasks::Launch(UE_SOURCE_LOCATION, [InInAppWallet, ChainID, bGasless, Factory, AccountOverride, SuccessDelegate, ErrorDelegate]
58+
UE::Tasks::Launch(UE_SOURCE_LOCATION, [InInAppWallet, ChainID, bGasless, Factory, AccountOverride, EntryPoint, SuccessDelegate, ErrorDelegate]
5859
{
5960
if (FString Error; Thirdweb::create_smart_wallet(
6061
TO_RUST_STRING(UThirdwebRuntimeSettings::GetClientId()),
@@ -64,7 +65,8 @@ void FSmartWalletHandle::Create(const FInAppWalletHandle& InInAppWallet,
6465
TO_RUST_STRING(FString::Printf(TEXT("%lld"), ChainID)),
6566
bGasless,
6667
TO_RUST_STRING(Factory),
67-
TO_RUST_STRING(AccountOverride)
68+
TO_RUST_STRING(AccountOverride),
69+
TO_RUST_STRING(EntryPoint)
6870
).AssignResult(Error))
6971
{
7072
const FSmartWalletHandle SmartWallet = FSmartWalletHandle(InInAppWallet, Error, Factory);

Source/Thirdweb/Public/AsyncTasks/Wallets/InApp/Create/AsyncTaskThirdwebCreateSmartWallet.h

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,20 +16,24 @@ class THIRDWEB_API UAsyncTaskThirdwebCreateSmartWallet : public UAsyncTaskThirdw
1616
public:
1717
virtual void Activate() override;
1818

19-
UFUNCTION(BlueprintCallable, meta=(BlueprintInternalUseOnly="true", WorldContext="WorldContextObject", AdvancedDisplay="Factory,AccountOverride"), Category="Thirdweb|Wallets|Smart")
19+
UFUNCTION(BlueprintCallable,
20+
meta=(BlueprintInternalUseOnly="true", WorldContext="WorldContextObject", AdvancedDisplay="Factory,AccountOverride,EntryPoint"),
21+
Category="Thirdweb|Wallets|Smart")
2022
static UAsyncTaskThirdwebCreateSmartWallet* CreateSmartWallet(UObject* WorldContextObject,
2123
const FInAppWalletHandle& InAppWallet,
2224
const int64 ChainID,
2325
const bool bGasless = true,
2426
const FString& Factory = "",
25-
const FString& AccountOverride = "")
27+
const FString& AccountOverride = "",
28+
const FString& EntryPoint = "")
2629
{
2730
NEW_TASK
2831
Task->InAppWallet = InAppWallet;
2932
Task->ChainID = ChainID;
3033
Task->bGasless = bGasless;
3134
Task->Factory = Factory;
3235
Task->AccountOverride = AccountOverride;
36+
Task->EntryPoint = EntryPoint;
3337
RR_TASK
3438
};
3539

@@ -57,6 +61,9 @@ class THIRDWEB_API UAsyncTaskThirdwebCreateSmartWallet : public UAsyncTaskThirdw
5761
UPROPERTY(Transient)
5862
FString AccountOverride;
5963

64+
UPROPERTY(Transient)
65+
FString EntryPoint;
66+
6067
private:
6168
UFUNCTION()
6269
void HandleResponse(const FSmartWalletHandle& Wallet);

0 commit comments

Comments
 (0)