def extract_bnd(bnd_path, output_dir): """ Extract files from a BND to output_dir. """ bnd = Bnd() load_success = bnd.load(bnd_path) if not load_success: return bnd.extract_all_files(output_dir)
def extract_bnd(bnd_path): print("Extract", bnd_path) bnd = Bnd() load_success = bnd.load(bnd_path) if not load_success: return output_dir = os.path.join( os.path.dirname(bnd_path), os.path.splitext(os.path.basename(bnd_path))[0] ) bnd.extract_all_files(output_dir)