Added Skrell blurb, also added language/species-based random name generator.

This commit is contained in:
Zuhayr
2014-12-11 15:11:35 +10:30
parent 62c6a4808c
commit 0c448de7c9
4 changed files with 73 additions and 8 deletions

View File

@@ -38,8 +38,18 @@ proc/random_facial_hair_style(gender, species = "Human")
return f_style return f_style
proc/random_name(gender, species = "Human") proc/random_name(gender, species = "Human")
if(gender==FEMALE) return capitalize(pick(first_names_female)) + " " + capitalize(pick(last_names))
else return capitalize(pick(first_names_male)) + " " + capitalize(pick(last_names)) var/datum/species/current_species
if(species)
current_species = all_species[species]
if(!current_species)
if(gender==FEMALE)
return capitalize(pick(first_names_female)) + " " + capitalize(pick(last_names))
else
return capitalize(pick(first_names_male)) + " " + capitalize(pick(last_names))
else
return current_species.get_random_name(gender)
proc/random_skin_tone() proc/random_skin_tone()
switch(pick(60;"caucasian", 15;"afroamerican", 10;"african", 10;"latino", 5;"albino")) switch(pick(60;"caucasian", 15;"afroamerican", 10;"african", 10;"latino", 5;"albino"))

View File

@@ -139,7 +139,7 @@ datum/preferences
if(load_character()) if(load_character())
return return
gender = pick(MALE, FEMALE) gender = pick(MALE, FEMALE)
real_name = random_name(gender) real_name = random_name(gender,species)
gear = list() gear = list()
@@ -1144,7 +1144,7 @@ datum/preferences
if("random") if("random")
switch(href_list["preference"]) switch(href_list["preference"])
if("name") if("name")
real_name = random_name(gender) real_name = random_name(gender,species)
if("age") if("age")
age = rand(AGE_MIN, AGE_MAX) age = rand(AGE_MIN, AGE_MAX)
if("hair") if("hair")
@@ -1603,7 +1603,7 @@ datum/preferences
/datum/preferences/proc/copy_to(mob/living/carbon/human/character, safety = 0) /datum/preferences/proc/copy_to(mob/living/carbon/human/character, safety = 0)
if(be_random_name) if(be_random_name)
real_name = random_name(gender) real_name = random_name(gender,species)
if(config.humans_need_surnames) if(config.humans_need_surnames)
var/firstspace = findtext(real_name, " ") var/firstspace = findtext(real_name, " ")

View File

@@ -17,6 +17,24 @@
var/list/syllables // Used when scrambling text for a non-speaker. var/list/syllables // Used when scrambling text for a non-speaker.
var/list/space_chance = 55 // Likelihood of getting a space in the random scramble string. var/list/space_chance = 55 // Likelihood of getting a space in the random scramble string.
/datum/language/proc/get_random_name(var/gender, name_count=2, syllable_count=4)
if(!syllables || !syllables.len)
if(gender==FEMALE)
return capitalize(pick(first_names_female)) + " " + capitalize(pick(last_names))
else
return capitalize(pick(first_names_male)) + " " + capitalize(pick(last_names))
var/full_name = ""
var/new_name = ""
for(var/i = 0;i<name_count;i++)
new_name = ""
for(var/x = rand(Floor(syllable_count/2),syllable_count);x>0;x--)
new_name += pick(syllables)
full_name += " [capitalize(lowertext(new_name))]"
return "[trim(full_name)]"
/datum/language/proc/scramble(var/input) /datum/language/proc/scramble(var/input)
if(!syllables || !syllables.len) if(!syllables || !syllables.len)
@@ -105,6 +123,13 @@
flags = WHITELISTED flags = WHITELISTED
syllables = list("ss","ss","ss","ss","skak","seeki","resh","las","esi","kor","sh") syllables = list("ss","ss","ss","ss","skak","seeki","resh","las","esi","kor","sh")
/datum/language/unathi/get_random_name()
var/new_name = ..()
while(findtextEx(new_name,"sss",1,null))
new_name = replacetext(new_name, "sss", "ss")
return capitalize(new_name)
/datum/language/tajaran /datum/language/tajaran
name = "Siik'tajr" name = "Siik'tajr"
desc = "The traditionally employed tongue of Ahdomai, composed of expressive yowls and chirps. Native to the Tajaran." desc = "The traditionally employed tongue of Ahdomai, composed of expressive yowls and chirps. Native to the Tajaran."
@@ -119,6 +144,15 @@
"ka","aasi","far","wa","baq","ara","qara","zir","sam","mak","hrar","nja","rir","khan","jun","dar","rik","kah", \ "ka","aasi","far","wa","baq","ara","qara","zir","sam","mak","hrar","nja","rir","khan","jun","dar","rik","kah", \
"hal","ket","jurl","mah","tul","cresh","azu","ragh") "hal","ket","jurl","mah","tul","cresh","azu","ragh")
/datum/language/tajaran/get_random_name(var/gender)
var/new_name = ..(gender,1)
if(prob(80))
new_name += " [pick(list("Hadii","Kaytam","Zhan-Khazan","Hharar","Njarir'Akhan"))]"
else
new_name += ..(gender,1)
return new_name
/datum/language/skrell /datum/language/skrell
name = "Skrellian" name = "Skrellian"
desc = "A melodic and complex language spoken by the Skrell of Qerrbalak. Some of the notes are inaudible to humans." desc = "A melodic and complex language spoken by the Skrell of Qerrbalak. Some of the notes are inaudible to humans."
@@ -128,7 +162,7 @@
colour = "skrell" colour = "skrell"
key = "k" key = "k"
flags = WHITELISTED flags = WHITELISTED
syllables = list("wub","wub","wub","wub","wub","wub","wub","WUB","vwwwworp","SO-LET-THE-BEAT-DROP") syllables = list("qr","qrr","xuq","qil","quum","xuqm","vol","xrim","zaoo","qu-uu","qix","qoo","zix","*","!")
/datum/language/vox /datum/language/vox
name = "Vox-pidgin" name = "Vox-pidgin"
@@ -138,10 +172,13 @@
exclaim_verb = "SHRIEKS" exclaim_verb = "SHRIEKS"
colour = "vox" colour = "vox"
key = "5" key = "5"
flags = RESTRICTED flags = WHITELISTED
syllables = list("ti","ti","ti","hi","hi","ki","ki","ki","ki","ya","ta","ha","ka","ya","chi","cha","kah", \ syllables = list("ti","ti","ti","hi","hi","ki","ki","ki","ki","ya","ta","ha","ka","ya","chi","cha","kah", \
"SKRE","AHK","EHK","RAWK","KRA","AAA","EEE","KI","II","KRI","KA") "SKRE","AHK","EHK","RAWK","KRA","AAA","EEE","KI","II","KRI","KA")
/datum/language/vox/get_random_name()
return ..(FEMALE,1,6)
/datum/language/diona /datum/language/diona
name = "Rootspeak" name = "Rootspeak"
desc = "A creaking, subvocal language spoken instinctively by the Dionaea. Due to the unique makeup of the average Diona, a phrase of Rootspeak can be a combination of anywhere from one to twelve individual voices and notes." desc = "A creaking, subvocal language spoken instinctively by the Dionaea. Due to the unique makeup of the average Diona, a phrase of Rootspeak can be a combination of anywhere from one to twelve individual voices and notes."
@@ -153,6 +190,11 @@
flags = RESTRICTED flags = RESTRICTED
syllables = list("hs","zt","kr","st","sh") syllables = list("hs","zt","kr","st","sh")
/datum/language/diona/get_random_name()
var/new_name = "[pick(list("To Sleep Beneath","Wind Over","Embrace of","Dreams of","Witnessing","To Walk Beneath","Approaching the"))]"
new_name += " [pick(list("the Void","the Sky","Encroaching Night","Planetsong","Starsong","the Wandering Star","the Empty Day","Daybreak","Nightfall","the Rain"))]"
return new_name
/datum/language/common /datum/language/common
name = "Galactic Common" name = "Galactic Common"
desc = "The common galactic tongue." desc = "The common galactic tongue."

