Animal Renaming Fixes (#11498)

This commit is contained in:
Doxxmedearly
2021-03-20 23:32:17 -03:00
committed by GitHub
parent b5892c2d50
commit f23b903258
4 changed files with 15 additions and 7 deletions
@@ -44,11 +44,10 @@
return ..()
/mob/living/simple_animal/hostile/can_name(var/mob/living/M)
if(hostile_nameable)
return ..()
if(faction && faction == M.faction) //In case the mob had a dociler used on it
return ..()
return FALSE
if(!hostile_nameable)
to_chat(M, SPAN_WARNING("\The [src] cannot be renamed."))
return FALSE
return ..()
/mob/living/simple_animal/hostile/proc/FindTarget()
@@ -662,8 +662,9 @@ mob/living/simple_animal/bullet_act(var/obj/item/projectile/Proj)
set category = "IC"
set src in view(1)
var/mob/living/M = usr
if(!M)
var/mob/living/carbon/M = usr
if(!istype(M))
to_chat(usr, SPAN_WARNING("You aren't allowed to rename \the [src]."))
return
if(can_name(M))