Fixes missing comment.
Fixes bugs introduced in converting the AI module format. Also implements getTriggers().
Fixes stray $ from last commit.
Merge branch 'refactor-modules'