Skip to content

Commit

Permalink
preflight for chest updates
Browse files Browse the repository at this point in the history
  • Loading branch information
lllwvlvwlll committed May 17, 2023
1 parent 0150ea1 commit 02e0ccc
Show file tree
Hide file tree
Showing 12 changed files with 58 additions and 21 deletions.
5 changes: 3 additions & 2 deletions sdk/dist/Chest.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,12 @@ export declare class Chest {
* Create one of these pass throughs for each method you expose in your smart contract. The goal of this entire class is to
* simplify the network configuration steps which can be complicated.
*/
createChest(name: string, type: number, eligibilityCases: [EligibilityCase], signer: wallet.Account): Promise<number | string>;
createChest(name: string, type: number, eligibilityCases: EligibilityCase[], signer: wallet.Account): Promise<number | string>;
isEligible(chestId: number, nftScriptHash: string, tokenId: string, signer?: wallet.Account): Promise<boolean>;
lootChest(chestId: number, nftScriptHash: string, tokenId: string, signer: wallet.Account): Promise<number | string>;
lootChestVerified(chestId: number, nftScriptHash: string, tokenId: string, signer: wallet.Account): Promise<any>;
lootChestAsOwner(chestId: number, signer: wallet.Account): Promise<number | string>;
getChestJSON(chestId: number, signer?: wallet.Account): Promise<number | string>;
totalChests(name: string, type: number, signer?: wallet.Account): Promise<number | string>;
totalChests(signer?: wallet.Account): Promise<number | string>;
loadChestFungible(tokenScriptHash: string, chestId: number, transferAmount: number, amountPerReservoirItem: number, signer: wallet.Account): Promise<any>;
}
13 changes: 12 additions & 1 deletion sdk/dist/Chest.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion sdk/dist/Chest.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion sdk/dist/api/chest.d.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { wallet } from "@cityofzion/neon-core";
import { EligibilityCase } from "../interface";
export declare class ChestAPI {
static createChest(node: string, networkMagic: number, contractHash: string, name: string, chestType: number, eligibilityCases: [EligibilityCase], signer: wallet.Account): Promise<number>;
static createChest(node: string, networkMagic: number, contractHash: string, name: string, chestType: number, eligibilityCases: EligibilityCase[], signer: wallet.Account): Promise<number>;
static isEligible(node: string, networkMagic: number, contractHash: string, chestId: number, nftSriptHash: string, tokenId: string, signer?: wallet.Account): Promise<boolean>;
static lootChest(node: string, networkMagic: number, contractHash: string, chestId: number, nftScriptHash: string, tokenId: string, signer: wallet.Account): Promise<any>;
static lootChestAsOwner(node: string, networkMagic: number, contractHash: string, chestId: number, signer: wallet.Account): Promise<any>;
Expand Down
5 changes: 3 additions & 2 deletions sdk/dist/api/chest.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion sdk/dist/api/chest.js.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion sdk/dist/interface/interface.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,5 +122,5 @@ export interface EligibilityAttribute {
}
export interface EligibilityCase {
scriptHash: string;
attributes: [EligibilityAttribute];
attributes: EligibilityAttribute[];
}
4 changes: 2 additions & 2 deletions sdk/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 02e0ccc

Please sign in to comment.