Refactoring in a more Angular.js fashion maneer
Added old code
Cleanup
Refactoring of merging and moving tiles logic
Cleanup