From a39ddcd5c4e8cd4b9dcfe21ce6f27fc12d5a169c Mon Sep 17 00:00:00 2001 From: Pelmenik123 <108460733+Pelmenik123@users.noreply.github.com> Date: Wed, 8 Jan 2025 02:28:36 +0300 Subject: [PATCH] bugfix --- code/datums/voice.dm | 24 ++++++++++---- code/game/jobs/job/job.dm | 2 +- code/game/jobs/job/medical.dm | 2 ++ code/game/jobs/job/security.dm | 2 ++ code/game/jobs/job/silicon.dm | 3 -- code/game/jobs/job/supervisor.dm | 2 ++ code/modules/economy/Job_Departments.dm | 31 +++++++++++++++++-- code/modules/mob/living/carbon/human/human.dm | 4 +-- .../mob/living/carbon/human/human_say.dm | 9 ++++++ code/modules/mob/mob_helpers.dm | 8 ++--- code/modules/mob/new_player/new_player.dm | 5 ++- 11 files changed, 71 insertions(+), 21 deletions(-) diff --git a/code/datums/voice.dm b/code/datums/voice.dm index 9cbe6a74c86..6b216a680e8 100644 --- a/code/datums/voice.dm +++ b/code/datums/voice.dm @@ -1,4 +1,5 @@ #define GENDER_NAME_UNKNOW list(MALE = "Незнакомец", FEMALE = "Незнакомка", NEUTER = "Неизвестный", PLURAL = "Неизвестный") +#define FACE_MOD_SWITCH TRUE //Новая система голоса /datum/voice_model var/mob/host = null //Носитель этой хуеты @@ -8,7 +9,7 @@ var/real_voice_name = "Неизвестный" var/list/famous_voices = list() - //var/list/famous_faces = list() + var/list/famous_faces = list() /datum/voice_model/New(var/mob/owner_voice) if(owner_voice != null) @@ -66,14 +67,14 @@ return t.fields["name"] return "IDENTIFICATION ERROR" //Технически name это представление твоего ебала -/* BYOND... + /datum/voice_model/proc/GetManifestKnowFace(mob/face_target) for(var/datum/data/record/t in GLOB.data_core.general) if(t) if(t.fields["name"] == face_target.name) return t.fields["name"] return "IDENTIFICATION FACE ERROR" -*/ + /datum/voice_model/proc/TryStore(mob/target) if(src == target.adv_voice) @@ -92,7 +93,8 @@ if(!((target_H.wear_mask?.flags_inv & HIDENAME) || (target_H.head?.flags_inv & HIDENAME)) && prov_wear_id) - //famous_faces[target_H.name] = prov_wear_id.registered_name //FUCK BYOND + if(FACE_MOD_SWITCH) + famous_faces[target_H.name] = prov_wear_id.registered_name //FUCK BYOND famous_voices[target_H.adv_voice.voice_name] = prov_wear_id.registered_name . = TRUE else if(prov_wear_id) @@ -101,7 +103,7 @@ return //For examie -/* FUCKING BYOND +// FUCKING BYOND /datum/voice_model/proc/TryRecollectFace(mob/target) if(src == target.adv_voice) return target.name @@ -120,7 +122,7 @@ else . = get_gender_unknown_name(target_H.gender) return -*/ + //For hear /datum/voice_model/proc/TryRecollectVoice(mob/target) if(!ishuman(host)) //Мышки мышки знают все.... @@ -144,4 +146,14 @@ return TRUE return FALSE +//HELPERS + +/proc/GenDepartamentVoiceTree(mob/target, list/departments) + var/list/result = list() + + for(var/dep_flag in departments) //:catsmile: + result[dep_flag] = list(target.adv_voice.voice_name = target.name) + + return result + #undef GENDER_NAME_UNKNOW diff --git a/code/game/jobs/job/job.dm b/code/game/jobs/job/job.dm index bf84c9c8e5b..d8ba8006c74 100644 --- a/code/game/jobs/job/job.dm +++ b/code/game/jobs/job/job.dm @@ -1,5 +1,5 @@ /datum/job - + //ПРЕДУПРЕЖДЕНИЕ ВСЕМ И ВСЯ, НЕ ЗАБЫВАЙТЕ ПРОПИСЫВАТЬ ДЕПОРТАМЕНТ В Job_Departamenst.dm ИНАЧЕ НАХУЙ ВСЕ СЛОМАЕТСЯ //The name of the job var/title = "NOPE" diff --git a/code/game/jobs/job/medical.dm b/code/game/jobs/job/medical.dm index 7f9a89f1b2c..0d79c46db5a 100644 --- a/code/game/jobs/job/medical.dm +++ b/code/game/jobs/job/medical.dm @@ -264,6 +264,8 @@ min_start_money = 200 max_start_money = 400 + college_department = list("Medical", "Science") + /datum/outfit/job/geneticist name = "Geneticist" jobtype = /datum/job/geneticist diff --git a/code/game/jobs/job/security.dm b/code/game/jobs/job/security.dm index 8f9cab1050f..230e73b2e89 100644 --- a/code/game/jobs/job/security.dm +++ b/code/game/jobs/job/security.dm @@ -274,6 +274,8 @@ min_start_money = 200 max_start_money = 550 + college_department = list("Security", "Medical") //:catsmile: + /datum/outfit/job/brigdoc name = "Brig Physician" jobtype = /datum/job/brigdoc diff --git a/code/game/jobs/job/silicon.dm b/code/game/jobs/job/silicon.dm index e5079638c36..bcb45e9ed33 100644 --- a/code/game/jobs/job/silicon.dm +++ b/code/game/jobs/job/silicon.dm @@ -13,8 +13,6 @@ exp_type = EXP_TYPE_SILICON insurance_type = INSURANCE_TYPE_NONE - college_department = list() //Синтам не нужны коллеги, ибо у них имена потом идут - /datum/job/ai/equip(mob/living/carbon/human/H) if(!H) return 0 @@ -39,7 +37,6 @@ insurance_type = INSURANCE_TYPE_NONE defoult_dep = FALSE - college_department = list() /datum/job/cyborg/equip(mob/living/carbon/human/H) if(!H) diff --git a/code/game/jobs/job/supervisor.dm b/code/game/jobs/job/supervisor.dm index 23f5989d43a..9c8c240d8c9 100644 --- a/code/game/jobs/job/supervisor.dm +++ b/code/game/jobs/job/supervisor.dm @@ -208,6 +208,8 @@ GLOBAL_DATUM_INIT(captain_announcement, /datum/announcement/minor, new(do_newsca min_start_money = 400 max_start_money = 700 + college_department = list("Command", "Security") + /datum/outfit/job/blueshield name = "Blueshield" jobtype = /datum/job/blueshield diff --git a/code/modules/economy/Job_Departments.dm b/code/modules/economy/Job_Departments.dm index f7d95c7d7b7..0b4781a0e43 100644 --- a/code/modules/economy/Job_Departments.dm +++ b/code/modules/economy/Job_Departments.dm @@ -11,6 +11,10 @@ GLOBAL_LIST_INIT(station_departments, list("Command", "Medical", "Engineering", /datum/job/captain/department = "Command" /datum/job/captain/head_position = 1 +/datum/job/nanotrasenrep/department = "Command" + +/datum/job/blueshield/department = "Command" + /datum/job/hop/department = "Support" /datum/job/hop/head_position = 1 @@ -22,26 +26,34 @@ GLOBAL_LIST_INIT(station_departments, list("Command", "Medical", "Engineering", /datum/job/hydro/department = "Support" -/datum/job/mining/department = "Support" - /datum/job/janitor/department = "Support" +/datum/job/clown/department = "Support" + +/datum/job/mime/department = "Support" + /datum/job/librarian/department = "Support" /datum/job/lawyer/department = "Support" /datum/job/chaplain/department = "Support" +/datum/job/explorer/department = "Support" + /datum/job/qm/department = "Cargo" /datum/job/qm/head_position = 1 /datum/job/cargo_tech/department = "Cargo" +/datum/job/mining/department = "Cargo" + /datum/job/chief_engineer/department = "Engineering" /datum/job/chief_engineer/head_position = 1 /datum/job/engineer/department = "Engineering" +/datum/job/mechanic/department = "Engineering" + /datum/job/atmos/department = "Engineering" /datum/job/engineer/trainee/department = "Engineering" @@ -51,10 +63,16 @@ GLOBAL_LIST_INIT(station_departments, list("Command", "Medical", "Engineering", /datum/job/doctor/department = "Medical" +/datum/job/coroner/department = "Medical" + /datum/job/chemist/department = "Medical" +/datum/job/virologist/department = "Medical" + /datum/job/geneticist/department = "Medical" +/datum/job/paramedic/department = "Medical" + /datum/job/psychiatrist/department = "Medical" /datum/job/doctor/intern/department = "Medical" @@ -77,3 +95,12 @@ GLOBAL_LIST_INIT(station_departments, list("Command", "Medical", "Engineering", /datum/job/officer/department = "Security" +/datum/job/brigdoc/department = "Security" + +/datum/job/pilot/department = "Security" + +/datum/job/judge/department = "Security" + +/datum/job/lawyer/department = "Security" + + diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm index 6538ad24030..65c003ec848 100644 --- a/code/modules/mob/living/carbon/human/human.dm +++ b/code/modules/mob/living/carbon/human/human.dm @@ -1964,7 +1964,6 @@ Eyes need to have significantly high darksight to shine unless the mob has the X if(istype(potential_spine)) carrydelay *= potential_spine.athletics_boost_multiplier */ - if(carrydelay <= 3 SECONDS) skills_space = " very quickly" else if(carrydelay <= 4 SECONDS) @@ -1980,5 +1979,6 @@ Eyes need to have significantly high darksight to shine unless the mob has the X if(!can_be_firemanned(target) || incapacitated(INC_IGNORE_GRABBED) || target.buckled) visible_message(span_warning("[src] fails to fireman carry [target]!")) return - + return buckle_mob(target, TRUE, FALSE, CARRIER_NEEDS_ARM) //checkloc is false because we usually grab people from nearest tile +//НЕ ВНОСИТЬ ИЗМЕНЕНИЯ, ЮБИЛЕЙНОЕ ЧИСЛО СТРОК diff --git a/code/modules/mob/living/carbon/human/human_say.dm b/code/modules/mob/living/carbon/human/human_say.dm index bcc9abbb6b4..7e244316cc5 100644 --- a/code/modules/mob/living/carbon/human/human_say.dm +++ b/code/modules/mob/living/carbon/human/human_say.dm @@ -8,6 +8,15 @@ return " (as [get_id_name("Unknown")])" return ..() +/mob/living/carbon/human/proc/GetDescription() + var/datum/species/prom_spec = dna.species + if(age < 24) + return "Young [prom_spec.name] [gender]" + if(age < 45) + return "Mature [prom_spec.name] [gender]" + if(age < 60) + return "Old [prom_spec.name] [gender]" + return "Ancient [prom_spec.name] [gender]" /mob/living/carbon/human/say_understands(mob/other, datum/language/speaking = null) if(dna?.species?.can_understand(other)) diff --git a/code/modules/mob/mob_helpers.dm b/code/modules/mob/mob_helpers.dm index 887fdae83a2..3befd346abf 100644 --- a/code/modules/mob/mob_helpers.dm +++ b/code/modules/mob/mob_helpers.dm @@ -525,7 +525,7 @@ GLOBAL_LIST_INIT(intents, list(INTENT_HELP,INTENT_DISARM,INTENT_GRAB,INTENT_HARM check_eye(src) return TRUE -/mob/proc/rename_character(oldname, newname, mass_update = FALSE) +/mob/proc/rename_character(oldname, newname, list/mass_update = list()) if(!newname) return 0 real_name = newname @@ -578,11 +578,11 @@ GLOBAL_LIST_INIT(intents, list(INTENT_HELP,INTENT_DISARM,INTENT_GRAB,INTENT_HARM pos = findtextEx_char(objective.explanation_text, oldname) objective.explanation_text = copytext_char(objective.explanation_text, 1, pos)+newname+copytext_char(objective.explanation_text, pos+length) UpdateVoice() - if(mass_update) - SEND_GLOBAL_SIGNAL(COMSIG_SPECIAL_MASS_STORE_VOICE, list("AbsolutePomny" = (list((adv_voice.voice_name) = name)))) + if(LAZYLEN(mass_update) != 0) + SEND_GLOBAL_SIGNAL(COMSIG_SPECIAL_MASS_STORE_VOICE, GenDepartamentVoiceTree(src, mass_update)) return 1 -/mob/proc/rename_self(var/role, var/allow_numbers = FALSE, var/force = FALSE, var/mass_update = FALSE) +/mob/proc/rename_self(var/role, var/allow_numbers = FALSE, var/force = FALSE, list/mass_update = list()) spawn(0) var/oldname = real_name diff --git a/code/modules/mob/new_player/new_player.dm b/code/modules/mob/new_player/new_player.dm index 90ba383859d..a3290052804 100644 --- a/code/modules/mob/new_player/new_player.dm +++ b/code/modules/mob/new_player/new_player.dm @@ -614,15 +614,14 @@ // stop_sound_channel(CHANNEL_LOBBYMUSIC) client?.tgui_panel?.stop_music() - if(mind) mind.active = 0 //we wish to transfer the key manually if(mind.assigned_role == JOB_TITLE_CLOWN) //give them a clownname if they are a clown new_character.real_name = pick(GLOB.clown_names) //I hate this being here of all places but unfortunately dna is based on real_name! - new_character.rename_self(JOB_TITLE_CLOWN, mass_update = TRUE) + new_character.rename_self(JOB_TITLE_CLOWN, mass_update = list("Support")) else if(mind.assigned_role == JOB_TITLE_MIME) new_character.real_name = pick(GLOB.mime_names) - new_character.rename_self(JOB_TITLE_MIME, mass_update = TRUE) + new_character.rename_self(JOB_TITLE_MIME, mass_update = list("Support")) mind.set_original_mob(new_character) mind.transfer_to(new_character) //won't transfer key since the mind is not active GLOB.human_names_list += new_character.real_name