Hi
I need a random move of more or less 20 objects.
My idea is something like this :
First I am drawing objects and then in the enterFrame function :
for i = 1, #dots do
if (dots[i].x % 2 == 0 ) then
dots[i].x = dots[i].x + 2
else
dots[i].x = dots[i].x - 2
end
end
The same I am doing for y .
I understand that is not perfectly good.
Do you have any better idea for random movement… ? , maybe is someone good in JavaScript :
This is very good site with scripts…
http://www.motionscript.com/mastering-expressions/random-1.html
random motion - more chaotic will be just perfect.
[import]uid: 13156 topic_id: 18310 reply_id: 318310[/import]
[import]uid: 52491 topic_id: 18310 reply_id: 70285[/import]