Fixes some contents of some holodeck things not always getting the HOLOGRAM flag (#41487)

This commit is contained in:
ShizCalev
2018-11-16 06:39:18 -05:00
committed by Emmett Gaines
parent 415e54f20c
commit 490702aaa0
+9 -1
View File
@@ -4,7 +4,7 @@ GLOBAL_LIST_INIT(duplicate_forbidden_vars,list(
"power_supply", "contents", "reagents", "stat", "x", "y", "z", "group", "atmos_adjacent_turfs", "comp_lookup"
))
/proc/DuplicateObject(atom/original, perfectcopy = TRUE, sameloc = FALSE, atom/newloc = null, nerf = FALSE, holoitem=FALSE)
/proc/DuplicateObject(atom/original, perfectcopy = TRUE, sameloc, atom/newloc = null, nerf, holoitem)
if(!original)
return
var/atom/O
@@ -40,6 +40,14 @@ GLOBAL_LIST_INIT(duplicate_forbidden_vars,list(
if(holoitem)
O.flags_1 |= HOLOGRAM_1
for(var/atom/thing in O)
thing.flags_1 |= HOLOGRAM_1
if(ismachinery(O))
var/obj/machinery/M = O
for(var/atom/contained_atom in M.component_parts)
contained_atom.flags_1 |= HOLOGRAM_1
if(M.circuit)
M.circuit.flags_1 |= HOLOGRAM_1
return O