(0079c13) Random name generator tweak needed?

I just uhhhh… embarked… and I got an NPC in my shelter with the same random generated name as me.

that’s all.

Murder your alternate self quickly before she kills and replaces you!

Well I dont know not really much of a bug given that you had a common name, there are only so many common last names and popular names.

The thing is that apart from the random “given+family” names, the generator can choose from “backer” names, which are treated as complete and unisex (regardless of whether or not they actually are). I understand the reason behind that, but it still leads to these kinda things.

Right now there’s 213 given names (combined M+F), and 104 family names. And 139 backer names. I don’t know the exact mechanism for choosing between a “backer” and a “given+family” name for random generation, but I think it’s pretty clear that we can do far better on the names front. A five second google gave me a page with the “top 1000 baby names in the US for 2011”. That a thousand given names each, male and female. A further five-second google gave me a site with over five thousand US surnames.

Surely it can’t be too much to ask to implement them all? Somebody did go through the trouble of pasting over 20 thousand “world” names into the game, after all. :wink:

Okay, so there is apparently a flat chance that a backer name will be chosen when randomly generated, and even has a default value to prevent the function from failing if the json has no backer names to choose from.

I understand that the contributions of the backers allowed this game to be where it is today, but when you have a one-in-five chance that a character or an NPC will receive a name from a much shorter list of sometimes much less fitting names, it tends to become noticeable.

Regardless, until that particular element is fixed (maybe make it so that the chance is based on the total number of names available?) there’s nothing to be done about it, so here’s my take on the english-language names file: link. 1219 male given names, 4275 female given names (don’t ask why so many, I just copied the whole damn list), and 3000 family names, because I couldn’t be bothered to paste the whole 20000+ list 1000 lines at a time, even though I probably could.

Working as intended, though it’d be a great easter egg to have the conversation tree react to it.

Though adding some more names to the list wouldn’t be amiss. Thanks for doing the legwork on this.

“You mean your name is Zaphod Beeblebrox, too? What a coincidence!”

Can we at least lower the chances of backer names appearing? Or perhaps leave them as is, but only for NPC names, leaving player generation with purely random names? It’s honestly irritating to have the same (male) name pop up three or four times when randomly generating a good-sounding name for a female character.

Would be more elegant to flag backer names once an NPC (or the PC themself) is generated with them, and remove them from the name pool after that, so that they’re unique in each game.

Edit: Oh, I see your objection. Well, they should probably be assigned genders, but I don’t envy anyone that particular task.

[quote=“halberdsturgeon, post:8, topic:5516”]Would be more elegant to flag backer names once an NPC (or the PC themself) is generated with them, and remove them from the name pool after that, so that they’re unique in each game.

Edit: Oh, I see your objection. Well, they should probably be assigned genders, but I don’t envy anyone that particular task.[/quote]There are just 139 backer names. Editing gender tags is hilariously easy. If anyone wants it done, I’m on it.

edit: and done, same link. I’ll see if I can just PR it, I guess.

https://github.com/CleverRaven/Cataclysm-DDA/pull/6830 (for completions sake).

Sucks that there are so few names from other languages. Perhaps we could get more submissions for that.