Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separates Factions In Observe/Follow Tab #5058

Merged
merged 4 commits into from
Dec 21, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion code/__DEFINES/mode.dm
Original file line number Diff line number Diff line change
Expand Up @@ -241,8 +241,16 @@ GLOBAL_LIST_INIT(whitelist_hierarchy, list(WHITELIST_NORMAL, WHITELIST_COUNCIL,

#define FACTION_LIST_MARINE list(FACTION_MARINE)
#define FACTION_LIST_HUMANOID list(FACTION_MARINE, FACTION_PMC, FACTION_WY, FACTION_WY_DEATHSQUAD, FACTION_CLF, FACTION_CONTRACTOR, FACTION_MARSHAL, FACTION_UPP, FACTION_FREELANCER, FACTION_SURVIVOR, FACTION_NEUTRAL, FACTION_COLONIST, FACTION_MERCENARY, FACTION_DUTCH, FACTION_HEFA, FACTION_GLADIATOR, FACTION_PIRATE, FACTION_PIZZA, FACTION_SOUTO, FACTION_YAUTJA, FACTION_ZOMBIE, FACTION_TWE)
#define FACTION_LIST_ERT list(FACTION_PMC, FACTION_WY_DEATHSQUAD, FACTION_CLF, FACTION_CONTRACTOR, FACTION_UPP, FACTION_FREELANCER, FACTION_MERCENARY, FACTION_DUTCH, FACTION_HEFA, FACTION_GLADIATOR, FACTION_PIRATE, FACTION_PIZZA, FACTION_SOUTO, FACTION_MARSHAL, FACTION_TWE)
#define FACTION_LIST_ERT list(FACTION_HEFA, FACTION_GLADIATOR, FACTION_PIRATE, FACTION_PIZZA, FACTION_SOUTO)
#define FACTION_LIST_WY list(FACTION_PMC, FACTION_WY_DEATHSQUAD, FACTION_WY)
#define FACTION_LIST_UPP list(FACTION_UPP)
#define FACTION_LIST_CLF list(FACTION_CLF)
#define FACTION_LIST_TWE list(FACTION_TWE)
#define FACTION_LIST_FREELANCER list(FACTION_FREELANCER)
#define FACTION_LIST_CONTRACTOR list(FACTION_CONTRACTOR)
Steelpoint marked this conversation as resolved.
Show resolved Hide resolved
#define FACTION_LIST_MERCENARY list(FACTION_MERCENARY)
#define FACTION_LIST_MARSHAL list(FACTION_MARSHAL)
#define FACTION_LIST_DUTCH list(FACTION_DUTCH)
#define FACTION_LIST_MARINE_WY list(FACTION_MARINE, FACTION_PMC, FACTION_WY_DEATHSQUAD, FACTION_WY)
#define FACTION_LIST_MARINE_UPP list(FACTION_MARINE, FACTION_UPP)
#define FACTION_LIST_MARINE_TWE list(FACTION_MARINE, FACTION_TWE)
Expand Down
2 changes: 1 addition & 1 deletion code/modules/gear_presets/contractor.dm
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
rank = JOB_CONTRACTOR
idtype = /obj/item/card/id/data
faction = FACTION_CONTRACTOR
faction_group = FACTION_LIST_ERT
Steelpoint marked this conversation as resolved.
Show resolved Hide resolved
faction_group = list(FACTION_CONTRACTOR)
languages = list(LANGUAGE_ENGLISH, LANGUAGE_SPANISH, LANGUAGE_RUSSIAN)
var/human_versus_human = FALSE
var/headset_type = /obj/item/device/radio/headset/distress/contractor
Expand Down
36 changes: 36 additions & 0 deletions code/modules/mob/dead/observer/orbit.dm
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,15 @@
var/list/survivors = list()
var/list/xenos = list()
var/list/ert_members = list()
var/list/upp = list()
var/list/clf = list()
var/list/wy = list()
var/list/twe = list()
var/list/freelancer = list()
var/list/contractor = list()
var/list/mercenary = list()
var/list/dutch = list()
var/list/marshal = list()
var/list/synthetics = list()
var/list/predators = list()
var/list/animals = list()
Expand Down Expand Up @@ -132,12 +141,30 @@

if(SSticker.mode.is_in_endgame == TRUE && !is_mainship_level(M.z) && !(human.faction in FACTION_LIST_ERT))
escaped += list(serialized)
else if(human.faction in FACTION_LIST_WY)
wy += list(serialized)
else if(issynth(human) && !isinfiltratorsynthetic(human))
synthetics += list(serialized)
else if(isyautja(human))
predators += list(serialized)
else if(human.faction in FACTION_LIST_ERT)
Drulikar marked this conversation as resolved.
Show resolved Hide resolved
ert_members += list(serialized)
else if(human.faction in FACTION_LIST_UPP)
upp += list(serialized)
else if(human.faction in FACTION_LIST_CLF)
clf += list(serialized)
else if(human.faction in FACTION_LIST_TWE)
twe += list(serialized)
else if(human.faction in FACTION_LIST_FREELANCER)
freelancer += list(serialized)
else if(human.faction in FACTION_LIST_CONTRACTOR)
contractor += list(serialized)
else if(human.faction in FACTION_LIST_MERCENARY)
mercenary += list(serialized)
else if(human.faction in FACTION_LIST_MARSHAL)
marshal += list(serialized)
else if(human.faction in FACTION_LIST_DUTCH)
dutch += list(serialized)
else if(human.faction in FACTION_LIST_MARINE)
marines += list(serialized)
else if(issurvivorjob(human.job))
Expand All @@ -156,6 +183,15 @@
data["survivors"] = survivors
data["xenos"] = xenos
data["ert_members"] = ert_members
data["upp"] = upp
data["clf"] = clf
data["wy"] = wy
data["twe"] = twe
data["freelancer"] = freelancer
data["contractor"] = contractor
data["mercenary"] = mercenary
data["dutch"] = dutch
data["marshal"] = marshal
data["synthetics"] = synthetics
data["predators"] = predators
data["animals"] = animals
Expand Down
46 changes: 46 additions & 0 deletions tgui/packages/tgui/interfaces/Orbit/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,15 @@ const ObservableContent = (props, context) => {
survivors = [],
xenos = [],
ert_members = [],
upp = [],
clf = [],
wy = [],
twe = [],
freelancer = [],
mercenary = [],
contractor = [],
dutch = [],
marshal = [],
synthetics = [],
predators = [],
animals = [],
Expand Down Expand Up @@ -145,6 +154,43 @@ const ObservableContent = (props, context) => {
section={synthetics}
title="Synthetics"
/>
<ObservableSection
color="green"
section={upp}
title="Union of Progressive Peoples"
/>
<ObservableSection
color="teal"
section={clf}
title="Colonial Liberation Front"
/>
<ObservableSection color="white" section={wy} title="Weyland Yutani" />
<ObservableSection
color="red"
section={twe}
title="Royal Marines Commando"
/>
<ObservableSection
color="orange"
section={freelancer}
title="Freelancers"
/>
<ObservableSection
color="label"
section={mercenary}
title="Mercenaries"
/>
<ObservableSection
color="light-grey"
section={contractor}
title="Military Contractors"
/>
<ObservableSection color="good" section={dutch} title="Dutchs Dozen" />
<ObservableSection
color="dark-blue"
section={marshal}
title="Colonial Marshal Bureau"
/>
<ObservableSection color="green" section={predators} title="Predators" />
<ObservableSection color="olive" section={escaped} title="Escaped" />
<ObservableSection section={vehicles} title="Vehicles" />
Expand Down
9 changes: 9 additions & 0 deletions tgui/packages/tgui/interfaces/Orbit/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,15 @@ export type OrbitData = {
survivors: Observable[];
xenos: Observable[];
ert_members: Observable[];
upp: Observable[];
twe: Observable[];
clf: Observable[];
wy: Observable[];
freelancer: Observable[];
contractor: Observable[];
mercenary: Observable[];
dutch: Observable[];
marshal: Observable[];
synthetics: Observable[];
predators: Observable[];
animals: Observable[];
Expand Down