-
-
Notifications
You must be signed in to change notification settings - Fork 186
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Massively simplify the internals of how stuff is registered.
- Loading branch information
1 parent
85cd3e0
commit 53449a9
Showing
17 changed files
with
246 additions
and
295 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
src/main/java/net/neoforged/neoforge/network/payload/ConfigFilePayload.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
package net.neoforged.neoforge.network.payload; | ||
|
||
import net.minecraft.network.FriendlyByteBuf; | ||
import net.minecraft.network.protocol.common.custom.CustomPacketPayload; | ||
import net.minecraft.resources.ResourceLocation; | ||
|
||
public record ConfigFilePayload() implements CustomPacketPayload { | ||
@Override | ||
public void write(FriendlyByteBuf p_294947_) { | ||
|
||
} | ||
|
||
@Override | ||
public ResourceLocation id() { | ||
return null; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 0 additions & 28 deletions
28
...ava/net/neoforged/neoforge/network/registration/registrar/IFlowBasedPayloadRegistrar.java
This file was deleted.
Oops, something went wrong.
16 changes: 16 additions & 0 deletions
16
...t/neoforged/neoforge/network/registration/registrar/INetworkPayloadVersioningBuilder.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
package net.neoforged.neoforge.network.registration.registrar; | ||
|
||
public interface INetworkPayloadVersioningBuilder { | ||
|
||
INetworkPayloadVersioningBuilder withVersion(int version); | ||
|
||
INetworkPayloadVersioningBuilder withMinimalVersion(int min); | ||
|
||
INetworkPayloadVersioningBuilder withMaximalVersion(int max); | ||
|
||
INetworkPayloadVersioningBuilder optional(); | ||
|
||
default INetworkPayloadVersioningBuilder withAcceptableRange(int min, int max) { | ||
return withMinimalVersion(min).withMaximalVersion(max); | ||
} | ||
} |
Oops, something went wrong.