Files
GS13NG/code/modules/jobs/jobs.dm
T
PoojawaandGitHub 7e9b96a00f April sync (#360)
* Maps and things no code/icons

* helpers defines globalvars

* Onclick world.dm orphaned_procs

* subsystems

Round vote and shuttle autocall done here too

* datums

* Game folder

* Admin - chatter modules

* clothing - mining

* modular computers - zambies

* client

* mob level 1

* mob stage 2 + simple_animal

* silicons n brains

* mob stage 3 + Alien/Monkey

* human mobs

* icons updated

* some sounds

* emitter y u no commit

* update tgstation.dme

* compile fixes

* travis fixes

Also removes Fast digest mode, because reasons.

* tweaks for travis Mentors are broke again

Also fixes Sizeray guns

* oxygen loss fix for vore code.

* removes unused code

* some code updates

* bulk fixes

* further fixes

* outside things

* whoops.

* Maint bar ported

* GLOBs.
2017-04-13 23:37:00 -05:00

109 lines
2.9 KiB
Plaintext

GLOBAL_LIST_INIT(command_positions, list(
"Captain",
"Head of Personnel",
"Head of Security",
"Chief Engineer",
"Research Director",
"Chief Medical Officer"))
GLOBAL_LIST_INIT(engineering_positions, list(
"Chief Engineer",
"Station Engineer",
"Atmospheric Technician"))
GLOBAL_LIST_INIT(medical_positions, list(
"Chief Medical Officer",
"Medical Doctor",
"Geneticist",
"Virologist",
"Chemist"))
GLOBAL_LIST_INIT(science_positions, list(
"Research Director",
"Scientist",
"Roboticist"))
GLOBAL_LIST_INIT(supply_positions, list(
"Head of Personnel",
"Quartermaster",
"Cargo Technician",
"Shaft Miner"))
GLOBAL_LIST_INIT(civilian_positions, list(
"Bartender",
"Botanist",
"Cook",
"Janitor",
"Librarian",
"Lawyer",
"Chaplain",
"Clown",
"Mime",
"Assistant"))
GLOBAL_LIST_INIT(security_positions, list(
"Head of Security",
"Warden",
"Detective",
"Security Officer"))
GLOBAL_LIST_INIT(nonhuman_positions, list(
"AI",
"Cyborg",
"pAI"))
/proc/guest_jobbans(job)
return ((job in GLOB.command_positions) || (job in GLOB.nonhuman_positions) || (job in GLOB.security_positions))
//this is necessary because antags happen before job datums are handed out, but NOT before they come into existence
//so I can't simply use job datum.department_head straight from the mind datum, laaaaame.
/proc/get_department_heads(var/job_title)
if(!job_title)
return list()
for(var/datum/job/J in SSjob.occupations)
if(J.title == job_title)
return J.department_head //this is a list
/proc/get_full_job_name(job)
var/static/regex/cap_expand = new("cap(?!tain)")
var/static/regex/cmo_expand = new("cmo")
var/static/regex/hos_expand = new("hos")
var/static/regex/hop_expand = new("hop")
var/static/regex/rd_expand = new("rd")
var/static/regex/ce_expand = new("ce")
var/static/regex/qm_expand = new("qm")
var/static/regex/sec_expand = new("(?<!security )officer")
var/static/regex/engi_expand = new("(?<!station )engineer")
var/static/regex/atmos_expand = new("atmos tech")
var/static/regex/doc_expand = new("(?<!medical )doctor|medic(?!al)")
var/static/regex/mine_expand = new("(?<!shaft )miner")
var/static/regex/chef_expand = new("chef")
var/static/regex/borg_expand = new("(?<!cy)borg")
job = lowertext(job)
job = cap_expand.Replace(job, "captain")
job = cmo_expand.Replace(job, "chief medical officer")
job = hos_expand.Replace(job, "head of security")
job = hop_expand.Replace(job, "head of personnel")
job = rd_expand.Replace(job, "research director")
job = ce_expand.Replace(job, "chief engineer")
job = qm_expand.Replace(job, "quartermaster")
job = sec_expand.Replace(job, "security officer")
job = engi_expand.Replace(job, "station engineer")
job = atmos_expand.Replace(job, "atmospheric technician")
job = doc_expand.Replace(job, "medical doctor")
job = mine_expand.Replace(job, "shaft miner")
job = chef_expand.Replace(job, "cook")
job = borg_expand.Replace(job, "cyborg")
return job