You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
for root, dirs, files in os.walk(source_folder):
for file_name in files:
file_path = os.path.join(root, file_name)
env = UnityPy.load(file_path)
# alternative way which keeps the original path
for path,obj in env.container.items():
if obj.type.name in ["Texture2D", "Sprite"]:
data = obj.read()
# create dest based on original path
dest = os.path.join(destination_folder, *path.split("/"))
# make sure that the dir of that path exists
os.makedirs(os.path.dirname(dest), exist_ok = True)
# edit texture
fp = os.path.join(replace_dir, data.name + '.png')
pil_img = Image.open(fp)
data.image = pil_img
data.image.save(dest)
Error
So this is working right now, it's loading a .bbq file which contains a .png file and other stuff, I'm just changing the .png file and saving, on the destination folder seems like the original path is working and everything, my question is ¿How do you convert it back to being a .bbq file?
I see, so my whole idea was wrong from the beggining.
I did try with the assets in the shared.assets bundle files but the library didn't show me anything there, maybe because it's for a game on Unity 2020.3? Does UnityPy work on that version?
Code
Error
So this is working right now, it's loading a .bbq file which contains a .png file and other stuff, I'm just changing the .png file and saving, on the destination folder seems like the original path is working and everything, my question is ¿How do you convert it back to being a .bbq file?
To Reproduce
This is the .bbq file I'm trying to edit: https://drive.google.com/file/d/1LA7sKNRrEXUeiHdzYjg8bfWyLSngBnG0/view?usp=sharing
I know it's not really a bug, but didn't found any info about it, thank you for the help and awesome work!
The text was updated successfully, but these errors were encountered: