-
Notifications
You must be signed in to change notification settings - Fork 44
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
[FEATURE] Layer Maximum Repeatability Settings #16
Comments
As written by arnaugm (Thank you very much for the work done here) It can be configured at a layer configuration level with the option maxRepeatedTraits which expects a numeric value. Example:
If for example this value is set to 2, whenever the art engine generates a new artwork that contains 3 or more traits already present in one of the pieces already created for the collection, this new piece will be discarded and a notification will be displayed in the console with the message: Combination of traits excluded because of exclusion rules! This option will reduce the number of possible combinations and could be possible that the collection can not reach the requested number of elements. In this case increase the number of maximum repetitions or provide more traits in the layers that has less options to increase the probability of selecting different traits. If the option is not defined the restriction is not applied. |
I have introduced this functionality into my repo and have slightly modified the error that gets returned to the screen to "Combination of traits excluded because of maximum repeatability exclusion rule!" |
Users can now make use of the maxRepeatedTraits configuration within their layer configuration set to allow the layers within that specific set to be generated only X number of times.
|
Summary
Add the ability to set the maximum number of times that a specific layer can repeat / be part of the collection.
Basic example
If I have a character layer with one item, hair layer with two items and glasses with three items.
Character:
main.png
Hair:
short.png
long.png
Glasses:
funky.png
square.png
oversized.png
Maximum layer repeatability: If I set my Glasses layer's maximum repeatability to 1, then only a single art work that gets generated will have one of the 3 glasses layer items. So with the layers, there would then be art work items generated:
Motivation
Users would like to be able to force rarity on certain layers for their collections.
The text was updated successfully, but these errors were encountered: