If your gif has really only 4 frames then The system based on my post would be
FRAME1 opacity 1
FRAME4 opacity 0
FRAME2 opacity 1
FRAME1 opacity 0
FRAME3 opacity 1
FRAME2 opacity 0
FRAME4 opacity 1
FRAME3 opacity 0
Sorry I am on phone no so I better not write the whole code to not make typo.
But your code should be looping too … you just need to write the code for opacity 0 right… you have at every overly name an extra zero example:
ITA FRAME3 0 opacity 0 in 0