z0nics Posted March 27, 2017 Share Posted March 27, 2017 Hi guys! I'm doing a 2D game with tiled map and I've run into a problem. When the group of objects (map layer and unit sprites) scaled, and camera is focused on sprite (by following with lerp), camera.view, or autoCull (or something else) gets some offset lag But all works fine with image map. You can uncomment the /* image map */ section in 'create' tab to check it out. Dont forget to comment the /* tile map */ section Just look: http://phaser.io/sandbox/edit/XNQoDGUq Buttons: LEFT ARROW - center camera on unit1 and scale group to 1.2 (if not zoomed); RIGHT ARROW - center camera on unit2 and scale group to 1.2 (if not zoomed); UP ARROW - unzoom (set group scale to 1); Spent last two days to fix this out, but have no more ideas. Link to comment Share on other sites More sharing options...
z0nics Posted March 28, 2017 Author Share Posted March 28, 2017 Fixed this with removing the .layer from groups and scale it manually. http://phaser.io/sandbox/edit/NamMcNHk Link to comment Share on other sites More sharing options...
Recommended Posts