mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-23 21:18:37 +01:00
Adds some actually useful items to the loadout (#23276)
* Update loadout_datum_pocket.dm * Update loadout_datum_pocket.dm * Apply suggestions frpm Discord * oops the uh separation thingy * Update loadout_datum_shoes.dm * Update loadout_datum_pocket.dm * Finally, pizza * Apply suggestions from code review Co-authored-by: GoldenAlpharex <58045821+GoldenAlpharex@users.noreply.github.com> * loadout blacklists and stuff * finally cool stuff * Update modular_skyrat/modules/loadouts/loadout_items/loadout_datum_pocket.dm --------- Co-authored-by: GoldenAlpharex <58045821+GoldenAlpharex@users.noreply.github.com> Co-authored-by: lessthanthree <83487515+lessthnthree@users.noreply.github.com>
This commit is contained in:
co-authored by
GoldenAlpharex
lessthanthree
parent
4bfbfe9091
commit
b5716e005f
@@ -22,6 +22,11 @@
|
||||
max_purchase = 6
|
||||
cost = 1
|
||||
|
||||
/datum/armament_entry/hecu/misc/pizza
|
||||
item_type = /obj/item/pizzabox/random
|
||||
max_purchase = 3
|
||||
cost = 2
|
||||
|
||||
/datum/armament_entry/hecu/misc/guitar
|
||||
item_type = /obj/item/instrument/guitar
|
||||
max_purchase = 1
|
||||
|
||||
@@ -1,3 +1,27 @@
|
||||
/// Handpicked list of various pizzas and "pizzas" to make sure it's both 'safe' (human-edible) and doesn't spawn the base type like the bomb pizza can.
|
||||
#define EDIBLE_PIZZA_LIST list( \
|
||||
/obj/item/food/pizza/margherita, \
|
||||
/obj/item/food/pizza/meat, \
|
||||
/obj/item/food/pizza/mushroom, \
|
||||
/obj/item/food/pizza/vegetable, \
|
||||
/obj/item/food/pizza/donkpocket, \
|
||||
/obj/item/food/pizza/dank, \
|
||||
/obj/item/food/pizza/sassysage, \
|
||||
/obj/item/food/pizza/pineapple, \
|
||||
/obj/item/food/pizza/mothic_margherita, \
|
||||
/obj/item/food/pizza/mothic_firecracker, \
|
||||
/obj/item/food/pizza/mothic_five_cheese, \
|
||||
/obj/item/food/pizza/mothic_white_pie, \
|
||||
/obj/item/food/pizza/mothic_pesto, \
|
||||
/obj/item/food/pizza/mothic_garlic, \
|
||||
/obj/item/food/pizza/flatbread/rustic, \
|
||||
/obj/item/food/pizza/flatbread/italic, \
|
||||
/obj/item/food/pizza/flatbread/zmorgast, \
|
||||
/obj/item/food/pizza/flatbread/fish, \
|
||||
/obj/item/food/pizza/flatbread/mushroom, \
|
||||
/obj/item/food/pizza/flatbread/nutty, \
|
||||
)
|
||||
|
||||
/obj/item/food/mre_course
|
||||
name = "undefined MRE course"
|
||||
desc = "Something you shouldn't see. But it's edible."
|
||||
@@ -97,3 +121,13 @@
|
||||
new dessert(src)
|
||||
new /obj/item/storage/box/gum(src)
|
||||
new /obj/item/food/spacers_sidekick(src)
|
||||
|
||||
/obj/item/pizzabox/random
|
||||
boxtag = "Randy's Surprise"
|
||||
boxtag_set = TRUE
|
||||
|
||||
/obj/item/pizzabox/random/Initialize(mapload)
|
||||
. = ..()
|
||||
if(!pizza)
|
||||
var/random_pizza = pick(EDIBLE_PIZZA_LIST)
|
||||
pizza = new random_pizza(src)
|
||||
|
||||
@@ -50,6 +50,8 @@ GLOBAL_LIST_EMPTY(all_loadout_datums)
|
||||
var/list/ckeywhitelist
|
||||
/// If set, is a list of job names of which can get the loadout item
|
||||
var/list/restricted_roles
|
||||
/// If set, is a list of job names of which can't get the loadout item
|
||||
var/list/blacklisted_roles
|
||||
/// If set, is a list of species which can get the loadout item
|
||||
var/list/restricted_species
|
||||
/// Whether the item is restricted to supporters
|
||||
|
||||
@@ -51,6 +51,11 @@ GLOBAL_LIST_INIT(loadout_inhand_items, generate_loadout_items(/datum/loadout_ite
|
||||
name = "Skateboard"
|
||||
item_path = /obj/item/melee/skateboard
|
||||
|
||||
/datum/loadout_item/inhand/toolbox
|
||||
name = "Full Toolbox"
|
||||
item_path = /obj/item/storage/toolbox/mechanical
|
||||
blacklisted_roles = list(JOB_PRISONER)
|
||||
|
||||
/datum/loadout_item/inhand/bouquet_mixed
|
||||
name = "Mixed Bouquet"
|
||||
item_path = /obj/item/bouquet
|
||||
|
||||
@@ -172,7 +172,74 @@ GLOBAL_LIST_INIT(loadout_pocket_items, generate_loadout_items(/datum/loadout_ite
|
||||
/datum/loadout_item/pocket_items/cross
|
||||
name = "Ornate Cross"
|
||||
item_path = /obj/item/crucifix
|
||||
restricted_roles = list(JOB_CHAPLAIN)
|
||||
|
||||
/*
|
||||
* UTILITY
|
||||
*/
|
||||
|
||||
/datum/loadout_item/pocket_items/moth_mre
|
||||
name = "Mothic Rations Pack"
|
||||
item_path = /obj/item/storage/box/mothic_rations
|
||||
|
||||
/datum/loadout_item/pocket_items/cloth_ten
|
||||
name = "Ten Cloth Sheets"
|
||||
item_path = /obj/item/stack/sheet/cloth/ten
|
||||
|
||||
/datum/loadout_item/pocket_items/random_pizza
|
||||
name = "Random Pizza Box"
|
||||
item_path = /obj/item/pizzabox/random
|
||||
|
||||
/datum/loadout_item/pocket_items/medkit
|
||||
name = "First-Aid Kit"
|
||||
item_path = /obj/item/storage/medkit/regular
|
||||
|
||||
/datum/loadout_item/pocket_items/ingredients
|
||||
name = "Wildcard Ingredient Box"
|
||||
item_path = /obj/item/storage/box/ingredients/wildcard
|
||||
|
||||
/datum/loadout_item/pocket_items/six_beer
|
||||
name = "Beer Six-Pack"
|
||||
item_path = /obj/item/storage/cans/sixbeer
|
||||
|
||||
/datum/loadout_item/pocket_items/six_soda
|
||||
name = "Soda Six-Pack"
|
||||
item_path = /obj/item/storage/cans/sixsoda
|
||||
|
||||
/datum/loadout_item/pocket_items/power_cell
|
||||
name = "Standard Power Cell"
|
||||
item_path = /obj/item/stock_parts/cell
|
||||
|
||||
/datum/loadout_item/pocket_items/soap
|
||||
name = "Bar of Soap"
|
||||
item_path = /obj/item/soap
|
||||
|
||||
/datum/loadout_item/pocket_items/mini_extinguisher
|
||||
name = "Mini Fire Extinguisher"
|
||||
item_path = /obj/item/extinguisher/mini
|
||||
|
||||
/datum/loadout_item/pocket_items/binoculars
|
||||
name = "Pair of Binoculars"
|
||||
item_path = /obj/item/binoculars
|
||||
|
||||
/datum/loadout_item/pocket_items/drugs_happy
|
||||
name = "Happy Pills"
|
||||
item_path = /obj/item/storage/pill_bottle/happy
|
||||
|
||||
/datum/loadout_item/pocket_items/drugs_lsd
|
||||
name = "Mindbreaker Pills"
|
||||
item_path = /obj/item/storage/pill_bottle/lsd
|
||||
|
||||
/datum/loadout_item/pocket_items/drugs_weed
|
||||
name = "Cannabis Seeds"
|
||||
item_path = /obj/item/seeds/cannabis
|
||||
|
||||
/datum/loadout_item/pocket_items/drugs_reishi
|
||||
name = "Reishi Seeds"
|
||||
item_path = /obj/item/seeds/reishi
|
||||
|
||||
/datum/loadout_item/pocket_items/drugs_liberty
|
||||
name = "Liberty Cap Seeds"
|
||||
item_path = /obj/item/seeds/liberty
|
||||
|
||||
/*
|
||||
* FRAGRANCES
|
||||
|
||||
@@ -211,6 +211,10 @@ GLOBAL_LIST_INIT(loadout_shoes, generate_loadout_items(/datum/loadout_item/shoes
|
||||
name = "Sport Shoes"
|
||||
item_path = /obj/item/clothing/shoes/sports
|
||||
|
||||
/datum/loadout_item/shoes/rollerskates
|
||||
name = "Roller Skates"
|
||||
item_path = /obj/item/clothing/shoes/wheelys/rollerskates
|
||||
|
||||
/*
|
||||
* SEASONAL
|
||||
*/
|
||||
|
||||
@@ -392,6 +392,10 @@ GLOBAL_LIST_INIT(loadout_toys, generate_loadout_items(/datum/loadout_item/toys))
|
||||
name = "Box of Crayons"
|
||||
item_path = /obj/item/storage/crayons
|
||||
|
||||
/datum/loadout_item/toys/spray_can
|
||||
name = "Spray Can"
|
||||
item_path = /obj/item/toy/crayon/spraycan
|
||||
|
||||
/datum/loadout_item/toys/eightball
|
||||
name = "Magic Eightball"
|
||||
item_path = /obj/item/toy/eightball
|
||||
|
||||
@@ -96,6 +96,7 @@
|
||||
|
||||
if("display_restrictions")
|
||||
display_job_restrictions(interacted_item)
|
||||
display_job_blacklists(interacted_item)
|
||||
display_species_restrictions(interacted_item)
|
||||
|
||||
// Clears the loadout list entirely.
|
||||
@@ -234,22 +235,33 @@
|
||||
if(INFO_DESCRIBED in owner.prefs.loadout_list[item.item_path])
|
||||
owner.prefs.loadout_list[item.item_path] -= INFO_DESCRIBED
|
||||
|
||||
/// If only certain jobs are allowed to equip this loadout item, display which
|
||||
/datum/loadout_manager/proc/display_job_restrictions(datum/loadout_item/item)
|
||||
if(!length(item.restricted_roles))
|
||||
return
|
||||
var/composed_message = span_boldnotice("The [initial(item.item_path.name)] is restricted to the following roles: <br>")
|
||||
var/composed_message = span_boldnotice("The [initial(item.item_path.name)] is whitelisted to the following roles: <br>")
|
||||
for(var/job_type in item.restricted_roles)
|
||||
composed_message += span_green("[job_type] <br>")
|
||||
|
||||
to_chat(owner, examine_block(composed_message))
|
||||
|
||||
/// If certain jobs aren't allowed to equip this loadout item, display which
|
||||
/datum/loadout_manager/proc/display_job_blacklists(datum/loadout_item/item)
|
||||
if(!length(item.blacklisted_roles))
|
||||
return
|
||||
var/composed_message = span_boldnotice("The [initial(item.item_path.name)] is blacklisted from the following roles: <br>")
|
||||
for(var/job_type in item.blacklisted_roles)
|
||||
composed_message += span_red("[job_type] <br>")
|
||||
|
||||
to_chat(owner, examine_block(composed_message))
|
||||
|
||||
/// If only a certain species is allowed to equip this loadout item, display which
|
||||
/datum/loadout_manager/proc/display_species_restrictions(datum/loadout_item/item)
|
||||
if(!length(item.restricted_species))
|
||||
return
|
||||
var/composed_message = span_boldnotice("\The [initial(item.item_path.name)] is restricted to the following species: <br>")
|
||||
for(var/species_type in item.restricted_species)
|
||||
composed_message += span_green("[species_type] <br>")
|
||||
composed_message += span_grey("[species_type] <br>")
|
||||
|
||||
to_chat(owner, examine_block(composed_message))
|
||||
|
||||
@@ -351,6 +363,7 @@
|
||||
formatted_item["is_greyscale"] = !!(initial(loadout_atom.greyscale_config) && initial(loadout_atom.greyscale_colors) && (initial(loadout_atom.flags_1) & IS_PLAYER_COLORABLE_1))
|
||||
formatted_item["is_renamable"] = item.can_be_named
|
||||
formatted_item["is_job_restricted"] = !isnull(item.restricted_roles)
|
||||
formatted_item["is_job_blacklisted"] = !isnull(item.blacklisted_roles)
|
||||
formatted_item["is_species_restricted"] = !isnull(item.restricted_species)
|
||||
formatted_item["is_donator_only"] = !isnull(item.donator_only)
|
||||
formatted_item["is_ckey_whitelisted"] = !isnull(item.ckeywhitelist)
|
||||
|
||||
@@ -48,6 +48,11 @@
|
||||
to_chat(src, span_warning("You were unable to get a loadout item([initial(item.item_path.name)]) due to job restrictions!"))
|
||||
continue
|
||||
|
||||
if(item.blacklisted_roles && equipping_job && (equipping_job.title in item.blacklisted_roles))
|
||||
if(client)
|
||||
to_chat(src, span_warning("You were unable to get a loadout item([initial(item.item_path.name)]) due to job blacklists!"))
|
||||
continue
|
||||
|
||||
if(item.restricted_species && !(dna.species.id in item.restricted_species))
|
||||
if(client)
|
||||
to_chat(src, span_warning("You were unable to get a loadout item ([initial(item.item_path.name)]) due to species restrictions!"))
|
||||
@@ -65,6 +70,11 @@
|
||||
to_chat(src, span_warning("You were unable to get a loadout item([initial(item.item_path.name)]) due to job restrictions!"))
|
||||
continue
|
||||
|
||||
if(item.blacklisted_roles && equipping_job && (equipping_job.title in item.blacklisted_roles))
|
||||
if(client)
|
||||
to_chat(src, span_warning("You were unable to get a loadout item([initial(item.item_path.name)]) due to job blacklists!"))
|
||||
continue
|
||||
|
||||
if(item.restricted_species && !(dna.species.id in item.restricted_species))
|
||||
if(client)
|
||||
to_chat(src, span_warning("You were unable to get a loadout item ([initial(item.item_path.name)]) due to species restrictions!"))
|
||||
|
||||
@@ -5,10 +5,10 @@
|
||||
icon_state = "cross_ornate"
|
||||
lefthand_file = 'modular_skyrat/modules/modular_items/icons/cross_left.dmi'
|
||||
righthand_file = 'modular_skyrat/modules/modular_items/icons/cross_right.dmi'
|
||||
force = 10 //Gem-encrusted and reinforced with GOD
|
||||
force = 5 //Gem-encrusted and reinforced with GOD
|
||||
throw_speed = 3
|
||||
throw_range = 4
|
||||
throwforce = 15
|
||||
throwforce = 10
|
||||
w_class = WEIGHT_CLASS_TINY
|
||||
|
||||
/datum/crafting_recipe/cross
|
||||
|
||||
@@ -101,6 +101,18 @@ export const LoadoutManager = (props, context) => {
|
||||
</Stack.Item>
|
||||
)}
|
||||
{!!item.is_job_restricted && (
|
||||
<Stack.Item>
|
||||
<Button
|
||||
icon="briefcase"
|
||||
onClick={() =>
|
||||
act('display_restrictions', {
|
||||
path: item.path,
|
||||
})
|
||||
}
|
||||
/>
|
||||
</Stack.Item>
|
||||
)}
|
||||
{!!item.is_job_blacklisted && (
|
||||
<Stack.Item>
|
||||
<Button
|
||||
icon="lock"
|
||||
@@ -112,6 +124,18 @@ export const LoadoutManager = (props, context) => {
|
||||
/>
|
||||
</Stack.Item>
|
||||
)}
|
||||
{!!item.is_species_restricted && (
|
||||
<Stack.Item>
|
||||
<Button
|
||||
icon="spaghetti-monster-flying"
|
||||
onClick={() =>
|
||||
act('display_restrictions', {
|
||||
path: item.path,
|
||||
})
|
||||
}
|
||||
/>
|
||||
</Stack.Item>
|
||||
)}
|
||||
{!!item.is_donator_only && (
|
||||
<Stack.Item>
|
||||
<Button
|
||||
|
||||
Reference in New Issue
Block a user