Alien fixes/changes:

Alien stun chance on harm decreased.
Alien stab intent changed to stun intent which deals light damage. It does have a very high chance of knock down and an even higher chance of disarming the target.
Hud icon changed to reflect this.
Upped the chance aliens stunning cyborgs with stun intent.
Updated aliens attacking monkeys code.
Aliens can now directly attack the AI.
General code cleanup for alien attacks and others attacking aliens (hand to hand).
Humanoid aliens may no longer run on tables.
Fixed a typo in the Corrode ability.
Increased the amount of abuse resin walls can take. Changed how damaging them works (as windows). Hulks may now smash straight through resin walls. Aliens may now destroy them without acid (and can no longer use acid on them).
Spit now produces a message when used.
Fixed aliens not being stunned by stun batons.
Aliens can now attack/destroy turrets.
Removed alien vision loss from being shot by lasors.
Aliens are not deterred by flash now (flashbangs should still work).
You can no-longer stab aliens in their nonexistent eyes with screwdrivers or forks.
Changing a mob into an alien now properly sets their intent (help).
Minor, misc alien code adjustments.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@762 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
noisomehollow@lycos.com
2011-01-03 23:32:18 +00:00
parent 0b69512b72
commit d2bb7d63ba
20 changed files with 670 additions and 444 deletions
@@ -24,7 +24,7 @@ These are being worked on.
return
/*Alien spit now works like a taser shot. It won't home in on the target but will act the same once it does hit.
Doesn't work on silicon mobs or other aliens.*/
Doesn't work on other aliens/AI.*/
/mob/living/carbon/alien/humanoid/verb/spit(mob/target as mob in oview())
set name = "Spit Neurotoxin (50)"
set desc = "Spits neurotoxin at someone, paralyzing them for a short time."
@@ -37,6 +37,10 @@ Doesn't work on silicon mobs or other aliens.*/
src << "\green Your allies are not a valid target."
return
if(src.toxloss >= 50)
src << "\green You spit neurotoxin at [target]."
for(var/mob/O in oviewers())
if ((O.client && !( O.blinded )))
O << "\red [src] spits neurotoxin at [target]!"
src.toxloss -= 50
var/turf/T = usr.loc
var/turf/U = (istype(target, /atom/movable) ? target.loc : target)
@@ -199,7 +203,7 @@ Doesn't work on silicon mobs or other aliens.*/
src.toxloss -= 100
src << "\green You begin to shape a wall of resin."
for(var/mob/O in viewers(src, null))
O.show_message(text("\green <B>[src] vomits up a thick purple substance and begins to shape it!</B>"), 1)
O.show_message(text("\red <B>[src] vomits up a thick purple substance and begins to shape it!</B>"), 1)
//var/obj/alien/resin/R = new(src.loc)
new /obj/alien/resin(src.loc)
else
@@ -189,10 +189,8 @@ This is all very silly and I will probably remove it in the future. /N
return
else if(flag == PROJECTILE_LASER)
var/d = 20
if (!src.eye_blurry) src.eye_blurry = 4 //This stuff makes no sense but lasers need a buff.
// if (!src.eye_blurry) src.eye_blurry = 4 //This stuff makes no sense but lasers need a buff./ It really doesn't make any sense. /N
if (prob(25)) src.stunned++
if (src.stat != 2)
src.bruteloss += d
src.updatehealth()
@@ -615,25 +613,38 @@ This is all very silly and I will probably remove it in the future. /N
return
/mob/living/carbon/alien/humanoid/attack_paw(mob/living/carbon/monkey/M as mob)
if(istype(M, /mob/living/carbon/alien)) return//Quick fix since these display double for aliens when they interact with aliens.
if (M.a_intent == "help")
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
for(var/mob/O in viewers(src, null))
O.show_message(text("\blue [M.name] shakes [src] trying to wake it up!", ), 1)
else
if (istype(src.wear_mask, /obj/item/clothing/mask/muzzle))
return
if (src.health > 0)
playsound(src.loc, 'bite.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[M.name] has bit [src]!</B>"), 1)
src.bruteloss += rand(1, 3)
if(!(istype(M, /mob/living/carbon/monkey))) return//Fix for aliens receiving double messages when attacking other aliens.
src.updatehealth()
if (!ticker)
M << "You cannot attack people before the game has started."
return
if (istype(src.loc, /turf) && istype(src.loc.loc, /area/start))
M << "No attacking people at spawn, you jackass."
return
..()
switch(M.a_intent)
if ("help")
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M.name] shakes [src] trying to wake it up!", ), 1)
else
if (istype(src.wear_mask, /obj/item/clothing/mask/muzzle))
return
if (src.health > 0)
playsound(src.loc, 'bite.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[M.name] has bit [src]!</B>"), 1)
src.bruteloss += rand(1, 3)
src.updatehealth()
return
/mob/living/carbon/alien/humanoid/attack_hand(mob/living/carbon/human/M as mob)
@@ -647,7 +658,7 @@ This is all very silly and I will probably remove it in the future. /N
..()
if ((M.gloves && M.gloves.elecgen == 1 && M.a_intent == "hurt") /*&& (!istype(src:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
if(M.gloves && M.gloves.elecgen == 1)//Stungloves. Any contact will stun the alien.
if(M.gloves.uses > 0)
M.gloves.uses--
if (src.weakened < 5)
@@ -657,40 +668,39 @@ This is all very silly and I will probably remove it in the future. /N
if (src.stunned < 5)
src.stunned = 5
for(var/mob/O in viewers(src, null))
if (O.client)
O.show_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>", 1, "\red You hear someone fall", 2)
else
M.gloves.elecgen = 0
M << "\red Not enough charge! "
return
if ((O.client && !( O.blinded )))
O.show_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>", 1, "\red You hear someone fall.", 2)
if (M.a_intent == "help")
if (src.health > 0)
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\blue [] shakes [] trying to wake [] up!", M, src, src), 1)
else
if (M.health >= -75.0)
if (((M.head && M.head.flags & 4) || ((M.wear_mask && !( M.wear_mask.flags & 32 )) || ((src.head && src.head.flags & 4) || (src.wear_mask && !( src.wear_mask.flags & 32 ))))))
M << "\blue <B>Remove that mask!</B>"
return
var/obj/equip_e/human/O = new /obj/equip_e/human( )
O.source = M
O.target = src
O.s_loc = M.loc
O.t_loc = src.loc
O.place = "CPR"
src.requests += O
spawn( 0 )
O.process()
return
else
if (M.a_intent == "grab")
switch(M.a_intent)
if ("help")
if (src.health > 0)
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [] shakes [] trying to wake [] up!", M, src, src), 1)
else
if (M.health >= -75.0)
if (((M.head && M.head.flags & 4) || ((M.wear_mask && !( M.wear_mask.flags & 32 )) || ((src.head && src.head.flags & 4) || (src.wear_mask && !( src.wear_mask.flags & 32 ))))))
M << "\blue <B>Remove that mask!</B>"
return
var/obj/equip_e/human/O = new /obj/equip_e/human( )
O.source = M
O.target = src
O.s_loc = M.loc
O.t_loc = src.loc
O.place = "CPR"
src.requests += O
spawn( 0 )
O.process()
return
if ("grab")
if (M == src)
return
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab( M )
@@ -705,50 +715,57 @@ This is all very silly and I will probably remove it in the future. /N
G.synch()
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red [] has grabbed [] passively!", M, src), 1)
else
if (M.a_intent == "hurt" && !(M.gloves && M.gloves.elecgen == 1))
var/damage = rand(1, 9)
if (prob(90))
if (M.mutations & 8)
damage += 5
spawn(0)
src.paralysis += 1
step_away(src,M,15)
sleep(3)
step_away(src,M,15)
playsound(src.loc, "punch", 25, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red [] has grabbed [] passively!", M, src), 1)
if ("hurt")
var/damage = rand(1, 9)
if (prob(90))
if (M.mutations & 8)
damage += 5
spawn(0)
src.paralysis += 1
step_away(src,M,15)
sleep(3)
step_away(src,M,15)
playsound(src.loc, "punch", 25, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has punched []!</B>", M, src), 1)
if (damage > 4.9)
if (src.weakened < 10)
src.weakened = rand(10, 15)
for(var/mob/O in viewers(M, null))
if (damage > 4.9)
if (src.weakened < 10)
src.weakened = rand(10, 15)
for(var/mob/O in viewers(M, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has weakened []!</B>", M, src), 1, "\red You hear someone fall.", 2)
src.bruteloss += damage
src.updatehealth()
else
playsound(src.loc, 'punchmiss.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has attempted to punch []!</B>", M, src), 1)
return
src.bruteloss += damage
src.updatehealth()
else
if (!( src.lying ) && !(M.gloves && M.gloves.elecgen == 1))
var/randn = rand(1, 100)
if (randn <= 25)
src.weakened = 2
playsound(src.loc, 'punchmiss.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has attempted to punch []!</B>", M, src), 1)
if ("disarm")
if (!src.lying)
var/randn = rand(1, 100)
if (randn <= 25)
src.weakened = 2
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has pushed down []!</B>", M, src), 1)
else
if (randn <= 60)
src.drop_item()
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has pushed down []!</B>", M, src), 1)
else
if (randn <= 60)
src.drop_item()
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has disarmed []!</B>", M, src), 1)
else
playsound(src.loc, 'punchmiss.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
else
playsound(src.loc, 'punchmiss.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has attempted to disarm []!</B>", M, src), 1)
return
@@ -768,25 +785,29 @@ In all, this is a lot like the monkey code. /N
..()
if (M.a_intent == "help")
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
for(var/mob/O in viewers(src, null))
O.show_message(text("\blue [M.name] nuzzles [] trying to wake it up!", src), 1)
switch(M.a_intent)
else
if (src.health > 0)
playsound(src.loc, 'bite.ogg', 50, 1, -1)
var/damage = rand(1, 3)
if ("help")
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[M.name] has bit []!</B>", src), 1)
src.bruteloss += damage
src.updatehealth()
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M.name] nuzzles [] trying to wake it up!", src), 1)
else
M << "\green <B>[src.name] is too injured for that.</B>"
if (src.health > 0)
playsound(src.loc, 'bite.ogg', 50, 1, -1)
var/damage = rand(1, 3)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[M.name] has bit []!</B>", src), 1)
src.bruteloss += damage
src.updatehealth()
else
M << "\green <B>[src.name] is too injured for that.</B>"
return
@@ -96,7 +96,7 @@
else if(flag == PROJECTILE_LASER)
var/d = 20
if (!src.eye_blurry) src.eye_blurry = 4 //This stuff makes no sense but lasers need a buff.
// if (!src.eye_blurry) src.eye_blurry = 4 //This stuff makes no sense but lasers need a buff./ It really doesn't make any sense. /N
if (prob(25)) src.stunned++
if (src.stat != 2)
@@ -331,27 +331,38 @@
return
/mob/living/carbon/alien/larva/attack_paw(mob/living/carbon/monkey/M as mob)
if(istype(M, /mob/living/carbon/alien)) return//Quick fix since these display double for aliens when they interact with aliens.
if (M.a_intent == "help")
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
for(var/mob/O in viewers(src, null))
O.show_message(text("\blue [M.name] shakes [src] trying to wake it up!", ), 1)
else
if (istype(src.wear_mask, /obj/item/clothing/mask/muzzle))
return
if (src.health > 0)
playsound(src.loc, 'bite.ogg', 50, 1, -1)
if(!(istype(M, /mob/living/carbon/monkey))) return//Fix for aliens receiving double messages when attacking other aliens.
if (!ticker)
M << "You cannot attack people before the game has started."
return
if (istype(src.loc, /turf) && istype(src.loc.loc, /area/start))
M << "No attacking people at spawn, you jackass."
return
..()
switch(M.a_intent)
if ("help")
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[M.name] has bit [src]!</B>"), 1)
var/damage = rand(1, 3)
src.bruteloss += damage
src.updatehealth()
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M.name] shakes [src] trying to wake it up!", ), 1)
else
if (istype(src.wear_mask, /obj/item/clothing/mask/muzzle))
return
if (src.health > 0)
playsound(src.loc, 'bite.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[M.name] has bit [src]!</B>"), 1)
src.bruteloss += rand(1, 3)
src.updatehealth()
return
/mob/living/carbon/alien/larva/attack_hand(mob/living/carbon/human/M as mob)
@@ -363,7 +374,9 @@
M << "No attacking people at spawn, you jackass."
return
if ((M.gloves && M.gloves.elecgen == 1 && M.a_intent == "hurt") /*&& (!istype(src:wear_suit, /obj/item/clothing/suit/judgerobe))*/)
..()
if(M.gloves && M.gloves.elecgen == 1)//Stungloves. Any contact will stun the alien.
if(M.gloves.uses > 0)
M.gloves.uses--
if (src.weakened < 5)
@@ -373,40 +386,39 @@
if (src.stunned < 5)
src.stunned = 5
for(var/mob/O in viewers(src, null))
if (O.client)
O.show_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>", 1, "\red You hear someone fall", 2)
else
M.gloves.elecgen = 0
M << "\red Not enough charge! "
return
if ((O.client && !( O.blinded )))
O.show_message("\red <B>[src] has been touched with the stun gloves by [M]!</B>", 1, "\red You hear someone fall.", 2)
if (M.a_intent == "help")
if (src.health > 0)
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\blue [] shakes [] trying to wake [] up!", M, src, src), 1)
else
if (M.health >= -75.0)
if ((M.head && M.head.flags & 4) || (M.wear_mask && !( M.wear_mask.flags & 32 )) )
M << "\blue <B>Remove that mask!</B>"
return
var/obj/equip_e/human/O = new /obj/equip_e/human( )
O.source = M
O.target = src
O.s_loc = M.loc
O.t_loc = src.loc
O.place = "CPR"
src.requests += O
spawn( 0 )
O.process()
return
else
if (M.a_intent == "grab")
switch(M.a_intent)
if ("help")
if (src.health > 0)
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [] shakes [] trying to wake [] up!", M, src, src), 1)
else
if (M.health >= -75.0)
if ((M.head && M.head.flags & 4) || (M.wear_mask && !( M.wear_mask.flags & 32 )) )
M << "\blue <B>Remove that mask!</B>"
return
var/obj/equip_e/human/O = new /obj/equip_e/human( )
O.source = M
O.target = src
O.s_loc = M.loc
O.t_loc = src.loc
O.place = "CPR"
src.requests += O
spawn( 0 )
O.process()
return
if ("grab")
if (M == src)
return
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab( M )
@@ -421,33 +433,36 @@
G.synch()
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red [] has grabbed [] passively!", M, src), 1)
if ((O.client && !( O.blinded )))
O.show_message(text("\red [] has grabbed [] passively!", M, src), 1)
else
if (M.a_intent == "hurt" && !(M.gloves && M.gloves.elecgen == 1))
var/damage = rand(1, 9)
if (prob(90))
if (M.mutations & 8 && prob(90))
damage += 5
spawn(0)
src.paralysis += 1
step_away(src,M,15)
sleep(3)
step_away(src,M,15)
playsound(src.loc, "punch", 25, 1, -1)
for(var/mob/O in viewers(src, null))
var/damage = rand(1, 9)
if (prob(90))
if (M.mutations & 8)
damage += 5
spawn(0)
src.paralysis += 1
step_away(src,M,15)
sleep(3)
step_away(src,M,15)
playsound(src.loc, "punch", 25, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has punched []!</B>", M, src), 1)
src.bruteloss += damage
src.updatehealth()
else
playsound(src.loc, 'punchmiss.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has attempted to punch []!</B>", M, src), 1)
return
if (damage > 4.9)
if (src.weakened < 10)
src.weakened = rand(10, 15)
for(var/mob/O in viewers(M, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has weakened []!</B>", M, src), 1, "\red You hear someone fall.", 2)
src.bruteloss += damage
src.updatehealth()
else
return
playsound(src.loc, 'punchmiss.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has attempted to punch []!</B>", M, src), 1)
return
/mob/living/carbon/alien/larva/attack_alien(mob/living/carbon/alien/humanoid/M as mob)
@@ -461,25 +476,29 @@
..()
if (M.a_intent == "help")
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
for(var/mob/O in viewers(src, null))
O.show_message(text("\blue [M.name] nuzzles [] trying to wake it up!", src), 1)
switch(M.a_intent)
else
if (src.health > 0)
playsound(src.loc, 'bite.ogg', 50, 1, -1)
var/damage = rand(1, 3)
if ("help")
src.sleeping = 0
src.resting = 0
if (src.paralysis >= 3) src.paralysis -= 3
if (src.stunned >= 3) src.stunned -= 3
if (src.weakened >= 3) src.weakened -= 3
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[M.name] has bit []!</B>", src), 1)
src.bruteloss += damage
src.updatehealth()
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M.name] nuzzles [] trying to wake it up!", src), 1)
else
M << "\green <B>[src.name] is too injured for that.</B>"
if (src.health > 0)
playsound(src.loc, 'bite.ogg', 50, 1, -1)
var/damage = rand(1, 3)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[M.name] has bit []!</B>", src), 1)
src.bruteloss += damage
src.updatehealth()
else
M << "\green <B>[src.name] is too injured for that.</B>"
return
/mob/living/carbon/alien/larva/restrained()
+122 -91
View File
@@ -5,6 +5,18 @@
if (!dna)
dna = new /datum/dna( null )
/*
if(istype(src, /mob/living/carbon/human/vampire))
spawn (1)
src.verbs += /mob/proc/mist
src.verbs += /mob/proc/port
src.verbs += /mob/proc/hellfire
src.verbs += /mob/proc/veil
src.verbs += /mob/proc/charm
src.verbs += /mob/proc/lights
src.verbs += /mob/proc/blood
src.mutantrace = "vampire"
*/
spawn (1)
var/datum/organ/external/chest/chest = new /datum/organ/external/chest( src )
chest.owner = src
@@ -1407,12 +1419,14 @@
M << "No attacking people at spawn, you jackass."
return
if (M.a_intent == "help")
for(var/mob/O in viewers(src, null))
O.show_message(text("\blue [M] caresses [src] with its scythe like arm."), 1)
else
//This will be changed to skin, where we can skin a dead human corpse//Actually, that sounds kind of impractical./N
if (M.a_intent == "grab")
switch(M.a_intent)
if ("help")
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M] caresses [src] with its scythe like arm."), 1)
if ("grab")
//This will be changed to skin, where we can skin a dead human corpse//Actually, that sounds kind of impractical./N
if (M == src)
return
if (src.w_uniform)
@@ -1429,106 +1443,123 @@
G.synch()
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red [] has grabbed [] passively!", M, src), 1)
else
if (M.a_intent == "hurt")
if (src.w_uniform)
src.w_uniform.add_fingerprint(M)
var/damage = rand(15, 30) // How much damage aliens do to humans? Increasing -- TLE
// I've decreased the chance of humans being protected by uniforms. Now aliens can actually damage them.
var/datum/organ/external/affecting = src.organs["chest"]
var/t = M.zone_sel.selecting
if ((t in list( "eyes", "mouth" )))
t = "head"
var/def_zone = ran_zone(t)
if (src.organs[def_zone])
affecting = src.organs[def_zone]
if ((istype(affecting, /datum/organ/external) && prob(95)))
playsound(src.loc, 'slice.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red [] has grabbed [] passively!", M, src), 1)
if ("hurt")
if (src.w_uniform)
src.w_uniform.add_fingerprint(M)
var/damage = rand(15, 30) // How much damage aliens do to humans? Increasing -- TLE
// I've decreased the chance of humans being protected by uniforms. Now aliens can actually damage them.
var/datum/organ/external/affecting = src.organs["chest"]
var/t = M.zone_sel.selecting
if ((t in list( "eyes", "mouth" )))
t = "head"
var/def_zone = ran_zone(t)
if (src.organs[def_zone])
affecting = src.organs[def_zone]
if ((istype(affecting, /datum/organ/external) && prob(95)))
playsound(src.loc, 'slice.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has slashed at []!</B>", M, src), 1)
if (def_zone == "head")
if ((((src.head && src.head.body_parts_covered & HEAD) || (src.wear_mask && src.wear_mask.body_parts_covered & HEAD)) && prob(5)))
if (prob(20))
affecting.take_damage(damage, 0)
else
src.show_message("\red You have been protected from a hit to the head.")
return
if (damage > 4.9)
if (src.weakened < 10)
src.weakened = rand(10, 15)
for(var/mob/O in viewers(M, null))
if (def_zone == "head")
if ((((src.head && src.head.body_parts_covered & HEAD) || (src.wear_mask && src.wear_mask.body_parts_covered & HEAD)) && prob(5)))
if (prob(20))
affecting.take_damage(damage, 0)
else
src.show_message("\red You have been protected from a hit to the head.")
return
if (damage >= 25)
if (src.weakened < 10)
src.weakened = rand(10, 15)
for(var/mob/O in viewers(M, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has wounded []!</B>", M, src), 1, "\red You hear someone fall.", 2)
affecting.take_damage(damage)
else
if (def_zone == "chest")
if ((((src.wear_suit && src.wear_suit.body_parts_covered & UPPER_TORSO) || (src.w_uniform && src.w_uniform.body_parts_covered & LOWER_TORSO)) && prob(10)))
src.show_message("\blue You have been protected from a hit to the chest.")
return
if (damage >= 25)
if (prob(50))
if (src.weakened < 5)
src.weakened = 5
playsound(src.loc, 'slashmiss.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has tackled down []!</B>", M, src), 1, "\red You hear someone fall.", 2)
else
if (src.stunned < 5)
src.stunned = 5
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has stunned []!</B>", M, src), 1)
if(src.stat != 2) src.stat = 1
affecting.take_damage(damage)
else
if (def_zone == "chest")
if ((((src.wear_suit && src.wear_suit.body_parts_covered & UPPER_TORSO) || (src.w_uniform && src.w_uniform.body_parts_covered & LOWER_TORSO)) && prob(10)))
src.show_message("\blue You have been protected from a hit to the chest.")
if (def_zone == "groin")
if ((((src.wear_suit && src.wear_suit.body_parts_covered & LOWER_TORSO) || (src.w_uniform && src.w_uniform.body_parts_covered & LOWER_TORSO)) && prob(1)))
src.show_message("\blue You have been protected from a hit to the lower chest.")
return
if (damage > 4.9)
if (damage >= 25)
if (prob(50))
if (src.weakened < 5)
src.weakened = 5
playsound(src.loc, 'slashmiss.ogg', 50, 1, -1)
if (src.weakened < 3)
src.weakened = 3
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has tackled down []!</B>", M, src), 1, "\red You hear someone fall.", 2)
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has tackled down []!</B>", M, src), 1, "\red You hear someone fall.", 2)
else
if (src.stunned < 5)
src.stunned = 5
if (src.stunned < 3)
src.stunned = 3
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has stunned []!</B>", M, src), 1)
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has stunned []!</B>", M, src), 1)
if(src.stat != 2) src.stat = 1
affecting.take_damage(damage)
else
if (def_zone == "groin")
if ((((src.wear_suit && src.wear_suit.body_parts_covered & LOWER_TORSO) || (src.w_uniform && src.w_uniform.body_parts_covered & LOWER_TORSO)) && prob(1)))
src.show_message("\blue You have been protected from a hit to the lower chest.")
return
if (damage > 4.9)
if (prob(50))
if (src.weakened < 3)
src.weakened = 3
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has tackled down []!</B>", M, src), 1, "\red You hear someone fall.", 2)
else
if (src.stunned < 3)
src.stunned = 3
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has stunned []!</B>", M, src), 1)
if(src.stat != 2) src.stat = 1
affecting.take_damage(damage)
else
affecting.take_damage(damage)
src.UpdateDamageIcon()
src.updatehealth()
affecting.take_damage(damage)
src.UpdateDamageIcon()
src.updatehealth()
else
playsound(src.loc, 'slashmiss.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[M] has lunged at [src] but missed!</B>"), 1)
if ("disarm")
var/damage = 5
var/datum/organ/external/affecting = src.organs["chest"]
var/t = M.zone_sel.selecting
if ((t in list( "eyes", "mouth" )))
t = "head"
var/def_zone = ran_zone(t)
if (src.organs[def_zone])
affecting = src.organs[def_zone]
if (src.w_uniform)
src.w_uniform.add_fingerprint(M)
var/randn = rand(1, 100)
if (randn <= 90)
playsound(src.loc, 'pierce.ogg', 25, 1, -1)
if (src.weakened < 15)
src.weakened = rand(10, 15)
affecting.take_damage(damage)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has tackled down []!</B>", M, src), 1)
else
if (randn <= 99)
playsound(src.loc, 'slash.ogg', 25, 1, -1)
src.drop_item()
affecting.take_damage(damage)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] disarmed []!</B>", M, src), 1)
else
playsound(src.loc, 'slashmiss.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[M] has lunged at [src] but missed!</B>"), 1)
return
else
//disarm
if (!( src.lying ))
if (src.w_uniform)
src.w_uniform.add_fingerprint(M)
var/randn = rand(1, 100)
if (randn <= 25)
playsound(src.loc, 'pierce.ogg', 25, 1, -1)
src.weakened = 2
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has tackled over []!</B>", M, src), 1)
else
if (randn <= 60)
playsound(src.loc, 'slash.ogg', 25, 1, -1)
src.drop_item()
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has knocked the item out of []'s hand!</B>", M, src), 1)
else
playsound(src.loc, 'slashmiss.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has tried to knock the item out of []'s hand!</B>", M, src), 1)
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has tried to disarm []!</B>", M, src), 1)
return
/mob/living/carbon/human/attack_hand(mob/living/carbon/human/M as mob)
+48 -46
View File
@@ -283,28 +283,27 @@
M << "No attacking people at spawn, you jackass."
return
if (M.a_intent == "help")
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M] caresses [src] with its scythe like arm."), 1)
else
if (M.a_intent == "hurt")
if ((prob(95) && src.health > 0))
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has slashed [src.name]!</B>", M), 1)
switch(M.a_intent)
if ("help")
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M] caresses [src] with its scythe like arm."), 1)
if ("hurt")
if ((prob(95) && src.health > 0))
playsound(src.loc, 'slice.ogg', 25, 1, -1)
var/damage = rand(15, 30)
if (prob(40))
if (damage >= 25)
damage = rand(20, 40)
if (src.paralysis < 5)
if (src.paralysis < 15)
src.paralysis = rand(10, 15)
spawn( 0 )
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has wounded [src.name]!</B>", M), 1)
return
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has wounded [src.name]!</B>", M), 1)
else
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has slashed [src.name]!</B>", M), 1)
src.bruteloss += damage
src.updatehealth()
else
@@ -312,36 +311,39 @@
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has attempted to lunge at [src.name]!</B>", M), 1)
else
if (M.a_intent == "grab")
if (M == src)
return
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab( M )
G.assailant = M
if (M.hand)
M.l_hand = G
else
M.r_hand = G
G.layer = 20
G.affecting = src
src.grabbed_by += G
G.synch()
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red [] has grabbed [src.name] passively!", M), 1)
if ("grab")
if (M == src)
return
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab( M )
G.assailant = M
if (M.hand)
M.l_hand = G
else
if (!( src.paralysis ))
playsound(src.loc, 'pierce.ogg', 25, 1, -1)
if(prob(25))
src.paralysis = 2
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has tackled down [src.name]!</B>", M), 1)
else
drop_item()
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has disarmed [src.name]!</B>", M), 1)
M.r_hand = G
G.layer = 20
G.affecting = src
src.grabbed_by += G
G.synch()
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red [] has grabbed [src.name] passively!", M), 1)
if ("disarm")
playsound(src.loc, 'pierce.ogg', 25, 1, -1)
var/damage = 5
if(prob(95))
src.weakened = rand(10, 15)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has tackled down [src.name]!</B>", M), 1)
else
drop_item()
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has disarmed [src.name]!</B>", M), 1)
src.bruteloss += damage
src.updatehealth()
return
/mob/living/carbon/monkey/Stat()
+34
View File
@@ -231,6 +231,40 @@
src.stunned = min(5, src.stunned)
return
/mob/living/silicon/ai/attack_alien(mob/living/carbon/alien/humanoid/M as mob)
if (!ticker)
M << "You cannot attack people before the game has started."
return
if (istype(src.loc, /turf) && istype(src.loc.loc, /area/start))
M << "No attacking people at spawn, you jackass."
return
switch(M.a_intent)
if ("help")
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M] caresses [src]'s plating with its scythe like arm."), 1)
else //harm
var/damage = rand(10, 20)
if (prob(90))
playsound(src.loc, 'slash.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has slashed at []!</B>", M, src), 1)
if(prob(8))
flick("noise", src.flash)
src.bruteloss += damage
src.updatehealth()
else
playsound(src.loc, 'slashmiss.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] took a swipe at []!</B>", M, src), 1)
return
/mob/living/silicon/ai/proc/switchCamera(var/obj/machinery/camera/C)
usr:cameraFollow = null
+64 -51
View File
@@ -460,66 +460,79 @@
return ..()
/mob/living/silicon/robot/attack_alien(mob/living/carbon/alien/humanoid/M as mob)
if (!ticker)
M << "You cannot attack people before the game has started."
return
if (M.a_intent == "help")
for(var/mob/O in viewers(src, null))
O.show_message(text("\blue [M] caresses [src]'s plating with its scythe like arm."), 1)
if (istype(src.loc, /turf) && istype(src.loc.loc, /area/start))
M << "No attacking people at spawn, you jackass."
return
else if (M.a_intent == "grab")
if (M == src)
return
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab( M )
G.assailant = M
if (M.hand)
M.l_hand = G
else
M.r_hand = G
G.layer = 20
G.affecting = src
src.grabbed_by += G
G.synch()
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red [] has grabbed [] passively!", M, src), 1)
switch(M.a_intent)
else if (M.a_intent == "hurt")
var/damage = rand(10, 20)
if (prob(90))
/*
if (M.class == "combat")
damage += 15
if(prob(20))
src.weakened = max(src.weakened,4)
src.stunned = max(src.stunned,4)
*/
playsound(src.loc, 'slash.ogg', 25, 1, -1)
if ("help")
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has slashed at []!</B>", M, src), 1)
if(prob(8))
flick("noise", src.flash)
src.bruteloss += damage
src.updatehealth()
else
playsound(src.loc, 'slashmiss.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] took a swipe at []!</B>", M, src), 1)
return
if ((O.client && !( O.blinded )))
O.show_message(text("\blue [M] caresses [src]'s plating with its scythe like arm."), 1)
else if (M.a_intent == "disarm")
if(!(src.lying))
var/randn = rand(1, 100)
if (randn <= 40)
src.stunned = 5
step(src,get_dir(M,src))
spawn(5) step(src,get_dir(M,src))
playsound(src.loc, 'slash.ogg', 50, 1, -1)
if ("grab")
if (M == src)
return
var/obj/item/weapon/grab/G = new /obj/item/weapon/grab( M )
G.assailant = M
if (M.hand)
M.l_hand = G
else
M.r_hand = G
G.layer = 20
G.affecting = src
src.grabbed_by += G
G.synch()
playsound(src.loc, 'thudswoosh.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red [] has grabbed [] passively!", M, src), 1)
if ("hurt")
var/damage = rand(10, 20)
if (prob(90))
/*
if (M.class == "combat")
damage += 15
if(prob(20))
src.weakened = max(src.weakened,4)
src.stunned = max(src.stunned,4)
What is this?*/
playsound(src.loc, 'slash.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] has pushed back []!</B>", M, src), 1)
O.show_message(text("\red <B>[] has slashed at []!</B>", M, src), 1)
if(prob(8))
flick("noise", src.flash)
src.bruteloss += damage
src.updatehealth()
else
playsound(src.loc, 'slashmiss.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
O.show_message(text("\red <B>[] attempted to push back []!</B>", M, src), 1)
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] took a swipe at []!</B>", M, src), 1)
if ("disarm")
if(!(src.lying))
var/randn = rand(1, 100)
if (randn <= 85)
src.stunned = 5
step(src,get_dir(M,src))
spawn(5) step(src,get_dir(M,src))
playsound(src.loc, 'pierce.ogg', 50, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] has forced back []!</B>", M, src), 1)
else
playsound(src.loc, 'slashmiss.ogg', 25, 1, -1)
for(var/mob/O in viewers(src, null))
if ((O.client && !( O.blinded )))
O.show_message(text("\red <B>[] attempted to force back []!</B>", M, src), 1)
return
/mob/living/silicon/robot/attack_hand(mob/user)
-1
View File
@@ -240,7 +240,6 @@
if (src.client)
src.client.mob = O
O.loc = src.loc
O.a_intent = "hurt"
O << "<B>You are now an alien.</B>"
del(src)
return