9
0
mirror of https://github.com/HibiscusMC/HibiscusCommons.git synced 2025-12-19 15:09:26 +00:00

fix: mount packet not being written in correct field

This commit is contained in:
LoJoSho
2024-12-16 13:05:50 -06:00
parent cf013b5ab5
commit 374df6848a
6 changed files with 6 additions and 6 deletions

View File

@@ -158,7 +158,7 @@ public class NMSPackets extends NMSCommon implements me.lojosho.hibiscuscommons.
@Override
public void sendMountPacket(int mountId, int[] passengerIds, List<Player> sendTo) {
FriendlyByteBuf byteBuf = new FriendlyByteBuf(Unpooled.buffer());
byteBuf.writeInt(mountId);
byteBuf.writeVarInt(mountId);
byteBuf.writeVarIntArray(passengerIds);
try {
ClientboundSetPassengersPacket packet = passengerConstructor.newInstance(byteBuf);

View File

@@ -158,7 +158,7 @@ public class NMSPackets extends NMSCommon implements me.lojosho.hibiscuscommons.
@Override
public void sendMountPacket(int mountId, int[] passengerIds, List<Player> sendTo) {
FriendlyByteBuf byteBuf = new FriendlyByteBuf(Unpooled.buffer());
byteBuf.writeInt(mountId);
byteBuf.writeVarInt(mountId);
byteBuf.writeVarIntArray(passengerIds);
try {
ClientboundSetPassengersPacket packet = passengerConstructor.newInstance(byteBuf);

View File

@@ -159,7 +159,7 @@ public class NMSPackets extends NMSCommon implements me.lojosho.hibiscuscommons.
@Override
public void sendMountPacket(int mountId, int[] passengerIds, List<Player> sendTo) {
FriendlyByteBuf byteBuf = new FriendlyByteBuf(Unpooled.buffer());
byteBuf.writeInt(mountId);
byteBuf.writeVarInt(mountId);
byteBuf.writeVarIntArray(passengerIds);
try {
ClientboundSetPassengersPacket packet = passengerConstructor.newInstance(byteBuf);

View File

@@ -158,7 +158,7 @@ public class NMSPackets extends NMSCommon implements me.lojosho.hibiscuscommons.
@Override
public void sendMountPacket(int mountId, int[] passengerIds, List<Player> sendTo) {
FriendlyByteBuf byteBuf = new FriendlyByteBuf(Unpooled.buffer());
byteBuf.writeInt(mountId);
byteBuf.writeVarInt(mountId);
byteBuf.writeVarIntArray(passengerIds);
try {
ClientboundSetPassengersPacket packet = passengerConstructor.newInstance(byteBuf);

View File

@@ -168,7 +168,7 @@ public class NMSPackets extends NMSCommon implements me.lojosho.hibiscuscommons.
@Override
public void sendMountPacket(int mountId, int[] passengerIds, List<Player> sendTo) {
FriendlyByteBuf byteBuf = new FriendlyByteBuf(Unpooled.buffer());
byteBuf.writeInt(mountId);
byteBuf.writeVarInt(mountId);
byteBuf.writeVarIntArray(passengerIds);
try {
ClientboundSetPassengersPacket packet = passengerConstructor.newInstance(byteBuf);

View File

@@ -156,7 +156,7 @@ public class NMSPackets extends NMSCommon implements me.lojosho.hibiscuscommons.
@Override
public void sendMountPacket(int mountId, int[] passengerIds, List<Player> sendTo) {
FriendlyByteBuf byteBuf = new FriendlyByteBuf(Unpooled.buffer());
byteBuf.writeInt(mountId);
byteBuf.writeVarInt(mountId);
byteBuf.writeVarIntArray(passengerIds);
try {
ClientboundSetPassengersPacket packet = passengerConstructor.newInstance(byteBuf);