Giter Site home page Giter Site logo

tezosmiami / fxhash-webpack-boilerplate Goto Github PK

View Code? Open in Web Editor NEW

This project forked from fxhash/fxhash-boilerplate

0.0 0.0 0.0 35 KB

A boiletplate with webpack to develop generative Tokens on fxhash

JavaScript 79.23% HTML 14.07% CSS 2.38% Batchfile 2.11% Shell 2.20%

fxhash-webpack-boilerplate's Introduction

FXHASH PFP Token generator

A boilerplate to automate and ease the creation of profile picture projects on fxhash.

Licensing

Template license: CC BY-NC-SA 4.0 Generated code license: MIT

The template itself is licensed as CC BY-NC-SA 4.0, you can read what this means in clear terms on the creative commons website.

The generated code is licensed as MIT, which basically means "do with it as you like, as long as you don't remove the original included license". You do not need to mention that you used this template in your works, however it would be nice if you did - and it would be even nicer if you added me with a 1% primary split, or similar. Read the linked document or included LICENSE file for legal details.

How to use

Note: You will need to have nodejs installed.

Get up and running

Download this generator by clicking on "Code" and then "Download ZIP" in the top part of this website, or by clicking here.

Extract it somewhere, and find the layers directory inside the public directory. This is where you will save your layers. You do not need to change any other part of the project.

Build your layers

Think of the layers like a stack of transparent layers on top of each other.

For each layer your project will have, generate a new directory with a name like this: order-name. For example: 00-base, 01-skin, 02-eyes, and so on. This determines the order your layers will be "stacked" in, with 00 being all the way in the bottom of the stack, 01 on top of that, and so on.

Then, in those directories, add your layer variations with a preset name, including chances, like this: chance-name. Here are some examples: 5-blue, 15-red, 1-orange. The chances do not need to add up to 100, they are just relative to each other. A chance of 5 is half as likely to appear as a chance of 10, but five times as likely as a chance of 1, for example.

Important notes

  • Make sure to use no spaces in your file or folder names! If you want spaces in the attributes, use _ instead
  • Emojis, question marks, and other special characters in folder or file names will not work either.
  • All images need to be the exact same size, otherwise they will look skewed
  • All images need to be in the PNG format
  • All images need to be transparent in all spots where lower layers should be seen through
  • The generated ZIP file needs to be less than 30 megabytes!
  • Clearly mark your project as a layered composition, either in the description or by using the Image composition tag - ideally both!

Layer options

There is a set of options you can use to define certain aspects of your layers, for example if they are hidden in the feature display or their blend mode.

See the following table for available options and their values:

Option name Possible values Description
hide true, false, default: false If a layer is hidden, it will not show up in the feature list on fxhash
blend All values listed here, default: source-over Sets the blend mode of this layer, much like in your picture editing program

To set these values, you need to add them to your layer names like in the following examples:

Options Result
hide: true, blend: overlay 00-(hide-true_blend-overlay)-layer_name
hide: false, blend: destination-out 00-(blend-destination-out)-layer_name

Layer structure example

Here is a complete layer structure as an example, with hair, clothes and accessories having custom chances, and whiteseyes and clownoutline being hidden, and mouths being hidden and using a custom blend mode:

๐Ÿ“ public
โ””โ”€โ”€ ๐Ÿ“ layers
   โ”œโ”€โ”€ ๐Ÿ“ 00-background
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-beige.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-blue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-brown.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-darkblue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-darkpink.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-green.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-lightblue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-purple.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-red.png
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 1-yellow.png
   โ”œโ”€โ”€ ๐Ÿ“ 01-(hide)-whiteseyes
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 1-whiteseyes.png
   โ”œโ”€โ”€ ๐Ÿ“ 02-skincolour
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-aqua.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-beige.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-blue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-brown.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-gold.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-green.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-orange.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-pink.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-purple.png
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 1-red.png
   โ”œโ”€โ”€ ๐Ÿ“ 03-eyes
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-aqua.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-blue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-brown.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-green.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-neon.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-orange.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-pastel.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-pink.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-purple.png
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 1-red.png
   โ”œโ”€โ”€ ๐Ÿ“ 04-(hide_blend-multiply)-mouths
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-aqua.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-darkblue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-darkergreen.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-darkgreen.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-darkpurple.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-green.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-maroon.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-orange.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-purple.png
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 1-yellow.png
   โ”œโ”€โ”€ ๐Ÿ“ 05-teeth
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-black.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-brown.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-darkgreen.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-green.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-lilac.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-neon.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-orange.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-purple.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-red.png
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 1-yellow.png
   โ”œโ”€โ”€ ๐Ÿ“ 06-eyebrows
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-aqua.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-black.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-blue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-darkblue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-green.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-orange.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-pink.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-purple.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-red.png
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 1-yellow.png
   โ”œโ”€โ”€ ๐Ÿ“ 07-facepaint
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-eyeblue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-eyegreen.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-eyered.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-faceblue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-faceorange.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-facered.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-mouthblue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-mouthorange.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-mouthred.png
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 1-none.png
   โ”œโ”€โ”€ ๐Ÿ“ 08-(hide)-clownoutline
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 1-outline.png
   โ”œโ”€โ”€ ๐Ÿ“ 09-clownnoses
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-aqua.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-blue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-green.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-neon.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-none.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-orange.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-pastel.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-pink.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-purple.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-red.png
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 1-yellow.png
   โ”œโ”€โ”€ ๐Ÿ“ 10-hair
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-none.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-red.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-aqua.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-blue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-darkgreen.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-neon.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-orange.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-pastel.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-pink.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-purple.png
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 5-yellow.png
   โ”œโ”€โ”€ ๐Ÿ“ 11-clothes
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-none.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-aqua.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-blue.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-green.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-lilac.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-neon.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-orange.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-pink.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-purple.png
   |  โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-red.png
   |  โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 5-yellow.png
   โ””โ”€โ”€ ๐Ÿ“ 12-accessories
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 1-none.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 10-bubblegum.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 10-earringcross.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 10-Nosering.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 11-textbubbleha.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 2-nightcap.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 4-pipe.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-lasereyesblue.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-lasereyesneon.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-lasereyesred.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 5-monocle.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 6-cigar.png
      โ”œโ”€โ”€ ๐Ÿ–ผ๏ธ 7-cigarette.png
      โ””โ”€โ”€ ๐Ÿ–ผ๏ธ 8-partywhistle.png

Additional features

Collectors can click/tap the image to make a Download image button appear. This lets them download the image in the original resolution, instead of the scaled presentation on the website.

Generate your token

After you have setup your layers and are happy with them, double click one of the included files generate.bat (Windows) or generate.sh (Mac and Linux), depending on the system you are on. If you are on mac or linux, you have to make the generate.sh file executable first.

This produces a project.zip file in the dist-zipped directory. This is the file you need to upload to fxhash to generate your token.

Publish your token

Go to https://fxhash.xyz/sandbox/ and upload the project.zip file in there to see if it works properly.

Finally, you can mint your token using the same project.zip file.

The capture settings are as follows:

When will the capture module trigger?
Programmatic trigger using fxpreview()
What will be the target of the capture module?
From <canvas>
A CSS selector that targets the canvas on which your graphics are rendered
#theCanvas

fxhash-webpack-boilerplate's People

Contributors

purespider avatar ciphrd avatar laurent-h avatar dennisklicker 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.