@artblocks/contracts 1.0.4 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +75 -7
- package/artifacts/contracts/AdminACLV0.sol/AdminACLV0.json +2 -2
- package/artifacts/contracts/AdminACLV1.sol/AdminACLV1.json +2 -2
- package/artifacts/contracts/DependencyRegistryV0.sol/DependencyRegistryV0.json +336 -131
- package/artifacts/contracts/archive/GenArt721CoreV3.sol/GenArt721CoreV3.json +2047 -0
- package/artifacts/contracts/archive/GenArt721CoreV3_Explorations.sol/GenArt721CoreV3_Explorations.json +2021 -0
- package/artifacts/contracts/{minter-suite → archive/minter-suite}/Minters/MinterBase_v0_1_1.sol/MinterBase.json +1 -1
- package/artifacts/contracts/archive/minter-suite/Minters/MinterDAExp/MinterDAExpV2.sol/MinterDAExpV2.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterDAExp/MinterDAExpV3.sol/MinterDAExpV3.json +2 -2
- package/artifacts/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterDAExp}/MinterDAExpV4.sol/MinterDAExpV4.json +3 -3
- package/artifacts/contracts/archive/minter-suite/Minters/MinterDAExpSettlement/MinterDAExpSettlementV0.sol/MinterDAExpSettlementV0.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterDAExpSettlement/MinterDAExpSettlementV1.sol/MinterDAExpSettlementV1.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterDAExpSettlement/MinterDAExpSettlementV2.sol/MinterDAExpSettlementV2.json +1109 -0
- package/artifacts/contracts/archive/minter-suite/Minters/MinterDALin/MinterDALinV2.sol/MinterDALinV2.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterDALin/MinterDALinV3.sol/MinterDALinV3.json +2 -2
- package/artifacts/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterDALin}/MinterDALinV4.sol/MinterDALinV4.json +3 -3
- package/artifacts/contracts/archive/minter-suite/Minters/MinterHolder/MinterHolderV1.sol/MinterHolderV1.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterHolder/MinterHolderV2.sol/MinterHolderV2.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterHolder/MinterHolderV3.sol/MinterHolderV3.json +2 -2
- package/artifacts/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterHolder}/MinterHolderV4.sol/MinterHolderV4.json +3 -3
- package/artifacts/contracts/archive/minter-suite/Minters/MinterMerkle/MinterMerkleV1.sol/MinterMerkleV1.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterMerkle/MinterMerkleV2.sol/MinterMerkleV2.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterMerkle/MinterMerkleV3.sol/MinterMerkleV3.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterMerkle/MinterMerkleV4.sol/MinterMerkleV4.json +2 -2
- package/artifacts/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterMerkle}/MinterMerkleV5.sol/MinterMerkleV5.json +3 -3
- package/artifacts/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterPolyptych}/MinterPolyptychV0.sol/IGenArt721CoreContractV3WithRandomizer.json +31 -63
- package/artifacts/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterPolyptych}/MinterPolyptychV0.sol/MinterPolyptychV0.json +3 -3
- package/artifacts/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterSEA}/MinterSEAV0.sol/MinterSEAV0.json +3 -3
- package/artifacts/contracts/archive/minter-suite/Minters/MinterSetPrice/MinterSetPriceV2.sol/MinterSetPriceV2.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterSetPrice/MinterSetPriceV3.sol/MinterSetPriceV3.json +2 -2
- package/artifacts/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterSetPrice}/MinterSetPriceV4.sol/MinterSetPriceV4.json +3 -3
- package/artifacts/contracts/archive/minter-suite/Minters/MinterSetPriceERC20/MinterSetPriceERC20V0.sol/MinterSetPriceERC20V0.json +65 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterSetPriceERC20/MinterSetPriceERC20V1.sol/MinterSetPriceERC20V1.json +65 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterSetPriceERC20/MinterSetPriceERC20V2.sol/MinterSetPriceERC20V2.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterSetPriceERC20/MinterSetPriceERC20V3.sol/MinterSetPriceERC20V3.json +2 -2
- package/artifacts/contracts/archive/minter-suite/Minters/MinterSetPriceERC20/MinterSetPriceERC20V4.sol/MinterSetPriceERC20V4.json +807 -0
- package/artifacts/contracts/engine/V2/GenArt721MinterBurner_PBAB.sol/GenArt721MinterBurner_PBAB.json +65 -2
- package/artifacts/contracts/engine/V2/GenArt721Minter_PBAB.sol/GenArt721Minter_PBAB.json +65 -2
- package/artifacts/contracts/engine/V3/EngineFactoryV0.sol/EngineFactoryV0.json +606 -0
- package/artifacts/contracts/engine/V3/GenArt721CoreV3_Engine.sol/GenArt721CoreV3_Engine.json +565 -209
- package/artifacts/contracts/engine/V3/GenArt721CoreV3_Engine_Flex.sol/GenArt721CoreV3_Engine_Flex.json +785 -227
- package/artifacts/contracts/engine/V3/forks/GenArt721CoreV3_Engine_Flex_PROOF.sol/GenArt721CoreV3_Engine_Flex_PROOF.json +40 -15
- package/artifacts/contracts/engine/V3/forks/PROHIBITION/AdminACLV0_PROHIBITION.sol/AdminACLV0_PROHIBITION.json +2 -2
- package/artifacts/contracts/engine/V3/forks/PROHIBITION/GenArt721CoreV3_Engine_Flex_PROHIBITION.sol/GenArt721CoreV3_Engine_Flex_PROHIBITION.json +40 -15
- package/artifacts/contracts/engine/V3/forks/PROHIBITION/interfaces/IGenArt721CoreContractV3_Engine_Flex_PROHIBITION.sol/IGenArt721CoreContractV3_Engine_Flex_PROHIBITION.json +36 -68
- package/artifacts/contracts/engine-registry/CoreRegistryV1.sol/CoreRegistryV1.json +12 -12
- package/artifacts/contracts/interfaces/v0.8.x/IAdminACLV0_Extended.sol/IAdminACLV0_Extended.json +140 -0
- package/artifacts/contracts/interfaces/v0.8.x/IBytecodeStorageReaderV2.sol/IBytecodeStorageReaderV2.json +130 -0
- package/artifacts/contracts/interfaces/v0.8.x/ICoreRegistryV1.sol/ICoreRegistryV1.json +6 -6
- package/artifacts/contracts/interfaces/v0.8.x/IDependencyRegistryV0.sol/IDependencyRegistryV0.json +71 -39
- package/artifacts/contracts/interfaces/v0.8.x/IEngineFactoryV0.sol/IEngineFactoryV0.json +283 -0
- package/artifacts/contracts/interfaces/v0.8.x/IFilteredMinterDAExpSettlementV0.sol/IFilteredMinterDAExpSettlementV0.json +12 -12
- package/artifacts/contracts/interfaces/v0.8.x/IFilteredMinterDAExpSettlementV1.sol/IFilteredMinterDAExpSettlementV1.json +12 -12
- package/artifacts/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3.sol/IGenArt721CoreContractV3.json +30 -62
- package/artifacts/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_Base.sol/IGenArt721CoreContractV3_Base.json +30 -62
- package/artifacts/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_Engine.sol/IGenArt721CoreContractV3_Engine.json +170 -104
- package/artifacts/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_Engine_Flex.sol/IGenArt721CoreContractV3_Engine_Flex.json +170 -104
- package/artifacts/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_Engine_Flex_PreV3p2.sol/IGenArt721CoreContractV3_Engine_Flex_PreV3p2.json +1028 -0
- package/artifacts/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_Engine_PreV3p2.sol/IGenArt721CoreContractV3_Engine_PreV3p2.json +741 -0
- package/artifacts/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_ProjectFinance.sol/IGenArt721CoreContractV3_ProjectFinance.json +87 -0
- package/artifacts/contracts/interfaces/v0.8.x/IGenArt721Minter_PBAB.sol/IGenArt721Minter_PBAB.json +279 -0
- package/artifacts/contracts/interfaces/v0.8.x/IMinterFilterV1.sol/IMinterFilterV1.json +22 -22
- package/artifacts/contracts/interfaces/v0.8.x/IPseudorandomAtomic.sol/IPseudorandomAtomic.json +1 -1
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterDAExpSettlementV0.sol/ISharedMinterDAExpSettlementV0.json +26 -101
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterDAExpV0.sol/ISharedMinterDAExpV0.json +1 -57
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterDALinV0.sol/ISharedMinterDALinV0.json +1 -57
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterDAV0.sol/ISharedMinterDAV0.json +2 -21
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterHolderERC20V0.sol/ISharedMinterHolderERC20V0.json +158 -0
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterHolderV0.sol/ISharedMinterHolderV0.json +15 -90
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterMerkleV0.sol/ISharedMinterMerkleV0.json +10 -36
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterRAMV0.sol/ISharedMinterRAMV0.json +62 -0
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterRequired.sol/ISharedMinterRequired.json +37 -0
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterSEAV0.sol/ISharedMinterSEAV0.json +4 -236
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterSimplePurchaseV0.sol/ISharedMinterSimplePurchaseV0.json +5 -5
- package/artifacts/contracts/interfaces/v0.8.x/ISharedMinterV0.sol/ISharedMinterV0.json +7 -423
- package/artifacts/contracts/interfaces/v0.8.x/ISharedRandomizerV0.sol/ISharedRandomizerV0.json +17 -17
- package/artifacts/contracts/interfaces/v0.8.x/ISplitAtomicFactoryV0.sol/ISplitAtomicFactoryV0.json +170 -0
- package/artifacts/contracts/interfaces/v0.8.x/ISplitAtomicV0.sol/ISplitAtomicV0.json +126 -0
- package/artifacts/contracts/interfaces/v0.8.x/ISplitProviderV0.sol/ISplitProviderV0.json +98 -0
- package/artifacts/contracts/interfaces/v0.8.x/integration-refs/splits-0x-v2/ISplitFactoryV2.sol/ISplitFactoryV2.json +123 -0
- package/artifacts/contracts/libs/integration-refs/delegation-registry/DelegationRegistry.sol/DelegationRegistry.json +2 -2
- package/artifacts/contracts/libs/integration-refs/gnosis-safe/GnosisSafeMock.sol/GnosisSafeMock.json +2 -2
- package/artifacts/contracts/libs/integration-refs/gnosis-safe/GnosisSafeProxyFactoryMock.sol/GnosisSafeProxyFactoryMock.json +2 -2
- package/artifacts/contracts/libs/integration-refs/gnosis-safe/MultiSendMock.sol/MultiSendMock.json +2 -2
- package/artifacts/contracts/libs/integration-refs/weth9/weth9.sol/WETH9_.json +2 -2
- package/artifacts/contracts/libs/v0.8.x/ABHelpers.sol/ABHelpers.json +2 -2
- package/artifacts/contracts/libs/v0.8.x/AuthLib.sol/AuthLib.json +2 -2
- package/artifacts/contracts/libs/v0.8.x/BitMap.sol/BitMaps256.json +10 -0
- package/artifacts/contracts/libs/v0.8.x/BytecodeStorageV0.sol/BytecodeStorage.json +2 -2
- package/artifacts/contracts/libs/v0.8.x/BytecodeStorageV1.sol/BytecodeStorageReader.json +2 -2
- package/artifacts/contracts/libs/v0.8.x/BytecodeStorageV1.sol/BytecodeStorageWriter.json +2 -2
- package/artifacts/contracts/libs/v0.8.x/BytecodeStorageV2.sol/BytecodeStorageReader.json +214 -0
- package/artifacts/contracts/libs/v0.8.x/BytecodeStorageV2.sol/BytecodeStorageWriter.json +10 -0
- package/artifacts/contracts/libs/v0.8.x/Bytes32Strings.sol/Bytes32Strings.json +2 -2
- package/artifacts/contracts/libs/v0.8.x/DependencyRegistryStorageLib.sol/DependencyRegistryStorageLib.json +10 -0
- package/artifacts/contracts/libs/v0.8.x/ERC721_PackedHashSeed.sol/ERC721_PackedHashSeed.json +2 -2
- package/artifacts/contracts/libs/v0.8.x/ERC721_PackedHashSeedV1.sol/ERC721_PackedHashSeedV1.json +444 -0
- package/artifacts/contracts/libs/v0.8.x/PackedBools.sol/PackedBools.json +10 -0
- package/artifacts/contracts/libs/v0.8.x/SSTORE2.sol/SSTORE2.json +2 -2
- package/artifacts/contracts/libs/v0.8.x/V3FlexLib.sol/V3FlexLib.json +208 -0
- package/artifacts/contracts/libs/v0.8.x/minter-libs/DAExpLib.sol/DAExpLib.json +60 -3
- package/artifacts/contracts/libs/v0.8.x/minter-libs/DALib.sol/DALib.json +30 -0
- package/artifacts/contracts/libs/v0.8.x/minter-libs/DALinLib.sol/DALinLib.json +60 -3
- package/artifacts/contracts/libs/v0.8.x/minter-libs/GenericMinterEventsLib.sol/GenericMinterEventsLib.json +346 -0
- package/artifacts/contracts/libs/v0.8.x/minter-libs/MaxInvocationsLib.sol/MaxInvocationsLib.json +29 -3
- package/artifacts/contracts/libs/v0.8.x/minter-libs/MerkleLib.sol/MerkleLib.json +30 -3
- package/artifacts/contracts/libs/v0.8.x/minter-libs/PolyptychLib.sol/PolyptychLib.json +2 -2
- package/artifacts/contracts/libs/v0.8.x/minter-libs/RAMLib.sol/RAMLib.json +398 -0
- package/artifacts/contracts/libs/v0.8.x/minter-libs/SEALib.sol/SEALib.json +254 -3
- package/artifacts/contracts/libs/v0.8.x/minter-libs/SetPriceLib.sol/SetPriceLib.json +48 -3
- package/artifacts/contracts/libs/v0.8.x/minter-libs/SettlementExpLib.sol/SettlementExpLib.json +41 -3
- package/artifacts/contracts/libs/v0.8.x/minter-libs/SplitFundsLib.sol/SplitFundsLib.json +35 -3
- package/artifacts/contracts/libs/v0.8.x/minter-libs/TokenHolderLib.sol/TokenHolderLib.json +79 -3
- package/artifacts/contracts/minter-suite/MinterFilter/MinterFilterV1.sol/MinterFilterV1.json +2 -2
- package/artifacts/contracts/minter-suite/MinterFilter/MinterFilterV2.sol/MinterFilterV2.json +41 -41
- package/artifacts/contracts/minter-suite/Minters/MinterDAExpHolderV5.sol/MinterDAExpHolderV5.json +66 -632
- package/artifacts/contracts/minter-suite/Minters/MinterDAExpSettlementV3.sol/MinterDAExpSettlementV3.json +67 -594
- package/artifacts/contracts/minter-suite/Minters/MinterDAExpV5.sol/MinterDAExpV5.json +33 -524
- package/artifacts/contracts/minter-suite/Minters/MinterDALinHolderV5.sol/MinterDALinHolderV5.json +66 -632
- package/artifacts/contracts/minter-suite/Minters/MinterDALinV5.sol/MinterDALinV5.json +33 -524
- package/artifacts/contracts/minter-suite/Minters/MinterRAMV0.sol/MinterRAMV0.json +1374 -0
- package/artifacts/contracts/minter-suite/Minters/MinterSEAV1.sol/MinterSEAV1.json +56 -722
- package/artifacts/contracts/minter-suite/Minters/MinterSetPriceERC20V5.sol/MinterSetPriceERC20V5.json +58 -454
- package/artifacts/contracts/minter-suite/Minters/MinterSetPriceHolderV5.sol/MinterSetPriceHolderV5.json +61 -552
- package/artifacts/contracts/minter-suite/Minters/MinterSetPriceMerkleV5.sol/MinterSetPriceMerkleV5.json +55 -497
- package/artifacts/contracts/minter-suite/Minters/MinterSetPricePolyptychERC20V5.sol/MinterSetPricePolyptychERC20V5.json +110 -571
- package/artifacts/contracts/minter-suite/Minters/MinterSetPricePolyptychV5.sol/MinterSetPricePolyptychV5.json +69 -560
- package/artifacts/contracts/minter-suite/Minters/MinterSetPriceV5.sol/MinterSetPriceV5.json +28 -444
- package/artifacts/contracts/minter-suite/Minters/one-off/MinterSetPriceV5_SingleCore.sol/MinterSetPriceV5_SingleCore.json +417 -0
- package/artifacts/contracts/mock/BytecodeV2LibCallsMock.sol/BytecodeV2LibCallsMock.json +154 -0
- package/artifacts/contracts/mock/BytecodeV2TextCR_DMock.sol/BytecodeV2TextCR_DMock.json +428 -0
- package/artifacts/contracts/mock/DummySharedMinter.sol/DummySharedMinter.json +2 -2
- package/artifacts/contracts/mock/ERC20Mock.sol/ERC20Mock.json +2 -2
- package/artifacts/contracts/mock/ForceSendMock.sol/ForceSendMock.json +24 -0
- package/artifacts/contracts/mock/GenArt721CoreV3_Engine_IncorrectCoreType.sol/GenArt721CoreV3_Engine_IncorrectCoreType.json +4 -9
- package/artifacts/contracts/mock/Mock0xSplitsV2PullFactory.sol/Mock0xSplitsV2PullFactory.json +149 -0
- package/artifacts/contracts/mock/Mock0xSplitsV2Splitter.sol/Mock0xSplitsV2Splitter.json +99 -0
- package/artifacts/contracts/mock/MockAdminACLV0.sol/MockAdminACLV0Events.json +20 -2
- package/artifacts/contracts/mock/MockAdminACLV0_PROHIBITION.sol/MockAdminACLV0Events_PROHIBITION.json +20 -2
- package/artifacts/contracts/mock/OriginRegisterMock.sol/OriginRegisterMock.json +2 -2
- package/artifacts/contracts/mock/RandomizerV2_NoAssignMock.sol/RandomizerV2_NoAssignMock.json +2 -2
- package/artifacts/contracts/mock/ReentrancyGenArt721MinterMock.sol/ReentrancyGenArt721MinterMock.json +100 -0
- package/artifacts/contracts/mock/ReentrancyHolderMock.sol/ReentrancyHolderMock.json +2 -2
- package/artifacts/contracts/mock/ReentrancyHolderMockShared.sol/ReentrancyHolderMockShared.json +136 -0
- package/artifacts/contracts/mock/ReentrancyMerkleMock.sol/ReentrancyMerkleMock.json +2 -2
- package/artifacts/contracts/mock/ReentrancyMerkleMockShared.sol/ReentrancyMerkleMockShared.json +105 -0
- package/artifacts/contracts/mock/ReentrancyMock.sol/ReentrancyMock.json +2 -2
- package/artifacts/contracts/mock/ReentrancyMockShared.sol/ReentrancyMockShared.json +100 -0
- package/artifacts/contracts/mock/ReentrancySEAMock.sol/ReentrancySEAAutoBidderMock.json +2 -2
- package/artifacts/contracts/mock/ReentrancySEAMockShared.sol/ReentrancySEAAutoBidderMockShared.json +69 -0
- package/artifacts/contracts/mock/ReentrancySplitterMocks.sol/ReentrancySplitterDrainETHMock.json +54 -0
- package/artifacts/contracts/mock/ReentrancySplitterMocks.sol/ReentrancySplitterSendETHMock.json +54 -0
- package/artifacts/contracts/randomizer/deprecated/PolyptychRandomizerV0.sol/BasicPolyptychRandomizerV0.json +2 -2
- package/artifacts/contracts/randomizer/deprecated/RandomizerV2.sol/BasicRandomizerV2.json +2 -2
- package/artifacts/contracts/randomizer/primitive/PseudorandomAtomicBasic.sol/PseudorandomAtomic.json +2 -2
- package/artifacts/contracts/randomizer/shared/SharedRandomizerV0.sol/SharedRandomizerV0.json +19 -19
- package/artifacts/contracts/split/SplitAtomicFactoryV0.sol/SplitAtomicFactoryV0.json +203 -0
- package/artifacts/contracts/split/SplitAtomicV0.sol/SplitAtomicV0.json +168 -0
- package/artifacts/contracts/split/split-provider/SplitProviderV0.sol/SplitProviderV0.json +141 -0
- package/contracts/AdminACLV0.sol +6 -2
- package/contracts/AdminACLV1.sol +2 -2
- package/contracts/DependencyRegistryV0.sol +737 -390
- package/contracts/{GenArt721CoreV3.sol → archive/GenArt721CoreV3.sol} +56 -20
- package/contracts/{explorations → archive}/GenArt721CoreV3_Explorations.sol +49 -13
- package/contracts/{minter-suite → archive/minter-suite}/Minters/MinterBase_v0_1_1.sol +4 -4
- package/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterDAExp}/MinterDAExpV4.sol +4 -4
- package/contracts/archive/minter-suite/Minters/MinterDAExpSettlement/MinterDAExpSettlementV0.sol +4 -4
- package/contracts/archive/minter-suite/Minters/MinterDAExpSettlement/MinterDAExpSettlementV1.sol +5 -5
- package/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterDAExpSettlement}/MinterDAExpSettlementV2.sol +9 -62
- package/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterDALin}/MinterDALinV4.sol +4 -4
- package/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterHolder}/MinterHolderV4.sol +5 -5
- package/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterMerkle}/MinterMerkleV5.sol +5 -5
- package/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterPolyptych}/MinterPolyptychV0.sol +7 -7
- package/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterSEA}/MinterSEAV0.sol +13 -13
- package/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterSetPrice}/MinterSetPriceV4.sol +4 -4
- package/contracts/archive/minter-suite/Minters/MinterSetPriceERC20/MinterSetPriceERC20V0.sol +82 -10
- package/contracts/archive/minter-suite/Minters/MinterSetPriceERC20/MinterSetPriceERC20V1.sol +82 -10
- package/contracts/{minter-suite/Minters → archive/minter-suite/Minters/MinterSetPriceERC20}/MinterSetPriceERC20V4.sol +88 -21
- package/contracts/engine/V2/GenArt721MinterBurner_PBAB.sol +81 -22
- package/contracts/engine/V2/GenArt721Minter_PBAB.sol +80 -22
- package/contracts/engine/V3/EngineFactoryV0.sol +419 -0
- package/contracts/engine/V3/GenArt721CoreV3_Engine.sol +893 -493
- package/contracts/engine/V3/GenArt721CoreV3_Engine_Flex.sol +1053 -655
- package/contracts/engine/V3/forks/GenArt721CoreV3_Engine_Flex_PROOF.sol +7 -13
- package/contracts/engine/V3/forks/PROHIBITION/GenArt721CoreV3_Engine_Flex_PROHIBITION.sol +5 -11
- package/contracts/engine/V3/forks/PROHIBITION/interfaces/IGenArt721CoreContractV3_Engine_Flex_PROHIBITION.sol +2 -2
- package/contracts/engine-registry/CoreRegistryV1.sol +58 -65
- package/contracts/interfaces/v0.8.x/IAdminACLV0_Extended.sol +20 -0
- package/contracts/interfaces/v0.8.x/IBytecodeStorageReaderV2.sol +23 -0
- package/contracts/interfaces/v0.8.x/ICoreRegistryV1.sol +6 -8
- package/contracts/interfaces/v0.8.x/IDependencyRegistryV0.sol +48 -43
- package/contracts/interfaces/v0.8.x/IEngineFactoryV0.sol +124 -0
- package/contracts/interfaces/v0.8.x/IFilteredMinterDAExpSettlementV0.sol +1 -3
- package/contracts/interfaces/v0.8.x/IFilteredMinterDAExpSettlementV1.sol +1 -3
- package/contracts/interfaces/v0.8.x/IFilteredMinterDAExpV1.sol +1 -3
- package/contracts/interfaces/v0.8.x/IFilteredMinterDALinV1.sol +1 -3
- package/contracts/interfaces/v0.8.x/IFilteredMinterHolderV2.sol +1 -3
- package/contracts/interfaces/v0.8.x/IFilteredMinterMerkleV2.sol +1 -3
- package/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_Base.sol +115 -11
- package/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_Engine.sol +84 -8
- package/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_Engine_Flex.sol +26 -8
- package/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_Engine_Flex_PreV3p2.sol +141 -0
- package/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_Engine_PreV3p2.sol +78 -0
- package/contracts/interfaces/v0.8.x/IGenArt721CoreContractV3_ProjectFinance.sol +47 -0
- package/contracts/interfaces/v0.8.x/IGenArt721Minter_PBAB.sol +91 -0
- package/contracts/interfaces/v0.8.x/IMinterFilterV1.sol +25 -25
- package/contracts/interfaces/v0.8.x/IPseudorandomAtomic.sol +1 -3
- package/contracts/interfaces/v0.8.x/ISharedMinterDAExpSettlementV0.sol +30 -20
- package/contracts/interfaces/v0.8.x/ISharedMinterDAExpV0.sol +1 -14
- package/contracts/interfaces/v0.8.x/ISharedMinterDALinV0.sol +1 -15
- package/contracts/interfaces/v0.8.x/ISharedMinterDAV0.sol +2 -8
- package/contracts/interfaces/v0.8.x/ISharedMinterHolderERC20V0.sol +47 -0
- package/contracts/interfaces/v0.8.x/ISharedMinterHolderV0.sol +15 -43
- package/contracts/interfaces/v0.8.x/ISharedMinterMerkleV0.sol +10 -20
- package/contracts/interfaces/v0.8.x/ISharedMinterRAMV0.sol +23 -0
- package/contracts/interfaces/v0.8.x/ISharedMinterRequired.sol +20 -0
- package/contracts/interfaces/v0.8.x/ISharedMinterSEAV0.sol +1 -67
- package/contracts/interfaces/v0.8.x/ISharedMinterSimplePurchaseV0.sol +5 -5
- package/contracts/interfaces/v0.8.x/ISharedMinterV0.sol +18 -160
- package/contracts/interfaces/v0.8.x/ISharedRandomizerV0.sol +37 -37
- package/contracts/interfaces/v0.8.x/ISplitAtomicFactoryV0.sol +81 -0
- package/contracts/interfaces/v0.8.x/ISplitAtomicV0.sol +72 -0
- package/contracts/interfaces/v0.8.x/ISplitProviderV0.sol +49 -0
- package/contracts/interfaces/v0.8.x/integration-refs/splits-0x-v2/ISplitFactoryV2.sol +62 -0
- package/contracts/libs/v0.8.x/ABHelpers.sol +31 -17
- package/contracts/libs/v0.8.x/AuthLib.sol +101 -102
- package/contracts/libs/v0.8.x/BitMap.sol +112 -0
- package/contracts/libs/v0.8.x/BytecodeStorageV2.sol +593 -0
- package/contracts/libs/v0.8.x/Bytes32Strings.sol +5 -5
- package/contracts/libs/v0.8.x/DependencyRegistryStorageLib.sol +90 -0
- package/contracts/libs/v0.8.x/ERC721_PackedHashSeedV1.sol +591 -0
- package/contracts/libs/v0.8.x/PackedBools.sol +42 -0
- package/contracts/libs/v0.8.x/V3FlexLib.sol +591 -0
- package/contracts/libs/v0.8.x/minter-libs/DAExpLib.sol +162 -39
- package/contracts/libs/v0.8.x/minter-libs/DALib.sol +26 -0
- package/contracts/libs/v0.8.x/minter-libs/DALinLib.sol +139 -37
- package/contracts/libs/v0.8.x/minter-libs/GenericMinterEventsLib.sol +171 -0
- package/contracts/libs/v0.8.x/minter-libs/MaxInvocationsLib.sol +299 -158
- package/contracts/libs/v0.8.x/minter-libs/MerkleLib.sol +268 -55
- package/contracts/libs/v0.8.x/minter-libs/PolyptychLib.sol +138 -58
- package/contracts/libs/v0.8.x/minter-libs/RAMLib.sol +2927 -0
- package/contracts/libs/v0.8.x/minter-libs/SEALib.sol +796 -123
- package/contracts/libs/v0.8.x/minter-libs/SetPriceLib.sol +131 -13
- package/contracts/libs/v0.8.x/minter-libs/SettlementExpLib.sol +607 -224
- package/contracts/libs/v0.8.x/minter-libs/SplitFundsLib.sol +494 -330
- package/contracts/libs/v0.8.x/minter-libs/TokenHolderLib.sol +217 -78
- package/contracts/minter-suite/MinterFilter/MinterFilterV2.sol +358 -309
- package/contracts/minter-suite/Minters/MinterDAExpHolderV5.sol +391 -491
- package/contracts/minter-suite/Minters/MinterDAExpSettlementV3.sol +396 -632
- package/contracts/minter-suite/Minters/MinterDAExpV5.sol +212 -273
- package/contracts/minter-suite/Minters/MinterDALinHolderV5.sol +393 -488
- package/contracts/minter-suite/Minters/MinterDALinV5.sol +220 -277
- package/contracts/minter-suite/Minters/MinterRAMV0.sol +1205 -0
- package/contracts/minter-suite/Minters/MinterSEAV1.sol +329 -677
- package/contracts/minter-suite/Minters/MinterSetPriceERC20V5.sol +287 -303
- package/contracts/minter-suite/Minters/MinterSetPriceHolderV5.sol +355 -446
- package/contracts/minter-suite/Minters/MinterSetPriceMerkleV5.sol +328 -416
- package/contracts/minter-suite/Minters/MinterSetPricePolyptychERC20V5.sol +552 -622
- package/contracts/minter-suite/Minters/MinterSetPricePolyptychV5.sol +429 -553
- package/contracts/minter-suite/Minters/MinterSetPriceV5.sol +180 -227
- package/contracts/minter-suite/Minters/one-off/MinterSetPriceV5_SingleCore.sol +446 -0
- package/contracts/mock/BytecodeV2LibCallsMock.sol +128 -0
- package/contracts/mock/BytecodeV2TextCR_DMock.sol +316 -0
- package/contracts/mock/ForceSendMock.sol +22 -0
- package/contracts/mock/GenArt721CoreV3_Engine_IncorrectCoreType.sol +3 -10
- package/contracts/mock/Mock0xSplitsV2PullFactory.sol +75 -0
- package/contracts/mock/Mock0xSplitsV2Splitter.sol +47 -0
- package/contracts/mock/MockAdminACLV0.sol +21 -0
- package/contracts/mock/MockAdminACLV0_PROHIBITION.sol +21 -0
- package/contracts/mock/ReentrancyGenArt721MinterMock.sol +47 -0
- package/contracts/mock/ReentrancyHolderMockShared.sol +59 -0
- package/contracts/mock/ReentrancyMerkleMockShared.sol +58 -0
- package/contracts/mock/ReentrancyMockShared.sol +48 -0
- package/contracts/mock/ReentrancySEAMockShared.sol +40 -0
- package/contracts/mock/ReentrancySplitterMocks.sol +67 -0
- package/contracts/randomizer/primitive/PseudorandomAtomicBasic.sol +1 -1
- package/contracts/randomizer/shared/SharedRandomizerV0.sol +79 -71
- package/contracts/split/SplitAtomicFactoryV0.sol +121 -0
- package/contracts/split/SplitAtomicV0.sol +265 -0
- package/contracts/split/split-provider/SplitProviderV0.sol +201 -0
- package/package.json +79 -45
- package/artifacts/contracts/GenArt721CoreV3.sol/GenArt721CoreV3.json +0 -1965
- package/artifacts/contracts/explorations/GenArt721CoreV3_Explorations.sol/GenArt721CoreV3_Explorations.json +0 -1939
- package/artifacts/contracts/minter-suite/Minters/MinterDAExpSettlementV2.sol/MinterDAExpSettlementV2.json +0 -1127
- package/artifacts/contracts/minter-suite/Minters/MinterSetPriceERC20V4.sol/MinterSetPriceERC20V4.json +0 -768
- package/artifacts/contracts/royalty-registry/GenArt721RoyaltyOverride.sol/GenArt721RoyaltyOverride.json +0 -208
- package/artifacts/contracts/royalty-registry/GenArt721RoyaltyOverride_PBAB.sol/GenArt721RoyaltyOverride_PBAB.json +0 -301
- package/contracts/royalty-registry/GenArt721RoyaltyOverride.sol +0 -168
- package/contracts/royalty-registry/GenArt721RoyaltyOverride_PBAB.sol +0 -221
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
// SPDX-License-Identifier: LGPL-3.0-only
|
|
2
2
|
// Created By: Art Blocks Inc.
|
|
3
3
|
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
4
|
+
// @dev fixed to specific solidity version for clarity and for more clear
|
|
5
|
+
// source code verification purposes.
|
|
6
|
+
pragma solidity 0.8.19;
|
|
7
7
|
|
|
8
|
-
import "../../
|
|
9
|
-
import "../../
|
|
10
|
-
import "../../
|
|
11
|
-
import "../../libs/v0.8.x/minter-libs/SetPriceLib.sol";
|
|
8
|
+
import {ISharedMinterSimplePurchaseV0} from "../../interfaces/v0.8.x/ISharedMinterSimplePurchaseV0.sol";
|
|
9
|
+
import {ISharedMinterV0} from "../../interfaces/v0.8.x/ISharedMinterV0.sol";
|
|
10
|
+
import {IMinterFilterV1} from "../../interfaces/v0.8.x/IMinterFilterV1.sol";
|
|
12
11
|
|
|
13
|
-
import "
|
|
12
|
+
import {AuthLib} from "../../libs/v0.8.x/AuthLib.sol";
|
|
13
|
+
import {SplitFundsLib} from "../../libs/v0.8.x/minter-libs/SplitFundsLib.sol";
|
|
14
|
+
import {MaxInvocationsLib} from "../../libs/v0.8.x/minter-libs/MaxInvocationsLib.sol";
|
|
15
|
+
import {SetPriceLib} from "../../libs/v0.8.x/minter-libs/SetPriceLib.sol";
|
|
14
16
|
|
|
15
|
-
|
|
17
|
+
import {ReentrancyGuard} from "@openzeppelin-4.5/contracts/security/ReentrancyGuard.sol";
|
|
16
18
|
|
|
17
19
|
/**
|
|
18
20
|
* @title Shared, filtered Minter contract that allows tokens to be minted with
|
|
@@ -35,6 +37,13 @@ pragma solidity 0.8.19;
|
|
|
35
37
|
* ----------------------------------------------------------------------------
|
|
36
38
|
* Additional admin and artist privileged roles may be described on other
|
|
37
39
|
* contracts that this minter integrates with.
|
|
40
|
+
* ----------------------------------------------------------------------------
|
|
41
|
+
* @notice Caution: While Engine projects must be registered on the Art Blocks
|
|
42
|
+
* Core Registry to assign this minter, this minter does not enforce that a
|
|
43
|
+
* project is registered when configured or queried. This is primarily for gas
|
|
44
|
+
* optimization purposes. It is, therefore, possible that fake projects may be
|
|
45
|
+
* configured on this minter, but they will not be able to mint tokens due to
|
|
46
|
+
* checks performed by this minter's Minter Filter.
|
|
38
47
|
*/
|
|
39
48
|
contract MinterSetPriceV5 is
|
|
40
49
|
ReentrancyGuard,
|
|
@@ -45,7 +54,7 @@ contract MinterSetPriceV5 is
|
|
|
45
54
|
address public immutable minterFilterAddress;
|
|
46
55
|
|
|
47
56
|
/// Minter filter this minter may interact with.
|
|
48
|
-
IMinterFilterV1 private immutable
|
|
57
|
+
IMinterFilterV1 private immutable _minterFilter;
|
|
49
58
|
|
|
50
59
|
/// minterType for this minter
|
|
51
60
|
string public constant minterType = "MinterSetPriceV5";
|
|
@@ -53,41 +62,6 @@ contract MinterSetPriceV5 is
|
|
|
53
62
|
/// minter version for this minter
|
|
54
63
|
string public constant minterVersion = "v5.0.0";
|
|
55
64
|
|
|
56
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
57
|
-
// STATE VARIABLES FOR SetPriceLib begin here
|
|
58
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
59
|
-
|
|
60
|
-
/// contractAddress => projectId => set price project config
|
|
61
|
-
mapping(address => mapping(uint256 => SetPriceLib.SetPriceProjectConfig))
|
|
62
|
-
private _setPriceProjectConfigMapping;
|
|
63
|
-
|
|
64
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
65
|
-
// STATE VARIABLES FOR SetPriceLib end here
|
|
66
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
67
|
-
|
|
68
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
69
|
-
// STATE VARIABLES FOR SplitFundsLib begin here
|
|
70
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
71
|
-
|
|
72
|
-
// contractAddress => IsEngineCache
|
|
73
|
-
mapping(address => SplitFundsLib.IsEngineCache) private _isEngineCaches;
|
|
74
|
-
|
|
75
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
76
|
-
// STATE VARIABLES FOR SplitFundsLib end here
|
|
77
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
78
|
-
|
|
79
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
80
|
-
// STATE VARIABLES FOR MaxInvocationsLib begin here
|
|
81
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
82
|
-
|
|
83
|
-
// contractAddress => projectId => max invocations specific project config
|
|
84
|
-
mapping(address => mapping(uint256 => MaxInvocationsLib.MaxInvocationsProjectConfig))
|
|
85
|
-
private _maxInvocationsProjectConfigMapping;
|
|
86
|
-
|
|
87
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
88
|
-
// STATE VARIABLES FOR MaxInvocationsLib end here
|
|
89
|
-
////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
|
90
|
-
|
|
91
65
|
// MODIFIERS
|
|
92
66
|
// @dev contract uses modifier-like internal functions instead of modifiers
|
|
93
67
|
// to reduce contract bytecode size
|
|
@@ -95,171 +69,168 @@ contract MinterSetPriceV5 is
|
|
|
95
69
|
|
|
96
70
|
/**
|
|
97
71
|
* @notice Initializes contract to be a Filtered Minter for
|
|
98
|
-
* `
|
|
99
|
-
* @param
|
|
72
|
+
* `minterFilter` minter filter.
|
|
73
|
+
* @param minterFilter Minter filter for which this will be a
|
|
100
74
|
* filtered minter.
|
|
101
75
|
*/
|
|
102
|
-
constructor(address
|
|
103
|
-
minterFilterAddress =
|
|
104
|
-
|
|
76
|
+
constructor(address minterFilter) ReentrancyGuard() {
|
|
77
|
+
minterFilterAddress = minterFilter;
|
|
78
|
+
_minterFilter = IMinterFilterV1(minterFilter);
|
|
105
79
|
}
|
|
106
80
|
|
|
107
81
|
/**
|
|
108
|
-
* @notice Manually sets the local maximum invocations of project `
|
|
109
|
-
* with the provided `
|
|
110
|
-
* than or equal to the value of project `
|
|
82
|
+
* @notice Manually sets the local maximum invocations of project `projectId`
|
|
83
|
+
* with the provided `maxInvocations`, checking that `maxInvocations` is less
|
|
84
|
+
* than or equal to the value of project `project_id`'s maximum invocations that is
|
|
111
85
|
* set on the core contract.
|
|
112
|
-
* @dev Note that a `
|
|
86
|
+
* @dev Note that a `maxInvocations` of 0 can only be set if the current `invocations`
|
|
113
87
|
* value is also 0 and this would also set `maxHasBeenInvoked` to true, correctly short-circuiting
|
|
114
88
|
* this minter's purchase function, avoiding extra gas costs from the core contract's maxInvocations check.
|
|
115
|
-
* @param
|
|
116
|
-
* @param
|
|
117
|
-
* @param
|
|
89
|
+
* @param projectId Project ID to set the maximum invocations for.
|
|
90
|
+
* @param coreContract Core contract address for the given project.
|
|
91
|
+
* @param maxInvocations Maximum invocations to set for the project.
|
|
118
92
|
*/
|
|
119
93
|
function manuallyLimitProjectMaxInvocations(
|
|
120
|
-
uint256
|
|
121
|
-
address
|
|
122
|
-
uint24
|
|
94
|
+
uint256 projectId,
|
|
95
|
+
address coreContract,
|
|
96
|
+
uint24 maxInvocations
|
|
123
97
|
) external {
|
|
124
98
|
AuthLib.onlyArtist({
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
99
|
+
projectId: projectId,
|
|
100
|
+
coreContract: coreContract,
|
|
101
|
+
sender: msg.sender
|
|
102
|
+
});
|
|
103
|
+
MaxInvocationsLib.manuallyLimitProjectMaxInvocations({
|
|
104
|
+
projectId: projectId,
|
|
105
|
+
coreContract: coreContract,
|
|
106
|
+
maxInvocations: maxInvocations
|
|
128
107
|
});
|
|
129
|
-
MaxInvocationsLib.manuallyLimitProjectMaxInvocations(
|
|
130
|
-
_projectId,
|
|
131
|
-
_coreContract,
|
|
132
|
-
_maxInvocations,
|
|
133
|
-
_maxInvocationsProjectConfigMapping[_coreContract][_projectId]
|
|
134
|
-
);
|
|
135
|
-
emit ProjectMaxInvocationsLimitUpdated(
|
|
136
|
-
_projectId,
|
|
137
|
-
_coreContract,
|
|
138
|
-
_maxInvocations
|
|
139
|
-
);
|
|
140
108
|
}
|
|
141
109
|
|
|
142
110
|
/**
|
|
143
|
-
* @notice Updates this minter's price per token of project `
|
|
111
|
+
* @notice Updates this minter's price per token of project `projectId`
|
|
144
112
|
* to be '_pricePerTokenInWei`, in Wei.
|
|
145
113
|
* @dev Note that it is intentionally supported here that the configured
|
|
146
114
|
* price may be explicitly set to `0`.
|
|
147
|
-
* @param
|
|
148
|
-
* @param
|
|
149
|
-
* @param
|
|
115
|
+
* @param projectId Project ID to set the price per token for.
|
|
116
|
+
* @param coreContract Core contract address for the given project.
|
|
117
|
+
* @param pricePerTokenInWei Price per token to set for the project, in Wei.
|
|
150
118
|
*/
|
|
151
119
|
function updatePricePerTokenInWei(
|
|
152
|
-
uint256
|
|
153
|
-
address
|
|
154
|
-
uint248
|
|
120
|
+
uint256 projectId,
|
|
121
|
+
address coreContract,
|
|
122
|
+
uint248 pricePerTokenInWei
|
|
155
123
|
) external {
|
|
156
124
|
AuthLib.onlyArtist({
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
125
|
+
projectId: projectId,
|
|
126
|
+
coreContract: coreContract,
|
|
127
|
+
sender: msg.sender
|
|
128
|
+
});
|
|
129
|
+
SetPriceLib.updatePricePerToken({
|
|
130
|
+
projectId: projectId,
|
|
131
|
+
coreContract: coreContract,
|
|
132
|
+
pricePerToken: pricePerTokenInWei
|
|
160
133
|
});
|
|
161
|
-
SetPriceLib.SetPriceProjectConfig
|
|
162
|
-
storage _setPriceProjectConfig = _setPriceProjectConfigMapping[
|
|
163
|
-
_coreContract
|
|
164
|
-
][_projectId];
|
|
165
|
-
SetPriceLib.updatePricePerTokenInWei(
|
|
166
|
-
_pricePerTokenInWei,
|
|
167
|
-
_setPriceProjectConfig
|
|
168
|
-
);
|
|
169
|
-
emit PricePerTokenInWeiUpdated(
|
|
170
|
-
_projectId,
|
|
171
|
-
_coreContract,
|
|
172
|
-
_pricePerTokenInWei
|
|
173
|
-
);
|
|
174
134
|
|
|
175
135
|
// for convenience, sync local max invocations to the core contract if
|
|
176
136
|
// and only if max invocations have not already been synced.
|
|
177
137
|
// @dev do not sync if max invocations have already been synced, as
|
|
178
138
|
// local max invocations could have been manually set to be
|
|
179
139
|
// intentionally less than the core contract's max invocations.
|
|
180
|
-
MaxInvocationsLib.MaxInvocationsProjectConfig
|
|
181
|
-
storage _maxInvocationsProjectConfig = _maxInvocationsProjectConfigMapping[
|
|
182
|
-
_coreContract
|
|
183
|
-
][_projectId];
|
|
184
140
|
// @dev if local maxInvocations and maxHasBeenInvoked are both
|
|
185
141
|
// initial values, we know they have not been populated on this minter
|
|
186
142
|
if (
|
|
187
|
-
MaxInvocationsLib.maxInvocationsIsUnconfigured(
|
|
188
|
-
|
|
189
|
-
|
|
143
|
+
MaxInvocationsLib.maxInvocationsIsUnconfigured({
|
|
144
|
+
projectId: projectId,
|
|
145
|
+
coreContract: coreContract
|
|
146
|
+
})
|
|
190
147
|
) {
|
|
191
|
-
syncProjectMaxInvocationsToCore(
|
|
148
|
+
MaxInvocationsLib.syncProjectMaxInvocationsToCore({
|
|
149
|
+
projectId: projectId,
|
|
150
|
+
coreContract: coreContract
|
|
151
|
+
});
|
|
192
152
|
}
|
|
193
153
|
}
|
|
194
154
|
|
|
195
155
|
/**
|
|
196
|
-
* @notice Purchases a token from project `
|
|
197
|
-
* @param
|
|
198
|
-
* @param
|
|
156
|
+
* @notice Purchases a token from project `projectId`.
|
|
157
|
+
* @param projectId Project ID to mint a token on.
|
|
158
|
+
* @param coreContract Core contract address for the given project.
|
|
199
159
|
* @return tokenId Token ID of minted token
|
|
200
160
|
*/
|
|
201
161
|
function purchase(
|
|
202
|
-
uint256
|
|
203
|
-
address
|
|
162
|
+
uint256 projectId,
|
|
163
|
+
address coreContract
|
|
204
164
|
) external payable returns (uint256 tokenId) {
|
|
205
|
-
tokenId = purchaseTo(
|
|
165
|
+
tokenId = purchaseTo({
|
|
166
|
+
to: msg.sender,
|
|
167
|
+
projectId: projectId,
|
|
168
|
+
coreContract: coreContract
|
|
169
|
+
});
|
|
206
170
|
return tokenId;
|
|
207
171
|
}
|
|
208
172
|
|
|
209
173
|
// public getter functions
|
|
210
174
|
/**
|
|
211
175
|
* @notice Gets the maximum invocations project configuration.
|
|
212
|
-
* @param
|
|
213
|
-
* @param
|
|
176
|
+
* @param projectId The ID of the project whose data needs to be fetched.
|
|
177
|
+
* @param coreContract The address of the core contract.
|
|
214
178
|
* @return MaxInvocationsLib.MaxInvocationsProjectConfig instance with the
|
|
215
179
|
* configuration data.
|
|
216
180
|
*/
|
|
217
181
|
function maxInvocationsProjectConfig(
|
|
218
|
-
uint256
|
|
219
|
-
address
|
|
182
|
+
uint256 projectId,
|
|
183
|
+
address coreContract
|
|
220
184
|
)
|
|
221
185
|
external
|
|
222
186
|
view
|
|
223
187
|
returns (MaxInvocationsLib.MaxInvocationsProjectConfig memory)
|
|
224
188
|
{
|
|
225
|
-
return
|
|
189
|
+
return
|
|
190
|
+
MaxInvocationsLib.getMaxInvocationsProjectConfig({
|
|
191
|
+
projectId: projectId,
|
|
192
|
+
coreContract: coreContract
|
|
193
|
+
});
|
|
226
194
|
}
|
|
227
195
|
|
|
228
196
|
/**
|
|
229
197
|
* @notice Gets the set price project configuration.
|
|
230
|
-
* @param
|
|
231
|
-
* @param
|
|
198
|
+
* @param projectId The ID of the project whose data needs to be fetched.
|
|
199
|
+
* @param coreContract The address of the core contract.
|
|
232
200
|
* @return SetPriceProjectConfig struct with the fixed price project
|
|
233
201
|
* configuration data.
|
|
234
202
|
*/
|
|
235
203
|
function setPriceProjectConfig(
|
|
236
|
-
uint256
|
|
237
|
-
address
|
|
204
|
+
uint256 projectId,
|
|
205
|
+
address coreContract
|
|
238
206
|
) external view returns (SetPriceLib.SetPriceProjectConfig memory) {
|
|
239
|
-
return
|
|
207
|
+
return
|
|
208
|
+
SetPriceLib.getSetPriceProjectConfig({
|
|
209
|
+
projectId: projectId,
|
|
210
|
+
coreContract: coreContract
|
|
211
|
+
});
|
|
240
212
|
}
|
|
241
213
|
|
|
242
214
|
/**
|
|
243
|
-
* @notice Checks if the specified `
|
|
244
|
-
* @dev This function retrieves the cached value of `
|
|
215
|
+
* @notice Checks if the specified `coreContract` is a valid engine contract.
|
|
216
|
+
* @dev This function retrieves the cached value of `isEngine` from
|
|
245
217
|
* the `isEngineCache` mapping. If the cached value is already set, it
|
|
246
|
-
* returns the cached value. Otherwise, it calls the `
|
|
247
|
-
* function from the `SplitFundsLib` library to check if `
|
|
218
|
+
* returns the cached value. Otherwise, it calls the `getV3CoreIsEngineView`
|
|
219
|
+
* function from the `SplitFundsLib` library to check if `coreContract`
|
|
248
220
|
* is a valid engine contract.
|
|
249
|
-
* @dev This function will revert if the provided `
|
|
221
|
+
* @dev This function will revert if the provided `coreContract` is not
|
|
250
222
|
* a valid Engine or V3 Flagship contract.
|
|
251
|
-
* @param
|
|
252
|
-
* @return bool indicating if `
|
|
223
|
+
* @param coreContract The address of the contract to check.
|
|
224
|
+
* @return bool indicating if `coreContract` is a valid engine contract.
|
|
253
225
|
*/
|
|
254
|
-
function isEngineView(address
|
|
255
|
-
SplitFundsLib.IsEngineCache storage isEngineCache =
|
|
256
|
-
|
|
257
|
-
];
|
|
226
|
+
function isEngineView(address coreContract) external view returns (bool) {
|
|
227
|
+
SplitFundsLib.IsEngineCache storage isEngineCache = SplitFundsLib
|
|
228
|
+
.getIsEngineCacheConfig(coreContract);
|
|
258
229
|
if (isEngineCache.isCached) {
|
|
259
230
|
return isEngineCache.isEngine;
|
|
260
231
|
} else {
|
|
261
|
-
// @dev this calls the non-modifying variant of
|
|
262
|
-
return SplitFundsLib.getV3CoreIsEngineView(
|
|
232
|
+
// @dev this calls the non-state-modifying variant of isEngine
|
|
233
|
+
return SplitFundsLib.getV3CoreIsEngineView(coreContract);
|
|
263
234
|
}
|
|
264
235
|
}
|
|
265
236
|
|
|
@@ -274,17 +245,18 @@ contract MinterSetPriceV5 is
|
|
|
274
245
|
* possible because the V3 core contract only allows maximum invocations
|
|
275
246
|
* to be reduced, not increased. Based on this rationale, we intentionally
|
|
276
247
|
* do not do input validation in this method as to whether or not the input
|
|
277
|
-
* @param
|
|
278
|
-
* @param
|
|
248
|
+
* @param projectId is an existing project ID.
|
|
249
|
+
* @param coreContract is an existing core contract address.
|
|
279
250
|
*/
|
|
280
251
|
function projectMaxHasBeenInvoked(
|
|
281
|
-
uint256
|
|
282
|
-
address
|
|
252
|
+
uint256 projectId,
|
|
253
|
+
address coreContract
|
|
283
254
|
) external view returns (bool) {
|
|
284
255
|
return
|
|
285
|
-
MaxInvocationsLib.getMaxHasBeenInvoked(
|
|
286
|
-
|
|
287
|
-
|
|
256
|
+
MaxInvocationsLib.getMaxHasBeenInvoked({
|
|
257
|
+
projectId: projectId,
|
|
258
|
+
coreContract: coreContract
|
|
259
|
+
});
|
|
288
260
|
}
|
|
289
261
|
|
|
290
262
|
/**
|
|
@@ -303,26 +275,27 @@ contract MinterSetPriceV5 is
|
|
|
303
275
|
* increased. When this happens, the minter will enable minting, allowing
|
|
304
276
|
* the core contract to enforce the max invocations check. Based on this
|
|
305
277
|
* rationale, we intentionally do not do input validation in this method as
|
|
306
|
-
* to whether or not the input `
|
|
307
|
-
* @param
|
|
308
|
-
* @param
|
|
278
|
+
* to whether or not the input `projectId` is an existing project ID.
|
|
279
|
+
* @param projectId is an existing project ID.
|
|
280
|
+
* @param coreContract is an existing core contract address.
|
|
309
281
|
*/
|
|
310
282
|
function projectMaxInvocations(
|
|
311
|
-
uint256
|
|
312
|
-
address
|
|
283
|
+
uint256 projectId,
|
|
284
|
+
address coreContract
|
|
313
285
|
) external view returns (uint256) {
|
|
314
286
|
return
|
|
315
|
-
MaxInvocationsLib.getMaxInvocations(
|
|
316
|
-
|
|
317
|
-
|
|
287
|
+
MaxInvocationsLib.getMaxInvocations({
|
|
288
|
+
projectId: projectId,
|
|
289
|
+
coreContract: coreContract
|
|
290
|
+
});
|
|
318
291
|
}
|
|
319
292
|
|
|
320
293
|
/**
|
|
321
294
|
* @notice Gets if price of token is configured, price of minting a
|
|
322
|
-
* token on project `
|
|
295
|
+
* token on project `projectId`, and currency symbol and address to be
|
|
323
296
|
* used as payment.
|
|
324
|
-
* @param
|
|
325
|
-
* @param
|
|
297
|
+
* @param projectId Project ID to get price information for
|
|
298
|
+
* @param coreContract Contract address of the core contract
|
|
326
299
|
* @return isConfigured true only if token price has been configured on
|
|
327
300
|
* this minter
|
|
328
301
|
* @return tokenPriceInWei current price of token on this minter - invalid
|
|
@@ -333,8 +306,8 @@ contract MinterSetPriceV5 is
|
|
|
333
306
|
* this minter. This minter always returns null address, reserved for ether
|
|
334
307
|
*/
|
|
335
308
|
function getPriceInfo(
|
|
336
|
-
uint256
|
|
337
|
-
address
|
|
309
|
+
uint256 projectId,
|
|
310
|
+
address coreContract
|
|
338
311
|
)
|
|
339
312
|
external
|
|
340
313
|
view
|
|
@@ -346,114 +319,94 @@ contract MinterSetPriceV5 is
|
|
|
346
319
|
)
|
|
347
320
|
{
|
|
348
321
|
SetPriceLib.SetPriceProjectConfig
|
|
349
|
-
storage
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
322
|
+
storage setPriceProjectConfig_ = SetPriceLib
|
|
323
|
+
.getSetPriceProjectConfig({
|
|
324
|
+
projectId: projectId,
|
|
325
|
+
coreContract: coreContract
|
|
326
|
+
});
|
|
327
|
+
isConfigured = setPriceProjectConfig_.priceIsConfigured;
|
|
328
|
+
tokenPriceInWei = setPriceProjectConfig_.pricePerToken;
|
|
354
329
|
currencySymbol = "ETH";
|
|
355
330
|
currencyAddress = address(0);
|
|
356
331
|
}
|
|
357
332
|
|
|
358
333
|
/**
|
|
359
|
-
* @notice Syncs local maximum invocations of project `
|
|
334
|
+
* @notice Syncs local maximum invocations of project `projectId` based on
|
|
360
335
|
* the value currently defined in the core contract.
|
|
361
|
-
* @param
|
|
362
|
-
* @param
|
|
336
|
+
* @param projectId Project ID to set the maximum invocations for.
|
|
337
|
+
* @param coreContract Core contract address for the given project.
|
|
363
338
|
* @dev this enables gas reduction after maxInvocations have been reached -
|
|
364
339
|
* core contracts shall still enforce a maxInvocation check during mint.
|
|
365
340
|
*/
|
|
366
341
|
function syncProjectMaxInvocationsToCore(
|
|
367
|
-
uint256
|
|
368
|
-
address
|
|
342
|
+
uint256 projectId,
|
|
343
|
+
address coreContract
|
|
369
344
|
) public {
|
|
370
345
|
AuthLib.onlyArtist({
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
346
|
+
projectId: projectId,
|
|
347
|
+
coreContract: coreContract,
|
|
348
|
+
sender: msg.sender
|
|
374
349
|
});
|
|
375
350
|
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
_maxInvocationsProjectConfigMapping[_coreContract][_projectId]
|
|
381
|
-
);
|
|
382
|
-
emit ProjectMaxInvocationsLimitUpdated(
|
|
383
|
-
_projectId,
|
|
384
|
-
_coreContract,
|
|
385
|
-
maxInvocations
|
|
386
|
-
);
|
|
351
|
+
MaxInvocationsLib.syncProjectMaxInvocationsToCore({
|
|
352
|
+
projectId: projectId,
|
|
353
|
+
coreContract: coreContract
|
|
354
|
+
});
|
|
387
355
|
}
|
|
388
356
|
|
|
389
357
|
/**
|
|
390
|
-
* @notice Purchases a token from project `
|
|
391
|
-
* the token's owner to `
|
|
392
|
-
* @param
|
|
393
|
-
* @param
|
|
394
|
-
* @param
|
|
358
|
+
* @notice Purchases a token from project `projectId` and sets
|
|
359
|
+
* the token's owner to `to`.
|
|
360
|
+
* @param to Address to be the new token's owner.
|
|
361
|
+
* @param projectId Project ID to mint a token on.
|
|
362
|
+
* @param coreContract Core contract address for the given project.
|
|
395
363
|
* @return tokenId Token ID of minted token
|
|
396
364
|
*/
|
|
397
365
|
function purchaseTo(
|
|
398
|
-
address
|
|
399
|
-
uint256
|
|
400
|
-
address
|
|
366
|
+
address to,
|
|
367
|
+
uint256 projectId,
|
|
368
|
+
address coreContract
|
|
401
369
|
) public payable nonReentrant returns (uint256 tokenId) {
|
|
402
370
|
// CHECKS
|
|
403
|
-
|
|
404
|
-
storage _setPriceProjectConfig = _setPriceProjectConfigMapping[
|
|
405
|
-
_coreContract
|
|
406
|
-
][_projectId];
|
|
407
|
-
MaxInvocationsLib.MaxInvocationsProjectConfig
|
|
408
|
-
storage _maxInvocationsProjectConfig = _maxInvocationsProjectConfigMapping[
|
|
409
|
-
_coreContract
|
|
410
|
-
][_projectId];
|
|
411
|
-
|
|
371
|
+
// pre-mint MaxInvocationsLib checks
|
|
412
372
|
// Note that `maxHasBeenInvoked` is only checked here to reduce gas
|
|
413
373
|
// consumption after a project has been fully minted.
|
|
414
|
-
// `
|
|
374
|
+
// `maxInvocationsProjectConfig.maxHasBeenInvoked` is locally cached to reduce
|
|
415
375
|
// gas consumption, but if not in sync with the core contract's value,
|
|
416
376
|
// the core contract also enforces its own max invocation check during
|
|
417
377
|
// minting.
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
);
|
|
422
|
-
|
|
423
|
-
// require artist to have configured price of token on this minter
|
|
424
|
-
require(
|
|
425
|
-
_setPriceProjectConfig.priceIsConfigured,
|
|
426
|
-
"Price not configured"
|
|
427
|
-
);
|
|
378
|
+
MaxInvocationsLib.preMintChecks({
|
|
379
|
+
projectId: projectId,
|
|
380
|
+
coreContract: coreContract
|
|
381
|
+
});
|
|
428
382
|
|
|
429
|
-
//
|
|
430
|
-
|
|
383
|
+
// pre-mint checks for set price lib, and get price per token in wei
|
|
384
|
+
// @dev price per token is loaded into memory here for gas efficiency
|
|
385
|
+
uint256 pricePerTokenInWei = SetPriceLib.preMintChecksAndGetPrice({
|
|
386
|
+
projectId: projectId,
|
|
387
|
+
coreContract: coreContract
|
|
388
|
+
});
|
|
431
389
|
|
|
432
390
|
require(msg.value >= pricePerTokenInWei, "Min value to mint req.");
|
|
433
391
|
|
|
434
392
|
// EFFECTS
|
|
435
|
-
tokenId =
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
msg.sender
|
|
440
|
-
);
|
|
393
|
+
tokenId = _minterFilter.mint_joo({
|
|
394
|
+
to: to,
|
|
395
|
+
projectId: projectId,
|
|
396
|
+
coreContract: coreContract,
|
|
397
|
+
sender: msg.sender
|
|
398
|
+
});
|
|
441
399
|
|
|
442
|
-
MaxInvocationsLib.
|
|
443
|
-
tokenId,
|
|
444
|
-
|
|
445
|
-
);
|
|
400
|
+
MaxInvocationsLib.validateMintEffectsInvocations({
|
|
401
|
+
tokenId: tokenId,
|
|
402
|
+
coreContract: coreContract
|
|
403
|
+
});
|
|
446
404
|
|
|
447
405
|
// INTERACTIONS
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
SplitFundsLib.splitFundsETH({
|
|
453
|
-
_projectId: _projectId,
|
|
454
|
-
_pricePerTokenInWei: pricePerTokenInWei,
|
|
455
|
-
_coreContract: _coreContract,
|
|
456
|
-
_isEngine: isEngine
|
|
406
|
+
SplitFundsLib.splitFundsETHRefundSender({
|
|
407
|
+
projectId: projectId,
|
|
408
|
+
pricePerTokenInWei: pricePerTokenInWei,
|
|
409
|
+
coreContract: coreContract
|
|
457
410
|
});
|
|
458
411
|
|
|
459
412
|
return tokenId;
|