-
Notifications
You must be signed in to change notification settings - Fork 5
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
Treat CAVE_AIR just like normal AIR blocks #92
Conversation
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
Thank you, unfortunately that probably stops the plugin from working in older versions where Material.CAVE_AIR doesn't exist. If you can't change that I will try to test it and adjust your PR,, thank you either way though since getting a new PR is very rare |
@ChanceSD Thanks for this, sorry that I didn't see your comment until now! I'll look into adapting this to XMaterial and update the PR. |
Update - I made the changes but still need to test them, I'll get that done this week. |
@fuhry Any update on this? No problem if not |
@ChanceSD I haven't had a chance to actually test this yet. Do you still need that done? |
I didn't try it either tbh |
I've finally gotten around to testing this now that 1.20 is released. I'm getting the "the from location is not air" message with both Edit: I was missing a |
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
@ChanceSD Just wanted to let you know this should now be ready to merge! I've noticed a couple of other issues, which I'm fairly certain are separate. If you think any could be regressions introduced by this PR, can you let me know? Otherwise I'll file separate issues and pull requests for them.
Have a feeling 2 and 3 are related, and maybe 1 is intended to prevent 2 and 3 from happening, will peek into the Bukkit/Spigot APIs to see if flow recalc can be inhibited directly. |
bump |
@@ -28,7 +28,7 @@ public class BlockUtil { | |||
standableMaterials = new EnumMap<>(Material.class); | |||
try { | |||
Arrays.asList(GateMaterial.values()).stream().forEach(x -> standableMaterials.put(x.getMaterial(), true)); | |||
standableMaterials.put(Material.AIR, true); // 0 Air | |||
standableMaterials.put(XMaterial.AIR.parseMaterial(), true); // 0 Air |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe it would be necessary to add CAVE_AIR to the standable materials as well, not entirely sure if it would make a difference.
Sorry, it's been so long, I will fix the conflicts and merge it soon. |
Recently, Minecraft began using CAVE_AIR for air blocks inside of caves, however AncientGates presently does not recognize this as air and refuses to construct portals inside of caves. This PR resolves this issue by using `XBlock.isAir()` instead of direct block material comparison.
67643e2
to
cef4697
Compare
Quality Gate passedIssues Measures |
Should be good, merging now, thank you for your contribution! |
Recently, Minecraft began using CAVE_AIR for air blocks inside of caves, however AncientGates presently does not recognize this as air and refuses to construct portals inside of caves.
This PR resolves this issue. It has been successfully tested on a server running Minecraft 1.20 with no issues.