Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
39 commits
Select commit Hold shift + click to select a range
51c2ea8
first commit
massaheartsu Aug 15, 2025
937f1ee
added rocks, sap, icons, and code
massaheartsu Aug 18, 2025
ae0d25f
working drop
massaheartsu Aug 18, 2025
64e26bc
Update pyrotechnics.dm
massaheartsu Aug 19, 2025
ad24242
nothingburger
massaheartsu Aug 19, 2025
1d374d6
IT WORKS FUCK YES
massaheartsu Aug 20, 2025
bb25ffc
Complete!
massaheartsu Aug 22, 2025
56ff72e
actually done
massaheartsu Aug 24, 2025
70a769d
dd
massaheartsu Aug 24, 2025
ce56ee5
reduced fent quantity
massaheartsu Aug 24, 2025
48b7e2a
oops
massaheartsu Aug 24, 2025
13d9549
Added and fixed requested changes!
massaheartsu Aug 24, 2025
de4126a
fixed inhand_icons
massaheartsu Aug 24, 2025
114af6a
fixed icon states again. also tweaked numbers in hindsight.
massaheartsu Aug 24, 2025
cdb67a7
Update code/modules/hydroponics/grown/flowers.dm
massaheartsu Aug 24, 2025
a573ea6
Update code/modules/reagents/chemistry/recipes/drugs.dm
massaheartsu Aug 24, 2025
dc893f6
Update code/game/objects/items/cigarettes.dm
massaheartsu Aug 24, 2025
7d652d1
fixed another attackby
massaheartsu Aug 24, 2025
85c0c5e
last interact_with
massaheartsu Aug 24, 2025
801f8f8
Very significant changes!
massaheartsu Aug 28, 2025
4e17cc9
Update drug_items.dm
massaheartsu Aug 28, 2025
ff983bd
linters bazinga
massaheartsu Aug 28, 2025
bb524b4
FINISHED
massaheartsu Aug 31, 2025
af932a5
Update consumables.dm
massaheartsu Aug 31, 2025
e8386a6
Update drugs.dm
massaheartsu Aug 31, 2025
af4af91
fixed interact
massaheartsu Sep 1, 2025
2df8bab
Update code/modules/reagents/chemistry/reagents/medicine_reagents.dm
massaheartsu Sep 9, 2025
ff48696
Update code/modules/reagents/chemistry/reagents/drug_reagents.dm
massaheartsu Sep 9, 2025
735361e
Update code/game/objects/items/drug_items.dm
massaheartsu Sep 9, 2025
0eef941
Update code/modules/reagents/chemistry/reagents/drug_reagents.dm
massaheartsu Sep 9, 2025
4d4015d
Fixed a few things at the behest of Tattle and Drago!
massaheartsu Sep 9, 2025
95af3fd
compatability
ZealousZeke Jun 15, 2026
953e12f
whoops
ZealousZeke Jun 15, 2026
7b07f1e
linter fix maybe
ZealousZeke Jun 15, 2026
645552c
alphabetical or sum shi
ZealousZeke Jun 15, 2026
4ab4324
Fixes crystal meth not having correct purity based colors
SyncIt21 Oct 20, 2025
f824577
swap
SyncIt21 Oct 20, 2025
7dca3be
[NO GBP] Crystal Meth reaction yields correct methamphetamine amounts
SyncIt21 Nov 9, 2025
5f3cbde
Was not my intention
SyncIt21 Nov 10, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions code/datums/components/crafting/entertainment.dm
Original file line number Diff line number Diff line change
Expand Up @@ -264,3 +264,15 @@
time = 30 SECONDS
category = CAT_ENTERTAINMENT
crafting_flags = CRAFT_CHECK_DENSITY | CRAFT_MUST_BE_LEARNED

