public class AnvilSaveConverter extends SaveFormatOld
Modifier and Type | Field and Description |
---|---|
private static org.apache.logging.log4j.Logger |
logger |
savesDirectory
Constructor and Description |
---|
AnvilSaveConverter(java.io.File p_i2144_1_) |
Modifier and Type | Method and Description |
---|---|
private void |
addRegionFilesToCollection(java.io.File worldDir,
java.util.Collection<java.io.File> collection)
filters the files in the par1 directory, and adds them to the par2 collections
|
private void |
convertChunks(java.io.File p_75811_1_,
java.io.File p_75811_2_,
WorldChunkManager p_75811_3_,
int p_75811_4_,
int p_75811_5_,
IProgressUpdate progressCallback)
copies a 32x32 chunk set from par2File to par1File, via AnvilConverterData
|
private void |
convertFile(java.io.File p_75813_1_,
java.lang.Iterable<java.io.File> p_75813_2_,
WorldChunkManager p_75813_3_,
int p_75813_4_,
int p_75813_5_,
IProgressUpdate p_75813_6_) |
boolean |
convertMapFormat(java.lang.String filename,
IProgressUpdate progressCallback)
converts the map to mcRegion
|
private void |
createFile(java.lang.String filename)
par: filename for the level.dat_mcr backup
|
void |
flushCache() |
boolean |
func_154334_a(java.lang.String saveName) |
java.lang.String |
getName()
Returns the name of the save format.
|
java.util.List<SaveFormatComparator> |
getSaveList() |
ISaveHandler |
getSaveLoader(java.lang.String saveName,
boolean storePlayerdata)
Returns back a loader for the specified save directory
|
protected int |
getSaveVersion() |
boolean |
isOldMapFormat(java.lang.String saveName)
gets if the map is old chunk saving (true) or McRegion (false)
|
canLoadWorld, deleteFiles, deleteWorldDirectory, func_154335_d, getWorldInfo, renameWorld
public java.lang.String getName()
getName
in interface ISaveFormat
getName
in class SaveFormatOld
public java.util.List<SaveFormatComparator> getSaveList() throws AnvilConverterException
getSaveList
in interface ISaveFormat
getSaveList
in class SaveFormatOld
AnvilConverterException
protected int getSaveVersion()
public void flushCache()
flushCache
in interface ISaveFormat
flushCache
in class SaveFormatOld
public ISaveHandler getSaveLoader(java.lang.String saveName, boolean storePlayerdata)
getSaveLoader
in interface ISaveFormat
getSaveLoader
in class SaveFormatOld
public boolean func_154334_a(java.lang.String saveName)
func_154334_a
in interface ISaveFormat
func_154334_a
in class SaveFormatOld
public boolean isOldMapFormat(java.lang.String saveName)
isOldMapFormat
in interface ISaveFormat
isOldMapFormat
in class SaveFormatOld
public boolean convertMapFormat(java.lang.String filename, IProgressUpdate progressCallback)
convertMapFormat
in interface ISaveFormat
convertMapFormat
in class SaveFormatOld
private void createFile(java.lang.String filename)
private void convertFile(java.io.File p_75813_1_, java.lang.Iterable<java.io.File> p_75813_2_, WorldChunkManager p_75813_3_, int p_75813_4_, int p_75813_5_, IProgressUpdate p_75813_6_)
private void convertChunks(java.io.File p_75811_1_, java.io.File p_75811_2_, WorldChunkManager p_75811_3_, int p_75811_4_, int p_75811_5_, IProgressUpdate progressCallback)
private void addRegionFilesToCollection(java.io.File worldDir, java.util.Collection<java.io.File> collection)