* Test coverage for Challenges Command
* Added CompleteChallengeCommand test class
* Added Utils test class
* Added ChallengesGUI test class
* Fix code smells from sonarcloud analysis
* Added .gitignore
* Added Travis CI config file
* WIP ChallengesManager Test class
* Added ChallengesManager test class
* Removed debug
* Removed code smells.
* Added ChallengesAddon test class.
* Added onDisbale test
* Added new TryToComplete test class - WIP
Covers inventory challenges.
* Added Island Challenge entity tests to TryToComplete test class
This is old change that was declined (#105), but unfortunately it is necessary.
If every ID is based on world names, than addon cannot process "/" in it. It mean that worlds cannot be put into different folders.
This change will fix it, but it is not completed.
In progress.
There does not exist converter, so old data is not usable with this version.
It looks like, exist plugins that keep capital letters in world names. That mean, it is not correct to lowercasing any id's.
To fix it, now, instead of lowercasing, challenges should be case insensitive.
Implement ability to complete challenge multiple times at once.
To do it, I split everything in checking/removing/rewarding steps.
In checking step, it calculates if it is possible to complete with minimal requirements and then calculates maximal repeating factor.
In removing step, it removes everything that is necessary.
In rewarding step, it give rewards by necessary factor (multilayer).
I rework item/block/entity removing as factors may be influenced at the last element, so I improve everything by memory usage. Create necessary sets/lists/queues for faster access to already collected items.
- Implement LockedIcon in ChallengeLevel (can be null)
- Implement defaultLockedIcon in Settings (can be overwritten by ChallengeLevel)
- Reformat Config File. !!!
Rework methods that access to ChallengesPlayerData object. Methods that access to this object will be private and use UUID and String where possible.
Add public methods that could use previously mentioned methods to access ChallengesPlayerData object.
Implement these methods in all places.
Add ability to enable/disable island storage in config (no-gui for now).
Disable challenge GUI opening, if user does not have island.
Add methods isLevelDone() and addCompletedLevel() to ChallengesPlayerData object.
Add isLevelCompleted(), validateLevelCompletion() and setLevelComplete() to ChallengesManager.
Add check in TryToComplete after completing challenges first time.
Challenge now will not know their world, as it is not necessary.
Remove ICON type, as it is useless.
Rename Level to Other, as under it will be not only level things.
Rename slot to order, as it was weird that users could define slot but not order. Order is easier to understand and use.
ChallengesLevel now knows all their levels.
Each challenge level only will be for single world.
Rename some variables.
ChallengesPlayerData was just adapted with changes in challenges and level classes.
This GUI currently does not have ability to change values. It only contains skeleton for each option, that user should be able to change.
Add new parameters to Challenges class.