/datum/crafting_recipe/crackpipe
name = "Glass Pipe"
result = /obj/item/cigarette/pipe/crackpipe
time = 5 SECONDS
reqs = list(
/obj/item/stack/sheet/glass = 3,
)
tool_paths = list(
/obj/item/screwdriver,
)
category = CAT_ENTERTAINMENT
10 changes: 10 additions & 0 deletions code/game/objects/effects/spawners/random/contraband.dm
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@
/obj/item/storage/pill_bottle/lsd = 10,
/obj/item/storage/pill_bottle/aranesp = 10,
/obj/item/storage/pill_bottle/stimulant = 10,
/obj/item/food/drug/saturnx = 5,
/obj/item/food/drug/meth_crystal = 5,
/obj/item/food/drug/opium = 5,
/obj/item/reagent_containers/cup/blastoff_ampoule = 5,
/obj/item/food/drug/moon_rock = 5,
/obj/item/storage/fancy/cigarettes/cigpack_syndicate = 10,
/obj/item/storage/fancy/cigarettes/cigpack_shadyjims = 10,
/obj/item/storage/box/donkpockets = 10,
Expand All @@ -40,6 +45,8 @@
/obj/item/reagent_containers/cup/bottle/thermite = 20,
/obj/item/restraints/legcuffs/beartrap = 10,
/obj/item/food/drug/saturnx = 5,
/obj/item/food/drug/meth_crystal = 5,
/obj/item/food/drug/opium = 5,
/obj/item/reagent_containers/cup/blastoff_ampoule = 5,
/obj/item/food/drug/moon_rock = 5,
/obj/item/grenade/empgrenade = 5,
Expand Down Expand Up @@ -73,9 +80,12 @@
/obj/item/food/drug/saturnx,
/obj/item/reagent_containers/cup/blastoff_ampoule,
/obj/item/food/drug/moon_rock,
/obj/item/food/drug/meth_crystal,
/obj/item/food/drug/opium,
/obj/item/storage/pill_bottle/happy,
/obj/item/storage/pill_bottle/lsd,
/obj/item/storage/pill_bottle/psicodine,
/obj/item/storage/box/flat/fentanylpatches,
)

/obj/effect/spawner/random/contraband/permabrig_weapon
Expand Down
26 changes: 20 additions & 6 deletions code/game/objects/items/cigarettes.dm
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,10 @@ CIGARETTE PACKETS ARE IN FANCY.DM
hitsound = 'sound/items/tools/welder.ogg'
damtype = BURN
force = 4

if(reagents && reagents.has_reagent(/datum/reagent/drug/methamphetamine))
reagents.flags |= NO_REACT

if(reagents.get_reagent_amount(/datum/reagent/toxin/plasma)) // the plasma explodes when exposed to fire
var/datum/effect_system/reagents_explosion/e = new()
e.set_up(round(reagents.get_reagent_amount(/datum/reagent/toxin/plasma) / 2.5, 1), get_turf(src), 0, 0)
Expand All @@ -368,8 +372,6 @@ CIGARETTE PACKETS ARE IN FANCY.DM
qdel(src)
return
// allowing reagents to react after being lit
reagents.flags &= ~(NO_REACT)
reagents.handle_reactions()
update_appearance(UPDATE_ICON)
if(flavor_text)
var/turf/T = get_turf(src)
Expand Down Expand Up @@ -794,15 +796,16 @@ CIGARETTE PACKETS ARE IN FANCY.DM
STOP_PROCESSING(SSobj, src)
QDEL_NULL(cig_smoke)

/obj/item/cigarette/pipe/attackby(obj/item/thing, mob/user, params)
if(!istype(thing, /obj/item/food/grown))
/obj/item/cigarette/pipe/attackby(obj/item/thing, mob/user, list/modifiers, list/attack_modifiers)
if(!(istype(thing, /obj/item/food/grown) || istype(thing, /obj/item/food/drug)))
return ..()

var/obj/item/food/grown/to_smoke = thing
if(packeditem)
to_chat(user, span_warning("It is already packed!"))
return
if(!HAS_TRAIT(to_smoke, TRAIT_DRIED))

var/obj/item/to_smoke = thing
if(istype(to_smoke, /obj/item/food/grown) && !HAS_TRAIT(to_smoke, TRAIT_DRIED))
to_chat(user, span_warning("It has to be dried first!"))
return

Expand Down Expand Up @@ -836,6 +839,17 @@ CIGARETTE PACKETS ARE IN FANCY.DM
inhand_icon_on = null
inhand_icon_off = null

/obj/item/cigarette/pipe/crackpipe
name = "glass pipe"
desc = "A slick, pragmatic delivery method. The ancients learned much wisdom with this tool."
icon_state = "crackpipe"
icon_on = "crackpipeon"
icon_off = "crackpipe"
inhand_icon_on = null
inhand_icon_off = null
lung_harm = 2
custom_materials = list(/datum/material/glass = SHEET_MATERIAL_AMOUNT)

