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

WorldGuard-Folia #2060

Draft
wants to merge 56 commits into
base: master
Choose a base branch
from

Conversation

Yomamaeatstoes
Copy link

Feel free to edit whatever you want on this, or deny it.

If you have any requested changes let me know. I have been using this for the better part of a couple months. Perhaps like 4.

@Yomamaeatstoes
Copy link
Author

I see there is already a WorldGuard folia so perhaps you want to go with that one. Either way, it is alright.

Copy link
Collaborator

@Joo200 Joo200 left a comment

Choose a reason for hiding this comment

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

This is a duplicate of #2012

That PR doesn't look like it's finished and there are a lot of removed code in comments. #2012 has some other flaws but looks better over all.

However without proper WorldEdit support there will be no WorldGuard support for Folia.

README.md Outdated
Comment on lines 40 to 44
# Folia Inquisitors
[<img src="https://github.com/Folia-Inquisitors.png" width=80 alt="Folia-Inquisitors">](https://github.com/orgs/Folia-Inquisitors/repositories)
[<img src="https://github.com/TechnicallyCoded.png" width=80 alt="TechnicallyCoded">](https://github.com/TechnicallyCoded)
[<img src="https://github.com/Yomamaeatstoes.png" width=80 alt="Yomamaeatstoes">](https://github.com/Yomamaeatstoes)

Copy link
Collaborator

Choose a reason for hiding this comment

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

Same as in WorldEdit:
EngineHub/WorldEdit#2462 (comment)

Copy link
Author

Choose a reason for hiding this comment

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

Heyy @Joo200 I have updated it. What do you think of it now?

gradle.properties Outdated Show resolved Hide resolved
worldguard-bukkit/build.gradle.kts Outdated Show resolved Hide resolved
@@ -52,19 +53,22 @@ public Optional<Field> load(Class<?> clazz) throws Exception {
public SchedulerReport() {
super("Scheduler");

List<BukkitTask> tasks = Bukkit.getServer().getScheduler().getPendingTasks();
append("Error", "MODDED FOLIA VERSION - DO NOT REPORT TO WORLDGUARD");
Copy link
Collaborator

Choose a reason for hiding this comment

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

That looks like it's not finished yet? Please don't remove the whole report.

Copy link
Author

Choose a reason for hiding this comment

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

Whoops, sorry about that. Originally I wasn’t intending to PR it so I put a comment there so people wouldn’t spam you guys if they found my fork. It seems I forgot to remove that comment.

Choose a reason for hiding this comment

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

Having looked closer into this, until TechnicallyCoded adds a method to getAllWrappedTasks either active or pending. I will contact him as he is a work colleague.

worldguard-bukkit/src/main/resources/plugin.yml Outdated Show resolved Hide resolved
Loving11ish and others added 2 commits January 28, 2024 23:41
…rldGuardPlugin.java. Fixed cancelling of Bukkit tasks if not running on Folia. Made SessionManager task async. Updated PaperAPI to 1.20.2. Fixed plugin.yml formatting. Updated README.md to reflect new project member(@Loving11ish).
Updated FoliaLib dependency. Fixed ProcessPlayerEvent scheduler in Wo…
@Yomamaeatstoes Yomamaeatstoes marked this pull request as draft January 29, 2024 16:35
Loving11ish and others added 23 commits February 6, 2024 02:37
…rReport.java. Re-added Bukkit task reports in SchedulerReport.java.
* Fix silent flag for gameplay commands

This issue has been fixed in CommandBook with
EngineHub/CommandBook@6448031
but never in WorldGuard.

Co-authored-by: Wyatt Childers <[email protected]>

* codestyle
* Fix checking bypass on initialize

* Add SessionManager#createSession back as deprecated
* Fix ItemStack conversion on block place

This issue is present in 1.21 because some materials do not convert 1:1 to item types.
This throws an exception in the ItemStack constructor.
Example: WALL_TORCH is a valid block but not a valid item, only TORCH is a valid item.

So, use the item in hand instead, creating a copy with quantity set to 1, for issueing the
use item event.

* Use ItemStack as-is.

Closes EngineHub#2092.

---------

Co-authored-by: wizjany <[email protected]>
* Fix compilation for MC 1.21. Nothing tested yet.

* Update Materials.java with 1.21 tags and materials

* Fix ItemStack conversion on block place on MC 1.21 (EngineHub#2093)

* Fix ItemStack conversion on block place

This issue is present in 1.21 because some materials do not convert 1:1 to item types.
This throws an exception in the ItemStack constructor.
Example: WALL_TORCH is a valid block but not a valid item, only TORCH is a valid item.

So, use the item in hand instead, creating a copy with quantity set to 1, for issueing the
use item event.

* Use ItemStack as-is.

Closes EngineHub#2092.

* Fix ItemStack conversion for spigot compatibility

* Special handling for WindCharges

* Do not call as a bulk event, because it has to check every blocks type

* WindCharge -> AbstractWindCharge

* Fix UseBlockFlag for multiple uses at the same time, add windburst-flag

* Cleanup code

* Handle vaults as use, crafters as chest-access.

---------

Co-authored-by: Joo200 <[email protected]>
Co-authored-by: Lennart <[email protected]>
Co-authored-by: Brokkonaut <[email protected]>
Idk why we even to this for betas, they're not getting a maven release.
aurorasmiles and others added 29 commits July 21, 2024 23:17
Definitely did not accidentally make a 40MB jar halfway through.
There's no tag which has wood+copper, but iron are not interactable anyway.

Relates to EngineHub#2130.
Note that bypass bypasses this if the player with bypass is the target of the potion, but only for the player with bypass.

Fixes EngineHub#2134.
Player flag is build-checked (default false) and breeze flag is not (default true).

Having multiple flags is ugly but if we need every bit of behavior to be manipulable this is the only way.
…tuff

Optimize and cleanup explosion events from entities

Fixes EngineHub#2099 and EngineHub#2097
* Create and implement moisture-change flag

* Fix imports

* Add comment

* Actually read the value from config.

Closes EngineHub#1879 

---------

Co-authored-by: wizjany <[email protected]>
Also update the changelog.
Event abstraction sucks and everything needs rewriting.
This is already past the debounce so in theory it's not getting hit *often*, but I guess if it's really slow it'll still show up.
* Avoid using metadata storage if possible

* Fix cause detection, use always on paper

* Fix fat fingers

Co-authored-by: aurora <[email protected]>
Entire command should eventually be removed.
Also this was supposed to be on a branch but I just realized I forgot.
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.