GAGs Buckets (#70749)
🆑 ShizCalev qol: Converted buckets (and naturally cleanbots) over to GAGs. fix: Cleanbots built with a wooden bucket will now properly drop a wooden bucket when destroyed. /🆑
@@ -366,6 +366,7 @@
|
||||
reqs = list(/obj/item/reagent_containers/cup/bucket = 1,
|
||||
/obj/item/assembly/prox_sensor = 1,
|
||||
/obj/item/bodypart/r_arm/robot = 1)
|
||||
parts = list(/obj/item/reagent_containers/cup/bucket = 1)
|
||||
time = 4 SECONDS
|
||||
category = CAT_ROBOT
|
||||
|
||||
|
||||
@@ -775,6 +775,31 @@
|
||||
icon_file = 'icons/obj/tapes.dmi'
|
||||
json_config = 'code/datums/greyscale/json_configs/tape_piece_spikes_worn.json'
|
||||
|
||||
/datum/greyscale_config/buckets
|
||||
name = "Buckets"
|
||||
icon_file = 'icons/obj/janitor.dmi'
|
||||
json_config = 'code/datums/greyscale/json_configs/buckets.json'
|
||||
|
||||
/datum/greyscale_config/buckets_worn
|
||||
name = "Buckets Worn"
|
||||
icon_file = 'icons/mob/clothing/head/utility.dmi'
|
||||
json_config = 'code/datums/greyscale/json_configs/buckets.json'
|
||||
|
||||
/datum/greyscale_config/buckets_inhands_left
|
||||
name = "Buckets Inhands Left"
|
||||
icon_file = 'icons/mob/inhands/equipment/custodial_lefthand.dmi'
|
||||
json_config = 'code/datums/greyscale/json_configs/buckets.json'
|
||||
|
||||
/datum/greyscale_config/buckets_inhands_right
|
||||
name = "Buckets Inhands Right"
|
||||
icon_file = 'icons/mob/inhands/equipment/custodial_righthand.dmi'
|
||||
json_config = 'code/datums/greyscale/json_configs/buckets.json'
|
||||
|
||||
/datum/greyscale_config/buckets_cleanbot
|
||||
name = "Buckets - Cleanbot"
|
||||
icon_file = 'icons/mob/silicon/aibots.dmi'
|
||||
json_config = 'code/datums/greyscale/json_configs/buckets_bot.json'
|
||||
|
||||
/datum/greyscale_config/buttondown_slacks
|
||||
name = "Buttondown with Slacks"
|
||||
icon_file = 'icons/obj/clothing/under/shorts_pants_shirts.dmi'
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"bucket": [
|
||||
{
|
||||
"type": "icon_state",
|
||||
"icon_state": "bucket",
|
||||
"blend_mode": "overlay",
|
||||
"color_ids": [ 1 ]
|
||||
},
|
||||
{
|
||||
"type": "icon_state",
|
||||
"icon_state": "bucket_handle",
|
||||
"blend_mode": "overlay"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,54 @@
|
||||
{
|
||||
"cleanbot0": [
|
||||
{
|
||||
"type": "icon_state",
|
||||
"icon_state": "cleanbot_bucket",
|
||||
"blend_mode": "overlay",
|
||||
"color_ids": [ 1 ]
|
||||
},
|
||||
{
|
||||
"type": "icon_state",
|
||||
"icon_state": "cleanbot0",
|
||||
"blend_mode": "overlay"
|
||||
}
|
||||
],
|
||||
"cleanbot1": [
|
||||
{
|
||||
"type": "icon_state",
|
||||
"icon_state": "cleanbot_bucket",
|
||||
"blend_mode": "overlay",
|
||||
"color_ids": [ 1 ]
|
||||
},
|
||||
{
|
||||
"type": "icon_state",
|
||||
"icon_state": "cleanbot1",
|
||||
"blend_mode": "overlay"
|
||||
}
|
||||
],
|
||||
"cleanbot-c": [
|
||||
{
|
||||
"type": "icon_state",
|
||||
"icon_state": "cleanbot_bucket",
|
||||
"blend_mode": "overlay",
|
||||
"color_ids": [ 1 ]
|
||||
},
|
||||
{
|
||||
"type": "icon_state",
|
||||
"icon_state": "cleanbot-c",
|
||||
"blend_mode": "overlay"
|
||||
}
|
||||
],
|
||||
"bucket_proxy": [
|
||||
{
|
||||
"type": "icon_state",
|
||||
"icon_state": "cleanbot_bucket",
|
||||
"blend_mode": "overlay",
|
||||
"color_ids": [ 1 ]
|
||||
},
|
||||
{
|
||||
"type": "icon_state",
|
||||
"icon_state": "bucket_proxy",
|
||||
"blend_mode": "overlay"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -18,6 +18,9 @@
|
||||
bot_type = CLEAN_BOT
|
||||
hackables = "cleaning software"
|
||||
path_image_color = "#993299"
|
||||
greyscale_config = /datum/greyscale_config/buckets_cleanbot
|
||||
///the bucket used to build us.
|
||||
var/obj/item/reagent_containers/cup/bucket/build_bucket
|
||||
|
||||
///Flags indicating what kind of cleanables we should scan for to set as our target to clean.
|
||||
var/janitor_mode_flags = CLEANBOT_CLEAN_BLOOD
|
||||
@@ -95,7 +98,11 @@
|
||||
maints_access_required = list(ACCESS_ROBOTICS, ACCESS_JANITOR, ACCESS_MEDICAL)
|
||||
bot_mode_flags = ~(BOT_MODE_ON | BOT_MODE_REMOTE_ENABLED)
|
||||
|
||||
/mob/living/simple_animal/bot/cleanbot/Initialize(mapload)
|
||||
/mob/living/simple_animal/bot/cleanbot/Initialize(mapload, obj/item/reagent_containers/cup/bucket/bucket_obj)
|
||||
if(!bucket_obj)
|
||||
bucket_obj = new()
|
||||
bucket_obj.forceMove(src)
|
||||
|
||||
. = ..()
|
||||
|
||||
AddComponent(/datum/component/cleaner, CLEANBOT_CLEANING_TIME, \
|
||||
@@ -111,7 +118,22 @@
|
||||
|
||||
GLOB.janitor_devices += src
|
||||
|
||||
/mob/living/simple_animal/bot/cleanbot/Entered(atom/movable/arrived, atom/old_loc, list/atom/old_locs)
|
||||
if(istype(arrived, /obj/item/reagent_containers/cup/bucket))
|
||||
if(build_bucket && build_bucket != arrived)
|
||||
qdel(build_bucket)
|
||||
build_bucket = arrived
|
||||
set_greyscale(build_bucket.greyscale_colors)
|
||||
return ..()
|
||||
|
||||
/mob/living/simple_animal/bot/cleanbot/Exited(atom/movable/gone, direction)
|
||||
if(gone == build_bucket)
|
||||
build_bucket = null
|
||||
return ..()
|
||||
|
||||
|
||||
/mob/living/simple_animal/bot/cleanbot/Destroy()
|
||||
QDEL_NULL(build_bucket)
|
||||
GLOB.janitor_devices -= src
|
||||
if(weapon)
|
||||
var/atom/drop_loc = drop_location()
|
||||
@@ -390,7 +412,7 @@
|
||||
|
||||
/mob/living/simple_animal/bot/cleanbot/explode()
|
||||
var/atom/drop_loc = drop_location()
|
||||
new /obj/item/reagent_containers/cup/bucket(drop_loc)
|
||||
build_bucket.forceMove(drop_loc)
|
||||
new /obj/item/assembly/prox_sensor(drop_loc)
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -45,15 +45,42 @@
|
||||
desc = "It's a bucket with a sensor attached."
|
||||
name = "incomplete cleanbot assembly"
|
||||
icon_state = "bucket_proxy"
|
||||
greyscale_config = /datum/greyscale_config/buckets_cleanbot
|
||||
throwforce = 5
|
||||
created_name = "Cleanbot"
|
||||
var/obj/item/reagent_containers/cup/bucket/bucket_obj
|
||||
|
||||
/obj/item/bot_assembly/cleanbot/Initialize(mapload, obj/item/reagent_containers/cup/bucket/new_bucket)
|
||||
if(!new_bucket)
|
||||
new_bucket = new()
|
||||
new_bucket.forceMove(src)
|
||||
return ..()
|
||||
|
||||
/obj/item/bot_assembly/cleanbot/Entered(atom/movable/arrived, atom/old_loc, list/atom/old_locs)
|
||||
if(istype(arrived, /obj/item/reagent_containers/cup/bucket))
|
||||
if(bucket_obj && bucket_obj != arrived)
|
||||
qdel(bucket_obj)
|
||||
bucket_obj = arrived
|
||||
set_greyscale(bucket_obj.greyscale_colors)
|
||||
return ..()
|
||||
|
||||
/obj/item/bot_assembly/cleanbot/Exited(atom/movable/gone, direction)
|
||||
if(gone == bucket_obj)
|
||||
bucket_obj = null
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/item/bot_assembly/cleanbot/Destroy(force)
|
||||
QDEL_NULL(bucket_obj)
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/item/bot_assembly/cleanbot/attackby(obj/item/W, mob/user, params)
|
||||
..()
|
||||
if(istype(W, /obj/item/bodypart/l_arm/robot) || istype(W, /obj/item/bodypart/r_arm/robot))
|
||||
if(!can_finish_build(W, user))
|
||||
return
|
||||
var/mob/living/simple_animal/bot/cleanbot/A = new(drop_location())
|
||||
var/mob/living/simple_animal/bot/cleanbot/A = new(drop_location(), bucket_obj)
|
||||
A.name = created_name
|
||||
A.robot_arm = W.type
|
||||
to_chat(user, span_notice("You add [W] to [src]. Beep boop!"))
|
||||
|
||||
@@ -311,6 +311,11 @@
|
||||
inhand_icon_state = "bucket"
|
||||
lefthand_file = 'icons/mob/inhands/equipment/custodial_lefthand.dmi'
|
||||
righthand_file = 'icons/mob/inhands/equipment/custodial_righthand.dmi'
|
||||
greyscale_colors = "#0085e5" //matches 1:1 with the original sprite color before gag-ification.
|
||||
greyscale_config = /datum/greyscale_config/buckets
|
||||
greyscale_config_worn = /datum/greyscale_config/buckets_worn
|
||||
greyscale_config_inhand_left = /datum/greyscale_config/buckets_inhands_left
|
||||
greyscale_config_inhand_right = /datum/greyscale_config/buckets_inhands_right
|
||||
custom_materials = list(/datum/material/iron=200)
|
||||
w_class = WEIGHT_CLASS_NORMAL
|
||||
amount_per_transfer_from_this = 20
|
||||
@@ -331,10 +336,20 @@
|
||||
ITEM_SLOT_DEX_STORAGE
|
||||
)
|
||||
|
||||
/obj/item/reagent_containers/cup/bucket/Initialize(mapload, vol)
|
||||
if(greyscale_colors == initial(greyscale_colors))
|
||||
set_greyscale(pick(list("#0085e5", COLOR_OFF_WHITE, COLOR_ORANGE_BROWN, COLOR_SERVICE_LIME, COLOR_MOSTLY_PURE_ORANGE, COLOR_FADED_PINK, COLOR_RED, COLOR_YELLOW, COLOR_VIOLET, COLOR_WEBSAFE_DARK_GRAY)))
|
||||
return ..()
|
||||
|
||||
/obj/item/reagent_containers/cup/bucket/wooden
|
||||
name = "wooden bucket"
|
||||
icon_state = "woodbucket"
|
||||
inhand_icon_state = "woodbucket"
|
||||
greyscale_colors = null
|
||||
greyscale_config = null
|
||||
greyscale_config_worn = null
|
||||
greyscale_config_inhand_left = null
|
||||
greyscale_config_inhand_right = null
|
||||
custom_materials = list(/datum/material/wood = MINERAL_MATERIAL_AMOUNT * 2)
|
||||
armor = list(MELEE = 10, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 0, BIO = 0, FIRE = 0, ACID = 50)
|
||||
resistance_flags = FLAMMABLE
|
||||
@@ -351,8 +366,8 @@
|
||||
else if(isprox(O)) //This works with wooden buckets for now. Somewhat unintended, but maybe someone will add sprites for it soon(TM)
|
||||
to_chat(user, span_notice("You add [O] to [src]."))
|
||||
qdel(O)
|
||||
qdel(src)
|
||||
user.put_in_hands(new /obj/item/bot_assembly/cleanbot)
|
||||
var/obj/item/bot_assembly/cleanbot/new_cleanbot_ass = new(null, src)
|
||||
user.put_in_hands(new_cleanbot_ass)
|
||||
return
|
||||
|
||||
return ..()
|
||||
|
||||
|
Before Width: | Height: | Size: 19 KiB After Width: | Height: | Size: 19 KiB |
|
Before Width: | Height: | Size: 2.5 KiB After Width: | Height: | Size: 2.5 KiB |
|
Before Width: | Height: | Size: 2.5 KiB After Width: | Height: | Size: 2.5 KiB |
|
Before Width: | Height: | Size: 79 KiB After Width: | Height: | Size: 80 KiB |
|
Before Width: | Height: | Size: 31 KiB After Width: | Height: | Size: 32 KiB |