Skip to content

Sponge module refactoring and fixes - #2697

Merged
me4502 merged 7 commits into
EngineHub:version/7.3.xfrom
Vilsu221:version/7.3.x
Apr 9, 2025
Merged

Sponge module refactoring and fixes#2697
me4502 merged 7 commits into
EngineHub:version/7.3.xfrom
Vilsu221:version/7.3.x

Conversation

@Vilsu221

@Vilsu221 Vilsu221 commented Jan 16, 2025

Copy link
Copy Markdown
Contributor

Fix items drop when making block changes.

Implement sendBiomeUpdates.

Move listeners into own class.

@Vilsu221
Vilsu221 requested a review from a team as a code owner January 16, 2025 20:55

@wizjany wizjany left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

In general, I'm unsure that we actually want all the changes from MC to Sponge classes/methods. Given that most of the Sponge API is just implemented via mixin, the only thing this really accomplishes and pushing the we-sponge code base even further from we-fabric/we-neoforge (making it harder to maintain), and there's several places where sponge classes are just cast back to MC classes anyway.

If this PR just had the block/biome fixes and maybe even the event listener refactor (though see my comments), it would be a lot easier to pull, but right now I feel like there's too much that isn't necessarily a benefit.

Comment thread worldedit-sponge/src/main/java/com/sk89q/worldedit/sponge/SpongeAdapter.java Outdated
Comment thread worldedit-sponge/src/main/java/com/sk89q/worldedit/sponge/SpongeAdapter.java Outdated
Comment thread worldedit-sponge/src/main/java/com/sk89q/worldedit/sponge/SpongeWorldEdit.java Outdated
@Vilsu221

Vilsu221 commented Jan 20, 2025

Copy link
Copy Markdown
Contributor Author

In general, I'm unsure that we actually want all the changes from MC to Sponge classes/methods. Given that most of the Sponge API is just implemented via mixin, the only thing this really accomplishes and pushing the we-sponge code base even further from we-fabric/we-neoforge (making it harder to maintain), and there's several places where sponge classes are just cast back to MC classes anyway.

If this PR just had the block/biome fixes and maybe even the event listener refactor (though see my comments), it would be a lot easier to pull, but right now I feel like there's too much that isn't necessarily a benefit.

In my opinion Sponge API is more "stable" than MC.

@Vilsu221
Vilsu221 requested a review from wizjany January 23, 2025 00:42
@me4502

me4502 commented Jan 23, 2025

Copy link
Copy Markdown
Member

given we're working with multiple platforms that are Minecraft code, from a maintainability perspective it's often better. Any potential benefits are immediately removed by all (from what i can tell) spots where you've swapped over to Sponge code requiring casting back to MC native code anyway.

I agree with wiz in that splitting out the biome & block fixes would be significantly better than this PR as-is. it's doing too much at once, and they're not all changes that make sense for us to merge.

@me4502
me4502 merged commit 77eb614 into EngineHub:version/7.3.x Apr 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants