Flush clipboards before writing schematics.

#1286
This commit is contained in:
dordsor21
2021-09-18 03:19:49 +01:00
parent bd95d5a86d
commit dbbb450172
4 changed files with 7 additions and 0 deletions

View File

@ -78,6 +78,10 @@ public class SpongeSchematicWriter implements ClipboardWriter {
@Override
public void write(Clipboard clipboard) throws IOException {
//FAWE start - ensure clipboard is flushed in case of using clipboard-on-disk. Maintains allowing of the same code
// between upstream and FAWE
clipboard.flush();
//FAWE end
// For now always write the latest version. Maybe provide support for earlier if more appear.
outputStream.writeNamedTag("Schematic", new CompoundTag(write2(clipboard)));
}