Skip to content
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

fix: use a holder to allow "upgrading" LocalBV3Set to a full fat one #3051

Merged
merged 3 commits into from
Jan 18, 2025

Conversation

dordsor21
Copy link
Member

There was a/some issue(s) that were due to a local set being used assumptively. The only instances of the local sets being explicitly used should now only be when using chunk coords, or for the floating tree remover

@dordsor21 dordsor21 requested a review from a team as a code owner December 30, 2024 17:39
@github-actions github-actions bot added the Bugfix This PR fixes a bug label Dec 30, 2024
@SirYwell
Copy link
Member

Do we need to expose BlockVector3SetHolder? I think having a private/package-private class would be better, with static factory methods like BlockVector3Set.expandable() and BlockVector3Set.fromLocal(LocalBlockVectorSet) or something similar.

Also the Cloneable interface/the clone() method are kinda flawed, maybe it's better to just have our own copy() methods.

@dordsor21
Copy link
Member Author

Do we need to expose BlockVector3SetHolder? I think having a private/package-private class would be better, with static factory methods like BlockVector3Set.expandable() and BlockVector3Set.fromLocal(LocalBlockVectorSet) or something similar.

Also the Cloneable interface/the clone() method are kinda flawed, maybe it's better to just have our own copy() methods.

Yeah I can probably move it into the local directly as there's no reason to have a holder for a full fat bv3set.

I also just copied the fact the local already had a clone method tbh, but yeah copy would also be consistent with everything else in FAWE

@dordsor21 dordsor21 force-pushed the fix/upgradeable-bv3-set branch from 4e4be5e to 234667a Compare December 31, 2024 10:49
@dordsor21 dordsor21 requested review from SirYwell and a team January 3, 2025 14:27
Copy link
Member

@SirYwell SirYwell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I also noticed CachedMask catches UnsupportedOperationException, should that be adjusted too? I guess those try-catch blocks can just be removed this way?

@dordsor21 dordsor21 mentioned this pull request Jan 10, 2025
@dordsor21 dordsor21 requested review from SirYwell and a team January 10, 2025 13:41
Copy link
Member

@SirYwell SirYwell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good

@dordsor21 dordsor21 requested a review from a team January 10, 2025 14:59
@dordsor21 dordsor21 merged commit 69d8543 into main Jan 18, 2025
11 checks passed
@dordsor21 dordsor21 deleted the fix/upgradeable-bv3-set branch January 18, 2025 17:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bugfix This PR fixes a bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants