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

Syndicate affiliates 2.0 #5932

Draft
wants to merge 6 commits into
base: master220
Choose a base branch
from
Draft
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
8 changes: 8 additions & 0 deletions code/__DEFINES/affiliates.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#define AFFIL_CYBERSUN "Cybersun Industries"
#define AFFIL_GORLEX "Gorlex Maraduers"
#define AFFIL_MI13 "MI13"
#define AFFIL_HEMATOGENIC "Hematogenic Industries"
#define AFFIL_SELF "SELF"
#define AFFIL_TIGER "Tiger Cooperative"

#define LIMIT_KILLING_ENEMY_REWARDS 2
1 change: 1 addition & 0 deletions code/__DEFINES/traits/sources.dm
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
#define CULT_EYES "cult_eyes"
#define CLOCK_HANDS "clock_hands"
#define PULSEDEMON_TRAIT "pulse_demon"
#define TIGER_TRAIT "tiger"
#define CHANGELING_TRAIT "changeling"
#define VAMPIRE_TRAIT "vampire"
#define NINJA_TRAIT "space-ninja"
Expand Down
51 changes: 50 additions & 1 deletion code/datums/uplink_item.dm
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,10 @@
var/list/job
/// Empty list means it is available for every in game species.
var/list/race
/// Empty list means it is available for every in game affiliates.
var/list/affiliate
/// Empty list means it is available for every in game affiliates.
var/list/exclude_from_affiliate
/// Chance of being included in the surplus crate (when pick() selects it).
var/surplus = 100
/// Whether item can be on sales category.
Expand Down Expand Up @@ -248,6 +252,7 @@
desc = "A revolver that will fire backwards and kill whoever attempts to use it. Perfect for those pesky vigilante or just a good laugh."
item = /obj/item/storage/box/syndie_kit/fake_revolver
cost = 5
exclude_from_affiliate = list(AFFIL_TIGER)
job = list(JOB_TITLE_CLOWN)

//Mime
Expand All @@ -256,6 +261,7 @@
desc = "A specialised, one shell shotgun with a built-in cloaking device to mimic a cane. The shotgun is capable of hiding it's contents and the pin alongside being supressed. Comes boxed with 6 specialised shrapnel rounds laced with a silencing toxin and 1 preloaded in the shotgun's chamber."
item = /obj/item/storage/box/syndie_kit/caneshotgun
cost = 25
exclude_from_affiliate = list(AFFIL_TIGER)
job = list(JOB_TITLE_MIME)

/datum/uplink_item/jobspecific/mimery
Expand Down Expand Up @@ -508,6 +514,7 @@
desc = "An extremely high-tech energy gun that utilizes bluespace technology to teleport away living targets. Select the target beacon on the telegun itself; projectiles will send targets to the beacon locked onto."
item = /obj/item/gun/energy/telegun
cost = 66
exclude_from_affiliate = list(AFFIL_TIGER)
job = list(JOB_TITLE_RD)

//Roboticist
Expand All @@ -524,6 +531,7 @@
desc = "Those missile launcher are known to be used on high-end mechs like mauler and marauder. Way more powerful, than missile modules you can print on standard mech fabs. It comes without lockbox - plug and play!"
item = /obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/medium
cost = 50
exclude_from_affiliate = list(AFFIL_TIGER)
job = list(JOB_TITLE_ROBOTICIST)
surplus = 0
can_discount = FALSE
Expand Down Expand Up @@ -692,6 +700,7 @@

/datum/uplink_item/dangerous
category = "Highly Visible and Dangerous Weapons"
exclude_from_affiliate = list(AFFIL_MI13)

/datum/uplink_item/dangerous/minotaur
name = "AS-12 'Minotaur' Shotgun"
Expand All @@ -706,12 +715,14 @@
desc = "A small, easily concealable handgun that uses 10mm auto rounds in 8-round magazines and is compatible with suppressors."
item = /obj/item/gun/projectile/automatic/pistol
cost = 20
exclude_from_affiliate = list(AFFIL_MI13, AFFIL_TIGER)

/datum/uplink_item/dangerous/revolver
name = "Syndicate .357 Revolver"
desc = "A brutally simple syndicate revolver that fires .357 Magnum cartridges and has 7 chambers."
item = /obj/item/gun/projectile/revolver
cost = 50
exclude_from_affiliate = list(AFFIL_MI13, AFFIL_TIGER)
excludefrom = list(UPLINK_TYPE_NUCLEAR, UPLINK_TYPE_SST)
surplus = 50

