Skip to content

Commit

Permalink
widow moment
Browse files Browse the repository at this point in the history
  • Loading branch information
Helg2 committed Aug 22, 2024
1 parent 9a12339 commit 5f2789c
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 44 deletions.
3 changes: 0 additions & 3 deletions code/__DEFINES/dcs/signals.dm
Original file line number Diff line number Diff line change
Expand Up @@ -646,9 +646,6 @@
///from /mob/living/proc/attack_alien_harm(mob/living/carbon/xenomorph/X, dam_bonus, set_location, random_location, no_head, no_crit, force_intent)
#define COMSIG_XENOMORPH_ATTACK_LIVING "xenomorph_attack_living"
#define COMSIG_XENOMORPH_BONUS_APPLIED (1<<0)
///from /mob/living/carbon/xenomorph/attack_alien(mob/living/carbon/xenomorph/xeno_attacker, damage_amount, damage_type, damage_flag, effects, armor_penetration, isrightclick)
///only on INTENT_HARM, INTENT_DISARM, IF it does damaage
#define COMSIG_XENOMORPH_ATTACK_HOSTILE_XENOMORPH "xenomorph_attack_xenomorph"

///after attacking, accounts for armor
#define COMSIG_XENOMORPH_POSTATTACK_LIVING "xenomorph_postattack_living"
Expand Down
7 changes: 3 additions & 4 deletions code/modules/mob/living/carbon/xenomorph/attack_alien.dm
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,12 @@
/mob/living/proc/attack_alien_grab(mob/living/carbon/xenomorph/X)
if(X == src || anchored || buckled || X.buckled)
return FALSE

if(!Adjacent(X))
return FALSE

X.start_pulling(src)
if(!X.start_pulling(src))
return FALSE
playsound(loc, 'sound/weapons/thudswoosh.ogg', 25, 1, 7)
return TRUE

/mob/living/carbon/human/attack_alien_grab(mob/living/carbon/xenomorph/X)
Expand Down Expand Up @@ -210,8 +211,6 @@
if (xeno_attacker.fortify || xeno_attacker.behemoth_charging)
return FALSE

SEND_SIGNAL(xeno_attacker, COMSIG_XENOMORPH_ATTACK_LIVING, src, damage_amount, xeno_attacker.xeno_caste.melee_damage * xeno_attacker.xeno_melee_damage_modifier)

switch(xeno_attacker.a_intent)
if(INTENT_HELP)
if(on_fire)
Expand Down
41 changes: 4 additions & 37 deletions code/modules/mob/living/carbon/xenomorph/xenoattacks.dm
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,6 @@

if(src == xeno_attacker)
return TRUE
if(isxenolarva(xeno_attacker)) //Larvas can't eat people
xeno_attacker.visible_message(span_danger("[xeno_attacker] nudges its head against \the [src]."), \
span_danger("We nudge our head against \the [src]."))
return FALSE

switch(xeno_attacker.a_intent)
if(INTENT_HELP)
Expand All @@ -92,6 +88,7 @@
return TRUE
xeno_attacker.visible_message(span_notice("\The [xeno_attacker] caresses \the [src] with its scythe-like arm."), \
span_notice("We caress \the [src] with our scythe-like arm."), null, 5)
return TRUE

if(INTENT_DISARM)
xeno_attacker.do_attack_animation(src, ATTACK_EFFECT_DISARM)
Expand All @@ -111,36 +108,6 @@
return TRUE

if(INTENT_GRAB)
if(anchored)
return FALSE
if(!xeno_attacker.start_pulling(src))
return FALSE
xeno_attacker.visible_message(span_warning("[xeno_attacker] grabs \the [src]!"), \
span_warning("We grab \the [src]!"), null, 5)
playsound(loc, 'sound/weapons/thudswoosh.ogg', 25, 1, 7)

if(INTENT_HARM)//Can't slash other xenos for now. SORRY // You can now! --spookydonut
if(issamexenohive(xeno_attacker) && !HAS_TRAIT(src, TRAIT_BANISHED))
xeno_attacker.do_attack_animation(src)
xeno_attacker.visible_message(span_warning("\The [xeno_attacker] nibbles \the [src]."), \
span_warning("We nibble \the [src]."), null, 5)
return TRUE
// copypasted from attack_alien.dm
//From this point, we are certain a full attack will go out. Calculate damage and modifiers
var/damage = xeno_attacker.xeno_caste.melee_damage

//Somehow we will deal no damage on this attack
if(!damage)
xeno_attacker.do_attack_animation(src)
playsound(xeno_attacker.loc, 'sound/weapons/alien_claw_swipe.ogg', 25, 1)
xeno_attacker.visible_message(span_danger("\The [xeno_attacker] lunges at [src]!"), \
span_danger("We lunge at [src]!"), null, 5)
return FALSE

xeno_attacker.visible_message(span_danger("\The [xeno_attacker] slashes [src]!"), \
span_danger("We slash [src]!"), null, 5)
log_combat(xeno_attacker, src, "slashed")

xeno_attacker.do_attack_animation(src, ATTACK_EFFECT_REDSLASH)
playsound(loc, "alien_claw_flesh", 25, 1)
apply_damage(damage, BRUTE, blocked = MELEE, updating_health = TRUE)
return attack_alien_grab(xeno_attacker)
if(INTENT_HARM)
return attack_alien_harm(xeno_attacker)

0 comments on commit 5f2789c

Please sign in to comment.