Skip to content

Commit

Permalink
Перевод консоли коммуникаций и связанных с ней вещей (TauCetiStation#…
Browse files Browse the repository at this point in the history
…13113)

* based

* sus

* Update communications.dm

* Update security_levels.dm

* Update communications.dm

* Update communications.dm

* Update communications.dm

* Update alarm.dm

* Update code/game/machinery/computer/communications.dm

Co-authored-by: Azzy <[email protected]>

* Update code/game/machinery/computer/communications.dm

Co-authored-by: Azzy <[email protected]>

* Update code/game/machinery/computer/communications.dm

Co-authored-by: Azzy <[email protected]>

* Update code/game/machinery/computer/communications.dm

Co-authored-by: Azzy <[email protected]>

* Update code/game/machinery/computer/communications.dm

Co-authored-by: Azzy <[email protected]>

* Update communications.dm

* Update code/game/machinery/alarm.dm

* Update alarm.dm

* Update code/game/machinery/computer/communications.dm

Co-authored-by: KandreyKandrey <[email protected]>

* Update code/game/machinery/computer/communications.dm

Co-authored-by: AirBlack <[email protected]>

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

Co-authored-by: simb11 <[email protected]>

* Update communications.dm

* Update communications.dm

* Update code/game/machinery/computer/communications.dm

Co-authored-by: daedrowe <[email protected]>

* Update code/game/machinery/computer/communications.dm

Co-authored-by: daedrowe <[email protected]>

* Update code/game/machinery/computer/communications.dm

Co-authored-by: daedrowe <[email protected]>

* Update code/game/machinery/alarm.dm

Co-authored-by: daedrowe <[email protected]>

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

Co-authored-by: Alexander V. <[email protected]>

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/datums/announcements/events.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Last Fix

Co-Authored-By: Alexander V. <[email protected]>

* Update response_team.dm

* asdsa

* Update code/game/machinery/computer/communications.dm

Co-authored-by: KIBORG04 <[email protected]>

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

Co-authored-by: KIBORG04 <[email protected]>

* Update code/game/machinery/computer/communications.dm

Co-authored-by: daedrowe <[email protected]>

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/alarm.dm

Co-authored-by: KIBORG04 <[email protected]>

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/alarm.dm

Co-authored-by: KIBORG04 <[email protected]>

* Update code/game/machinery/computer/communications.dm

* Фиксим цвет, спасибо Пикачушке за помощь

Co-Authored-By: NinjaPikachuska <[email protected]>

* Update code/game/machinery/computer/communications.dm

* Apply suggestions from code review

* Update code/game/machinery/alarm.dm

Co-authored-by: KIBORG04 <[email protected]>

* Update code/game/machinery/computer/communications.dm

* Update code/game/machinery/computer/communications.dm

* Update communications.dm

* Update communications.dm

* Update communications.dm

* Apply suggestions from code review

@AmnyamNyam thanks

Co-authored-by: Amnyam <[email protected]>

* Apply suggestions from code review

Co-authored-by: Amnyam <[email protected]>

* Apply suggestions from code review

Co-authored-by: Amnyam <[email protected]>

---------

Co-authored-by: Azzy <[email protected]>
Co-authored-by: KandreyKandrey <[email protected]>
Co-authored-by: AirBlack <[email protected]>
Co-authored-by: Kiroma <[email protected]>
Co-authored-by: simb11 <[email protected]>
Co-authored-by: daedrowe <[email protected]>
Co-authored-by: Alexander V. <[email protected]>
Co-authored-by: Alexander V. <[email protected]>
Co-authored-by: KIBORG04 <[email protected]>
Co-authored-by: NinjaPikachuska <[email protected]>
Co-authored-by: Amnyam <[email protected]>
  • Loading branch information
12 people authored Oct 20, 2024
1 parent 4626050 commit ccb8f88
Show file tree
Hide file tree
Showing 9 changed files with 137 additions and 161 deletions.
8 changes: 4 additions & 4 deletions code/__DEFINES/misc.dm
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,10 @@
#define GAME_STATE_FINISHED 4

