Finished the AI goal allocator.