Skip to content

Commit

Permalink
Merge branch 'master' into DOGSHIT-LAPTOP
Browse files Browse the repository at this point in the history
  • Loading branch information
vero5123 authored Jun 6, 2024
2 parents c661de7 + 45c048d commit 0bbc160
Show file tree
Hide file tree
Showing 54 changed files with 952 additions and 418 deletions.
3 changes: 2 additions & 1 deletion code/__HELPERS/icons.dm
Original file line number Diff line number Diff line change
Expand Up @@ -919,8 +919,9 @@ world
// From /datum/preferences/proc/copy_appearance_to
body.age = original.age
body.gender = original.gender
body.ethnicity = original.ethnicity
body.skin_color = original.skin_color
body.body_type = original.body_type
body.body_size = original.body_size

body.r_eyes = original.r_eyes
body.g_eyes = original.g_eyes
Expand Down
9 changes: 6 additions & 3 deletions code/__HELPERS/mobs.dm
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
#define isdeaf(A) (ismob(A) && ((A?:sdisabilities & DISABILITY_DEAF) || A?:ear_deaf))
#define xeno_hivenumber(A) (isxeno(A) ? A?:hivenumber : FALSE)

/proc/random_ethnicity()
return pick(GLOB.ethnicities_list)
/proc/random_skin_color()
return pick(GLOB.skin_color_list)

/proc/random_body_type()
return pick(GLOB.body_types_list)
return pick(GLOB.body_type_list)

/proc/random_body_size()
return pick(GLOB.body_size_list)

/proc/random_hair_style(gender, species = "Human")
var/h_style = "Crewcut"
Expand Down
16 changes: 11 additions & 5 deletions code/__HELPERS/sanitize_values.dm
Original file line number Diff line number Diff line change
Expand Up @@ -45,18 +45,24 @@
else return default
return default

/proc/sanitize_ethnicity(ethnicity, default = "Western")
if (ethnicity in GLOB.ethnicities_list)
return ethnicity
/proc/sanitize_skin_color(skin_color, default = "Pale 2")
if(skin_color in GLOB.skin_color_list)
return skin_color

return default

/proc/sanitize_body_type(body_type, default = "Mesomorphic (Average)")
if (body_type in GLOB.body_types_list)
/proc/sanitize_body_type(body_type, default = "Lean")
if(body_type in GLOB.body_type_list)
return body_type

return default

/proc/sanitize_body_size(body_size, default = "Average")
if(body_size in GLOB.body_size_list)
return body_size

return default

/proc/sanitize_hexcolor(color, default="#000000")
if(!istext(color)) return default
var/len = length(color)
Expand Down
9 changes: 5 additions & 4 deletions code/_globalvars/global_lists.dm
Original file line number Diff line number Diff line change
Expand Up @@ -198,10 +198,11 @@ GLOBAL_LIST_INIT(custom_event_info_list, setup_custom_event_info())
GLOBAL_LIST_INIT(poster_designs, subtypesof(/datum/poster))

//Preferences stuff
// Ethnicities
GLOBAL_REFERENCE_LIST_INDEXED(ethnicities_list, /datum/ethnicity, name) // Stores /datum/ethnicity indexed by name
// Body Types
GLOBAL_REFERENCE_LIST_INDEXED(body_types_list, /datum/body_type, name) // Stores /datum/body_type indexed by name
// Skin colors
GLOBAL_REFERENCE_LIST_INDEXED(skin_color_list, /datum/skin_color, name) // Stores /datum/skin_color indexed by name
// Body
GLOBAL_REFERENCE_LIST_INDEXED(body_type_list, /datum/body_type, name) // Stores /datum/body_type indexed by name
GLOBAL_REFERENCE_LIST_INDEXED(body_size_list, /datum/body_size, name) // Stores /datum/body_size indexed by name
//Hairstyles
GLOBAL_REFERENCE_LIST_INDEXED(hair_styles_list, /datum/sprite_accessory/hair, name) //stores /datum/sprite_accessory/hair indexed by name
GLOBAL_REFERENCE_LIST_INDEXED(facial_hair_styles_list, /datum/sprite_accessory/facial_hair, name) //stores /datum/sprite_accessory/facial_hair indexed by name
Expand Down
35 changes: 21 additions & 14 deletions code/datums/datacore.dm
Original file line number Diff line number Diff line change
Expand Up @@ -256,31 +256,38 @@ GLOBAL_DATUM_INIT(data_core, /datum/datacore, new)
var/icon/icobase = H.species.icobase
var/icon/temp

