Jump to content

Recommended Posts

Posted

I'm trying to rename some items from other mods. I've added "othermodid:item-name" entries into my mod's lang file, but they seem to be being ignored. I can't figure out what might be happening here, because as far as I understand, this should work. Are there any reasons why lang entries from other mods would be ignored or not overriden? The entries for game: and my own modid: domains are being applied correctly, so the file itself seems to be fine. The other mods aren't required for my mod to run, so I'm not adding them as dependencies.

Just to confirm that I haven't got silly typos in the lang keys, I'm attaching screenshots of the entries in my lang file, an example entry from floralzonescosmopolitanregion's lang file, and the item in game showing the original name instead of mine.

What am I missing?

 

 

1.png

2.png

3.png

Posted

I myself am a bit confused why this isn't working. This should theoretically be possible without adding dependencies to the modinfo. I tested it a couple of times successfully and advised others on this matter, on which I got positive feedback. Very curious.

Posted

I don't know how the game determines these things, but if you just put your assets in other domains, won't they just conflict rather than overriding? If you're explicitly trying to override, why not try a patch?

Posted (edited)
1 hour ago, Diff said:

I don't know how the game determines these things, but if you just put your assets in other domains, won't they just conflict rather than overriding? If you're explicitly trying to override, why not try a patch?

Language files are special. They cannot be patched (because lang assets are processed before patches), Compatibility Lib doesn't touch them (most likely for the same reason).

Edited by Brady_The
  • Thanks 1
Posted
9 hours ago, Brady_The said:

I myself am a bit confused why this isn't working. This should theoretically be possible without adding dependencies to the modinfo. I tested it a couple of times successfully and advised others on this matter, on which I got positive feedback. Very curious.

To my understanding the Lang system is just a last entry wins system, meaning what matters is the load order. 

Posted

I've made an interesting discovery after more testing: this issue only happens when running the debug client from my IDE. If I package a release of the mod and use that, then the lang entries get overridden correctly. It must be some obscure bug in the development setup or the mod template..? At least now I know I can just ignore it while I'm testing and just double check it works when I make a release.

Posted
5 minutes ago, Averixus said:

I've made an interesting discovery after more testing: this issue only happens when running the debug client from my IDE. If I package a release of the mod and use that, then the lang entries get overridden correctly. It must be some obscure bug in the development setup or the mod template..? At least now I know I can just ignore it while I'm testing and just double check it works when I make a release.

🤔 That's certainly interesting... when debugging from the IDE it adds the folder it compiled into as an extra place to load mods from, perhaps this somehow affects the load order when it's not decided by dependencies.

Posted (edited)
1 hour ago, The Insanity God said:

🤔 That's certainly interesting... when debugging from the IDE it adds the folder it compiled into as an extra place to load mods from, perhaps this somehow affects the load order when it's not decided by dependencies.

That could be it. My modid is alphabetically after the mods I'm trying to override. But in the console when I run the debug client it seems to be prepended with "arg" and loaded first. Although this also seems to show that it's loaded before vanilla survival, which surely can't be what's actually happening?! Because some of my lang entries override vanilla and they are being applied correctly. Also, my mod patches various recipes and other files from those other mods, and all of those patches are being applied correctly too.

Screenshot2026-01-18at09_55_05.thumb.png.7770d282e0f3de5073abb1503eed4c77.png

 

Edited by Averixus
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.