upstream-merge-27852

This commit is contained in:
LetterJay
2017-06-11 00:20:55 -05:00
parent 4624ec7e04
commit 28d4372aa0
6 changed files with 102 additions and 16 deletions

View File

@@ -21,7 +21,7 @@
sharpness = IS_SHARP
var/list/trophies = list()
var/charged = TRUE
var/charge_time = 14
var/charge_time = 15
/obj/item/weapon/twohanded/required/mining_hammer/Destroy()
for(var/a in trophies)
@@ -92,16 +92,21 @@
for(var/t in trophies)
var/obj/item/crusher_trophy/T = t
T.on_mark_detonation(target, user)
new /obj/effect/temp_visual/kinetic_blast(get_turf(L))
var/backstab_dir = get_dir(user, L)
var/def_check = L.getarmor(type = "bomb")
if((user.dir & backstab_dir) && (L.dir & backstab_dir))
L.apply_damage(80, BRUTE, blocked = def_check)
playsound(user, 'sound/weapons/Kenetic_accel.ogg', 100, 1) //Seriously who spelled it wrong
else
L.apply_damage(50, BRUTE, blocked = def_check)
if(!QDELETED(C) && !QDELETED(L))
C.total_damage += target_health - L.health //we did some damage, but let's not assume how much we did
if(!QDELETED(L))
if(!QDELETED(C))
C.total_damage += target_health - L.health //we did some damage, but let's not assume how much we did
new /obj/effect/temp_visual/kinetic_blast(get_turf(L))
var/backstab_dir = get_dir(user, L)
var/def_check = L.getarmor(type = "bomb")
if((user.dir & backstab_dir) && (L.dir & backstab_dir))
if(!QDELETED(C))
C.total_damage += 80 //cheat a little and add the total before killing it, so certain mobs don't have much lower chances of giving an item
L.apply_damage(80, BRUTE, blocked = def_check)
playsound(user, 'sound/weapons/Kenetic_accel.ogg', 100, 1) //Seriously who spelled it wrong
else
if(!QDELETED(C))
C.total_damage += 50
L.apply_damage(50, BRUTE, blocked = def_check)
/obj/item/weapon/twohanded/required/mining_hammer/proc/Recharge()
if(!charged)
@@ -185,9 +190,70 @@
/obj/item/crusher_trophy/proc/on_mark_application(mob/living/target, datum/status_effect/crusher_mark/mark, had_mark) //the target, the mark applied, and if the target had a mark before
/obj/item/crusher_trophy/proc/on_mark_detonation(mob/living/target, mob/living/user) //the target and the user
//goliath
/obj/item/crusher_trophy/goliath_tentacle
name = "goliath tentacle"
desc = "A sliced-off goliath tentacle. Suitable as a trophy for a kinetic crusher."
icon_state = "goliath_tentacle"
denied_type = /obj/item/crusher_trophy/goliath_tentacle
bonus_value = 2
var/missing_health_ratio = 0.1
var/missing_health_desc = 10
/obj/item/crusher_trophy/goliath_tentacle/effect_desc()
return "mark detonation to do <b>[bonus_value]</b> more damage for every <b>[missing_health_desc]</b> health you are missing"
/obj/item/crusher_trophy/goliath_tentacle/on_mark_detonation(mob/living/target, mob/living/user)
var/missing_health = user.health - user.maxHealth
missing_health *= missing_health_ratio //bonus is active at all times, even if you're above 90 health
missing_health *= bonus_value //multiply the remaining amount by bonus_value
if(missing_health > 0)
target.adjustBruteLoss(missing_health) //and do that much damage
/watcher
/obj/item/crusher_trophy/watcher_wing
name = "watcher wing"
desc = "A wing ripped from a watcher. Suitable as a trophy for a kinetic crusher."
icon_state = "watcher_wing"
denied_type = /obj/item/crusher_trophy/watcher_wing
bonus_value = 8
/obj/item/crusher_trophy/watcher_wing/effect_desc()
return "mark detonation to prevent certain creatures from using certain attacks for <b>[bonus_value*0.1]</b> second[bonus_value*0.1 == 1 ? "":"s"]"
/obj/item/crusher_trophy/watcher_wing/on_mark_detonation(mob/living/target, mob/living/user)
if(ishostile(target))
var/mob/living/simple_animal/hostile/H = target
if(H.ranged) //briefly delay ranged attacks
if(H.ranged_cooldown_time >= world.time)
H.ranged_cooldown_time += bonus_value
else
H.ranged_cooldown_time = bonus_value + world.time
//legion
/obj/item/crusher_trophy/legion_skull
name = "legion skull"
desc = "A dead and lifeless legion skull. Suitable as a trophy for a kinetic crusher."
icon_state = "legion_skull"
denied_type = /obj/item/crusher_trophy/legion_skull
bonus_value = 3
/obj/item/crusher_trophy/legion_skull/effect_desc()
return "a kinetic crusher to recharge <b>[bonus_value*0.1]</b> second[bonus_value*0.1 == 1 ? "":"s"] faster"
/obj/item/crusher_trophy/legion_skull/add_to(obj/item/weapon/twohanded/required/mining_hammer/H, mob/living/user)
. = ..()
if(.)
H.charge_time -= bonus_value
/obj/item/crusher_trophy/legion_skull/remove_from(obj/item/weapon/twohanded/required/mining_hammer/H, mob/living/user)
. = ..()
if(.)
H.charge_time += bonus_value
//ash drake
/obj/item/crusher_trophy/tail_spike
desc = "A spike taken from a ash drake's tail."
desc = "A spike taken from a ash drake's tail. Suitable as a trophy for a kinetic crusher."
denied_type = /obj/item/crusher_trophy/tail_spike
bonus_value = 5
@@ -210,7 +276,7 @@
//bubblegum
/obj/item/crusher_trophy/demon_claws
name = "demon claws"
desc = "A set of blood-drenched claws from a massive demon's hand."
desc = "A set of blood-drenched claws from a massive demon's hand. Suitable as a trophy for a kinetic crusher."
icon_state = "demon_claws"
gender = PLURAL
denied_type = /obj/item/crusher_trophy/demon_claws
@@ -244,7 +310,7 @@
//colossus
/obj/item/crusher_trophy/blaster_tubes
name = "blaster tubes"
desc = "The blaster tubes from a colossus's arm."
desc = "The blaster tubes from a colossus's arm. Suitable as a trophy for a kinetic crusher."
icon_state = "blaster_tubes"
gender = PLURAL
denied_type = /obj/item/crusher_trophy/blaster_tubes
@@ -273,7 +339,7 @@
//hierophant
/obj/item/crusher_trophy/vortex_talisman
name = "vortex talisman"
desc = "A glowing trinket that was originally the Hierophant's beacon."
desc = "A glowing trinket that was originally the Hierophant's beacon. Suitable as a trophy for a kinetic crusher."
icon_state = "vortex_talisman"
denied_type = /obj/item/crusher_trophy/vortex_talisman