//Security levels
#define SEC_LEVEL_GREEN 0
#define SEC_LEVEL_BLUE 1
#define SEC_LEVEL_RED 2
#define SEC_LEVEL_DELTA 3
#define SEC_LEVEL_GREEN 1
#define SEC_LEVEL_BLUE 2
#define SEC_LEVEL_RED 3
#define SEC_LEVEL_DELTA 4

#define ROUNDSTART_LOGOUT_REPORT_TIME 6000 //Amount of time (in deciseconds) after the rounds starts, that the player disconnect report is issued.

Expand Down
2 changes: 1 addition & 1 deletion code/datums/wires/nuclearbomb.dm
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ var/global/const/NUKE_WIRE_SAFETY = 4
N.timing = 0
if(istype(N, /obj/machinery/nuclearbomb/fake))
return
if(get_security_level() == "delta")
if(code_name_eng[security_level] == "delta")
set_security_level("red")

if(NUKE_WIRE_SAFETY)
Expand Down
22 changes: 13 additions & 9 deletions code/game/machinery/alarm.dm
Original file line number Diff line number Diff line change
Expand Up @@ -1134,7 +1134,7 @@ FIRE ALARM
d2 = text("<A href='?src=\ref[];time=1'>Initiate Time Lock</A>", src)
var/second = round(time) % 60
var/minute = (round(time) - second) / 60
var/dat = "[d1]\n<HR><b>The current alert level is: [get_security_level()]</b><br><br>\nTimer System: [d2]<BR>\nTime Left: [(minute ? "[minute]:" : null)][second] <A href='?src=\ref[src];tp=-30'>-</A> <A href='?src=\ref[src];tp=-1'>-</A> <A href='?src=\ref[src];tp=1'>+</A> <A href='?src=\ref[src];tp=30'>+</A>\n"
var/dat = "[d1]\n<HR><b>The current alert level is: [code_name_eng[security_level]]</b><br><br>\nTimer System: [d2]<BR>\nTime Left: [(minute ? "[minute]:" : null)][second] <A href='?src=\ref[src];tp=-30'>-</A> <A href='?src=\ref[src];tp=-1'>-</A> <A href='?src=\ref[src];tp=1'>+</A> <A href='?src=\ref[src];tp=30'>+</A>\n"

var/datum/browser/popup = new(user, "window=firealarm", src.name)
popup.set_content(dat)
Expand All @@ -1151,7 +1151,7 @@ FIRE ALARM
d2 = text("<A href='?src=\ref[];time=1'>[]</A>", src, stars("Initiate Time Lock"))
var/second = round(time) % 60
var/minute = (round(time) - second) / 60
var/dat = "[d1]\n<HR><b>The current alert level is: [stars(get_security_level())]</b><br><br>\nTimer System: [d2]<BR>\nTime Left: [(minute ? text("[]:", minute) : null)][second] <A href='?src=\ref[src];tp=-30'>-</A> <A href='?src=\ref[src];tp=-1'>-</A> <A href='?src=\ref[src];tp=1'>+</A> <A href='?src=\ref[src];tp=30'>+</A>\n"
var/dat = "[d1]\n<HR><b>The current alert level is: [stars(code_name_eng[security_level])]</b><br><br>\nTimer System: [d2]<BR>\nTime Left: [(minute ? text("[]:", minute) : null)][second] <A href='?src=\ref[src];tp=-30'>-</A> <A href='?src=\ref[src];tp=-1'>-</A> <A href='?src=\ref[src];tp=1'>+</A> <A href='?src=\ref[src];tp=30'>+</A>\n"

