Skip to content

Commit

Permalink
Переделка экзамайна и новые переменные
Browse files Browse the repository at this point in the history
  • Loading branch information
YegorKandziuba committed Oct 29, 2023
1 parent ee61d5f commit d0369b2
Show file tree
Hide file tree
Showing 3 changed files with 34 additions and 0 deletions.
9 changes: 9 additions & 0 deletions mods/_rus/_rus.dm
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
/singleton/modpack/russian_names
name = "Руссификация"
desc = @{"Руссификация переменных name и desc"}

/atom
var/name_rus
var/desc_rus

/atom/Initialize(mapload, ...)
. = ..()
if(!name_rus) name_rus = name
if(!desc_rus) desc_rus = desc
1 change: 1 addition & 0 deletions mods/_rus/_rus.dme
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#define MODPACK_RUSSIAN_NAME

#include "_rus.dm"
#include "code/proc/examine.dm"
#include "code/obj/tools.dm"
#include "code/obj/tanks.dm"
#include "code/obj/storage/storage.dm"
Expand Down
24 changes: 24 additions & 0 deletions mods/_rus/code/proc/examine.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
/atom/examine(mob/user, distance, is_adjacent, infix = "", suffix = "")
if(FALSE /*client.get_preference_value(умнаяхуйня/language) == GLOB.PREF_LANG_EN*/ ) return ..()
var/f_name = "<b>[src][infix].</b>"
if(blood_color && !istype(src, /obj/decal))
f_name = "[name_rus][infix]. Видны следы крови!"

to_chat(user, "[icon2html(src, user)] Это [f_name] [suffix]")
to_chat(user, desc_rus)
if (get_max_health())
examine_damage_state(user)

if (IsFlameSource())
to_chat(user, SPAN_DANGER("Виден открытый огонь."))
else if (distance <= 1 && IsHeatSource())
to_chat(user, SPAN_WARNING("Слишком горячо для касания."))

return TRUE

/// Works same as /atom/proc/Examine(), only this output comes immediately after any and all made by /atom/proc/Examine()
/atom/LateExamine(mob/user, distance, is_adjacent)
SHOULD_NOT_SLEEP(TRUE)

user.ForensicsExamination(src, distance)
return TRUE

0 comments on commit d0369b2

Please sign in to comment.