diff --git a/_maps/map_files/stations/boxstation.dmm b/_maps/map_files/stations/boxstation.dmm index 030174304fe..883e66783df 100644 --- a/_maps/map_files/stations/boxstation.dmm +++ b/_maps/map_files/stations/boxstation.dmm @@ -27880,7 +27880,7 @@ /obj/machinery/atmospherics/pipe/simple/hidden/supply{ dir = 4 }, -/mob/living/simple_animal/hostile/gorilla/cargo_domestic{ +/mob/living/basic/gorilla/cargo_domestic{ name = "Forklift" }, /turf/simulated/floor/plasteel, diff --git a/_maps/map_files/stations/cerestation.dmm b/_maps/map_files/stations/cerestation.dmm index 87b49023003..b3cbfe481fb 100644 --- a/_maps/map_files/stations/cerestation.dmm +++ b/_maps/map_files/stations/cerestation.dmm @@ -56733,7 +56733,7 @@ }, /area/station/maintenance/asmaint) "kzP" = ( -/mob/living/simple_animal/hostile/gorilla/cargo_domestic, +/mob/living/basic/gorilla/cargo_domestic, /turf/simulated/floor/plasteel{ dir = 1; icon_state = "darkfull" diff --git a/_maps/map_files/stations/deltastation.dmm b/_maps/map_files/stations/deltastation.dmm index 9f547680fea..7e05fd3948a 100644 --- a/_maps/map_files/stations/deltastation.dmm +++ b/_maps/map_files/stations/deltastation.dmm @@ -12114,7 +12114,7 @@ /area/station/supply/office) "aWu" = ( /obj/effect/turf_decal/stripes/line, -/mob/living/simple_animal/hostile/gorilla/cargo_domestic{ +/mob/living/basic/gorilla/cargo_domestic{ name = "Forklift" }, /turf/simulated/floor/plasteel, diff --git a/_maps/map_files/stations/emeraldstation.dmm b/_maps/map_files/stations/emeraldstation.dmm index edf47a70fb6..22235e07dfa 100644 --- a/_maps/map_files/stations/emeraldstation.dmm +++ b/_maps/map_files/stations/emeraldstation.dmm @@ -121790,7 +121790,7 @@ }, /area/station/supply/storage) "ylD" = ( -/mob/living/simple_animal/hostile/gorilla/cargo_domestic{ +/mob/living/basic/gorilla/cargo_domestic{ name = "Forklift" }, /obj/structure/cable{ diff --git a/code/__DEFINES/mob_defines.dm b/code/__DEFINES/mob_defines.dm index 18f6d8acef8..bca02adda14 100644 --- a/code/__DEFINES/mob_defines.dm +++ b/code/__DEFINES/mob_defines.dm @@ -259,7 +259,7 @@ #define isslaughterdemon(A) (istype((A), /mob/living/simple_animal/demon/slaughter)) #define isdemon(A) (istype((A), /mob/living/simple_animal/demon)) #define iscat(A) (istype((A), /mob/living/simple_animal/pet/cat)) -#define isgorilla(A) (istype((A), /mob/living/simple_animal/hostile/gorilla)) +#define isgorilla(A) (istype((A), /mob/living/basic/gorilla)) #define ismorph(A) (istype((A), /mob/living/simple_animal/hostile/morph)) #define issilicon(A) (istype((A), /mob/living/silicon)) diff --git a/code/datums/keybindings/emote_keybinds.dm b/code/datums/keybindings/emote_keybinds.dm index 2baf1e31eb3..8f2ebf8f099 100644 --- a/code/datums/keybindings/emote_keybinds.dm +++ b/code/datums/keybindings/emote_keybinds.dm @@ -636,7 +636,7 @@ return isnymph(M) && ..() /datum/keybinding/emote/simple_animal/gorilla_ooga - linked_emote = /datum/emote/living/simple_animal/gorilla/ooga + linked_emote = /datum/emote/living/basic_mob/gorilla/ooga name = "Ooga (Gorilla)" /datum/keybinding/emote/simple_animal/gorilla_ooga/can_use(client/C, mob/M) diff --git a/code/game/objects/structures/crates_lockers/crittercrate.dm b/code/game/objects/structures/crates_lockers/crittercrate.dm index dc8b05f4116..6b4511a0b0d 100644 --- a/code/game/objects/structures/crates_lockers/crittercrate.dm +++ b/code/game/objects/structures/crates_lockers/crittercrate.dm @@ -124,8 +124,8 @@ /obj/structure/closet/critter/gorilla name = "gorilla crate" - content_mob = /mob/living/simple_animal/hostile/gorilla + content_mob = /mob/living/basic/gorilla /obj/structure/closet/critter/gorilla/cargo name = "cargorilla crate" - content_mob = /mob/living/simple_animal/hostile/gorilla/cargo_domestic + content_mob = /mob/living/basic/gorilla/cargo_domestic diff --git a/code/modules/mob/living/simple_animal/hostile/gorilla/gorilla.dm b/code/modules/mob/living/basic/hostile/gorilla/gorilla.dm similarity index 73% rename from code/modules/mob/living/simple_animal/hostile/gorilla/gorilla.dm rename to code/modules/mob/living/basic/hostile/gorilla/gorilla.dm index 9a514ce668b..88c86d2150b 100644 --- a/code/modules/mob/living/simple_animal/hostile/gorilla/gorilla.dm +++ b/code/modules/mob/living/basic/hostile/gorilla/gorilla.dm @@ -1,4 +1,4 @@ -/mob/living/simple_animal/hostile/gorilla +/mob/living/basic/gorilla name = "gorilla" desc = "A ground-dwelling, predominantly herbivorous ape that inhabits the forests of central Africa on Earth." icon = 'icons/mob/gorilla.dmi' @@ -6,27 +6,28 @@ icon_living = "crawling" icon_dead = "dead" mob_biotypes = MOB_ORGANIC|MOB_HUMANOID - speak_chance = 80 maxHealth = 220 health = 220 butcher_results = list(/obj/item/food/meat/slab/gorilla = 4) - response_help = "prods" - response_disarm = "challenges" - response_harm = "thumps" - attacktext = "pummels" + response_help_continuous = "prods" + response_help_simple = "prod" + response_disarm_continuous = "challenges" + response_disarm_simple = "challenge" + attack_verb_continuous = "pummels" + attack_verb_simple = "pummel" speed = 0.5 melee_damage_lower = 15 melee_damage_upper = 18 + melee_attack_cooldown_min = 1.5 SECONDS + melee_attack_cooldown_max = 2.5 SECONDS damage_coeff = list(BRUTE = 1, BURN = 1.5, TOX = 1.5, CLONE = 0, STAMINA = 0, OXY = 1.5) obj_damage = 20 environment_smash = ENVIRONMENT_SMASH_WALLS | ENVIRONMENT_SMASH_STRUCTURES - attack_sound = 'sound/weapons/punch1.ogg' faction = list("hostile", "monkey", "jungle") - robust_searching = TRUE - minbodytemp = 270 - footstep_type = FOOTSTEP_MOB_BAREFOOT - stat_attack = UNCONSCIOUS // Sleeping won't save you + minimum_survivable_temperature = 270 + step_type = FOOTSTEP_MOB_BAREFOOT a_intent = INTENT_HARM // Angrilla + ai_controller = /datum/ai_controller/basic_controller/simple/simple_hostile_obstacles/gorilla /// Is the gorilla stood up or not? var/is_bipedal = FALSE /// The max number of crates we can carry @@ -42,14 +43,14 @@ /// Chance of doing the throw or stamina damage, along with the flat damage amount var/throw_onhit = 50 -/mob/living/simple_animal/hostile/gorilla/Initialize(mapload) +/mob/living/basic/gorilla/Initialize(mapload) . = ..() var/datum/action/innate/gorilla_toggle/toggle = new toggle.Grant(src) var/static/default_cache = typecacheof(list(/obj/structure/closet/crate)) // Normal crates only please, no weird sized ones carriable_cache = default_cache -/mob/living/simple_animal/hostile/gorilla/Destroy() +/mob/living/basic/gorilla/Destroy() LAZYCLEARLIST(crates_in_hand) return ..() @@ -62,11 +63,11 @@ /datum/action/innate/gorilla_toggle/Activate() . = ..() - var/mob/living/simple_animal/hostile/gorilla/gorilla = owner + var/mob/living/basic/gorilla/gorilla = owner if(!istype(gorilla)) return - var/mob/living/simple_animal/hostile/gorilla/cargo_domestic/domesticated = gorilla + var/mob/living/basic/gorilla/cargo_domestic/domesticated = gorilla if(istype(domesticated) && LAZYLEN(domesticated.crates_in_hand)) to_chat(domesticated, "You can't get on all fours while carrying something!") return @@ -80,7 +81,7 @@ // Gorillas like to dismember limbs from unconscious mobs. /// Returns null when the target is not an unconscious carbon mob; a list of limbs (possibly empty) otherwise. -/mob/living/simple_animal/hostile/gorilla/proc/get_target_bodyparts(atom/hit_target) +/mob/living/basic/gorilla/proc/get_target_bodyparts(atom/hit_target) if(!ishuman(hit_target)) return @@ -97,10 +98,10 @@ parts += part return parts -/mob/living/simple_animal/hostile/gorilla/AttackingTarget(atom/attacked_target) +/mob/living/basic/gorilla/melee_attack(atom/attacked_target) if(client) - if(is_type_in_typecache(target, carriable_cache)) - var/atom/movable/movable_target = target + if(is_type_in_typecache(attacked_target, carriable_cache)) + var/atom/movable/movable_target = attacked_target if(LAZYLEN(crates_in_hand) >= crate_limit) to_chat(src, "You are carrying too many crates!") return COMPONENT_CANCEL_ATTACK_CHAIN @@ -111,15 +112,15 @@ to_chat(src, "This crate is too heavy!") return COMPONENT_CANCEL_ATTACK_CHAIN - LAZYADD(crates_in_hand, target) + LAZYADD(crates_in_hand, attacked_target) is_bipedal = TRUE update_icon(UPDATE_OVERLAYS | UPDATE_ICON_STATE) movable_target.forceMove(src) return COMPONENT_CANCEL_ATTACK_CHAIN - var/turf/target_turf = target + var/turf/target_turf = attacked_target if(istype(target_turf) && !target_turf.is_blocked_turf() && LAZYLEN(crates_in_hand)) - drop_random_crate(target) + drop_random_crate(attacked_target) return COMPONENT_CANCEL_ATTACK_CHAIN . = ..() @@ -129,14 +130,14 @@ if(client) oogaooga() - var/list/parts = get_target_bodyparts(target) + var/list/parts = get_target_bodyparts(attacked_target) if(length(parts) && prob(dismember_chance)) var/obj/item/organ/external/to_dismember = pick(parts) to_dismember.droplimb() return - if(isliving(target)) - var/mob/living/living_target = target + if(isliving(attacked_target)) + var/mob/living/living_target = attacked_target if(prob(throw_onhit)) living_target.throw_at(get_edge_target_turf(living_target, dir), rand(1, 2), 7, src) return @@ -144,7 +145,7 @@ living_target.apply_damage(stamina_damage, STAMINA) visible_message("[src] knocks [living_target] down!") -/mob/living/simple_animal/hostile/gorilla/update_icon_state() +/mob/living/basic/gorilla/update_icon_state() . = ..() if(is_dead()) icon_state = icon_dead @@ -155,7 +156,7 @@ icon_state = initial(icon_state) -/mob/living/simple_animal/hostile/gorilla/update_overlays() +/mob/living/basic/gorilla/update_overlays() . = ..() if(!LAZYLEN(crates_in_hand)) return @@ -163,31 +164,19 @@ . += mutable_appearance(random_crate.icon, random_crate.icon_state) . += mutable_appearance(icon, "standing_overlay") -/mob/living/simple_animal/hostile/gorilla/CanAttack(atom/the_target) - var/list/parts = get_target_bodyparts(target) - return ..() && !ismonkeybasic(the_target) && (!parts || length(parts) > 3) - -/mob/living/simple_animal/hostile/gorilla/CanSmashTurfs(turf/T) - return iswallturf(T) - -/mob/living/simple_animal/hostile/gorilla/handle_automated_speech(override) - if(speak_chance && (override || prob(speak_chance))) - playsound(src, 'sound/creatures/gorilla.ogg', 50) - return ..() - -/mob/living/simple_animal/hostile/gorilla/proc/oogaooga() +/mob/living/basic/gorilla/proc/oogaooga() if(prob(rand(15, 50))) playsound(src, 'sound/creatures/gorilla.ogg', 50) -/mob/living/simple_animal/hostile/gorilla/special_get_hands_check() +/mob/living/basic/gorilla/special_get_hands_check() if(LAZYLEN(crates_in_hand)) return pick(crates_in_hand) -/mob/living/simple_animal/hostile/gorilla/death(gibbed) +/mob/living/basic/gorilla/death(gibbed) drop_all_crates(drop_location()) return ..() -/mob/living/simple_animal/hostile/gorilla/examine(mob/user) +/mob/living/basic/gorilla/examine(mob/user) . = ..() var/num_crates = LAZYLEN(crates_in_hand) if(num_crates) @@ -196,51 +185,50 @@ . += "[crate]." . += "" -/mob/living/simple_animal/hostile/gorilla/drop_item_v() +/mob/living/basic/gorilla/drop_item_v() drop_random_crate(drop_location()) /// Drops one random crates from our crate list. -/mob/living/simple_animal/hostile/gorilla/proc/drop_random_crate(atom/drop_to) +/mob/living/basic/gorilla/proc/drop_random_crate(atom/drop_to) var/obj/structure/closet/crate/held_crate = pick(crates_in_hand) held_crate.forceMove(drop_to) LAZYREMOVE(crates_in_hand, held_crate) update_icon(UPDATE_OVERLAYS | UPDATE_ICON_STATE) /// Drops all the crates in our crate list. -/mob/living/simple_animal/hostile/gorilla/proc/drop_all_crates(atom/drop_to) +/mob/living/basic/gorilla/proc/drop_all_crates(atom/drop_to) for(var/obj/structure/closet/crate/held_crate as anything in crates_in_hand) held_crate.forceMove(drop_to) LAZYREMOVE(crates_in_hand, held_crate) update_icon(UPDATE_OVERLAYS | UPDATE_ICON_STATE) -/mob/living/simple_animal/hostile/gorilla/cargo_domestic +/mob/living/basic/gorilla/cargo_domestic name = "cargorilla" // Overriden, normally icon = 'icons/mob/cargorillia.dmi' desc = "Cargo's pet gorilla. He seems to have an 'I love Mom' tattoo." faction = list("neutral", "monkey", "jungle") gender = MALE a_intent = INTENT_HELP - unique_pet = TRUE crate_limit = 2 /// The ID card that the gorilla is currently wearing. var/obj/item/card/id/access_card -/mob/living/simple_animal/hostile/gorilla/cargo_domestic/Login() +/mob/living/basic/gorilla/cargo_domestic/Login() . = ..() // Github copilot wrote the below fluff IDK to_chat(src, "You are [name]. You are a domesticated gorilla, and you are Cargo's pet. You are a loyal and hardworking gorilla, and you love your job. You are a good gorilla, and Cargo loves you.") to_chat(src, "You can pick up crates by clicking them, and drop them by clicking on an open floor. You can carry [crate_limit] crates at a time.") -/mob/living/simple_animal/hostile/gorilla/cargo_domestic/Initialize(mapload) +/mob/living/basic/gorilla/cargo_domestic/Initialize(mapload) . = ..() access_card = new /obj/item/card/id/supply/cargo_gorilla(src) ADD_TRAIT(src, TRAIT_PACIFISM, INNATE_TRAIT) -/mob/living/simple_animal/hostile/gorilla/cargo_domestic/Destroy() +/mob/living/basic/gorilla/cargo_domestic/Destroy() QDEL_NULL(access_card) return ..() -/mob/living/simple_animal/hostile/gorilla/cargo_domestic/get_access() +/mob/living/basic/gorilla/cargo_domestic/get_access() . = ..() . |= access_card.GetAccess() @@ -249,7 +237,7 @@ registered_name = "Cargorilla" desc = "A card used to provide ID and determine access across the station. A gorilla-sized ID for a gorilla-sized cargo technician." -/mob/living/simple_animal/hostile/gorilla/rampaging +/mob/living/basic/gorilla/rampaging name = "Rampaging Gorilla" desc = "A gorilla that has gone wild. Run!" speed = 0 @@ -264,7 +252,23 @@ stamina_damage = 40 throw_onhit = 80 -/mob/living/simple_animal/hostile/gorilla/rampaging/Initialize(mapload) +/mob/living/basic/gorilla/rampaging/Initialize(mapload) . = ..() add_overlay(mutable_appearance('icons/effects/effects.dmi', "electricity")) // I wanna be Winston +/datum/ai_controller/basic_controller/simple/simple_hostile_obstacles/gorilla + blackboard = list( + BB_TARGETING_STRATEGY = /datum/targeting_strategy/basic, + BB_TARGET_MINIMUM_STAT = UNCONSCIOUS + ) + + planning_subtrees = list( + /datum/ai_planning_subtree/simple_find_target, + /datum/ai_planning_subtree/attack_obstacle_in_path, + /datum/ai_planning_subtree/basic_melee_attack_subtree, + /datum/ai_planning_subtree/random_speech/gorilla, + ) + +/datum/ai_planning_subtree/random_speech/gorilla + speech_chance = 6 + sound = list('sound/creatures/gorilla.ogg') diff --git a/code/modules/mob/living/basic/hostile/gorilla/gorilla_emote.dm b/code/modules/mob/living/basic/hostile/gorilla/gorilla_emote.dm new file mode 100644 index 00000000000..9b4e2a7e354 --- /dev/null +++ b/code/modules/mob/living/basic/hostile/gorilla/gorilla_emote.dm @@ -0,0 +1,10 @@ +/datum/emote/living/basic_mob/gorilla + mob_type_allowed_typecache = list(/mob/living/basic/gorilla) + +/datum/emote/living/basic_mob/gorilla/ooga + key = "ooga" + key_third_person = "oogas" + message = "oogas." + message_param = "oogas at %t." + emote_type = EMOTE_AUDIBLE + sound = 'sound/creatures/gorilla.ogg' diff --git a/code/modules/mob/living/simple_animal/hostile/gorilla/gorilla_emote.dm b/code/modules/mob/living/simple_animal/hostile/gorilla/gorilla_emote.dm deleted file mode 100644 index 41602ab402a..00000000000 --- a/code/modules/mob/living/simple_animal/hostile/gorilla/gorilla_emote.dm +++ /dev/null @@ -1,10 +0,0 @@ -/datum/emote/living/simple_animal/gorilla - mob_type_allowed_typecache = list(/mob/living/simple_animal/hostile/gorilla) - -/datum/emote/living/simple_animal/gorilla/ooga - key = "ooga" - key_third_person = "oogas" - message = "oogas." - message_param = "oogas at %t." - emote_type = EMOTE_AUDIBLE - sound = 'sound/creatures/gorilla.ogg' diff --git a/code/modules/mob/transform_procs.dm b/code/modules/mob/transform_procs.dm index 70111688695..be7f4f36e7e 100644 --- a/code/modules/mob/transform_procs.dm +++ b/code/modules/mob/transform_procs.dm @@ -287,9 +287,9 @@ icon = null invisibility = INVISIBILITY_MAXIMUM visible_message("[src] transforms into a gorilla!", "You transform into a gorilla! Ooga ooga!", "You hear a loud roar!") - var/mob/living/simple_animal/hostile/gorilla/new_gorilla + var/mob/living/basic/gorilla/new_gorilla if(rage) - var/mob/living/simple_animal/hostile/gorilla/rampaging/rampaging_gorilla = new (get_turf(src)) + var/mob/living/basic/gorilla/rampaging/rampaging_gorilla = new (get_turf(src)) new_gorilla = rampaging_gorilla else new_gorilla = new (get_turf(src)) diff --git a/code/modules/projectiles/projectile/magic_projectiles.dm b/code/modules/projectiles/projectile/magic_projectiles.dm index 67761587981..7ae12cbfb81 100644 --- a/code/modules/projectiles/projectile/magic_projectiles.dm +++ b/code/modules/projectiles/projectile/magic_projectiles.dm @@ -199,7 +199,7 @@ GLOBAL_LIST_INIT(wabbajack_hostile_animals, list( "bat" = /mob/living/basic/scarybat, "goat" = /mob/living/simple_animal/hostile/retaliate/goat, "tomato" = /mob/living/simple_animal/hostile/killertomato, - "gorilla" = /mob/living/simple_animal/hostile/gorilla, + "gorilla" = /mob/living/basic/gorilla, "kangaroo" = /mob/living/simple_animal/hostile/retaliate/kangaroo, )) diff --git a/paradise.dme b/paradise.dme index a9a718633fa..7e8ded4f603 100644 --- a/paradise.dme +++ b/paradise.dme @@ -2413,6 +2413,8 @@ #include "code\modules\mob\living\basic\hostile\bear.dm" #include "code\modules\mob\living\basic\hostile\carp.dm" #include "code\modules\mob\living\basic\hostile\skeleton_mob.dm" +#include "code\modules\mob\living\basic\hostile\gorilla\gorilla.dm" +#include "code\modules\mob\living\basic\hostile\gorilla\gorilla_emote.dm" #include "code\modules\mob\living\basic\nether_mobs\blankbody.dm" #include "code\modules\mob\living\basic\nether_mobs\faithless.dm" #include "code\modules\mob\living\basic\nether_mobs\migo.dm" @@ -2643,8 +2645,6 @@ #include "code\modules\mob\living\simple_animal\hostile\tree.dm" #include "code\modules\mob\living\simple_animal\hostile\venus_human_trap.dm" #include "code\modules\mob\living\simple_animal\hostile\winter_mobs.dm" -#include "code\modules\mob\living\simple_animal\hostile\gorilla\gorilla.dm" -#include "code\modules\mob\living\simple_animal\hostile\gorilla\gorilla_emote.dm" #include "code\modules\mob\living\simple_animal\hostile\megafauna\ancient_robot.dm" #include "code\modules\mob\living\simple_animal\hostile\megafauna\blood_drunk_miner.dm" #include "code\modules\mob\living\simple_animal\hostile\megafauna\bubblegum.dm" diff --git a/tools/UpdatePaths/Scripts/29783_gorilla.txt b/tools/UpdatePaths/Scripts/29783_gorilla.txt new file mode 100644 index 00000000000..e1d690b0499 --- /dev/null +++ b/tools/UpdatePaths/Scripts/29783_gorilla.txt @@ -0,0 +1 @@ +/mob/living/simple_animal/hostile/gorilla/@SUBTYPES : /mob/living/basic/gorilla/@SUBTYPES{@OLD}