var/datum/browser/popup = new(user, "window=firealarm", stars(src.name))
popup.set_content(dat)
Expand Down Expand Up @@ -1216,16 +1216,20 @@ FIRE ALARM
/obj/machinery/firealarm/examine(mob/user)
. = ..()
var/msg
switch(get_security_level())
switch(code_name_eng[security_level])
if("green")
msg = "<font color='green'><b>Green</b></font>"
msg = "<font color='green'><b>зелёный</b></font>"
to_chat(user, "Маленький индикатор указывает на [msg] уровень тревоги.")
if("blue")
msg = "<font color='blue'><b>Blue</b></font>"
msg = "<font color='blue'><b>синий</b></font>"
to_chat(user, "Маленький индикатор указывает на [msg] уровень тревоги.")
if("red")
msg = "<font color='red'><b>Red</b></font>"
msg = "<font color='red'><b>красный</b></font>"
to_chat(user, "Маленький индикатор указывает на [msg] уровень тревоги.")
if("delta")
msg = "<font color='purple'><b>Delta</b></font>"
to_chat(user, "The small light indicates [msg] security level.")
msg = "<font color='purple'><b>дельта</b></font>"
to_chat(user, "Маленький индикатор указывает об активированном коде [msg].")


/obj/machinery/firealarm/atom_init(mapload, dir, building)
. = ..()
Expand All @@ -1246,7 +1250,7 @@ FIRE ALARM

if(is_station_level(z) || is_mining_level(z))
if(security_level)
add_overlay(image('icons/obj/monitors.dmi', "overlay_[get_security_level()]"))
add_overlay(image('icons/obj/monitors.dmi', "overlay_[code_name_eng[security_level]]"))
else
add_overlay(image('icons/obj/monitors.dmi', "overlay_green"))

Expand Down
181 changes: 93 additions & 88 deletions code/game/machinery/computer/communications.dm

Large diffs are not rendered by default.

19 changes: 9 additions & 10 deletions code/game/machinery/computer/shop.dm
Original file line number Diff line number Diff line change
Expand Up @@ -37,16 +37,15 @@
var/data[0]

data["stationTime"] = worldtime2text()
var/secLevelStr
switch(get_security_level())
if("green")
secLevelStr = "<font color='green'><b>&#9899;</b></font>"
if("blue")
secLevelStr = "<font color='blue'><b>&#9899;</b></font>"
if("red")
secLevelStr = "<font color='red'><b>&#9899;</b></font>"
if("delta")
secLevelStr = "<font color='purple'><b>&Delta;</b></font>"
var/secLevelStr = code_name_eng[security_level]
if(security_level == SEC_LEVEL_GREEN)
secLevelStr = "<font color='green'><b>&#9899;</b></font>"
if(security_level == SEC_LEVEL_BLUE)
secLevelStr = "<font color='blue'><b>&#9899;</b></font>"
if(security_level == SEC_LEVEL_RED)
secLevelStr = "<font color='red'><b>&#9899;</b></font>"
if(security_level == SEC_LEVEL_DELTA)
secLevelStr = "<font color='purple'><b>&Delta;</b></font>"
data["securityLevel"] = secLevelStr

data["mode"] = mode
Expand Down
19 changes: 9 additions & 10 deletions code/game/objects/items/devices/PDA/PDA.dm
Original file line number Diff line number Diff line change
Expand Up @@ -658,16 +658,15 @@

data["stationTime"] = worldtime2text()

var/secLevelStr
switch(get_security_level())
if("green")
secLevelStr = "<font color='green'><b>&#9899;</b></font>"
if("blue")
secLevelStr = "<font color='blue'><b>&#9899;</b></font>"
if("red")
secLevelStr = "<font color='red'><b>&#9899;</b></font>"
if("delta")
secLevelStr = "<font color='purple'><b>&Delta;</b></font>"
var/secLevelStr = code_name_eng[security_level]
if(security_level == SEC_LEVEL_GREEN)
secLevelStr = "<font color='green'><b>&#9899;</b></font>"
if(security_level == SEC_LEVEL_BLUE)
secLevelStr = "<font color='blue'><b>&#9899;</b></font>"
if(security_level == SEC_LEVEL_RED)
secLevelStr = "<font color='red'><b>&#9899;</b></font>"
if(security_level == SEC_LEVEL_DELTA)
secLevelStr = "<font color='purple'><b>&Delta;</b></font>"
data["securityLevel"] = secLevelStr

