Skip to content

Commit

Permalink
dorabotochka
Browse files Browse the repository at this point in the history
  • Loading branch information
Antoonij authored Nov 16, 2024
1 parent eef7e0a commit 36272cc
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
18 changes: 9 additions & 9 deletions code/game/dna/genes/disabilities.dm
Original file line number Diff line number Diff line change
Expand Up @@ -389,31 +389,31 @@

/datum/dna/gene/disability/aphasia
name = "Aphasia"
desc = "Цель забывает как говорить на общегалактическом."
desc = "Цель забывает язык повседневного общения."
activation_message = list("Вам становится труднее выражать свои мысли. Meh nahbleh blahmeh?")
deactivation_message = list("Ваша речь возвращается в норму.")
instability = -GENE_INSTABILITY_MINOR

/datum/dna/gene/disability/aphasia/New()
..()
. = ..()
block = GLOB.aphasiablock

/datum/dna/gene/disability/aphasia/can_activate(mob/living/carbon/human/H, flags)
if(isplasmaman(H) || iswryn(H))
to_chat(H, span_warning("Вы чувствуете, что что-то не так, но не можете понять, что именно."))
return FALSE
. = ..()

return ..()

/datum/dna/gene/disability/aphasia/activate(mob/living/carbon/human/H, flags)
. = ..()
if(H.remove_language(LANGUAGE_GALACTIC_COMMON))
H.add_language(LANGUAGE_GALACTIC_COMMON, TRUE)
if(H.dna.species.default_language == LANGUAGE_GALACTIC_COMMON)
H.dna.species.default_language = H.dna.species.language
if(H.remove_language(H.dna.species.default_language))
H.add_language(H.dna.species.default_language, TRUE)
H.dna.species.default_language = H.dna.species.language


/datum/dna/gene/disability/aphasia/deactivate(mob/living/carbon/human/H, flags)
. = ..()
if(H.remove_language(LANGUAGE_GALACTIC_COMMON, TRUE))
H.add_language(LANGUAGE_GALACTIC_COMMON)
if(H.remove_language(initial(H.dna.species.default_language), TRUE))
H.add_language(initial(H.dna.species.default_language))
H.dna.species.default_language = initial(H.dna.species.default_language)
4 changes: 2 additions & 2 deletions code/modules/mob/language.dm
Original file line number Diff line number Diff line change
Expand Up @@ -909,7 +909,7 @@
// Language handling.
/mob/proc/add_language(language_name, var/only_listening = FALSE)
if(SEND_SIGNAL(src, COMSIG_MOB_LANGUAGE_ADD, language_name) & DISEASE_MOB_LANGUAGE_PROCESSED)
return TRUE
return FALSE

var/datum/language/new_language = GLOB.all_languages[language_name]
if(new_language in languages)
Expand All @@ -932,7 +932,7 @@

/mob/proc/remove_language(language_name, var/only_listening = FALSE)
if(SEND_SIGNAL(src, COMSIG_MOB_LANGUAGE_REMOVE, language_name) & DISEASE_MOB_LANGUAGE_PROCESSED)
return TRUE
return FALSE

var/datum/language/rem_language = GLOB.all_languages[language_name]
if(!istype(rem_language))
Expand Down

0 comments on commit 36272cc

Please sign in to comment.