Add map drawing, fix bugs. Not optimized