# Create a function which takes a (or several) time-dependent plot(s) as input and produces a sequence of images

I want to use Wolfram Script to create a sequence of PNG images depending on some parameter (which I then turn into a movie). Currently I do this with a for loop. I would like to avoid having to write a for loop each time and instead define a function which takes one (or several) time-dependent plot(s) as an input and creates the sequence of images. Here's what I tried so far

#!/usr/bin/env wolframscript

fps=30;
durationofmovie=1;

timedependentplot[time_]=ParametricPlot[{time*s,time*s^2},{s,0,1},PlotStyle->{blue,Thickness[0.005]},Axes->None,PlotRangeClipping->False,PlotRange->{{-1,1},{-1,1}}];

CreateImageSequence[timedependentplot_]:=For[i=0,i<=fps*durationofmovie,i++,t=1/(fps*durationofmovie)*i;
Export[ToString[IntegerString[i,10,4]]<>".png",Show[timedependentplot[t]],RasterSize->{480,360}]
];

CreateImageSequence[timedependentplot];


but things don't work. That is, the resulting images are just white.

Use SetDelayed:
timedependentplot[time_] := ParametricPlot[{time*s, time*s^2}, {s, 0, 1},