View File

@@ -25,7 +25,7 @@
var/unarmed_type = /datum/unarmed_attack var/unarmed_type = /datum/unarmed_attack
var/secondary_unarmed_type = /datum/unarmed_attack/bite var/secondary_unarmed_type = /datum/unarmed_attack/bite
var/language // Default racial language, if any. var/language = "Galactic Common" // Default racial language, if any.
// Default language is used when 'say' is used without modifiers. // Default language is used when 'say' is used without modifiers.
var/default_language = "Galactic Common" var/default_language = "Galactic Common"
var/secondary_langs = list() // The names of secondary languages that are available to this species. var/secondary_langs = list() // The names of secondary languages that are available to this species.
@@ -102,6 +102,10 @@
if(unarmed_type) unarmed = new unarmed_type() if(unarmed_type) unarmed = new unarmed_type()
if(secondary_unarmed_type) secondary_unarmed = new secondary_unarmed_type() if(secondary_unarmed_type) secondary_unarmed = new secondary_unarmed_type()
/datum/species/proc/get_random_name(var/gender)
var/datum/language/species_language = all_languages[language]
return species_language.get_random_name(gender)
/datum/species/proc/create_organs(var/mob/living/carbon/human/H) //Handles creation of mob organs. /datum/species/proc/create_organs(var/mob/living/carbon/human/H) //Handles creation of mob organs.
//Trying to work out why species changes aren't fixing organs properly. //Trying to work out why species changes aren't fixing organs properly.
@@ -291,6 +295,11 @@
language = "Skrellian" language = "Skrellian"
primitive = /mob/living/carbon/monkey/skrell primitive = /mob/living/carbon/monkey/skrell
unarmed_type = /datum/unarmed_attack/punch unarmed_type = /datum/unarmed_attack/punch
blurb = "An amphibious species, Skrell come from the star system known as Qerr'Vallis, which translates to 'Star of \
the royals' or 'Light of the Crown'.<br/><br/>Skrell are a highly advanced and logical race who live under the rule \
of the Qerr'Katish, a caste within their society which keeps the empire of the Skrell running smoothly. Skrell are \
herbivores on the whole and tend to be co-operative with the other species of the galaxy, although they rarely reveal \
the secrets of their empire to their allies."
flags = IS_WHITELISTED | HAS_LIPS | HAS_UNDERWEAR | HAS_SKIN_COLOR flags = IS_WHITELISTED | HAS_LIPS | HAS_UNDERWEAR | HAS_SKIN_COLOR
@@ -353,6 +362,10 @@
"stack" = /datum/organ/internal/stack/vox "stack" = /datum/organ/internal/stack/vox
) )
/datum/species/vox/get_random_name(var/gender)
var/datum/language/species_language = all_languages[default_language]
return species_language.get_random_name(gender)
/datum/species/vox/armalis /datum/species/vox/armalis
name = "Vox Armalis" name = "Vox Armalis"
name_plural = "Vox" name_plural = "Vox"