var/datum/ethnicity/ET = GLOB.ethnicities_list[H.ethnicity]
var/datum/body_type/B = GLOB.body_types_list[H.body_type]
var/datum/skin_color/set_skin_color = GLOB.skin_color_list[H.skin_color]
var/datum/body_type/set_body_type = GLOB.body_type_list[H.body_type]
var/datum/body_size/set_body_size = GLOB.body_size_list[H.body_size]

var/e_icon
var/b_icon
var/skin_color_icon
var/body_type_icon
var/body_size_icon

if (!ET)
e_icon = "western"
if(!set_skin_color)
skin_color_icon = "pale2"
else
e_icon = ET.icon_name
skin_color_icon = set_skin_color.icon_name

if (!B)
b_icon = "mesomorphic"
if(!set_body_type)
body_type_icon = "lean"
else
b_icon = B.icon_name
body_type_icon = set_body_type.icon_name

preview_icon = new /icon(icobase, get_limb_icon_name(H.species, b_icon, H.gender, "torso", e_icon))
temp = new /icon(icobase, get_limb_icon_name(H.species, b_icon, H.gender, "groin", e_icon))
if(!set_body_size)
body_size_icon = "avg"
else
body_size_icon = set_body_size.icon_name

preview_icon = new /icon(icobase, get_limb_icon_name(H.species, body_size_icon, body_type_icon, H.gender, "torso", skin_color_icon))
temp = new /icon(icobase, get_limb_icon_name(H.species, body_size_icon, body_type_icon, H.gender, "groin", skin_color_icon))
preview_icon.Blend(temp, ICON_OVERLAY)
temp = new /icon(icobase, get_limb_icon_name(H.species, b_icon, H.gender, "head", e_icon))
temp = new /icon(icobase, get_limb_icon_name(H.species, body_size_icon, body_type_icon, H.gender, "head", skin_color_icon))
preview_icon.Blend(temp, ICON_OVERLAY)

for(var/obj/limb/E in H.limbs)
if(E.status & LIMB_DESTROYED) continue
temp = new /icon(icobase, get_limb_icon_name(H.species, b_icon, H.gender, E.name, e_icon))
temp = new /icon(icobase, get_limb_icon_name(H.species, body_size_icon, body_type_icon, H.gender, E.name, skin_color_icon))
if(E.status & LIMB_ROBOT)
temp.MapColors(rgb(77,77,77), rgb(150,150,150), rgb(28,28,28), rgb(0,0,0))
preview_icon.Blend(temp, ICON_OVERLAY)
Expand Down
137 changes: 137 additions & 0 deletions code/datums/supply_packs/black_market.dm
Original file line number Diff line number Diff line change
Expand Up @@ -722,6 +722,143 @@ USCM spare items, miscellaneous gear that's too niche and distant (or restricted
contains = list(/obj/item/storage/box/guncase/m1911/socom)
containertype = /obj/structure/largecrate/black_market

/* --- AMMO --- */

/datum/supply_packs/contraband/ammo
group = "Contraband Ammo"

