Skip to content

Commit

Permalink
Fix unit test issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Atermonera committed Sep 20, 2024
1 parent 8956ef0 commit dad08ec
Show file tree
Hide file tree
Showing 98 changed files with 903 additions and 198 deletions.
7 changes: 5 additions & 2 deletions code/modules/backgrounds/citizenship/citizenship_other.dm
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
/decl/background_detail/citizenship/other
name = "Other Culture"
description = "You are from one of the many small, relatively unknown cultures scattered across the galaxy."
name = "Other Polity"
uid = "stateless_citizenship"
description = "You are from one of the many small, relatively unknown powers scattered across the galaxy."
language = /decl/language/human/common
secondary_langs = list(
/decl/language/human/common,
Expand All @@ -9,6 +10,7 @@

/decl/background_detail/citizenship/stateless
name = "Stateless"
uid = "stateless"
description = "Statelessness is an extremely uncommon occurance. Any stateless human or positronic in SolGov space is \
automatically extended SolGov citizenship, as are stateless members of other species who cannot regain citizenship in their \
homeworld. Most other interstellar states have comperable policies. As such, statelessness tends to be at least semi-voluntary, \
Expand All @@ -18,6 +20,7 @@

/decl/background_detail/citizenship/synthetic
name = "Stateless Drone"
uid = "stateless_drone"
description = "Drones are considered property in SolGov, and citizenships extended by the Almach Protectorate are not recognized. \
Thus, statelessness is ubiqtuous for them."
secondary_langs = list(
Expand Down
3 changes: 1 addition & 2 deletions code/unit_tests/equipment_tests.dm
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@
return 0

H = locate(test["mobref"])
H.equip_to_slot(new glasses_type(H), slot_glasses_str)
return 1
return H?.equip_to_slot(new glasses_type(H), slot_glasses_str, TRUE, TRUE)

/datum/unit_test/vision_glasses/check_result()

Expand Down
3 changes: 2 additions & 1 deletion maps/exodus/exodus.dm
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@
// Must come after borers for compatibility.
#include "../../mods/content/psionics/_psionics.dme"

#include "../../mods/species/neoavians/_neoavians.dme"
#include "../../mods/species/skrell/_skrell.dme"
#include "../../mods/species/tajaran/_tajaran.dme"
#include "../../mods/species/unathi/_unathi.dme"
#include "../../mods/species/teshari/_teshari.dme"

#include "../random_ruins/exoplanet_ruins/playablecolony/playablecolony.dm"

Expand Down Expand Up @@ -77,6 +77,7 @@
#include "exodus_jobs.dm"
#include "exodus_loadout.dm"
#include "exodus_overmap.dm"
#include "exodus_overrides.dm"
#include "exodus_setup.dm"
#include "exodus_shuttles.dm"
#include "exodus_unit_testing.dm"
Expand Down
21 changes: 21 additions & 0 deletions maps/exodus/exodus_define.dm
Original file line number Diff line number Diff line change
Expand Up @@ -52,5 +52,26 @@
list("name" = "AI Private", "key" = "p", "frequency" = 1343, "color" = COMMS_COLOR_AI, "span_class" = "airadio", "secured" = list(access_ai_upload))
)

_background_categories = list(
/decl/background_category/heritage,
/decl/background_category/citizenship,
/decl/background_category/faction,
/decl/background_category/religion
)

available_background_info = list(
/decl/background_category/faction = list(/decl/background_detail/faction/other),
/decl/background_category/heritage = list(/decl/background_detail/heritage/other),
/decl/background_category/religion = list(/decl/background_detail/religion/other),
/decl/background_category/citizenship = list(/decl/background_detail/citizenship/other)
)

default_background_info = list(
/decl/background_category/faction = /decl/background_detail/faction/other,
/decl/background_category/heritage = /decl/background_detail/heritage/other,
/decl/background_category/religion = /decl/background_detail/religion/other,
/decl/background_category/citizenship = /decl/background_detail/citizenship/other
)

/datum/map/exodus/get_map_info()
return "Welcome to Exodus Station, one of the largest remaining stopovers between the core worlds and the rim. Enjoy your stay!"
11 changes: 11 additions & 0 deletions maps/exodus/exodus_overrides.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
/decl/species/monkey
force_background_info = list(
/decl/background_category/heritage = /decl/background_detail/heritage/hidden/monkey,
/decl/background_category/faction = /decl/background_detail/faction/other
)

/decl/species/golem
force_background_info = list(
/decl/background_category/heritage = /decl/background_detail/heritage/hidden/cultist,
/decl/background_category/faction = /decl/background_detail/faction/other
)
2 changes: 1 addition & 1 deletion maps/exodus/jobs/synthetics.dm
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
return H

/datum/job/computer/do_spawn_special(var/mob/living/character, var/mob/new_player/new_player_mob, var/latejoin)
character = character.AIize(move=0) // AIize the character, but don't move them yet
character = character.AIize() // AIize the character, but don't move them yet

// is_available for AI checks that there is an empty core available in this list
var/obj/structure/aicore/deactivated/C = empty_playable_ai_cores[1]
Expand Down
20 changes: 20 additions & 0 deletions maps/tradeship/tradeship_overrides.dm
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,23 @@

/obj/item/stack/cable_coil/random/three
amount = 3

/decl/species/monkey
force_background_info = list(
/decl/background_category/heritage = /decl/background_detail/heritage/hidden/monkey,
/decl/background_category/faction = /decl/background_detail/faction/other
)

/decl/species/golem
force_background_info = list(
/decl/background_category/heritage = /decl/background_detail/heritage/hidden/cultist,
/decl/background_category/faction = /decl/background_detail/faction/other
)

/decl/species/grafadreka
force_background_info = list(
/decl/background_category/heritage = /decl/background_detail/heritage/grafadreka,
/decl/background_category/citizenship = /decl/background_detail/citizenship/grafadreka,
/decl/background_category/faction = /decl/background_detail/faction/grafadreka,
/decl/background_category/religion = /decl/background_detail/religion/grafadreka
)
8 changes: 7 additions & 1 deletion maps/~mapsystem/maps.dm
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,13 @@ var/global/const/MAP_HAS_RANK = 2 //Rank system, also togglable
"reinforced"
)
var/background_categories_generated = FALSE
var/list/_background_categories
var/list/_background_categories = list(
/decl/background_category/heritage,
/decl/background_category/homeworld,
/decl/background_category/faction,
/decl/background_category/religion
)


/datum/map/proc/get_background_categories()
if(!background_categories_generated)
Expand Down
Loading

0 comments on commit dad08ec

Please sign in to comment.