View File

@@ -76,5 +76,6 @@
stat_attack = UNCONSCIOUS
movement_type = FLYING
robust_searching = 1
crusher_loot = /obj/item/crusher_trophy/watcher_wing
loot = list()
butcher_results = list(/obj/item/weapon/ore/diamond = 2, /obj/item/stack/sheet/sinew = 2, /obj/item/stack/sheet/bone = 1)

View File

@@ -85,6 +85,7 @@
icon_dead = "goliath_dead"
throw_message = "does nothing to the tough hide of the"
pre_attack_icon = "goliath2"
crusher_loot = /obj/item/crusher_trophy/goliath_tentacle
butcher_results = list(/obj/item/weapon/reagent_containers/food/snacks/meat/slab/goliath = 2, /obj/item/stack/sheet/animalhide/goliath_hide = 1, /obj/item/stack/sheet/bone = 2)
loot = list()
stat_attack = UNCONSCIOUS

View File

@@ -46,6 +46,10 @@
OpenFire()
return TRUE
/mob/living/simple_animal/hostile/asteroid/hivelord/spawn_crusher_loot()
loot += crusher_loot //we don't butcher
/mob/living/simple_animal/hostile/asteroid/hivelord/death(gibbed)
mouse_opacity = 1
..(gibbed)
@@ -101,6 +105,7 @@
speak_emote = list("echoes")
attack_sound = 'sound/weapons/pierce.ogg'
throw_message = "bounces harmlessly off of"
crusher_loot = /obj/item/crusher_trophy/legion_skull
loot = list(/obj/item/organ/regenerative_core/legion)
brood_type = /mob/living/simple_animal/hostile/asteroid/hivelordbrood/legion
del_on_death = 1

View File

@@ -11,6 +11,7 @@
response_help = "pokes"
response_disarm = "shoves"
response_harm = "strikes"
var/crusher_loot
status_flags = 0
a_intent = INTENT_HARM
var/throw_message = "bounces off of"
@@ -19,6 +20,11 @@
lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE
mob_size = MOB_SIZE_LARGE
/mob/living/simple_animal/hostile/asteroid/Initialize(mapload)
. = ..()
apply_status_effect(STATUS_EFFECT_CRUSHERDAMAGETRACKING)
/mob/living/simple_animal/hostile/asteroid/Aggro()
..()
if(vision_range != aggro_vision_range)
@@ -44,14 +50,21 @@
if(!stat)
Aggro()
if(T.throwforce <= 20)
visible_message("<span class='notice'>The [T.name] [src.throw_message] [src.name]!</span>")
visible_message("<span class='notice'>The [T.name] [throw_message] [src.name]!</span>")
return
..()
/mob/living/simple_animal/hostile/asteroid/death(gibbed)
SSblackbox.add_details("mobs_killed_mining","[src.type]")
var/datum/status_effect/crusher_damage/C = has_status_effect(STATUS_EFFECT_CRUSHERDAMAGETRACKING)
if(C && crusher_loot && prob((C.total_damage/maxHealth)) * 5) //on average, you'll need to kill 20 creatures before getting the item
spawn_crusher_loot()
..(gibbed)
/mob/living/simple_animal/hostile/asteroid/proc/spawn_crusher_loot()
butcher_results[crusher_loot] = 1
/mob/living/simple_animal/hostile/asteroid/handle_temperature_damage()
if(bodytemperature < minbodytemp)
adjustBruteLoss(2)

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 18 KiB