Hello why implementation of motion (MoveTo, etc) use time for increment transition?
If distance is long speed is high for finish in duration
if distance is short spedd is low for finish in same duration.
Why use duration for increment and not distance ?_? and when start position = end position stop motion? :D
why MoveTo and another Action use Duration for increment?
(4 posts) (3 voices)-
Posted 2 years ago #
-
do you know if for this problem i need use Speed class?
Posted 2 years ago # -
Are you asking for the reasoning why cocos2D is a time based approach?
Are you trying to speed up the characters movements?
I'm not quite sure if the question is about a specific problem you want fixed or just a discussion about why cocos2d was planned with a certain approach.
Posted 2 years ago # -
Sounds like you want your objects to travel at constant speed with variable times? I am not sure if cocos has anything to let you define speed instead of duration. It looks like the speed class only allows you to modify the rate of the action, and not set a speed.
You can always get the distance between the two points and divide it by your specified speed to get the duration that you want.
Posted 2 years ago #
Reply
You must log in to post.