So basically I want it on the x axis to go 5 studs right slowly and then 5 studs left. This would be a loop any advice?
I could script this for you however, i have not seen a script of yours presented, so in this answer I will just recommend somethings you can use to do what you're asking.
~~ KingLoneCat