I’m trying to make a game and I can’t figure out how to move objects around. The Stage will have something like 10 objects (MC’s). When I click on an object it’s selected, then if I click in a specific point (another MC), this selected object should move to that point.
A fast transition is very easy, but I’d like to make the object moving smooth. For one object I can do something like:
object._x += (destiny._x-object._x)/speed;
object._y += (destiny._y-object._y)/speed;
In this Way, the object move very smooth! But this code should be placed in an enterFrame event. The problem start when I have 10 objects on the stage, I guess I can’t configure the enterFrame for every one of them or else the movie will be very CPU intensive.
Is there a way to enable/disable the enterFrame event of the movie clips? Or is there a better solution for this problem?
Thanks
(my apologies about my english)