Added agent id occupation options

This commit is contained in:
Rasmus Dyhr Larsen
2018-04-05 23:59:50 +02:00
parent b6abc4098a
commit 5065221dd6
+31 -1
View File
@@ -440,7 +440,37 @@
RebuildHTML()
if("Occupation")
var/new_job = sanitize(stripped_input(user,"What job would you like to put on this card?\nChanging occupation will not grant or remove any access levels.","Agent Card Occupation", "Civilian", MAX_MESSAGE_LEN))
var/list/departments =list(
"Civilian",
"Engineering",
"Medical",
"Science",
"Security",
"Support",
"Command",
"Custom",
)
var/department = input(user, "What job would you like to put on this card?\nChoose a department or a custom job title.\nChanging occupation will not grant or remove any access levels.","Agent Card Occupation") in departments
var/new_job = "Civilian"
if(department == "Custom")
new_job = sanitize(stripped_input(user,"Choose a custom jon title:","Agent Card Occupation", "Civilian", MAX_MESSAGE_LEN))
else if(department != "Civilian")
switch(department)
if("Engineering")
new_job = input(user, "What job would you like to put on this card?\nChanging occupation will not grant or remove any access levels.","Agent Card Occupation") in engineering_positions
if("Medical")
new_job = input(user, "What job would you like to put on this card?\nChanging occupation will not grant or remove any access levels.","Agent Card Occupation") in medical_positions
if("Science")
new_job = input(user, "What job would you like to put on this card?\nChanging occupation will not grant or remove any access levels.","Agent Card Occupation") in science_positions
if("Security")
new_job = input(user, "What job would you like to put on this card?\nChanging occupation will not grant or remove any access levels.","Agent Card Occupation") in security_positions
if("Support")
new_job = input(user, "What job would you like to put on this card?\nChanging occupation will not grant or remove any access levels.","Agent Card Occupation") in support_positions
if("Command")
new_job = input(user, "What job would you like to put on this card?\nChanging occupation will not grant or remove any access levels.","Agent Card Occupation") in command_positions
if(!Adjacent(user))
return
src.assignment = new_job