From af6f8c04a6ca737bbc3466ea79b90d14c3bf8daa Mon Sep 17 00:00:00 2001 From: KorPhaeron Date: Thu, 17 Dec 2015 01:57:08 -0600 Subject: [PATCH 1/5] Admin items --- code/game/objects/items/weapons/twohanded.dm | 25 +++++++++++++++++++ code/modules/clothing/suits/armor.dm | 21 ++++++++++------ .../living/simple_animal/hostile/illusion.dm | 21 ++++++++++++++-- 3 files changed, 58 insertions(+), 9 deletions(-) diff --git a/code/game/objects/items/weapons/twohanded.dm b/code/game/objects/items/weapons/twohanded.dm index 054dcf76376..84d723bef07 100644 --- a/code/game/objects/items/weapons/twohanded.dm +++ b/code/game/objects/items/weapons/twohanded.dm @@ -411,3 +411,28 @@ if(src == user.get_active_hand()) //update inhands user.update_inv_l_hand() user.update_inv_r_hand() + + +//GREY TIDE +/obj/item/weapon/twohanded/spear/grey_tide + icon_state = "spearglass0" + name = "\improper Grey Tide" + desc = "Recovered from the aftermath of a revolt aboard Defense Outpost Theta Aegis, in which a seemingly endless tide of Assistants caused heavy casualities among Nanotrasen military forces." + force_unwielded = 15 + force_wielded = 25 + throwforce = 20 + throw_speed = 4 + attack_verb = list("gored") + var/list/spear_owners = list() +/obj/item/weapon/twohanded/spear/grey_tide/afterattack(atom/movable/AM, mob/living/user, proximity) + ..() + if(!(user in spear_owners)) + user.faction += "greytide([rand(1, 1000)])" + spear_owners += user + if(istype(AM, /mob/living)) + var/mob/living/L = AM + if(!L.stat && prob(50)) + var/mob/living/simple_animal/hostile/illusion/M = new(user.loc) + M.faction = user.faction + M.Copy_Parent(user, 100, user.health/2.5, 12, 30) + M.GiveTarget(L) diff --git a/code/modules/clothing/suits/armor.dm b/code/modules/clothing/suits/armor.dm index c7f42350d07..40d77f12752 100644 --- a/code/modules/clothing/suits/armor.dm +++ b/code/modules/clothing/suits/armor.dm @@ -200,10 +200,6 @@ return 0 - - - - /obj/item/clothing/suit/armor/reactive/stealth name = "reactive stealth armor" @@ -221,10 +217,21 @@ owner.alpha = initial(owner.alpha) return 1 +/obj/item/clothing/suit/armor/reactive/tesla + name = "reactive tesla armor" - - - +/obj/item/clothing/suit/armor/reactive/tesla/hit_reaction(mob/living/carbon/human/owner, attack_text) + if(!active) + return 0 + if(prob(hit_reaction_chance)) + owner.visible_message("The [src] blocks the [attack_text], sending out arcs of lightning!") + for(var/mob/living/M in view(6, owner)) + if(M == owner) + continue + owner.Beam(M,icon_state="purple_lightning",icon='icons/effects/effects.dmi',time=5) + M.adjustFireLoss(25) + playsound(M, 'sound/machines/defib_zap.ogg', 50, 1, -1) + return 1 //All of the armor below is mostly unused diff --git a/code/modules/mob/living/simple_animal/hostile/illusion.dm b/code/modules/mob/living/simple_animal/hostile/illusion.dm index 7518f55e1da..b070b0ba4f2 100644 --- a/code/modules/mob/living/simple_animal/hostile/illusion.dm +++ b/code/modules/mob/living/simple_animal/hostile/illusion.dm @@ -8,12 +8,14 @@ melee_damage_lower = 5 melee_damage_upper = 5 a_intent = "harm" + attacktext = "gores" maxHealth = 100 health = 100 speed = 0 faction = list("illusion") var/life_span = INFINITY //how long until they despawn var/mob/living/parent_mob + var/multiply_chance = 0 //if we multiply on hit /mob/living/simple_animal/hostile/illusion/Life() @@ -22,11 +24,15 @@ death() -/mob/living/simple_animal/hostile/illusion/proc/Copy_Parent(mob/living/original, life = 50) +/mob/living/simple_animal/hostile/illusion/proc/Copy_Parent(mob/living/original, life = 50, health = 100, damage = 0, replicate = 0 ) appearance = original.appearance parent_mob = original dir = original.dir - life_span = world.time+life //5 seconds + life_span = world.time+life + melee_damage_lower = damage + melee_damage_upper = damage + multiply_chance = replicate + faction -= "neutral" /mob/living/simple_animal/hostile/illusion/death() @@ -42,6 +48,17 @@ return ..() +/mob/living/simple_animal/hostile/illusion/AttackingTarget() + ..() + if(istype(target, /mob/living) && prob(multiply_chance)) + var/mob/living/L = target + if(L.stat == DEAD) + return + var/mob/living/simple_animal/hostile/illusion/M = new(loc) + M.faction = faction + M.Copy_Parent(parent_mob, life_span, health/2, melee_damage_upper, multiply_chance/2) + M.GiveTarget(L) + ///////Actual Types///////// /mob/living/simple_animal/hostile/illusion/escape From 89528b1e3930fb7771f87255e8c10b54b77fc0df Mon Sep 17 00:00:00 2001 From: KorPhaeron Date: Fri, 18 Dec 2015 00:54:29 -0600 Subject: [PATCH 2/5] User reference --- code/game/objects/items/weapons/twohanded.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/game/objects/items/weapons/twohanded.dm b/code/game/objects/items/weapons/twohanded.dm index 84d723bef07..17194705b92 100644 --- a/code/game/objects/items/weapons/twohanded.dm +++ b/code/game/objects/items/weapons/twohanded.dm @@ -427,7 +427,7 @@ /obj/item/weapon/twohanded/spear/grey_tide/afterattack(atom/movable/AM, mob/living/user, proximity) ..() if(!(user in spear_owners)) - user.faction += "greytide([rand(1, 1000)])" + user.faction += "greytide(\ref[user])" spear_owners += user if(istype(AM, /mob/living)) var/mob/living/L = AM From 5b0777e2b42d890a02ede2594d46ef144ed2d468 Mon Sep 17 00:00:00 2001 From: KorPhaeron Date: Fri, 18 Dec 2015 13:57:25 -0600 Subject: [PATCH 3/5] Faction copy --- code/game/objects/items/weapons/twohanded.dm | 5 ++--- code/modules/mob/living/simple_animal/hostile/illusion.dm | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/code/game/objects/items/weapons/twohanded.dm b/code/game/objects/items/weapons/twohanded.dm index 17194705b92..ce49c423473 100644 --- a/code/game/objects/items/weapons/twohanded.dm +++ b/code/game/objects/items/weapons/twohanded.dm @@ -427,12 +427,11 @@ /obj/item/weapon/twohanded/spear/grey_tide/afterattack(atom/movable/AM, mob/living/user, proximity) ..() if(!(user in spear_owners)) - user.faction += "greytide(\ref[user])" - spear_owners += user + user.faction |= "greytide(\ref[user])" if(istype(AM, /mob/living)) var/mob/living/L = AM if(!L.stat && prob(50)) var/mob/living/simple_animal/hostile/illusion/M = new(user.loc) - M.faction = user.faction + M.faction = user.faction.Copy() M.Copy_Parent(user, 100, user.health/2.5, 12, 30) M.GiveTarget(L) diff --git a/code/modules/mob/living/simple_animal/hostile/illusion.dm b/code/modules/mob/living/simple_animal/hostile/illusion.dm index b070b0ba4f2..53e8bdd94e6 100644 --- a/code/modules/mob/living/simple_animal/hostile/illusion.dm +++ b/code/modules/mob/living/simple_animal/hostile/illusion.dm @@ -55,7 +55,7 @@ if(L.stat == DEAD) return var/mob/living/simple_animal/hostile/illusion/M = new(loc) - M.faction = faction + M.faction = faction.Copy() M.Copy_Parent(parent_mob, life_span, health/2, melee_damage_upper, multiply_chance/2) M.GiveTarget(L) From 2601154d6373bb78aca1ef22410d5fb8b570b9a6 Mon Sep 17 00:00:00 2001 From: KorPhaeron Date: Fri, 18 Dec 2015 14:02:27 -0600 Subject: [PATCH 4/5] Slightly better replicate chance for illusions --- code/modules/mob/living/simple_animal/hostile/illusion.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/modules/mob/living/simple_animal/hostile/illusion.dm b/code/modules/mob/living/simple_animal/hostile/illusion.dm index 53e8bdd94e6..b16ef6d9207 100644 --- a/code/modules/mob/living/simple_animal/hostile/illusion.dm +++ b/code/modules/mob/living/simple_animal/hostile/illusion.dm @@ -56,7 +56,7 @@ return var/mob/living/simple_animal/hostile/illusion/M = new(loc) M.faction = faction.Copy() - M.Copy_Parent(parent_mob, life_span, health/2, melee_damage_upper, multiply_chance/2) + M.Copy_Parent(parent_mob, life_span, health/2, melee_damage_upper, multiply_chance) M.GiveTarget(L) ///////Actual Types///////// From 17006ed3f8f21cb2c4035269745616d2e097c51c Mon Sep 17 00:00:00 2001 From: KorPhaeron Date: Fri, 18 Dec 2015 14:18:28 -0600 Subject: [PATCH 5/5] I'm not paying any attention at all right now sorry --- code/game/objects/items/weapons/twohanded.dm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/code/game/objects/items/weapons/twohanded.dm b/code/game/objects/items/weapons/twohanded.dm index ce49c423473..f0c2cde3211 100644 --- a/code/game/objects/items/weapons/twohanded.dm +++ b/code/game/objects/items/weapons/twohanded.dm @@ -423,11 +423,10 @@ throwforce = 20 throw_speed = 4 attack_verb = list("gored") - var/list/spear_owners = list() + /obj/item/weapon/twohanded/spear/grey_tide/afterattack(atom/movable/AM, mob/living/user, proximity) ..() - if(!(user in spear_owners)) - user.faction |= "greytide(\ref[user])" + user.faction |= "greytide(\ref[user])" if(istype(AM, /mob/living)) var/mob/living/L = AM if(!L.stat && prob(50))