ata4 / disunity

An experimental toolset for Unity asset and asset bundle files.
The Unlicense
2.69k stars 663 forks source link

extract files for unity editor / no issue just request #10

Open francoiscoiscois opened 10 years ago

francoiscoiscois commented 10 years ago

Hi, I want to thank you for this great tool It really help me understand how Unity project are build by looking into the files I can extract and convert with disunity.

Just a request if you are interested. Would it be possible to extract an assets file so that it can be seen in unity editor directly? like the unity script UnpackAssets.cs http://forum.cgpersia.com/f79/unpackassets-editor-unity-3d-51528/

UnpackAssets is great but doesnt work with many unity game and never work with iphone apps made with unity. While your tool is always able to extract them.

I have tryes to extract raw data with disunity but they are .bin files and I cannot load them in Unity.

Would it be possible to extract the .asset .anim .prefab ? Tell me if you need some iphone app to extract

thank you :)

ata4 commented 10 years ago

I think the split command kind of does that, but not always with the correct extension (in case .asset doesn't work). But most of the time, it's easier to change the extension of "mainData" or the "levelX" files to .unity and just load the whole scene into the Unity Editor and work from there instead. The fixrefs command may help in case the dependencies aren't loaded correctly.

francoiscoiscois commented 10 years ago

Thank you again ata4. I didnt know about the split command. work perfectly so far.

Was you able to open files from iphone or android game in the unity engine? After spliting the files with disunity. when I try to import the asset in the editor I get an error message. fatal error position out of bound corrupted files. and I have to close the editor. This is the same for all the iphone game I have tried today. (almost never get this problem from webbuild) Do you know if there is a workaround.

Thanks

ata4 commented 10 years ago

It would be helpful to know what exactly you would like to do. But I can say that iPhone games, as well as most other standalone builds, don't embed their data structure into the asset files, which is required for the editor to load the files correctly. I can think of a solution using the structure database, but it's very experimental and probably won't work in some cases.

francoiscoiscois commented 10 years ago

Thanks I am a student learning 3d and Level design for game. I am very interested to learn how iphone project are put together in unity, as we want to make an iphone app in our school team. Beeing able to load a level in Unity, have a look in the game object, the materials, the modeling .is really usefull .. It teach me a to look professional games. But also just being able to export the meshes als .obj would be really cool (it doesnt work with ios project either) I didnt know iphone games would have a completly different structure ... That would be awesome If you would be able to reconstruct the assets for iphone apps, so the levels can be loaded in unity editor. So many unity project are made essentialy for iphone/android those days. I gess it is easier to say than to do it. Anyway I can provide you some iphone games to test if you want. Would be happy to help Have a nice day

ata4 commented 10 years ago

But also just being able to export the meshes als .obj would be really cool (it doesnt work with ios project either)

It should work if it's for Unity 4.x, otherwise... yeah, I'm working on that.

I didnt know iphone games would have a completly different structure ...

The structure isn't necessarily different, it's just missing as meta data. DisUnity has to "guess" what structures need to be used. The file format itself is identical.

Anyway I can provide you some iphone games to test if you want.

Yes, please! Most of my games for testing are browser games and I only have like two or three iPhone games.

francoiscoiscois commented 10 years ago

It should work if it's for Unity 4.x, otherwise... yeah, I'm working on that. Awesome ! Disunity is going to be the best tool for reverse engenering !! I dont know why but so far I was never able to extract mesh from ios apps ...

here I have copied a few games on my dropbox account you can access here https://www.dropbox.com/sh/eh7riogdbo04qj1/br-T6mgoQ5 (I will remove them in 2 days) I have a lot more unity apps I game share later but my drpbox is full already if you rename the .ipa as .rar you can extract everything If you want to contact me directly you can mail me at francoiscoiscois at hotmail dot com Good luck in your progress ;)

ata4 commented 10 years ago

Thanks! It sure will come in handy for the next update.

andrewpros commented 10 years ago

@francoiscoiscois Hey, i'm exactly doing the same, want to learn how professional games are made, i'm using for this purpose android games.

The problem with this is that the apk file contains always split sharedassets, for example sharedassets0.assets.split0 sharedassets0.assets.split1 etc.

Maybe disunity should support this, the apk file is just zip archive, when i use disunity i always first join all sharedassets that are split, it is just one continuous file, so after joining i have one or more sharedassets.assets files.

But there are strange files sometime, named like this "54ecd29b786bc472fabcf814aa92df84", many of them, don't know whats there and how to open them, any advice?

Most of them are small and contains only references to some others or sharedassets, but there are also bigger ones, i suppose with some needed data and assets.

Maybe we should have some wiki page to explain what files are what and couple of things, i don't know also what mainData is and for what it is used, and how to use/extract it?

Would it be possible to extract the .asset .anim .prefab ?

That would be great, but it is not so simple i'm afraid.

Was trying to load some level or mainData from apk in unity, after joining split parts, but it is always the same, either error or corrupted file. A think if you want to open assets in unity it must be the same version that the game was compiled, so disunity is still better, if only we could extract more complicated data like prefab, materials, anim or maybe just a way to show its parameters in a readable form.

I know what someone have even converted an android game - sub way sur fers to a pc version, so anything is possible right?

MOTCONVITBEO commented 9 years ago

@andrewpros:

sorry, but could you please show me the way to join split shared assets files? Thanks

andrewpros commented 9 years ago

@motconvitbeo

Just join them together with any software that can join files, i was using HxD.

First join all same name files like

sharedassets0.assets.split0 sharedassets0.assets.split1

sharedassets0 - this is the shared prefix

Then any with other names like

sharedassets1.assets.split0 sharedassets1.assets.split1 sharedassets1.assets.split2

at the end you will have single files:

sharedassets0.assets sharedassets1.assets

etc And use disunity on them.

jenokizm commented 9 years ago

subscribe to topic, tell me what commands to use to decompress these files without an extension? ashampoo_snap_2015 04 28_19h18m58s_001_

andrewpros commented 9 years ago

Without extension? I don't know, all important data is in the assets files anyway and the code is in dlls.

jenokizm commented 9 years ago

I'm sorry, probably I did not know. sharedassets0.assets.split0 to sharedassets0.assets.split6 ? are they? I did not get to do it (

jenokizm commented 9 years ago

I suspect I need a command to merge .split0 - .split6 ,but I did not find it, tell me what to type in the console?

ata4 commented 9 years ago

The files without extensions are using the same format as the .assets files. And to process .split files in DisUnity, you just need to pick one of the files, the other files are loaded automatically.

andrewpros commented 9 years ago

"the other files are loaded automatically" there was no such function back then or it was not working well (i don't know if it is working well by now) and again, the most interesting data is in files with extensions

@jenokizm I was using HxD software, it has a join function, but maybe DisUnity works now good with joining split files.

jenokizm commented 9 years ago

ata4, error ashampoo_snap_2015 04 29_16h09m16s_001_ - c--windows-system32-cmd-exe

ata4 commented 9 years ago

These are Unity 5 files, which are unsupported in DisUnity 0.3. The current dev version of 0.4 should support it, but it's nowhere near finished and can currently extract only very few asset types.

jenokizm commented 9 years ago

ok you have understood. thanks for the reply, I wish you as soon as possible to add a new version of the tool! ps andrewpros, HxD software is a good thing, but still not unpack ... we will wait for the update!

matrixreal commented 9 years ago

@ata4 got this error disunity

ata4 commented 9 years ago

@matrixreal 0.3, right? You'll need to call disunity from its directory, just adding the .bat to PATH won't work.

matrixreal commented 9 years ago

@ata4 it's latest one from this repo

matrixreal commented 9 years ago

@ata4 wich directory i can found disunity ? thanks

ata4 commented 9 years ago

Usually the same directory where disunity.jar is located.

matrixreal commented 9 years ago

sans titre