diff --git a/code/game/jobs/job/captain.dm b/code/game/jobs/job/captain.dm index 596f078eca..fc467d4f71 100644 --- a/code/game/jobs/job/captain.dm +++ b/code/game/jobs/job/captain.dm @@ -23,7 +23,8 @@ var/datum/announcement/minor/captain_announcement = new(do_newscast = 1) economic_modifier = 20 minimum_character_age = 25 - ideal_character_age = 70 // Old geezer captains ftw + min_age_by_species = list(SPECIES_UNATHI = 70, SPECIES_TESHARI = 20, "mechanical" = 10) +/// ideal_character_age = 70 // Old geezer captains ftw outfit_type = /decl/hierarchy/outfit/job/captain job_description = "The Site Manager manages the other Command Staff, and through them the rest of the station. Though they have access to everything, \ @@ -31,6 +32,7 @@ var/datum/announcement/minor/captain_announcement = new(do_newscast = 1) have an understanding of Standard Operating Procedure, and is subject to it, and legal action, in the same way as every other crew member." alt_titles = list("Overseer"= /datum/alt_title/overseer) + /* /datum/job/captain/equip(var/mob/living/carbon/human/H) . = ..() @@ -66,7 +68,8 @@ var/datum/announcement/minor/captain_announcement = new(do_newscast = 1) economic_modifier = 10 minimum_character_age = 25 - ideal_character_age = 50 + min_age_by_species = list(SPECIES_UNATHI = 70, SPECIES_TESHARI = 20, "mechanical" = 10) +/// ideal_character_age = 50 outfit_type = /decl/hierarchy/outfit/job/hop job_description = "The Head of Personnel manages the Service department, the Exploration team, and most other civilians. They also \ diff --git a/code/game/jobs/job/engineering.dm b/code/game/jobs/job/engineering.dm index ae937d106b..06ee1c6fc9 100644 --- a/code/game/jobs/job/engineering.dm +++ b/code/game/jobs/job/engineering.dm @@ -17,7 +17,8 @@ economic_modifier = 10 minimum_character_age = 25 - ideal_character_age = 50 + min_age_by_species = list(SPECIES_UNATHI = 70, SPECIES_TESHARI = 20, "mechanical" = 10) +/// ideal_character_age = 50 access = list(access_engine, access_engine_equip, access_tech_storage, access_maint_tunnels, @@ -55,6 +56,8 @@ "Engine Technician" = /datum/alt_title/engine_tech, "Electrician" = /datum/alt_title/electrician) minimal_player_age = 3 + minimum_character_age = 1 + min_age_by_species = list(SPECIES_PROMETHEAN = 2) outfit_type = /decl/hierarchy/outfit/job/engineering/engineer job_description = "An Engineer keeps the station running. They repair damages, keep the atmosphere stable, and ensure that power is being \ @@ -94,6 +97,8 @@ minimal_access = list(access_eva, access_engine, access_atmospherics, access_maint_tunnels, access_emergency_storage, access_construction, access_external_airlocks) minimal_player_age = 3 + minimum_character_age = 1 + min_age_by_species = list(SPECIES_PROMETHEAN = 2) outfit_type = /decl/hierarchy/outfit/job/engineering/atmos job_description = "An Atmospheric Technician is primarily concerned with keeping the station's atmosphere breathable. They are expected to have a good \ diff --git a/code/game/jobs/job/job.dm b/code/game/jobs/job/job.dm index b78fc5f74a..b812c4b39c 100644 --- a/code/game/jobs/job/job.dm +++ b/code/game/jobs/job/job.dm @@ -22,6 +22,7 @@ var/department_accounts = null // Which department accounts should people with this position be given the pin for? var/assignable = TRUE // Should it show up on things like the ID computer? var/minimum_character_age = 0 + var/list/min_age_by_species = null var/ideal_character_age = 30 var/has_headset = TRUE //Do people with this job need to be given headsets and told how to use them? E.g. Cyborgs don't. @@ -158,4 +159,9 @@ if(mannequin.back) var/obj/O = mannequin.back mannequin.drop_from_inventory(O) - qdel(O) \ No newline at end of file + qdel(O) + +///Assigns minimum age by race & brain type. Code says Positronic = mechanical and Drone = digital because nothing can be simple. +///Will first check based on brain type, then based on species. +/datum/job/proc/get_min_age(species_name, brain_type) + return (brain_type && LAZYACCESS(min_age_by_species, brain_type)) || LAZYACCESS(min_age_by_species, species_name) || minimum_character_age \ No newline at end of file diff --git a/code/game/jobs/job/medical.dm b/code/game/jobs/job/medical.dm index e74b0798b6..b91b546e61 100644 --- a/code/game/jobs/job/medical.dm +++ b/code/game/jobs/job/medical.dm @@ -23,8 +23,9 @@ access_keycard_auth, access_sec_doors, access_psychiatrist, access_eva, access_external_airlocks, access_maint_tunnels) minimum_character_age = 25 + min_age_by_species = list(SPECIES_UNATHI = 70, SPECIES_TESHARI = 20, "mechanical" = 10) minimal_player_age = 10 - ideal_character_age = 50 +// ideal_character_age = 50 outfit_type = /decl/hierarchy/outfit/job/medical/cmo job_description = "The CMO manages the Medical department and is a position requiring experience and skill; their goal is to ensure that their \ @@ -58,6 +59,9 @@ "Nurse" = /datum/alt_title/nurse, "Virologist" = /datum/alt_title/virologist) + minimum_character_age = 1 + min_age_by_species = list(SPECIES_PROMETHEAN = 3) + //Medical Doctor Alt Titles /datum/alt_title/surgeon title = "Surgeon" @@ -103,6 +107,8 @@ access = list(access_medical, access_medical_equip, access_morgue, access_surgery, access_chemistry, access_virology, access_genetics) minimal_access = list(access_medical, access_medical_equip, access_chemistry) minimal_player_age = 3 + minimum_character_age = 0 + min_age_by_species = list(SPECIES_PROMETHEAN = 3) outfit_type = /decl/hierarchy/outfit/job/medical/chemist job_description = "A Chemist produces and maintains a stock of basic to advanced chemicals for medical and occasionally research use. \ @@ -186,6 +192,9 @@ They may also be called upon to keep patients stable when Medical is busy or understaffed." alt_titles = list("Emergency Medical Technician" = /datum/alt_title/emt) + minimum_character_age = 1 + min_age_by_species = list(SPECIES_PROMETHEAN = 2) + // Paramedic Alt Titles /datum/alt_title/emt title = "Emergency Medical Technician" diff --git a/code/game/jobs/job/science.dm b/code/game/jobs/job/science.dm index 4edc848d0e..b861c28984 100644 --- a/code/game/jobs/job/science.dm +++ b/code/game/jobs/job/science.dm @@ -26,7 +26,8 @@ minimum_character_age = 25 minimal_player_age = 14 - ideal_character_age = 50 + min_age_by_species = list(SPECIES_UNATHI = 70, SPECIES_TESHARI = 20, "mechanical" = 10) +/// ideal_character_age = 50 outfit_type = /decl/hierarchy/outfit/job/science/rd job_description = "The Research Director manages and maintains the Research department. They are required to ensure the safety of the entire crew, \ @@ -35,6 +36,7 @@ are encouraged to allow their staff to perform their own duties." alt_titles = list("Research Supervisor" = /datum/alt_title/research_supervisor) + // Research Director Alt Titles /datum/alt_title/research_supervisor title = "Research Supervisor" @@ -100,6 +102,8 @@ minimal_access = list(access_research, access_xenobiology, access_hydroponics, access_tox_storage) minimal_player_age = 14 + minimum_character_age = 1 + min_age_by_species = list(SPECIES_PROMETHEAN = 2) outfit_type = /decl/hierarchy/outfit/job/science/xenobiologist job_description = "A Xenobiologist studies esoteric lifeforms, usually in the relative safety of their lab. They attempt to find ways to benefit \ @@ -129,6 +133,8 @@ access = list(access_robotics, access_tox, access_tox_storage, access_tech_storage, access_morgue, access_research) //As a job that handles so many corpses, it makes sense for them to have morgue access. minimal_access = list(access_robotics, access_tech_storage, access_morgue, access_research) //As a job that handles so many corpses, it makes sense for them to have morgue access. minimal_player_age = 7 + minimum_character_age = 1 + min_age_by_species = list(SPECIES_PROMETHEAN = 2) outfit_type = /decl/hierarchy/outfit/job/science/roboticist job_description = "A Roboticist maintains and repairs the station's synthetics, including crew with prosthetic limbs. \ diff --git a/code/game/jobs/job/security.dm b/code/game/jobs/job/security.dm index 52f0d71006..a639c49283 100644 --- a/code/game/jobs/job/security.dm +++ b/code/game/jobs/job/security.dm @@ -24,6 +24,7 @@ access_research, access_engine, access_mining, access_medical, access_construction, access_mailsorting, access_heads, access_hos, access_RC_announce, access_keycard_auth, access_gateway, access_external_airlocks) minimum_character_age = 25 + min_age_by_species = list(SPECIES_UNATHI = 70, SPECIES_TESHARI = 20, "mechanical" = 10) minimal_player_age = 14 outfit_type = /decl/hierarchy/outfit/job/security/hos @@ -32,6 +33,7 @@ perform the duties of absent Security roles, such as distributing gear from the Armory." alt_titles = list("Security Commander" = /datum/alt_title/sec_commander, "Chief of Security" = /datum/alt_title/sec_chief) + // Head of Security Alt Titles /datum/alt_title/sec_commander title = "Security Commander" @@ -117,6 +119,9 @@ No one is above the Law, not Security or Command." alt_titles = list("Junior Officer" = /datum/alt_title/junior_officer) + minimum_character_age = 1 + min_age_by_species = list(SPECIES_PROMETHEAN = 3) + // Security Officer Alt Titles /datum/alt_title/junior_officer title = "Junior Officer" diff --git a/code/game/jobs/job_controller.dm b/code/game/jobs/job_controller.dm index 5eaede945a..893dbc9604 100644 --- a/code/game/jobs/job_controller.dm +++ b/code/game/jobs/job_controller.dm @@ -54,7 +54,7 @@ var/global/datum/controller/occupations/job_master var/datum/job/job = GetJob(rank) if(!job) return 0 - if(job.minimum_character_age && (player.client.prefs.age < job.minimum_character_age)) + if(job.minimum_character_age && (player.client.prefs.age < job.get_min_age(player.client.prefs.species, player.client.prefs.organ_data["brain"]))) return 0 if(jobban_isbanned(player, rank)) return 0 diff --git a/code/modules/client/preference_setup/occupation/occupation.dm b/code/modules/client/preference_setup/occupation/occupation.dm index 99c0d04685..9d5d14ddb8 100644 --- a/code/modules/client/preference_setup/occupation/occupation.dm +++ b/code/modules/client/preference_setup/occupation/occupation.dm @@ -123,8 +123,8 @@ var/available_in_days = job.available_in_days(user.client) . += "[rank] \[IN [(available_in_days)] DAYS]" continue - if(job.minimum_character_age && user.client && (user.client.prefs.age < job.minimum_character_age)) - . += "[rank] \[MINIMUM CHARACTER AGE: [job.minimum_character_age]]" + if(job.minimum_character_age && user.client && (user.client.prefs.age < job.get_min_age(user.client.prefs.species, user.client.prefs.organ_data["brain"]))) + . += "[rank] \[MINIMUM CHARACTER AGE FOR SELECTED RACE & BRAIN TYPE: [job.get_min_age(user.client.prefs.species, user.client.prefs.organ_data["brain"])]\]" continue if((pref.job_civilian_low & ASSISTANT) && job.type != /datum/job/assistant) . += "[rank]" diff --git a/code/modules/mob/living/carbon/human/species/station/prometheans.dm b/code/modules/mob/living/carbon/human/species/station/prometheans.dm index 38fc0ed83a..c4e39284c0 100644 --- a/code/modules/mob/living/carbon/human/species/station/prometheans.dm +++ b/code/modules/mob/living/carbon/human/species/station/prometheans.dm @@ -45,7 +45,7 @@ var/datum/species/shapeshifter/promethean/prometheans female_cough_sounds = list('sound/effects/slime_squish.ogg') min_age = 1 - max_age = 10 + max_age = 16 economic_modifier = 3 diff --git a/code/modules/mob/new_player/new_player.dm b/code/modules/mob/new_player/new_player.dm index 512df98a92..47ba7d669f 100644 --- a/code/modules/mob/new_player/new_player.dm +++ b/code/modules/mob/new_player/new_player.dm @@ -494,7 +494,7 @@ for(var/datum/job/job in job_master.occupations) if(job && IsJobAvailable(job.title)) // Checks for jobs with minimum age requirements - if(job.minimum_character_age && (client.prefs.age < job.minimum_character_age)) + if(job.minimum_character_age && (client.prefs.age < job.get_min_age(client.prefs.species, client.prefs.organ_data["brain"]))) continue // Checks for jobs set to "Never" in preferences //TODO: Figure out a better way to check for this if(!(client.prefs.GetJobDepartment(job, 1) & job.flag)) diff --git a/maps/southern_cross/southern_cross_jobs.dm b/maps/southern_cross/southern_cross_jobs.dm index 0903a3ac3d..aa90106235 100644 --- a/maps/southern_cross/southern_cross_jobs.dm +++ b/maps/southern_cross/southern_cross_jobs.dm @@ -108,6 +108,8 @@ var/const/access_explorer = 43 economic_modifier = 4 access = list(access_medical, access_medical_equip, access_morgue, access_surgery, access_chemistry, access_virology, access_eva, access_maint_tunnels, access_external_airlocks, access_psychiatrist, access_explorer) minimal_access = list(access_medical, access_medical_equip, access_morgue, access_explorer) + minimum_character_age = 1 + min_age_by_species = list(SPECIES_PROMETHEAN = 2) outfit_type = /decl/hierarchy/outfit/job/medical/sar job_description = "A Search and Rescue operative recovers individuals who are injured or dead on the surface of Sif." \ No newline at end of file