ProjectOpenSea / seadrop

Smart contracts for primary drops on EVM chains

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Problem using seadrop in another contract

amirfaramarzi opened this issue · comments

commented

Hello friends

I want to write a special contract and deploy it through truffle or hardhat
My problem:
I get a clone from the seadrop contract and execute the yarn init and yarn build commands. After that, I write a contract as follows, but during compilation, errors are returned stating that some files do not exist (one of the errors returned is Error: not found operator-filter-registry/DefaultOperatorFilterer.sol
) where is the problem How can I solve my problem?

// SPDX-License-Identifier: MIT
pragma solidity 0.8.17;
import { ERC721SeaDrop } from "src/ERC721SeaDrop.sol";
contract Test is ERC721SeaDrop {
constructor(
string memory name,
string memory symbol
address[] memory allowedSeaDrop
) ERC721SeaDrop(name, symbol, allowedSeaDrop) {}
}

You need to use the hardhat.config file in root to run to process the import remapping, see package.json scripts for examples. It might be easier to just use foundry if you are familiar with that instead of hardhat! :)

commented

Hello dear ryanio, thank you, I understood how to solve my problem

But I have another question

I create every contract based on seadrop, even though I don't verify it, it is automatically verified, but this is not my problem, my problem is that I edit my contract, but after the system is deployed, it is automatically signed. which deploys and verifies what it wants (it seems that every contract I create is ignored and the system automatically takes a clone of the contract 0xce110f93c8aca816a2bd48ec6e30fa4ce1f4ac7a and deploys it again)

What is the reason for this? And how can I solve this problem?

Hi, I have finished preparing my NFT project and I want to use this seadrop smart contract to publish my project on opensea. What are the variables that I must change in the contract to suit my project? Thank you. I am waiting for an answer, if you would be so kind.

@amirfaramarzi I'm not sure, sounds like an issue with your deployment code deploying the standard contract instead of your custom one?

@Hassan19731985 it is easiest for you to deploy the contract using the OpenSea Creator Studio UI and use the website to configure the drop as you'd like.

commented

Hello dear @ryanio

I found out where the problem was

After compiling, the system caches the code and deploys the cached code forever