Jump to content

Mod bugs that cause NPCs’ names to change?


Recommended Posts

This happened after I’d moved my save files from one computer to another. Do you think comparing the two WeiDU logs help?

I set up the second computer to be largely like the first one, but not entirely identical. 

Edited by ensbana
Link to post

If you use save games from one modded game in another one, this is bound to happen.

Theoretically, if you manage to set up the exact same game with the exact same mod install, the savegames should not show scrumbled names. But that would only work if you use the exact same mod versions.

Link to post
44 minutes ago, jastey said:

Theoretically, if you manage to set up the exact same game with the exact same mod install, the savegames should not show scrumbled names. But that would only work if you use the exact same mod versions.

Well, no theory about this: If you just copy the entire game folder from one computer to a flash storage device and paste it to another computer with the game already installed in the same exact folder without mods, you can continue the game and then paste the save games back and forth... just like with Steams cloud saves etc in other games.

But have a single misfire with mods, and your dialog.tlk get's cheesed up and you are bount to get these errors, making you to need start a new game.

44 minutes ago, jastey said:

if you use the exact same mod versions.

Yeah... thing is, there are mods that randomize during installs. And believe me, when I say that's a bad thing.

Of course my method requires you to be able to write over files, which in the modern Windows OS gets to be tricky as you need the game to be installed in the users profile files folders.. to be able to write over files.

3 hours ago, ensbana said:

but not entirely identical. 

It needs to be exatly identical.

Edited by Jarno Mikkola
Link to post
16 minutes ago, Jarno Mikkola said:

thing is, there are mods that randomize during installs.

But not item names, I think. Randomization is usually for places were items can be found. But yes, in principle you are right that depending on which mods, even the exact same mod versions in exact same install order might not give the same game.

Link to post

As others already pointed out, this is caused by using a save from a game with different mods (or different versions of mods, or different order of installation).  The reason for this is that NPC character files get stored in the baldur.gam file including the reference to their name in the dialog.tlk file, it is not looked up again from  the .cre file.  The same thing can happen with areas and shops, which are saved in the baldur.sav file. This is different from items and spells, which do refer to the game file every time they are referenced, so this never happens with items and spells.

I have a tool that might fix this, but it's very much experimental so use at your own risk.  The tool is found here:
https://github.com/AngelGryph/BGSaveFixer

Link to post
1 hour ago, Angel said:

As others already pointed out, this is caused by using a save from a game with different mods (or different versions of mods, or different order of installation).  The reason for this is that NPC character files get stored in the baldur.gam file including the reference to their name in the dialog.tlk file, it is not looked up again from  the .cre file.  The same thing can happen with areas and shops, which are saved in the baldur.sav file. This is different from items and spells, which do refer to the game file every time they are referenced, so this never happens with items and spells.

I have a tool that might fix this, but it's very much experimental so use at your own risk.  The tool is found here:
https://github.com/AngelGryph/BGSaveFixer

I will give this a try. Thanks. 

The two systems were set up maybe about a week apart, so the versions of the mods should still be the same. I guess one or two mods or features that don’t exist in the first system have caused the problem. Maybe I will try to uninstall them and see if that helps.

Link to post
3 hours ago, ensbana said:

Maybe I will try to uninstall them and see if that helps.

They won't. This is because the install order is permanent with it's effects to the dialog.tlk -file. You are better off with copying the entire game, like saids.

Link to post
15 hours ago, ensbana said:

I will give this a try. Thanks. 

The two systems were set up maybe about a week apart, so the versions of the mods should still be the same. I guess one or two mods or features that don’t exist in the first system have caused the problem. Maybe I will try to uninstall them and see if that helps.

Yes, mod features installed on one system and not on the other would do that.  The problem is with dialog.tlk, which is an index of strings.  The index stored in files in the baldur.gam or baldur.sav files still references the dialog.tlk on the other system which is not the same as your current dialog.tlk (and no, you can't just copy the other one, that will mess up other references).

What my fixer tool does is loop through the files stored in baldur.gam and baldur.sav, check out the real files on disk, and attempt to guess what the references should be from there.  Due to the way files are saved this unfortunately doesn't always work with .are files, but with NPC .cre files it usually does.

Brief how-to (for Windows): Copy the save_fixer folder into your game directory, then locate the baldur.gam and baldur.sav files in your latest save and copy them into save_fixer\old_save.  Locate a copy of weidu.exe (or grab the setup-xxx.exe from any other mod) and copy it as setup-save_fixer.exe in your game folder.  Run setup-savefixer.exe and choose option 1 to attempt to fix string references.  Afterwards, the changed baldur.gam and baldur.sav files will be in save_fixer\new_save, copy them back into your save game, then attempt to continue from that save.  Should anything go wrong, the old baldur.gam and baldur.sav are still in save_fixer\old_save.

While save_fixer works a lot like a WeiDU mod, it is not stored in weidu.log and can be run as many times as needed.

Edited by Angel
Link to post
12 hours ago, Angel said:

Yes, mod features installed on one system and not on the other would do that.  The problem is with dialog.tlk, which is an index of strings.  The index stored in files in the baldur.gam or baldur.sav files still references the dialog.tlk on the other system which is not the same as your current dialog.tlk (and no, you can't just copy the other one, that will mess up other references).

What my fixer tool does is loop through the files stored in baldur.gam and baldur.sav, check out the real files on disk, and attempt to guess what the references should be from there.  Due to the way files are saved this unfortunately doesn't always work with .are files, but with NPC .cre files it usually does.

Brief how-to (for Windows): Copy the save_fixer folder into your game directory, then locate the baldur.gam and baldur.sav files in your latest save and copy them into save_fixer\old_save.  Locate a copy of weidu.exe (or grab the setup-xxx.exe from any other mod) and copy it as setup-save_fixer.exe in your game folder.  Run setup-savefixer.exe and choose option 1 to attempt to fix string references.  Afterwards, the changed baldur.gam and baldur.sav files will be in save_fixer\new_save, copy them back into your save game, then attempt to continue from that save.  Should anything go wrong, the old baldur.gam and baldur.sav are still in save_fixer\old_save.

While save_fixer works a lot like a WeiDU mod, it is not stored in weidu.log and can be run as many times as needed.

I’ve just realized that the issue extends to containers like gem bags or bags of holding as well. Do you think this is related to the error that you mentioned, and if your tool could fix it?

 

 

Screenshot 2020-09-13 at 22.47.20 copy.jpg

Screenshot 2020-09-13 at 22.47.48 copy.jpg

Link to post

Yes, containers are implemented as stores and my fix should patch them up as well.  I repeat though that it is experimental, but it has fixed my game two or three times so far.

Link to post
14 minutes ago, ensbana said:

It worked! Thanks so much!

… not entirely though, unfortunately. The merchant at the Shadow Thieves’ Guild Hall still has that problem. 

Still, thanks for the fix. At least this fixes that annoying issue with the containers. 

Link to post
10 hours ago, ensbana said:

… not entirely though, unfortunately. The merchant at the Shadow Thieves’ Guild Hall still has that problem. 

Still, thanks for the fix. At least this fixes that annoying issue with the containers. 

Yes, with areas it doesn't always work.  Because of how the creatures are embedded in the area file, it's a little tricky to match embedded creatures to the original .cre file.  I'm still working on improving that, but not sure how far I'll get.

Link to post
Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...