Giter Site home page Giter Site logo

sample_nft_project's Introduction

Sample NFT project

Directories & Files

  • images_processed - this is the output directory of the compiled images and metadata
  • images_raw - this is a directory holding all the layers to build the images, organised by a subdirectory
  • src-node - this directory holds truffle config for CLI deploy and contract verification
  • src-php - this directory holds the script to compile the images and metadata
  • .env.example - this file should be copied to .env with secret data for your truffle scripts
  • composer.json - this is configuration for the php scripts (src-php/)
  • package.json - this is configuration for the node scripts (src-node/)

Installation and Running

Note: To begin, you should run composer install and npm install

  • Compile the images with composer run start (composer run test for setup tests)
  • Compile the contracts with truffle migrate --network rinkeby (make sure you run this when pwd is src-node)
    • Verify the contract with Etherscan with truffle run verify SampleNftContract --network rinkeby (make sure you run this when pwd src-node)

Instructions

  • Make sure you name your image files as <trait_name>_<trait_shape>_<trait_color>.png
  • Generate your layers, with 00head being the main "background" of the image
    • 01eyes being a transparent background image containing different eye skins
    • 02mouth being a transparent background image containing different mouth skins
  • Read through the code in src-php/index.php and make adjustments as you see fit
    • You may want to add in some forced rarity in here
  • Run composer run test to run the tests, and if passed, run composer run start to compile the images and metadata
  • Upload the directory images_processed/* to a webserver - people favour IPFS for this

sample_nft_project's People

Contributors

409h avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.