Merging corrected, only one value-group my be merged per action. Implemented shifting for all directions now.