/datum/supply_packs/contraband/ammo/r4t
name = "45-70 bullet box crate (x300 rounds)"
dollar_cost = 135
contains = list(/obj/item/ammo_box/magazine/lever_action)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/r4t/training
name = "45-70 bullet box crate (x300 training rounds)"
dollar_cost = 35
contains = list(/obj/item/ammo_box/magazine/lever_action/training)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/m16
name = "Magazine box (M16, 12x regular mags)"
dollar_cost = 100
contains = list(/obj/item/ammo_box/magazine/M16)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/ar10
name = "Magazine box (AR10, 12x regular mags)"
dollar_cost = 115
contains = list(/obj/item/ammo_box/magazine/ar10)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/deagle
name = "Magazine box (Desert Eagle, 16x regular mags)"
dollar_cost = 180
contains = list(/obj/item/ammo_box/magazine/deagle)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/deagle/hiap
name = "Magazine box (Desert Eagle, 16x HIAP mags)"
dollar_cost = 260
contains = list(/obj/item/ammo_box/magazine/deagle/super/highimpact/ap/empty)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/type73
name = "Magazine box (Type 73, 16x regular mags)"
dollar_cost = 60
contains = list(/obj/item/ammo_box/magazine/type73)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/nsg
name = "Magazine box (NSG-23, 16x regular mags)"
dollar_cost = 140
contains = list(/obj/item/ammo_box/magazine/nsg23)
containertype = /obj/structure/largecrate/black_market
/datum/supply_packs/contraband/ammo/mar30
name = "Magazines box (MAR30, 10x regular mags)"
dollar_cost = 60
contains = list(/obj/item/ammo_box/magazine/mar30)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/fp9000
name = "Magazines box (FN FP9000, 10x mags)"
dollar_cost = 35
contains = list(/obj/item/ammo_box/magazine/fp9000)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/mp27
name = "Magazines box (MP-27, 12x mags)"
dollar_cost = 45
contains = list(/obj/item/ammo_box/magazine/mp27)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/uzi
name = "Magazines box (UZI, 12x mags)"
dollar_cost = 25
contains = list(/obj/item/ammo_box/magazine/uzi)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/mac15
name = "Magazines box (MAC-15, 12x mags)"
dollar_cost = 15
contains = list(/obj/item/ammo_box/magazine/mac15)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/pps43
name = "Magazines box (Type-19, 10x regular mags)"
dollar_cost = 40
contains = list(/obj/item/ammo_box/magazine/type19)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/b92fs
name = "Magazines box (Beretta 92FS, 16x mags)"
dollar_cost = 30
contains = list(/obj/item/ammo_box/magazine/b92fs)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/kt42
name = "Magazines box (KT-42, 16x mags)"
dollar_cost = 45
contains = list(/obj/item/ammo_box/magazine/kt42)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/bizon
name = "Magazines box (Type 64, 10x mags)"
dollar_cost = 40
contains = list(/obj/item/ammo_box/magazine/type64)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/m1911
name = "Magazines box (M1911, 16x mags)"
dollar_cost = 40
contains = list(/obj/item/ammo_box/magazine/m1911)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/mk45
name = "Magazines box (MK-45 Automagnum, 16x mags)"
dollar_cost = 80
contains = list(/obj/item/ammo_box/magazine/mk45)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/cmb
name = "Speed loaders box (CMB Spearhead, 16x HP loaders)"
dollar_cost = 70
contains = list(/obj/item/ammo_box/magazine/spearhead)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/smw
name = "Speed loaders box (Smith and Wesson revolver, 12x loaders)"
dollar_cost = 30
contains = list(/obj/item/ammo_box/magazine/snw)
containertype = /obj/structure/largecrate/black_market

/datum/supply_packs/contraband/ammo/zhnk
name = "Speed loaders box (ZHNK-72, 12x loaders)"
dollar_cost = 30
contains = list(/obj/item/ammo_box/magazine/zhnk)
containertype = /obj/structure/largecrate/black_market


/* --- DEEP STORAGE --- */

