How to add new random names?

Users who are viewing this thread

So upon looking at the spcultures.xml file in the SandBoxCore\ModuleData\ folder, I found the random names list that the game uses for generated characters. However, this is what it looks like:
Code:
<name name="{=aeLgc0cU}Acthon" />

What is this code-like structure before the actual name? It seems to be unique for every character, so I imagine it's some kind of UID of some sort. What purpose does it serve, and do I need to generate one somehow for every name I add to this list?
 
Solution
I still don't know what the code text is for but it doesn't seem to be important.

XML:
<name name="{=aeLgc0cU}Acthon" />

<!-- from std_spcultures_xml.xml -->
<string id="aeLgc0cU" text="Acthon" />
C#:
        public TextObject(string value = "", Dictionary<string, TextObject> attributes = null)
        {
            this.Value = value;
            this.Attributes = attributes;
        }
Not sure of anything at this early stage with bannerlord...
I'm gonna try adding a bunch of names that don't have them and see what happens.

I actually just want more variety, since in my current game there's multiple NPCs with the same exact name (yes including their title/last name thing). Visible in the Encyclopedia, and you can see there that they're actually different people of course, but they got randomly assigned the same names. I figure more random names will help reduce the chance of this happening.


- edit: I have tested it and it seems to work so far. Some random Wanderers spawned using some of the random names I added to the list. I still don't know what the code text is for but it doesn't seem to be important.
 
Last edited:
Upvote 0
I still don't know what the code text is for but it doesn't seem to be important.

XML:
<name name="{=aeLgc0cU}Acthon" />

<!-- from std_spcultures_xml.xml -->
<string id="aeLgc0cU" text="Acthon" />
C#:
        public TextObject(string value = "", Dictionary<string, TextObject> attributes = null)
        {
            this.Value = value;
            this.Attributes = attributes;
        }
Not sure of anything at this early stage with bannerlord...
 
Upvote 0
Solution
Hmm interesting. Good find, thanks. I suppose I can just make a simple random UID generator to make it work with that.

Hopefully when the official modding tools come out, all this stuff will be automated/built-in to that so we just need to worry about the actual names.
 
Upvote 0
Back
Top Bottom