mirror of
https://github.com/KabKebab/GS13.git
synced 2026-07-10 07:30:36 +01:00
@@ -14,6 +14,7 @@
|
||||
volume = 50
|
||||
resistance_flags = NONE
|
||||
var/isGlass = TRUE //Whether the 'bottle' is made of glass or not so that milk cartons dont shatter when someone gets hit by it
|
||||
splashable = TRUE
|
||||
|
||||
/obj/item/reagent_containers/food/drinks/on_reagent_change(changetype)
|
||||
if (gulp_size < 5)
|
||||
@@ -104,6 +105,7 @@
|
||||
/obj/item/reagent_containers/food/drinks/throw_impact(atom/target, datum/thrownthing/throwinfo)
|
||||
. = ..()
|
||||
if(!.) //if the bottle wasn't caught
|
||||
SplashReagents(target)
|
||||
smash(target, throwinfo.thrower, TRUE)
|
||||
|
||||
/obj/item/reagent_containers/food/drinks/proc/smash(atom/target, mob/thrower, ranged = FALSE)
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
var/spillable = FALSE
|
||||
var/beaker_weakness_bitflag = NONE//Bitflag!
|
||||
var/container_HP = 2
|
||||
var/splashable = FALSE
|
||||
|
||||
/obj/item/reagent_containers/Initialize(mapload, vol)
|
||||
. = ..()
|
||||
@@ -92,7 +93,7 @@
|
||||
transform = initial(transform)
|
||||
|
||||
/obj/item/reagent_containers/proc/SplashReagents(atom/target, thrown = FALSE)
|
||||
if(!reagents || !reagents.total_volume || !spillable)
|
||||
if(!reagents || !reagents.total_volume || !(splashable ? splashable : spillable))
|
||||
return
|
||||
|
||||
if(ismob(target) && target.reagents)
|
||||
|
||||
Reference in New Issue
Block a user