Skip to content

Commit

Permalink
Update to 1.17.1
Browse files Browse the repository at this point in the history
  • Loading branch information
Patbox committed Jul 6, 2021
1 parent 529309b commit c931556
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 9 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ dependencies {

modImplementation include("xyz.nucleoid:packet-tweaker:0.2.0-1.17-pre1")

modRuntime "fr.catcore:server-translations-api:1.4.4+1.17"
modRuntime "fr.catcore:server-translations-api:1.4.5+1.17"

// PSA: Some older mods, compiled on Loom 0.2.1, might have outdated Maven POMs.
// You may need to force-disable transitiveness on them.
Expand Down
8 changes: 4 additions & 4 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@ org.gradle.jvmargs=-Xmx1G

# Fabric Properties
# check these on https://fabricmc.net/use
minecraft_version=1.17
yarn_mappings=1.17+build.9
minecraft_version=1.17.1
yarn_mappings=1.17.1+build.1
loader_version=0.11.3

# Mod Properties
mod_version = 0.1.0-pre5-1.17
mod_version = 0.1.0-pre6+1.17.1
maven_group = eu.pb4
archives_base_name = polymer

# Dependencies
# currently not on the main fabric site, check on the maven: https://maven.fabricmc.net/net/fabricmc/fabric-api/fabric-api
fabric_version=0.36.0+1.17
fabric_version=0.36.1+1.17
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public abstract class ServerChunkManagerMixin {
@Nullable
public abstract WorldChunk getWorldChunk(int chunkX, int chunkZ);

@Shadow @Final private ServerLightingProvider lightProvider;
@Shadow @Final private ServerLightingProvider lightingProvider;
@Unique
private final Object2LongArrayMap<ChunkSectionPos> lastUpdates = new Object2LongArrayMap<>();

Expand Down Expand Up @@ -89,7 +89,7 @@ private void sendLightUpdates(LightType type, ChunkSectionPos pos, CallbackInfo

if (sendUpdate) {
BitSet bitSet = new BitSet();
bitSet.set(pos.getSectionY() - this.lightProvider.getBottomY());
bitSet.set(pos.getSectionY() - this.lightingProvider.getBottomY());
Packet<?> packet = new LightUpdateS2CPacket(pos.toChunkPos(), this.getLightingProvider(), new BitSet(this.world.getTopSectionCoord() + 2), bitSet, true);
Set<ServerPlayerEntity> players = this.threadedAnvilChunkStorage.getPlayersWatchingChunk(pos.toChunkPos(), false).collect(Collectors.toSet());
if (players.size() > 0) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ private void resendToolIfItsBlockClientSide(PlayerInteractBlockC2SPacket packet,
ItemStack itemStack = this.player.getStackInHand(packet.getHand());

if (itemStack.getItem() instanceof VirtualItem && (((VirtualItem) itemStack.getItem()).getVirtualItem() instanceof BlockItem || ((VirtualItem) itemStack.getItem()).getVirtualItem() instanceof BucketItem)) {
this.sendPacket(new ScreenHandlerSlotUpdateS2CPacket(this.player.playerScreenHandler.syncId, packet.getHand() == Hand.MAIN_HAND ? 36 + this.player.getInventory().selectedSlot : 45, itemStack));
this.sendPacket(new ScreenHandlerSlotUpdateS2CPacket(this.player.playerScreenHandler.syncId, this.player.playerScreenHandler.nextRevision(), packet.getHand() == Hand.MAIN_HAND ? 36 + this.player.getInventory().selectedSlot : 45, itemStack));
}
}

Expand Down Expand Up @@ -80,15 +80,19 @@ private void resendArmorIfNeeded(ClickSlotC2SPacket packet, CallbackInfo ci) {
for (ItemStack stack : this.player.getInventory().armor) {
if (stack.getItem() instanceof VirtualItem && !ItemStack.areEqual(this.armorItems.get(x), stack)) {
this.sendPacket(new ScreenHandlerSlotUpdateS2CPacket(this.player.playerScreenHandler.syncId,
this.player.playerScreenHandler.nextRevision(),
8 - x,
stack));

if (packet.getSlot() != 8 - x) {
this.sendPacket(new ScreenHandlerSlotUpdateS2CPacket(this.player.playerScreenHandler.syncId, packet.getSlot(),
this.sendPacket(new ScreenHandlerSlotUpdateS2CPacket(this.player.playerScreenHandler.syncId,
this.player.playerScreenHandler.nextRevision(),
packet.getSlot(),
this.player.playerScreenHandler.getSlot(packet.getSlot()).getStack()));
}

this.sendPacket(new ScreenHandlerSlotUpdateS2CPacket(-1,
0,
0,
this.player.currentScreenHandler.getCursorStack()));
return;
Expand Down

0 comments on commit c931556

Please sign in to comment.