yarn
yarn copied to clipboard
BlockEntity::markDirty replacement names
The general consensus in Discord was that markDirty
isn't great as it doesn't indicate what is marked as dirty. The method actually only indicates that the chunk containing the BE needs to be saved to disk, not that (contrary to common belief) update packets should be sent to clients.
The two proposed options so far:
-
scheduleSave
-
markChanged
either one 👍
I was going to open an issue for this, but realized this already exists. +1 for finding something better than markDirty
, especially for block entities where it additionally fires a comparator update. Although we will have to use the same for Inventory
as well.
Ideally the mapping would convey that we go from "no guaranteed save" to "guaranteed save".