mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-10 09:42:29 +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. /🆑
32 lines
1.4 KiB
Plaintext
32 lines
1.4 KiB
Plaintext
|
|
/**
|
|
* Checks that all enabled roundstart species
|
|
* selectable within the preferences menu
|
|
* have their info / page setup correctly.
|
|
*/
|
|
/datum/unit_test/preference_species
|
|
|
|
/datum/unit_test/preference_species/Run()
|
|
|
|
// Go though all selectable species to see if they have their page setup correctly.
|
|
for(var/species_id in get_selectable_species())
|
|
|
|
var/species_type = GLOB.species_list[species_id]
|
|
var/datum/species/species = GLOB.species_prototypes[species_type]
|
|
|
|
// Check the species decription.
|
|
// If it's not overridden, a stack trace will be thrown (and fail the test).
|
|
// If it's null, it was improperly overriden. Fail the test.
|
|
var/species_desc = species.get_species_description()
|
|
if(isnull(species_desc))
|
|
TEST_FAIL("Species [species] ([species_type]) is selectable, but did not properly implement get_species_description().")
|
|
|
|
// Check the species lore.
|
|
// If it's not overridden, a stack trace will be thrown (and fail the test).
|
|
// If it's null, or returned a list, it was improperly overriden. Fail the test.
|
|
var/species_lore = species.get_species_lore()
|
|
if(isnull(species_lore))
|
|
TEST_FAIL("Species [species] ([species_type]) is selectable, but did not properly implement get_species_lore().")
|
|
else if(!islist(species_lore))
|
|
TEST_FAIL("Species [species] ([species_type]) is selectable, but did not properly implement get_species_lore() (Did not return a list).")
|