mirror of
https://github.com/dmulloy2/ProtocolLib.git
synced 2025-04-17 17:46:21 +02:00
Add a convenience retriever for integer array fields.
This commit is contained in:
parent
300111b850
commit
98a9377384
@ -43,7 +43,6 @@ import com.comphenix.protocol.wrappers.BukkitConverters;
|
||||
import com.comphenix.protocol.wrappers.ChunkPosition;
|
||||
import com.comphenix.protocol.wrappers.WrappedDataWatcher;
|
||||
import com.comphenix.protocol.wrappers.WrappedWatchableObject;
|
||||
import com.google.common.io.Closeables;
|
||||
|
||||
import net.minecraft.server.Packet;
|
||||
|
||||
@ -196,6 +195,14 @@ public class PacketContainer implements Serializable {
|
||||
public StructureModifier<byte[]> getByteArrays() {
|
||||
return structureModifier.withType(byte[].class);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieves a read/write structure for every int array field.
|
||||
* @return A modifier for every int array field.
|
||||
*/
|
||||
public StructureModifier<int[]> getIntegerArrays() {
|
||||
return structureModifier.withType(int[].class);
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieves a read/write structure for ItemStack.
|
||||
|
Loading…
Reference in New Issue
Block a user