mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2026-08-28 07:39:13 +01:00
[MIRROR] Make simplemobs drop bones if leave remains are on (#12160)
Co-authored-by: tacoguy7765093 <karokaromaro@gmail.com>
This commit is contained in:
co-authored by
tacoguy7765093
parent
251e1abd98
commit
6ffeee0226
@@ -42,7 +42,7 @@
|
||||
skull_type = /obj/item/digestion_remains/skull/sergal
|
||||
|
||||
/obj/belly/proc/handle_remains_leaving(var/mob/living/M)
|
||||
if(!ishuman(M) && !isrobot(M)) //Are we even humanoid or a borg?
|
||||
if(!isliving(M)) //Are we even a living thing? (Sorry ghosts)
|
||||
return
|
||||
//Moving some vars here for both borgs and carbons to use
|
||||
var/bones_amount = rand(2,4) //some random variety in amount of bones left
|
||||
@@ -60,6 +60,21 @@
|
||||
new new_bone(src,owner)
|
||||
return //Dont need to do carbon stuff after this
|
||||
|
||||
if(ismouse(M)) //Mice dont have massive bones to leave behind
|
||||
return
|
||||
if(isanimal(M)) //If they are a simplemob
|
||||
var/list/organic_bones = list( //Generic bone variation system
|
||||
/obj/item/digestion_remains,
|
||||
/obj/item/digestion_remains/variant1,
|
||||
/obj/item/digestion_remains/variant2,
|
||||
/obj/item/digestion_remains/variant3
|
||||
)
|
||||
for(var/i = 1, i <= bones_amount, i++)
|
||||
var/new_bone = pick(organic_bones)
|
||||
new new_bone(src,owner)
|
||||
return
|
||||
|
||||
|
||||
var/mob/living/carbon/human/H = M
|
||||
|
||||
if((H.species.name in GLOB.remainless_species)) //Don't leave anything if there is nothing to leave
|
||||
|
||||
Reference in New Issue
Block a user