mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-24 05:30:05 +01:00
DNA Infusers now check for a datum trait instead of whether non-living objects are edible and have the GORE food type. (#87154)
This commit is contained in:
@@ -135,6 +135,7 @@
|
||||
#include "dcs_get_id_from_elements.dm"
|
||||
#include "designs.dm"
|
||||
#include "dismemberment.dm"
|
||||
#include "dna_infusion.dm"
|
||||
#include "door_access.dm"
|
||||
#include "dragon_expiration.dm"
|
||||
#include "drink_icons.dm"
|
||||
@@ -211,7 +212,6 @@
|
||||
#include "operating_table.dm"
|
||||
#include "orderable_items.dm"
|
||||
#include "organ_bodypart_shuffle.dm"
|
||||
#include "organ_set_bonus.dm"
|
||||
#include "organs.dm"
|
||||
#include "orphaned_genturf.dm"
|
||||
#include "outfit_sanity.dm"
|
||||
|
||||
@@ -1,3 +1,16 @@
|
||||
///Check that input types that aren't living mobs have the TRAIT_VALID_DNA_INFUSION trait
|
||||
/datum/unit_test/valid_dna_infusion
|
||||
|
||||
/datum/unit_test/valid_dna_infusion/Run()
|
||||
for(var/datum/infuser_entry/infuser_entry as anything in flatten_list(GLOB.infuser_entries))
|
||||
for(var/input_type as anything in infuser_entry.input_obj_or_mob)
|
||||
if(ispath(input_type, /mob/living))
|
||||
continue
|
||||
var/atom/movable/movable = allocate(input_type)
|
||||
if(!HAS_TRAIT(movable, TRAIT_VALID_DNA_INFUSION))
|
||||
//TEST_FAIL() doesn't early return the unit test so we can keep checking.
|
||||
TEST_FAIL("[input_type] is in the 'input_obj_or_mob' list for [infuser_entry.type] but doesn't have TRAIT_VALID_DNA_INFUSION.")
|
||||
|
||||
/// Checks that all "organ_set_bonus" status effects have unique "id" vars.
|
||||
/// Required to ensure that the status effects are treated as "unique".
|
||||
/datum/unit_test/organ_set_bonus_id
|
||||
Reference in New Issue
Block a user