Para obtener los atributos del avatar hay un error. Inicialmente se está obteniendo cada valor pasando el tokenId como parámetro, cuando debería ser el dna. Para ello primero se debe resolver la promesa
const [
tokenURI,
dna,
owner,
] = await Promise.all([
platziPunks.methods.tokenURI(tokenId).call(),
platziPunks.methods.tokenDNA(tokenId).call(),
platziPunks.methods.ownerOf(tokenId).call(),
]);
y luego con el dna se obtiene los valores de loa atributos:
const [
accessoriesType,
clotheColor,
clotheType,
eyeType,
eyeBrowType,
facialHairColor,
facialHairType,
hairColor,
hatColor,
graphicType,
mouthType,
skinColor,
topType,
] = await Promise.all([
platziPunks.methods.getAccessoriesType(dna).call(),
platziPunks.methods.getClotheColor(dna).call(),
platziPunks.methods.getClotheType(dna).call(),
platziPunks.methods.getEyeType(dna).call(),
platziPunks.methods.getEyeBrowType(dna).call(),
platziPunks.methods.getFacialHairColor(dna).call(),
platziPunks.methods.getFacialHairType(dna).call(),
platziPunks.methods.getHairColor(dna).call(),
platziPunks.methods.getHatColor(dna).call(),
platziPunks.methods.getGraphicType(dna).call(),
platziPunks.methods.getMouthType(dna).call(),
platziPunks.methods.getSkinColor(dna).call(),
platziPunks.methods.getTopType(dna).call(),
])