Converts antimagic from GetComponent to a signal
This commit is contained in:
@@ -689,6 +689,16 @@
|
||||
mob_spell_list -= S
|
||||
qdel(S)
|
||||
|
||||
/mob/proc/anti_magic_check(magic = TRUE, holy = FALSE)
|
||||
if(!magic && !holy)
|
||||
return
|
||||
var/list/protection_sources = list()
|
||||
if(SEND_SIGNAL(src, COMSIG_MOB_RECEIVE_MAGIC, magic, holy, protection_sources) & COMPONENT_BLOCK_MAGIC)
|
||||
if(protection_sources.len)
|
||||
return pick(protection_sources)
|
||||
else
|
||||
return src
|
||||
|
||||
//You can buckle on mobs if you're next to them since most are dense
|
||||
/mob/buckle_mob(mob/living/M, force = FALSE, check_loc = TRUE)
|
||||
if(M.buckled)
|
||||
|
||||
Reference in New Issue
Block a user