Merge pull request #42586 from 4dplanner/antimagic

Antimagic works again
This commit is contained in:
Jordan Brown
2019-01-30 11:33:48 -05:00
committed by GitHub
+3 -3
View File
@@ -33,12 +33,12 @@
UnregisterSignal(user, COMSIG_MOB_RECEIVE_MAGIC)
/datum/component/anti_magic/proc/protect(datum/source, mob/user, _magic, _holy, major, self, list/protection_sources)
if(((_magic && magic) || (_holy && holy)) && (self && blocks_self))
if(((_magic && magic) || (_holy && holy)) && (!self || blocks_self))
protection_sources += parent
reaction.Invoke(user, major)
reaction?.Invoke(user, major)
if(major)
charges--
if(charges <= 0)
expire.Invoke(user)
expire?.Invoke(user)
return COMPONENT_BLOCK_MAGIC