Author Topic: Customised NPRs  (Read 1413 times)

0 Members and 1 Guest are viewing this topic.

Offline Steve Walmsley (OP)

  • Aurora Designer
  • Star Marshal
  • S
  • Posts: 11669
  • Thanked: 20440 times
Customised NPRs
« on: November 29, 2023, 11:51:46 AM »
I've been working on a new option for game start, that allows you to customise NPRs, while still retaining a reasonable degree of randomness. Essentially, if you click a 'Customise NPR' checkbox on game start, you will get one popup window for each NPR as part of the game creation process. So far, this allows you to alter the following options, or leave the random option generated before the window is displayed.
  • Race Name, Race Title and Home World name
  • Images for Race, Flag, Ship and Station
  • Commander Naming Theme and Rank Theme
  • Name Themes for Systems, Classes, Ground Forces and Missiles
  • Species characteristics such as Xenophobia, Determination, etc.
  • Production, Research and Growth modifiers
  • Starting Tech Point and Build Point modifiers
  • Ship Size modifier
  • If the Race uses Shields: Yes, No or Random
  • If the Race uses Missiles: Yes, No or Random
  • Primary Beam Weapon: Random, Laser, Railgun, Particle or Carronade
  • Point Defence Beam Weapon: Random, Laser, Railgun or Gauss
  • Starting System and a list of acceptable Dominant Terrain

(snipping Star Trek Locations text as this is now in a new thread)
« Last Edit: November 30, 2023, 05:38:44 AM by Steve Walmsley »
 

Offline Desdinova

  • Lt. Commander
  • ********
  • D
  • Posts: 280
  • Thanked: 280 times
Re: Customised NPRs and Star Trek System Locations
« Reply #1 on: November 29, 2023, 12:22:59 PM »
I would just like to be able to make a pass to check that NPRs aren't being created with silly names as they're frequently generated with real-world place names.
 

Offline alex_brunius

  • Vice Admiral
  • **********
  • Posts: 1240
  • Thanked: 153 times
Re: Customised NPRs and Star Trek System Locations
« Reply #2 on: November 29, 2023, 12:34:27 PM »
 

Offline Steve Walmsley (OP)

  • Aurora Designer
  • Star Marshal
  • S
  • Posts: 11669
  • Thanked: 20440 times
Re: Customised NPRs and Star Trek System Locations
« Reply #3 on: November 29, 2023, 12:44:20 PM »
Thanks for the maps. The main issue is that in many cases the maps refer to the names from Star Trek, rather than the actual system names. Star Trek is setup within real space and uses many real system names, but then throws invented systems into the mix too, either without a real-world equivalent, or without mentioning the real world name. Some fans have interpreted locations based on nearby real stars, based on proximity on the maps.
 

Offline Steve Walmsley (OP)

  • Aurora Designer
  • Star Marshal
  • S
  • Posts: 11669
  • Thanked: 20440 times
Re: Customised NPRs and Star Trek System Locations
« Reply #4 on: November 29, 2023, 12:46:24 PM »
I would just like to be able to make a pass to check that NPRs aren't being created with silly names as they're frequently generated with real-world place names.

If you can outline the 'non-silly name' logic, I would be happy to implement it :)
 

Offline nuclearslurpee

  • Admiral of the Fleet
  • ***********
  • Posts: 2982
  • Thanked: 2243 times
  • Radioactive frozen beverage.
Re: Customised NPRs and Star Trek System Locations
« Reply #5 on: November 29, 2023, 12:52:55 PM »
I would just like to be able to make a pass to check that NPRs aren't being created with silly names as they're frequently generated with real-world place names.

If you can outline the 'non-silly name' logic, I would be happy to implement it :)

I suspect that the main 'fix' would be to remove a lot of the names from the DB - for example, names that are real places, animals, etc. - and just leave the names that are suitably alien or fantasy-sounding.

Of course, the problem is that no one will agree on which names are silly and which are not. Is a race called "Bobcat Hierarchy", to use a current example in my test game, too silly to believe, or would humans name an alien race that looked like bobcats as the Bobcats race because that's what humans do? We already had Boaty McBoatyface...

I think the proposed functionality would be a good compromise, actually I would also find it useful to make sure that the NPRs have consistent naming schemes as well.

BTW, will this feature also be used for newly-generated races? I'd use it for the same reasons if so... One other thing I would suggest is having somewhere the option to change the names for ruins races as well, these often tend to be silly and unlike NPRs we cannot change their name in the Intel window to be more reasonable.
 

Offline Steve Walmsley (OP)

  • Aurora Designer
  • Star Marshal
  • S
  • Posts: 11669
  • Thanked: 20440 times
Re: Customised NPRs and Star Trek System Locations
« Reply #6 on: November 29, 2023, 01:01:21 PM »
I would just like to be able to make a pass to check that NPRs aren't being created with silly names as they're frequently generated with real-world place names.

