Updated the agent system to run in a new way.

Need to implement the process and messenger system.