nesrak1 / UABEA

c# uabe for newer versions of unity
MIT License
1.05k stars 135 forks source link

Urgent: UABEA cant open resources.assets file while AssetBundleExtractor can. #302

Closed Flanua closed 5 months ago

Flanua commented 5 months ago

System.ArgumentException: The output char buffer is too small to contain the decoded characters, encoding 'Unicode (UTF-8)' fallback 'System.Text.DecoderReplacementFallback'. (Parameter 'chars') at System.Text.Encoding.ThrowCharsOverflow(DecoderNLS decoder, Boolean nothingDecoded) at System.Text.Encoding.GetCharsWithFallback(ReadOnlySpan1 bytes, Int32 originalBytesLength, Span1 chars, Int32 originalCharsLength, DecoderNLS decoder) at System.Text.UTF8Encoding.GetCharsWithFallback(ReadOnlySpan1 bytes, Int32 originalBytesLength, Span1 chars, Int32 originalCharsLength, DecoderNLS decoder) at System.Text.Encoding.GetCharsWithFallback(Byte pOriginalBytes, Int32 originalByteCount, Char pOriginalChars, Int32 originalCharCount, Int32 bytesConsumedSoFar, Int32 charsWrittenSoFar, DecoderNLS decoder) at System.Text.DecoderNLS.GetChars(Byte bytes, Int32 byteCount, Char chars, Int32 charCount, Boolean flush) at System.Text.Decoder.GetChars(ReadOnlySpan1 bytes, Span1 chars, Boolean flush) at System.IO.BinaryReader.Read() at System.IO.BinaryReader.ReadChar() at AssetsTools.NET.AssetsFileReader.ReadNullTerminated() at AssetsTools.NET.AssetsFileExternal.Read(AssetsFileReader reader) at AssetsTools.NET.AssetsFileMetadata.Read(AssetsFileReader reader, UInt32 version, Int64 dataOffset) at AssetsTools.NET.AssetsFileMetadata.Read(AssetsFileReader reader, AssetsFileHeader header) at AssetsTools.NET.AssetsFile.Read(AssetsFileReader reader) at AssetsTools.NET.Extra.AssetsFileInstance..ctor(Stream stream, String filePath) at AssetsTools.NET.Extra.AssetsManager.LoadAssetsFileCacheless(Stream stream, String path, Boolean loadDeps, BundleFileInstance bunInst) at AssetsTools.NET.Extra.AssetsManager.LoadAssetsFile(FileStream stream, Boolean loadDeps) at AssetsTools.NET.Extra.AssetsManager.LoadAssetsFile(String path, Boolean loadDeps) at UABEAvalonia.MainWindow.OpenFiles(String[] files) in D:\a\UABEA\UABEA\UABEAvalonia\MainWindow.axaml.cs:line 111 at System.Threading.Tasks.Task.<>c.b__1280(Object state) at Avalonia.Threading.JobRunner.JobWithArg.Avalonia.Threading.JobRunner.IJob.Run() in //src/Avalonia.Base/Threading/JobRunner.cs:line 241 at Avalonia.Threading.JobRunner.RunJobs(Nullable`1 priority) in //src/Avalonia.Base/Threading/JobRunner.cs:line 38 at Avalonia.Win32.Win32Platform.WndProc(IntPtr hWnd, UInt32 msg, IntPtr wParam, IntPtr lParam) in //src/Windows/Avalonia.Win32/Win32Platform.cs:line 267 at Avalonia.Win32.Interop.UnmanagedMethods.DispatchMessage(MSG& lpmsg) at Avalonia.Win32.Win32Platform.RunLoop(CancellationToken cancellationToken) in //src/Windows/Avalonia.Win32/Win32Platform.cs:line 215 at Avalonia.Threading.Dispatcher.MainLoop(CancellationToken cancellationToken) in //src/Avalonia.Base/Threading/Dispatcher.cs:line 61 at Avalonia.Controls.ApplicationLifetimes.ClassicDesktopStyleApplicationLifetime.Start(String[] args) in //src/Avalonia.Controls/ApplicationLifetimes/ClassicDesktopStyleApplicationLifetime.cs:line 122 at Avalonia.ClassicDesktopStyleApplicationLifetimeExtensions.StartWithClassicDesktopLifetime(AppBuilder builder, String[] args, ShutdownMode shutdownMode) in //src/Avalonia.Controls/ApplicationLifetimes/ClassicDesktopStyleApplicationLifetime.cs:line 214 at UABEAvalonia.Program.Main(String[] args) in D:\a\UABEA\UABEA\UABEAvalonia\Program.cs:line 53

Flanua commented 5 months ago

Want to open my resources.assets file in UABEA to dumb mesh info in json format because json dump from AssetBundleExtractor is in a different formatting and can't be imported into UABEA. Just trying to replace clothes from the old game build to the latest one.

nesrak1 commented 5 months ago

Is this a free game? This would be hard to fix without a file.

Cocollini commented 5 months ago

I am having the same problem when i try to open the sharedassets0.assets of the game Huniepop, but with others programs like AssetStudio i can, idk how to fix this :(

nesrak1 commented 5 months ago

@Cocollini Is it the same error? If not, open a new issue.

Cocollini commented 5 months ago

@Cocollini Is it the same error? If not, open a new issue.

yes is the same

Flanua commented 5 months ago

Is this a free game? This would be hard to fix without a file.

Yes its actually a free game from a steam with even a source code available the game is called: Planet Explorers

nesrak1 commented 5 months ago

Can't reproduce on any of the four resources.assets files in Planet Explorers. They all open fine for me. Are you on a non-English system by any chance? The exception seems to be in English but I just want to double check.

Flanua commented 5 months ago

Can't reproduce on any of the four resources.assets files in Planet Explorers. They all open fine for me. Are you on a non-English system by any chance? The exception seems to be in English but I just want to double check.

Sorry forgot to mention it can’t open resources.assets on the older smaller build: Planet Explorers Alpha 0.53 It can be downloaded from here: https://www.indiedb.com/games/planet-explorers/downloads/planet-explorers-alpha-053 P.S: Using english Windows 11 home edition x64.

nesrak1 commented 5 months ago

That version's release date is 2013, which is two years before unity 5's release date. UABEA will only support unity 5 and above. So this is just a wontfix. You can still use UABE for older games, you'll just have to use the UABE dump or UABE json format.