If you can outline the 'non-silly name' logic, I would be happy to implement it :)

I suspect that the main 'fix' would be to remove a lot of the names from the DB - for example, names that are real places, animals, etc. - and just leave the names that are suitably alien or fantasy-sounding.

Of course, the problem is that no one will agree on which names are silly and which are not. Is a race called "Bobcat Hierarchy", to use a current example in my test game, too silly to believe, or would humans name an alien race that looked like bobcats as the Bobcats race because that's what humans do? We already had Boaty McBoatyface...

I think the proposed functionality would be a good compromise, actually I would also find it useful to make sure that the NPRs have consistent naming schemes as well.

BTW, will this feature also be used for newly-generated races? I'd use it for the same reasons if so... One other thing I would suggest is having somewhere the option to change the names for ruins races as well, these often tend to be silly and unlike NPRs we cannot change their name in the Intel window to be more reasonable.

Some real place names make very good sci-fi names - the problem is deciding which and who makes the decision. Its not something that can be solved by code. Players can always go into the DB and delete themes they don't like though. The renaming on the Intelligence window was a way to deal with anything too outlandish.

This feature is intended for initial game setup. A race generated mid-game would already have a system and a planet created, so some of the functionality wouldn't work. Also, having a window popup on mid-game race generation would remove any fog-of-war and spoil immersion. The name change for ruin races can be handled separately though.
 
The following users thanked this post: nuclearslurpee

Offline Desdinova

  • Lt. Commander
  • ********
  • D
  • Posts: 280
  • Thanked: 280 times
Re: Customised NPRs and Star Trek System Locations
« Reply #7 on: November 29, 2023, 03:16:50 PM »
I would just like to be able to make a pass to check that NPRs aren't being created with silly names as they're frequently generated with real-world place names.

If you can outline the 'non-silly name' logic, I would be happy to implement it :)


Well, the real solution would be to create a random name generator. Of course it takes a lot of work to generate aesthetically pleasing results. Here's a quick and dirty java random name generator I threw together to generate some alien-sounding names:

Code: [Select]
import java.util.Random;

public class RandomNameGenerator
{
String plosives = "ptkbdg";
String onsets = "ptkbsfhjmnvz";
String codas = "tkbdgsmnrl";
String onset_medials = "rlwy";
String coda_medials = "rln";
String vowels = "aeiou";

int onset_chance = 80;
int onset_medial_chance = 20;
int coda_chance = 80;
int coda_medial_chance = 10;
int dipthong_chance = 10;

Random rand;

public RandomNameGenerator()
{
rand = new Random();
rand.setSeed(System.currentTimeMillis());
}

public char GetRandomLetter(String str)
{
int len = str.length();
int num = rand.nextInt(len);
return str.charAt(num);
}

public String GenerateSyllable()
{
String ret = new String();

if (rand.nextInt(100) <= onset_medial_chance)
{
ret += GetRandomLetter(plosives);
ret += GetRandomLetter(onset_medials);
}
else if (rand.nextInt(100) <= onset_chance) ret += GetRandomLetter(onsets);
ret += GetRandomLetter(vowels);
if (rand.nextInt(100) <= dipthong_chance) ret += GetRandomLetter(vowels);
if (rand.nextInt(100) <= coda_medial_chance)
{
ret += GetRandomLetter(coda_medials);
ret += GetRandomLetter(codas);
}
else if (rand.nextInt(100) <= coda_chance) ret += GetRandomLetter(codas);
return ret;
}

public String GenerateWord()
{
String ret = new String();
for (int x = rand.nextInt(2) + 2; x > 0; x-- )
{
ret += GenerateSyllable();
}
return ret;
}
}

public class Main
{
public static void main(String[] args)
{
RandomNameGenerator rng = new RandomNameGenerator();
Random rand = new Random();
rand.setSeed(System.currentTimeMillis());

String str = new String();
for (int x = 100; x > 0; x-- )
{
System.out.println(rng.GenerateWord());
}
}
}

Sample output:
Code: [Select]
proknim
faporfur
varpyis
aram
gyoknabmalm
onno
ursklusbom
kotkwos
kebturnor
haktas
pyidpud
sonkras
pletkuteag
kweethabfers
tudwahei
kubaimkunk
folotoenb
mekputblun
toleu
bwikkogklo
eban
kamugseg
kebraok
ohailhog
pamfag
vukwur
zitdwarhod
neudom
krulmozat
zafols
utnalam
sekseln
utmagbe
felfudjoab
suneg
tenzont
bugsem
mobprurgtild
ermbyub
pobonis
nurha
pugfoddlaat
grurkfilvok
umplid
unulkug
tadmorkkwol
tildkweug
hudyassis
obkaan
akanfes
ponum
torembyeb
muldnib
fihunfa
binskyebkus
blanhab
funkbut
niges
arut
erbyot
gwanrji
fileod
basdwaad
sunhinmua
nunhed
adton
krumuktward
huljud
tigbas
sannos
mimbu
dranjus
vorbaanat
kyurmad
dwasadton
kleaitdyug
aamjirs
tirpalmulg
netbek
faltukgwol
mulhut
jubog
mobzo
judyolvarm
kusan
ulkrugun
gyizurbvum
brenminhid
immet
kwerpiddlont
kobzeukzuurt
bozuub
twilgtlotam
ikpoer
pitmull
kridipiak
zukka
sajersplon
tutvim
draoglaal

