Randomize mine items only in places it can fit. Hence fix 0 item bug #178
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This essentially combines 3ae3c90#diff-179a97f89e4d8cc0cce87781606fe8b5 and https://github.com/Ishadijcks/Ishadijcks.github.io/pull/175/files to fix the underground.
Currently, underground randomizes items between 1 and
max-3
, then checks if items can fit. As a result, some larger items are not guaranteed to fit. Some people may be very unlucky and have all 3 of their items not fit and create the "zero items bug".Here, we always guarantee the successful addition of the first item, by randomizing for spots that the item can fit.
Note: this is basically the same as pokeclicker/pokeclicker@afaf88d#diff-c337aaee8e9ee46ce006207353a43b08 in the TypeScript rewrite.