everything but mob stuff

This commit is contained in:
Poojawa
2018-04-23 01:06:17 -05:00
parent cc6b320f83
commit 5518efebea
111 changed files with 978 additions and 3448 deletions
+2 -2
View File
@@ -116,8 +116,8 @@
for(var/obj/item/reagent_containers/food/snacks/grown/G in PB.contents)
if(i >= max_items)
break
PB.remove_from_storage(G, src)
i++
if(PB.SendSignal(COMSIG_TRY_STORAGE_TAKE, G, src))
i++
if(i<max_items)
to_chat(user, "<span class='info'>You empty the plant bag into the biogenerator.</span>")
else if(PB.contents.len == 0)
+1 -4
View File
@@ -787,11 +787,8 @@
else if(istype(O, /obj/item/storage/bag/plants))
attack_hand(user)
var/obj/item/storage/bag/plants/S = O
for(var/obj/item/reagent_containers/food/snacks/grown/G in locate(user.x,user.y,user.z))
if(!S.can_be_inserted(G))
return
S.handle_item_insertion(G, 1)
O.SendSignal(COMSIG_TRY_STORAGE_INSERT, G, user, TRUE)
else if(istype(O, /obj/item/wrench) && unwrenchable)
if(using_irrigation)
+11 -10
View File
@@ -74,7 +74,7 @@
if(default_deconstruction_crowbar(O))
return
if (istype(O, /obj/item/storage/bag/plants))
if(istype(O, /obj/item/storage/bag/plants))
var/obj/item/storage/P = O
var/loaded = 0
for(var/obj/item/seeds/G in P.contents)
@@ -83,7 +83,7 @@
++loaded
add_seed(G)
if (loaded)
to_chat(user, "<span class='notice'>You put the seeds from \the [O.name] into [src].</span>")
to_chat(user, "<span class='notice'>You put as many seeds from \the [O.name] into [src] as you can.</span>")
else
to_chat(user, "<span class='notice'>There are no seeds in \the [O.name].</span>")
return
@@ -122,6 +122,7 @@
src.amount = am
/obj/machinery/seed_extractor/ui_interact(mob/user)
. = ..()
if (stat)
return FALSE
@@ -175,21 +176,21 @@
/obj/machinery/seed_extractor/proc/add_seed(obj/item/seeds/O)
if(contents.len >= 999)
to_chat(usr, "<span class='notice'>\The [src] is full.</span>")
return 0
return FALSE
if(ismob(O.loc))
GET_COMPONENT_FROM(STR, /datum/component/storage, O.loc)
if(STR)
if(!STR.remove_from_storage(O,src))
return FALSE
else if(ismob(O.loc))
var/mob/M = O.loc
if(!M.transferItemToLoc(O, src))
return 0
else if(istype(O.loc, /obj/item/storage))
var/obj/item/storage/S = O.loc
S.remove_from_storage(O,src)
return FALSE
. = 1
. = TRUE
for (var/datum/seed_pile/N in piles)
if (O.plantname == N.name && O.lifespan == N.lifespan && O.endurance == N.endurance && O.maturation == N.maturation && O.production == N.production && O.yield == N.yield && O.potency == N.potency)
++N.amount
return
piles += new /datum/seed_pile(O.plantname, O.lifespan, O.endurance, O.maturation, O.production, O.yield, O.potency)
return