Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't decompress sc file #13

Open
E12Dragon opened this issue Sep 29, 2023 · 1 comment
Open

Can't decompress sc file #13

E12Dragon opened this issue Sep 29, 2023 · 1 comment

Comments

@E12Dragon
Copy link

Hi,

Trying to decode some new sc files from Clash of Clans using latest version of x-coder on python 3.11.1

I have uploaded the files I am unable to decompress to google drive.

[INFO] File: scenery_ghost2023_dl_opt__1_.sc. Collecting information...
[INFO] ZSTD compression detected
[ERROR] ERROR! (builtins.AttributeError: 'SWFTexture' object has no attribute 'image')
Traceback (most recent call last):

  File "C:\...\XCoder-2.6.7\main.py", line 50, in <module>
    main()
    └ <function main at 0x0000013C0DDC04A0>

  File "C:\...\XCoder-2.6.7\main.py", line 40, in main
    handler()
    └ <function decode_and_render_objects at 0x0000013C109B79C0>

> File "C:\...\XCoder-2.6.7\system\lib\features\sc\decode.py", line 80, in decode_and_render_objects
    _save_textures(swf, objects_output_folder / "textures", base_name)
    │              │    │                                   └ 'scenery_ghost2023_dl_opt__1_'
    │              │    └ WindowsPath('SC/Out-Sprites/scenery_ghost2023_dl_opt__1_')
    │              └ <system.lib.swf.SupercellSWF object at 0x0000013C10A42050>
    └ <function _save_textures at 0x0000013C10A0C2C0>

  File "C:\...\XCoder-2.6.7\system\lib\features\sc\decode.py", line 112, in _save_textures
    swf.textures[img_index].image.save(textures_output / f"{filename}.png")
    │   │        │                     └ WindowsPath('SC/Out-Sprites/scenery_ghost2023_dl_opt__1_/textures')
    │   │        └ 0
    │   └ [<system.lib.objects.texture.SWFTexture object at 0x0000013C10B43550>, <system.lib.objects.texture.SWFTexture object at 0x000...
    └ <system.lib.swf.SupercellSWF object at 0x0000013C10A42050>

AttributeError: 'SWFTexture' object has no attribute 'image'
@E12Dragon
Copy link
Author

The same issue occurs with all sc files in the latest version (v15.547.x)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant