From 3c63657795cf27879fe45d2155330c4678bf0d08 Mon Sep 17 00:00:00 2001 From: VerySoft Date: Fri, 11 Mar 2022 00:13:44 -0500 Subject: [PATCH] Fix Spacewhale Movement Now it should actually do what it's supposed to do. --- .../animal/alien animals/spacewhale.dm | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/spacewhale.dm b/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/spacewhale.dm index 4cc14a1caa..0b27faa6c8 100644 --- a/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/spacewhale.dm +++ b/code/modules/mob/living/simple_mob/subtypes/animal/alien animals/spacewhale.dm @@ -137,7 +137,7 @@ if(post_restless_tired) post_restless_tired-- return - if(!restless && prob(0.5)) + if(prob(0.5)) handle_restless() /mob/living/simple_mob/vore/overmap/spacewhale/proc/handle_restless() @@ -149,9 +149,7 @@ ai_holder.base_wander_delay = initial(ai_holder.base_wander_delay) ai_holder.wander = FALSE post_restless_tired = 250 - if(child_om_marker.known == TRUE) - child_om_marker.icon_state = "space_whale" - visible_message("\The [child_om_marker.name] settles down.") + update_icon() else restless = TRUE hazard_pickup_chance *= 1.5 @@ -159,9 +157,18 @@ movement_cooldown = 1 ai_holder.base_wander_delay = 2 ai_holder.wander_delay = 2 - if(child_om_marker.known == TRUE) + ai_holder.wander = TRUE + update_icon() + +/mob/living/simple_mob/vore/overmap/spacewhale/update_icon() + . = ..() + if(child_om_marker.known == TRUE) + if(restless) child_om_marker.icon_state = "space_whale_restless" visible_message("\The [child_om_marker.name] ripples excitedly.") + else + child_om_marker.icon_state = "space_whale" + visible_message("\The [child_om_marker.name] settles down.") /datum/ai_holder/simple_mob/melee/spacewhale hostile = TRUE @@ -182,8 +189,6 @@ if(stance == STANCE_IDLE) W.hazard_pickup_chance = initial(W.hazard_pickup_chance) W.hazard_drop_chance = initial(W.hazard_drop_chance) - W.movement_cooldown = 50 - base_wander_delay = 50 W.restless = FALSE W.handle_restless() W.movement_cooldown = initial(W.movement_cooldown)