How to loop a pattern node?

Hi Guys!

Im trying make a scene in unreal where curtains make wave-like movements. But i cant make this moviment looping. Can someone help me?

you might need a tileable texture for that. and pan in a direction that tiles.