![]() |
|
||||||||||
|
|||||
|
Регистрация: Jun 2009
Сообщений: 39
|
VVall, big thanks.
Вот рабочий метод, может кому пригодиться ) public function rotate(currentAngle:Number, targetAngle:Number, body:DisplayObject):void { var angle:Number = targetAngle - body.rotation; while (angle < 0) angle += 360; while (angle > 360) angle -= 360; trace (angle); if (angle > 180) body.rotation -= currentAngle; else body.rotation += currentAngle; if (body.rotation > targetAngle - currentAngle && body.rotation < targetAngle + currentAngle) body.rotation = targetAngle; } |
![]() |
Часовой пояс GMT +4, время: 00:04. |
|
|
« Предыдущая тема | Следующая тема » |
|
|