/*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,7 @@
list("M10 Helmet Netting", floor(scale * 10), /obj/item/prop/helmetgarb/netting, VENDOR_ITEM_REGULAR),
list("M10 Helmet Rain Cover", floor(scale * 10), /obj/item/prop/helmetgarb/raincover, VENDOR_ITEM_REGULAR),
list("Firearm Lubricant", floor(scale * 15), /obj/item/prop/helmetgarb/gunoil, VENDOR_ITEM_REGULAR),
list("Attachable Dogtags", floor(scale * 15), /obj/item/clothing/accessory/dogtags, VENDOR_ITEM_REGULAR),
list("USCM Flair", floor(scale * 15), /obj/item/prop/helmetgarb/flair_uscm, VENDOR_ITEM_REGULAR),
list("Falling Falcons Shoulder Patch", floor(scale * 15), /obj/item/clothing/accessory/patch/falcon, VENDOR_ITEM_REGULAR),
list("USCM Shoulder Patch", floor(scale * 15), /obj/item/clothing/accessory/patch, VENDOR_ITEM_REGULAR),
Expand Down
28 changes: 28 additions & 0 deletions code/game/objects/items/stacks/sheets/sheet_types.dm
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,34 @@ GLOBAL_LIST_INIT_TYPED(cardboard_recipes, /datum/stack_recipe, list ( \
null, \
new/datum/stack_recipe("empty magazine box (MP5)", /obj/item/ammo_box/magazine/mp5/empty), \
null, \
new/datum/stack_recipe("empty magazine box (MAR30)", /obj/item/ammo_box/magazine/mar30/empty), \
new/datum/stack_recipe("empty magazine box (MAR30 EX)", /obj/item/ammo_box/magazine/mar30/ext/empty), \
new/datum/stack_recipe("empty magazine box (MAR50)", /obj/item/ammo_box/magazine/mar50/empty), \
null, \
new/datum/stack_recipe("empty magazine box (UZI)", /obj/item/ammo_box/magazine/uzi/empty), \
null, \
new/datum/stack_recipe("empty magazine box (MAC-15)", /obj/item/ammo_box/magazine/mac15/empty), \
null, \
new/datum/stack_recipe("empty magazine box (MP27)", /obj/item/ammo_box/magazine/mp27/empty), \
null, \
new/datum/stack_recipe("empty magazine box (M1911)", /obj/item/ammo_box/magazine/m1911/empty), \
null, \
new/datum/stack_recipe("empty magazine box (MK-45)", /obj/item/ammo_box/magazine/mk45/empty), \
null, \
new/datum/stack_recipe("empty magazine box (KT-42)", /obj/item/ammo_box/magazine/kt42/empty), \
null, \
new/datum/stack_recipe("empty magazine box (Beretta 92FS)", /obj/item/ammo_box/magazine/b92fs/empty), \
null, \
new/datum/stack_recipe("empty magazine box (FN FP9000)", /obj/item/ammo_box/magazine/fp9000/empty), \
null, \
new/datum/stack_recipe("empty magazine box (Type19)", /obj/item/ammo_box/magazine/type19/empty), \
null, \
new/datum/stack_recipe("empty magazine box (ZhNK-72)", /obj/item/ammo_box/magazine/zhnk/empty), \
null, \
new/datum/stack_recipe("empty magazine box (Type64 Bizon)", /obj/item/ammo_box/magazine/type64/empty), \
null, \
new/datum/stack_recipe("empty magazine box (S&W .38)", /obj/item/ammo_box/magazine/snw/empty), \
null, \
new/datum/stack_recipe("empty magazine box (NSG 23)", /obj/item/ammo_box/magazine/nsg23/empty), \
new/datum/stack_recipe("empty magazine box (NSG 23 AP)", /obj/item/ammo_box/magazine/nsg23/ap/empty), \
new/datum/stack_recipe("empty magazine box (NSG 23 EX)", /obj/item/ammo_box/magazine/nsg23/ex/empty), \
Expand Down
1 change: 1 addition & 0 deletions code/game/supplyshuttle.dm
Original file line number Diff line number Diff line change
Expand Up @@ -437,6 +437,7 @@ GLOBAL_DATUM_INIT(supply_controller, /datum/controller/supply, new())
"Seized Items",
"Shipside Contraband",
"Surplus Equipment",
"Contraband Ammo",
"Deep Storage",
"Miscellaneous"
)
Expand Down
Loading

0 comments on commit 0bbc160

Please sign in to comment.