diff --git a/baystation12.dme b/baystation12.dme index df06cf606bc..afcec78b11e 100644 --- a/baystation12.dme +++ b/baystation12.dme @@ -746,6 +746,7 @@ #include "code\modules\client\client defines.dm" #include "code\modules\client\client procs.dm" #include "code\modules\client\preferences.dm" +#include "code\modules\client\preferences_gear.dm" #include "code\modules\client\preferences_savefile.dm" #include "code\modules\client\preferences_spawnpoints.dm" #include "code\modules\client\preferences_toggles.dm" diff --git a/code/controllers/master_controller.dm b/code/controllers/master_controller.dm index cb52b2252fa..2ae5d1db1e8 100644 --- a/code/controllers/master_controller.dm +++ b/code/controllers/master_controller.dm @@ -79,13 +79,6 @@ datum/controller/game_controller/proc/setup() for(var/i=0, iGenerating resource distribution map." + var/datum/ore_distribution/O = new() + O.populate_distribution_map() + + //Set up spawn points. + populate_spawn_points() + + //Set up gear list. + populate_gear_list() + world << "\red \b Initializations complete." sleep(-1) diff --git a/code/modules/client/preferences.dm b/code/modules/client/preferences.dm index c05a0d98390..85d56d31eef 100644 --- a/code/modules/client/preferences.dm +++ b/code/modules/client/preferences.dm @@ -73,8 +73,9 @@ datum/preferences var/r_eyes = 0 //Eye color var/g_eyes = 0 //Eye color var/b_eyes = 0 //Eye color - var/species = "Human" + var/species = "Human" //Species datum to use. var/language = "None" //Secondary language + var/list/gear //Custom/fluff item loadout. //Mob preview var/icon/preview_icon = null @@ -104,7 +105,6 @@ datum/preferences // maps each organ to either null(intact), "cyborg" or "amputated" // will probably not be able to do this for head and torso ;) var/list/organ_data = list() - var/list/player_alt_titles = new() // the default name of a job like "Medical Doctor" var/flavor_text = "" @@ -132,6 +132,8 @@ datum/preferences gender = pick(MALE, FEMALE) real_name = random_name(gender) + gear = list() + /datum/preferences proc/ZeroSkills(var/forced = 0) for(var/V in SKILLS) for(var/datum/skill/S in SKILLS[V]) @@ -340,6 +342,22 @@ datum/preferences else dat += "

