ghorsington / CM3D2.YATranslator

Yet Another Translator -- Translation plug-in for CM3D2 remade from scratch
https://coder.horse/CM3D2.YATranslator
The Unlicense
28 stars 5 forks source link

[COM3D2] Certain Assets not getting replaced #15

Closed asyetriec closed 6 years ago

asyetriec commented 6 years ago

Hey Denikson,

Thanks for the COM3D2 Update.

Works well with no errors so far except that certain UI Assets are not being replaced even though I've placed the files inside Config/Assets/resources.

I see the code where you replace the assets. However I'm not sure how to debug this moving forward. Certain assets like the default CM3D2 ones e.g. AtlasCommon etc do get replaced but the newer ones like e.g. shisetsu_infoplate for the facilities/room management are not getting replaced.

Wonder if you have anymore info about this?

Specs: COM3D2 v1.04 Sybaris with only IMGUI, AutoTranslate and YATranslator.

Let me know if you need anymore information

Here's the translations UI file: https://drive.google.com/file/d/1M7bpvkSi7253EgUqc4Z9NQLwvd0kaQSD/view

ghorsington commented 6 years ago

Thank you for the information.

At the moment I don't have COM3D2 installed, so there's not much I can do in terms of debugging.
I do have Assembly-CSharp.dll, so I'll take a look at the changes between CM3D2 and COM3D2 in terms of asset loading.

Meanwhile, did you perchance use YAT's asset dumping to obtain the textures that are not being replaced. If not, did you extract the assets from ARC files directly?

asyetriec commented 6 years ago

I didn't use YAT asset dumping to obtain the textures.

Instead I used Unity Assets Bundle Extractor and I pulled them out from resources.assets and sharedassets0.

Do the files also live in the arc files? Sorry I am a little new to doing this and understand the structure of CM3D2/COM3D2 and Unity Games in general as I have no experience in this field but trying my best!

I have already extracted out most of the arc files with the CM3D2.Toolkit and I can extract assets out no issues with your TexTool v2.

There still appears to be some issues with Sybaris but I can't seem to find a source for that so I will probably look at whether I can decompile the dll.

ghorsington commented 6 years ago

Pardon my prolonged silence.

The reason why I ask is because YAT treats some UI elements differently (which in turn is due to how the game itself handles the elements). Indeed, some UI elements are so-called Assets that are used in most of the UIs. However, some UI elements are what is referred to as TexSprites; they are handled differently by YAT. Some elements are even part of normal Textures!

While I don't have the game available, you can (and should) try using resource dumping to dump Assets and TexSprites. That way YAT will (1) dump everything in the correct folders and (2) not dump anything it cannot detect. The latter is crucial, as it can help to see whether YAT actually fails to catch a UI element. Please, try using resource dumping and use the problematic UIs. If they will not get dumped by YAT, I will look more closely into the issue.

asyetriec commented 6 years ago

No worries! We all do this in our free time.

I have verified via dumping through YATranslator and it definitely dumps the same filename and it's a Texture Sprite. Do I need to compile them to .tex in this instance for it to work?

image

ghorsington commented 6 years ago

No, you don't have to, although YAT will accept TEX files.

However, you need to put them into Config/Textures folder in order for them to be replaced -- not Config/Assets. Again, that is due to how C(O)M3D2 handles some of the UI differently.

asyetriec commented 6 years ago

Yeah I just saw the wiki!

Thanks denikson. Verified that that works. :)

I think there's something other issues that some guys are facing with YATranslator but that's only with the starting sequence (new game) but otherwise I think YATranslator is really stable for COM3D2.

ghorsington commented 6 years ago

Might not be YAT, if there are no visible errors in console that are related to texture/asset loading.

If you do manage to obtain an error log that points to YAT being the culprit, feel free to create a new issue with the information. Otherwise there really isn't a way to fix the problem.

This custom version of UnityInjector might help with error hunting. It provides a more detailed error info in the console.

asyetriec commented 6 years ago

Yeah.

I don't think it's YAT either. But some guys over at HongFire stated that the error occurs with YAT enabled. But I'll do some debugging/trial and error and see what happens.

Thanks for everything so far!