///////////
//ROLLING//
///////////
Expand Down
97 changes: 97 additions & 0 deletions code/game/objects/items/drug_items.dm
Original file line number Diff line number Diff line change
Expand Up @@ -81,3 +81,100 @@
/obj/item/reagent_containers/cup/blastoff_ampoule/Initialize(mapload, vol)
. = ..()
ADD_TRAIT(src, TRAIT_CONTRABAND, INNATE_TRAIT)

/obj/item/food/drug/meth_crystal
name = "crystal meth"
desc = "A clear, sad, fake looking crystal substance."
icon_state = "meth_crystal1"
tastes = list("awfulness", "burning")
force = 3
throwforce = 4
embed_type = /datum/embedding/meth

/datum/embedding/meth // lmao
embed_chance = 9
rip_time = 2 SECONDS
COOLDOWN_DECLARE(reagent_message_cd)
ignore_throwspeed_threshold = TRUE
var/transfer_per_second = 0.5

/datum/embedding/meth/process_effect(seconds_per_tick)
var/obj/item/rock = parent
if(!istype(rock, /obj/item/food/drug/meth_crystal))
return

if(!IS_ORGANIC_LIMB(owner_limb))
return

if(!owner?.reagents || !rock.reagents?.total_volume)
return

rock.reagents.trans_to(
owner,
transfer_per_second * seconds_per_tick,
methods = INJECT,
show_message = SPT_PROB(15, seconds_per_tick)
)

/obj/item/food/drug/meth_crystal/Initialize(mapload)
. = ..()
icon_state = pick("meth_crystal1", "meth_crystal2", "meth_crystal3", "meth_crystal4", "meth_crystal5")
ADD_TRAIT(src, TRAIT_CONTRABAND, INNATE_TRAIT)
reagents.add_reagent(/datum/reagent/drug/methamphetamine, 10)

/obj/item/food/drug/opium
name = "opium"
desc = "A little of it, taken as much as a grain of ervum is a pain-easer, and a sleep-causer, and a digester... \
but being drank too much it hurts, making spacemen lethargical, and it kills."
icon_state = "opium1"
tastes = list("amber", "a bitter vanilla")
food_reagents = list(
/datum/reagent/medicine/morphine = 10,
/datum/reagent/consumable/sugar = 1
)

/obj/item/food/drug/opium/examine()
. = ..()
if(reagents.get_reagent_amount(/datum/reagent/medicine/morphine) >= 10)
. += span_notice("The opium is large and rich in fragrance; it needs no further refinement.")
else
. += span_notice("The opium is still small, and can be pressed together with more to increase its potency and richness.")

/obj/item/food/drug/opium/Initialize(mapload) // For narcotics and black market purchases, pure and proper.
. = ..()
icon_state = pick("opium1", "opium2", "opium3", "opium4", "opium5")
ADD_TRAIT(src, TRAIT_CONTRABAND, INNATE_TRAIT)

/obj/item/food/drug/opium/raw/Initialize(mapload, potency) // Randomizes amount depending upon potency.
. = ..()
reagents.clear_reagents()
var/mult = max(potency / 20, 1) // 20 = base, 100 = 5x, 200 = 10x
reagents.add_reagent(/datum/reagent/medicine/morphine, (rand(4, 25) / 10) * mult)
reagents.add_reagent(/datum/reagent/consumable/sugar, rand(1, 7) / 10)

/obj/item/food/drug/opium/raw/interact_with_atom(obj/item/I, mob/user) // allows for combining opium up to 10u, refining it until rich and fragrant.
if(istype(I, /obj/item/food/drug/opium/raw))
var/obj/item/food/drug/opium/raw/other = I

var/current = reagents.get_reagent_amount(/datum/reagent/medicine/morphine)
if(current >= 10)
to_chat(user, span_notice("This chunk can't hold any more."))
return TRUE

var/capacity_left = 10 - current
var/transferred = other.reagents.trans_to(src, capacity_left)

if(transferred > 0)
var/overflow = reagents.get_reagent_amount(/datum/reagent/medicine/morphine) - 10
if(overflow > 0)
reagents.trans_to(other, overflow)

