Merge pull request #4139 from Anewbe/nicknames

Adds the ability to choose nicknames
This commit is contained in:
Neerti
2017-10-23 13:37:34 -04:00
committed by GitHub
4 changed files with 23 additions and 1 deletions

View File

@@ -88,6 +88,8 @@
// Checks if the mob's own name is included inside message. Handles both first and last names.
/mob/proc/check_mentioned(var/message)
var/list/valid_names = splittext(real_name, " ") // Should output list("John", "Doe") as an example.
var/list/nicknames = splittext(nickname, " ")
valid_names += nicknames
valid_names += special_mentions()
for(var/name in valid_names)
if(findtext(message, regex("\\b[name]\\b", "i"))) // This is to stop 'ai' from triggering if someone says 'wait'.

View File

@@ -67,6 +67,7 @@
var/stuttering = null //Carbon
var/slurring = null //Carbon
var/real_name = null
var/nickname = null
var/flavor_text = ""
var/med_record = ""
var/sec_record = ""