Clear[]
x1[t_] := 
      t + (1/3) + (1/2)*Cos[t] + (1/6)*Cos[(Sqrt[3])*t]
x2[t_] := t + (1/3) - (1/3)*Cos[(Sqrt[3])*t]
x3[t_] := 
      t + (1/3) - (1/2)*Cos[t] + (1/6)*Cos[(Sqrt[3])*t]
Sp1[t_] := 
      Show[Graphics[{RGBColor[0, 0, 1], Thickness[0.005], 
            Line[{{-0.5 + x1[t], 0}, {x1[t], 
                  0}, {0.5 + (4/5)*x1[t] + (1/5)*x2[t], 
                  0.5}, {1 + (3/5)*x1[t] + (2/5)*x2[t], -0.5}, {1.5 + 
                    (2/5)*x1[t] + (3/5)*x2[t], 
                  0.5}, {2 + (1/5)*x1[t] + (4/5)*x2[t], -0.5}, {2.5 + 
                    x2[t], 0}, {3 + x2[t], 0}}]}, 
          PlotRange -> {{-5, 20}, {-1, 1}}, 
          AspectRatio -> Automatic], 
        DisplayFunction -> Identity]
Sp2[t_] := 
      Show[Graphics[{RGBColor[0, 0, 1], Thickness[0.005], 
            Line[{{3 + x2[t], 0}, {3.5 + x2[t], 
                  0}, {4 + (4/5)*x2[t] + (1/5)*x3[t], 
                  0.5}, {4.5 + (3/5)*x2[t] + (2/5)*x3[t], -0.5}, {5 + 
                    (2/5)*x2[t] + (3/5)*x3[t], 
                  0.5}, {5.5 + (1/5)*x2[t] + (4/5)*x3[t], -0.5}, {6 + 
                    x3[t], 0}, {6.5 + x3[t], 0}}]}, 
          PlotRange -> {{-5, 20}, {-1, 1}}, 
          AspectRatio -> Automatic], 
        DisplayFunction -> Identity]
m1[t_] := 
      Show[Graphics[{RGBColor[0, 1, 0], Disk[{-0.5 + x1[t], 0}, 0.3]}, 
          AspectRatio -> Automatic], 
        DisplayFunction -> Identity]
m2[t_] := 
      Show[Graphics[{RGBColor[0, 1, 0], Disk[{3 + x2[t], 0}, 0.3]}, 
          AspectRatio -> Automatic], 
        DisplayFunction -> Identity]
m3[t_] := 
      Show[Graphics[{RGBColor[0, 1, 0], Disk[{6.5 + x3[t], 0}, 0.3]}, 
          AspectRatio -> Automatic], 
        DisplayFunction -> Identity]
g = 
      Table[Show[Sp1[t], Sp2[t], m1[t], m2[t], m3[t], 
          DisplayFunction -> $DisplayFunction], {t, 0, 10, 
          0.1}]
Export["yaya4-3.avi", g]