IPC Culinary Processing Implant (#30475)

* add the ipc culinary implant

* add spans
This commit is contained in:
Paul
2025-10-17 16:53:11 +00:00
committed by GitHub
parent 9a578dbf61
commit afd37f310f
6 changed files with 41 additions and 8 deletions
+1
View File
@@ -232,6 +232,7 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
#define TRAIT_FORCED_STANDING "forced_standing" // The mob cannot be floored, or lie down
#define TRAIT_IPC_JOINTS_MAG "ipc_joints_mag" // IPC has weaker limbs but can re-attach them with ease
#define TRAIT_IPC_JOINTS_SEALED "ipc_joints_sealed" // The IPC's limbs will not pop off bar sharp damage (aka like a human), but will take slightly more stamina damage
#define TRAIT_IPC_CAN_EAT "ipc_can_eat" // IPC can eat food
#define TRAIT_HAS_GPS "has_gps" // used for /Stat
#define TRAIT_CAN_VIEW_HEALTH "can_view_health" // Also used for /Stat
#define TRAIT_MAGPULSE "magpulse" // Used for anything that is magboot related
+1
View File
@@ -81,6 +81,7 @@ GLOBAL_LIST_INIT(traits_by_type, list(
"TRAIT_SHOW_WIRE_INFO" = TRAIT_SHOW_WIRE_INFO,
"TRAIT_IPC_JOINTS_MAG" = TRAIT_IPC_JOINTS_MAG,
"TRAIT_IPC_JOINTS_SEALED" = TRAIT_IPC_JOINTS_SEALED,
"TRAIT_IPC_CAN_EAT" = TRAIT_IPC_CAN_EAT,
"TRAIT_CAN_BE_EATEN_BY_LIZARDS" = TRAIT_EDIBLE_BUG,
"TRAIT_FLATTENED" = TRAIT_FLATTENED,
"TRAIT_SM_HALLUCINATION_IMMUNE" = SM_HALLUCINATION_IMMUNE,
@@ -1780,25 +1780,27 @@ Eyes need to have significantly high darksight to shine unless the mob has the X
return TRUE
/mob/living/carbon/human/can_eat(flags = 255)
return dna.species && (dna.species.dietflags & flags)
return dna.species && ((dna.species.dietflags & flags) || HAS_TRAIT(src, TRAIT_IPC_CAN_EAT))
/mob/living/carbon/human/selfFeed(obj/item/food/toEat, fullness)
if(!check_has_mouth())
to_chat(src, "Where do you intend to put \the [toEat]? You don't have a mouth!")
return FALSE
if(!ismachineperson(src) || (ismachineperson(src) && !HAS_TRAIT(src, TRAIT_IPC_CAN_EAT)))
to_chat(src, "<span class='notice'>Where do you intend to put [toEat]? You don't have a mouth!</span>")
return FALSE
return ..()
/mob/living/carbon/human/forceFed(obj/item/food/toEat, mob/user, fullness)
if(!check_has_mouth())
if(!((istype(toEat, /obj/item/reagent_containers/drinks) && (ismachineperson(src)))))
to_chat(user, "Where do you intend to put \the [toEat]? \The [src] doesn't have a mouth!")
return FALSE
if(!ismachineperson(src) || !HAS_TRAIT(src, TRAIT_IPC_CAN_EAT))
if(!((istype(toEat, /obj/item/reagent_containers/drinks) && (ismachineperson(src)))))
to_chat(user, "<span class='notice'>Where do you intend to put [toEat]? \The [src] doesn't have a mouth!</span>")
return FALSE
return ..()
/mob/living/carbon/human/selfDrink(obj/item/reagent_containers/drinks/toDrink)
if(!check_has_mouth())
if(!ismachineperson(src))
to_chat(src, "Where do you intend to put \the [src]? You don't have a mouth!")
to_chat(src, "<span class='notice'>Where do you intend to put \the [src]? You don't have a mouth!</span>")
return FALSE
else
to_chat(src, "<span class='notice'>You pour a bit of liquid from [toDrink] into your connection port.</span>")
+3 -1
View File
@@ -2,7 +2,9 @@
return TASTE_SENSITIVITY_NORMAL
/mob/living/carbon/human/get_taste_sensitivity()
if(dna.species)
if(HAS_TRAIT(src, TRAIT_IPC_CAN_EAT))
return TASTE_SENSITIVITY_NORMAL
else if(dna.species)
return dna.species.taste_sensitivity
else
return TASTE_SENSITIVITY_NORMAL
@@ -1478,6 +1478,17 @@
build_path = /obj/item/organ/internal/cyberimp/chest/ipc_joints/flayer_pacification
category = list("IPC Upgrades")
/datum/design/culinary_processing_implant
name = "Culinary Processing Implant"
desc = "This implant emulates the functions of a gastrointestinal system, allowing IPCs to eat and experience taste."
id = "ci-culinary_implant"
req_tech = list("materials" = 3, "powerstorage" = 4, "biotech" = 3)
build_type = MECHFAB
construction_time = 60
materials = list(MAT_METAL = 500, MAT_GLASS = 500, MAT_GOLD = 500)
build_path = /obj/item/organ/internal/cyberimp/chest/ipc_food
category = list("IPC Upgrades")
// Misc
/datum/design/mecha_tracking
name = "Exosuit Tracking Beacon"
@@ -1022,6 +1022,22 @@
REMOVE_TRAIT(M, TRAIT_MINDFLAYER_NULLIFIED, UNIQUE_TRAIT_SOURCE(src))
return ..()
/obj/item/organ/internal/cyberimp/chest/ipc_food
name = "Culinary Processing Implant"
desc = "This implant emulates the functions of a gastrointestinal system, allowing IPCs to eat and experience taste."
implant_color = "#d8780a"
origin_tech = "materials=2;powerstorage=2;biotech=2"
slot = "gastrointestinal"
requires_machine_person = TRUE
/obj/item/organ/internal/cyberimp/chest/ipc_food/insert(mob/living/carbon/M, special = FALSE)
..()
ADD_TRAIT(M, TRAIT_IPC_CAN_EAT, "ipc_food[UID()]")
/obj/item/organ/internal/cyberimp/chest/ipc_food/remove(mob/living/carbon/M, special = FALSE)
REMOVE_TRAIT(M, TRAIT_IPC_CAN_EAT, "ipc_food[UID()]")
return ..()
//BOX O' IMPLANTS
/obj/item/storage/box/cyber_implants