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

Gangs #1535

Open
wants to merge 56 commits into
base: master
Choose a base branch
from
Open

Gangs #1535

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
7e35ee1
yay
wraith-54321 Dec 5, 2023
e8908d4
Merge remote-tracking branch 'upstream/master' into gangs-but-for-real
wraith-54321 Dec 5, 2023
5d1e4b0
Update tgstation.dme
wraith-54321 Dec 5, 2023
0d70376
oo
wraith-54321 Jan 27, 2024
166a98b
o
wraith-54321 Jan 28, 2024
60ccbd6
dgft
wraith-54321 Jan 29, 2024
f043f06
AHHHHHH
wraith-54321 Feb 1, 2024
e96b119
Merge remote-tracking branch 'upstream/master' into gangs-but-for-real
wraith-54321 Feb 1, 2024
ae23c52
merged work
wraith-54321 Feb 1, 2024
56862c6
e
wraith-54321 Feb 1, 2024
ffab210
cool
wraith-54321 Feb 3, 2024
136d935
hand
wraith-54321 Feb 4, 2024
cec2b00
guess I should
wraith-54321 Feb 20, 2024
8f529b9
area resources
wraith-54321 Feb 22, 2024
99d4b17
ok
wraith-54321 Feb 22, 2024
df52da9
geez, FINE
wraith-54321 Feb 22, 2024
e7e11ed
Merge remote-tracking branch 'upstream/master' into gangs-but-for-real
wraith-54321 Feb 22, 2024
11bf25f
Merge branch 'team-huds' into gangs-but-for-real
wraith-54321 Feb 22, 2024
d5cb2e7
communicate and hud
wraith-54321 Feb 26, 2024
6eb4aa8
oh
wraith-54321 Feb 28, 2024
225330f
dont hang signals
wraith-54321 Feb 29, 2024
a3feac4
faction
wraith-54321 Mar 1, 2024
65dc0c4
C
wraith-54321 Mar 5, 2024
c7714bd
hdftr
wraith-54321 Mar 6, 2024
f8df9cd
oo
wraith-54321 Mar 17, 2024
c17290f
machines
wraith-54321 Mar 28, 2024
d9c239f
Merge remote-tracking branch 'upstream/master' into gangs-but-for-real
wraith-54321 Mar 28, 2024
4ab07db
does not really matter
wraith-54321 Mar 31, 2024
8e76517
Makes the easter event spawning logic use a more curated list (#82275)
Profakos Mar 29, 2024
240a0ac
it works fine im sure
wraith-54321 Apr 1, 2024
f2bb30f
Merge remote-tracking branch 'upstream/master' into gangs-but-for-real
wraith-54321 Apr 1, 2024
0666b41
Merge remote-tracking branch 'upstream/master' into easter-is-reaaaal…
wraith-54321 Apr 1, 2024
dea9389
Merge branch 'gangs-but-for-real' into easter-is-reaaaalllllll
wraith-54321 Apr 1, 2024
087d695
temp test
wraith-54321 Apr 2, 2024
e96434f
works good but audio still borked
wraith-54321 Apr 4, 2024
6ad4f99
Merge branch 'master' into easter-is-reaaaalllllll
wraith-54321 Apr 4, 2024
b893648
uuuuuuuu
wraith-54321 Apr 8, 2024
4b93751
Merge branch 'master' into easter-is-reaaaalllllll
wraith-54321 Apr 23, 2024
304d1fa
Merge remote-tracking branch 'upstream/master' into easter-is-reaaaal…
wraith-54321 Apr 29, 2024
0eac9ba
Update gang_spraycan.dm
wraith-54321 Apr 30, 2024
f5a4d62
Merge remote-tracking branch 'upstream/master' into easter-is-reaaaal…
wraith-54321 Apr 30, 2024
2348999
Merge remote-tracking branch 'upstream/master' into easter-is-reaaaal…
wraith-54321 May 14, 2024
089e0a6
lets hope this works
wraith-54321 May 30, 2024
b259722
fixed I guess
wraith-54321 May 30, 2024
caf08fb
yeah lets not spam admins
wraith-54321 May 30, 2024
c9d2984
Merge remote-tracking branch 'upstream/master' into easter-is-reaaaal…
wraith-54321 Jul 4, 2024
e778500
tgstrstfcgr
wraith-54321 Aug 2, 2024
dabe44f
Merge remote-tracking branch 'upstream/master' into easter-is-reaaaal…
wraith-54321 Aug 2, 2024
6e2470b
much
wraith-54321 Aug 25, 2024
652d74b
Merge remote-tracking branch 'upstream/master' into easter-is-reaaaal…
wraith-54321 Aug 25, 2024
b66e958
ooijkui
wraith-54321 Aug 26, 2024
73c9eac
basic objectives system
wraith-54321 Aug 30, 2024
5164a49
retfs
wraith-54321 Aug 30, 2024
5b1fab6
Update traitor.dm
wraith-54321 Aug 30, 2024
d2e3693
renae
wraith-54321 Aug 30, 2024
ca94825
hope this works
wraith-54321 Aug 30, 2024
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
8 changes: 7 additions & 1 deletion code/__DEFINES/role_preferences.dm
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,12 @@
#define ROLE_OPERATIVE "Operative"
#define ROLE_TRAITOR "Traitor"
#define ROLE_WIZARD "Wizard"
#define ROLE_CLOCK_CULTIST "Clock Cultist" //monkestation edit
//monkestation edit start
#define ROLE_CLOCK_CULTIST "Clock Cultist"
#define ROLE_GANG_MEMBER "Gang Member"
#define ROLE_OPFOR_CANDIDATE "OPFOR Candidate"
#define ROLE_ASSAULT_OPERATIVE "Assault Operative"
//monkestation edit end

// Midround roles
#define ROLE_ABDUCTOR "Abductor"
Expand Down Expand Up @@ -131,9 +134,12 @@ GLOBAL_LIST_INIT(special_roles, list(
ROLE_REV_HEAD = 14,
ROLE_TRAITOR = 0,
ROLE_WIZARD = 14,
//monkestation edit start
ROLE_CLOCK_CULTIST = 14,
ROLE_BLOODSUCKER = 0,
ROLE_GANG_MEMBER = 14,
ROLE_ASSAULT_OPERATIVE = 14,
//monkestation edit end

// Midround
ROLE_ABDUCTOR = 0,
Expand Down
9 changes: 9 additions & 0 deletions code/__DEFINES/~monkestation/antagonists.dm
Original file line number Diff line number Diff line change
Expand Up @@ -47,3 +47,12 @@
#define BORER_HIDING (1<<3)
/// If the borer can produce eggs without a host
#define BORER_ALONE_PRODUCTION (1<<4)

// Gang member
#define IS_GANGMEMBER(mob) mob?.mind?.has_antag_datum(/datum/antagonist/gang_member)
///Checks if a gangmember antag datum's rank is >= the input gang rank level
#define MEETS_GANG_RANK(antag_datum, rank_to_meet) antag_datum?.rank >= rank_to_meet
///Return the gang a mob is in or FALSE otherwise
//#define GET_MOB_GANG(mob)
///Check if a mob is in the specified gang
#define IS_IN_GANG(mob, gang) mob?.mind in gang?.members
5 changes: 5 additions & 0 deletions code/__DEFINES/~monkestation/dcs/signals/_signals_object.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
//RENAMED FOR CONFLICT AVOIDENCE
/// called on implants, before an implant has been removed: (mob/living/source, silent, special)
#define COMSIG_PRE_IMPLANT_REMOVED "pre_implant_removed"
/// Stops the call of removed() on the implant
#define COMPONENT_STOP_IMPLANT_REMOVAL (1<<0)
4 changes: 4 additions & 0 deletions code/__DEFINES/~monkestation/dcs/signals/signals_datum.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
///Sent when a gang takes control of an area (taken_area)
#define COMSIG_GANG_TOOK_AREA "gang_took_area"
///Sent when a gang loses control of an area (lost_area)
#define COMSIG_GANG_LOST_AREA "gang_lost_area"
12 changes: 12 additions & 0 deletions code/__DEFINES/~monkestation/gang.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#define GANG_RANK_MEMBER 0
#define GANG_RANK_LIEUTENANT 1
#define GANG_RANK_BOSS 2

#define MAX_LIEUTENANTS 2

#define SEND_MESSAGE_TO_ALL_GANGS(sent_message, span, append) \
var/list/gang_list = list(); \
for(var/gang in GLOB.all_gangs_by_tag) { \
gang_list += GLOB.all_gangs_by_tag[gang]; \
} \
send_gang_message(null, gang_list, sent_message, span, append);
2 changes: 2 additions & 0 deletions code/__DEFINES/~monkestation/uplink.dm
Original file line number Diff line number Diff line change
@@ -1,2 +1,4 @@
/// This item is purchasable to gangs
#define UPLINK_GANGS (1 << 5) //slightly higher bitshift to reduce risk of conflicts with TG in the future
/// the uplink flag for contractors
#define UPLINK_CONTRACTORS (1 << 6)
6 changes: 4 additions & 2 deletions code/controllers/subsystem/traitor.dm
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ SUBSYSTEM_DEF(traitor)

current_global_progression += progression_scaling_delta
for(var/datum/uplink_handler/handler in uplink_handlers)
if(!handler.has_progression || QDELETED(handler))
if(!handler.has_progression || QDELETED(handler) || istype(handler, /datum/uplink_handler/gang)) //monkestation edit: adds the gang handler check
uplink_handlers -= handler
var/deviance = (previous_global_progression - handler.progression_points) / progression_scaling_deviance
if(abs(deviance) < 0.01)
Expand All @@ -85,9 +85,11 @@ SUBSYSTEM_DEF(traitor)
handler.progression_points += amount_to_give
handler.update_objectives()
handler.on_update()
if(length(GLOB.gang_controlled_areas)) //monkestation edit
handle_gangs() //monkestation edit

/datum/controller/subsystem/traitor/proc/register_uplink_handler(datum/uplink_handler/uplink_handler)
if(!uplink_handler.has_progression)
if(!uplink_handler.has_progression || istype(uplink_handler, /datum/uplink_handler/gang)) //monkestation edit: adds the gang handler check
return
uplink_handlers |= uplink_handler
// An uplink handler can be registered multiple times if they get assigned to new uplinks, so
Expand Down
2 changes: 1 addition & 1 deletion code/datums/components/uplink.dm
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@
return
var/list/data = list()
data["telecrystals"] = uplink_handler.telecrystals
data["progression_points"] = uplink_handler.progression_points
data["progression_points"] = uplink_handler.progression_points * (istype(uplink_handler, /datum/uplink_handler/gang) ? 60 : 1) //monkestation edit: adds gang check(pain)
data["current_expected_progression"] = SStraitor.current_global_progression
data["maximum_active_objectives"] = uplink_handler.maximum_active_objectives
data["progression_scaling_deviance"] = SStraitor.progression_scaling_deviance
Expand Down
6 changes: 3 additions & 3 deletions code/game/objects/items/crayons.dm
Original file line number Diff line number Diff line change
Expand Up @@ -323,14 +323,14 @@
rand_items += list(list("item" = i))


/obj/item/toy/crayon/ui_data()
/obj/item/toy/crayon/ui_data(mob/user) //monkestation "edit": makes the user arg be passed
var/static/list/crayon_drawables

if (!crayon_drawables)
crayon_drawables = staticDrawables()

. = list()
.["drawables"] = crayon_drawables
.["drawables"] = crayon_drawables + formatted_additional_drawables //monkestation edit: adds formatted_additional_drawables
.["selected_stencil"] = drawtype
.["text_buffer"] = text_buffer

Expand All @@ -351,7 +351,7 @@
. = TRUE
if("select_stencil")
var/stencil = params["item"]
if(stencil in all_drawables + randoms)
if(stencil in all_drawables + randoms + formatted_additional_drawables) //monkestation edit: adds additional_drawables
drawtype = stencil
. = TRUE
text_buffer = ""
Expand Down
17 changes: 16 additions & 1 deletion code/game/objects/items/devices/traitordevices.dm
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,10 @@ effective or pretty fucking useless.

/obj/item/storage/toolbox/emergency/turret
desc = "You feel a strange urge to hit this with a wrench."
//monkestation edit start
///The type of turret we create
var/obj/machinery/porta_turret/syndicate/toolbox/turret_type = /obj/machinery/porta_turret/syndicate/toolbox
//monkestation edit end

/obj/item/storage/toolbox/emergency/turret/PopulateContents()
new /obj/item/screwdriver(src)
Expand All @@ -325,6 +329,11 @@ effective or pretty fucking useless.
if(!attacking_item.toolspeed)
return

//monkestation edit start
if(!construction_checks(user))
return
//monkestation edit end

balloon_alert(user, "constructing...")
if(!attacking_item.use_tool(src, user, 2 SECONDS, volume = 20))
return
Expand All @@ -334,7 +343,7 @@ effective or pretty fucking useless.
span_danger("You bash [src] with [attacking_item]!"), null, COMBAT_MESSAGE_RANGE)

playsound(src, "sound/items/drill_use.ogg", 80, TRUE, -1)
var/obj/machinery/porta_turret/syndicate/toolbox/turret = new(get_turf(loc))
var/obj/machinery/porta_turret/syndicate/toolbox/turret = new turret_type(get_turf(loc)) //monkestation edit: adds turret_type
set_faction(turret, user)
turret.toolbox = src
forceMove(turret)
Expand All @@ -345,6 +354,12 @@ effective or pretty fucking useless.
/obj/item/storage/toolbox/emergency/turret/nukie/set_faction(obj/machinery/porta_turret/turret, mob/user)
turret.faction = list(ROLE_SYNDICATE)

//monkestation edit start
///Put any extra checks you want to do before constructing here
/obj/item/storage/toolbox/emergency/turret/proc/construction_checks(mob/living/user)
return TRUE
//monkestation edit end

/obj/machinery/porta_turret/syndicate/toolbox
icon_state = "toolbox_off"
base_icon_state = "toolbox"
Expand Down
9 changes: 7 additions & 2 deletions code/game/objects/items/implants/implant.dm
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,12 @@
* * silent - unused here
* * special - unused here
*/
/obj/item/implant/proc/removed(mob/living/source, silent = FALSE, special = 0)
/obj/item/implant/proc/removed(mob/living/source, silent = FALSE, special = 0, forced = FALSE) //monkestation edit: adds forced
//monkestation edit start
if((SEND_SIGNAL(src, COMSIG_PRE_IMPLANT_REMOVED, source, silent, special) & COMPONENT_STOP_IMPLANT_REMOVAL) && !forced) //we still want to send the signal even if forced
return FALSE
//monkestation edit end

moveToNullspace()
imp_in = null
source.implants -= src
Expand All @@ -126,7 +131,7 @@

/obj/item/implant/Destroy()
if(imp_in)
removed(imp_in)
removed(imp_in, forced = TRUE) //monkestation edit: adds forced
return ..()
/**
* Gets implant specifications for the implant pad
Expand Down
2 changes: 1 addition & 1 deletion code/game/objects/items/implants/implant_chem.dm
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
if(.)
RegisterSignal(target, COMSIG_LIVING_DEATH, PROC_REF(on_death))

/obj/item/implant/chem/removed(mob/target, silent = FALSE, special = FALSE)
/obj/item/implant/chem/removed(mob/target, silent = FALSE, special = FALSE, forced = FALSE) //monkestation edit: adds forced
. = ..()
if(.)
UnregisterSignal(target, COMSIG_LIVING_DEATH)
Expand Down
2 changes: 1 addition & 1 deletion code/game/objects/items/implants/implant_clown.dm
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
if(.)
RegisterSignal(target, COMSIG_MOB_EMOTED("deathgasp"), PROC_REF(on_deathgasp))

/obj/item/implant/sad_trombone/removed(mob/target, silent = FALSE, special = FALSE)
/obj/item/implant/sad_trombone/removed(mob/target, silent = FALSE, special = FALSE, forced = FALSE) //monkestation edit: adds forced
. = ..()
if(.)
UnregisterSignal(target, COMSIG_MOB_EMOTED("deathgasp"))
Expand Down
2 changes: 1 addition & 1 deletion code/game/objects/items/implants/implant_exile.dm
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
ADD_TRAIT(living_target, TRAIT_NO_TELEPORT, IMPLANT_TRAIT)
return TRUE

/obj/item/implant/exile/noteleport/removed(mob/target, silent = FALSE, special = FALSE)
/obj/item/implant/exile/noteleport/removed(mob/target, silent = FALSE, special = FALSE, forced = FALSE) //monkestation edit: adds forced
. = ..()
if(!. || !isliving(target))
return FALSE
Expand Down
2 changes: 1 addition & 1 deletion code/game/objects/items/implants/implant_explosive.dm
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
if(.)
RegisterSignal(target, COMSIG_LIVING_DEATH, PROC_REF(on_death))

/obj/item/implant/explosive/removed(mob/target, silent = FALSE, special = FALSE)
/obj/item/implant/explosive/removed(mob/target, silent = FALSE, special = FALSE, forced = FALSE) //monkestation edit: adds forced
. = ..()
if(.)
UnregisterSignal(target, COMSIG_LIVING_DEATH)
Expand Down
2 changes: 1 addition & 1 deletion code/game/objects/items/implants/implant_mindshield.dm
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
to_chat(target, span_notice("You feel a sense of peace and security. You are now protected from brainwashing."))
return TRUE

/obj/item/implant/mindshield/removed(mob/target, silent = FALSE, special = FALSE)
/obj/item/implant/mindshield/removed(mob/target, silent = FALSE, special = FALSE, forced = FALSE) //monkestation edit: adds forced
. = ..()
if(!.)
return FALSE
Expand Down
2 changes: 1 addition & 1 deletion code/game/objects/items/implants/implant_spell.dm
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
spell_to_give.Grant(target)
return TRUE

/obj/item/implant/spell/removed(mob/living/source, silent = FALSE, special = 0)
/obj/item/implant/spell/removed(mob/living/source, silent = FALSE, special = 0, forced = FALSE) //monkestation edit: adds forced
. = ..()
if (!.)
return FALSE
Expand Down
2 changes: 1 addition & 1 deletion code/game/objects/items/implants/implant_storage.dm
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
. = ..()
atom_storage?.open_storage(imp_in)

/obj/item/implant/storage/removed(source, silent = FALSE, special = FALSE)
/obj/item/implant/storage/removed(source, silent = FALSE, special = FALSE, forced = FALSE) //monkestation edit: adds forced
if(special)
return ..()

Expand Down
6 changes: 5 additions & 1 deletion code/game/objects/items/implants/implant_track.dm
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,12 @@
. = ..()
timerid = QDEL_IN_STOPPABLE(src, lifespan)

/obj/item/implant/tracking/c38/removed(mob/living/source, silent, special)
/obj/item/implant/tracking/c38/removed(mob/living/source, silent, special, forced) //monkestation edit: adds forced
. = ..()
//monkestation edit start
if(!.)
return
//monkestation edit end
deltimer(timerid)
timerid = null

Expand Down
12 changes: 11 additions & 1 deletion code/game/objects/items/implants/implantuplink.dm
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,17 @@

/obj/item/implant/uplink/implant(mob/living/carbon/target, mob/user, silent, force)
. = ..()
var/datum/component/uplink/new_uplink = AddComponent(/datum/component/uplink, owner = target?.key, lockable = TRUE, enabled = FALSE, uplink_handler_override = uplink_handler, starting_tc = starting_tc)
//monkestation removal on next line to make edits easier
// var/datum/component/uplink/new_uplink = AddComponent(/datum/component/uplink, owner = target?.key, lockable = TRUE, enabled = FALSE, uplink_handler_override = uplink_handler, starting_tc = starting_tc)
//monkestation edit start
var/datum/component/uplink/new_uplink = AddComponent(/datum/component/uplink, \
owner = target?.key, \
lockable = TRUE, \
enabled = FALSE, \
uplink_flag = uplink_flag, \
uplink_handler_override = uplink_handler, \
starting_tc = starting_tc)
//monkestation edit end
new_uplink.unlock_text = "Your Syndicate Uplink has been cunningly implanted in you, for a small TC fee. Simply trigger the uplink to access it."
if(!uplink_handler)
new_uplink.uplink_handler.owner = target.mind
Expand Down
2 changes: 1 addition & 1 deletion code/game/objects/items/storage/uplink_kits.dm
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,7 @@
to_chat(human_target, span_userdanger("This implant does NOT, in any way, brainwash you. If you were a normal crew member beforehand, forcibly implanted or otherwise, you are still one and cannot assist the nuclear operatives."))
return TRUE

/obj/item/implant/nuclear_operative/removed(mob/target, silent = FALSE, special = FALSE)
/obj/item/implant/nuclear_operative/removed(mob/target, silent = FALSE, special = FALSE, forced = FALSE) //monkestation edit: adds forced
. = ..()
if(!. || !isliving(target))
return FALSE
Expand Down
11 changes: 6 additions & 5 deletions code/modules/admin/sql_ban_system.dm
Original file line number Diff line number Diff line change
Expand Up @@ -347,12 +347,13 @@
ROLE_ALIEN,
ROLE_BLOB,
ROLE_BROTHER,
ROLE_BLOODSUCKER,
ROLE_BLOODSUCKERBREAKOUT,
ROLE_BLOODSUCKER, //monkestation edit
ROLE_BLOODSUCKERBREAKOUT, //monkestation edit
ROLE_CORTICAL_BORER, // MONKESTATION ADDITION -- CORTICAL_BORERS
ROLE_CHANGELING,
ROLE_CLOCK_CULTIST,
ROLE_CLOCK_CULTIST, //monkestation edit
ROLE_CULTIST,
ROLE_GANG_MEMBER, //monkestation edit
ROLE_HERETIC,
ROLE_HIVE,
ROLE_INFILTRATOR,
Expand All @@ -365,11 +366,11 @@
ROLE_REVENANT,
ROLE_REV_HEAD,
ROLE_SENTIENT_DISEASE,
ROLE_SLASHER,
ROLE_SLASHER, //monkestation edit
ROLE_SPIDER,
ROLE_SYNDICATE,
ROLE_TRAITOR,
ROLE_VAMPIRICACCIDENT,
ROLE_VAMPIRICACCIDENT, //monkestation edit
ROLE_WIZARD,
BAN_OPFOR,
ROLE_ASSAULT_OPERATIVE,
Expand Down
2 changes: 1 addition & 1 deletion code/modules/admin/verbs/manipulate_organs.dm
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@
O.Remove(C)
else
I = organ
I.removed(C)
I.removed(C, forced = TRUE) //monkestation edit: adds forced

organ.forceMove(get_turf(C))

Expand Down
2 changes: 1 addition & 1 deletion code/modules/antagonists/traitor/objective_category.dm
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
var/list/category_list = list()
for(var/value in category.objectives)
if(islist(value))
var/list/objective_category = filter_invalid_objective_list(value, progression_points, uplink_flag) //monkestation edit:: adds uplink_flag
var/list/objective_category = filter_invalid_objective_list(value, progression_points, uplink_flag) //monkestation edit: adds uplink_flag
if(!length(objective_category))
continue
category_list[objective_category] = category.objectives[value]
Expand Down
4 changes: 2 additions & 2 deletions code/modules/antagonists/traitor/traitor_objective.dm
Original file line number Diff line number Diff line change
Expand Up @@ -239,11 +239,11 @@
"name" = name,
"description" = description,
"progression_minimum" = progression_minimum,
"progression_reward" = progression_reward,
"progression_reward" = progression_reward * ((valid_uplinks & UPLINK_GANGS) ? 100 : 1), //monkestation edit: adds the gang check
"telecrystal_reward" = telecrystal_reward,
"ui_buttons" = generate_ui_buttons(user),
"objective_state" = objective_state,
"original_progression" = original_progression,
"original_progression" = original_progression * ((valid_uplinks & UPLINK_GANGS) ? 100 : 1), //monkestation edit: adds the gang check,
"telecrystal_penalty" = telecrystal_penalty,
"contractor_rep" = given_contractor_rep, //monkestation edit
)
Expand Down
3 changes: 2 additions & 1 deletion code/modules/antagonists/traitor/uplink_handler.dm
Original file line number Diff line number Diff line change
Expand Up @@ -246,14 +246,15 @@

/datum/uplink_handler/proc/take_objective(mob/user, datum/traitor_objective/to_take)
if(!(to_take in potential_objectives))
return
return FALSE //monkestation edit: adds the FALSE return

user.playsound_local(get_turf(user), 'sound/traitor/objective_taken.ogg', vol = 100, vary = FALSE, channel = CHANNEL_TRAITOR)
to_take.on_objective_taken(user)
to_take.objective_state = OBJECTIVE_STATE_ACTIVE
potential_objectives -= to_take
active_objectives += to_take
on_update()
return TRUE //monkestation edit

/datum/uplink_handler/proc/ui_objective_act(mob/user, datum/traitor_objective/to_act_on, action)
if(!(to_act_on in active_objectives))
Expand Down
Loading
Loading