diff --git a/_maps/RandomRuins/SpaceRuins/mrow_thats_right.dmm b/_maps/RandomRuins/SpaceRuins/mrow_thats_right.dmm index 37dcd97bb41..e1f35d27fd2 100644 --- a/_maps/RandomRuins/SpaceRuins/mrow_thats_right.dmm +++ b/_maps/RandomRuins/SpaceRuins/mrow_thats_right.dmm @@ -410,7 +410,7 @@ /turf/open/floor/iron, /area/ruin/space/has_grav/powered/cat_man) "bs" = ( -/mob/living/simple_animal/hostile/cat_butcherer, +/mob/living/basic/cat_butcherer, /turf/open/floor/iron/white/side{ dir = 4 }, diff --git a/code/modules/mob/living/basic/space_fauna/cat_surgeon.dm b/code/modules/mob/living/basic/space_fauna/cat_surgeon.dm new file mode 100644 index 00000000000..ba5a627d62c --- /dev/null +++ b/code/modules/mob/living/basic/space_fauna/cat_surgeon.dm @@ -0,0 +1,78 @@ +/** + * ## Cat Surgeon + * + * A mean motherfucker who wants to steal them cat tails... be warned should you see it, as it doesn't really speak much either. + */ + +/mob/living/basic/cat_butcherer + name = "Cat Surgeon" + desc = "A man with the quest of chasing endless feline tail." + icon = 'icons/mob/simple/simple_human.dmi' + icon_state = "cat_butcher" + icon_living = "cat_butcher" + icon_dead = "syndicate_dead" + icon_gib = "syndicate_gib" + speed = 0.8 + maxHealth = 100 + health = 100 + melee_damage_lower = 15 + melee_damage_upper = 15 + attack_verb_continuous = "slashes at" + attack_verb_simple = "slash at" + attack_sound = 'sound/weapons/circsawhit.ogg' + combat_mode = TRUE + mob_biotypes = MOB_ORGANIC|MOB_HUMANOID + sentience_type = SENTIENCE_HUMANOID + habitable_atmos = list("min_oxy" = 5, "max_oxy" = 0, "min_plas" = 0, "max_plas" = 1, "min_co2" = 0, "max_co2" = 5, "min_n2" = 0, "max_n2" = 0) + unsuitable_atmos_damage = 7.5 + faction = list(FACTION_HOSTILE) + status_flags = CANPUSH + basic_mob_flags = DEL_ON_DEATH + + ai_controller = /datum/ai_controller/basic_controller/cat_butcherer + + /// The stuff we drop on death. + var/static/list/drop_on_death = list( + /obj/effect/mob_spawn/corpse/human/cat_butcher, + /obj/item/circular_saw, + ) + +/mob/living/basic/cat_butcherer/Initialize(mapload) + . = ..() + apply_dynamic_human_appearance(src, mob_spawn_path = /obj/effect/mob_spawn/corpse/human/cat_butcher, l_hand = /obj/item/circular_saw, bloody_slots = ITEM_SLOT_GLOVES|ITEM_SLOT_OCLOTHING) + AddElement(/datum/element/death_drops, drop_on_death) + RegisterSignal(src, COMSIG_HOSTILE_POST_ATTACKINGTARGET, PROC_REF(after_attack)) + +/mob/living/basic/cat_butcherer/proc/after_attack(mob/living/basic/attacker, atom/target) + SIGNAL_HANDLER + + if(!iscarbon(target) || !prob(35)) + return + + var/mob/living/carbon/human/attacked = target + var/obj/item/organ/external/tail/cat/tail = attacked.get_organ_by_type(/obj/item/organ/external/tail/cat) + if(QDELETED(tail)) + return + + visible_message( + span_warning("[src] severs [attacked]'s tail off in one swift swipe!"), + span_warning("You sever [attacked]'s tail off."), + ) + tail.Remove(attacked) + tail.forceMove(drop_location()) + tail.color = attacked.hair_color + +/datum/ai_controller/basic_controller/cat_butcherer + blackboard = list( + BB_TARGETTING_DATUM = new /datum/targetting_datum/basic, + ) + + ai_movement = /datum/ai_movement/basic_avoidance + idle_behavior = /datum/idle_behavior/idle_random_walk + + planning_subtrees = list( + /datum/ai_planning_subtree/target_retaliate, + /datum/ai_planning_subtree/simple_find_target, + /datum/ai_planning_subtree/attack_obstacle_in_path, + /datum/ai_planning_subtree/basic_melee_attack_subtree, + ) diff --git a/code/modules/mob/living/simple_animal/hostile/cat_butcher.dm b/code/modules/mob/living/simple_animal/hostile/cat_butcher.dm deleted file mode 100644 index e5fcc922d9a..00000000000 --- a/code/modules/mob/living/simple_animal/hostile/cat_butcher.dm +++ /dev/null @@ -1,47 +0,0 @@ -/mob/living/simple_animal/hostile/cat_butcherer - name = "Cat Surgeon" - desc = "A man with the quest of chasing endless feline tail." - icon = 'icons/mob/simple/simple_human.dmi' - icon_state = "cat_butcher" - icon_living = "cat_butcher" - icon_dead = "syndicate_dead" - icon_gib = "syndicate_gib" - speak_chance = 0 - turns_per_move = 5 - speed = 0 - stat_attack = HARD_CRIT - robust_searching = 1 - maxHealth = 100 - health = 100 - harm_intent_damage = 5 - melee_damage_lower = 15 - melee_damage_upper = 15 - attack_verb_continuous = "slashes at" - attack_verb_simple = "slash at" - attack_sound = 'sound/weapons/circsawhit.ogg' - combat_mode = TRUE - mob_biotypes = MOB_ORGANIC|MOB_HUMANOID - sentience_type = SENTIENCE_HUMANOID - loot = list(/obj/effect/mob_spawn/corpse/human/cat_butcher, /obj/item/circular_saw) - atmos_requirements = list("min_oxy" = 5, "max_oxy" = 0, "min_plas" = 0, "max_plas" = 1, "min_co2" = 0, "max_co2" = 5, "min_n2" = 0, "max_n2" = 0) - unsuitable_atmos_damage = 7.5 - faction = list(FACTION_HOSTILE) - check_friendly_fire = 1 - status_flags = CANPUSH - del_on_death = TRUE - -/mob/living/simple_animal/hostile/cat_butcherer/Initialize(mapload) - . = ..() - apply_dynamic_human_appearance(src, mob_spawn_path = /obj/effect/mob_spawn/corpse/human/cat_butcher, l_hand = /obj/item/circular_saw, bloody_slots = ITEM_SLOT_GLOVES|ITEM_SLOT_OCLOTHING) - -/mob/living/simple_animal/hostile/cat_butcherer/AttackingTarget() - . = ..() - if(. && prob(35) && iscarbon(target)) - var/mob/living/carbon/human/L = target - var/obj/item/organ/external/tail/cat/tail = L.get_organ_by_type(/obj/item/organ/external/tail/cat) - if(!QDELETED(tail)) - visible_message(span_notice("[src] severs [L]'s tail in one swift swipe!"), span_notice("You sever [L]'s tail in one swift swipe.")) - tail.Remove(L) - var/obj/item/organ/external/tail/cat/dropped_tail = new(target.drop_location()) - dropped_tail.color = L.hair_color - return 1 diff --git a/code/modules/unit_tests/simple_animal_freeze.dm b/code/modules/unit_tests/simple_animal_freeze.dm index da24f035e4b..7d7df334e43 100644 --- a/code/modules/unit_tests/simple_animal_freeze.dm +++ b/code/modules/unit_tests/simple_animal_freeze.dm @@ -124,7 +124,6 @@ /mob/living/simple_animal/hostile/boss, /mob/living/simple_animal/hostile/boss/paper_wizard, /mob/living/simple_animal/hostile/boss/paper_wizard/copy, - /mob/living/simple_animal/hostile/cat_butcherer, /mob/living/simple_animal/hostile/construct, /mob/living/simple_animal/hostile/construct/artificer, /mob/living/simple_animal/hostile/construct/artificer/angelic, diff --git a/tgstation.dme b/tgstation.dme index c6b892e4177..c1b8b593067 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -4028,6 +4028,7 @@ #include "code\modules\mob\living\basic\pets\dog.dm" #include "code\modules\mob\living\basic\pets\pet.dm" #include "code\modules\mob\living\basic\ruin_defender\stickman.dm" +#include "code\modules\mob\living\basic\space_fauna\cat_surgeon.dm" #include "code\modules\mob\living\basic\space_fauna\faithless.dm" #include "code\modules\mob\living\basic\space_fauna\garden_gnome.dm" #include "code\modules\mob\living\basic\space_fauna\ghost.dm" @@ -4273,7 +4274,6 @@ #include "code\modules\mob\living\simple_animal\hostile\blob.dm" #include "code\modules\mob\living\simple_animal\hostile\blobbernaut.dm" #include "code\modules\mob\living\simple_animal\hostile\blobspore.dm" -#include "code\modules\mob\living\simple_animal\hostile\cat_butcher.dm" #include "code\modules\mob\living\simple_animal\hostile\dark_wizard.dm" #include "code\modules\mob\living\simple_animal\hostile\eyeballs.dm" #include "code\modules\mob\living\simple_animal\hostile\headcrab.dm" diff --git a/tools/UpdatePaths/Scripts/75599_simple_to_basic_cat_surgeon.txt b/tools/UpdatePaths/Scripts/75599_simple_to_basic_cat_surgeon.txt new file mode 100644 index 00000000000..8bd8aceeebe --- /dev/null +++ b/tools/UpdatePaths/Scripts/75599_simple_to_basic_cat_surgeon.txt @@ -0,0 +1 @@ +/mob/living/simple_animal/hostile/cat_butcherer : /mob/living/basic/cat_butcherer{@OLD}