Buff Shadekin Empathy

Gives you a verb called 'Adjust Empathy Range' if you have shadekin empathy that lets you set the range you want to send to.

Global - The current behavior and default, unlimited range
This Z - Only sends to people on the Z you are on
Local - Sends only to default view range
Subtle - Only adjacent

Shadekin get the verb by default, and if you obtain shadekin empathy through absorption, you also get the verb

if you have shadekin empathy by some other means, you will need to speak through shadekin empathy once to get the verb.

This way if you want to do empathy at your friend across the table and not invite every shadekin on the server to see what you're on about, now you can.
This commit is contained in:
VerySoft
2023-01-24 07:17:38 -05:00
parent 37dfa08e35
commit 030069d3bd
6 changed files with 54 additions and 1 deletions
+43
View File
@@ -0,0 +1,43 @@
mob
var/hive_lang_range = 0
mob/proc/shadekin_empathy_range()
set name = "Adjust Empathy Range"
set desc = "Changes the range you will transmit your empathy to!"
set category = "IC"
var/option = tgui_alert(src, "What range?", "Adjust empathy range", list("Global","This Z level","Local", "Subtle"))
switch(option)
if("Global")
hive_lang_range = 0
if("This Z level")
hive_lang_range = -1
if("Local")
hive_lang_range = world.view
if("Subtle")
hive_lang_range = 1
/datum/language/shadekin/broadcast(var/mob/living/speaker,var/message,var/speaker_mask)
log_say("(HIVE) [message]", speaker)
speaker.verbs |= /mob/proc/shadekin_empathy_range
if(!speaker_mask) speaker_mask = speaker.name
message = "[get_spoken_verb(message)], \"[format_message(message, get_spoken_verb(message))]\""
if(speaker.hive_lang_range == -1)
var/turf/t = get_turf(speaker)
for(var/mob/player in player_list)
var/turf/b = get_turf(player)
if (t.z == b.z)
player.hear_broadcast(src, speaker, speaker_mask, message)
else if(speaker.hive_lang_range)
var/turf/t = get_turf(speaker)
for(var/mob/player in player_list)
var/turf/b = get_turf(player)
if(get_dist(t,b) <= speaker.hive_lang_range)
player.hear_broadcast(src, speaker, speaker_mask, message)
else
for(var/mob/player in player_list)
player.hear_broadcast(src, speaker, speaker_mask, message)