[AI/Lua] Setting behaviors as AI-compatible is buggy
The behavior data attribute ai
is expected to make scripts usable by NPC AI, but it doesn't appear to work.
I've noticed having a scores
behavior attribute, as well having a flags
data attribute randomly makes it work, but it's really not clear. It appears arbitrary, under some unclear prerequisites. It looks like some chain of events (having a scores
attribute, a ai = true
data attribute, and/or a flags
data attribute) leads to a condition being met, which finally makes a behavior AI-compatible.
Unclear because for some reason, upon undoing the changes that led to the behavior being AI-compatible, the behavior remains AI-compatible...
Really needs investigation.