So obviously, it is a modification of the default sample one. I eventually want it to be able to generate an entire deck of unique cards for Caravan, and I don’t know yet how to get it to add jokers (which would need to remove the suit information)
I have been having trouble finding out where to look up this information.
so looking at it, the
getcards
list isn’t called for in the list itself, and is pulled up in the html right after the title. and this is what makes it ensure that there is no duplicates?i did get it to output between 30-60 which is what i want, i deleted the
select-until-plugin
nothing happened but when i tried removingconsole.log(cards.size)
like you said, it broke it, so i put it backmy updated generator with tweaks based on the code you gave me is here https://perchance.org/6903zy9slr
Yes, the
getCards
is your main displaying output there which is why it is placed on the HTML, you can name them what you want if you prefer it having namedoutput
on the HTML, just need to rename some on the code. It isn’t the main code that is ensuring that there are no duplicates, the code for it is on theselectCards
portion, butselectCards
is also the one that displays it.You might need to also remove the comma after it e.g.
... (console.log(cards.size), cards.add(...), ...) : ...
To
... (cards.add(...), ...) : ...