A more elegant solution might be to use the real-world database names as a starting point, and then apply random changes, for example, change out one consonant for another, remove syllables, etc.
 

Offline KriegsMeister

  • Chief Petty Officer
  • ***
  • K
  • Posts: 34
  • Thanked: 19 times
Re: Customised NPRs and Star Trek System Locations
« Reply #8 on: November 29, 2023, 07:58:48 PM »
Can we get that system/planet picking function for player races as well? I plan on starting a new campaign with new human settlements on nearby stars that got there via generation ships. I've done a similar campaign before but had to use the space master grav survey to explore dozens of systems before finding the ones I wanted, than going back through to clean up and undiscover the fillers was super tedious
 
The following users thanked this post: nuclearslurpee

Offline nuclearslurpee

  • Admiral of the Fleet
  • ***********
  • Posts: 2982
  • Thanked: 2243 times
  • Radioactive frozen beverage.
Re: Customised NPRs and Star Trek System Locations
« Reply #9 on: November 29, 2023, 08:58:42 PM »
Can we get that system/planet picking function for player races as well? I plan on starting a new campaign with new human settlements on nearby stars that got there via generation ships. I've done a similar campaign before but had to use the space master grav survey to explore dozens of systems before finding the ones I wanted, than going back through to clean up and undiscover the fillers was super tedious

I would second this, as it while the Create Habitable System button is nice this would remove a couple of steps and not require a separate SM race to handle everything (unless you want your first player race to know of all other home systems).
 

Offline QuakeIV

  • Registered
  • Commodore
  • **********
  • Posts: 759
  • Thanked: 168 times
Re: Customised NPRs and Star Trek System Locations
« Reply #10 on: November 29, 2023, 10:05:07 PM »
I would just like to be able to make a pass to check that NPRs aren't being created with silly names as they're frequently generated with real-world place names.

If you can outline the 'non-silly name' logic, I would be happy to implement it :)

I think what he is saying is he would just like to be able to manually check.  Algorithm would be HumanBrainV1.0
 

Offline Steve Walmsley (OP)

  • Aurora Designer
  • Star Marshal
  • S
  • Posts: 11669
  • Thanked: 20440 times
Re: Customised NPRs and Star Trek System Locations
« Reply #11 on: November 30, 2023, 05:06:14 AM »
Can we get that system/planet picking function for player races as well? I plan on starting a new campaign with new human settlements on nearby stars that got there via generation ships. I've done a similar campaign before but had to use the space master grav survey to explore dozens of systems before finding the ones I wanted, than going back through to clean up and undiscover the fillers was super tedious

You can use Create Habitable to do that now for player races. Click the button and pick a system and it will generate a habitable planet in that system. You may still need to adjust though for a human species.

Also this new NPR generation system won't necessarily help you. Its designed to create a planet based on selected terrain and then generate a race based on the resulting planet. It isn't designed to generate a planet suitable for an existing species. That would require a different set of code. I might add that in the future, but I want to check this is working fine first.
« Last Edit: November 30, 2023, 05:21:24 AM by Steve Walmsley »
 

Offline Steve Walmsley (OP)

  • Aurora Designer
  • Star Marshal
  • S
  • Posts: 11669
  • Thanked: 20440 times
Re: Customised NPRs and Star Trek System Locations
« Reply #12 on: November 30, 2023, 05:07:12 AM »
I would just like to be able to make a pass to check that NPRs aren't being created with silly names as they're frequently generated with real-world place names.

If you can outline the 'non-silly name' logic, I would be happy to implement it :)

I think what he is saying is he would just like to be able to manually check.  Algorithm would be HumanBrainV1.0

Using this logic, every time a new race is generated, you would need a pop-up to name it, even though you don't necessarily know the race was just generated. I think that would spoil fog-of-war and break immersion, especially when enter a new system and get the 'new name' popup.

You can rename new races already as soon as they are detected. I thought the idea was to generate 'non-silly-names' behind the scenes.
« Last Edit: November 30, 2023, 05:40:58 AM by Steve Walmsley »
 

Offline Steve Walmsley (OP)

  • Aurora Designer
  • Star Marshal
  • S
  • Posts: 11669
  • Thanked: 20440 times
