mirror of
https://github.com/Nan1t/NanoLimbo.git
synced 2025-07-16 22:20:14 +02:00
Compare commits
6 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
a5b9e3510d | ||
|
155e6cc6c3 | ||
|
b99a533e1a | ||
|
94edb65dac | ||
|
48346762bf | ||
|
402484c838 |
@ -35,7 +35,8 @@ Symbol `X` means all minor versions.
|
|||||||
- [x] 1.17.X
|
- [x] 1.17.X
|
||||||
- [x] 1.18.X
|
- [x] 1.18.X
|
||||||
- [x] 1.19.X
|
- [x] 1.19.X
|
||||||
- [x] 1.20-1.20.6
|
- [x] 1.20.X
|
||||||
|
- [x] 1.21
|
||||||
|
|
||||||
The server **doesn't** support snapshots.
|
The server **doesn't** support snapshots.
|
||||||
|
|
||||||
@ -50,6 +51,8 @@ Note that the server also will be closed correctly if you just press `Ctrl+C`.
|
|||||||
|
|
||||||
### Installation
|
### Installation
|
||||||
|
|
||||||
|
Required software: JRE 11+
|
||||||
|
|
||||||
The installation process is simple.
|
The installation process is simple.
|
||||||
|
|
||||||
1. Download the latest version of the program [**here**](https://github.com/Nan1t/NanoLimbo/releases).
|
1. Download the latest version of the program [**here**](https://github.com/Nan1t/NanoLimbo/releases).
|
||||||
@ -82,7 +85,7 @@ to add some functionality that is suitable for a limbo server and won't signific
|
|||||||
|
|
||||||
Required software:
|
Required software:
|
||||||
|
|
||||||
* JDK 1.8+
|
* JDK 11+
|
||||||
* Gradle 7+ (optional)
|
* Gradle 7+ (optional)
|
||||||
|
|
||||||
To build a minimized jar, go to the project root directory and run in the terminal:
|
To build a minimized jar, go to the project root directory and run in the terminal:
|
||||||
|
@ -5,7 +5,7 @@ plugins {
|
|||||||
}
|
}
|
||||||
|
|
||||||
group 'ua.nanit'
|
group 'ua.nanit'
|
||||||
version '1.8'
|
version '1.8.1'
|
||||||
|
|
||||||
compileJava {
|
compileJava {
|
||||||
options.encoding = "UTF-8"
|
options.encoding = "UTF-8"
|
||||||
|
@ -199,16 +199,16 @@ public final class PacketSnapshots {
|
|||||||
|
|
||||||
PACKET_REGISTRY_DATA = PacketSnapshot.of(packetRegistryData);
|
PACKET_REGISTRY_DATA = PacketSnapshot.of(packetRegistryData);
|
||||||
|
|
||||||
Dimension dimension1_20_5 = server.getDimensionRegistry().getDimension_1_20_5();
|
Dimension dimension1_21 = server.getDimensionRegistry().getDimension_1_21();
|
||||||
List<PacketSnapshot> packetRegistries = new ArrayList<>();
|
List<PacketSnapshot> packetRegistries = new ArrayList<>();
|
||||||
CompoundBinaryTag dimensionTag = dimension1_20_5.getData();
|
CompoundBinaryTag dimensionTag = dimension1_21.getData();
|
||||||
for (String registryType : dimensionTag.keySet()) {
|
for (String registryType : dimensionTag.keySet()) {
|
||||||
CompoundBinaryTag compundRegistryType = dimensionTag.getCompound(registryType);
|
CompoundBinaryTag compoundRegistryType = dimensionTag.getCompound(registryType);
|
||||||
|
|
||||||
PacketRegistryData registryData = new PacketRegistryData();
|
PacketRegistryData registryData = new PacketRegistryData();
|
||||||
registryData.setDimensionRegistry(server.getDimensionRegistry());
|
registryData.setDimensionRegistry(server.getDimensionRegistry());
|
||||||
|
|
||||||
ListBinaryTag values = compundRegistryType.getList("value");
|
ListBinaryTag values = compoundRegistryType.getList("value");
|
||||||
registryData.setMetadataWriter((message, version) -> {
|
registryData.setMetadataWriter((message, version) -> {
|
||||||
message.writeString(registryType);
|
message.writeString(registryType);
|
||||||
|
|
||||||
|
@ -66,7 +66,7 @@ public enum State {
|
|||||||
);
|
);
|
||||||
serverBound.register(
|
serverBound.register(
|
||||||
PacketLoginAcknowledged::new,
|
PacketLoginAcknowledged::new,
|
||||||
map(0x03, V1_20_2, V1_20_5)
|
map(0x03, V1_20_2, Version.getMax())
|
||||||
);
|
);
|
||||||
clientBound.register(PacketDisconnect::new,
|
clientBound.register(PacketDisconnect::new,
|
||||||
map(0x00, Version.getMin(), Version.getMax())
|
map(0x00, Version.getMin(), Version.getMax())
|
||||||
@ -84,43 +84,43 @@ public enum State {
|
|||||||
clientBound.register(
|
clientBound.register(
|
||||||
PacketPluginMessage::new,
|
PacketPluginMessage::new,
|
||||||
map(0x00, V1_20_2, V1_20_3),
|
map(0x00, V1_20_2, V1_20_3),
|
||||||
map(0x01, V1_20_5, V1_20_5)
|
map(0x01, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(
|
clientBound.register(
|
||||||
PacketDisconnect::new,
|
PacketDisconnect::new,
|
||||||
map(0x01, V1_20_2, V1_20_3),
|
map(0x01, V1_20_2, V1_20_3),
|
||||||
map(0x02, V1_20_5, V1_20_5)
|
map(0x02, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(
|
clientBound.register(
|
||||||
PacketFinishConfiguration::new,
|
PacketFinishConfiguration::new,
|
||||||
map(0x02, V1_20_2, V1_20_3),
|
map(0x02, V1_20_2, V1_20_3),
|
||||||
map(0x03, V1_20_5, V1_20_5)
|
map(0x03, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(
|
clientBound.register(
|
||||||
PacketKeepAlive::new,
|
PacketKeepAlive::new,
|
||||||
map(0x03, V1_20_2, V1_20_3),
|
map(0x03, V1_20_2, V1_20_3),
|
||||||
map(0x04, V1_20_5, V1_20_5)
|
map(0x04, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(
|
clientBound.register(
|
||||||
PacketRegistryData::new,
|
PacketRegistryData::new,
|
||||||
map(0x05, V1_20_2, V1_20_3),
|
map(0x05, V1_20_2, V1_20_3),
|
||||||
map(0x07, V1_20_5, V1_20_5)
|
map(0x07, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
|
|
||||||
serverBound.register(
|
serverBound.register(
|
||||||
PacketPluginMessage::new,
|
PacketPluginMessage::new,
|
||||||
map(0x01, V1_20_2, V1_20_3),
|
map(0x01, V1_20_2, V1_20_3),
|
||||||
map(0x02, V1_20_2, V1_20_5)
|
map(0x02, V1_20_2, V1_21)
|
||||||
);
|
);
|
||||||
serverBound.register(
|
serverBound.register(
|
||||||
PacketFinishConfiguration::new,
|
PacketFinishConfiguration::new,
|
||||||
map(0x02, V1_20_2, V1_20_3),
|
map(0x02, V1_20_2, V1_20_3),
|
||||||
map(0x03, V1_20_5, V1_20_5)
|
map(0x03, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
serverBound.register(
|
serverBound.register(
|
||||||
PacketKeepAlive::new,
|
PacketKeepAlive::new,
|
||||||
map(0x03, V1_20_2, V1_20_3),
|
map(0x03, V1_20_2, V1_20_3),
|
||||||
map(0x04, V1_20_5, V1_20_5)
|
map(0x04, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -141,7 +141,7 @@ public enum State {
|
|||||||
map(0x12, V1_19_4, V1_20),
|
map(0x12, V1_19_4, V1_20),
|
||||||
map(0x14, V1_20_2, V1_20_2),
|
map(0x14, V1_20_2, V1_20_2),
|
||||||
map(0x15, V1_20_3, V1_20_3),
|
map(0x15, V1_20_3, V1_20_3),
|
||||||
map(0x18, V1_20_5, V1_20_5)
|
map(0x18, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
|
|
||||||
clientBound.register(PacketDeclareCommands::new,
|
clientBound.register(PacketDeclareCommands::new,
|
||||||
@ -153,7 +153,7 @@ public enum State {
|
|||||||
map(0x0F, V1_19, V1_19_1),
|
map(0x0F, V1_19, V1_19_1),
|
||||||
map(0x0E, V1_19_3, V1_19_3),
|
map(0x0E, V1_19_3, V1_19_3),
|
||||||
map(0x10, V1_19_4, V1_20),
|
map(0x10, V1_19_4, V1_20),
|
||||||
map(0x11, V1_20_2, V1_20_5)
|
map(0x11, V1_20_2, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketJoinGame::new,
|
clientBound.register(PacketJoinGame::new,
|
||||||
map(0x01, V1_7_2, V1_8),
|
map(0x01, V1_7_2, V1_8),
|
||||||
@ -168,7 +168,7 @@ public enum State {
|
|||||||
map(0x24, V1_19_3, V1_19_3),
|
map(0x24, V1_19_3, V1_19_3),
|
||||||
map(0x28, V1_19_4, V1_20),
|
map(0x28, V1_19_4, V1_20),
|
||||||
map(0x29, V1_20_2, V1_20_3),
|
map(0x29, V1_20_2, V1_20_3),
|
||||||
map(0x2B, V1_20_5, V1_20_5)
|
map(0x2B, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketPluginMessage::new,
|
clientBound.register(PacketPluginMessage::new,
|
||||||
map(0x19, V1_13, V1_13_2),
|
map(0x19, V1_13, V1_13_2),
|
||||||
@ -182,7 +182,7 @@ public enum State {
|
|||||||
map(0x15, V1_19_3, V1_19_3),
|
map(0x15, V1_19_3, V1_19_3),
|
||||||
map(0x17, V1_19_4, V1_20),
|
map(0x17, V1_19_4, V1_20),
|
||||||
map(0x18, V1_20_2, V1_20_3),
|
map(0x18, V1_20_2, V1_20_3),
|
||||||
map(0x19, V1_20_5, V1_20_5)
|
map(0x19, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketPlayerAbilities::new,
|
clientBound.register(PacketPlayerAbilities::new,
|
||||||
map(0x39, V1_7_2, V1_8),
|
map(0x39, V1_7_2, V1_8),
|
||||||
@ -199,7 +199,7 @@ public enum State {
|
|||||||
map(0x30, V1_19_3, V1_19_3),
|
map(0x30, V1_19_3, V1_19_3),
|
||||||
map(0x34, V1_19_4, V1_20),
|
map(0x34, V1_19_4, V1_20),
|
||||||
map(0x36, V1_20_2, V1_20_3),
|
map(0x36, V1_20_2, V1_20_3),
|
||||||
map(0x38, V1_20_5, V1_20_5)
|
map(0x38, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketPlayerPositionAndLook::new,
|
clientBound.register(PacketPlayerPositionAndLook::new,
|
||||||
map(0x08, V1_7_2, V1_8),
|
map(0x08, V1_7_2, V1_8),
|
||||||
@ -216,7 +216,7 @@ public enum State {
|
|||||||
map(0x38, V1_19_3, V1_19_3),
|
map(0x38, V1_19_3, V1_19_3),
|
||||||
map(0x3C, V1_19_4, V1_20),
|
map(0x3C, V1_19_4, V1_20),
|
||||||
map(0x3E, V1_20_2, V1_20_3),
|
map(0x3E, V1_20_2, V1_20_3),
|
||||||
map(0x40, V1_20_5, V1_20_5)
|
map(0x40, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketKeepAlive::new,
|
clientBound.register(PacketKeepAlive::new,
|
||||||
map(0x00, V1_7_2, V1_8),
|
map(0x00, V1_7_2, V1_8),
|
||||||
@ -232,7 +232,7 @@ public enum State {
|
|||||||
map(0x1F, V1_19_3, V1_19_3),
|
map(0x1F, V1_19_3, V1_19_3),
|
||||||
map(0x23, V1_19_4, V1_20),
|
map(0x23, V1_19_4, V1_20),
|
||||||
map(0x24, V1_20_2, V1_20_3),
|
map(0x24, V1_20_2, V1_20_3),
|
||||||
map(0x26, V1_20_5, V1_20_5)
|
map(0x26, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketChatMessage::new,
|
clientBound.register(PacketChatMessage::new,
|
||||||
map(0x02, V1_7_2, V1_8),
|
map(0x02, V1_7_2, V1_8),
|
||||||
@ -247,7 +247,7 @@ public enum State {
|
|||||||
map(0x64, V1_19_4, V1_20),
|
map(0x64, V1_19_4, V1_20),
|
||||||
map(0x67, V1_20_2, V1_20_2),
|
map(0x67, V1_20_2, V1_20_2),
|
||||||
map(0x69, V1_20_3, V1_20_3),
|
map(0x69, V1_20_3, V1_20_3),
|
||||||
map(0x6C, V1_20_5, V1_20_5)
|
map(0x6C, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketBossBar::new,
|
clientBound.register(PacketBossBar::new,
|
||||||
map(0x0C, V1_9, V1_14_4),
|
map(0x0C, V1_9, V1_14_4),
|
||||||
@ -256,7 +256,7 @@ public enum State {
|
|||||||
map(0x0D, V1_17, V1_18_2),
|
map(0x0D, V1_17, V1_18_2),
|
||||||
map(0x0A, V1_19, V1_19_3),
|
map(0x0A, V1_19, V1_19_3),
|
||||||
map(0x0B, V1_19_4, V1_20),
|
map(0x0B, V1_19_4, V1_20),
|
||||||
map(0x0A, V1_20_2, V1_20_5)
|
map(0x0A, V1_20_2, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketPlayerInfo::new,
|
clientBound.register(PacketPlayerInfo::new,
|
||||||
map(0x38, V1_7_2, V1_8),
|
map(0x38, V1_7_2, V1_8),
|
||||||
@ -273,7 +273,7 @@ public enum State {
|
|||||||
map(0x36, V1_19_3, V1_19_3),
|
map(0x36, V1_19_3, V1_19_3),
|
||||||
map(0x3A, V1_19_4, V1_20),
|
map(0x3A, V1_19_4, V1_20),
|
||||||
map(0x3C, V1_20_2, V1_20_3),
|
map(0x3C, V1_20_2, V1_20_3),
|
||||||
map(0x3E, V1_20_5, V1_20_5)
|
map(0x3E, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketTitleLegacy::new,
|
clientBound.register(PacketTitleLegacy::new,
|
||||||
map(0x45, V1_8, V1_11_1),
|
map(0x45, V1_8, V1_11_1),
|
||||||
@ -292,7 +292,7 @@ public enum State {
|
|||||||
map(0x5F, V1_19_4, V1_20),
|
map(0x5F, V1_19_4, V1_20),
|
||||||
map(0x61, V1_20_2, V1_20_2),
|
map(0x61, V1_20_2, V1_20_2),
|
||||||
map(0x63, V1_20_3, V1_20_3),
|
map(0x63, V1_20_3, V1_20_3),
|
||||||
map(0x65, V1_20_5, V1_20_5)
|
map(0x65, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketTitleSetSubTitle::new,
|
clientBound.register(PacketTitleSetSubTitle::new,
|
||||||
map(0x57, V1_17, V1_17_1),
|
map(0x57, V1_17, V1_17_1),
|
||||||
@ -302,7 +302,7 @@ public enum State {
|
|||||||
map(0x5D, V1_19_4, V1_20),
|
map(0x5D, V1_19_4, V1_20),
|
||||||
map(0x5F, V1_20_2, V1_20_2),
|
map(0x5F, V1_20_2, V1_20_2),
|
||||||
map(0x61, V1_20_3, V1_20_3),
|
map(0x61, V1_20_3, V1_20_3),
|
||||||
map(0x63, V1_20_5, V1_20_5)
|
map(0x63, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketTitleTimes::new,
|
clientBound.register(PacketTitleTimes::new,
|
||||||
map(0x5A, V1_17, V1_17_1),
|
map(0x5A, V1_17, V1_17_1),
|
||||||
@ -312,7 +312,7 @@ public enum State {
|
|||||||
map(0x60, V1_19_4, V1_20),
|
map(0x60, V1_19_4, V1_20),
|
||||||
map(0x62, V1_20_2, V1_20_2),
|
map(0x62, V1_20_2, V1_20_2),
|
||||||
map(0x64, V1_20_3, V1_20_3),
|
map(0x64, V1_20_3, V1_20_3),
|
||||||
map(0x66, V1_20_5, V1_20_5)
|
map(0x66, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketPlayerListHeader::new,
|
clientBound.register(PacketPlayerListHeader::new,
|
||||||
map(0x47, V1_8, V1_8),
|
map(0x47, V1_8, V1_8),
|
||||||
@ -332,22 +332,22 @@ public enum State {
|
|||||||
map(0x65, V1_19_4, V1_20),
|
map(0x65, V1_19_4, V1_20),
|
||||||
map(0x68, V1_20_2, V1_20_2),
|
map(0x68, V1_20_2, V1_20_2),
|
||||||
map(0x6A, V1_20_3, V1_20_3),
|
map(0x6A, V1_20_3, V1_20_3),
|
||||||
map(0x6D, V1_20_5, V1_20_5)
|
map(0x6D, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketSpawnPosition::new,
|
clientBound.register(PacketSpawnPosition::new,
|
||||||
map(0x4C, V1_19_3, V1_19_3),
|
map(0x4C, V1_19_3, V1_19_3),
|
||||||
map(0x50, V1_19_4, V1_20),
|
map(0x50, V1_19_4, V1_20),
|
||||||
map(0x52, V1_20_2, V1_20_2),
|
map(0x52, V1_20_2, V1_20_2),
|
||||||
map(0x54, V1_20_3, V1_20_3),
|
map(0x54, V1_20_3, V1_20_3),
|
||||||
map(0x56, V1_20_5, V1_20_5)
|
map(0x56, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketGameEvent::new,
|
clientBound.register(PacketGameEvent::new,
|
||||||
map(0x20, V1_20_3, V1_20_3),
|
map(0x20, V1_20_3, V1_20_3),
|
||||||
map(0x22, V1_20_5, V1_20_5)
|
map(0x22, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
clientBound.register(PacketEmptyChunk::new,
|
clientBound.register(PacketEmptyChunk::new,
|
||||||
map(0x25, V1_20_3, V1_20_3),
|
map(0x25, V1_20_3, V1_20_3),
|
||||||
map(0x27, V1_20_5, V1_20_5)
|
map(0x27, V1_20_5, V1_21)
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -72,7 +72,9 @@ public enum Version {
|
|||||||
// 1.20.1 has same protocol number
|
// 1.20.1 has same protocol number
|
||||||
V1_20_2(764),
|
V1_20_2(764),
|
||||||
V1_20_3(765),
|
V1_20_3(765),
|
||||||
V1_20_5(766);
|
V1_20_5(766),
|
||||||
|
// 1.20.6 has same protocol number
|
||||||
|
V1_21(767);
|
||||||
|
|
||||||
private static final Map<Integer, Version> VERSION_MAP;
|
private static final Map<Integer, Version> VERSION_MAP;
|
||||||
private static final Version MAX;
|
private static final Version MAX;
|
||||||
|
@ -34,6 +34,7 @@ public final class DimensionRegistry {
|
|||||||
private Dimension defaultDimension_1_16;
|
private Dimension defaultDimension_1_16;
|
||||||
private Dimension defaultDimension_1_18_2;
|
private Dimension defaultDimension_1_18_2;
|
||||||
private Dimension dimension_1_20_5;
|
private Dimension dimension_1_20_5;
|
||||||
|
private Dimension dimension_1_21;
|
||||||
|
|
||||||
private CompoundBinaryTag codec_1_16;
|
private CompoundBinaryTag codec_1_16;
|
||||||
private CompoundBinaryTag codec_1_18_2;
|
private CompoundBinaryTag codec_1_18_2;
|
||||||
@ -41,6 +42,7 @@ public final class DimensionRegistry {
|
|||||||
private CompoundBinaryTag codec_1_19_1;
|
private CompoundBinaryTag codec_1_19_1;
|
||||||
private CompoundBinaryTag codec_1_19_4;
|
private CompoundBinaryTag codec_1_19_4;
|
||||||
private CompoundBinaryTag codec_1_20;
|
private CompoundBinaryTag codec_1_20;
|
||||||
|
private CompoundBinaryTag codec_1_21;
|
||||||
private CompoundBinaryTag oldCodec;
|
private CompoundBinaryTag oldCodec;
|
||||||
|
|
||||||
public DimensionRegistry(LimboServer server) {
|
public DimensionRegistry(LimboServer server) {
|
||||||
@ -71,6 +73,10 @@ public final class DimensionRegistry {
|
|||||||
return codec_1_20;
|
return codec_1_20;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public CompoundBinaryTag getCodec_1_21() {
|
||||||
|
return codec_1_21;
|
||||||
|
}
|
||||||
|
|
||||||
public CompoundBinaryTag getOldCodec() {
|
public CompoundBinaryTag getOldCodec() {
|
||||||
return oldCodec;
|
return oldCodec;
|
||||||
}
|
}
|
||||||
@ -87,20 +93,26 @@ public final class DimensionRegistry {
|
|||||||
return dimension_1_20_5;
|
return dimension_1_20_5;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public Dimension getDimension_1_21() {
|
||||||
|
return dimension_1_21;
|
||||||
|
}
|
||||||
|
|
||||||
public void load(String def) throws IOException {
|
public void load(String def) throws IOException {
|
||||||
|
// On 1.16-1.16.1 different codec format
|
||||||
|
oldCodec = readCodecFile("/dimension/codec_old.snbt");
|
||||||
codec_1_16 = readCodecFile("/dimension/codec_1_16.snbt");
|
codec_1_16 = readCodecFile("/dimension/codec_1_16.snbt");
|
||||||
codec_1_18_2 = readCodecFile("/dimension/codec_1_18_2.snbt");
|
codec_1_18_2 = readCodecFile("/dimension/codec_1_18_2.snbt");
|
||||||
codec_1_19 = readCodecFile("/dimension/codec_1_19.snbt");
|
codec_1_19 = readCodecFile("/dimension/codec_1_19.snbt");
|
||||||
codec_1_19_1 = readCodecFile("/dimension/codec_1_19_1.snbt");
|
codec_1_19_1 = readCodecFile("/dimension/codec_1_19_1.snbt");
|
||||||
codec_1_19_4 = readCodecFile("/dimension/codec_1_19_4.snbt");
|
codec_1_19_4 = readCodecFile("/dimension/codec_1_19_4.snbt");
|
||||||
codec_1_20 = readCodecFile("/dimension/codec_1_20.snbt");
|
codec_1_20 = readCodecFile("/dimension/codec_1_20.snbt");
|
||||||
// On 1.16-1.16.1 different codec format
|
codec_1_21 = readCodecFile("/dimension/codec_1_21.snbt");
|
||||||
oldCodec = readCodecFile("/dimension/codec_old.snbt");
|
|
||||||
|
|
||||||
defaultDimension_1_16 = getDefaultDimension(def, codec_1_16);
|
defaultDimension_1_16 = getDefaultDimension(def, codec_1_16);
|
||||||
defaultDimension_1_18_2 = getDefaultDimension(def, codec_1_18_2);
|
defaultDimension_1_18_2 = getDefaultDimension(def, codec_1_18_2);
|
||||||
|
|
||||||
dimension_1_20_5 = getModernDimension(def, codec_1_20);
|
dimension_1_20_5 = getModernDimension(def, codec_1_20);
|
||||||
|
dimension_1_21 = getModernDimension(def, codec_1_21);
|
||||||
}
|
}
|
||||||
|
|
||||||
private Dimension getDefaultDimension(String def, CompoundBinaryTag tag) {
|
private Dimension getDefaultDimension(String def, CompoundBinaryTag tag) {
|
||||||
@ -148,10 +160,7 @@ public final class DimensionRegistry {
|
|||||||
|
|
||||||
private String streamToString(InputStream in) throws IOException {
|
private String streamToString(InputStream in) throws IOException {
|
||||||
try (BufferedReader bufReader = new BufferedReader(new InputStreamReader(in, StandardCharsets.UTF_8))) {
|
try (BufferedReader bufReader = new BufferedReader(new InputStreamReader(in, StandardCharsets.UTF_8))) {
|
||||||
String content = bufReader.lines()
|
return bufReader.lines().collect(Collectors.joining("\n"));
|
||||||
.collect(Collectors.joining("\n"));
|
|
||||||
|
|
||||||
return content;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
2816
src/main/resources/dimension/codec_1_21.snbt
Normal file
2816
src/main/resources/dimension/codec_1_21.snbt
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user