refactors washing items

fixes #3570
Could have fixed with another if statement in sink/attackby, but it was
already pretty snowflakey, and had the potential to get worse
Items now have a wash proc that the sink calls, that can be overridden
when needed
This commit is contained in:
VampyrBytes
2016-02-20 12:01:40 +00:00
parent e124b53593
commit 386ed87126
6 changed files with 52 additions and 42 deletions

View File

@@ -71,4 +71,11 @@
for (var/datum/reagent/R in snack.reagents.reagent_list) //no reagents will be left behind
data += "[R.id]([R.volume] units); " //Using IDs because SOME chemicals(I'm looking at you, chlorhydrate-beer) have the same names as other chemicals.
return data
else return "No reagents"
else return "No reagents"
/obj/item/weapon/reagent_containers/wash(mob/user, atom/source)
if(is_open_container())
reagents.add_reagent("water", min(volume - reagents.total_volume, amount_per_transfer_from_this))
user << "<span class='notice'>You fill [src] from [source].</span>"
return
..()