PatchworkMC / patchwork-api

An attempt to reimplement the Minecraft Forge API on Fabric
GNU Lesser General Public License v2.1
282 stars 48 forks source link

Implement ForgeHooks, ForgeEventFactory, etc. #115

Closed kitlith closed 4 years ago

kitlith commented 4 years ago

Doesn't immediately fix the mod listed in #21 as that specific event either doesn't have a method in EntityEvents or isn't implemented yet. Lays some foundataion I guess.

The PR isn't done yet (gotta check the rest of the events modules at least), but I figured I'd get the bikeshed party started early since I've reached a place where it makes sense to pause.

kitlith commented 4 years ago

Alright, I think that covers the trivial redirects. The question now is, how do we want to handle e.g. events that are already implemented but are dispatched directly from mixins instead of through a class? We could either dispatch the event directly from the hook, or we could reorganize those mixins to call into a class that ForgeHooks also delegates to.

TheGlitch76 commented 4 years ago

Reorg the mixins to call from a PatchworkXEvents, and then call from there. That should be a separate PR, though.

kitlith commented 4 years ago

I'm splitting this into seperate PRs: