Skip to content

Commit

Permalink
Shotgun Overhaul (#304)
Browse files Browse the repository at this point in the history
Co-authored-by: AndroBetel <[email protected]>
  • Loading branch information
AmoryBlaine and AndroBetel authored Aug 28, 2024
1 parent 28c01ab commit f384b96
Show file tree
Hide file tree
Showing 28 changed files with 311 additions and 336 deletions.
154 changes: 107 additions & 47 deletions code/datums/ammo/bullet/shotgun.dm
Original file line number Diff line number Diff line change
Expand Up @@ -11,28 +11,30 @@
name = "shotgun slug"
handful_state = "slug_shell"

accurate_range = 6
max_range = 8
damage = 70
penetration = ARMOR_PENETRATION_TIER_4
accurate_range = 7
max_range = 14
damage = 90
penetration = ARMOR_PENETRATION_TIER_6
damage_var_low = PROJECTILE_VARIANCE_TIER_10
damage_var_high = PROJECTILE_VARIANCE_TIER_1
damage_armor_punch = 2
handful_state = "slug_shell"

/datum/ammo/bullet/shotgun/slug/on_hit_mob(mob/M,obj/projectile/P)
knockback(M, P, 6)
knockback(M, P, 8)

/datum/ammo/bullet/shotgun/slug/knockback_effects(mob/living/living_mob, obj/projectile/fired_projectile)
if(iscarbonsizexeno(living_mob))
var/mob/living/carbon/xenomorph/target = living_mob
to_chat(target, SPAN_XENODANGER("You are shaken and slowed by the sudden impact!"))
target.KnockDown(0.5) // If you ask me the KD should be left out, but players like their visual cues
target.Stun(0.5)
target.apply_effect(1, SUPERSLOW)
target.apply_effect(3, SLOW)
target.KnockDown(3.5)
target.Stun(3.5)
target.Slow(5)
else
if(!isyautja(living_mob)) //Not predators.
living_mob.apply_effect(1, SUPERSLOW)
living_mob.apply_effect(2, SLOW)
living_mob.KnockDown(2)
living_mob.Stun(2)
living_mob.Superslow(5)
to_chat(living_mob, SPAN_HIGHDANGER("The impact knocks you off-balance!"))
living_mob.apply_stamina_damage(fired_projectile.ammo.damage, fired_projectile.def_zone, ARMOR_BULLET)

Expand All @@ -42,11 +44,9 @@
handful_state = "beanbag_slug"
icon_state = "beanbag"
flags_ammo_behavior = AMMO_BALLISTIC|AMMO_IGNORE_RESIST
sound_override = 'sound/weapons/gun_shotgun_riot.ogg'

max_range = 12
shrapnel_chance = 0
damage = 0
damage = 20
stamina_damage = 45
accuracy = HIT_ACCURACY_TIER_3
shell_speed = AMMO_SPEED_TIER_3
Expand Down Expand Up @@ -127,19 +127,36 @@

accuracy_var_low = PROJECTILE_VARIANCE_TIER_5
accuracy_var_high = PROJECTILE_VARIANCE_TIER_5
accurate_range = 4
max_range = 4
damage = 65
damage_var_low = PROJECTILE_VARIANCE_TIER_8
damage_var_high = PROJECTILE_VARIANCE_TIER_8
accurate_range = 7
max_range = 9
damage = 50
damage_var_low = PROJECTILE_VARIANCE_TIER_10
damage_var_high = PROJECTILE_VARIANCE_TIER_1
penetration = ARMOR_PENETRATION_TIER_1
bonus_projectiles_amount = EXTRA_PROJECTILES_TIER_3
bonus_projectiles_amount = EXTRA_PROJECTILES_TIER_7
shell_speed = AMMO_SPEED_TIER_2
damage_armor_punch = 0
pen_armor_punch = 0
handful_state = "buckshot_shell"
multiple_handful_name = TRUE

/datum/ammo/bullet/shotgun/buckshot/on_hit_mob(mob/M,obj/projectile/P)
knockback(M, P, 4)
/datum/ammo/bullet/shotgun/buckshot/knockback_effects(mob/living/living_mob, obj/projectile/fired_projectile)
if(iscarbonsizexeno(living_mob))
var/mob/living/carbon/xenomorph/target = living_mob
to_chat(target, SPAN_XENODANGER("You are shaken and slowed by the sudden impact!"))
target.KnockDown(2.5)
target.Stun(2.5)
target.Slow(4)
else
if(!isyautja(living_mob)) //Not predators.
living_mob.KnockDown(3)
living_mob.Stun(3)
living_mob.Slow(5)
to_chat(living_mob, SPAN_HIGHDANGER("The impact knocks you off-balance!"))
living_mob.apply_stamina_damage(fired_projectile.ammo.damage, fired_projectile.def_zone, ARMOR_BULLET)

/datum/ammo/bullet/shotgun/buckshot/incendiary
name = "incendiary buckshot shell"
handful_state = "incen_buckshot"
Expand Down Expand Up @@ -178,8 +195,8 @@
accuracy_var_low = PROJECTILE_VARIANCE_TIER_6
accuracy_var_high = PROJECTILE_VARIANCE_TIER_6
accurate_range = 4
max_range = 4
damage = 65
max_range = 6
damage = 50
damage_var_low = PROJECTILE_VARIANCE_TIER_8
damage_var_high = PROJECTILE_VARIANCE_TIER_8
penetration = ARMOR_PENETRATION_TIER_1
Expand All @@ -191,6 +208,23 @@
/datum/ammo/bullet/shotgun/spread/masterkey
damage = 20

/datum/ammo/bullet/shotgun/spread/on_hit_mob(mob/M,obj/projectile/P)
knockback(M, P, 4)
/datum/ammo/bullet/shotgun/spread/knockback_effects(mob/living/living_mob, obj/projectile/fired_projectile)
if(iscarbonsizexeno(living_mob))
var/mob/living/carbon/xenomorph/target = living_mob
to_chat(target, SPAN_XENODANGER("You are shaken and slowed by the sudden impact!"))
target.KnockDown(2.5)
target.Stun(2.5)
target.Slow(4)
else
if(!isyautja(living_mob)) //Not predators.
living_mob.KnockDown(3)
living_mob.Stun(3)
living_mob.Slow(5)
to_chat(living_mob, SPAN_HIGHDANGER("The impact knocks you off-balance!"))
living_mob.apply_stamina_damage(fired_projectile.ammo.damage, fired_projectile.def_zone, ARMOR_BULLET)

/datum/ammo/bullet/shotgun/spread/special
name = "additional buckshot, USCM special type"

Expand All @@ -209,24 +243,53 @@
handful_state = "heavy_buckshot"
multiple_handful_name = TRUE
bonus_projectiles_type = /datum/ammo/bullet/shotgun/heavy/buckshot/spread
bonus_projectiles_amount = EXTRA_PROJECTILES_TIER_3
accurate_range = 3
max_range = 3
bonus_projectiles_amount = EXTRA_PROJECTILES_TIER_8
accurate_range = 8
max_range = 10
damage = 75
penetration = 0
penetration = ARMOR_PENETRATION_TIER_2
shell_speed = AMMO_SPEED_TIER_2
damage_armor_punch = 0
pen_armor_punch = 0

/datum/ammo/bullet/shotgun/heavy/buckshot/on_hit_mob(mob/M,obj/projectile/P)
knockback(M,P)
knockback(M,P,5)
/datum/ammo/bullet/shotgun/heavy/buckshot/knockback_effects(mob/living/living_mob, obj/projectile/fired_projectile)
if(iscarbonsizexeno(living_mob))
var/mob/living/carbon/xenomorph/target = living_mob
to_chat(target, SPAN_XENODANGER("You are shaken and slowed by the sudden impact!"))
target.KnockDown(5)
target.Stun(5)
target.Slow(8)
else
if(!isyautja(living_mob)) //Not predators.
living_mob.KnockDown(2)
living_mob.Stun(2)
living_mob.Slow(6)
to_chat(living_mob, SPAN_HIGHDANGER("The impact knocks you off-balance!"))
living_mob.apply_stamina_damage(fired_projectile.ammo.damage, fired_projectile.def_zone, ARMOR_BULLET)

/datum/ammo/bullet/shotgun/heavy/buckshot/spread
name = "additional heavy buckshot"
max_range = 4
max_range = 7
scatter = SCATTER_AMOUNT_TIER_1
bonus_projectiles_amount = 0

/datum/ammo/bullet/shotgun/heavy/buckshot/spread/knockback_effects(mob/living/living_mob, obj/projectile/fired_projectile)
if(iscarbonsizexeno(living_mob))
var/mob/living/carbon/xenomorph/target = living_mob
to_chat(target, SPAN_XENODANGER("You are shaken and slowed by the sudden impact!"))
target.KnockDown(5)
target.Stun(5)
target.Slow(8)
else
if(!isyautja(living_mob)) //Not predators.
living_mob.KnockDown(2)
living_mob.Stun(2)
living_mob.Slow(6)
to_chat(living_mob, SPAN_HIGHDANGER("The impact knocks you off-balance!"))
living_mob.apply_stamina_damage(fired_projectile.ammo.damage, fired_projectile.def_zone, ARMOR_BULLET)

/datum/ammo/bullet/shotgun/heavy/buckshot/special
bonus_projectiles_type = /datum/ammo/bullet/shotgun/heavy/buckshot/spread/special
bonus_projectiles_amount = EXTRA_PROJECTILES_TIER_8
Expand All @@ -251,8 +314,8 @@
multiple_handful_name = TRUE
damage_type = BURN
damage = 60
accurate_range = 3
max_range = 4
accurate_range = 4
max_range = 6
bonus_projectiles_type = /datum/ammo/bullet/shotgun/heavy/buckshot/dragonsbreath/spread

/datum/ammo/bullet/shotgun/heavy/buckshot/dragonsbreath/set_bullet_traits()
Expand All @@ -264,36 +327,34 @@
/datum/ammo/bullet/shotgun/heavy/buckshot/dragonsbreath/spread
name = "additional dragon's breath"
bonus_projectiles_amount = 0
accurate_range = 4
max_range = 5 //make use of the ablaze property
shell_speed = AMMO_SPEED_TIER_4 // so they hit before the main shell stuns
shell_speed = AMMO_SPEED_TIER_4


/datum/ammo/bullet/shotgun/heavy/slug
name = "heavy shotgun slug"
handful_state = "heavy_slug"

accurate_range = 7
max_range = 8
damage = 90 //ouch.
penetration = ARMOR_PENETRATION_TIER_6
max_range = 17
damage = 120 //ouch.
penetration = ARMOR_PENETRATION_TIER_9
damage_armor_punch = 2

/datum/ammo/bullet/shotgun/heavy/slug/on_hit_mob(mob/M,obj/projectile/P)
knockback(M, P, 7)
knockback(M, P, 8)

/datum/ammo/bullet/shotgun/heavy/slug/knockback_effects(mob/living/living_mob, obj/projectile/fired_projectile)
if(iscarbonsizexeno(living_mob))
var/mob/living/carbon/xenomorph/target = living_mob
to_chat(target, SPAN_XENODANGER("You are shaken and slowed by the sudden impact!"))
target.KnockDown(0.5) // If you ask me the KD should be left out, but players like their visual cues
target.Stun(0.5)
target.apply_effect(2, SUPERSLOW)
target.apply_effect(5, SLOW)
target.KnockDown(7)
target.Stun(7)
target.Slow(10)
else
if(!isyautja(living_mob)) //Not predators.
living_mob.apply_effect(1, SUPERSLOW)
living_mob.apply_effect(2, SLOW)
living_mob.KnockDown(8)
living_mob.Stun(8)
living_mob.Superslow(15)
to_chat(living_mob, SPAN_HIGHDANGER("The impact knocks you off-balance!"))
living_mob.apply_stamina_damage(fired_projectile.ammo.damage, fired_projectile.def_zone, ARMOR_BULLET)

Expand All @@ -303,14 +364,13 @@
headshot_state = HEADSHOT_OVERLAY_MEDIUM
handful_state = "heavy_beanbag"
flags_ammo_behavior = AMMO_BALLISTIC|AMMO_IGNORE_RESIST
sound_override = 'sound/weapons/gun_shotgun_riot.ogg'

max_range = 7
shrapnel_chance = 0
damage = 0
damage = 25
stamina_damage = 100
accuracy = HIT_ACCURACY_TIER_2
shell_speed = AMMO_SPEED_TIER_2
accuracy = HIT_ACCURACY_TIER_6
shell_speed = 3

/datum/ammo/bullet/shotgun/heavy/beanbag/on_hit_mob(mob/M, obj/projectile/P)
if(!M || M == P.firer)
Expand Down
2 changes: 1 addition & 1 deletion code/datums/supply_packs/black_market.dm
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ Non-USCM items, from CLF, UPP, colonies, etc. Mostly combat-related.
new /obj/item/ammo_magazine/smg/mac15(src)
new /obj/item/ammo_magazine/smg/mac15(src)
if(4) //upp
new /obj/item/weapon/gun/shotgun/type23/riot_control(src)
new /obj/item/weapon/gun/shotgun/type23/riot(src)
new /obj/item/ammo_magazine/handful/shotgun/heavy/beanbag(src)
new /obj/item/ammo_magazine/handful/shotgun/heavy/beanbag(src)
new /obj/item/ammo_magazine/handful/shotgun/heavy/flechette(src)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,7 @@ GLOBAL_LIST_INIT(cm_vending_clothing_chief_engineer, list(
list("Heat Absorbent Coif", 0, /obj/item/clothing/mask/rebreather/scarf, MARINE_CAN_BUY_MASK, VENDOR_ITEM_REGULAR),

list("PRIMARY FIREARMS (CHOOSE 1)", 0, null, null, null),
list("M37A2 Pump Shotgun", 0, /obj/item/storage/box/guncase/pumpshotgun, MARINE_CAN_BUY_ESSENTIALS, VENDOR_ITEM_REGULAR),
list("M120 Tactical Shotgun", 0, /obj/item/storage/box/guncase/shotguncombat, MARINE_CAN_BUY_ESSENTIALS, VENDOR_ITEM_REGULAR),
list("M41A Pulse Rifle MK2", 0, /obj/item/storage/box/guncase/m41a, MARINE_CAN_BUY_ESSENTIALS, VENDOR_ITEM_REGULAR),
list("M240 Incinerator Unit", 0, /obj/item/storage/box/guncase/flamer, MARINE_CAN_BUY_ESSENTIALS, VENDOR_ITEM_REGULAR),

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,10 @@
new /obj/item/weapon/shield/riot(src)
new /obj/item/weapon/shield/riot(src)
new /obj/item/weapon/shield/riot(src)
new /obj/item/ammo_magazine/shotgun/beanbag/riot(src)
new /obj/item/ammo_magazine/shotgun/beanbag/riot(src)
new /obj/item/ammo_magazine/shotgun/beanbag/riot(src)
new /obj/item/ammo_magazine/shotgun/beanbag/riot(src)
new /obj/item/ammo_magazine/shotgun/beanbag(src)
new /obj/item/ammo_magazine/shotgun/beanbag(src)
new /obj/item/ammo_magazine/shotgun/beanbag(src)
new /obj/item/ammo_magazine/shotgun/beanbag(src)
new /obj/item/weapon/gun/launcher/grenade/m81/riot(src, TRUE)
new /obj/item/storage/box/nade_box/tear_gas(src)
new /obj/item/clothing/mask/gas(src)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@
new /obj/item/weapon/shield/riot(src)
new /obj/item/weapon/shield/riot(src)
new /obj/item/weapon/shield/riot(src)
new /obj/item/ammo_magazine/shotgun/beanbag/riot(src)
new /obj/item/ammo_magazine/shotgun/beanbag/riot(src)
new /obj/item/ammo_magazine/shotgun/beanbag/riot(src)
new /obj/item/ammo_magazine/shotgun/beanbag/riot(src)
new /obj/item/ammo_magazine/shotgun/beanbag(src)
new /obj/item/ammo_magazine/shotgun/beanbag(src)
new /obj/item/ammo_magazine/shotgun/beanbag(src)
new /obj/item/ammo_magazine/shotgun/beanbag(src)
new /obj/item/weapon/gun/launcher/grenade/m81/riot(src, TRUE)
new /obj/item/storage/box/nade_box/tear_gas(src)
new /obj/item/clothing/mask/gas(src)
Expand Down
Loading

0 comments on commit f384b96

Please sign in to comment.