Skip to content

Commit

Permalink
blood drip randomization + ammo casings (#3731)
Browse files Browse the repository at this point in the history
mapping tools as title

:cl:
code: more spent casings + blood drips moving themselves on mapload
/:cl:
  • Loading branch information
Erikafox authored Nov 27, 2024
1 parent f34fdf9 commit 76f9f22
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 4 deletions.
10 changes: 10 additions & 0 deletions code/game/objects/effects/decals/cleanable/humans.dm
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,16 @@
var/drips = 1
dryname = "drips of blood"
drydesc = "It's red."
var/move_on_init = TRUE

/obj/effect/decal/cleanable/blood/drip/Initialize(mapload, list/datum/disease/diseases)
. = ..()
dry()
add_blood_DNA(list("Non-human DNA" = random_blood_type()))
if(move_on_init)
pixel_x = rand(-16,16)
pixel_y = rand(-16, 16)


/obj/effect/decal/cleanable/blood/drip/can_bloodcrawl_in()
return TRUE
Expand Down
45 changes: 41 additions & 4 deletions code/modules/projectiles/ammunition/_ammo_casing.dm
Original file line number Diff line number Diff line change
Expand Up @@ -153,10 +153,6 @@
ammo_stack.update_ammo_count()
return ammo_stack

/obj/item/ammo_casing/spent
name = "spent bullet casing"
BB = null

/obj/item/ammo_casing/Initialize()
. = ..()
if(projectile_type)
Expand Down Expand Up @@ -216,3 +212,44 @@

else if(location.bullet_bounce_sound)
addtimer(CALLBACK(GLOBAL_PROC, GLOBAL_PROC_REF(playsound), src, pick(location.bullet_bounce_sound), 20, 1), bounce_delay) //Soft / non-solid turfs that shouldn't make a sound when a shell casing is ejected over them.

/obj/item/ammo_casing/spent
name = "spent bullet casing"
projectile_type = null
BB = null

/obj/item/ammo_casing/spent/pistol_brass
icon_state = "pistol-brass"

/obj/item/ammo_casing/spent/pistol_steel
icon_state = "pistol-steel"

/obj/item/ammo_casing/spent/magnum_brass
icon_state = "magnum-brass"

/obj/item/ammo_casing/spent/magnum_steel
icon_state = "magnum-steel"

/obj/item/ammo_casing/spent/rifle_brass
icon_state = "rifle-brass"

/obj/item/ammo_casing/spent/rifle_steel
icon_state = "rifle-steel"

/obj/item/ammo_casing/spent/big_brass
icon_state = "big-brass"

/obj/item/ammo_casing/spent/big_steel
icon_state = "big-steel" //balls

/obj/item/ammo_casing/spent/slug
icon_state = "slug"

/obj/item/ammo_casing/spent/slug/buck
icon_state = "buckshot"

/obj/item/ammo_casing/spent/slug/beanbag
icon_state = "beanbag"

/obj/item/ammo_casing/spent/slug/rubber
icon_state = "rubber"

0 comments on commit 76f9f22

Please sign in to comment.