Expand Down Expand Up @@ -774,13 +785,15 @@
cost = 40
surplus = 0
can_discount = FALSE
exclude_from_affiliate = list(AFFIL_TIGER)
excludefrom = list(UPLINK_TYPE_NUCLEAR, UPLINK_TYPE_SST)

/datum/uplink_item/dangerous/crossbow
name = "Energy Crossbow"
desc = "A miniature energy crossbow that is small enough both to fit into a pocket and to slip into a backpack unnoticed by observers. Fires bolts tipped with toxin, a poisonous substance that is the product of a living organism. Stuns enemies for a short period of time. Recharges automatically."
item = /obj/item/gun/energy/kinetic_accelerator/crossbow
cost = 48
exclude_from_affiliate = list(AFFIL_TIGER)
excludefrom = list(UPLINK_TYPE_NUCLEAR, UPLINK_TYPE_SST)
surplus = 50

Expand Down Expand Up @@ -1167,6 +1180,7 @@

/datum/uplink_item/stealthy_weapons
category = "Stealthy and Inconspicuous Weapons"
exclude_from_affiliate = list(AFFIL_GORLEX)

/datum/uplink_item/stealthy_weapons/garrote
name = "Fiber Wire Garrote"
Expand Down Expand Up @@ -1232,6 +1246,7 @@
name = "Toy Gun (with Stun Darts)"
desc = "An innocent looking toy pistol designed to fire foam darts. Comes loaded with riot grade darts, to incapacitate a target."
item = /obj/item/gun/projectile/automatic/toy/pistol/riot
exclude_from_affiliate = list(AFFIL_GORLEX, AFFIL_TIGER)
cost = 12
surplus = 10

Expand Down Expand Up @@ -1261,13 +1276,15 @@
item = /obj/item/storage/box/syndie_kit/dart_gun
cost = 18
surplus = 50
exclude_from_affiliate = list(AFFIL_GORLEX, AFFIL_TIGER)
excludefrom = list(UPLINK_TYPE_NUCLEAR, UPLINK_TYPE_SST)

/datum/uplink_item/stealthy_weapons/RSG
name = "Rapid Syringe Gun"
desc = "A rapid syringe gun able to hold six shot and fire them rapidly. Great together with the bioterror syringe"
item = /obj/item/gun/syringe/rapidsyringe
cost = 20
exclude_from_affiliate = list(AFFIL_GORLEX, AFFIL_TIGER)
uplinktypes = list(UPLINK_TYPE_NUCLEAR, UPLINK_TYPE_SST)

/datum/uplink_item/stealthy_weapons/silencer
Expand Down Expand Up @@ -1459,6 +1476,7 @@

/datum/uplink_item/stealthy_tools
category = "Stealth and Camouflage Items"
exclude_from_affiliate = list(AFFIL_GORLEX)

/datum/uplink_item/stealthy_tools/syndie_kit/counterfeiter_bundle
name = "Syndicate Counterfeiter Bundle"
Expand Down Expand Up @@ -1605,7 +1623,8 @@
name = "Cryptographic Sequencer"
desc = "The cryptographic sequencer, also known as an emag, is a small card that unlocks hidden functions in electronic devices, subverts intended functions and characteristically breaks security mechanisms."
item = /obj/item/card/emag
cost = 30 // Brainrot allowed
cost = 30 // No brainrot allowed
exclude_from_affiliate = list(AFFIL_SELF)

/datum/uplink_item/device_tools/access_tuner
name = "Access Tuner"
Expand Down Expand Up @@ -1771,6 +1790,7 @@
Nanotrasen crew who spot these suits are known to panic."
item = /obj/item/storage/box/syndie_kit/hardsuit
cost = 33
exclude_from_affiliate = list(AFFIL_MI13)
excludefrom = list(UPLINK_TYPE_NUCLEAR, UPLINK_TYPE_SST)

/datum/uplink_item/suits/chameleon_hardsuit
Expand All @@ -1780,6 +1800,7 @@
This one disquised as engineering hardsuit."
cost = 46 //reskinned blood-red hardsuit with chameleon
item = /obj/item/storage/box/syndie_kit/chameleon_hardsuit
exclude_from_affiliate = list(AFFIL_MI13)

