mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-28 07:38:05 +01:00
Simple animal emotes work again. Fixed #4963
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
//Things like airguitar can be done without arms, and the flap thing makes so little sense it's a keeper.
|
||||
//Intended to be called by a higher up emote proc if the requested emote isn't in the custom emotes.
|
||||
|
||||
/mob/living/emote(var/act,var/m_type=1,var/message = null)
|
||||
/mob/living/emote(var/act, var/m_type=1, var/message = null)
|
||||
var/param = null
|
||||
|
||||
if (findtext(act, "-", 1, null))
|
||||
|
||||
@@ -134,23 +134,23 @@
|
||||
else
|
||||
randomValue -= speak.len
|
||||
if(emote_see && randomValue <= emote_see.len)
|
||||
emote(pick(emote_see),1)
|
||||
emote("me", 1, pick(emote_see))
|
||||
else
|
||||
emote(pick(emote_hear),2)
|
||||
emote("me", 2, pick(emote_see))
|
||||
else
|
||||
say(pick(speak))
|
||||
else
|
||||
if(!(emote_hear && emote_hear.len) && (emote_see && emote_see.len))
|
||||
emote(pick(emote_see),1)
|
||||
emote("me", 1, pick(emote_see))
|
||||
if((emote_hear && emote_hear.len) && !(emote_see && emote_see.len))
|
||||
emote(pick(emote_hear),2)
|
||||
emote("me", 2, pick(emote_see))
|
||||
if((emote_hear && emote_hear.len) && (emote_see && emote_see.len))
|
||||
var/length = emote_hear.len + emote_see.len
|
||||
var/pick = rand(1,length)
|
||||
if(pick <= emote_see.len)
|
||||
emote(pick(emote_see),1)
|
||||
emote("me", 1, pick(emote_see))
|
||||
else
|
||||
emote(pick(emote_hear),2)
|
||||
emote("me", 2, pick(emote_see))
|
||||
|
||||
|
||||
//Atmos
|
||||
@@ -243,14 +243,13 @@
|
||||
return "[emote], \"[text]\""
|
||||
return "says, \"[text]\"";
|
||||
|
||||
/mob/living/simple_animal/emote(var/act)
|
||||
/mob/living/simple_animal/emote(var/act, var/m_type=1, var/message = null)
|
||||
if(stat)
|
||||
return
|
||||
if(act == "scream")
|
||||
act = "makes a loud and pained whimper" //ugly hack to stop animals screaming when crushed :P
|
||||
visible_message("<B>[src]</B> [act].")
|
||||
return
|
||||
..(act)
|
||||
message = "makes a loud and pained whimper" //ugly hack to stop animals screaming when crushed :P
|
||||
act = "me"
|
||||
..(act, m_type, message)
|
||||
|
||||
/mob/living/simple_animal/attack_animal(mob/living/simple_animal/M as mob)
|
||||
if(M.melee_damage_upper == 0)
|
||||
|
||||
@@ -22,10 +22,7 @@
|
||||
|
||||
message = trim(copytext(sanitize(message), 1, MAX_MESSAGE_LEN))
|
||||
|
||||
if(ishuman(src) || isrobot(src))
|
||||
usr.emote("me",1,message)
|
||||
else
|
||||
usr.emote(message)
|
||||
usr.emote("me",1,message)
|
||||
|
||||
/mob/proc/say_dead(var/message)
|
||||
var/name = src.real_name
|
||||
|
||||
Reference in New Issue
Block a user