-
Notifications
You must be signed in to change notification settings - Fork 11
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
Introduce Capability system #112
Conversation
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.
The docs definitely need rewording as they're quite confusing in places, I'll try to do it later today
src/main/java/com/gtnewhorizon/gtnhlib/capability/CapabilityUtil.java
Outdated
Show resolved
Hide resolved
src/main/java/com/gtnewhorizon/gtnhlib/capability/ICapabilityProvider.java
Outdated
Show resolved
Hide resolved
Some examples like for some vanilla stuff would be useful |
Warning: 2 uncommitted changes |
src/main/java/com/gtnewhorizon/gtnhlib/capability/CapabilityUtil.java
Outdated
Show resolved
Hide resolved
Now it's reworked and significantly simplified thanks to Raven. Please take another look.
As written on Javadoc, usage of vanilla/Forge interfaces as capability is discouraged. |
This PR introduces Capability system.
For those who don't know about Capability
Please read Javadoc. If there's anything unclear, feel free to ask questions.
For those who are familiar with Capability in later MC versions
This PR was originally based on 1.12.2 Forge implementation. After that Raven's suggestion drastically simplified it. Now
Capability
class is gone and there're onlyCapabilityProvider
andCapabilities
.Side note, due to skill issue I used generative AI to generate documents. While I used multiple models, read everything they outputted and tweaked sentences, there could still be oddities.