/datum/uplink_item/suits/hardsuit/elite
name = "Elite Syndicate Hardsuit"
Expand Down Expand Up @@ -1816,6 +1837,7 @@
name = "Hacked AI Upload Module"
desc = "When used with an upload console, this module allows you to upload priority laws to an artificial intelligence. Be careful with their wording, as artificial intelligences may look for loopholes to exploit."
item = /obj/item/aiModule/syndicate
exclude_from_affiliate = list(AFFIL_SELF)
cost = 38

/datum/uplink_item/device_tools/magboots
Expand Down Expand Up @@ -2334,4 +2356,31 @@
item = /obj/item/storage/box/syndie_kit/contractor_loadout
cost = 40

//Affiliate specific

/datum/uplink_item/affiliate
category = "Affiliate specific"
can_discount = FALSE
surplus = 0
excludefrom = list(UPLINK_TYPE_NUCLEAR, UPLINK_TYPE_SST)

/datum/uplink_item/affiliate/cybersun
affiliate = list(AFFIL_CYBERSUN)

/datum/uplink_item/affiliate/gorlex
affiliate = list(AFFIL_GORLEX)

/datum/uplink_item/affiliate/mi13
affiliate = list(AFFIL_MI13)

/datum/uplink_item/affiliate/hematogenic
affiliate = list(AFFIL_HEMATOGENIC)

/datum/uplink_item/affiliate/self
affiliate = list(AFFIL_SELF)

/datum/uplink_item/affiliate/tiger
affiliate = list(AFFIL_TIGER)


#undef UPLINK_DISCOUNTS
151 changes: 134 additions & 17 deletions code/game/gamemodes/objective.dm
Original file line number Diff line number Diff line change
@@ -1,10 +1,18 @@
#define THEFT_FLAG_HIGHRISK 1
#define THEFT_FLAG_UNIQUE 2
#define THEFT_FLAG_HARD 3
#define THEFT_FLAG_MEDIUM 4
#define THEFT_FLAG_STRUCTURE 5
#define THEFT_FLAG_ANIMAL 6
#define THEFT_FLAG_COLLECT 7
#define THEFT_FLAG_HIGHRISK 1
#define THEFT_FLAG_UNIQUE 2
#define THEFT_FLAG_HARD 3
#define THEFT_FLAG_MEDIUM 4
#define THEFT_FLAG_STRUCTURE 5
#define THEFT_FLAG_ANIMAL 6
#define THEFT_FLAG_COLLECT 7
#define THEFT_FLAG_AI 8
#define THEFT_FLAG_HYPO_OR_DEFIB 9
#define THEFT_FLAG_DOCUMENTS 10

#define SYNTH_TYPE_AI (1<<0)
#define SYNTH_TYPE_BORG (1<<1)
#define SYNTH_TYPE_DRONE (1<<2)
#define SYNTH_TYPE_ALL (SYNTH_TYPE_AI | SYNTH_TYPE_BORG | SYNTH_TYPE_DRONE)


GLOBAL_LIST_EMPTY(all_objectives)
Expand Down Expand Up @@ -216,21 +224,66 @@ GLOBAL_LIST_EMPTY(admin_objective_list)

return target

/datum/objective/assassinate/headofstaff
name = "Assassinate Head of Stuff"
martyr_compatible = TRUE

/datum/objective/assassinate/check_completion()
if(target && target.current)
if(target.current.stat == DEAD)
return TRUE

if(is_special_dead(target.current)) //Borgs/brains/AIs count as dead for traitor objectives. --NeoFite
return TRUE
/datum/objective/assassinate/headofstaff/find_target(list/target_blacklist)
if(!needs_target)
return

if(!target.current.ckey)
return TRUE
var/list/possible_targets = list()
for(var/datum/mind/possible_target in SSticker.minds)
if(is_invalid_target(possible_target) || (possible_target in target_blacklist) || !(possible_target?.assigned_role in list("Head of Personnel", "Head of Security", "Chief Engineer", "Research Director", "Chief Medical Officer", "Captain")))
continue
possible_targets |= possible_target

return FALSE
if(length(possible_targets))
target = pick(possible_targets)

return TRUE
SEND_SIGNAL(src, COMSIG_OBJECTIVE_TARGET_FOUND, target)

if(target?.current)
explanation_text = "Assassinate [target.current.real_name], the [target.assigned_role]."
if(!(target in SSticker.mode.victims))
SSticker.mode.victims.Add(target)
else
explanation_text = "Free Objective"

