Fixes wizards being able to cast most spells while under incapacitation. (#11194)

This commit is contained in:
Matt Atlas
2021-02-16 11:59:55 +01:00
committed by GitHub
parent 83064f96a7
commit abc0212278
2 changed files with 43 additions and 2 deletions
@@ -222,8 +222,8 @@ var/list/spells = typesof(/spell) //needed for the badmin verb for now
return 0
if(!(spell_flags & GHOSTCAST) && holder == user)
if(user.stat && !(spell_flags & STATALLOWED))
to_chat(usr, "Not when you're incapacitated.")
if(user.incapacitated(INCAPACITATION_KNOCKOUT) && !(spell_flags & STATALLOWED))
to_chat(usr, SPAN_WARNING("Not when you're incapacitated."))
return 0
if(ishuman(user) && !(invocation_type in list(SpI_EMOTE, SpI_NONE)))