diff --git a/README.md b/README.md index b2e4873..a504591 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,7 @@ # AnimeWwise -Extract audio from .pck and .hdiff to mp3 with this tool. It can in theory extract any pck or hdiff file from any game even though it was made for Genshin Impact. There are others tools that do the same but none of them were working so I just made my own. +Extract audio from .pck and .hdiff to mp3 including original filenames with this tool. It can in theory extract any pck or hdiff file from any game even though it was made for Genshin Impact. There are others tools that do the same but none of them were working so I just made my own. + +⚠️ Only audio from genshin will be exported with original filenames, and the coverage is very low, don't except every file to have a name # Usage @@ -14,7 +16,6 @@ Extract audio from .pck and .hdiff to mp3 with this tool. It can in theory extra --- ## ℹ️ There is a separate branch called `dev` that may includes new features, you can check it out if you want to get them early. Those features are, as of right now : -- export files with their original names - more export formats support - reverse search ? diff --git a/extract.py b/extract.py index 0b51a90..39e7474 100644 --- a/extract.py +++ b/extract.py @@ -14,7 +14,7 @@ cwd = os.getcwd() path = lambda path: os.path.join(cwd, path) call = lambda args: subprocess.call(args, stdout=subprocess.DEVNULL, stderr=subprocess.STDOUT) spinner = Halo(text="spinner", spinner={'interval': 100, 'frames': ['◜', '◠', '◝', '◞', '◡', '◟']}, placement="right") -skips = "000111111" # used for debugging +skips = "000000000" # used for debugging # 1 - original extract # 2 - patch @@ -234,13 +234,6 @@ def main(): new_files = [f"{f.split('.')[0]}.mp3" for f in new_files] changed_files = [f"{f.split('.')[0]}.mp3" for f in changed_files] - # todo: something is wrong here with extraction of hdiff, it's missing files and not extracting everything ? - # actually it may not, the old method was just naming them by increasing numbers, one change and it offset all of them - # making two of the same nums to be different because of offset. The old method may actually extract unwanted stuff :O - # print(all_files) - # print(new_files) - # print(changed_files) - ######################### ### 7 - Map filenames ### ######################### @@ -311,7 +304,6 @@ def main(): os.rename("temp/map", f"temp/{filename}") shutil.move(f"temp/{filename}", f"output/{filename}") - # todo: final cleanup, will get deleted anyway after so idk yet spinner.stop() print(f"[{curr}/{steps}] Cleaning up")