mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-26 01:22:03 +00:00
## About The Pull Request This PR moves random name generation for species onto their languages. What does this mean? - For species with a predefined name list, such as Lizards and Moths, nothing. - For species without predefined name lists, such as Felinids, their names will now be randomly generated from their language's syllables.   (In the prefs menu:)  Why? - Well, we actually had some dead code that did this. All I did was fix it up and re-enable it. - Generates some pretty believable in-universe names for various languages that are lacking name lists. Obviously defined lists would be preferred, but until they are added, at least. - Moves some stuff off of species, which is always nice. - Also hopefully makes it a tad easier to work with name generation. There's now a standard framework for getting a random name for a mob, and for getting a random name based on a species. Misc: - Adds a generic `species_prototype` global, uses it in a lot of places in prefs code. - Makes `GLOB.species_list` init via the global defines - Deletes Language SS - Alphabetizes some instances of admin tooling using the list of all species IDs - Docs language stuff - Deletes random_skin_tone, it does pretty much nothin ## Changelog 🆑 Melbert refactor: Random Name Generation has been refactored. Report any instances of people having weird (or "Unknown") names. qol: Felinids, Slimepeople, Podpeople, and some other species without defined namelists now automatically generate names based on their primary language(s). qol: More non-human names can be generated in codewords (and other misc. areas) than just lizard names. /🆑
34 lines
1.6 KiB
Plaintext
34 lines
1.6 KiB
Plaintext
|
|
/datum/admins/proc/create_mob(mob/user)
|
|
var/static/create_mob_html
|
|
if (!create_mob_html)
|
|
var/mobjs = null
|
|
mobjs = jointext(typesof(/mob), ";")
|
|
create_mob_html = file2text('html/create_object.html')
|
|
create_mob_html = replacetext(create_mob_html, "Create Object", "Create Mob")
|
|
create_mob_html = replacetext(create_mob_html, "null /* object types */", "\"[mobjs]\"")
|
|
|
|
user << browse(create_panel_helper(create_mob_html), "window=create_mob;size=425x475")
|
|
|
|
/**
|
|
* Randomizes everything about a human, including DNA and name
|
|
*/
|
|
/proc/randomize_human(mob/living/carbon/human/human, randomize_mutations = FALSE)
|
|
human.gender = human.dna.species.sexes ? pick(MALE, FEMALE, PLURAL, NEUTER) : PLURAL
|
|
human.physique = human.gender
|
|
human.real_name = human.generate_random_mob_name()
|
|
human.name = human.get_visible_name()
|
|
human.set_hairstyle(random_hairstyle(human.gender), update = FALSE)
|
|
human.set_facial_hairstyle(random_facial_hairstyle(human.gender), update = FALSE)
|
|
human.set_haircolor("#[random_color()]", update = FALSE)
|
|
human.set_facial_haircolor(human.hair_color, update = FALSE)
|
|
human.eye_color_left = random_eye_color()
|
|
human.eye_color_right = human.eye_color_left
|
|
human.skin_tone = pick(GLOB.skin_tones)
|
|
human.dna.species.randomize_active_underwear_only(human)
|
|
// Needs to be called towards the end to update all the UIs just set above
|
|
human.dna.initialize_dna(newblood_type = random_blood_type(), create_mutation_blocks = randomize_mutations, randomize_features = TRUE)
|
|
// Snowflake for Ethereals
|
|
human.updatehealth()
|
|
human.updateappearance(mutcolor_update = TRUE)
|