mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 18:22:39 +00:00
[MIRROR] Species Stats Visible During Creation (#11595)
Co-authored-by: Will <7099514+Willburd@users.noreply.github.com> Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
894f20a88a
commit
837fc4c83d
@@ -95,6 +95,55 @@
|
||||
data["autohiss"] = pref.autohiss
|
||||
data["emote_sound_mode"] = pref.read_preference(/datum/preference/choiced/living/emote_sound_mode)
|
||||
|
||||
// Get species stats so they can be displayed
|
||||
var/datum/species/species = null
|
||||
var/mob/living/carbon/human/dummy/mannequin/mannequin = get_mannequin(pref.client_ckey)
|
||||
if(mannequin)
|
||||
species = mannequin.species
|
||||
else if(pref.species)
|
||||
species = GLOB.all_species[pref.species]
|
||||
else
|
||||
species = GLOB.all_species[SPECIES_HUMAN]
|
||||
|
||||
var/list/species_stats = list(
|
||||
"total_health" = species.total_health,
|
||||
"slowdown" = species.slowdown,
|
||||
"brute_mod" = species.brute_mod,
|
||||
"burn_mod" = species.burn_mod,
|
||||
"oxy_mod" = species.oxy_mod,
|
||||
"toxins_mod" = species.toxins_mod,
|
||||
"radiation_mod" = species.radiation_mod,
|
||||
"flash_mod" = species.flash_mod,
|
||||
"pain_mod" = species.pain_mod,
|
||||
"stun_mod" = species.stun_mod,
|
||||
"weaken_mod" = species.weaken_mod,
|
||||
"lightweight" = species.lightweight,
|
||||
"dispersed_eyes" = species.dispersed_eyes,
|
||||
"trashcan" = species.trashcan,
|
||||
"eat_minerals" = species.eat_minerals,
|
||||
"darksight" = species.darksight,
|
||||
"chem_strength_tox" = species.chem_strength_tox,
|
||||
"cold_level_1" = species.cold_level_1,
|
||||
"heat_level_1" = species.heat_level_1,
|
||||
"chem_strength_heal" = species.chem_strength_heal,
|
||||
"siemens_coefficient" = species.siemens_coefficient,
|
||||
"has_vibration_sense" = species.has_vibration_sense,
|
||||
"item_slowdown_mod" = species.item_slowdown_mod,
|
||||
"body_temperature" = species.body_temperature,
|
||||
"hazard_low_pressure" = species.hazard_low_pressure,
|
||||
"breath_type" = GLOB.gas_data.name[species.breath_type],
|
||||
"hazard_high_pressure" = species.hazard_high_pressure,
|
||||
"soft_landing" = species.soft_landing,
|
||||
"bloodsucker" = species.bloodsucker,
|
||||
"can_space_freemove" = species.can_space_freemove,
|
||||
"can_zero_g_move" = species.can_zero_g_move,
|
||||
"water_breather" = species.water_breather,
|
||||
"can_climb" = species.can_climb,
|
||||
"has_flight" = (/mob/living/proc/flying_toggle in species.inherent_verbs),
|
||||
)
|
||||
|
||||
data["species_stats"] = species_stats
|
||||
|
||||
return data
|
||||
|
||||
/datum/category_item/player_setup_item/general/basic/tgui_static_data(mob/user)
|
||||
@@ -102,6 +151,45 @@
|
||||
|
||||
data["allow_metadata"] = CONFIG_GET(flag/allow_metadata)
|
||||
|
||||
var/list/human_stats = list(
|
||||
"total_health" = /datum/species/human::total_health,
|
||||
"slowdown" = /datum/species/human::slowdown,
|
||||
"brute_mod" = /datum/species/human::brute_mod,
|
||||
"burn_mod" = /datum/species/human::burn_mod,
|
||||
"oxy_mod" = /datum/species/human::oxy_mod,
|
||||
"toxins_mod" = /datum/species/human::toxins_mod,
|
||||
"radiation_mod" = /datum/species/human::radiation_mod,
|
||||
"flash_mod" = /datum/species/human::flash_mod,
|
||||
"pain_mod" = /datum/species/human::pain_mod,
|
||||
"stun_mod" = /datum/species/human::stun_mod,
|
||||
"weaken_mod" = /datum/species/human::weaken_mod,
|
||||
"lightweight" = FALSE,
|
||||
"dispersed_eyes" = FALSE,
|
||||
"trashcan" = FALSE,
|
||||
"eat_minerals" = FALSE,
|
||||
"darksight" = /datum/species/human::darksight,
|
||||
"chem_strength_tox" = /datum/species/human::chem_strength_tox,
|
||||
"cold_level_1" = /datum/species/human::cold_level_1,
|
||||
"heat_level_1" = /datum/species/human::heat_level_1,
|
||||
"chem_strength_heal" = /datum/species/human::chem_strength_heal,
|
||||
"siemens_coefficient" = /datum/species/human::siemens_coefficient,
|
||||
"has_vibration_sense" = FALSE,
|
||||
"item_slowdown_mod" = /datum/species/human::item_slowdown_mod,
|
||||
"body_temperature" = /datum/species/human::body_temperature,
|
||||
"hazard_low_pressure" = /datum/species/human::hazard_low_pressure,
|
||||
"breath_type" = GLOB.gas_data.name[/datum/species/human::breath_type],
|
||||
"hazard_high_pressure" = /datum/species/human::hazard_high_pressure,
|
||||
"soft_landing" = FALSE,
|
||||
"bloodsucker" = FALSE,
|
||||
"can_space_freemove" = FALSE,
|
||||
"can_zero_g_move" = FALSE,
|
||||
"water_breather" = FALSE,
|
||||
"can_climb" = FALSE,
|
||||
"has_flight" = FALSE,
|
||||
)
|
||||
|
||||
data["basehuman_stats"] = human_stats
|
||||
|
||||
return data
|
||||
|
||||
/datum/category_item/player_setup_item/general/basic/tgui_act(action, list/params, datum/tgui/ui, datum/tgui_state/state)
|
||||
|
||||
Reference in New Issue
Block a user