geforkt von Mirrors/Paper
0ae1e62bfc
The minecraft serialisation logic for ListTag updates the type byte of the list tag during writing to match either the first element in the list or 0, if said list tag is empty. As such, list content type information cannot be carried through a write/read process, e.g. chunk load/unload or a creative client updating the item. The recently introduced persistent data type collections for lists hence can also not enforce a specific list content type if the found list is empty, which it currently attempts to do. As such, a call to PersistentDataContainer#has would also yield false for any empty list as the lists type byte would be 0. The faulty behaviour has been fixed by considering an empty list in the persistent data container to match any list type. This change, while technically breaking the #has check, is needed and reasonable as the #has check for this is currently broken in the first place as described above. By: Bjarne Koll <lynxplay101@gmail.com> |
||
---|---|---|
paper-server |