iPhone 应用程序从最后一个位置旋转图像
我正在尝试创建一个动画旋转图像。这一切都很好,我正在使用 CABasicAnimation,如该线程 如何使用cocos2d 中的动画?
我的问题是我想多次旋转图像随机次数,并且我想从最后的位置旋转它。目前,我可以让图像旋转,它会在随机位置完成,但如果我尝试添加另一个旋转,它会将图像重置为其初始位置。我多年来一直在寻找解决方案,如果有人有任何提示,我将不胜感激。
我想我想复制拾取器旋转,但有一个围绕中心点旋转的二维图像 - 如果这更清楚的话!
谢谢
I am trying to create an animated spinning image. This is all fine and I am using CABasicAnimation as described in this thread how can I use animation in cocos2d?
My problem is that I want to spin the image more than once a random number of times and I want to spin it from it's last position. At the moment I can get the image to spin, it finishes in a random position but then if I try to add another spin it resets the image to its initial position. I have been searching for a solution for ages now, if anyone has any tips that would be most appreciated.
I guess I want to replicate the picker spinning but with a 2d image spinning around a central point - if that is clearer!
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
你定了
吗?
那应该让动画从上一个停止的地方继续。
Did you set
?
That SHOULD have the animation continue from where the previous one left off.