edits to Agent and Simulate