added support for all directions