Skip to content

Commit

Permalink
Fixes confetti shotgun shells (#174)
Browse files Browse the repository at this point in the history
* initial

* fix confetti shell

* donkpocket sprites and more

* this is for a different PR

* forgot these

* ..()

* reviews

* // instead of /// for overrides

---------

Co-authored-by: Bloop <[email protected]>
  • Loading branch information
2 people authored and Iajret committed Jan 3, 2024
1 parent ba9aaf5 commit 7b0ccb1
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 20 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@
item_type = /obj/item/ammo_box/advanced/s12gauge/antitide

/datum/armament_entry/company_import/vitezstvi/shot_shells/confetti
item_type = /obj/item/ammo_box/advanced/s12gauge/honk
item_type = /obj/item/ammo_box/advanced/s12gauge/honkshot

// Boxes of kiboko launcher ammo

Expand Down
8 changes: 4 additions & 4 deletions modular_nova/modules/shotgunrebalance/code/ammobox.dm
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,9 @@
ammo_type = /obj/item/ammo_casing/shotgun/incendiary
max_ammo = 15

/obj/item/ammo_box/advanced/s12gauge/honk
name = "Confetti ammo box"
desc = "A box of 35 shotgun shells. These ones contain harmless confetti, yippie!"
/obj/item/ammo_box/advanced/s12gauge/honkshot
name = "Confetti Honkshot ammo box"
desc = "A box of 35 shotgun shells."
icon_state = "honk"
ammo_type = /obj/item/ammo_casing/shotgun/honk
ammo_type = /obj/item/ammo_casing/shotgun/honkshot
max_ammo = 35
41 changes: 26 additions & 15 deletions modular_nova/modules/shotgunrebalance/code/shotgun.dm
Original file line number Diff line number Diff line change
Expand Up @@ -255,35 +255,33 @@
/obj/projectile/bullet/pellet/shotgun_improvised
weak_against_armour = TRUE // We will not have Improvised are Better 2.0

/obj/item/ammo_casing/shotgun/honk
/obj/item/ammo_casing/shotgun/honkshot
name = "confetti shell"
desc = "A 12 gauge buckshot shell thats been filled to the brim with confetti. Who is making all these?"
desc = "A 12 gauge buckshot shell thats been filled to the brim with confetti, yippie!"
icon_state = "honkshell"
projectile_type = /obj/projectile/bullet/pellet/shotgun_buckshot/honk
projectile_type = /obj/projectile/bullet/honkshot
pellets = 12
variance = 35
fire_sound = 'sound/items/bikehorn.ogg'
harmful = FALSE

/obj/projectile/bullet/pellet/shotgun_buckshot/honk
/obj/projectile/bullet/honkshot
name = "confetti"
damage = 0
stamina = 1
stamina_falloff_tile = 0
wound_bonus = 0
bare_wound_bonus = 0
sharpness = NONE
shrapnel_type = NONE
impact_effect_type = null
ricochet_chance = 0
jitter = 1 SECONDS
eyeblur = 1 SECONDS
sharpness = NONE
hitsound = SFX_CLOWN_STEP
range = 12
range = 4
icon_state = "guardian"
embedding = null

/obj/projectile/bullet/pellet/shotgun_buckshot/honk/Initialize(mapload)
/obj/projectile/bullet/honkshot/Initialize(mapload)
. = ..()
SpinAnimation()
range = rand(6, 12)
range = rand(1, 4)
color = pick(
COLOR_PRIDE_RED,
COLOR_PRIDE_ORANGE,
Expand All @@ -293,6 +291,19 @@
COLOR_PRIDE_PURPLE,
)

/obj/projectile/bullet/pellet/shotgun_buckshot/honk/on_range()
// This proc addition will spawn a decal on each tile the projectile travels over
/obj/projectile/bullet/honkshot/Moved(atom/old_loc, movement_dir, forced, list/old_locs, momentum_change = TRUE)
new /obj/effect/decal/cleanable/confetti(get_turf(old_loc))
return ..()

// This proc addition will make living humanoids do a flip animation when hit by the projectile
/obj/projectile/bullet/honkshot/on_hit(atom/target, blocked, pierce_hit)
if(!isliving(target))
return ..()
target.SpinAnimation(7,1)
return ..()

// This proc addition adds a spark effect when the projectile expires/hits
/obj/projectile/bullet/honkshot/on_range()
do_sparks(1, TRUE, src)
..()
return ..()

0 comments on commit 7b0ccb1

Please sign in to comment.