I'm creating a buffer for player input to trigger and prioritize moves. Each button and gamepad direction is assigned a letter which is pushed to the back of an array which is limited in size to (6,1). Every tick I set an instance variable called "Moves" in the array as follows:
PlayerInput.At(0) & PlayerInput.At(1) & PlayerInput.At(2) & PlayerInput.At(3) & PlayerInput.At(4) & PlayerInput.At(5)
I now want to check that this array does NOT contain a specific set of combo inputs (e.g. "ABXY", "XYABX") which may be 4, 5 or 6 letters long, so that I can trigger lower priority non-combo moves
I have tried the following event using the "system compare two values" option:
find(PlayerInput.Moves, "ABXY") = -1 AND find(PlayerInput.Moves, "XYABX") = -1
But this doesn't seem to work. I assume the find expression returns -1 when the string is not found. Is there a better way to do this check? Any suggestions appreciated.