mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-31 00:58:26 +01:00
Merges species/var/list/default_features with species/var/list/mutant_bodyparts. (#54525)
default_features and mutant_bodyparts have been used ambivelently since a long time, so I'm merging the two together and replacing relevant 'in' list access operations with '[ ]' for performance while I'm at it.
This commit is contained in:
@@ -375,7 +375,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
//Mutant stuff
|
||||
var/mutant_category = 0
|
||||
|
||||
if("tail_lizard" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["tail_lizard"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -388,7 +388,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "</td>"
|
||||
mutant_category = 0
|
||||
|
||||
if("snout" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["snout"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -401,7 +401,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "</td>"
|
||||
mutant_category = 0
|
||||
|
||||
if("horns" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["horns"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -414,7 +414,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "</td>"
|
||||
mutant_category = 0
|
||||
|
||||
if("frills" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["frills"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -427,7 +427,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "</td>"
|
||||
mutant_category = 0
|
||||
|
||||
if("spines" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["spines"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -440,7 +440,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "</td>"
|
||||
mutant_category = 0
|
||||
|
||||
if("body_markings" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["body_markings"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -453,7 +453,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "</td>"
|
||||
mutant_category = 0
|
||||
|
||||
if("legs" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["legs"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -466,7 +466,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "</td>"
|
||||
mutant_category = 0
|
||||
|
||||
if("moth_wings" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["moth_wings"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -479,7 +479,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "</td>"
|
||||
mutant_category = 0
|
||||
|
||||
if("moth_antennae" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["moth_antennae"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -492,7 +492,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "</td>"
|
||||
mutant_category = 0
|
||||
|
||||
if("moth_markings" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["moth_markings"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -505,7 +505,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "</td>"
|
||||
mutant_category = 0
|
||||
|
||||
if("tail_human" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["tail_human"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -518,7 +518,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "</td>"
|
||||
mutant_category = 0
|
||||
|
||||
if("ears" in pref_species.default_features)
|
||||
if(pref_species.mutant_bodyparts["ears"])
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -539,7 +539,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
|
||||
if(CONFIG_GET(flag/join_with_mutant_humans))
|
||||
|
||||
if("wings" in pref_species.default_features && GLOB.r_wings_list.len >1)
|
||||
if(pref_species.mutant_bodyparts["wings"] && GLOB.r_wings_list.len >1)
|
||||
if(!mutant_category)
|
||||
dat += APPEARANCE_CATEGORY_COLUMN
|
||||
|
||||
@@ -1930,10 +1930,10 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
character.set_species(chosen_species, icon_update = FALSE, pref_load = TRUE)
|
||||
character.dna.real_name = character.real_name
|
||||
|
||||
if("tail_lizard" in pref_species.default_features)
|
||||
character.dna.species.mutant_bodyparts |= "tail_lizard"
|
||||
if("spines" in pref_species.default_features)
|
||||
character.dna.species.mutant_bodyparts |= "spines"
|
||||
if(pref_species.mutant_bodyparts["tail_lizard"])
|
||||
character.dna.species.mutant_bodyparts["tail_lizard"] = pref_species.mutant_bodyparts["tail_lizard"]
|
||||
if(pref_species.mutant_bodyparts["spines"])
|
||||
character.dna.species.mutant_bodyparts["spines"] = pref_species.mutant_bodyparts["spines"]
|
||||
|
||||
if(icon_updates)
|
||||
character.update_body()
|
||||
|
||||
Reference in New Issue
Block a user