Skip to content

Commit 34d90f9

Browse files
committed
chore: start update to 24w45a
A couple of changes: - There's a new shadow styling for chat - PlayerList items can have 'showHat' - ItemModel custom data is totally broken - Structures got an added registry access for placement - Chunk Region tickets lost POST_TELEPORT entirely, this might be worth looking into a functional replacement or not - Client menu changes, needs fixing
1 parent b666fd3 commit 34d90f9

File tree

20 files changed

+87
-64
lines changed

20 files changed

+87
-64
lines changed

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ mixinConfigs=mixins.sponge.accessors.json,mixins.sponge.api.json,mixins.sponge.c
1212
mixins.sponge.tracker.json,mixins.sponge.ipforward.json,mixins.sponge.optimization.json
1313
superClassChanges=common.superclasschange
1414

15-
minecraftVersion=1.21.3
15+
minecraftVersion=24w45a
1616
recommendedVersion=0-SNAPSHOT
1717

1818
org.gradle.dependency.verification.console=verbose

gradle/verification-metadata.xml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1232,6 +1232,14 @@
12321232
<sha256 value="d3bfc56998b7db90b46c8909c6c8a222b98437fda196cf5a0ede11c7085d28e2" origin="Generated by Gradle"/>
12331233
</artifact>
12341234
</component>
1235+
<component group="com.mojang" name="authlib" version="6.0.57">
1236+
<artifact name="authlib-6.0.57.jar">
1237+
<sha256 value="e40ec0926a408aa05faf902f05dcde7e5f6255f6eeeb17f1e7ffb68b369d809a" origin="Generated by Gradle"/>
1238+
</artifact>
1239+
<artifact name="authlib-6.0.57.module">
1240+
<sha256 value="81034a34ae135cae2671386a6e763183c6e04a6250b9ed5bd2128faf90dc9c8d" origin="Generated by Gradle"/>
1241+
</artifact>
1242+
</component>
12351243
<component group="com.mojang" name="blocklist" version="1.0.10">
12361244
<artifact name="blocklist-1.0.10.jar">
12371245
<sha256 value="830bfd639c8db49236bbd8e45d3a2b8c96c56ff654a10118654958a6235d4c44" origin="Generated by Gradle"/>

src/accessors/java/org/spongepowered/common/accessor/network/chat/StyleAccessor.java

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,20 +29,22 @@
2929
import net.minecraft.network.chat.Style;
3030
import net.minecraft.network.chat.TextColor;
3131
import net.minecraft.resources.ResourceLocation;
32-
import org.checkerframework.checker.nullness.qual.Nullable;
3332
import org.spongepowered.asm.mixin.Mixin;
3433
import org.spongepowered.asm.mixin.gen.Accessor;
3534
import org.spongepowered.asm.mixin.gen.Invoker;
3635
import org.spongepowered.common.UntransformedInvokerError;
3736