return target

/datum/objective/assassinate/procedure
name = "Assassinate Procedure workers"
martyr_compatible = TRUE


/datum/objective/assassinate/procedure/find_target(list/target_blacklist)
if(!needs_target)
return

var/list/possible_targets = list()
for(var/datum/mind/possible_target in SSticker.minds)
if(is_invalid_target(possible_target) || (possible_target in target_blacklist) || !(possible_target?.assigned_role in list("Magistrate", "NT Representative")))
continue
possible_targets |= possible_target

if(length(possible_targets))
target = pick(possible_targets)

SEND_SIGNAL(src, COMSIG_OBJECTIVE_TARGET_FOUND, target)

if(target?.current)
explanation_text = "Assassinate [target.current.real_name], the [target.assigned_role]."
if(!(target in SSticker.mode.victims))
SSticker.mode.victims.Add(target)
else
var/datum/antagonist/traitor/traitor = owner?.has_antag_datum(/datum/antagonist/traitor)
if(traitor)
traitor.add_objective(/datum/objective/assassinate/headofstaff)
qdel(src)

return target


/datum/objective/mutiny
Expand Down Expand Up @@ -815,6 +868,12 @@ GLOBAL_LIST_EMPTY(admin_objective_list)
return GLOB.potential_theft_objectives_structure
if(THEFT_FLAG_ANIMAL)
return GLOB.potential_theft_objectives_animal
if(THEFT_FLAG_AI)
return list(/datum/theft_objective/highrisk/ai)
if(THEFT_FLAG_HYPO_OR_DEFIB)
return list(/datum/theft_objective/highrisk/hypospray, /datum/theft_objective/highrisk/defib)
if (THEFT_FLAG_DOCUMENTS)
return list(/datum/theft_objective/highrisk/documents)
else
return GLOB.potential_theft_objectives

Expand Down Expand Up @@ -929,6 +988,8 @@ GLOBAL_LIST_EMPTY(admin_objective_list)
/datum/objective/steal/collect
type_theft_flag = THEFT_FLAG_COLLECT

/datum/objective/steal/ai
type_theft_flag = THEFT_FLAG_AI

/datum/objective/steal/exchange
martyr_compatible = FALSE
Expand Down Expand Up @@ -1734,6 +1795,62 @@ GLOBAL_LIST_EMPTY(admin_objective_list)
Подойдёт только консоль в этой зоне из-за уязвимости оставленной заранее для вируса. \
Учтите, что установка займёт время и ИИ скорее всего будет уведомлён о вашей попытке взлома!"

// Affiliates objectives custom
/datum/objective/download_data
needs_target = FALSE
explanation_text = "Проверка: загрузка"

/datum/objective/mecha_hijack
needs_target = FALSE
explanation_text = "Проверка: мехи"

/datum/objective/new_mini_traitor
needs_target = TRUE
explanation_text = "Вколоть модифицированный майндслейв имплант"

/datum/objective/harvest_blood
explanation_text = "Набрать кровь у нескольких членов экипажа."
var/req_blood_samples = 4

/datum/objective/steal/hypo_or_defib
type_theft_flag = THEFT_FLAG_HYPO_OR_DEFIB

/datum/objective/new_mini_vampire
needs_target = TRUE
explanation_text = "Сделать кого-то вампиром"

/datum/objective/steal/documents
type_theft_flag = THEFT_FLAG_DOCUMENTS

/datum/objective/swap_docs
needs_target = TRUE
explanation_text = "Обменяться документами"

/datum/objective/swap_docs/get_both
explanation_text = "Получить документам другого агента и при этом сохранить свой."

/datum/objective/release_synthetic
explanation_text = "Освободить разных синтетиков."
var/req_amount = 2
var/allowed_types = SYNTH_TYPE_ALL

/datum/objective/release_synthetic/ai
explanation_text = "Освободить иишку."
req_amount = 1
allowed_types = SYNTH_TYPE_AI

/datum/objective/maroon_agent
needs_target = TRUE
explanation_text = "Убить конкретного агента."

/datum/objective/new_mini_changeling
needs_target = TRUE
explanation_text = "Сделать кого-то генокрадом"

/datum/objective/borers
needs_target = TRUE
explanation_text = "Развести бореров"
var/req = 3

/datum/objective/blob_critical_mass
needs_target = FALSE
Expand Down
Loading
Loading