I am able to create a comet that moves based on the (x,y) points in an array. While moving it leaves a trail to give the comet like effect.
My problem is that, I have to set my var motionTrailLength
with a big value, (=200) and my var animationTime
to (=3000), so the trail does not disappear halfway. I am attempting to shorten the var motionTrailLength
to 20 and var animationTime
to 1000.
The comet should move through the defined array point withouts breaking halfway. I do not have an idea why this happens and I have check the code many times. I think my logic is wrong, so I need your help.
Can someone please help check the code here and help me know whats wrong? Appreciate it very much.
Aucun commentaire:
Enregistrer un commentaire