From 1acb7d6aad90c9b87e5b869cc5fb40bd09430df1 Mon Sep 17 00:00:00 2001 From: Rykka Date: Tue, 10 Sep 2019 21:48:18 -0600 Subject: [PATCH 1/3] Adds corrupt maint drone to .dme loading, fixes indentation --- .../simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm | 4 ++-- vorestation.dme | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm b/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm index 8765aed00e5..f5cf44d95a8 100644 --- a/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm +++ b/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm @@ -30,7 +30,7 @@ maxHealth = 25 health = 25 movement_cooldown = 0 - movement_sound = 'sound/effects/servostep.ogg' + movement_sound = 'sound/effects/servostep.ogg' pass_flags = PASSTABLE mob_swap_flags = 0 @@ -44,7 +44,7 @@ attack_sound = 'sound/weapons/bladeslice.ogg' attacktext = list("cut", "sliced") - poison_per_bite = 5 + poison_per_bite = 5 poison_type = "welder fuel" ai_holder_type = /datum/ai_holder/simple_mob/melee/evasive diff --git a/vorestation.dme b/vorestation.dme index 218d5a00164..9a95a50ebd4 100644 --- a/vorestation.dme +++ b/vorestation.dme @@ -2452,6 +2452,7 @@ #include "code\modules\mob\living\simple_mob\subtypes\humanoid\mercs\mercs_vr.dm" #include "code\modules\mob\living\simple_mob\subtypes\illusion\illusion.dm" #include "code\modules\mob\living\simple_mob\subtypes\mechanical\combat_drone.dm" +#include "code\modules\mob\living\simple_mob\subtypes\mechanical\corrupt_maint_drone_vr.dm" #include "code\modules\mob\living\simple_mob\subtypes\mechanical\disbot_vr.dm" #include "code\modules\mob\living\simple_mob\subtypes\mechanical\golem.dm" #include "code\modules\mob\living\simple_mob\subtypes\mechanical\mechanical.dm" From a6f8d3bdfc34280771243f5e0c4a340614a96463 Mon Sep 17 00:00:00 2001 From: Rykka Date: Tue, 10 Sep 2019 21:58:59 -0600 Subject: [PATCH 2/3] Adds Venom Injection Code --- .../mechanical/corrupt_maint_drone_vr.dm | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm b/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm index f5cf44d95a8..f69fd4e0671 100644 --- a/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm +++ b/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm @@ -44,11 +44,31 @@ attack_sound = 'sound/weapons/bladeslice.ogg' attacktext = list("cut", "sliced") + var/poison_type = "spidertoxin" // The reagent that gets injected when it attacks. + var/poison_chance = 35 // Chance for injection to occur. + var/poison_per_bite = 5 // Amount added per injection. + poison_per_bite = 5 poison_type = "welder fuel" ai_holder_type = /datum/ai_holder/simple_mob/melee/evasive + +/mob/living/simple_mob/mechanical/corrupt_maint_drone/apply_melee_effects(var/atom/A) + if(isliving(A)) + var/mob/living/L = A + if(L.reagents) + var/target_zone = pick(BP_TORSO,BP_TORSO,BP_TORSO,BP_L_LEG,BP_R_LEG,BP_L_ARM,BP_R_ARM,BP_HEAD) + if(L.can_inject(src, null, target_zone)) + inject_poison(L, target_zone) + +// Does actual poison injection, after all checks passed. +/mob/living/simple_mob/mechanical/corrupt_maint_drone/proc/inject_poison(mob/living/L, target_zone) + if(prob(poison_chance)) + to_chat(L, "Something burns in your veins.") + L.reagents.add_reagent(poison_type, poison_per_bite) + + /mob/living/simple_mob/mechanical/corrupt_maint_drone/death() ..(null,"is smashed into pieces!") qdel(src) \ No newline at end of file From 8c63a408d8fba654b24952b180d7140ad218079e Mon Sep 17 00:00:00 2001 From: Rykka Date: Tue, 10 Sep 2019 22:17:14 -0600 Subject: [PATCH 3/3] Removes redundant lines --- .../simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm b/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm index f69fd4e0671..f71242a6373 100644 --- a/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm +++ b/code/modules/mob/living/simple_mob/subtypes/mechanical/corrupt_maint_drone_vr.dm @@ -44,13 +44,10 @@ attack_sound = 'sound/weapons/bladeslice.ogg' attacktext = list("cut", "sliced") - var/poison_type = "spidertoxin" // The reagent that gets injected when it attacks. + var/poison_type = "welder fuel" // The reagent that gets injected when it attacks. var/poison_chance = 35 // Chance for injection to occur. var/poison_per_bite = 5 // Amount added per injection. - poison_per_bite = 5 - poison_type = "welder fuel" - ai_holder_type = /datum/ai_holder/simple_mob/melee/evasive