to_chat(user, span_notice("You press the chunks of opium together, enriching them."))
if(!other.reagents.total_volume)
qdel(other)
else
to_chat(user, span_notice("The opium cannot be pressed together further."))

return TRUE

return ..()
10 changes: 10 additions & 0 deletions code/game/objects/items/storage/boxes/flat_boxes.dm
Original file line number Diff line number Diff line change
Expand Up @@ -20,3 +20,13 @@
flat_box.pixel_y = pixel_y

qdel(src)

/obj/item/storage/box/flat/fentanylpatches
name = "discrete box"
desc = "A small box containing a set of unmarked transdermal patches."
icon_state = "flat"

/obj/item/storage/box/flat/fentanylpatches/Initialize(mapload)
. = ..()
for(var/i = 1 to 3)
new /obj/item/reagent_containers/pill/patch/fent(src)
35 changes: 35 additions & 0 deletions code/game/objects/items/storage/boxes/misc.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
/obj/item/storage/box/methdealer
name = "box"
desc = "A brown box."
icon_state = "blank_package"

/obj/item/storage/box/methdealer/PopulateContents()
var/static/list/items_inside = list(
/obj/item/food/drug/meth_crystal = 4,
/obj/item/cigarette/pipe/crackpipe = 2,
)
generate_items_inside(items_inside, src)

/obj/item/storage/box/opiumdealer
name = "box"
desc = "A brown box."
icon_state = "blank_package"

/obj/item/storage/box/opiumdealer/PopulateContents()
var/static/list/items_inside = list(
/obj/item/food/drug/opium = 4,
/obj/item/cigarette/pipe/cobpipe = 2,
)
generate_items_inside(items_inside, src)

/obj/item/storage/box/kronkdealer
name = "box"
desc = "A brown box."
icon_state = "blank_package"

/obj/item/storage/box/kronkdealer/PopulateContents()
var/static/list/items_inside = list(
/obj/item/food/drug/moon_rock = 4,
/obj/item/cigarette/pipe/crackpipe = 2,
)
generate_items_inside(items_inside, src)
66 changes: 66 additions & 0 deletions code/modules/cargo/markets/market_items/consumables.dm
Original file line number Diff line number Diff line change
Expand Up @@ -74,3 +74,69 @@
price_min = CARGO_CRATE_VALUE * 0.25
price_max = CARGO_CRATE_VALUE * 0.75
availability_prob = 90

/datum/market_item/consumable/methshipment
name = "Wholesale Methaphemtamine Shipment"
desc = "Dealer quantity! Don't get high on your own supply. Or do. You already bought it."
item = /obj/item/storage/box/methdealer

stock_min = 1
stock_max = 3
price_min = CARGO_CRATE_VALUE * 0.5
price_max = CARGO_CRATE_VALUE * 1.5
availability_prob = 25

/datum/market_item/consumable/opiumshipment
name = "Wholesale Opium Shipment"
desc = "Are your coworkers stressed? We've got vice in bulk."
item = /obj/item/storage/box/opiumdealer

stock_min = 1
stock_max = 3
price_min = CARGO_CRATE_VALUE * 0.5
price_max = CARGO_CRATE_VALUE * 1.2
availability_prob = 35

/datum/market_item/consumable/kronkshipment
name = "Wholesale Kronkaine Shipment"
desc = "Warning! Security might actually care about this one!"
item = /obj/item/storage/box/kronkdealer

stock_min = 1
stock_max = 3
price_min = CARGO_CRATE_VALUE * 1
price_max = CARGO_CRATE_VALUE * 2
availability_prob = 15

/datum/market_item/consumable/methaphetamine
name = "Crystal Meth"
desc = "A big rock, for when you just need a hit."
item = /obj/item/food/drug/meth_crystal

stock_min = 1
stock_max = 5
price_min = CARGO_CRATE_VALUE * 0.4
price_max = CARGO_CRATE_VALUE * 0.5
availability_prob = 35

/datum/market_item/consumable/heroin
name = "Heroin"
desc = "Chase the dragon."
item = /obj/item/food/drug/opium

stock_min = 1
stock_max = 5
price_min = CARGO_CRATE_VALUE * 0.35
price_max = CARGO_CRATE_VALUE * 0.5
availability_prob = 45

