Holding Block While Using KeyFlip in V4

maxman

Well-known member
I am trying out v4 of OpenBOR on this. When I tried using keyflip while blocking with anim block (holdblock 1 is already assigned), I cannot press left or right to turn directions at all. I know it works well with v3, but not v4, unless I'm proven wrong.

Code:
anim block
    delay 4
    offset 128 243
    @cmd keyflip
#@cmd keyint openborconstant("ANI_FOLLOW5") 0 "D" 0 0
    frame data/chars/shaia/block00.png
    @cmd keyflip
#@cmd keyint openborconstant("ANI_FOLLOW5") 0 "D" 0 0
    frame data/chars/shaia/block00.png

C:
void keyflip()
{// Change hero's facing direction if left or right is pressed
    void self = getlocalvar("self");
    int iPIndex = getentityproperty(self,"playerindex"); //Get player index

    if (playerkeys(iPIndex, 0, "moveleft")){ // Left is pressed?
      changeentityproperty(self, "direction", 0); //Face left
    } else if (playerkeys(iPIndex, 0, "moveright")){ // Right is pressed?
      changeentityproperty(self, "direction", 1); //Face right
    }
}

How can I turn directions while pressing left/right during block?
 
Back
Top Bottom