Merge pull request #5628 from Zuhayr/master

Made Vox-Pidgin and Rootspeak untranslatable even by pAIs.
This commit is contained in:
Mloc
2014-07-16 14:39:38 +01:00
5 changed files with 29 additions and 28 deletions
+5 -5
View File
@@ -34,10 +34,10 @@
speech_verb = "mrowls"
colour = "tajaran_signlang"
key = "y" //only "dfpqxyz" left.
//need to find a way to resolve possesive macros
signlang_verb = list("flicks their left ear", "flicks their right ear", "swivels their ears", "twitches their tail", "curls the end of their tail", "arches their tail", "wiggles the end of their tail", "waves their tail about", "holds up a claw", "gestures with their left hand", "gestures with their right hand", "gestures with their tail", "gestures with their ears")
flags = WHITELISTED | NONVERBAL
/datum/language/skrell
@@ -54,7 +54,7 @@
speech_verb = "shrieks"
colour = "vox"
key = "v"
flags = RESTRICTED
flags = RESTRICTED | UNTRANSLATABLE
/datum/language/diona
name = "Rootspeak"
@@ -62,7 +62,7 @@
speech_verb = "creaks and rustles"
colour = "soghun"
key = "q"
flags = RESTRICTED
flags = RESTRICTED | UNTRANSLATABLE
/datum/language/human
name = "Sol Common"
@@ -106,7 +106,7 @@
// Can we speak this language, as opposed to just understanding it?
/mob/proc/can_speak(datum/language/speaking)
return (universal_speak || speaking in src.languages)
return ((universal_speak && !(speaking.flags & UNTRANSLATABLE)) || speaking in src.languages)
//TBD
/mob/verb/check_languages()
+5 -5
View File
@@ -67,7 +67,7 @@
add_language("Sol Common", 1)
add_language("Tradeband", 1)
add_language("Gutter", 1)
//PDA
pda = new(src)
spawn(5)
@@ -81,20 +81,20 @@
..()
usr << browse_rsc('html/paigrid.png') // Go ahead and cache the interface resources as early as possible
// this function shows the information about being silenced as a pAI in the Status panel
/mob/living/silicon/pai/proc/show_silenced()
if(src.silence_time)
var/timeleft = round((silence_time - world.timeofday)/10 ,1)
stat(null, "Communications system reboot in -[(timeleft / 60) % 60]:[add_zero(num2text(timeleft % 60), 2)]")
/mob/living/silicon/pai/Stat()
..()
statpanel("Status")
if (src.client.statpanel == "Status")
show_silenced()
if (proc_holder_list.len)//Generic list for proc_holder objects.
for(var/obj/effect/proc_holder/P in proc_holder_list)
statpanel("[P.panel]","",P)
+7 -7
View File
@@ -15,7 +15,7 @@
/mob/living/silicon/say_understands(var/other,var/datum/language/speaking = null)
//These only pertain to common. Languages are handled by mob/say_understands()
if (!speaking)
if (istype(other, /mob/living/carbon/human))
if (istype(other, /mob/living/carbon))
return 1
if (istype(other, /mob/living/silicon))
return 1
@@ -60,7 +60,7 @@
return
var/verb = say_quote(message)
//parse radio key and consume it
var/message_mode = parse_message_mode(message, "general")
if (message_mode)
@@ -68,19 +68,19 @@
message = trim(copytext(message,2))
else
message = trim(copytext(message,3))
if(message_mode && bot_type == IS_ROBOT && message_mode != "binary" && !R.is_component_functioning("radio"))
src << "\red Your radio isn't functional at this time."
return
//parse language key and consume it
var/datum/language/speaking = parse_language(message)
if (speaking)
verb = speaking.speech_verb
message = copytext(message,3)
switch(message_mode)
if("department")
switch(bot_type)
+7 -7
View File
@@ -72,11 +72,11 @@
if (src.stat == 2) //Dead
return 1
//Universal speak makes everything understandable, for obvious reasons.
else if(src.universal_speak || src.universal_understand)
else if((src.universal_speak || src.universal_understand) && !(speaking.flags & UNTRANSLATABLE))
return 1
//Languages are handled after.
if (!speaking)
if(!other)
@@ -88,12 +88,12 @@
if (istype(other, src.type) || istype(src, other.type))
return 1
return 0
//Language check.
for(var/datum/language/L in src.languages)
if(speaking.name == L.name)
return 1
return 0
/mob/proc/say_quote(var/text,var/datum/language/speaking)
@@ -156,7 +156,7 @@
if(length(message) >= 2)
var/channel_prefix = copytext(message, 1 ,3)
return department_radio_keys[channel_prefix]
return null
//parses the language code (e.g. :j) from text, such as that supplied to say.
@@ -167,6 +167,6 @@
var/datum/language/L = language_keys[language_prefix]
if (can_speak(L))
return L
return null