10 Commits

Author SHA1 Message Date
Bjarne Koll
f49e9d1932
#971: Remove strong chunk reference in PDC
A previous fix for SPIGOT-6814 implemented a callback function for the
PDC implementation that could be set to actively define a chunk as
unsaved, allowing chunks that have not been mutated through block
changes to still require saving if the chunks pdc was mutated.

This implementation however would pass a callback that references the
chunk access internally, meaning the PDC now actively holds onto a
callback that holds a reference to the entire chunk.

Aditionally, this change also impacted the pdc for item metas and
entities for really no reason whatsoever.

This commit re-implements the fix by introducing a new child of the pdc
implementation that the chunk now uses as its pdc. This specific
implementation maintains a dirty flag that is set to `true` on any form
of mutation and set back to false by the chunk that owns the PDC
whenever the chunk itself is flag as no longer dirty.
2021-12-05 08:53:46 +11:00
DerFrZocker
04f8e7e21f
SPIGOT-6814: (Chunk) PersistentData is lost after restart 2021-11-29 09:28:19 +11:00
md_5
a7b8b0270a
Update to Minecraft 1.18-pre5 2021-11-22 09:00:00 +11:00
Wesley Smith
d49530f9c4
#845: Remove unnecessary calls to Class#getSimpleName in PDC 2021-05-21 08:25:11 +10:00
md_5
90d6905b15
Repackage NMS 2021-03-16 09:00:00 +11:00
Parker Hawke
c49b67ac91
#685: Implement support for PersistentDataContainer arrays 2020-06-26 10:49:28 +10:00
Parker Hawke
b900513035
#671: Implement PersistentDataContainer#getKeys() 2020-06-26 10:49:28 +10:00
md_5
ce66f6937b Misc checkstyle fixes 2020-04-14 12:34:43 +10:00
md_5
de42aa13f3 Update to Minecraft 1.15 2019-12-11 09:00:00 +11:00
Bjarne Koll
42f88f72b5 Replace ItemTag API with new API that also expands to Tiles and Entities 2019-04-25 14:42:39 +10:00