Adds mercenary sniper rifle

Adds the scoped mercenary sniper rifle and ammunition defines. Does not
add syndicate uplink option.
This commit is contained in:
mwerezak
2015-02-14 21:57:22 -05:00
parent 13ca926c0f
commit ad24aa8e47
11 changed files with 50 additions and 29 deletions

View File

@@ -128,7 +128,7 @@
xo = new_x - starting_loc.x
//Called when the projectile intercepts a mob. Returns 1 if the projectile hit the mob, 0 if it missed and should keep flying.
/obj/item/projectile/proc/attack_mob(var/mob/living/target_mob, var/distance, var/miss_modifier = -30)
/obj/item/projectile/proc/attack_mob(var/mob/living/target_mob, var/distance, var/miss_modifier)
//accuracy bonus from aiming
if (istype(shot_from, /obj/item/weapon/gun)) //If you aim at someone beforehead, it'll hit more often.
var/obj/item/weapon/gun/daddy = shot_from //Kinda balanced by fact you need like 2 seconds to aim
@@ -137,7 +137,7 @@
miss_modifier += -30
//roll to-hit
var/hit_zone = get_zone_with_miss_chance(def_zone, target_mob, max(miss_modifier + 15*distance, 0))
var/hit_zone = get_zone_with_miss_chance(def_zone, target_mob, max(miss_modifier + 15*(distance-2), 0))
if(!hit_zone)
visible_message("<span class='notice'>\The [src] misses [target_mob] narrowly!</span>")
return 0