缩放和旋转时,libgdx精灵会被中断

时间:2016-03-17 13:42:25

标签: libgdx rotation sprite scale scaling

我想旋转和缩放我的精灵,但它看起来有点失效: Disorted Sprite

这是我的渲染方法:

 public void renderMain(float delta){
        batch.begin();
        GameScreenShipUpdater.getTexture(yourship).setPosition(yourship.getRectangle().x, yourship.getRectangle().y);
        GameScreenShipUpdater.getTexture(yourship).setSize(25f, 10f);
        GameScreenShipUpdater.getTexture(yourship).setOriginCenter();
        GameScreenShipUpdater.getTexture(yourship).setRotation(130f);
        GameScreenShipUpdater.getTexture(yourship).draw(batch);

        batch.end();

    }

我该如何解决这个问题?这是Sprite在不旋转的情况下的外观: not rotated

0 个答案:

没有答案