Skip to content
This repository has been archived by the owner on Mar 11, 2024. It is now read-only.

๐Ÿ‘พ ๐—ผ๐—ป-๐—ฐ๐—ต๐—ฎ๐—ถ๐—ป ๐—ด๐—ฒ๐—ป๐—ฒ๐—ฟ๐—ฎ๐˜๐—ถ๐˜ƒ๐—ฒ ๐˜€๐˜๐—ผ๐—ฟ๐˜†๐˜๐—ฒ๐—น๐—น๐—ถ๐—ป๐—ด ๐—ป๐—ณ๐˜๐˜€ ๐—ณ๐—ผ๐—ฟ ๐—ณ๐—ถ๐—น๐—บ๐—บ๐—ฎ๐—ธ๐—ฒ๐—ฟ ๐—ฑ๐—ฎ๐—ผ

Notifications You must be signed in to change notification settings

go-outside-labs/generative-sol

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

46 Commits
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 
ย 

Repository files navigation

๐ŸŽญ smart contract for the "on-chain generative storytelling NFT collection"



tl; dr

  • the storytelling card is a generative ERC721 collection loosely based on the loot project, that celebrates the sunset of FilmmakerDAO.
  • SVGs are generated (pseudo-)randomly on the ethereum blockchain: you can check the contract here or mint your card here.


setting up

  • set an account and project on infura or alchemy.
  • set a test account in metamask and copy your private key (i used rinkeby for dev and you can get some funds in this faucet).
  • set up an account at etherscan and grab the API key.
cp env_example .env
vim .env

install dependencies:

npm install


deploying on rinkeby

set the default network "rinkeby" at hardhat.config.js.

compile the contract:

npx hardhat compile

deploy the contract:

npx hardhat run scripts/deploy.js

you should be able to see it at rinkeby etherscan.



Interacting with the contract

npx hardhat console --network rinkeby

ad-hoc minting:

> const Film = await ethers.getContractFactory('FilmmakerDAO');
> const film = await Film.attach('<contract>')
> await film.mint(<tokenID>)

you should be able to see the NFT on the opensea (testnet).



verify your smart contract

install hardhat etherscan plugin (compatible with etherscan and polygonscan)

npm install --save-dev @nomiclabs/hardhat-etherscan

verify the smart contract with the contract address

npx hardhat verify --network rinkeby YOUR_CONTRACT_ADDRESS


useful commands

test a smart contract:

npx hardhat test

clean artifacts:

npx hardhat clean


deploying on mainnet

same steps, simply set the default network to "mainnet" and make sure the private key in .env is from the desired account.

About

๐Ÿ‘พ ๐—ผ๐—ป-๐—ฐ๐—ต๐—ฎ๐—ถ๐—ป ๐—ด๐—ฒ๐—ป๐—ฒ๐—ฟ๐—ฎ๐˜๐—ถ๐˜ƒ๐—ฒ ๐˜€๐˜๐—ผ๐—ฟ๐˜†๐˜๐—ฒ๐—น๐—น๐—ถ๐—ป๐—ด ๐—ป๐—ณ๐˜๐˜€ ๐—ณ๐—ผ๐—ฟ ๐—ณ๐—ถ๐—น๐—บ๐—บ๐—ฎ๐—ธ๐—ฒ๐—ฟ ๐—ฑ๐—ฎ๐—ผ

Topics

Resources

Stars

Watchers

Forks