-
Notifications
You must be signed in to change notification settings - Fork 225
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Index.js only has 96 lines of code #9
Comments
I am also running into the same issue |
look closely at the lines hes added. the guide actually shows that the first part of the generator, only generates pictures. you have to choose to dump them to ipfs, and then if you want, contract them, or put them on opensea with lazyminting. The guide isnt wrong, hes just modified his for everything he wants. In the youtube videos, it posts the github, AND the ipfs configuration. what your looking at, is the IPFS config, along with the contract signing he has built in. if your having issues with the code, verify your running these things on a mac or linux terminal, as windows has no git commands. pay close attention to installing pre reqs and verify they exist before moving forward. Outside of that, you would need to be more specific other than "its missing code". I get it, i felt the same way until i did some investigation. |
Sorry for my first comment i have detailed my issue more thoroughly this time i really appreciate your time and help! So i have made some progress i have all of my generated art uploaded to moralis shown in photo. But I notice some discrepancies.... First off my photos do not have the 64 0's after them when looking at image on IPFS, but i think that may be issue with my index.js code i have shown below. Second i noticed my columns are labeled differently than the video, this is also connected to the first issue i think. But my big issue now is when i execute my contract i am only seeing one photo for all nft's. i will leave the code for my contract below. Here is working code for Config.js /*******************************************************************
// adds a rarity to the configuration. This is expected to correspond with a directory containing the rarity for each defined layer // get the name without last 4 characters -> slice .png from the name // reads the filenames of a given folder and returns it with its name and path // adds a layer to the configuration. The layer will hold information on all the defined parts and
}); let elementsForLayer = { // adds layer-specific percentages to use one vs another rarity /**************************************************************
// image width in pixels // create required weights // create required layers ]; // provide any specific percentages that are required for a given layer and rarity level module.exports = { Here is working code for index.js const fs = require("fs"); // canvas for image compile // Moralis creds Moralis.start({ serverUrl, appId, masterKey }); // adds a signature to the top left corner of the canvas // generate a random color hue const drawBackground = () => { // add metadata for individual nft edition // prepare attributes for the given element to be used as metadata // loads an image from the layer path const drawElement = (_element) => { // check the configured layer to find information required for rendering the layer // check if the given dna is contained within the given dnaList const getRandomRarity = (_rarityOptions) => { for (let i = 0; i <= _rarityOptions.length; i++) { // create a dna based on the available layers for the given rarity // holds which rarity should be used for which image in edition const writeMetaData = (_data) => { // holds which dna has already been used during generation // clear meta data from previous run // prepare dnaList object // create NFTs from startEditionFrom to editionSize while (editionCount <= editionSize) {
} // Initiate code Contract code // SPDX-License-Identifier: MIT //import 1155 token contract from Openzeppelin // Example contract to be deployed via https://remix.ethereum.org/ for testing purposes. contract OZ is ERC1155, Ownable {
} |
i removed my sensitive data from the index.js in the code above |
Please send full code in this file |
got the codes bro? |
Yea I’ll send after work
…Sent from my iPhone
On Feb 18, 2022, at 3:14 PM, roop37 ***@***.***> wrote:
got the codes bro?
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications on the go with GitHub Mobile for iOS or Android.
You are receiving this because you authored the thread.
|
In the video when he is done with config.js and opens index.js i only have 96 lines of code and he scrolls down to 260 to make a vital code change. When i look at the index.js on Github i also only see 96 lines of code... where am i going wrong to not generate the rest of the code?
The text was updated successfully, but these errors were encountered: