przemoo83 Posted June 25, 2015 Report Share Posted June 25, 2015 HiCan please somebody take a look at this code?http://phaser.io/sandbox/VkHvBKKRhttp://phaser.io/sandbox/VkHvBKKR/playI want to achieve the effect when I draw a solid line no matter how fast I draw. At the moment when I draw fast only couple of dots appear. Any idea how to fix that? Quote Link to comment Share on other sites More sharing options...
Tom Atom Posted June 25, 2015 Report Share Posted June 25, 2015 Hi, for solid line, you will have to record previous position and draw line from it to your current position. Then save current position as previous for next frame. Without this you will never get continuous curve as update runs for example 60 frames per second, but if you move 180 pixels in second then you will get only every third... Quote Link to comment Share on other sites More sharing options...
przemoo83 Posted June 26, 2015 Author Report Share Posted June 26, 2015 I think I get the idea. Now I just have to think how to code it. Thanks for pointing me in the right direction Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.