We have been working on techniques to write better AI behavior for simulations and games. We are focusing on a visual authoring tool that provides a way to quickly synthesize complex behavior, and are building a corresponding AI engine to run with a simulation or game. For game development uses, we see our tool as making the AI understandable to game designers and end users, as well as improving developers' productivity. This work will also be useful for simulation developers and subsequently for analysts, operators, and instructors. We explain some of our tool's features and how the AI engine processes the resulting content.