mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-15 20:22:07 +00:00
[NEW GHOST ANTAG] The Paradox Clone (#71141)

[DESIGN DOC]
https://hackmd.io/@tGKknGe5Q7qtddEspif79g/BJ3w9QLri/edit
Bluespace technology has destabilized the very fabric of reality, even
time itself!
Sometimes during a shift, it's possible for a PARADOX CLONE to spawn
somewhere on the station (usually maintenance). This paradox clone has
the exact appearance and DNA as a random crew member on the station,
wearing the same clothes they were at the start of the shift, including
their ID.
To maintain timeline coherency, the paradox clone must now hunt down and
kill the original and take their place or die trying, if the original
survives they have failed.
The only thing the paradox clone spawns with is a mechanical toolbox
that helps them from being stuck in maints if their ID doesn't have
maints access.
The inclusion of this antag encourages good crew coordination and adds a
less destructive, more personalized antag to the roster.
This antag rewards good detective work, as both the clone and the
original are identical in every way, and will therefore require a
detective to break out their detective skills to figure out who the
clone is.
Also a possible tie-in with the Chrono Legionnaires in the future.
🆑
add: Time and space has destabilized even further due to Nanotrasen
bluespace research, now, on occasion, clones from different timelines
can appear on the station and hunt you down to maintain timeline
stability! Beware the Paradox Clone!
/🆑
---------
Co-authored-by: 1bw0kopy <xz2rbf23@protonmail.com>
Co-authored-by: MrMelbert <51863163+MrMelbert@users.noreply.github.com>
Co-authored-by: John Willard <53777086+JohnFulpWillard@users.noreply.github.com>
Co-authored-by: Jeremiah <42397676+jlsnow301@users.noreply.github.com>
(cherry picked from commit 214174874c)
Co-authored-by: Shadyyy66 <114319683+Shadyyy66@users.noreply.github.com>
98 lines
2.8 KiB
Plaintext
98 lines
2.8 KiB
Plaintext
///List of all vars that will not be copied over when using duplicate_object()
|
|
GLOBAL_LIST_INIT(duplicate_forbidden_vars, list(
|
|
"AIStatus",
|
|
"actions",
|
|
"active_hud_list",
|
|
"active_timers",
|
|
"appearance",
|
|
"area",
|
|
"atmos_adjacent_turfs",
|
|
"bodyparts",
|
|
"ckey",
|
|
"client_mobs_in_contents",
|
|
"comp_lookup",
|
|
"computer_id",
|
|
"contents",
|
|
"cooldowns",
|
|
"datum_components",
|
|
"external_organs",
|
|
"external_organs_slot",
|
|
"group",
|
|
"hand_bodyparts",
|
|
"held_items",
|
|
"hud_list",
|
|
"implants",
|
|
"important_recursive_contents",
|
|
"internal_organs",
|
|
"internal_organs_slot",
|
|
"key",
|
|
"lastKnownIP",
|
|
"loc",
|
|
"locs",
|
|
"managed_overlays",
|
|
"managed_vis_overlays",
|
|
"overlays",
|
|
"overlays_standing",
|
|
"parent",
|
|
"parent_type",
|
|
"power_supply",
|
|
"quirks",
|
|
"reagents",
|
|
"signal_procs",
|
|
"stat",
|
|
"status_effects",
|
|
"status_traits",
|
|
"tag",
|
|
"tgui_shared_states",
|
|
"type",
|
|
"update_on_z",
|
|
"vars",
|
|
"verbs",
|
|
"x", "y", "z",
|
|
))
|
|
GLOBAL_PROTECT(duplicate_forbidden_vars)
|
|
|
|
/**
|
|
* # duplicate_object
|
|
*
|
|
* Makes a copy of an item and transfers most vars over, barring GLOB.duplicate_forbidden_vars
|
|
* Args:
|
|
* original - Atom being duplicated
|
|
* spawning_location - Turf where the duplicated atom will be spawned at.
|
|
*/
|
|
/proc/duplicate_object(atom/original, turf/spawning_location)
|
|
RETURN_TYPE(original.type)
|
|
if(!original)
|
|
return
|
|
|
|
var/atom/made_copy = new original.type(spawning_location)
|
|
|
|
for(var/atom_vars in original.vars - GLOB.duplicate_forbidden_vars)
|
|
if(islist(original.vars[atom_vars]))
|
|
var/list/var_list = original.vars[atom_vars]
|
|
made_copy.vars[atom_vars] = var_list.Copy()
|
|
continue
|
|
else if(istype(original.vars[atom_vars], /datum) || ismob(original.vars[atom_vars]))
|
|
continue // this would reference the original's object, that will break when it is used or deleted.
|
|
made_copy.vars[atom_vars] = original.vars[atom_vars]
|
|
|
|
if(isliving(made_copy))
|
|
if(iscarbon(made_copy))
|
|
var/mob/living/carbon/original_carbon = original
|
|
var/mob/living/carbon/copied_carbon = made_copy
|
|
//transfer DNA over (also body features), then update skin color.
|
|
original_carbon.dna.copy_dna(copied_carbon.dna)
|
|
copied_carbon.updateappearance(mutcolor_update = TRUE)
|
|
|
|
var/mob/living/original_living = original
|
|
var/mob/living/copied_living = made_copy
|
|
//transfer implants, we do this so the original's implants being removed won't destroy ours.
|
|
for(var/obj/item/implant/original_implants as anything in original_living.implants)
|
|
var/obj/item/implant/copied_implant = new original_implants.type
|
|
copied_implant.implant(made_copy, silent = TRUE, force = TRUE)
|
|
//transfer quirks, we do this because transfering the original's quirks keeps the 'owner' as the original.
|
|
for(var/datum/quirk/original_quirks as anything in original_living.quirks)
|
|
copied_living.add_quirk(original_quirks.type)
|
|
|
|
return made_copy
|