예제 #1
0
  @Override
  public void start(CCNode aTarget) {
    super.start(aTarget);

    startPosition.set(target.getPositionRef());
    delta.set(endPosition.x - startPosition.x, endPosition.y - startPosition.y);
  }
예제 #2
0
  @Override
  public void start(CCNode aTarget) {
    super.start(aTarget);
    _start_angle = _target.rotation();
    if (_start_angle > 0) _start_angle = (float) (_start_angle % 360.0f);
    else _start_angle = (float) (_start_angle % -360.0f);

    _angle -= _start_angle;
    if (_angle > 180) _angle = -360 + _angle;
    if (_angle < -180) _angle = 360 + _angle;
  }