鱼叉作为libgdx中的痛苦游戏

时间:2016-10-31 13:31:58

标签: android libgdx

我正在使用Scene2D。 这是我的射击演员

 if(Gdx.input.justTouched() && hasdisparado == false){
        hasdisparado =true;
        touch = new Vector3(Gdx.input.getX(), Gdx.input.getY(), 0);

        stage.getCamera().unproject(touch);
        arponRegion = new TextureRegion(textureDisparo, 0, 0, 20, 40);

        actorDisparo = new ActorDisparo(world,arponRegion,new Vector2(touch.x/BolasGame.MetrosAPixels,touch.y/BolasGame.MetrosAPixels ),20/BolasGame.MetrosAPixels,40/BolasGame.MetrosAPixels,0,2f,BolasGame.USERDATA_DISPARO);
        stage.addActor(actorDisparo);
    }

这是对射击课的召唤

textureDisparo = new Texture("gfx/disparo.png");

这创造了一个像子弹一样的镜头,但是我需要,因为我触摸屏幕直到它被摧毁是连续的像游戏剧中的鱼叉

textureregion纹理的电荷,其尺寸为446x20

'Returns the postcode or #VALUE error when used as worksheet function.
'Use the 'OR alternatives if being called from within VBA - will return TRUE/FALSE on matches.
Public Function ValidatePostCode(strData As String) As String 'OR Boolean
    Dim RE As Object, REMatches As Object

    Set RE = CreateObject("vbscript.regexp")
    With RE
        .MultiLine = False
        .Global = False
        .IgnoreCase = True
        .Pattern = "^([A-PR-UWYZ0-9][A-HK-Y0-9][AEHMNPRTVXY0-9]?[ABEHMNPRVWXY0-9]? {1,2}[0-9][ABD-HJLN-UW-Z]{2}|GIR 0AA)$"
    End With

    Set REMatches = RE.Execute(strData)

    ValidatePostCode = REMatches(0) 'OR REMatches.Count > 0

End Function

我不知道怎么做,因为你必须在box2d中重复图像和身体的碰撞。 我完全失去了

如果有人能给我一个想法会很感激 谢谢 (抱歉我的英语,我现在正在学习)

0 个答案:

没有答案