37+
import javax.annotation.Nullable;
38+
import java.util.Optional;
39+
3840
@Mixin(Style.class)
3941
public interface StyleAccessor {
4042

4143
@Invoker("<init>")
42-
static Style invoker$new(final @Nullable TextColor color, final @Nullable Boolean bold, final @Nullable Boolean italic,
43-
final @Nullable Boolean underlined, final @Nullable Boolean strikethrough, final @Nullable Boolean obfuscated,
44-
final @Nullable ClickEvent clickEvent, final @Nullable HoverEvent hoverEvent, final @Nullable String insertion,
45-
final @Nullable ResourceLocation font) {
44+
static Style invoker$new(final @Nullable TextColor color, final @Nullable Integer shadowColor, final @Nullable Boolean bold, final @Nullable Boolean italic,
45+
final @Nullable Boolean underlined, final @Nullable Boolean strikethrough, final @Nullable Boolean obfuscated,
46+
final @Nullable ClickEvent clickEvent, final @Nullable HoverEvent hoverEvent, final @Nullable String insertion,
47+
final @Nullable ResourceLocation font) {
4648
throw new UntransformedInvokerError();
4749
}
4850

src/accessors/java/org/spongepowered/common/accessor/network/protocol/game/ServerboundMoveVehiclePacketAccessor.java

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,15 @@
2525
package org.spongepowered.common.accessor.network.protocol.game;
2626

2727
import net.minecraft.network.protocol.game.ServerboundMoveVehiclePacket;
28+
import net.minecraft.world.phys.Vec3;
2829
import org.spongepowered.asm.mixin.Mixin;
2930
import org.spongepowered.asm.mixin.Mutable;
3031
import org.spongepowered.asm.mixin.gen.Accessor;
3132

3233
@Mixin(ServerboundMoveVehiclePacket.class)
3334
public interface ServerboundMoveVehiclePacketAccessor {
3435

35-
@Accessor("x") @Mutable void accessor$x(final double x);
36-
37-
@Accessor("y") @Mutable void accessor$y(final double y);
38-
39-
@Accessor("z") @Mutable void accessor$z(final double z);
36+
@Accessor("position") @Mutable void accessor$position(final Vec3 position);
4037

4138
@Accessor("yRot") @Mutable void accessor$yRot(final float yRot);
4239

src/main/java/org/spongepowered/common/data/provider/item/stack/ArmorItemStackData.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ public static void register(final DataProviderRegistrator registrator) {
5454
if (equippable == null) {
5555
return null;
5656
}
57-
return equippable.model()
57+
return equippable.assetId()
5858
.map(rl -> (ResourceKey) (Object) rl)
5959
.flatMap(rk -> RegistryTypes.ARMOR_MATERIAL.get().findEntry(rk))
6060
.map(RegistryEntry::value)

src/main/java/org/spongepowered/common/data/provider/item/stack/ItemStackData.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -117,10 +117,10 @@ public static void register(final DataProviderRegistrator registrator) {
117117
.get(h -> (ItemType) h.getItem().getCraftingRemainder().getItem())
118118
.create(Keys.DISPLAY_NAME)
119119
.get(h -> SpongeAdventure.asAdventure(h.getDisplayName()))
120-
.create(Keys.CUSTOM_MODEL_DATA)
121-
.get(h -> h.getOrDefault(DataComponents.CUSTOM_MODEL_DATA, CustomModelData.DEFAULT).value())
122-
.set((h, v) -> h.set(DataComponents.CUSTOM_MODEL_DATA, new CustomModelData(v)))
123-
.delete(h -> h.remove(DataComponents.CUSTOM_MODEL_DATA))
120+
// .create(Keys.CUSTOM_MODEL_DATA)
121+
// .get(h -> h.getOrDefault(DataComponents.CUSTOM_MODEL_DATA, CustomModelData.EMPTY))
122+
// .set((h, v) -> h.set(DataComponents.CUSTOM_MODEL_DATA, new CustomModelData(v)))
123+
// .delete(h -> h.remove(DataComponents.CUSTOM_MODEL_DATA))
124124
.create(Keys.CUSTOM_NAME)
125125
.get(h -> {
126126
if (h.has(DataComponents.CUSTOM_NAME)) {

src/main/java/org/spongepowered/common/effect/particle/SpongeParticleHelper.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,7 @@ public void process(final double x, final double y, final double z, final List<P
243243
final ClientboundLevelParticlesPacket packet = new ClientboundLevelParticlesPacket(
244244
this.particleData,
245245
true,
246+
true,
246247
posX, posY, posZ,
247248
offX, offY, offZ,
248249
0.0F,
@@ -263,6 +264,7 @@ public void process(final double x, final double y, final double z, final List<P
263264
final ClientboundLevelParticlesPacket packet = new ClientboundLevelParticlesPacket(
264265
this.particleData,
265266
true,
267+
true,
266268
px0, py0, pz0,
267269
velocityX, velocityY, velocityZ,
268270
1f,

src/main/java/org/spongepowered/common/entity/living/human/HumanEntity.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -430,7 +430,7 @@ public ClientboundPlayerInfoUpdatePacket createPlayerListPacket(final EnumSet<Cl
430430
final ClientboundPlayerInfoUpdatePacket packet = new ClientboundPlayerInfoUpdatePacket(actions, List.of());
431431

432432
((ClientboundPlayerInfoUpdatePacketAccessor) packet).accessor$entries(List.of(
433-
new ClientboundPlayerInfoUpdatePacket.Entry(this.uuid, this.fakeProfile.gameProfile(), false, 0, GameType.DEFAULT_MODE, this.getDisplayName(), 0, null)));
433+
new ClientboundPlayerInfoUpdatePacket.Entry(this.uuid, this.fakeProfile.gameProfile(), false, 0, GameType.DEFAULT_MODE, this.getDisplayName(), false, 0, null)));
434434
return packet;
435435
}
436436

src/main/java/org/spongepowered/common/entity/player/tab/SpongeTabList.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -194,7 +194,7 @@ void sendUpdate(final TabListEntry entry, final EnumSet<ClientboundPlayerInfoUpd
194194
final RemoteChatSession.Data chatSessionData = ((SpongeTabListEntry) entry).profilePublicKey() == null ? null : new RemoteChatSession.Data(entry.profile().uuid(), ((SpongeTabListEntry) entry).profilePublicKey());
195195
final net.minecraft.network.chat.Component displayName = entry.displayName().isPresent() ? SpongeAdventure.asVanilla(entry.displayName().get()) : null;
196196
final ClientboundPlayerInfoUpdatePacket.Entry data = new ClientboundPlayerInfoUpdatePacket.Entry(entry.profile().uniqueId(), SpongeGameProfile.toMcProfile(entry.profile()),
197-
entry.listed(), entry.latency(), (GameType) (Object) entry.gameMode(), displayName, listOrder, chatSessionData);
197+
entry.listed(), entry.latency(), (GameType) (Object) entry.gameMode(), displayName, false, listOrder, chatSessionData);
198198
((ClientboundPlayerInfoUpdatePacketAccessor) packet).accessor$entries(List.of(data));
199199
this.player.connection.send(packet);
200200
}

src/main/java/org/spongepowered/common/entity/projectile/ProjectileUtil.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -296,7 +296,7 @@ protected Optional<WitherSkull> createProjectile(final LivingEntity source, fina
296296
@Override
297297
protected Optional<FishingBobber> createProjectile(final LivingEntity source, final ServerLocation loc) {
298298
if (source instanceof Player) {
299-
final FishingHook hook = new FishingHook((Player) source, source.level(), 0, 0, new ItemStack(Items.FISHING_ROD));
299+
final FishingHook hook = new FishingHook((Player) source, source.level(), 0, 0);
300300
hook.setPos(loc.x(), loc.y(), loc.z());
301301
return ProjectileUtil.doLaunch(loc.world(), (FishingBobber) hook);
302302
}

0 commit comments

Comments
 (0)