data["new_Message"] = newmessage
Expand Down
2 changes: 1 addition & 1 deletion code/game/response_team/response_team.dm
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ var/global/can_call_ert
return
if(tgui_alert(usr, "Вы хотите отправить отряд быстрого реагирования?",, list("Да","Нет")) != "Да")
return
if(get_security_level() != "red") // Allow admins to reconsider if the alert level isn't Red
if(code_name_eng[security_level] != "red") // Allow admins to reconsider if the alert level isn't Red

if(tgui_alert(usr, "На станции не введён красный код. Вы всё ещё хотите отправить отряд быстрого реагирования?",, list("Да","Нет")) != "Да")
return
Expand Down
8 changes: 4 additions & 4 deletions code/modules/admin/secrets.dm
Original file line number Diff line number Diff line change
Expand Up @@ -476,16 +476,16 @@
message_admins("[key_name_admin(usr)] has triggered a battle to the death (only one)")
// Security levels
if("securitylevel0")
set_security_level(0)
set_security_level(SEC_LEVEL_GREEN)
message_admins("<span class='notice'>[key_name_admin(usr)] change security level to Green.</span>", 1)
if("securitylevel1")
set_security_level(1)
set_security_level(SEC_LEVEL_BLUE)
message_admins("<span class='notice'>[key_name_admin(usr)] change security level to Blue.</span>", 1)
if("securitylevel2")
set_security_level(2)
set_security_level(SEC_LEVEL_RED)
message_admins("<span class='notice'>[key_name_admin(usr)] change security level to Red.</span>", 1)
if("securitylevel3")
set_security_level(3)
set_security_level(SEC_LEVEL_DELTA)
message_admins("<span class='notice'>[key_name_admin(usr)] change security level to Delta.</span>", 1)
// Drop asteroid
if("drop_asteroid")
Expand Down
37 changes: 3 additions & 34 deletions code/modules/security_levels/security_levels.dm
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
/var/security_level = 0
/var/security_level = SEC_LEVEL_GREEN
/var/delta_timer_id = 0
var/global/list/code_name_eng = list("green", "blue", "red", "delta")
var/global/list/code_name_ru = list("зелёный", "синий", "красный", "дельта")

/proc/set_security_level(level)
switch(level)
Expand Down Expand Up @@ -93,36 +95,3 @@ var/global/list/quiet_alarm_areas = typecacheof(typesof(/area/station/maintenanc
else if (is_type_in_typecache(A, loud_alarm_areas))
M.playsound_local(get_turf(M), 'sound/machines/alarm_delta.ogg', VOL_EFFECTS_MASTER, null, FALSE)
return

/proc/get_security_level()
switch(security_level)
if(SEC_LEVEL_GREEN)
return "green"
if(SEC_LEVEL_BLUE)
return "blue"
if(SEC_LEVEL_RED)
return "red"
if(SEC_LEVEL_DELTA)
return "delta"

/proc/num2seclevel(num)
switch(num)
if(SEC_LEVEL_GREEN)
return "green"
if(SEC_LEVEL_BLUE)
return "blue"
if(SEC_LEVEL_RED)
return "red"
if(SEC_LEVEL_DELTA)
return "delta"

/proc/seclevel2num(seclevel)
switch( lowertext(seclevel) )
if("green")
return SEC_LEVEL_GREEN
if("blue")
return SEC_LEVEL_BLUE
if("red")
return SEC_LEVEL_RED
if("delta")
return SEC_LEVEL_DELTA

0 comments on commit ccb8f88

Please sign in to comment.