" + dat += "Custom Loadout: " + var/total_cost = 0 + if(gear && gear.len) + dat += "
" + for(var/gear_name in gear) + if(gear_datums[gear_name]) + var/datum/gear/G = gear_datums[gear_name] + total_cost += G.cost + dat += "[gear_name] ([G.cost]) " + dat += "\[remove\]
" + if(total_cost < MAX_GEAR_COST) + dat += "\[add\]
" + dat += "Used: [total_cost] points.
" + else + dat += "none.
" + if(gender == MALE) dat += "Underwear: [underwear_m[underwear]]
" else @@ -835,6 +853,22 @@ datum/preferences ShowChoices(user) return 1 + else if (href_list["preference"] == "loadout") + + if(href_list["task"] == "input") + + var/choice = input("Select gear to add.") as null|anything in gear_datums + if(choice && gear_datums[choice]) + gear += choice + + else if(href_list["task"] == "remove") + var/to_remove = href_list["gear"] + if(!to_remove) return + for(var/gear_name in gear) + if(gear_name == to_remove) + gear -= gear_name + break + switch(href_list["task"]) if("random") switch(href_list["preference"]) diff --git a/code/modules/client/preferences_gear.dm b/code/modules/client/preferences_gear.dm new file mode 100644 index 00000000000..29065325618 --- /dev/null +++ b/code/modules/client/preferences_gear.dm @@ -0,0 +1,131 @@ +var/global/list/gear_datums = list() + +proc/populate_gear_list() + for(var/type in typesof(/datum/gear)-/datum/gear) + var/datum/gear/G = new type() + gear_datums[G.display_name] = G + +/datum/gear + var/display_name //Name/index. + var/path //Path to item. + var/cost //Number of points used. + var/slot //Slot to equip to. + var/list/allowed_roles //Roles that can spawn with this item. + +//Standard gear datums. +/datum/gear/tie_horrible + display_name = "horrible tie" + path = /obj/item/clothing/tie/horrible + cost = 2 + +/datum/gear/hairflower + display_name = "hair flower pin" + path = /obj/item/clothing/head/hairflower + cost = 1 + slot = SLOT_HEAD + +/datum/gear/bandana + display_name = "pirate bandana" + path = /obj/item/clothing/head/bandana + cost = 1 + slot = SLOT_HEAD + +/datum/gear/overalls + display_name = "overalls" + path = /obj/item/clothing/suit/apron/overalls + cost = 1 + slot = SLOT_OCLOTHING + +/datum/gear/wcoat + display_name = "waistcoat" + path = /obj/item/clothing/suit/wcoat + cost = 1 + slot = SLOT_OCLOTHING + +/datum/gear/prescription + display_name = "prescription sunglasses" + path = /obj/item/clothing/glasses/sunglasses/prescription + cost = 2 + slot = SLOT_EYES + +/datum/gear/eyepatch + display_name = "eyepatch" + path = /obj/item/clothing/glasses/eyepatch + cost = 1 + slot = SLOT_EYES + +/datum/gear/flatcap + display_name = "flat cap" + path = /obj/item/clothing/head/flatcap + cost = 1 + slot = SLOT_HEAD + +/datum/gear/labcoat + display_name = "labcoat" + path = /obj/item/clothing/suit/storage/labcoat + cost = 2 + slot = SLOT_OCLOTHING + +/datum/gear/sandal + display_name = "sandals" + path = /obj/item/clothing/shoes/sandal + cost = 1 + slot = SLOT_FEET + +/datum/gear/leather + display_name = "leather shoes" + path = /obj/item/clothing/shoes/leather + cost = 1 + slot = SLOT_FEET + +/datum/gear/dress_shoes + display_name = "dress shoes" + path = /obj/item/clothing/shoes/centcom + cost = 1 + slot = SLOT_FEET + +//Security +/datum/gear/security + display_name = "Security HUD" + path = /obj/item/clothing/glasses/hud/security + cost = 1 + slot = SLOT_EYES + allowed_roles = list("Security Officer","Head of Security","Warden") + +/datum/gear/sec_beret + display_name = "security beret" + path = /obj/item/clothing/head/beret/sec + cost = 1 + slot = SLOT_HEAD + allowed_roles = list("Security Officer","Head of Security","Warden") + +//Engineering +/datum/gear/eng_beret + display_name = "engineering beret" + path = /obj/item/clothing/head/beret/eng + cost = 1 + slot = SLOT_HEAD + allowed_roles = list("Station Engineering","Atmospheric Technician","Chief Engineer") + +//Species-specific gear datums. +/datum/gear/zhan_furs + display_name = "Zhan-Khazan furs" + path = /obj/item/clothing/suit/tajaran/furs + cost = 3 + +/datum/gear/zhan_scarf + display_name = "Zhan-Khazan headscarf" + path = /obj/item/clothing/head/tajaran/scarf + cost = 2 + +/datum/gear/unathi_robe + display_name = "roughspun robe" + path = /obj/item/clothing/suit/unathi/robe + cost = 3 + slot = SLOT_OCLOTHING + +/datum/gear/unathi_mantle + display_name = "hide mantle" + path = /obj/item/clothing/suit/unathi/mantle + cost = 2 + slot = SLOT_OCLOTHING \ No newline at end of file diff --git a/code/modules/clothing/suits/alien.dm b/code/modules/clothing/suits/alien.dm index 5b664f21b35..8b3c7de076f 100644 --- a/code/modules/clothing/suits/alien.dm +++ b/code/modules/clothing/suits/alien.dm @@ -12,4 +12,22 @@ desc = "A rather grisly selection of cured hides and skin, sewn together to form a ragged mantle." icon_state = "mantle-unathi" item_state = "mantle-unathi" - body_parts_covered = UPPER_TORSO \ No newline at end of file + body_parts_covered = UPPER_TORSO + +//Taj clothing. + +/obj/item/clothing/suit/tajaran/furs + name = "heavy furs" + desc = "A traditional Zhan-Khazan garment." + icon_state = "zhan_furs" + item_state = "zhan_furs" + body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS + + sprite_sheets = list( + "Tajaran" = 'icons/mob/species/tajaran/suit.dmi', + ) + +/obj/item/clothing/head/tajaran/scarf + name = "headscarf" + desc = "A scarf of coarse fabric. Seems to have ear-holes." + icon_state = "zhan_scarf" \ No newline at end of file diff --git a/code/modules/mining/drilling/distribution.dm b/code/modules/mining/drilling/distribution.dm index 2ca9a3f685c..1b4c698ea9b 100644 --- a/code/modules/mining/drilling/distribution.dm +++ b/code/modules/mining/drilling/distribution.dm @@ -75,9 +75,6 @@ Deep minerals: //Halfassed diamond-square algorithm with some fuckery since it's a single dimension array. /datum/ore_distribution/proc/populate_distribution_map() - //Announce it! - world << "Generating resource distribution map." - //Seed beginning values. var/x = 1 var/y = 1 diff --git a/code/modules/mob/living/carbon/species.dm b/code/modules/mob/living/carbon/species.dm index c2ecf6d539d..6812a4c4259 100644 --- a/code/modules/mob/living/carbon/species.dm +++ b/code/modules/mob/living/carbon/species.dm @@ -54,6 +54,9 @@ var/race_key = 0 var/icon/icon_template + //Used for character generation fluff items. + var/list/custom_gear_options + /datum/species/New() unarmed = new unarmed_type() @@ -142,6 +145,11 @@ reagent_tag = IS_UNATHI base_color = "#066000" + custom_gear_options = list( + "Unathi robe" = /obj/item/clothing/suit/unathi/robe, + "Unathi mantle" = /obj/item/clothing/suit/unathi/mantle + ) + /datum/species/tajaran name = "Tajaran" icobase = 'icons/mob/human_races/r_tajaran.dmi' @@ -167,6 +175,11 @@ flesh_color = "#AFA59E" base_color = "#333333" + custom_gear_options = list( + /obj/item/clothing/head/tajaran/scarf, + /obj/item/clothing/suit/tajaran/furs + ) + /datum/species/skrell name = "Skrell" icobase = 'icons/mob/human_races/r_skrell.dmi' diff --git a/code/setup.dm b/code/setup.dm index a86e0665765..55c15102348 100644 --- a/code/setup.dm +++ b/code/setup.dm @@ -811,4 +811,6 @@ var/list/RESTRICTED_CAMERA_NETWORKS = list( //Those networks can only be accesse #define IS_DIONA 1 #define IS_VOX 2 #define IS_SKRELL 3 -#define IS_UNATHI 4 \ No newline at end of file +#define IS_UNATHI 4 + +#define MAX_GEAR_COST 5 //Used in chargen for loadout limit. \ No newline at end of file diff --git a/icons/mob/species/tajaran/suit.dmi b/icons/mob/species/tajaran/suit.dmi index 620da66a60c..d0eca318fd2 100644 Binary files a/icons/mob/species/tajaran/suit.dmi and b/icons/mob/species/tajaran/suit.dmi differ