The character is asymmetrical so I have to use separate animations for left or right rather than using mirroring, and I also have it set up so that when you press a particular attack key, the resulting attack animation is different depending on your current animation.
To easily manage this I figured I could use a 3D Array. X lists each possible animation, Y lists the normal or attacking variant parallel to each other, and the Z determines whether it is the left or right version of the animation.
I've never actually used an array before though, and the process is very complex.
I've already stored all the animations in the array, but I need to know how I can set it up so that an event will read the X of an array when the key is pressed, and once it finds the one that's currently playing it'll activate the animation directly beneath it on the Y axis.
It would also decide which Z axis to search through based on the direction the player is facing (which I've stored as a variable).
Say the player is facing right and playing the animation stored on (X2,Y0,Z1), it would search through Z1 until it finds X2, then play the animation stored on (X2,Y1,Z1).