Merge branch 'master' into Ghommie-cit539

This commit is contained in:
Ghom
2020-02-14 19:42:36 +01:00
committed by GitHub
1641 changed files with 61259 additions and 20704 deletions
+8 -7
View File
@@ -90,6 +90,10 @@
var/decayedRange //stores original range
var/reflect_range_decrease = 5 //amount of original range that falls off when reflecting, so it doesn't go forever
var/is_reflectable = FALSE // Can it be reflected or not?
/// factor to multiply by for zone accuracy percent.
var/zone_accuracy_factor = 1
//Effects
var/stun = 0
var/knockdown = 0
@@ -185,10 +189,6 @@
else
new /obj/effect/temp_visual/dir_setting/bloodsplatter(target_loca, splatter_dir, bloodtype_to_color())
if(iscarbon(L) && !HAS_TRAIT(L, TRAIT_NOMARROW))
var/mob/living/carbon/C = L
C.bleed(damage)
else
L.add_splatter_floor(target_loca)
else if(impact_effect_type && !hitscan)
new impact_effect_type(target_loca, hitx, hity)
@@ -250,7 +250,8 @@
return TRUE
var/distance = get_dist(T, starting) // Get the distance between the turf shot from and the mob we hit and use that for the calculations.
def_zone = ran_zone(def_zone, max(100-(7*distance), 5)) //Lower accurancy/longer range tradeoff. 7 is a balanced number to use.
if(check_zone(def_zone) != BODY_ZONE_CHEST)
def_zone = ran_zone(def_zone, max(100-(7*distance), 5) * zone_accuracy_factor) //Lower accurancy/longer range tradeoff. 7 is a balanced number to use.
if(isturf(A) && hitsound_wall)
var/volume = CLAMP(vol_by_damage() + 20, 0, 100)
@@ -640,11 +641,11 @@
Bump(original)
/obj/item/projectile/Destroy()
STOP_PROCESSING(SSprojectiles, src)
if(hitscan)
finalize_hitscan_and_generate_tracers()
STOP_PROCESSING(SSprojectiles, src)
cleanup_beam_segments()
qdel(trajectory)
QDEL_NULL(trajectory)
return ..()
/obj/item/projectile/proc/cleanup_beam_segments()