From 071ecc371f9b15d90135652ae039c816460060a2 Mon Sep 17 00:00:00 2001 From: warriorstar-orion Date: Thu, 3 Apr 2025 09:50:36 -0400 Subject: [PATCH] refactor: remove unused var /mob/var/LAssailant (#28825) --- code/game/objects/items.dm | 5 ----- code/game/objects/items/weapons/batons.dm | 1 - code/game/objects/items/weapons/storage/bible.dm | 4 ---- code/modules/antagonists/vampire/vamp_datum.dm | 4 ---- .../mob/living/carbon/human/species/_species.dm | 5 ----- code/modules/mob/living/living.dm | 6 ------ code/modules/mob/living/living_defense.dm | 1 - code/modules/mob/mob.dm | 1 - code/modules/mob/mob_grab.dm | 4 ---- code/modules/mob/mob_vars.dm | 3 --- code/modules/recycling/disposal.dm | 4 ---- .../research/xenobiology/xenobio_camera.dm | 15 ++++++--------- 12 files changed, 6 insertions(+), 47 deletions(-) diff --git a/code/game/objects/items.dm b/code/game/objects/items.dm index a875dce2b36..b4f1a84afe7 100644 --- a/code/game/objects/items.dm +++ b/code/game/objects/items.dm @@ -661,11 +661,6 @@ GLOBAL_DATUM_INIT(welding_sparks, /mutable_appearance, mutable_appearance('icons to_chat(user, "You cannot locate any eyes on this creature!") return - if(!iscarbon(user)) - M.LAssailant = null - else - M.LAssailant = user - src.add_fingerprint(user) playsound(loc, src.hitsound, 30, TRUE, -1) diff --git a/code/game/objects/items/weapons/batons.dm b/code/game/objects/items/weapons/batons.dm index 2e905ae2540..0885bdca91a 100644 --- a/code/game/objects/items/weapons/batons.dm +++ b/code/game/objects/items/weapons/batons.dm @@ -97,7 +97,6 @@ playsound(target, stun_sound, 75, TRUE, -1) add_attack_logs(user, target, "Knocked down with [src]") // Hit 'em - target.LAssailant = iscarbon(user) ? user : null target.KnockDown(knockdown_duration) on_cooldown = TRUE addtimer(VARSET_CALLBACK(src, on_cooldown, FALSE), cooldown) diff --git a/code/game/objects/items/weapons/storage/bible.dm b/code/game/objects/items/weapons/storage/bible.dm index 20b8f8870a7..06544e3961a 100644 --- a/code/game/objects/items/weapons/storage/bible.dm +++ b/code/game/objects/items/weapons/storage/bible.dm @@ -73,10 +73,6 @@ /obj/item/storage/bible/attack__legacy__attackchain(mob/living/M, mob/living/user) add_attack_logs(user, M, "Hit with [src]") - if(!iscarbon(user)) - M.LAssailant = null - else - M.LAssailant = user if(!(ishuman(user) || SSticker) && SSticker.mode.name != "monkey") to_chat(user, "You don't have the dexterity to do this!") diff --git a/code/modules/antagonists/vampire/vamp_datum.dm b/code/modules/antagonists/vampire/vamp_datum.dm index e734ca36437..1e62f6e8474 100644 --- a/code/modules/antagonists/vampire/vamp_datum.dm +++ b/code/modules/antagonists/vampire/vamp_datum.dm @@ -109,10 +109,6 @@ RESTRICT_TYPE(/datum/antagonist/vampire) return add_attack_logs(owner.current, H, "vampirebit & is draining their blood.", ATKLOG_ALMOSTALL) owner.current.visible_message("[owner.current] grabs [H]'s neck harshly and sinks in [owner.current.p_their()] fangs!", "You sink your fangs into [H] and begin to drain [H.p_their()] blood.", "You hear a soft puncture and a wet sucking noise.") - if(!iscarbon(owner.current)) - H.LAssailant = null - else - H.LAssailant = owner while(do_mob(owner.current, H, suck_rate, hidden = TRUE)) owner.current.do_attack_animation(H, ATTACK_EFFECT_BITE) if(unique_suck_id in drained_humans) diff --git a/code/modules/mob/living/carbon/human/species/_species.dm b/code/modules/mob/living/carbon/human/species/_species.dm index 494f5aef98d..a8187b7d4f7 100644 --- a/code/modules/mob/living/carbon/human/species/_species.dm +++ b/code/modules/mob/living/carbon/human/species/_species.dm @@ -562,11 +562,6 @@ return FALSE add_attack_logs(user, target, "Melee attacked with fists", target.ckey ? null : ATKLOG_ALL) - if(!iscarbon(user)) - target.LAssailant = null - else - target.LAssailant = user - target.lastattacker = user.real_name target.lastattackerckey = user.ckey diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index d5f17f68be3..31a3d23af02 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -1008,12 +1008,6 @@ AM.pulledby = src if(pullin) pullin.update_icon(UPDATE_ICON_STATE) - if(ismob(AM)) - var/mob/M = AM - if(!iscarbon(src)) - M.LAssailant = null - else - M.LAssailant = usr /mob/living/proc/check_pull() if(pulling && !pulling.Adjacent(src)) diff --git a/code/modules/mob/living/living_defense.dm b/code/modules/mob/living/living_defense.dm index 2ad44d96520..e12a1b36fb9 100644 --- a/code/modules/mob/living/living_defense.dm +++ b/code/modules/mob/living/living_defense.dm @@ -305,7 +305,6 @@ return 0 user.put_in_active_hand(G) G.synch() - LAssailant = user playsound(src.loc, 'sound/weapons/thudswoosh.ogg', 50, TRUE, -1) /*if(user.dir == src.dir) diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm index ebc9afff5ae..100ef35f84a 100644 --- a/code/modules/mob/mob.dm +++ b/code/modules/mob/mob.dm @@ -25,7 +25,6 @@ for(var/datum/alternate_appearance/AA in viewing_alternate_appearances) AA.viewers -= src viewing_alternate_appearances = null - LAssailant = null runechat_msg_location = null if(length(observers)) for(var/mob/dead/observe as anything in observers) diff --git a/code/modules/mob/mob_grab.dm b/code/modules/mob/mob_grab.dm index b831fce5fc6..a985bedd550 100644 --- a/code/modules/mob/mob_grab.dm +++ b/code/modules/mob/mob_grab.dm @@ -343,10 +343,6 @@ icon_state = "grabbed+1" add_attack_logs(assailant, affecting, "Neck grabbed", ATKLOG_ALL) - if(!iscarbon(assailant)) - affecting.LAssailant = null - else - affecting.LAssailant = assailant hud.icon_state = "kill" hud.name = "kill" affecting.Stun(3 SECONDS) // Ensures the grab is able to be secured diff --git a/code/modules/mob/mob_vars.dm b/code/modules/mob/mob_vars.dm index 9a4424ea66f..838f18bbddf 100644 --- a/code/modules/mob/mob_vars.dm +++ b/code/modules/mob/mob_vars.dm @@ -138,9 +138,6 @@ //Generic list for proc holders. Only way I can see to enable certain verbs/procs. Should be modified if needed. var/proc_holder_list[] = list() -//The last mob/living/carbon to push/drag/grab this mob (mostly used by slimes friend recognition) - var/mob/living/carbon/LAssailant = null - var/list/mob_spell_list = list() //construct spells and mime spells. Spells that do not transfer from one mob to another and can not be lost in mindswap. //List of active diseases diff --git a/code/modules/recycling/disposal.dm b/code/modules/recycling/disposal.dm index 9e2e9e00fbd..42fbde0b192 100644 --- a/code/modules/recycling/disposal.dm +++ b/code/modules/recycling/disposal.dm @@ -322,10 +322,6 @@ "You hear the sound of someone being stuffed into a disposal unit." ) - if(!iscarbon(user)) - target.LAssailant = null - else - target.LAssailant = user add_attack_logs(user, target, "Disposal'ed", !!target.ckey ? null : ATKLOG_ALL) else return diff --git a/code/modules/research/xenobiology/xenobio_camera.dm b/code/modules/research/xenobiology/xenobio_camera.dm index e33810f4398..cf44f3881f4 100644 --- a/code/modules/research/xenobiology/xenobio_camera.dm +++ b/code/modules/research/xenobiology/xenobio_camera.dm @@ -269,7 +269,6 @@ if(/obj/item/food/monkeycube/wolpincube) // Wolpin food = new /mob/living/carbon/human/wolpin(remote_eye.loc) SSmobs.cubemonkeys += food - food.LAssailant = C X.monkeys -- to_chat(owner, "[X] now has [X.monkeys] monkeys left.") else @@ -466,21 +465,19 @@ return else if(turfarea.name == E.allowed_area || turfarea.xenobiology_compatible) if(X.monkeys >= 1) - var/mob/living/carbon/human/monkey/food switch(recycler.cube_type) if(/obj/item/food/monkeycube) // Regular monkey - food = new /mob/living/carbon/human/monkey(T) + new /mob/living/carbon/human/monkey(T) if(/obj/item/food/monkeycube/nian_wormecube) // Worme - food = new /mob/living/carbon/human/nian_worme(T) + new /mob/living/carbon/human/nian_worme(T) if(/obj/item/food/monkeycube/farwacube) // Farwa - food = new /mob/living/carbon/human/farwa(T) + new /mob/living/carbon/human/farwa(T) if(/obj/item/food/monkeycube/stokcube) // Stok - food = new /mob/living/carbon/human/stok(T) + new /mob/living/carbon/human/stok(T) if(/obj/item/food/monkeycube/neaeracube) // Neara - food = new /mob/living/carbon/human/neara(T) + new /mob/living/carbon/human/neara(T) if(/obj/item/food/monkeycube/wolpincube) // Wolpin - food = new /mob/living/carbon/human/wolpin(T) - food.LAssailant = C + new /mob/living/carbon/human/wolpin(T) X.monkeys-- X.monkeys = round(X.monkeys, 0.1) to_chat(user, "[X] now has [X.monkeys] monkeys left.")