-
-
Notifications
You must be signed in to change notification settings - Fork 179
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
[1.20.2] Add an event to register custom sprite source types #77
[1.20.2] Add an event to register custom sprite source types #77
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.
This should also have some sort of test to make checking that this works now and in the future possible.
src/main/java/net/minecraftforge/client/event/RegisterSpriteSourceTypesEvent.java
Outdated
Show resolved
Hide resolved
c4b1b11
to
116af92
Compare
src/main/java/net/minecraftforge/client/event/RegisterSpriteSourceTypesEvent.java
Outdated
Show resolved
Hide resolved
src/main/java/net/minecraftforge/client/event/RegisterSpriteSourceTypesEvent.java
Outdated
Show resolved
Hide resolved
src/main/java/net/minecraftforge/client/event/RegisterSpriteSourceTypesEvent.java
Outdated
Show resolved
Hide resolved
6cdb716
to
11db25c
Compare
11db25c
to
3bc2c25
Compare
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.
Can you also update the CustomTASTest
testmod with this PR?
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.
Just some internal markings and it looks good to go. Figured they should be added since we shouldn't be firing this event outside of the NeoForged startup.
src/main/java/net/neoforged/neoforge/client/event/RegisterSpriteSourceTypesEvent.java
Show resolved
Hide resolved
3bc2c25
to
a35d9d2
Compare
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.
Two rather nitpicky things, but other than that it works great in my testing
tests/src/main/java/net/neoforged/neoforge/debug/client/CustomSpriteSourceTest.java
Outdated
Show resolved
Hide resolved
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.
See comments, plus: This PR needs documentation in the PR message, what can you do with these changes, how is it supposed to be used etc.
src/main/java/net/neoforged/neoforge/client/event/RegisterSpriteSourceTypesEvent.java
Show resolved
Hide resolved
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.
Mainly documentation issues.
patches/net/minecraft/client/renderer/texture/atlas/SpriteResourceLoader.java.patch
Outdated
Show resolved
Hide resolved
src/main/java/net/neoforged/neoforge/client/event/RegisterSpriteSourceTypesEvent.java
Outdated
Show resolved
Hide resolved
src/main/java/net/neoforged/neoforge/client/textures/SpriteContentConstructor.java
Outdated
Show resolved
Hide resolved
src/main/java/net/neoforged/neoforge/client/textures/SpriteContentConstructor.java
Outdated
Show resolved
Hide resolved
tests/src/main/java/net/neoforged/neoforge/debug/client/CustomSpriteSourceTest.java
Show resolved
Hide resolved
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.
Sure, this is good enough for now.
997cfa8
to
96bbe2f
Compare
1f8dcd9
to
9aca096
Compare
…eoforged#77)" This reverts commit 2f87365.
This PR makes it possible to register custom
SpriteSource
types and load customSpriteContents
from them.