Files
Aurora.3/code/game/objects/random/misc.dm
hazelrat d8c991674f Hydroponics Overhaul: the Atmos Update (#21059)
### What does this achieve?

This overhauls hydroponics to integrate atmospherics mechanics more
heavily, with the hope of establishing the foundations of much more
significant mechanical depth to what has been a very shallow job for a
very long time.

Currently, this is limited to the preferences and tolerances system -
hydroponics is now comprised of five 'reservoirs' of segmented portions
of the pipe system connected to trays, with a gas heater and cooler to
change temperature across the entire system, and you can cut off each
reservoir with valves to separate it from the rest and maintain its
current temperature.

Five tiers, each with a trait, have been implemented for the different
heat ideals of different plants. Plants from Adhomai and Moghes are the
most environmentally extreme, and cannot be grown outside of drastically
low and high temperatures respectively, limiting them to hydroponics
proper, whereas colder and warmer terrestrial plants can be grown at
room temperature but will grow much slower than if they were within
their preferences. **This means there will be plants that outright
cannot be grown in the garden.**

With this, hydroponics becomes an atmos puzzle. If you need to grow
nothing but mushrooms you'll probably send every tray cold, but if you
need a diversity of different temperature ranges you'll have to
fine-tune your setup and routine to have everything within their
preferences. Once you're done growing mushrooms off one reservoir, you
may turn the heat in it up so you can grow citrus, etc etc.

This also solves several bugs and makes a lot of QoL changes, the full
changelog will list everything.

<img width="608" height="320" alt="image"
src="https://github.com/user-attachments/assets/12e53224-d9be-4e69-9c48-6185d3303a14"
/>

<img width="384" height="608" alt="image"
src="https://github.com/user-attachments/assets/1a0c2b0c-8ad6-4f5c-b992-2e78035ab52d"
/>

<img width="640" height="512" alt="image"
src="https://github.com/user-attachments/assets/1cf837d1-3db5-440a-a465-071841febaea"
/>


### What about the mapping?

Atmos has been integrated into every hydroponics tray in the mapping
changes, rather than only on D1 like at present, to support the new
mechanics. I've moved as much stuff up to D2 as I could fit, in the
interest of getting players to the more visible and socially viable spot
rather than hiding in their basement. D1 is now exclusively intended as
a storage area, laboratory, and now has an expanded Hazardous Specimens
unit.

### To-do before review

- [x] Ensure that chefs can still do alien-specific menus without a
hydroponicist, now that they can't necessarily grow their stuff in the
garden - loadout produce box, maybe?
- [x] Remap xenobotany
- [x] Review whether every alien crop can still grow on its respective
in-game exoplanet - Adhomai might be okay? (Adhomai is essentially fine,
Moghes will need work before we go back into the sector)
- [x] Make sure the yield_mod interactions aren't explosive.

### Known issues

1. Yes, the examine on hydroponics trays is huge. In the long-term, IMO
this should probably be a TGUI.
2. The TGUI on seed storage units is clunky, this is also on the to-do
list for the future.
3. The logic for calculating growth is bad, it's very RNG-skewed.
Another thing for later.
4. Atmos mechanics like these can be pretty opaque to players, so this
will certainly require a wiki update shortly after merge describing
exactly what steps you should take to operate the new atmos equipment.
2025-08-02 19:58:04 +00:00

642 lines
20 KiB
Plaintext

/obj/random/smokable
name = "random smokable"
desc = "This is a random smoking item."
icon_state = "cigarettes"
problist = list(
/obj/item/storage/box/fancy/cigarettes = 30,
/obj/item/storage/box/fancy/cigarettes/blank = 5,
/obj/item/storage/box/fancy/cigarettes/acmeco = 2,
/obj/item/storage/box/fancy/cigarettes/dromedaryco = 10,
/obj/item/storage/box/fancy/cigarettes/cigar = 9,
/obj/item/storage/box/fancy/cigarettes/nicotine = 10,
/obj/item/storage/box/fancy/cigarettes/rugged = 10,
/obj/item/storage/box/fancy/cigarettes/pra = 5,
/obj/item/storage/box/fancy/cigarettes/dpra = 2,
/obj/item/storage/box/fancy/cigarettes/nka = 2,
/obj/item/storage/box/fancy/cigarettes/federation = 2,
/obj/item/storage/box/fancy/cigarettes/dyn = 2
)
/obj/random/action_figure
name = "random action figure"
desc = "This is a random action figure."
icon_state = "toy"
spawnlist = list(
/obj/item/toy/figure/cmo,
/obj/item/toy/figure/assistant,
/obj/item/toy/figure/atmos,
/obj/item/toy/figure/bartender,
/obj/item/toy/figure/borg,
/obj/item/toy/figure/gardener,
/obj/item/toy/figure/captain,
/obj/item/toy/figure/cargotech,
/obj/item/toy/figure/ce,
/obj/item/toy/figure/chaplain,
/obj/item/toy/figure/chef,
/obj/item/toy/figure/chemist,
/obj/item/toy/figure/clown,
/obj/item/toy/figure/corgi,
/obj/item/toy/figure/detective,
/obj/item/toy/figure/dsquad,
/obj/item/toy/figure/engineer,
/obj/item/toy/figure/geneticist,
/obj/item/toy/figure/hop,
/obj/item/toy/figure/hos,
/obj/item/toy/figure/qm,
/obj/item/toy/figure/janitor,
/obj/item/toy/figure/agent,
/obj/item/toy/figure/librarian,
/obj/item/toy/figure/md,
/obj/item/toy/figure/mime,
/obj/item/toy/figure/miner,
/obj/item/toy/figure/ninja,
/obj/item/toy/figure/wizard,
/obj/item/toy/figure/rd,
/obj/item/toy/figure/roboticist,
/obj/item/toy/figure/scientist,
/obj/item/toy/figure/syndie,
/obj/item/toy/figure/secofficer,
/obj/item/toy/figure/warden,
/obj/item/toy/figure/psychologist,
/obj/item/toy/figure/paramedic,
/obj/item/toy/figure/ert
)
/obj/random/plushie
name = "random plushie"
desc = "This is a random plushie."
icon_state = "plushie"
spawnlist = list(
/obj/item/toy/plushie/ian,
/obj/item/toy/plushie/drone,
/obj/item/toy/plushie/carp,
/obj/item/toy/plushie/beepsky,
/obj/item/toy/plushie/ivancarp,
/obj/item/toy/plushie/nymph,
/obj/item/toy/plushie/mouse,
/obj/item/toy/plushie/kitten,
/obj/item/toy/plushie/lizard,
/obj/item/toy/plushie/spider,
/obj/item/toy/plushie/farwa,
/obj/item/toy/plushie/bear,
/obj/item/toy/plushie/bearfire,
/obj/item/toy/plushie/schlorrgo,
/obj/item/toy/plushie/coolschlorrgo,
/obj/item/toy/plushie/slime,
/obj/item/toy/plushie/bee,
/obj/item/toy/plushie/shark,
/obj/item/toy/plushie/greimorian,
/obj/item/toy/plushie/herring_gull,
/obj/item/toy/plushie/cockatoo,
/obj/item/toy/plushie/norinori,
/obj/item/toy/plushie/fox,
/obj/item/toy/plushie/fox/black,
/obj/item/toy/plushie/fox/marble,
/obj/item/toy/plushie/fox/blue,
/obj/item/toy/plushie/fox/orange,
/obj/item/toy/plushie/fox/coffee,
/obj/item/toy/plushie/fox/pink,
/obj/item/toy/plushie/fox/purple,
/obj/item/toy/plushie/fox/crimson,
/obj/item/toy/plushie/axic,
/obj/item/toy/plushie/qill,
/obj/item/toy/plushie/xana,
/obj/item/toy/plushie/ipc,
/obj/item/toy/plushie/domadice,
/obj/item/toy/plushie/squid
)
/obj/random/balloon
name = "random balloon"
desc = "This is a random balloon."
icon_state = "bloon"
spawnlist = list(
/obj/item/toy/balloon/color = 7,
/obj/item/toy/balloon/latex = 1,
/obj/item/toy/balloon/latex/nitrile = 1,
/obj/item/toy/balloon/syndicate = 2,
/obj/item/toy/balloon/nanotrasen = 2,
/obj/item/toy/balloon/fellowship = 1,
/obj/item/toy/balloon/fellowshiphead = 1,
/obj/item/toy/balloon/contender = 1,
/obj/item/toy/balloon/contenderhead = 1,
/obj/item/toy/balloon/bat = 1,
/obj/item/toy/balloon/ghost = 1,
/obj/item/toy/balloon/xmastree = 1,
/obj/item/toy/balloon/candycane = 1
)
/obj/random/desktoy
name = "random desk toy"
desc = "This is a random desk toy."
icon_state = "desktoy"
spawnlist = list(
/obj/item/toy/desk/newtoncradle,
/obj/item/toy/desk/fan,
/obj/item/toy/desk/officetoy,
/obj/item/toy/desk/dippingbird
)
/obj/random/lavalamp
name = "random lava lamp"
desc = "This is a random lava lamp."
icon_state = "lavalamp"
spawnlist = list(
/obj/item/device/flashlight/lamp/lava,
/obj/item/device/flashlight/lamp/lava/red,
/obj/item/device/flashlight/lamp/lava/orange,
/obj/item/device/flashlight/lamp/lava/yellow,
/obj/item/device/flashlight/lamp/lava/green,
/obj/item/device/flashlight/lamp/lava/cyan,
/obj/item/device/flashlight/lamp/lava/blue,
/obj/item/device/flashlight/lamp/lava/purple,
/obj/item/device/flashlight/lamp/lava/pink
)
/obj/random/glowstick
name = "random glowstick"
desc = "This is a random glowstick."
icon_state = "glowstick"
spawnlist = list(
/obj/item/device/flashlight/flare/glowstick,
/obj/item/device/flashlight/flare/glowstick/red,
/obj/item/device/flashlight/flare/glowstick/blue,
/obj/item/device/flashlight/flare/glowstick/orange,
/obj/item/device/flashlight/flare/glowstick/yellow
)
/obj/random/arcade
name = "random arcade loot"
desc = "Arcade loot!"
icon_state = "toy"
spawnlist = list(
/obj/item/storage/box/snappops = 11,
/obj/item/clothing/under/syndicate/tacticool = 5,
/obj/item/toy/sword = 22,
/obj/item/gun/projectile/revolver/capgun = 11,
/obj/item/toy/crossbow = 11,
/obj/item/storage/box/fancy/crayons = 11,
/obj/item/toy/spinningtoy = 11,
/obj/item/toy/mech/ripley = 1,
/obj/item/toy/mech/fireripley = 1,
/obj/item/toy/mech/deathripley = 1,
/obj/item/toy/mech/gygax = 1,
/obj/item/toy/mech/durand = 1,
/obj/item/toy/mech/honk = 1,
/obj/item/toy/mech/marauder = 1,
/obj/item/toy/mech/seraph = 1,
/obj/item/toy/mech/mauler = 1,
/obj/item/toy/mech/odysseus = 1,
/obj/item/toy/mech/phazon = 1,
/obj/item/reagent_containers/spray/waterflower = 5,
/obj/random/action_figure = 11,
/obj/random/plushie = 44,
/obj/item/toy/cultsword = 5,
/obj/random/balloon = 22,
/obj/item/toy/katana = 11,
/obj/item/toy/bosunwhistle = 5,
/obj/item/storage/belt/champion = 11,
/obj/item/pen/invisible = 5,
/obj/item/grenade/fake = 1,
/obj/item/bikehorn = 11,
/obj/item/clothing/mask/fakemoustache = 11,
/obj/item/clothing/mask/gas/mime = 11,
/obj/item/clothing/shoes/slippers/carp = 9,
/obj/item/gun/energy/wand/toy = 5,
/obj/item/device/binoculars = 11,
/obj/item/device/megaphone = 11,
/obj/item/eightball = 11,
/obj/item/eightball/haunted = 1,
/obj/item/eightball/broken = 1,
/obj/item/spirit_board = 5,
/obj/item/device/laser_pointer = 1,
/obj/item/clothing/accessory/badge/press/plastic = 2,
/obj/item/storage/box/partypopper = 11
)
/obj/random/arcade/orion
name = "random arcade loot for orion trails"
desc = "Arcade loot for orion trails aracde machine!"
icon_state = "toy"
spawnlist = list(
/obj/item/clothing/under/syndicate/tacticool = 7,
/obj/item/toy/sword = 22,
/obj/item/gun/projectile/revolver/capgun = 11,
/obj/item/gun/bang = 22,
/obj/item/toy/crossbow = 11,
/obj/random/action_figure = 11,
/obj/item/toy/cultsword = 7,
/obj/random/balloon = 22,
/obj/item/toy/katana = 11,
/obj/random/plushie = 55,
/obj/item/storage/belt/champion = 11,
/obj/item/pen/invisible = 10,
/obj/item/grenade/fake = 7,
/obj/item/gun/energy/wand/toy = 7,
/obj/item/device/binoculars = 11,
/obj/item/device/megaphone = 11,
/obj/item/eightball = 11,
/obj/item/eightball/haunted = 5,
/obj/item/spirit_board = 5,
/obj/item/clothing/accessory/badge/press/plastic = 2
)
/obj/random/animal_crate
name = "random animal"
desc = "Contains a random crate with an animal."
icon_state = "woodcrate"
spawnlist = list(
/obj/structure/largecrate/animal/corgi = 3,
/obj/structure/largecrate/animal/cow = 4,
/obj/structure/largecrate/animal/goat = 3,
/obj/structure/largecrate/animal/cat = 2,
/obj/structure/largecrate/animal/chick = 4,
/obj/structure/largecrate/animal/adhomai = 0.5,
/obj/structure/largecrate/animal/adhomai/fatshouter = 0.5,
/obj/structure/largecrate/animal/adhomai/rafama = 0.5,
/obj/structure/largecrate/animal/adhomai/schlorrgo = 0.2,
/obj/structure/largecrate/animal/hakhma = 0.5,
/obj/structure/largecrate/animal/moghes = 0.5,
/obj/structure/largecrate/animal/moghes/warmount = 0.2,
/obj/structure/largecrate/animal/moghes/miervesh = 0.5,
/obj/structure/largecrate/animal/moghes/otzek = 0.5
)
/obj/random/random_flag
name = "random flag"
desc = "Contains a random boxed flag or banner."
icon_state = "flagbox"
spawnlist = list(
/obj/item/flag/biesel,
/obj/item/flag/biesel/l,
/obj/item/flag/dominia,
/obj/item/flag/dominia/l,
/obj/item/flag/dpra,
/obj/item/flag/dpra/l,
/obj/item/flag/elyra,
/obj/item/flag/elyra/l,
/obj/item/flag/eridani,
/obj/item/flag/eridani/l,
/obj/item/flag/hegemony,
/obj/item/flag/hegemony/l,
/obj/item/flag/heph,
/obj/item/flag/heph/l,
/obj/item/flag/nralakk,
/obj/item/flag/nralakk/l,
/obj/item/flag/nanotrasen,
/obj/item/flag/nanotrasen/l,
/obj/item/flag/nka,
/obj/item/flag/nka/l,
/obj/item/flag/pra,
/obj/item/flag/pra/l,
/obj/item/flag/sol,
/obj/item/flag/sol/l,
/obj/item/flag/sedantis,
/obj/item/flag/sedantis/l,
/obj/item/flag/zenghu,
/obj/item/flag/zenghu/l,
/obj/item/flag/coalition,
/obj/item/flag/coalition/l
)
/obj/random/gift
name = "random gift"
desc = "Contains a randomly sized gift."
icon_state = "present"
spawnlist = list(
/obj/item/xmasgift = 0.5,
/obj/item/xmasgift/medium = 0.3,
/obj/item/xmasgift/large = 0.2
)
/obj/random/junk
name = "random trash"
desc = "This is toss."
icon_state = "junk"
spawn_nothing_percentage = 5
problist = list(
/obj/item/trash/koisbar = 0.5,
/obj/item/trash/raisins = 1,
/obj/item/trash/candy = 1,
/obj/item/trash/cheesie = 2,
/obj/item/trash/chips = 0.75,
/obj/item/trash/popcorn = 0.75,
/obj/item/trash/sosjerky = 0.5,
/obj/item/trash/syndi_cakes = 0.25,
/obj/item/trash/waffles = 0.75,
/obj/item/trash/plate = 0.75,
/obj/item/trash/snack_bowl = 0.75,
/obj/item/trash/pistachios = 0.75,
/obj/item/trash/semki = 0.5,
/obj/item/trash/tray = 0.75,
/obj/item/trash/candle = 0.75,
/obj/item/trash/liquidfood = 0.75,
/obj/item/trash/tastybread= 0.75,
/obj/item/trash/meatsnack = 0.5,
/obj/item/trash/maps = 0.5,
/obj/item/trash/tuna = 0.5,
/obj/effect/decal/cleanable/ash = 1.5,
/obj/effect/decal/cleanable/dirt = 2,
/obj/effect/decal/cleanable/flour = 1,
/obj/effect/decal/cleanable/greenglow = 1,
/obj/effect/decal/cleanable/molten_item = 1,
/obj/effect/decal/cleanable/vomit = 2,
/obj/effect/decal/cleanable/generic = 2,
/obj/effect/decal/cleanable/liquid_fuel = 0.5,
/obj/effect/decal/cleanable/mucus = 1.5,
/obj/effect/decal/cleanable/blood/drip = 1.5,
/obj/item/storage/box = 1,
/obj/item/material/shard = 1,
/obj/item/material/shard/shrapnel = 1,
/obj/item/broken_bottle = 1,
/obj/item/stack/material/cardboard = 1,
/obj/item/stack/rods = 1,
/obj/item/corncob = 1,
/obj/item/paper/crumpled = 1,
/obj/item/inflatable/torn = 1,
/obj/item/ammo_casing/c45/rubber = 0.5,
/obj/item/ammo_casing/c9mm/rubber = 0.5,
/obj/item/ammo_casing/c45/flash = 0.5,
/obj/item/ammo_casing/shotgun/beanbag = 0.5,
/obj/item/flame/lighter/random = 0.25,
/obj/item/lipstick/random = 0.25,
/obj/item/reagent_containers/glass/beaker/vial/random = 0.1,
/obj/item/towel/random = 0.1,
/obj/item/device/flashlight/flare/glowstick/random = 0.25,
/obj/item/stack/cable_coil/random/ = 0.1,
/obj/item/bananapeel = 0.1, //honk,
/obj/item/key = 0.1,
/obj/item/reagent_containers/blood/ripped = 0.1,
/obj/item/shreddedp = 0.1
)
/obj/random/dirt_75
name = "dirt 75%"
desc = "75% chance of spawning dirt, otherwise nothing."
icon = 'icons/effects/effects.dmi'
icon_state = "dirt"
layer = BELOW_OBJ_LAYER // just so it appears under structures in map editor
spawn_nothing_percentage = 25
spawnlist = list(
/obj/effect/decal/cleanable/dirt
)
/obj/random/vendor
name = "random vendor"
icon_state = "vendor"
var/depleted = FALSE
var/scan_id = TRUE // Should the spawned vendor check IDs
problist = list(
/obj/machinery/vending/boozeomat = 1,
/obj/machinery/vending/coffee = 1,
/obj/machinery/vending/snack = 1,
/obj/machinery/vending/cola = 1,
/obj/machinery/vending/cigarette = 1,
/obj/machinery/vending/medical = 1.2,
/obj/machinery/vending/phoronresearch = 0.7,
/obj/machinery/vending/security = 0.3,
/obj/machinery/vending/hydronutrients = 1,
/obj/machinery/vending/hydroseeds = 1,
/obj/machinery/vending/dinnerware = 1,
/obj/machinery/vending/sovietsoda = 2,
/obj/machinery/vending/tool = 1,
/obj/machinery/vending/engivend = 0.6,
/obj/machinery/vending/engineering = 1,
/obj/machinery/vending/robotics = 1,
/obj/machinery/vending/tacticool = 0.2,
/obj/machinery/vending/tacticool/ert = 0.1
)
has_postspawn = TRUE
/obj/random/vendor/Initialize(mapload, _depleted = 0)
depleted = _depleted
. = ..()
/obj/random/vendor/post_spawn(obj/machinery/vending/V)
if (!depleted)
return
//Greatly reduce the contents. it will have 0-20% of what it usually has
for (var/content in V.products)
if (prob(40))
V.products[content] = 0 //40% chance to completely lose an item
else
var/multiplier = rand(0,20) //Else, we reduce it to a very low percentage
if (multiplier)
multiplier /= 100
V.products[content] *= multiplier
if (V.products[content] < 1 && V.products[content] > 0) //But we'll usually have at least 1 left
V.products[content] = 0
// Clamp to an integer so we don't get 0.78 of a screwdriver.
V.products[content] = round(V.products[content])
V.scan_id &= scan_id
/obj/random/smalltank
name = "random small tank"
icon_state = "airtank"
/obj/random/smalltank/item_to_spawn()
if (prob(40))
return /obj/item/tank/emergency_oxygen
else if (prob(60))
return /obj/item/tank/emergency_oxygen/engi
else
return /obj/item/tank/emergency_oxygen/double
/obj/random/pottedplant
name = "random potted plant, big"
desc = "Spawns a random potted plant."
icon_state = "potted_plant_big"
spawn_nothing_percentage = 1
/obj/random/pottedplant/spawn_item()
var/obj/structure/flora/pottedplant/P = null
var/list/unwanted = list(
/obj/structure/flora/pottedplant, // don't want parent base obj
/obj/structure/flora/pottedplant/dead2, // does not fit horizon's aesthetic
/obj/structure/flora/pottedplant/empty
)
var/list/rare = list(
/obj/structure/flora/pottedplant/eye,
/obj/structure/flora/pottedplant/dead
)
while(!P)
P = pick(typesof(/obj/structure/flora/pottedplant))
if((P in unwanted) || ((P in rare) && prob(50)))
P = null
. = new P(loc)
/obj/random/pottedplant_small
name = "random potted plant, small"
desc = "Spawns a random potted plant."
icon_state = "potted_plant_small"
spawn_nothing_percentage = 1
/obj/random/pottedplant_small/spawn_item()
var/obj/item/flora/pottedplant_small/P = null
var/list/unwanted = list(
/obj/item/flora/pottedplant_small, // don't want parent base obj
/obj/item/flora/pottedplant_small/empty
)
var/list/rare = list(
/obj/item/flora/pottedplant_small/dead
)
while(!P)
P = pick(typesof(/obj/item/flora/pottedplant_small))
if((P in unwanted) || ((P in rare) && prob(50)))
P = null
. = new P(loc)
/obj/random/syrup
name = "random syrup"
desc = "Contains random bottles of flavored syrup."
icon_state = "syrup"
problist = list(
/obj/item/reagent_containers/food/condiment/syrup_chocolate = 2,
/obj/item/reagent_containers/food/condiment/syrup_strawberry = 1,
/obj/item/reagent_containers/food/condiment/syrup_berry = 0.5,
/obj/item/reagent_containers/food/condiment/syrup_raspberry = 0.3,
/obj/item/reagent_containers/food/condiment/syrup_blueberry = 0.3,
/obj/item/reagent_containers/food/condiment/syrup_blue_raspberry = 0.3,
/obj/item/reagent_containers/food/condiment/syrup_ylphaberry = 0.3,
/obj/item/reagent_containers/food/condiment/syrup_caramel = 0.5,
/obj/item/reagent_containers/food/condiment/syrup_pumpkin = 0.3,
/obj/item/reagent_containers/food/condiment/syrup_vanilla = 0.5,
/obj/item/reagent_containers/food/condiment/syrup_dirtberry = 0.3
)
/obj/random/condiment
name = "random condiments and sauces"
desc = "Contains random condiments for use in the kitchen."
icon_state = "condiment"
spawn_nothing_percentage = 10
problist = list(
/obj/item/reagent_containers/food/condiment/ketchup = 2,
/obj/item/reagent_containers/food/condiment/mayonnaise = 1.8,
/obj/item/reagent_containers/food/condiment/hot_sauce = 1.5,
/obj/random/syrup = 1.5,
/obj/item/reagent_containers/food/condiment/honey = 1,
/obj/item/reagent_containers/food/condiment/soysauce = 1,
/obj/item/reagent_containers/food/condiment/garlicsauce = 1,
/obj/item/reagent_containers/food/condiment/barbecue = 1,
/obj/item/reagent_containers/food/condiment/ntella = 1,
/obj/item/reagent_containers/food/condiment/peanut_butter = 1,
/obj/item/reagent_containers/food/condiment/cherry_jelly = 1,
/obj/item/reagent_containers/food/condiment/sweet_chili = 0.8,
/obj/item/reagent_containers/food/condiment/grape_jelly = 0.5
)
/obj/random/kitchen_staples
name = "random kitchen staples"
desc = "Contains random ingredients that are handy in the kitchen"
icon_state = "ingredient_bag"
spawn_nothing_percentage = 20
problist = list(
/obj/item/reagent_containers/food/condiment/gelatin = 1,
/obj/item/reagent_containers/food/condiment/batter = 1,
/obj/item/reagent_containers/food/condiment/syrup_simple = 1,
/obj/item/reagent_containers/food/condiment/vanilla = 1,
/obj/item/reagent_containers/food/condiment/rice = 1,
/obj/item/reagent_containers/food/condiment/cocoa = 1
)
/obj/random/maintenance_junk_or_loot
name = "random maintenance junk or loot"
desc = "Spawns any of: junk, loot, trash, trash pile, locker with junk or loot, (or other things)."
icon_state = "maint_junk_loot"
spawn_nothing_percentage = 25
has_postspawn = TRUE
problist = list(
// spawn just one thing:
/obj/random/junk = 3,
/obj/random/dirt_75 = 1,
/obj/random/loot = 1,
/obj/structure/trash_pile = 1,
/obj/random/tool = 0.2,
/obj/random/tech_supply = 0.1,
/obj/structure/girder = 0.1,
/obj/random/canister/empty = 0.1,
/obj/random/canister/filled = 0.05,
/obj/structure/closet/crate/loot = 0.01,
// spawn a container and maybe fill it with more junk:
/obj/structure/table/rack = 1,
/obj/structure/table/steel = 1,
/obj/structure/closet/crate = 1,
/obj/structure/closet/crate/trashcart = 0.2,
/obj/structure/closet/crate/plastic = 0.1,
)
var/list/more_junk_problist = list(
/obj/random/junk = 2,
/obj/random/loot = 1,
/obj/random/tech_supply = 0.2,
/obj/random/tool = 0.2,
)
/obj/random/maintenance_junk_or_loot/post_spawn(var/obj/spawned)
if(istype(spawned, /obj/structure/table))
if(prob(65))
var/obj/more_junk = pickweight(more_junk_problist)
new more_junk(spawned.loc)
else if(istype(spawned, /obj/structure/closet))
if(prob(90))
var/i_max = rand(1, 4)
for(var/i in 1 to i_max)
var/obj/more_junk = pickweight(more_junk_problist)
new more_junk(spawned.loc)
/obj/random/yarn
name = "random yarn"
desc = "This is a random ball of yarn."
icon = 'icons/obj/item/knitting.dmi'
icon_state = "white_ball"
spawnlist = list(
/obj/item/yarn/blue,
/obj/item/yarn/green,
/obj/item/yarn/purple,
/obj/item/yarn/red,
/obj/item/yarn/yellow
)
/obj/random/horticulture_magazine
name = "random horticulture magazine"
desc = "This is a random magazine."
icon = 'icons/obj/library.dmi'
icon_state = "horticulture1"
spawnlist = list(
/obj/item/toy/comic/magazine/horticulturetoday/issue1,
/obj/item/toy/comic/magazine/horticulturetoday/issue2,
/obj/item/toy/comic/magazine/horticulturetoday/issue3,
/obj/item/toy/comic/magazine/horticulturetoday/issue4,
/obj/item/toy/comic/magazine/horticulturetoday/issue5,
/obj/item/toy/comic/magazine/horticulturetoday/issue6
)
/obj/random/hydroponics
name = "random hydroponics item"
desc = "This is a hydroponics thing."
icon_state = "tech_supply"
spawnlist = list(
/obj/item/material/scythe/sickle = 1,
/obj/item/material/scythe = 1,
/obj/item/reagent_containers/glass/bottle/mutagen = 1,
/obj/item/reagent_containers/glass/fertilizer/rh = 1,
/obj/item/reagent_containers/glass/fertilizer/l4z = 1,
/obj/item/reagent_containers/glass/fertilizer/ez = 1,
/obj/item/crowbar = 1,
/obj/item/shovel = 1,
/obj/item/shovel/spade = 1,
/obj/item/wrench = 1,
/obj/random/condiment = 3,
/obj/random/kitchen_staples = 3,
/obj/random/smokable = 1,
/obj/random/seed = 3,
/obj/random/plushie = 1,
/obj/random/med_stack = 1,
/obj/item/reagent_containers/glass/bottle/ammonia = 1,
)