Larian Banner: Baldur's Gate Patch 9
Previous Thread
Next Thread
Print Thread
Page 1 of 2 1 2
#597499 27/12/16 07:57 AM
Joined: Dec 2016
Location: United States
member
OP Offline
member
Joined: Dec 2016
Location: United States
Hello everyone,

I'm trying to publish my mod to steam, but the generated package is missing the entire data/public/mymod directory. Is there some extra step I need to take to include these? I have quite a few things that are supposed to appear there, such as stat files, scripts, textures, etc.

Hopefully there's an easy fix to this; thank you for your time!

Last edited by Ameranth; 27/12/16 08:00 AM.
Joined: Jun 2013
old hand
Offline
old hand
Joined: Jun 2013
I think this has happened to someone else before, you might try searching the forum.


One thing you can try to do is create a new mod with the same name in the editor and the game will generate a new UUID tag at the end. Then copy all your stuff to the new mod (don't forget the editor folder), make sure all the module settings and such are all set. Build the story. And see if it works that way.

Joined: Dec 2016
Location: United States
member
OP Offline
member
Joined: Dec 2016
Location: United States
Thanks for the reply, I'll give it a shot when I have some time later tonight.

Another question, though: I'm having trouble replacing the base scripts "_SKILL_Base" "Base" "DefaultCharacter" and "Player". If I have them located in Data/public/shared/scripts it works fine, but if I move them to Data/public/MyMod/scripts they no longer appear to replace their original versions.

This is a problem because, as far as I know, files in Data/public/shared won't get packaged for steam uploads.

Thank you again for your time!

Last edited by Ameranth; 27/12/16 09:46 PM.
Joined: Jun 2013
old hand
Offline
old hand
Joined: Jun 2013
Is this a main dependent mod or a standalone mod?

It sounds to me like you haven't imported those scripts.

I'm not entirely sure you can truly replace a shared/main script anyway though in an editor module. I think I tried it once and what ended up happening was I just had two versions of the script with the same name.

And all the characters had the shared one attached still so to change it would require manually opening the side bar of each character and adding the proper one.







Joined: Dec 2016
Location: United States
member
OP Offline
member
Joined: Dec 2016
Location: United States
This is a main dependent mod, the scripts are also imported. It works flawlessly with the scripts in public/shared, so it's odd that doing it from public/mymod doesn't work.

I suppose manually adding the script through the sidebar on every creature *is* an option, though I have already done it once and doing it again would be painful :P

Thanks for your input!

Joined: Jun 2013
old hand
Offline
old hand
Joined: Jun 2013
So if you have imported your versions of DefaultCharacter and such, are they listed twice in the script list?


I'm pretty sure that any scripts imported through the resource manager and located in Public/mymod will never overwrite the ones from shared because they have different location.


I'm not sure if there's a "Copy to my mod" function for charscripts. There is for story editor files.

Joined: Dec 2016
Location: United States
member
OP Offline
member
Joined: Dec 2016
Location: United States
Yeah, you're right--there are two copies of them in the script list (Even if they are placed in public/shared/scripts). There *is* a "Copy to my mod" function; though I don't know what it does.

If I do need to manually add my script variations to each creature, is there are easier way to modify them all at once rather than each separately?

I've seen that the "XC bags" mod contains the "base" charscript in public/mymod/scripts. I assume it *does* work, though I haven't tested it.

Last edited by Ameranth; 28/12/16 09:42 AM.
Joined: Sep 2015
A
addict
Offline
addict
A
Joined: Sep 2015
The problem with replacing scripts is that they are listed in the game resources ('Data\Public\Main\Content\Assets\Scripts' and '...Shared\Content\Assets\Scripts') with a unique ID and a folder location. If they're stored at a different location they'll get ignored.

The Base script, for example, is listed in 'Data\Public\Shared\Content\Assets\Scripts\[PAK]_Base\Base.lsb' with the following information:
Code
<node id="Resource">
							<attribute id="ID" value="ed3701ac-8b42-4ba9-b92f-6273a6f6b525" type="22" />
							<attribute id="Localized" value="False" type="19" />
							<attribute id="MapKey" value="ed3701ac-8b42-4ba9-b92f-6273a6f6b525" type="22" />
							<attribute id="Name" value="Base" type="23" />
							<attribute id="SourceFile" value="Public/Shared/Scripts/Base.charScript" type="30" />
							<children>


I had the same problem with my current mod project. There are two options:

1. Very inefficient: Adding the new versions of your scipts to the resources of your mod via Resource Manager and re-assigning them to all related characters (i. e. replacing the old script IDs in the character information with the new ones).
2. Best option (that's also what XC_Bags does): Adding the new version of the script to the resources of your mod via Resource Manager (the file will be in 'Data\Public\YourMod\Content' or a subfolder of the 'Content' folder, depending on what structure you create), converting the lsb file in your 'Content' folder to lsx with Norbyte's tool, converting the 'Base.lsb' from 'Public\Shared' to lsx, opening both lsx files with a text editor and replacing the ID and MapKey of the 'Base' script in your lsx with the original ID and MapKey in 'Base.lsx', and converting your file back to lsb.

If you have a great amount of scripts to replace you can also copy the relevant content lsbs of the main campaign to your content folder and just replace the location information (Shared or Main) with the script location of YourMod.

Edit: Unfortunately the 'Copy to my mod'-function of the Resource Manager still locates the script in Main or Shared (checked it in the content lsb of my mod), not YourMod, which makes it quite useless.

Last edited by Abraxas*; 28/12/16 01:31 PM. Reason: Addition

My mods for DOS 1 EE: FasterAnimations - QuietDay - Samaritan
Joined: Dec 2016
Location: United States
member
OP Offline
member
Joined: Dec 2016
Location: United States
This is exactly the kind of solution I was hoping for, Abraxas, thank you very much! I'll get started on trying it out.

Oh and, while we're at this, is there any way to have a modified english.xml file packaged and used in a steam upload? Many of the game's strings can be overwritten using your own localization files, but some of them, like the names and descriptions of talents/abilities, don't have their string keys listed anywhere that I could find, making english.xml editing the only way to modify them.

Also, is there any way to make requirements.txt work outside of public/shared?

Thank you for your insight!

Last edited by Ameranth; 28/12/16 09:13 PM.
Joined: Sep 2015
A
addict
Offline
addict
A
Joined: Sep 2015
Your welcome smile

I haven't dealt with localizations yet, so I can't help here.

As for Requirements: I know SniperHF and FrauBlake wanted to use this file for their mods but they couldn't. Doesn't seem to be possible. Only Larian can make the engine read this file from mod folders.



My mods for DOS 1 EE: FasterAnimations - QuietDay - Samaritan
Joined: Dec 2016
Location: United States
member
OP Offline
member
Joined: Dec 2016
Location: United States
I'm relatively okay with that--it unfortunately means that requirements.txt and english.xml will (sort of) need to be downloaded elsewhere for my mod, but the core of it will function with only the steam download, thanks to you guys.

As an update on what you suggested, SniperHF, I had to modify the content .lsb files--similarly to what Abraxas* had me do with the Scripts earlier--in order to have them all using the new uuid, but after completing the process the mod now appears to package all the files it should!

I'm ecstatic, I'll try to go for the upload soon, thank you both for your help; I've included special thanks for the both of you.


EDIT: Actually, something is still worrying me; the editor is showing the old mod uuid in addition to the new one (even after I deleted the old folders) when I choose which mod to open in the editor, could this be a problem? I replaced files in data/editor, data/mods/mymod, data/public/mymod.

Last edited by Ameranth; 28/12/16 10:25 PM.
Joined: Jun 2013
old hand
Offline
old hand
Joined: Jun 2013
It's probably showing the old one in the mod list because your .pak file from the old UUID version is still sitting in your mods folder.

Always delete or move the pak file after generating one otherwise the editor freaks out a bit when saving.

Joined: Dec 2016
Location: United States
member
OP Offline
member
Joined: Dec 2016
Location: United States
Yep, that was the problem, thanks for that smile

Joined: Jun 2015
F
enthusiast
Offline
enthusiast
F
Joined: Jun 2015
If you're willing to do the search, you can find the UUIDs (or GUIDs) of talents etc. in the .exe, EoCapp.exe. At least for a couple of things, I found some of them and could look them up in the English.xml file.
Just search for the internal talent names in the .exe, the ones you can also find in Requirements.txt. (Like 'Raistlin' for 'Glass Cannon' etc.)

If you create your own names and want to localize them, you need to unpack the file where your object is saved, add a handle="..." to the name entry and put that handle into the English.xml or whatever language you use.

Last edited by FrauBlake; 29/12/16 09:50 PM.
Joined: Dec 2016
Location: United States
member
OP Offline
member
Joined: Dec 2016
Location: United States
Interesting, thanks for the tip. Unfortunately I'd still need an outside download for requirements.txt though.

I'll definitely look into doing that at some point, I'm not sure where to start in searching the exe as you suggested though.

Joined: Jun 2015
F
enthusiast
Offline
enthusiast
F
Joined: Jun 2015
It was a very 'stupid' search I did, I loaded the .exe in Notepad++ and searched for known strings like 'Raistlin' (or something else, dont't remember anymore). In the vicinity of this string I found something that looked like the GUIDs (?) that are in the English.xml. I loaded English.xml, searched for this GUID and found found what I had expected.

So, it is a very stupid search but after all, the GUIDs must be somewhere in the .exe or else the game would have to work with hardcoded translations for every supported language.

As you have already seen, the TranslatedKeyString editor has absolutely nothing to do with localization or 'translation'.
(To provide translations, you'd also have to unpack these 'translated string key' files with Norbyte's tool and add handles manually.)


Last edited by FrauBlake; 02/01/17 02:00 AM.
Joined: Dec 2016
Location: United States
member
OP Offline
member
Joined: Dec 2016
Location: United States
Oh! I see. Hey man, if it works, it isn't stupid :P

I haven't tried it just yet, but I don't see why this method wouldn't work to replace these strings.

Joined: Dec 2016
Location: United States
member
OP Offline
member
Joined: Dec 2016
Location: United States
Unfortunately it doesn't seem to change anything with my first few tries. I used Comeback Kid as my test.

Using a fresh localization file, I have:

<?xml version="1.0" encoding="utf-8"?>
<save>
<header version="2" time="0" />
<version major="2" minor="0" revision="0" build="0" />
<region id="TranslatedStringKeys">
<node id="root">
<children>
<node id="TranslatedStringKey">
<attribute id="Content" value="abba" type="28" handle="hb15a53dbge70eg4ca7gba85g94f17e75c0e0" />
<attribute id="ExtraData" value="" type="23" />
<attribute id="Speaker" value="" type="22" />
<attribute id="Stub" value="True" type="19" />
<attribute id="UUID" value="ResistDead" type="22" />
</node>
</children>
</node>
</region>
</save>


"hb15a53dbge70eg4ca7gba85g94f17e75c0e0" is the handle corresponding to "Comeback Kid" in English.xml.

Note that I tried both "ResistDead" and "TALENT_ResistDead" for the UUID, as those were the only relevant looking things I could find in the .exe.

Last edited by Ameranth; 03/01/17 11:13 PM.
Joined: Jun 2015
F
enthusiast
Offline
enthusiast
F
Joined: Jun 2015
So you have some script that uses a function DisplayText( 'ResistDead', ... ) ? (don't remember the exact parameters.)
Or another function that uses a 'string key to translate' like the Osiris CharacterDisplayText() ?
And you want to display the string 'Comeback Kid' instead of 'abba' with it ?

Translated string keys don't come into play if you want to change talent descriptions. With those, the ID to look up in the localization file (English.xml) is directly in the .exe.
If you did that and it does not work, it might be the same problem that existed with 'Data\Public\Main mods' and MainLSF.pak: the English.xml is never read because there is already one English.pak in the Data\Localization directory. And this file exists for every installation, if you change the game language, you might have German.pak, French.pak, etc.
I never tried out any manipulation of English.xml, my question somewhere in last June if there was a simple way to do localization is still unanswered.

You can give it a try though if your changes work if you unpack English.pak and copy its contents plus your changed English.xml to the Localization directory and move English.pak away to a different location. (Not just rename which was sufficient for MainLSF.pak, but I guess, any file of any name might be read from this directory, because the engine cannot know, which language you want to use, thus move the file away instead of only renaming it.)

You already know that some things are always read from the default files even if you have them in your mod directory, Requirements.txt is such a case. Localization files might be another.
As long as no Raze and no developers step in and explain things to us, it's trial and error. That was half of my 'work' in XC_Bags ;-)

Btw. are you Steam's 'Sandpie' or 'the name I could never remember' ?

Joined: Dec 2016
Location: United States
member
OP Offline
member
Joined: Dec 2016
Location: United States
I'm not sure I understand--I was trying to change the talent name "Comback Kid" with "abba". I can already do this by directly modifying english.xml, but I was hoping to find a method that allowed me to do this without modifying english.xml, so that the changes can be part of a steam-distributable mod package file.

And yes, I am Sandpie on steam smile

Page 1 of 2 1 2

Link Copied to Clipboard
Powered by UBB.threads™ PHP Forum Software 7.7.5