Skip to content

Commit

Permalink
small things
Browse files Browse the repository at this point in the history
  • Loading branch information
Zonespace27 committed Aug 24, 2023
1 parent aa87803 commit 7703890
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion code/modules/cm_marines/equipment/guncases.dm
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@
name = "\improper M707 anti-materiel rifle case"
desc = "A gun case containing the M707 \"Vulture\" anti-materiel rifle and its requisite spotting tools."
icon_state = "guncase_blue"
storage_slots = 7
storage_slots = 5
can_hold = list(
/obj/item/weapon/gun/boltaction/vulture,
/obj/item/ammo_magazine/rifle/boltaction/vulture,
Expand Down
3 changes: 2 additions & 1 deletion code/modules/projectiles/ammo_datums.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1623,7 +1623,8 @@

/datum/ammo/bullet/sniper/anti_materiel/vulture
damage = 400 // Fully intended to vaporize anything smaller than a mini cooper
accurate_range_min = 10 // yeah.
accurate_range_min = 10
accuracy_range_falloff = 50
handful_state = "vulture_bullet"

/datum/ammo/bullet/sniper/anti_materiel/vulture/set_bullet_traits()
Expand Down
2 changes: 2 additions & 0 deletions code/modules/projectiles/gun_attachables.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1453,6 +1453,8 @@ Defined in conflicts.dm of the #defines folder.

/obj/item/attachable/vulture_scope/proc/on_unscope()
SIGNAL_HANDLER
if(!scope_user)
return

var/mob/scoper = scope_user.resolve()
if(isgun(loc))
Expand Down
4 changes: 3 additions & 1 deletion code/modules/projectiles/projectile.dm
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,8 @@

/// The flicker that plays when a bullet hits a target. Usually red. Can be nulled so it doesn't show up at all.
var/hit_effect_color = "#FF0000"
/// How much to make the bullet fall off by accuracy-wise when closer than the ideal range
var/accuracy_range_falloff = 10

/obj/item/projectile/Initialize(mapload, datum/cause_data/cause_data)
. = ..()
Expand Down Expand Up @@ -534,7 +536,7 @@
var/ammo_flags = ammo.flags_ammo_behavior | projectile_override_flags
if(distance_travelled <= ammo.accurate_range)
if(distance_travelled <= ammo.accurate_range_min) // If bullet stays within max accurate range + random variance
effective_accuracy -= (ammo.accurate_range_min - distance_travelled) * 10 // Snipers have accuracy falloff at closer range before point blank
effective_accuracy -= (ammo.accurate_range_min - distance_travelled) * accuracy_range_falloff // Snipers have accuracy falloff at closer range before point blank
else
effective_accuracy -= (distance_travelled - ammo.accurate_range) * ((ammo_flags & AMMO_SNIPER) ? 1.5 : 10) // Snipers have a smaller falloff constant due to longer max range

Expand Down

0 comments on commit 7703890

Please sign in to comment.