Central Command access rework

This commit is contained in:
Markolie
2015-03-04 16:36:17 +01:00
parent 6352d2abd9
commit 9c54d2feaa
14 changed files with 271 additions and 266 deletions
+77 -51
View File
@@ -77,28 +77,20 @@
/var/const/access_weapons = 99 //Weapon authorization for secbots
//BEGIN CENTCOM ACCESS
/*Should leave plenty of room if we need to add more access levels.
/var/const/Mostly for admin fun times.*/
/var/const/access_cent_general = 101//General facilities.
/var/const/access_cent_thunder = 102//Thunderdome.
/var/const/access_cent_specops = 103//Special Ops.
/var/const/access_cent_medical = 104//Medical/Research
/var/const/access_cent_living = 105//Living quarters.
/var/const/access_cent_storage = 106//Generic storage areas.
/var/const/access_cent_teleporter = 107//Teleporter.
/var/const/access_cent_creed = 108//Creed's office.
/var/const/access_cent_captain = 109//Captain's office/ID comp/AI.
//EMBASSIES
/var/const/embassy_tajaran = 120
/var/const/embassy_skrell = 121
/var/const/embassy_unathi = 122
/var/const/embassy_diona = 123
/var/const/embassy_kidan = 124
/var/const/embassy_slime = 125
/var/const/embassy_grey = 126
/var/const/embassy_vox = 127
/var/const/access_cent_living = 102//Living quarters.
/var/const/access_cent_medical = 103//Medical.
/var/const/access_cent_security = 104//Security.
/var/const/access_cent_storage = 105//Storage areas.
/var/const/access_cent_shuttles = 106//Shuttle docks.
/var/const/access_cent_telecomms = 107//Telecomms.
/var/const/access_cent_teleporter = 108//Telecomms.
/var/const/access_cent_specops = 109//Special Ops.
/var/const/access_cent_specops_commander = 110//Special Ops Commander.
/var/const/access_cent_blackops = 111//Black Ops.
/var/const/access_cent_thunder = 112//Thunderdome.
/var/const/access_cent_bridge = 113//Bridge.
/var/const/access_cent_commander = 114//Commander's Office/ID computer.
//The Syndicate
/var/const/access_syndicate = 150//General Syndicate Access
@@ -197,34 +189,49 @@
/proc/get_centcom_access(job)
switch(job)
if("VIP Guest")
return list(access_cent_general)
return list(access_cent_general, access_cent_living)
if("Custodian")
return list(access_cent_general, access_cent_living, access_cent_storage)
return list(access_cent_general, access_cent_living, access_cent_medical, access_cent_storage)
if("Thunderdome Overseer")
return list(access_cent_general, access_cent_thunder)
if("Emergency Response Team")
return list(access_cent_general, access_cent_living, access_cent_storage) + get_all_accesses()
if("Emergency Response Team Member")
return list(access_cent_general, access_cent_living, access_cent_medical, access_cent_security, access_cent_storage, access_cent_specops) + get_all_accesses()
if("Emergency Response Team Leader")
return list(access_cent_general, access_cent_living, access_cent_storage, access_cent_teleporter) + get_all_accesses()
if("Intel Officer")
return list(access_cent_general, access_cent_living) + get_all_accesses()
return list(access_cent_general, access_cent_living, access_cent_medical, access_cent_security, access_cent_storage, access_cent_specops, access_cent_specops_commander) + get_all_accesses()
if("Medical Officer")
return list(access_cent_general, access_cent_living, access_cent_medical) + get_all_accesses()
if("Death Commando")
return list(access_cent_general, access_cent_specops, access_cent_living, access_cent_storage) + get_all_accesses()
return list(access_cent_general, access_cent_living, access_cent_medical, access_cent_storage) + get_all_accesses()
if("Intel Officer")
return list(access_cent_general, access_cent_living, access_cent_security, access_cent_storage) + get_all_accesses()
if("Research Officer")
return list(access_cent_general, access_cent_specops, access_cent_medical, access_cent_teleporter, access_cent_storage) + get_all_accesses()
if("BlackOps Commander")
return list(access_cent_general, access_cent_thunder, access_cent_specops, access_cent_living, access_cent_storage, access_cent_creed) + get_all_accesses()
return list(access_cent_general, access_cent_specops, access_cent_medical, access_cent_storage, access_cent_telecomms, access_cent_teleporter) + get_all_accesses()
if("Death Commando")
return list(access_cent_general, access_cent_living, access_cent_medical, access_cent_security, access_cent_storage, access_cent_specops, access_cent_specops_commander, access_cent_blackops) + get_all_accesses()
if("Deathsquad Officer")
return get_all_centcom_access() + get_all_accesses()
if("Special Operations Officer")
return get_all_centcom_access() + get_all_accesses()
if("Nanotrasen Navy Representative")
return get_all_centcom_access() + get_all_accesses()
if("Nanotrasen Navy Officer")
return get_all_centcom_access() + get_all_accesses()
if("Nanotrasen Navy Captain")
return get_all_centcom_access() + get_all_accesses()
if("Supreme Commander")
return get_all_centcom_access() + get_all_accesses()
/proc/get_syndicate_access(job)
switch(job)
if("Syndicate Operative")
return list(access_syndicate)
if("Syndicate Operative Leader")
return list(access_syndicate, access_syndicate_leader)
if("Vox Raider")
return list(access_vox)
if("Vox Trader")
return list(access_vox)
if("Syndicate Commando")
return list(access_syndicate, access_syndicate_leader)
/proc/get_all_accesses()
return list(access_security, access_sec_doors, access_brig, access_armory, access_forensics_lockers, access_court,
access_medical, access_genetics, access_morgue, access_rd,
@@ -240,10 +247,10 @@
access_pilot, access_ntrep, access_magistrate, access_minisat)
/proc/get_all_centcom_access()
return list(access_cent_general, access_cent_thunder, access_cent_specops, access_cent_medical, access_cent_living, access_cent_storage, access_cent_teleporter, access_cent_creed, access_cent_captain)
return list(access_cent_general, access_cent_living, access_cent_medical, access_cent_security, access_cent_storage, access_cent_shuttles, access_cent_telecomms, access_cent_teleporter, access_cent_specops, access_cent_specops_commander, access_cent_blackops, access_cent_thunder, access_cent_bridge, access_cent_commander)
/proc/get_all_syndicate_access()
return list(access_syndicate)
return list(access_syndicate, access_syndicate_leader, access_vox)
/proc/get_region_accesses(var/code)
switch(code)
@@ -436,23 +443,42 @@
/proc/get_centcom_access_desc(A)
switch(A)
if(access_cent_general)
return "Code Grey"
if(access_cent_thunder)
return "Code Yellow"
if(access_cent_storage)
return "Code Orange"
return "General Access"
if(access_cent_living)
return "Code Green"
return "Living Quarters"
if(access_cent_medical)
return "Code White"
return "Medical"
if(access_cent_security)
return "Security"
if(access_cent_storage)
return "Storage"
if(access_cent_shuttles)
return "Shuttles"
if(access_cent_telecomms)
return "Telecommunications"
if(access_cent_teleporter)
return "Code Blue"
return "Teleporter"
if(access_cent_specops)
return "Code Black"
if(access_cent_creed)
return "Code Silver"
if(access_cent_captain)
return "Code Gold"
return "Special Ops"
if(access_cent_specops_commander)
return "Special Ops Commander"
if(access_cent_blackops)
return "Black Ops"
if(access_cent_thunder)
return "Thunderdome"
if(access_cent_bridge)
return "Bridge"
if(access_cent_commander)
return "Commander"
/proc/get_syndicate_access_desc(A)
switch(A)
if(access_syndicate)
return "Syndicate Operative"
if(access_syndicate_leader)
return "Syndicate Operative Leader"
if(access_vox)
return "Vox"
/proc/get_all_jobs()
var/list/all_jobs = list()
@@ -465,7 +491,7 @@
return all_jobs
/proc/get_all_centcom_jobs()
return list("VIP Guest","Custodian","Thunderdome Overseer","Emergency Response Team Member","Emergency Response Team Leader","Intel Officer","Medical Officer","Death Commando","Research Officer","BlackOps Commander","Special Operations Officer","Nanotrasen Navy Officer","Nanotrasen Navy Captain","Supreme Commander")
return list("VIP Guest","Custodian","Thunderdome Overseer","Emergency Response Team Member","Emergency Response Team Leader","Intel Officer","Medical Officer","Death Commando","Research Officer","Deathsquad Officer","Special Operations Officer","Nanotrasen Navy Representative","Nanotrasen Navy Officer","Nanotrasen Navy Captain","Supreme Commander")
//gets the actual job rank (ignoring alt titles)
//this is used solely for sechuds
+3 -3
View File
@@ -36,9 +36,9 @@
networks["Anomaly Isolation"] = list(access_rd,access_hos,access_captain)
networks["Toxins"] = list(access_rd,access_hos,access_captain)
networks["Telepad"] = list(access_rd,access_hos,access_captain)
networks["ERT"] = list(access_cent_teleporter,access_cent_captain)
networks["CentCom"] = list(access_cent_captain)
networks["Thunderdome"] = list(access_cent_captain)
networks["ERT"] = list(access_cent_specops_commander,access_cent_commander)
networks["CentCom"] = list(access_cent_security,access_cent_commander)
networks["Thunderdome"] = list(access_cent_thunder,access_cent_commander)
attack_ai(var/mob/user as mob)
return attack_hand(user)
+1 -1
View File
@@ -291,4 +291,4 @@
/obj/machinery/computer/card/centcom
name = "CentCom Identification Computer"
circuit = "/obj/item/weapon/circuitboard/card/centcom"
req_access = list(access_cent_captain)
req_access = list(access_cent_commander)
@@ -14,7 +14,7 @@ var/syndicate_elite_shuttle_timeleft = 0
name = "Elite Syndicate Squad Shuttle Console"
icon = 'icons/obj/computer.dmi'
icon_state = "syndishuttle"
req_access = list(access_cent_specops)
req_access = list(access_syndicate)
var/temp = null
var/hacked = 0
var/allowedtocall = 0
+1 -1
View File
@@ -27,7 +27,7 @@
name = "Seraph"
icon_state = "seraph"
initial_icon = "seraph"
operation_req_access = list(access_cent_creed)
operation_req_access = list(access_cent_commander)
step_in = 3
health = 550
wreckage = /obj/effect/decal/mecha_wreckage/seraph
+6 -11
View File
@@ -296,7 +296,7 @@ var/can_call_ert
M.gender = pick(MALE, FEMALE)
M.set_species("Human",1)
M.dna.ready_dna(M) // Quadriplegic Nuke Ops won't be participating in the paralympics
M.dna.ready_dna(M)
var/hair_c = pick("#8B4513","#000000","#FF4500","#FFD700") // Brown, black, red, blonde
var/eye_c = pick("#000000","#8B4513","1E90FF") // Black, brown, blue
@@ -375,8 +375,7 @@ var/can_call_ert
W.registered_name = M.real_name
W.name = "[M.real_name]'s ID Card (Emergency Response Team - Commander)"
W.icon_state = "centcom"
W.access = get_all_accesses()
W.access += list(access_cent_general, access_cent_living, access_cent_medical, access_cent_storage, access_cent_thunder, access_cent_teleporter)
W.access = get_centcom_access(W.assignment)
M.equip_to_slot_or_del(W, slot_wear_id)
var/obj/item/device/pda/heads/pda = new(src)
@@ -460,8 +459,7 @@ var/can_call_ert
W.registered_name = M.real_name
W.name = "[M.real_name]'s ID Card (Emergency Response Team - Officer)"
W.icon_state = "centcom"
W.access = get_all_accesses()
W.access += list(access_cent_general, access_cent_living, access_cent_thunder)
W.access = get_centcom_access(W.assignment)
M.equip_to_slot_or_del(W, slot_wear_id)
var/obj/item/device/pda/heads/pda = new(src)
@@ -500,8 +498,7 @@ var/can_call_ert
W.registered_name = M.real_name
W.name = "[M.real_name]'s ID Card (Emergency Response Team - Medic)"
W.icon_state = "centcom"
W.access = get_all_accesses()
W.access += list(access_cent_general, access_cent_living, access_cent_medical)
W.access = get_centcom_access(W.assignment)
M.equip_to_slot_or_del(W, slot_wear_id)
var/obj/item/device/pda/heads/pda = new(src)
@@ -542,8 +539,7 @@ var/can_call_ert
W.registered_name = M.real_name
W.name = "[M.real_name]'s ID Card (Emergency Response Team - Engineer)"
W.icon_state = "centcom"
W.access = get_all_accesses()
W.access += list(access_cent_general, access_cent_living, access_cent_storage)
W.access = get_centcom_access(W.assignment)
M.equip_to_slot_or_del(W, slot_wear_id)
var/obj/item/device/pda/heads/pda = new(src)
@@ -586,8 +582,7 @@ var/can_call_ert
W.registered_name = M.real_name
W.name = "[M.real_name]'s ID Card (Emergency Response Team - Janitor)"
W.icon_state = "centcom"
W.access = get_all_accesses()
W.access += list(access_cent_general, access_cent_living, access_cent_storage)
W.access = get_centcom_access(W.assignment)
M.equip_to_slot_or_del(W, slot_wear_id)
var/obj/item/device/pda/heads/pda = new(src)
+15 -23
View File
@@ -855,8 +855,8 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
W.icon_state = "centcom"
W.item_state = "id_inv"
W.access = get_all_accesses()
W.access += list("VIP Guest","Custodian","Thunderdome Overseer","Intel Officer","Medical Officer","Death Commando","Research Officer")
W.assignment = "Nanotrasen Navy Representative"
W.access = get_centcom_access(W.assignment)
W.registered_name = M.real_name
M.equip_if_possible(W, slot_wear_id)
@@ -878,9 +878,8 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
var/obj/item/weapon/card/id/centcom/W = new(M)
W.name = "[M.real_name]'s ID Card (Nanotrasen Navy Officer)"
W.access = get_all_accesses()
W.access += get_all_centcom_access()
W.assignment = "Nanotrasen Navy Officer"
W.assignment = "Nanotrasen Navy Officer"
W.access = get_centcom_access(W.assignment)
W.registered_name = M.real_name
M.equip_if_possible(W, slot_wear_id)
@@ -904,12 +903,12 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
var/obj/item/weapon/card/id/centcom/W = new(M)
W.name = "[M.real_name]'s ID Card (Nanotrasen Navy Captain)"
W.access = get_all_accesses()
W.access += get_all_centcom_access()
W.assignment = "Nanotrasen Navy Captain"
W.assignment = "Nanotrasen Navy Captain"
W.access = get_centcom_access(W.assignment)
W.registered_name = M.real_name
M.equip_if_possible(W, slot_wear_id)
if("emergency response team")
if("emergency response team member")
M.equip_to_slot_or_del(new /obj/item/clothing/under/rank/centcom_officer(M), slot_w_uniform)
M.equip_to_slot_or_del(new /obj/item/clothing/shoes/combat(M), slot_shoes)
M.equip_to_slot_or_del(new /obj/item/clothing/gloves/swat(M), slot_gloves)
@@ -919,11 +918,10 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
M.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel(M), slot_back)
var/obj/item/weapon/card/id/W = new(M)
W.name = "[M.real_name]'s ID Card (Emergency Response Team)"
W.name = "[M.real_name]'s ID Card (Emergency Response Team - Member)"
W.icon_state = "centcom"
W.access = get_all_accesses()
W.access += get_all_centcom_access()
W.assignment = "Emergency Response Team"
W.assignment = "Emergency Response Team Member"
W.access = get_centcom_access(W.assignment)
W.registered_name = M.real_name
M.equip_to_slot_or_del(W, slot_wear_id)
@@ -942,11 +940,10 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
M.equip_to_slot_or_del(new /obj/item/weapon/storage/backpack/satchel(M), slot_back)
var/obj/item/weapon/card/id/W = new(M)
W.name = "[M.real_name]'s ID Card (Emergency Response Team Leader)"
W.name = "[M.real_name]'s ID Card (Emergency Response Team - Leader)"
W.icon_state = "centcom"
W.access = get_all_accesses()
W.access += get_all_centcom_access()
W.assignment = "Emergency Response Team Leader"
W.access = get_centcom_access(W.assignment)
W.registered_name = M.real_name
M.equip_to_slot_or_del(W, slot_wear_id)
@@ -980,9 +977,8 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
var/obj/item/weapon/card/id/W = new(M)
W.name = "[M.real_name]'s ID Card (Special Operations Officer)"
W.icon_state = "centcom"
W.access = get_all_accesses()
W.access += get_all_centcom_access()
W.assignment = "Special Operations Officer"
W.access = get_centcom_access(W.assignment)
W.registered_name = M.real_name
M.equip_to_slot_or_del(W, slot_wear_id)
@@ -1010,9 +1006,8 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
var/obj/item/weapon/card/id/W = new(M)
W.name = "[M.real_name]'s ID Card (Special Operations Officer)"
W.icon_state = "centcom"
W.access = get_all_accesses()
W.access += get_all_centcom_access()
W.assignment = "Special Operations Officer"
W.access = get_centcom_access(W.assignment)
W.registered_name = M.real_name
M.equip_to_slot_or_del(W, slot_wear_id)
@@ -1039,7 +1034,6 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
W.registered_name = M.real_name
M.equip_to_slot_or_del(W, slot_wear_id)
if("blue wizard")
M.equip_to_slot_or_del(new /obj/item/clothing/under/color/lightpurple(M), slot_w_uniform)
M.equip_to_slot_or_del(new /obj/item/clothing/suit/wizrobe(M), slot_wear_suit)
@@ -1116,9 +1110,8 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
var/obj/item/weapon/card/id/W = new(M)
W.name = "[M.real_name]'s ID Card (Deathsquad Officer)"
W.icon_state = "centcom"
W.access = get_all_accesses()
W.access += get_all_centcom_access()
W.assignment = "Deathsquad Officer"
W.access = get_centcom_access(W.assignment)
W.registered_name = M.real_name
M.equip_to_slot_or_del(W, slot_wear_id)
@@ -1150,9 +1143,8 @@ But you can call procs that are of type /mob/living/carbon/human/proc/ for that
var/obj/item/weapon/card/id/W = new(M)
W.name = "[M.real_name]'s ID Card (Deathsquad Officer)"
W.icon_state = "centcom"
W.access = get_all_accesses()
W.access += get_all_centcom_access()
W.assignment = "Deathsquad Officer"
W.access = get_centcom_access(W.assignment)
W.registered_name = M.real_name
M.equip_to_slot_or_del(W, slot_wear_id)
+1 -2
View File
@@ -168,9 +168,8 @@ var/global/sent_strike_team = 0
var/obj/item/weapon/card/id/W = new(src)
W.name = "[real_name]'s ID Card"
W.icon_state = "centcom"
W.access = get_all_accesses()//They get full station access.
W.access += list(access_cent_general, access_cent_specops, access_cent_living, access_cent_storage)//Let's add their alloted CentCom access.
W.assignment = "Death Commando"
W.access = get_centcom_access(W.assignment)
W.registered_name = real_name
equip_to_slot_or_del(W, slot_wear_id)
@@ -171,8 +171,8 @@ var/global/sent_syndicate_strike_team = 0
W.name = "[real_name]'s ID Card"
W.icon_state = "id"
W.access = get_all_accesses()//They get full station access because obviously the syndicate has HAAAX, and can make special IDs for their most elite members.
W.access += list(access_cent_general, access_cent_specops, access_cent_living, access_cent_storage, access_syndicate)//Let's add their forged CentCom access and syndicate access.
W.assignment = "Syndicate Commando"
W.access = get_syndicate_access(W.assignment)
W.registered_name = real_name
equip_to_slot_or_del(W, slot_wear_id)
+1 -1
View File
@@ -342,6 +342,6 @@
return accesses
authenticate()
if(access_cent_captain in reader.access)
if(access_cent_commander in reader.access)
return 1
return 0
+2 -2
View File
@@ -5,7 +5,7 @@
icon = 'icons/obj/computer.dmi'
icon_state = "aiupload"
density = 1
req_one_access = list(access_hop, access_captain, access_cent_captain)
req_one_access = list(access_hop, access_captain, access_cent_commander)
var/receipt_num
var/machine_id = ""
var/obj/item/weapon/card/id/held_card
@@ -16,7 +16,7 @@
proc/get_access_level()
if (!held_card)
return 0
if(access_cent_captain in held_card.access)
if(access_cent_commander in held_card.access)
return 2
else if(access_hop in held_card.access || access_captain in held_card.access)
return 1
+1 -1
View File
@@ -179,7 +179,7 @@
var/obj/item/I = usr.get_active_hand()
if (istype(I, /obj/item/weapon/card))
var/obj/item/weapon/card/id/C = I
if(access_cent_captain in C.access || access_hop in C.access || access_captain in C.access)
if(access_cent_commander in C.access || access_hop in C.access || access_captain in C.access)
access_code = 0
usr << "\icon[src]<span class='info'>Access code reset to 0.</span>"
else if (istype(I, /obj/item/weapon/card/emag))
+1 -1
View File
@@ -1,7 +1,7 @@
/obj/machinery/computer/shuttle_control/specops
name = "special operations shuttle console"
shuttle_tag = "Special Operations"
req_access = list(access_cent_general)
req_access = list(access_cent_specops)
/obj/machinery/computer/shuttle_control/specops/attack_ai(user as mob)
user << "\red Access Denied."