mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2025-12-31 20:53:34 +00:00
Expanded productivity bit usage (#30476)
This commit is contained in:
@@ -186,6 +186,8 @@
|
||||
|
||||
/obj/item/storage/AltClick(mob/user)
|
||||
if(ishuman(user) && Adjacent(user) && !user.incapacitated(FALSE, TRUE))
|
||||
if(attached_bits.len > 0)
|
||||
..()
|
||||
open(user)
|
||||
add_fingerprint(user)
|
||||
else if(isobserver(user))
|
||||
@@ -631,6 +633,8 @@
|
||||
var/turf/T = get_turf(src)
|
||||
hide_from(user)
|
||||
for(var/obj/item/I in contents)
|
||||
if(I & attached_bits)
|
||||
continue
|
||||
remove_from_storage(I, T)
|
||||
I.scatter_atom()
|
||||
CHECK_TICK
|
||||
|
||||
@@ -122,6 +122,8 @@
|
||||
/obj/item/kitchen/knife/Initialize(mapload)
|
||||
. = ..()
|
||||
AddComponent(/datum/component/surgery_initiator/robo)
|
||||
RegisterSignal(src, COMSIG_BIT_ATTACH, PROC_REF(add_bit))
|
||||
RegisterSignal(src, COMSIG_CLICK_ALT, PROC_REF(remove_bit))
|
||||
|
||||
/obj/item/kitchen/knife/suicide_act(mob/user)
|
||||
user.visible_message(pick("<span class='suicide'>[user] is slitting [user.p_their()] wrists with [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>", \
|
||||
|
||||
@@ -265,6 +265,11 @@
|
||||
icon_state = "portaseeder"
|
||||
origin_tech = "biotech=3;engineering=2"
|
||||
|
||||
/obj/item/storage/bag/plants/portaseeder/Initialize(mapload)
|
||||
. = ..()
|
||||
RegisterSignal(src, COMSIG_BIT_ATTACH, PROC_REF(add_bit))
|
||||
RegisterSignal(src, COMSIG_CLICK_ALT, PROC_REF(remove_bit))
|
||||
|
||||
/obj/item/storage/bag/plants/portaseeder/examine(mob/user)
|
||||
. = ..()
|
||||
if(Adjacent(user))
|
||||
@@ -275,8 +280,14 @@
|
||||
to_chat(user, "<span class='warning'>[src] has no seeds inside!</span>")
|
||||
return
|
||||
var/had_anything = FALSE
|
||||
var/seed_amount = 1
|
||||
// Multiply seeds by productivity
|
||||
seed_amount = clamp(seed_amount * bit_productivity_mod, 1, 4)
|
||||
// Reduce with low efficiency
|
||||
if(bit_efficiency_mod < 1)
|
||||
seed_amount = max(1, seed_amount * bit_efficiency_mod)
|
||||
for(var/obj/item/O in contents)
|
||||
had_anything |= seedify(O, 1)
|
||||
had_anything |= seedify(O, seed_amount)
|
||||
hide_from_all()
|
||||
if(had_anything)
|
||||
to_chat(user, "<span class='notice'>[src] whirrs a bit as it converts the plants inside to seeds.</span>")
|
||||
|
||||
Reference in New Issue
Block a user