mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-21 19:17:50 +01:00
* Get pants that match or else you gonna look silly yo
* Posters
* Fix other hud elements
* Rereviewed
* Update shotglass.dm
* Fix for new merged PRs
* Typo
* Coming across other stuff
* Update theblob.dm
* No takebacksies
* smh i forget to leave a comment
* Updated for the detgun and cards
* Should have rerun langserver again
* No longer plastic, more in scope
* Damn you bluespace
* Reverting turret logic, out of scope at this point
* Tweak that part
* Went over energy guns again, and fixed UI White's sprite sheet
* Welding masks, glasses, and JUSTICE
* Update portable_atmospherics.dm
* Cleaning up, clearing things up
* Review and suggestions
* Update valve.dm
* More tweaks
* Missing character
* Not distinct lightmasks, so they can be overlays
* Update generator.dm
* Add parameter so holodeck doesn't try to make a perfect copy
* Update unsorted.dm
* Spiders
* Better fix for spiders, fix vamps too
* Ghosts
* Update telekinesis.dm
* Cleaning up old procs
* It's set up to not copy datums... Unless they're in a list
* Donuts, duct tape, and detgun. D3VR coming to Early Access
* Update procs that interact with doors so they call update_state instead
* Forgot one spot, and actually might as well just force lock
* Cleaning up other things... Sigh, and kitty ears
* oops
* Getting used to how it works
* blinds
* Going back to the suit obscuring thing, so it doesn't update all the time
* Missed that from merging master
* I made this PR and forgot about it
* Fix runtimes in cards
* Make things a bit more unified
* Update update_icons.dm
* yarn, really?
* Update library_equipment.dm
* Update shieldgen.dm
* Every time Charlie merges something, I go back and see if I can improve things further
* what's this? more?
* Update misc_special.dm
* wow, paper
* Review
* More reviews
* To be sure, seems like being broken messed something sometimes
* Brought airlocks closer to how TG works to iron out some stuff
* Pizza and morgue
* Doesn't seem to hurt, tried with holodeck
* Revert "Doesn't seem to hurt, tried with holodeck"
This reverts commit 158529302b.
* Icon conflict
* Fix organ damage
* Don't ask how. Why. It's like that on prod too.
* Cutting down on things and updating from TG.
* More flexible. Just in case the thing you stuck it on didn't destroy.
* Hydro was one the things I touched earlier on, better rework it
* Reviews
* Cleaning up further, also bri'ish
* Undo a change I did, and switch over to a more recent implementation
* Update biogenerator.dm
* Rolling back to old airlocks, but with new duct taped note
* Functionally the same. I'd just rather not have the smoothing happen there
* Went over APCs again
* Fix welding helmet names in species files
* Update airlock.dm
* Update persistent_overlay.dm
* Oh, topic
100 lines
3.4 KiB
Plaintext
100 lines
3.4 KiB
Plaintext
/obj/structure/fermenting_barrel
|
|
name = "wooden barrel"
|
|
desc = "A large wooden barrel. You can ferment fruits and such inside it, or just use it to hold liquid."
|
|
icon = 'icons/obj/objects.dmi'
|
|
icon_state = "barrel"
|
|
density = TRUE
|
|
anchored = TRUE
|
|
container_type = DRAINABLE | AMOUNT_VISIBLE
|
|
pressure_resistance = 2 * ONE_ATMOSPHERE
|
|
max_integrity = 300
|
|
var/open = FALSE
|
|
var/speed_multiplier = 1 //How fast it distills. Defaults to 100% (1.0). Lower is better.
|
|
|
|
/obj/structure/fermenting_barrel/Initialize()
|
|
create_reagents(300) //Bluespace beakers, but without the portability or efficiency in circuits.
|
|
. = ..()
|
|
|
|
/obj/structure/fermenting_barrel/examine(mob/user)
|
|
. = ..()
|
|
. += "<span class='notice'>It is currently [open ? "open, letting you pour liquids in." : "closed, letting you draw liquids from the tap."] </span>"
|
|
|
|
/obj/structure/fermenting_barrel/proc/makeWine(obj/item/reagent_containers/food/snacks/grown/G)
|
|
if(G.reagents)
|
|
G.reagents.trans_to(src, G.reagents.total_volume)
|
|
var/amount = G.seed.potency / 4
|
|
if(G.distill_reagent)
|
|
reagents.add_reagent(G.distill_reagent, amount)
|
|
else
|
|
var/data = list()
|
|
data["names"] = list("[initial(G.name)]" = 1)
|
|
data["color"] = G.filling_color
|
|
data["alcohol_perc"] = G.wine_power
|
|
if(G.wine_flavor)
|
|
data["tastes"] = list(G.wine_flavor = 1)
|
|
else
|
|
data["tastes"] = list(G.tastes[1] = 1)
|
|
reagents.add_reagent("fruit_wine", amount, data)
|
|
qdel(G)
|
|
playsound(src, 'sound/effects/bubbles.ogg', 50, TRUE)
|
|
|
|
/obj/structure/fermenting_barrel/attackby(obj/item/I, mob/user, params)
|
|
var/obj/item/reagent_containers/food/snacks/grown/G = I
|
|
if(istype(G))
|
|
if(!G.can_distill)
|
|
to_chat(user, "<span class='warning'>You can't distill this into anything...</span>")
|
|
return FALSE
|
|
else if(!user.drop_item())
|
|
to_chat(user, "<span class='warning'>[G] is stuck to your hand!</span>")
|
|
return FALSE
|
|
G.forceMove(src)
|
|
to_chat(user, "<span class='notice'>You place [G] into [src] to start the fermentation process.</span>")
|
|
addtimer(CALLBACK(src, .proc/makeWine, G), rand(80, 120) * speed_multiplier)
|
|
else if(I.is_refillable())
|
|
return FALSE // To refill via afterattack proc
|
|
else
|
|
return ..()
|
|
|
|
/obj/structure/fermenting_barrel/attack_hand(mob/user)
|
|
open = !open
|
|
if(open)
|
|
container_type = REFILLABLE | AMOUNT_VISIBLE
|
|
to_chat(user, "<span class='notice'>You open [src], letting you fill it.</span>")
|
|
else
|
|
container_type = DRAINABLE | AMOUNT_VISIBLE
|
|
to_chat(user, "<span class='notice'>You close [src], letting you draw from its tap.</span>")
|
|
update_icon(UPDATE_ICON_STATE)
|
|
|
|
/obj/structure/fermenting_barrel/crowbar_act(mob/living/user, obj/item/I)
|
|
. = TRUE
|
|
if(!I.use_tool(src, user, 0))
|
|
return
|
|
TOOL_ATTEMPT_DISMANTLE_MESSAGE
|
|
if(I.use_tool(src, user, 50, volume = I.tool_volume))
|
|
TOOL_DISMANTLE_SUCCESS_MESSAGE
|
|
deconstruct(disassembled = TRUE)
|
|
|
|
/obj/structure/fermenting_barrel/wrench_act(mob/living/user, obj/item/I)
|
|
. = TRUE
|
|
default_unfasten_wrench(user, I, time = 20)
|
|
|
|
/obj/structure/fermenting_barrel/deconstruct(disassembled = FALSE)
|
|
var/mat_drop = 15
|
|
if(disassembled)
|
|
mat_drop = 30
|
|
new /obj/item/stack/sheet/wood(drop_location(), mat_drop)
|
|
..()
|
|
|
|
/obj/structure/fermenting_barrel/update_icon_state()
|
|
if(open)
|
|
icon_state = "barrel_open"
|
|
else
|
|
icon_state = "barrel"
|
|
|
|
/datum/crafting_recipe/fermenting_barrel
|
|
name = "Wooden Barrel"
|
|
result = list(/obj/structure/fermenting_barrel)
|
|
reqs = list(/obj/item/stack/sheet/wood = 30)
|
|
time = 50
|
|
category = CAT_PRIMAL
|