This commit is contained in:
Fox-McCloud
2015-01-15 19:42:15 -05:00
parent 342200d6fc
commit baa88a7463
18 changed files with 172 additions and 64 deletions
+5 -4
View File
@@ -202,9 +202,10 @@ update_flag
return
/obj/machinery/portable_atmospherics/canister/bullet_act(var/obj/item/projectile/Proj)
if(Proj.damage)
src.health -= round(Proj.damage / 2)
healthcheck()
if((Proj.damage_type == BRUTE || Proj.damage_type == BURN))
if(Proj.damage)
src.health -= round(Proj.damage / 2)
healthcheck()
..()
/obj/machinery/portable_atmospherics/canister/meteorhit(var/obj/O as obj)
@@ -252,7 +253,7 @@ update_flag
/obj/machinery/portable_atmospherics/canister/attack_paw(var/mob/user as mob)
return src.attack_hand(user)
/obj/machinery/portable_atmospherics/canister/attack_alien(mob/living/carbon/alien/humanoid/user)
return
+2 -2
View File
@@ -63,10 +63,10 @@
/obj/machinery/computer/bullet_act(var/obj/item/projectile/Proj)
if(prob(Proj.damage))
set_broken()
if((Proj.damage_type == BRUTE || Proj.damage_type == BURN))
set_broken()
..()
/obj/machinery/computer/blob_act()
if (prob(75))
for(var/x in verbs)
+4 -1
View File
@@ -369,8 +369,11 @@ Status: []<BR>"},
sleep(60)
attacked = 0
src.health -= Proj.damage
if((Proj.damage_type == BRUTE || Proj.damage_type == BURN))
health -= Proj.damage
..()
if(prob(45) && Proj.damage > 0) src.spark_system.start()
if (src.health <= 0)
src.die() // the death process :(
+7 -6
View File
@@ -275,12 +275,13 @@
popping = 0
/obj/machinery/turret/bullet_act(var/obj/item/projectile/Proj)
src.health -= Proj.damage
..()
if(prob(45) && Proj.damage > 0) src.spark_system.start()
del (Proj)
if (src.health <= 0)
src.die()
if((Proj.damage_type == BRUTE || Proj.damage_type == BURN))
src.health -= Proj.damage
..()
if(prob(45) && Proj.damage > 0) src.spark_system.start()
del(Proj)
if (src.health <= 0)
src.die()
return
/obj/machinery/turret/attackby(obj/item/weapon/W, mob/user)//I can't believe no one added this before/N
+5 -3
View File
@@ -260,7 +260,7 @@
if(do_after(melee_cooldown))
melee_can_hit = 1
return
/obj/mecha/proc/mech_toxin_damage(mob/living/target)
playsound(src, 'sound/effects/spray2.ogg', 50, 1)
if(target.reagents)
@@ -554,8 +554,10 @@
return
if(istype(Proj, /obj/item/projectile/beam/pulse))
ignore_threshold = 1
src.take_damage(Proj.damage,Proj.flag)
src.check_for_internal_damage(list(MECHA_INT_FIRE,MECHA_INT_TEMP_CONTROL,MECHA_INT_TANK_BREACH,MECHA_INT_CONTROL_LOST,MECHA_INT_SHORT_CIRCUIT),ignore_threshold)
if((Proj.damage_type == BRUTE || Proj.damage_type == BURN))
src.take_damage(Proj.damage,Proj.flag)
src.visible_message("<span class='danger'>[src.name] is hit by [Proj].</span>")
src.check_for_internal_damage(list(MECHA_INT_FIRE,MECHA_INT_TEMP_CONTROL,MECHA_INT_TANK_BREACH,MECHA_INT_CONTROL_LOST,MECHA_INT_SHORT_CIRCUIT),ignore_threshold)
Proj.on_hit(src)
return
+37
View File
@@ -19,6 +19,43 @@
return
*/
/obj/mecha/working/ripley/Destroy()
while(src.damage_absorption.["brute"] < 0.6)
new /obj/item/asteroid/goliath_hide(src.loc)
src.damage_absorption.["brute"] = src.damage_absorption.["brute"] + 0.1 //If a goliath-plated ripley gets killed, all the plates drop
for(var/atom/movable/A in src.cargo)
A.loc = loc
step_rand(A)
cargo.Cut()
..()
/obj/mecha/working/ripley/go_out()
..()
if (src.damage_absorption.["brute"] < 0.6 && src.damage_absorption.["brute"] > 0.3)
src.overlays = null
src.overlays += image("icon" = "mecha.dmi", "icon_state" = "ripley-g-open")
else if (src.damage_absorption.["brute"] == 0.3)
src.overlays = null
src.overlays += image("icon" = "mecha.dmi", "icon_state" = "ripley-g-full-open")
/obj/mecha/working/ripley/moved_inside(var/mob/living/carbon/human/H as mob)
..()
if (src.damage_absorption.["brute"] < 0.6 && src.damage_absorption.["brute"] > 0.3)
src.overlays = null
src.overlays += image("icon" = "mecha.dmi", "icon_state" = "ripley-g")
else if (src.damage_absorption.["brute"] == 0.3)
src.overlays = null
src.overlays += image("icon" = "mecha.dmi", "icon_state" = "ripley-g-full")
/obj/mecha/working/ripley/mmi_moved_inside(var/obj/item/device/mmi/mmi_as_oc as obj,mob/user as mob)
..()
if (src.damage_absorption.["brute"] < 0.6 && src.damage_absorption.["brute"] > 0.3)
src.overlays = null
src.overlays += image("icon" = "mecha.dmi", "icon_state" = "ripley-g")
else if (src.damage_absorption.["brute"] == 0.3)
src.overlays = null
src.overlays += image("icon" = "mecha.dmi", "icon_state" = "ripley-g-full")
/obj/mecha/working/ripley/firefighter
desc = "Standart APLU chassis was refitted with additional thermal protection and cistern."
name = "APLU \"Firefighter\""
@@ -155,13 +155,13 @@
qdel(src)
/obj/structure/closet/bullet_act(var/obj/item/projectile/Proj)
health -= Proj.damage
..()
if(health <= 0)
for(var/atom/movable/A as mob|obj in src)
A.loc = src.loc
del(src)
if((Proj.damage_type == BRUTE || Proj.damage_type == BURN))
health -= Proj.damage
if(health <= 0)
for(var/atom/movable/A as mob|obj in src)
A.loc = src.loc
del(src)
return
/obj/structure/closet/attack_animal(mob/living/simple_animal/user as mob)
@@ -273,7 +273,7 @@
else if(istype(W, /obj/item/weapon/weldingtool))
var/obj/item/weapon/weldingtool/WT = W
if(src == user.loc)
user << "<span class='notice'>You can not [welded?"unweld":"weld"] the locker from inside.</span>"
user << "<span class='notice'>You can not [welded?"unweld":"weld"] the locker from inside.</span>"
return
if(!WT.remove_fuel(0,user))
user << "<span class='notice'>You need more welding fuel to complete this task.</span>"
+5 -5
View File
@@ -69,16 +69,16 @@
/obj/structure/displaycase/captains_laser
name = "captain's display case"
desc = "A display case for the captain's antique laser gun. It taunts you to kick it."
desc = "A display case for the captain's antique laser gun. It taunts you to kick it."
/obj/structure/displaycase/captains_laser/New()
req_access = list(access_captain)
occupant = new /obj/item/weapon/gun/energy/laser/captain(src)
locked = 1
update_icon()
/obj/structure/proc/getPrint(mob/user as mob)
return md5(user:dna:uni_identity)
return md5(user:dna:uni_identity)
/obj/structure/displaycase/examine()
..()
@@ -112,12 +112,12 @@
/obj/structure/displaycase/bullet_act(var/obj/item/projectile/Proj)
health -= Proj.damage
if((Proj.damage_type == BRUTE || Proj.damage_type == BURN))
health -= Proj.damage
..()
src.healthcheck()
return
/obj/structure/displaycase/blob_act()
if (prob(75))
getFromPool(/obj/item/weapon/shard, loc)
+6 -9
View File
@@ -128,16 +128,13 @@
return !density
/obj/structure/grille/bullet_act(var/obj/item/projectile/Proj)
if(!Proj) return
//Tasers and the like should not damage grilles.
if(Proj.damage_type == STAMINA)
if(!Proj)
return
src.health -= Proj.damage*0.2
healthcheck()
return 0
..()
if((Proj.damage_type != STAMINA)) //Grilles can't be exhausted to death
src.health -= Proj.damage*0.3
healthcheck()
return
/obj/structure/grille/attackby(obj/item/weapon/W as obj, mob/user as mob)
if(iswirecutter(W))
+3 -5
View File
@@ -58,11 +58,9 @@ var/global/wcColored
// var/icon/silicateIcon = null // the silicated icon
/obj/structure/window/bullet_act(var/obj/item/projectile/Proj)
//Tasers and the like should not damage windows.
if(Proj.damage_type == STAMINA)
return
health -= Proj.damage
if((Proj.damage_type == BRUTE || Proj.damage_type == BURN))
health -= Proj.damage
update_nearby_icons()
..()
if(health <= 0)
var/pdiff=performWallPressureCheck(src.loc)
@@ -179,7 +179,8 @@
if(istype(P, /obj/item/projectile/energy) || istype(P, /obj/item/projectile/beam))
var/reflectchance = 80 - round(P.damage/3)
if(prob(reflectchance))
adjustBruteLoss(P.damage * 0.5)
if((P.damage_type == BRUTE || P.damage_type == BURN))
adjustBruteLoss(P.damage * 0.5)
visible_message("<span class='danger'>The [P.name] gets reflected by [src]'s shell!</span>", \
"<span class='userdanger'>The [P.name] gets reflected by [src]'s shell!</span>")
@@ -11,7 +11,7 @@
var/projectiletype
var/projectilesound
var/casingtype
var/move_to_delay = 2 //delay for the automated movement.
var/move_to_delay = 3 //delay for the automated movement.
var/list/friends = list()
var/vision_range = 9 //How big of an area to search for targets in, a vision of 9 attempts to find targets as soon as they walk into screen view
@@ -32,8 +32,8 @@
/mob/living/simple_animal/hostile/asteroid/bullet_act(var/obj/item/projectile/P)//Reduces damage from most projectiles to curb off-screen kills
if(!stat)
Aggro()
if(P.damage < 30)
P.damage = (P.damage / 2)
if(P.damage < 30 && P.damage_type != BRUTE)
P.damage = (P.damage / 3)
visible_message("<span class='danger'>The [P] has a reduced effect on [src]!</span>")
..()
@@ -42,7 +42,7 @@
var/obj/item/T = AM
if(!stat)
Aggro()
if(T.throwforce <= 15)
if(T.throwforce <= 20)
visible_message("<span class='notice'>The [T.name] [src.throw_message] [src.name]!</span>")
return
..()
@@ -76,6 +76,7 @@
ranged_cooldown_cap = 4
aggro_vision_range = 9
idle_vision_range = 2
turns_per_move = 5
/obj/item/projectile/temp/basilisk
name = "freezing blast"
@@ -123,13 +124,13 @@
icon_aggro = "Goldgrub_alert"
icon_dead = "Goldgrub_dead"
icon_gib = "syndicate_gib"
vision_range = 3
vision_range = 2
aggro_vision_range = 9
idle_vision_range = 3
move_to_delay = 3
idle_vision_range = 2
move_to_delay = 5
friendly = "harmlessly rolls into"
maxHealth = 60
health = 60
maxHealth = 45
health = 45
harm_intent_damage = 5
melee_damage_lower = 0
melee_damage_upper = 0
@@ -208,6 +209,10 @@
Reward()
..()
/mob/living/simple_animal/hostile/asteroid/goldgrub/adjustBruteLoss(var/damage)
idle_vision_range = 9
..()
/mob/living/simple_animal/hostile/asteroid/hivelord
name = "hivelord"
desc = "A truly alien creature, it is a mass of unknown organic material, constantly fluctuating. When attacking, pieces of it split off and attack in tandem with the original."
@@ -293,7 +298,7 @@
icon_dead = "Hivelordbrood"
icon_gib = "syndicate_gib"
mouse_opacity = 2
move_to_delay = 0
move_to_delay = 1
friendly = "buzzes near"
vision_range = 10
speed = 3
@@ -328,9 +333,10 @@
mouse_opacity = 2
move_to_delay = 40
ranged = 1
ranged_cooldown = 2 //By default, start the Goliath with his cooldown off so that people can run away quickly on first sight
ranged_cooldown_cap = 8
friendly = "wails at"
vision_range = 5
vision_range = 4
speed = 3
maxHealth = 300
health = 300
@@ -341,18 +347,50 @@
throw_message = "does nothing to the rocky hide of the"
aggro_vision_range = 9
idle_vision_range = 5
anchored = 1 //Stays anchored until death as to be unpullable
var/pre_attack = 0
/mob/living/simple_animal/hostile/asteroid/goliath/Life()
..()
handle_preattack()
/mob/living/simple_animal/hostile/asteroid/goliath/proc/handle_preattack()
if(ranged_cooldown <= 2 && !pre_attack)
pre_attack++
if(!pre_attack || stat || stance == HOSTILE_STANCE_IDLE)
return
icon_state = "Goliath_preattack"
/mob/living/simple_animal/hostile/asteroid/goliath/revive()
anchored = 1
..()
/mob/living/simple_animal/hostile/asteroid/goliath/Die()
anchored = 0
..()
/mob/living/simple_animal/hostile/asteroid/goliath/OpenFire()
visible_message("<span class='warning'>The [src.name] digs its tentacles under [target.name]!</span>")
var/tturf = get_turf(target)
new /obj/effect/goliath_tentacle/original(tturf)
ranged_cooldown = ranged_cooldown_cap
if(get_dist(src, target) <= 7)//Screen range check, so you can't get tentacle'd offscreen
visible_message("<span class='warning'>The [src.name] digs its tentacles under [target.name]!</span>")
new /obj/effect/goliath_tentacle/original(tturf)
ranged_cooldown = ranged_cooldown_cap
icon_state = icon_aggro
pre_attack = 0
return
/mob/living/simple_animal/hostile/asteroid/goliath/adjustBruteLoss(var/damage)
ranged_cooldown--
handle_preattack()
..()
/mob/living/simple_animal/hostile/asteroid/goliath/Aggro()
vision_range = aggro_vision_range
handle_preattack()
if(icon_state != icon_aggro)
icon_state = icon_aggro
return
/obj/effect/goliath_tentacle/
name = "Goliath tentacle"
icon = 'icons/mob/animal.dmi'
@@ -369,6 +407,9 @@
/obj/effect/goliath_tentacle/original
/obj/effect/goliath_tentacle/original/New()
for(var/obj/effect/goliath_tentacle/original/O in loc)//No more GG NO RE from 2+ goliaths simultaneously tentacling you
if(O != src)
qdel(src)
var/list/directions = cardinal.Copy()
var/counter
for(counter = 1, counter <= 3, counter++)
@@ -378,6 +419,7 @@
new /obj/effect/goliath_tentacle(T)
..()
/obj/effect/goliath_tentacle/proc/Trip()
for(var/mob/living/M in src.loc)
M.Weaken(5)
@@ -400,6 +442,7 @@
desc = "Pieces of a goliath's rocky hide, these might be able to make your suit a bit more durable to attack from the local fauna."
icon = 'icons/obj/items.dmi'
icon_state = "goliath_hide"
flags = NOBLUDGEON
w_class = 3
layer = 4
@@ -408,10 +451,31 @@
if(istype(target, /obj/item/clothing/suit/space/rig/mining) || istype(target, /obj/item/clothing/head/helmet/space/rig/mining))
var/obj/item/clothing/C = target
var/current_armor = C.armor
if(current_armor.["melee"] < 90)
current_armor.["melee"] = min(current_armor.["melee"] + 10, 90)
if(current_armor.["melee"] < 80)
current_armor.["melee"] = min(current_armor.["melee"] + 10, 80)
user << "<span class='info'>You strengthen [target], improving its resistance against melee attacks.</span>"
del(src)
else
user << "<span class='info'>You can't improve [C] any further.</span>"
return
return
if(istype(target, /obj/mecha/working/ripley))
var/obj/mecha/D = target
var/list/damage_absorption = D.damage_absorption
if(damage_absorption.["brute"] > 0.3)
damage_absorption.["brute"] = max(damage_absorption.["brute"] - 0.1, 0.3)
user << "<span class='info'>You strengthen [target], improving its resistance against melee attacks.</span>"
qdel(src)
if(D.icon_state == "ripley-open")
D.overlays += image("icon"="mecha.dmi", "icon_state"="ripley-g-open")
D.desc = "Autonomous Power Loader Unit. Its armour is enhanced with some goliath hide plates."
else
user << "<span class='info'>You can't add armour onto the mech while someone is inside!</span>"
if(damage_absorption.["brute"] == 0.3)
if(D.icon_state == "ripley-open")
D.overlays += image("icon"="mecha.dmi", "icon_state"="ripley-g-full-open")
D.desc = "Autonomous Power Loader Unit. It's wearing a fearsome carapace entirely composed of goliath hide plates - the pilot must be an experienced monster hunter."
else
user << "<span class='info'>You can't add armour onto the mech while someone is inside!</span>"
else
user << "<span class='info'>You can't improve [D] any further.</span>"
return
@@ -75,7 +75,8 @@
/mob/living/simple_animal/hostile/syndicate/melee/bullet_act(var/obj/item/projectile/Proj)
if(!Proj) return
if(prob(65))
src.health -= Proj.damage
if((Proj.damage_type == BRUTE || Proj.damage_type == BURN))
src.health -= Proj.damage
else
visible_message("\red <B>[src] blocks [Proj] with its shield!</B>")
return 0
@@ -56,7 +56,7 @@
var/friendly = "nuzzles" //If the mob does no damage with it's attack
var/environment_smash = 0 //Set to 1 to allow breaking of crates,lockers,racks,tables; 2 for walls; 3 for Rwalls
var/speed = 0 //LETS SEE IF I CAN SET SPEEDS FOR SIMPLE MOBS WITHOUT DESTROYING EVERYTHING. Higher speed is slower, negative speed is faster
var/speed = 1 //LETS SEE IF I CAN SET SPEEDS FOR SIMPLE MOBS WITHOUT DESTROYING EVERYTHING. Higher speed is slower, negative speed is faster
var/can_hide = 0
//Hot simple_animal baby making vars
@@ -251,8 +251,11 @@
adjustBruteLoss(damage)
/mob/living/simple_animal/bullet_act(var/obj/item/projectile/Proj)
if(!Proj) return
adjustBruteLoss(Proj.damage)
if(!Proj)
return
if((Proj.damage_type != STAMINA))
adjustBruteLoss(Proj.damage)
Proj.on_hit(src, 0)
return 0
/mob/living/simple_animal/attack_hand(mob/living/carbon/human/M as mob)