Was busy mapping stuff last week, here's the combined update documentation!
Fabric Loader 0.14.22 was released with a small change to version handling.
Fabric API has received several breaking changes in both versions.
Networking API's implementation was reworked based on Mojang's changes. While the API breakage is minimum, the packet protocol it uses is different from the older one.
Mojang introduced "configuration phase" - a phase between LOGIN and PLAY. This phase can be used to configure the client before the player joins (i.e. before ServerPlayerEntity
instance is created). Networking API now establishes networking channels during this phase, instead of LOGIN, which should improve compatibility with proxies. Channel establishment allows one side of the connection to detect whether the other side can receive a packet before sending one.
In addition, a mod can use the configuration phase to send its own packet. Note that during this phase, PlayerEntity
instance does not exist. The API will be improved in a future update, stay tuned!
One API breaking change: ClientPlayNetworking#createC2SPacket
and ServerPlayNetworking#createS2CPacket
's return types have changed. These now return Packet<ServerCommonPacketListener>
instead of Packet<ServerPlayPacketListener>
.
RegSync now uses configuration phase to sync registry.
In 23w32a, the status effects were changed to use a string ID instead of integer (raw) ID when saving. This was the last bit of the registry using raw ID in a persistent manner; this means that Registry Sync no longer has to save the raw ID on a file. API-wise, this means RegistryAttribute#PERSISTED
is removed.
These deprecated APIs were removed:
fabric-networking-v0
fabric-loot-tables-v1
LootEntryTypeRegistry
fromfabric-content-registries-v0
Here are some noteworthy changes:
onMouseScrolled
method now takes both horizontal and vertical scroll amount.- Texture rendering methods have changed;
drawTexture
calls should be replaced withdrawGuiTexture
. Note that since the game no longer uses atlases in GUI textures, there is no need to specify UV. renderBackground
method now takes mouse positions andtickDelta
.- Several networking classes have been renamed or repackaged.
- When using
PersistentState
, you must now create aType
instance, which includes the deserializer and data fix type.