1- // SPDX-License-Identifier: Apache-2.0
2- pragma solidity ^ 0.8.11 ;
1+ // // SPDX-License-Identifier: Apache-2.0
2+ // pragma solidity ^0.8.11;
33
4- import "../feature/interface/ITokenBundle.sol " ;
4+ // import "../feature/interface/ITokenBundle.sol";
55
6- /**
7- * The thirdweb `Pack` contract is a lootbox mechanism. An account can bundle up arbitrary ERC20, ERC721 and ERC1155 tokens into
8- * a set of packs. A pack can then be opened in return for a selection of the tokens in the pack. The selection of tokens distributed
9- * on opening a pack depends on the relative supply of all tokens in the packs.
10- */
6+ // / **
7+ // * The thirdweb `Pack` contract is a lootbox mechanism. An account can bundle up arbitrary ERC20, ERC721 and ERC1155 tokens into
8+ // * a set of packs. A pack can then be opened in return for a selection of the tokens in the pack. The selection of tokens distributed
9+ // * on opening a pack depends on the relative supply of all tokens in the packs.
10+ // */
1111
12- interface ITempPack is ITokenBundle {
12+ // interface ITempPack is ITokenBundle {
1313
14- /// @notice The types of tokens that can be added to packs.
15- // enum TokenType { ERC20, ERC721, ERC1155 }
14+ // /// @notice The types of tokens that can be added to packs.
15+ // // enum TokenType { ERC20, ERC721, ERC1155 }
1616
17- /**
18- * @notice A unit of content i.e. a token in a pack.
19- *
20- * @param assetContract The contract address of the token.
21- * @param tokenType The type of the token -- ERC20 / ERC721 / ERC1155
22- * @param tokenId The tokenId of the the token, if applicable.
23- * @param totalAmountPacked The total amount of this token packed in the pack.
24- * @param amountPerUnit The amount of this token to distribute as a unit,
25- * on opening a pack.
26- */
27- // struct PackContent {
28- // address assetContract;
29- // TokenType tokenType;
30- // uint256 tokenId;
31- // uint256 totalAmountPacked;
32- // uint256 amountPerUnit;
33- // }
17+ // /**
18+ // * @notice A unit of content i.e. a token in a pack.
19+ // *
20+ // * @param assetContract The contract address of the token.
21+ // * @param tokenType The type of the token -- ERC20 / ERC721 / ERC1155
22+ // * @param tokenId The tokenId of the the token, if applicable.
23+ // * @param totalAmountPacked The total amount of this token packed in the pack.
24+ // * @param amountPerUnit The amount of this token to distribute as a unit,
25+ // * on opening a pack.
26+ // */
27+ // // struct PackContent {
28+ // // address assetContract;
29+ // // TokenType tokenType;
30+ // // uint256 tokenId;
31+ // // uint256 totalAmountPacked;
32+ // // uint256 amountPerUnit;
33+ // // }
3434
35- /**
36- * @notice All info relevant to packs.
37- *
38- * @param contents The reward units packed in the packs.
39- * @param openStartTimestamp The timestamp after which packs can be opened.
40- * @param amountDistributedPerOpen The number of reward units distributed per open.
41- * @param packUri The metadata URI for packs.
42- */
43- // struct PackInfo {
44- // PackContent[] contents;
45- // uint128 openStartTimestamp;
46- // uint128 amountDistributedPerOpen;
47- // string uri;
48- // }
35+ // /**
36+ // * @notice All info relevant to packs.
37+ // *
38+ // * @param contents The reward units packed in the packs.
39+ // * @param openStartTimestamp The timestamp after which packs can be opened.
40+ // * @param amountDistributedPerOpen The number of reward units distributed per open.
41+ // * @param packUri The metadata URI for packs.
42+ // */
43+ // // struct PackInfo {
44+ // // PackContent[] contents;
45+ // // uint128 openStartTimestamp;
46+ // // uint128 amountDistributedPerOpen;
47+ // // string uri;
48+ // // }
4949
50- //mychange
51- //modified structs from IPack
52- struct PackContent {
53- Token token;
54- uint256 amountPerUnit;
55- }
50+ // //mychange
51+ // //modified structs from IPack
52+ // struct PackContent {
53+ // Token token;
54+ // uint256 amountPerUnit;
55+ // }
5656
57- struct PackInfo {
58- // BundleInfo bundle;
59- uint128 openStartTimestamp;
60- uint128 amountDistributedPerOpen;
61- }
57+ // struct PackInfo {
58+ // // BundleInfo bundle;
59+ // uint128 openStartTimestamp;
60+ // uint128 amountDistributedPerOpen;
61+ // }
6262
63- /// @notice Emitted when a set of packs is created.
64- event PackCreated (uint256 indexed packId , address indexed packCreator , address recipient , PackInfo packInfo , uint256 totalPacksCreated );
63+ // /// @notice Emitted when a set of packs is created.
64+ // event PackCreated(uint256 indexed packId, address indexed packCreator, address recipient, PackInfo packInfo, uint256 totalPacksCreated);
6565
66- /// @notice Emitted when a pack is opened.
67- event PackOpened (uint256 indexed packId , address indexed opener , uint256 numOfPacksOpened , PackContent[] rewardUnitsDistributed );
66+ // /// @notice Emitted when a pack is opened.
67+ // event PackOpened(uint256 indexed packId, address indexed opener, uint256 numOfPacksOpened, PackContent[] rewardUnitsDistributed);
6868
69- /// @dev Emitted when the owner is updated.
70- event OwnerUpdated (address prevOwner , address newOwner );
69+ // /// @dev Emitted when the owner is updated.
70+ // event OwnerUpdated(address prevOwner, address newOwner);
7171
72- /**
73- * @notice Creates a pack with the stated contents.
74- *
75- * @param contents The reward units to pack in the packs.
76- * @param packUri The (metadata) URI assigned to the packs created.
77- * @param openStartTimestamp The timestamp after which packs can be opened.
78- * @param amountDistributedPerOpen The number of reward units distributed per open.
79- * @param recipient The recipient of the packs created.
80- *
81- * @return packId The unique identifer of the created set of packs.
82- * @return packTotalSupply The total number of packs created.
83- */
84- function createPack (
85- PackContent[] calldata contents ,
86- string calldata packUri ,
87- uint128 openStartTimestamp ,
88- uint128 amountDistributedPerOpen ,
89- address recipient
90- ) external returns (uint256 packId , uint256 packTotalSupply );
72+ // /**
73+ // * @notice Creates a pack with the stated contents.
74+ // *
75+ // * @param contents The reward units to pack in the packs.
76+ // * @param packUri The (metadata) URI assigned to the packs created.
77+ // * @param openStartTimestamp The timestamp after which packs can be opened.
78+ // * @param amountDistributedPerOpen The number of reward units distributed per open.
79+ // * @param recipient The recipient of the packs created.
80+ // *
81+ // * @return packId The unique identifer of the created set of packs.
82+ // * @return packTotalSupply The total number of packs created.
83+ // */
84+ // function createPack(
85+ // PackContent[] calldata contents,
86+ // string calldata packUri,
87+ // uint128 openStartTimestamp,
88+ // uint128 amountDistributedPerOpen,
89+ // address recipient
90+ // ) external returns (uint256 packId, uint256 packTotalSupply);
9191
92- /**
93- * @notice Lets a pack owner open a pack and receive the pack's reward unit.
94- *
95- * @param packId The identifier of the pack to open.
96- * @param amountToOpen The number of packs to open at once.
97- */
98- function openPack (uint256 packId , uint256 amountToOpen ) external ;
99- }
92+ // /**
93+ // * @notice Lets a pack owner open a pack and receive the pack's reward unit.
94+ // *
95+ // * @param packId The identifier of the pack to open.
96+ // * @param amountToOpen The number of packs to open at once.
97+ // */
98+ // function openPack(uint256 packId, uint256 amountToOpen) external;
99+ // }
0 commit comments