adding action parsing
slight change to syntax to make more flexible and added more options