Re: Customised NPRs and Star Trek System Locations
« Reply #13 on: November 30, 2023, 05:29:14 AM »
I would just like to be able to make a pass to check that NPRs aren't being created with silly names as they're frequently generated with real-world place names.

If you can outline the 'non-silly name' logic, I would be happy to implement it :)


Well, the real solution would be to create a random name generator. Of course it takes a lot of work to generate aesthetically pleasing results. Here's a quick and dirty java random name generator I threw together to generate some alien-sounding names:

Code: [Select]
import java.util.Random;

public class RandomNameGenerator
{
String plosives = "ptkbdg";
String onsets = "ptkbsfhjmnvz";
String codas = "tkbdgsmnrl";
String onset_medials = "rlwy";
String coda_medials = "rln";
String vowels = "aeiou";

int onset_chance = 80;
int onset_medial_chance = 20;
int coda_chance = 80;
int coda_medial_chance = 10;
int dipthong_chance = 10;

Random rand;

public RandomNameGenerator()
{
rand = new Random();
rand.setSeed(System.currentTimeMillis());
}

public char GetRandomLetter(String str)
{
int len = str.length();
int num = rand.nextInt(len);
return str.charAt(num);
}

public String GenerateSyllable()
{
String ret = new String();

if (rand.nextInt(100) <= onset_medial_chance)
{
ret += GetRandomLetter(plosives);
ret += GetRandomLetter(onset_medials);
}
else if (rand.nextInt(100) <= onset_chance) ret += GetRandomLetter(onsets);
ret += GetRandomLetter(vowels);
if (rand.nextInt(100) <= dipthong_chance) ret += GetRandomLetter(vowels);
if (rand.nextInt(100) <= coda_medial_chance)
{
ret += GetRandomLetter(coda_medials);
ret += GetRandomLetter(codas);
}
else if (rand.nextInt(100) <= coda_chance) ret += GetRandomLetter(codas);
return ret;
}

public String GenerateWord()
{
String ret = new String();
for (int x = rand.nextInt(2) + 2; x > 0; x-- )
{
ret += GenerateSyllable();
}
return ret;
}
}

public class Main
{
public static void main(String[] args)
{
RandomNameGenerator rng = new RandomNameGenerator();
Random rand = new Random();
rand.setSeed(System.currentTimeMillis());

String str = new String();
for (int x = 100; x > 0; x-- )
{
System.out.println(rng.GenerateWord());
}
}
}

Sample output:
Code: [Select]
proknim
faporfur
varpyis
aram
gyoknabmalm
onno
ursklusbom
kotkwos
kebturnor
haktas
pyidpud
sonkras
pletkuteag
kweethabfers
tudwahei
kubaimkunk
folotoenb
mekputblun
toleu
bwikkogklo
eban
kamugseg
kebraok
ohailhog
pamfag
vukwur
zitdwarhod
neudom
krulmozat
zafols
utnalam
sekseln
utmagbe
felfudjoab
suneg
tenzont
bugsem
mobprurgtild
ermbyub
pobonis
nurha
pugfoddlaat
grurkfilvok
umplid
unulkug
tadmorkkwol
tildkweug
hudyassis
obkaan
akanfes
ponum
torembyeb
muldnib
fihunfa
binskyebkus
blanhab
funkbut
niges
arut
erbyot
gwanrji
fileod
basdwaad
sunhinmua
nunhed
adton
krumuktward
huljud
tigbas
sannos
mimbu
dranjus
vorbaanat
kyurmad
dwasadton
kleaitdyug
aamjirs
tirpalmulg
netbek
faltukgwol
mulhut
jubog
mobzo
judyolvarm
kusan
ulkrugun
gyizurbvum
brenminhid
immet
kwerpiddlont
kobzeukzuurt
bozuub
twilgtlotam
ikpoer
pitmull
kridipiak
zukka
sajersplon
tutvim
draoglaal

A more elegant solution might be to use the real-world database names as a starting point, and then apply random changes, for example, change out one consonant for another, remove syllables, etc.

To be honest, I would rather have real-world names than gibberish that doesn't mean anything. But again, this is down to personal preference, which is why it is so hard to agree a definition of 'non-silly names' because the above seem like silly names to me.
 
The following users thanked this post: Black

Offline Garfunkel

  • Registered
  • Admiral of the Fleet
  • ***********
  • Posts: 2791
  • Thanked: 1052 times
Re: Customised NPRs
« Reply #14 on: November 30, 2023, 07:44:06 AM »
Yeah, I agree. My pet peeve with both fantasy and sci-fi authors is when they cobble together nonsense gobbledygook to pretend it as an alien language. Either go full Tolkien and make up an entire language or just use normal words and say it's a translation.
 
The following users thanked this post: BAGrimm, nuclearslurpee