/datum/market_item/consumable/kronkaine
name = "Kronkaine"
desc = "An 8⁸ ball, this is hardly ever on the market!"
item = /obj/item/food/drug/moon_rock

stock_min = 1
stock_max = 2
price_min = CARGO_CRATE_VALUE * 0.5
price_max = CARGO_CRATE_VALUE * 1
availability_prob = 15
13 changes: 13 additions & 0 deletions code/modules/hydroponics/grown/flowers.dm
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,19 @@
mutatelist = list(/obj/item/seeds/poppy/geranium, /obj/item/seeds/poppy/lily)
reagents_add = list(/datum/reagent/medicine/c2/libital = 0.2, /datum/reagent/consumable/nutriment = 0.05)

/obj/item/seeds/poppy/interact_with_atom(obj/item/I, mob/user, obj/machinery/hydroponics/tray)
if(I.sharpness && !src.extracted && tray.age >= 10 && tray.age <= 19)
src.extracted = TRUE
var/seed_yield = tray.myseed?.potency
new /obj/item/food/drug/opium/raw(get_turf(src), seed_yield)
playsound(src, 'sound/effects/bubbles/bubbles.ogg', 30, TRUE)
playsound(loc, 'sound/items/weapons/bladeslice.ogg', 30, TRUE)
user.visible_message(
span_notice("You carefully slice the poppy's pod, collecting the fragrant, alluring sap.")
)
return ITEM_INTERACT_SUCCESS
return NONE

/obj/item/food/grown/poppy
seed = /obj/item/seeds/poppy
name = "poppy"
Expand Down
6 changes: 6 additions & 0 deletions code/modules/hydroponics/hydroponics.dm
Original file line number Diff line number Diff line change
Expand Up @@ -924,6 +924,12 @@
to_chat(user, span_warning("This plot is completely devoid of weeds! It doesn't need uprooting."))
return

else if(O.sharpness) // Allows for the extraction (for opium or sap) interaction if a seed has it.
if(myseed && !myseed.extracted)
myseed.interact_with_atom(O, user, src)
else
return ..()

else if(istype(O, /obj/item/secateurs))
if(!myseed)
to_chat(user, span_notice("This plot is empty."))
Expand Down
2 changes: 2 additions & 0 deletions code/modules/hydroponics/seeds.dm
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@
var/graft_gene
///Determines if the plant should be allowed to mutate early at 30+ instability.
var/seed_flags = MUTATE_EARLY
///Determines if the plant has been sliced with a hatchet to extract substances like saps.
var/extracted = 0

/obj/item/seeds/Initialize(mapload, nogenes = FALSE)
. = ..()
Expand Down
3 changes: 2 additions & 1 deletion code/modules/reagents/chemistry/reagents/drug_reagents.dm
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@
description = "Reduces stun times by about 300%, speeds the user up, and allows the user to quickly recover stamina while dealing a small amount of Brain damage. If overdosed the subject will move randomly, laugh randomly, drop items and suffer from Toxin and Brain damage. If addicted the subject will constantly jitter and drool, before becoming dizzy and losing motor control and eventually suffer heavy toxin damage."
reagent_state = LIQUID
color = "#78C8FA" //best case scenario is the "default", gets muddled depending on purity
taste_description = "harsh, burning chemicals"
overdose_threshold = 20
metabolization_rate = 0.75 * REAGENTS_METABOLISM
ph = 5
Expand Down Expand Up @@ -177,7 +178,7 @@

/datum/reagent/drug/methamphetamine/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
. = ..()
var/high_message = pick("You feel hyper.", "You feel like you need to go faster.", "You feel like you can run the world.")
var/high_message = pick("You feel hyper.", "You feel like you need to go faster.", "You feel like you can run the world.", "You understand now.")
if(SPT_PROB(2.5, seconds_per_tick))
to_chat(affected_mob, span_notice("[high_message]"))
//surfshack start
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -658,6 +658,7 @@
description = "A painkiller that allows the patient to move at full speed even when injured. Causes drowsiness and eventually unconsciousness in high doses. Overdose will cause a variety of effects, ranging from minor to lethal."
reagent_state = LIQUID
color = "#A9FBFB"
taste_description = "a perfumy, bitter vanilla"
metabolization_rate = 0.5 * REAGENTS_METABOLISM
overdose_threshold = 30
ph = 8.96
Expand Down
Loading
Loading