Removed handmade Math.sign method and replaced them with built-in js library functions. (map.js)