amulet.utils.format_utils module

amulet.utils.format_utils.check_all_exist(in_dir, *args)[source]

Check that all files exist in a parent directory

Parameters
  • in_dir (str) – The parent directory

  • args (str) – file or folder names to look for

Return type

bool

Returns

Boolean value indicating whether all were found

amulet.utils.format_utils.check_one_exists(in_dir, *args)[source]

Check that at least one file exists in a parent directory

Parameters
  • in_dir (str) – The parent directory

  • args (str) – file or folder names to look for

Return type

bool

Returns

Boolean value indicating whether at least one was found

amulet.utils.format_utils.load_leveldat(in_dir)[source]

Load the root tag of the level.dat file in the directory

Parameters

in_dir (str) – The world directory containing the level.dat file

Return type

NamedTag

Returns

The NBT root tag