Trying to optimize the map background movement since it seems really slow. Proof of concept is done, still need to clean up the code.
Fixed some glitches
Fixed more glitches
Cleaned up code
Put background draw in right place, reuse same image
Fixed lag issues by increasing the tile buffer size, and cleaning up some old code
Went back to using Kinetic.Tween since the background is one big image again
Fixed bug where the map would jump around sometimes while moving
Made the background reload less often so it doesn't reload EVERY time the player stops moving
Reduced memory problems by removing the step where an extra background image was created
Further reduced memory problems by only using one hidden canvas instead of 2
Fixed a bug where tile images would sometimes load too late in firefox. This fix also reduces the initial load time.
merged with mapoptimize
Removed unused code