/** * Retrieves a read/write structure for collections of chunk positions. * * <p>This modifier will automatically marshall between the visible ProtocolLib ChunkPosition and * the internal Minecraft ChunkPosition. * * @return A modifier for ChunkPosition list fields. */ public StructureModifier<List<ChunkPosition>> getPositionCollectionModifier() { // Convert to and from the ProtocolLib wrapper return structureModifier.withType( Collection.class, BukkitConverters.getListConverter( MinecraftReflection.getChunkPositionClass(), ChunkPosition.getConverter())); }
/** * Retrieves a read/write structure for chunk positions. * * @return A modifier for a ChunkPosition. */ public StructureModifier<ChunkPosition> getPositionModifier() { // Convert to and from the Bukkit wrapper return structureModifier.withType( MinecraftReflection.getChunkPositionClass(), ChunkPosition.getConverter()); }