Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lesser drone nerfs #6140

Merged
merged 13 commits into from
Apr 20, 2024
29 changes: 19 additions & 10 deletions code/modules/mob/living/carbon/xenomorph/Facehuggers.dm
Drulikar marked this conversation as resolved.
Show resolved Hide resolved
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,9 @@
return
addtimer(CALLBACK(src, PROC_REF(check_turf)), 0.2 SECONDS)
if(stat == CONSCIOUS && loc) //Make sure we're conscious and not idle or dead.
go_idle()
var/jumps_before = jumps_left
go_idle(FALSE)
jumps_left = jumps_before
Drulikar marked this conversation as resolved.
Show resolved Hide resolved
if(attached)
attached = FALSE
die()
Expand Down Expand Up @@ -173,10 +175,15 @@
if(exposed_temperature > 300)
die()

/obj/item/clothing/mask/facehugger/equipped(mob/M)
/obj/item/clothing/mask/facehugger/equipped(mob/holder)
SHOULD_CALL_PARENT(FALSE) // ugh equip sounds
// So picking up a hugger does not prematurely kill it
go_idle()
if (!isxeno(holder))
return

var/mob/living/carbon/xenomorph/xeno = holder

if (xeno.caste.hugger_nurturing || hivenumber == XENO_HIVE_TUTORIAL)
go_idle()

/obj/item/clothing/mask/facehugger/Crossed(atom/target)
has_proximity(target)
Expand Down Expand Up @@ -343,30 +350,32 @@
stat = CONSCIOUS
jump_timer = addtimer(CALLBACK(src, PROC_REF(try_jump)), time_between_jumps, TIMER_OVERRIDE|TIMER_STOPPABLE|TIMER_UNIQUE)

/obj/item/clothing/mask/facehugger/proc/go_idle() //Idle state does not count toward the death timer.
/obj/item/clothing/mask/facehugger/proc/go_idle(delete_timer = TRUE) //Idle state does not count toward the death timer.
if(stat == DEAD || stat == UNCONSCIOUS)
return

stat = UNCONSCIOUS
icon_state = "[initial(icon_state)]_inactive"
if(jump_timer)
deltimer(jump_timer)
jump_timer = null
if(delete_timer)
if(jump_timer)
deltimer(jump_timer)
jump_timer = null
Drulikar marked this conversation as resolved.
Show resolved Hide resolved
// Reset the jumps left to their original count
jumps_left = initial(jumps_left)
addtimer(CALLBACK(src, PROC_REF(go_active)), rand(MIN_ACTIVE_TIME,MAX_ACTIVE_TIME))

/obj/item/clothing/mask/facehugger/proc/try_jump()
jump_timer = addtimer(CALLBACK(src, PROC_REF(try_jump)), time_between_jumps, TIMER_OVERRIDE|TIMER_STOPPABLE|TIMER_UNIQUE)
if(stat != CONSCIOUS || isnull(loc)) //Make sure we're conscious and not idle or dead.
if(isnull(loc)) //Make sure we're conscious and not idle or dead.
return

if(isxeno(loc))
var/mob/living/carbon/xenomorph/X = loc
if(X.caste.hugger_nurturing) // caste can prevent hugger death
return

leap_at_nearest_target()
if(stat == CONSCIOUS)
leap_at_nearest_target()
jumps_left--
if(!jumps_left)
end_lifecycle()
Expand Down
10 changes: 9 additions & 1 deletion code/modules/mob/living/carbon/xenomorph/castes/lesser_drone.dm
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,10 @@
can_be_revived = FALSE

build_time_mult = BUILD_TIME_MULT_LESSER_DRONE
behavior_delegate_type = /datum/behavior_delegate/lesser_drone_base

caste_desc = "A builder of hives."
can_hold_facehuggers = 1
can_hold_facehuggers = TRUE
can_hold_eggs = CAN_HOLD_TWO_HANDS
acid_level = 1
weed_level = WEED_LEVEL_STANDARD
Expand Down Expand Up @@ -118,3 +119,10 @@

/mob/living/carbon/xenomorph/lesser_drone/handle_ghost_message()
return

/datum/behavior_delegate/lesser_drone_base
name = "Base Lesser Drone Behavior Delegate"

/datum/behavior_delegate/lesser_drone_base/on_life()
if(bound_xeno.body_position == STANDING_UP && !(locate(/obj/effect/alien/weeds) in get_turf(bound_xeno)))
bound_xeno.adjustBruteLoss(5)
Loading