added new Agent code and a test function to main
Merge pull request #4 from ordrin/dev_eric

added new Agent code and a test function to main