mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-01-28 10:01:58 +00:00
## About The Pull Request
- Large amount of storage datum cleanup.
- Documentation.
- Maybe more consistent use of parent vs real_location.
- Removes the weakrefs, replaces it with just references.
- These were already managed references anyways so why bother?
- Removes a bunch of arguments no one used and would ever used so only
the most useful args are left.
- Some bugfixes.
## Why It's Good For The Game
Aiming to make storage easier to work with. The whole intent of this was
to bugfix the whole "weight class" thing that keeps popping up but I had
to do this first.
## Changelog
🆑 Melbert
fix: When placing an item into storage (such as backpacks), all nearby
mobs now get a message, rather than just the first mob.
fix: TGC decks of cards should act a bit less odd when looking inside.
refactor: Refactored a bit of storage, cleaned up a fair bit of its
code. Let me know if you notice anything funky about storage (like
backpacks).
/🆑
148 lines
5.1 KiB
Plaintext
148 lines
5.1 KiB
Plaintext
// This file contains all boxes used by the Science department and its purpose on the station.
|
|
|
|
/obj/item/storage/box/swab
|
|
name = "box of microbiological swabs"
|
|
desc = "Contains a number of sterile swabs for collecting microbiological samples."
|
|
illustration = "swab"
|
|
|
|
/obj/item/storage/box/swab/PopulateContents()
|
|
for(var/i in 1 to 7)
|
|
new /obj/item/swab(src)
|
|
|
|
/obj/item/storage/box/petridish
|
|
name = "box of petridishes"
|
|
desc = "This box purports to contain a number of high rim petridishes."
|
|
illustration = "petridish"
|
|
|
|
/obj/item/storage/box/petridish/PopulateContents()
|
|
for(var/i in 1 to 7)
|
|
new /obj/item/petri_dish(src)
|
|
|
|
/obj/item/storage/box/plumbing
|
|
name = "box of plumbing supplies"
|
|
desc = "Contains a small supply of pipes, water recyclers, and iron to connect to the rest of the station."
|
|
|
|
//Disk boxes
|
|
|
|
/obj/item/storage/box/disks
|
|
name = "diskette box"
|
|
illustration = "disk_kit"
|
|
|
|
/obj/item/storage/box/disks/PopulateContents()
|
|
for(var/i in 1 to 7)
|
|
new /obj/item/disk/data(src)
|
|
|
|
/obj/item/storage/box/monkeycubes
|
|
name = "monkey cube box"
|
|
desc = "Drymate brand monkey cubes. Just add water!"
|
|
icon_state = "monkeycubebox"
|
|
illustration = null
|
|
/// Which type of cube are we spawning in this box?
|
|
var/cube_type = /obj/item/food/monkeycube
|
|
|
|
/obj/item/storage/box/monkeycubes/Initialize(mapload)
|
|
. = ..()
|
|
atom_storage.max_slots = 7
|
|
atom_storage.set_holdable(/obj/item/food/monkeycube)
|
|
|
|
/obj/item/storage/box/monkeycubes/PopulateContents()
|
|
for(var/i in 1 to 5)
|
|
new cube_type(src)
|
|
|
|
/obj/item/storage/box/monkeycubes/syndicate
|
|
desc = "Waffle Co. brand monkey cubes. Just add water and a dash of subterfuge!"
|
|
cube_type = /obj/item/food/monkeycube/syndicate
|
|
|
|
/obj/item/storage/box/gorillacubes
|
|
name = "gorilla cube box"
|
|
desc = "Waffle Co. brand gorilla cubes. Do not taunt."
|
|
icon_state = "monkeycubebox"
|
|
illustration = null
|
|
|
|
/obj/item/storage/box/gorillacubes/Initialize(mapload)
|
|
. = ..()
|
|
atom_storage.max_slots = 3
|
|
atom_storage.set_holdable(/obj/item/food/monkeycube)
|
|
|
|
/obj/item/storage/box/gorillacubes/PopulateContents()
|
|
for(var/i in 1 to 3)
|
|
new /obj/item/food/monkeycube/gorilla(src)
|
|
|
|
/obj/item/storage/box/stockparts/basic //for ruins where it's a bad idea to give access to an autolathe/protolathe, but still want to make stock parts accessible
|
|
name = "box of stock parts"
|
|
desc = "Contains a variety of basic stock parts."
|
|
|
|
/obj/item/storage/box/stockparts/basic/PopulateContents()
|
|
var/static/items_inside = list(
|
|
/obj/item/stock_parts/capacitor = 3,
|
|
/obj/item/stock_parts/servo = 3,
|
|
/obj/item/stock_parts/matter_bin = 3,
|
|
/obj/item/stock_parts/micro_laser = 3,
|
|
/obj/item/stock_parts/scanning_module = 3,
|
|
)
|
|
generate_items_inside(items_inside,src)
|
|
|
|
/obj/item/storage/box/stockparts/deluxe
|
|
name = "box of deluxe stock parts"
|
|
desc = "Contains a variety of deluxe stock parts."
|
|
icon_state = "syndiebox"
|
|
|
|
/obj/item/storage/box/stockparts/deluxe/PopulateContents()
|
|
var/static/items_inside = list(
|
|
/obj/item/stock_parts/capacitor/quadratic = 3,
|
|
/obj/item/stock_parts/scanning_module/triphasic = 3,
|
|
/obj/item/stock_parts/servo/femto = 3,
|
|
/obj/item/stock_parts/micro_laser/quadultra = 3,
|
|
/obj/item/stock_parts/matter_bin/bluespace = 3,
|
|
)
|
|
generate_items_inside(items_inside,src)
|
|
|
|
/obj/item/storage/box/rndboards
|
|
name = "\proper the liberator's legacy"
|
|
desc = "A box containing a gift for worthy golems."
|
|
illustration = "scicircuit"
|
|
|
|
/obj/item/storage/box/rndboards/PopulateContents()
|
|
new /obj/item/circuitboard/machine/protolathe/offstation(src)
|
|
new /obj/item/circuitboard/machine/destructive_analyzer(src)
|
|
new /obj/item/circuitboard/machine/circuit_imprinter/offstation(src)
|
|
new /obj/item/circuitboard/computer/rdconsole(src)
|
|
|
|
/obj/item/storage/box/stabilized //every single stabilized extract from xenobiology
|
|
name = "box of stabilized extracts"
|
|
icon_state = "syndiebox"
|
|
|
|
/obj/item/storage/box/stabilized/Initialize(mapload)
|
|
. = ..()
|
|
atom_storage.allow_big_nesting = TRUE
|
|
atom_storage.max_slots = 99
|
|
atom_storage.max_specific_storage = WEIGHT_CLASS_GIGANTIC
|
|
atom_storage.max_total_storage = 99
|
|
|
|
/obj/item/storage/box/stabilized/PopulateContents()
|
|
var/static/items_inside = list(
|
|
/obj/item/slimecross/stabilized/adamantine=1,
|
|
/obj/item/slimecross/stabilized/black=1,
|
|
/obj/item/slimecross/stabilized/blue=1,
|
|
/obj/item/slimecross/stabilized/bluespace=1,
|
|
/obj/item/slimecross/stabilized/cerulean=1,
|
|
/obj/item/slimecross/stabilized/darkblue=1,
|
|
/obj/item/slimecross/stabilized/darkpurple=1,
|
|
/obj/item/slimecross/stabilized/gold=1,
|
|
/obj/item/slimecross/stabilized/green=1,
|
|
/obj/item/slimecross/stabilized/grey=1,
|
|
/obj/item/slimecross/stabilized/lightpink=1,
|
|
/obj/item/slimecross/stabilized/metal=1,
|
|
/obj/item/slimecross/stabilized/oil=1,
|
|
/obj/item/slimecross/stabilized/orange=1,
|
|
/obj/item/slimecross/stabilized/pink=1,
|
|
/obj/item/slimecross/stabilized/purple=1,
|
|
/obj/item/slimecross/stabilized/pyrite=1,
|
|
/obj/item/slimecross/stabilized/rainbow=1,
|
|
/obj/item/slimecross/stabilized/red=1,
|
|
/obj/item/slimecross/stabilized/sepia=1,
|
|
/obj/item/slimecross/stabilized/silver=1,
|
|
/obj/item/slimecross/stabilized/yellow=1,
|
|
)
|
|
generate_items_inside(items_inside,src)
|