Thank you very much. It worked perfectly.
--- In [email protected], "brucexs" <[EMAIL PROTECTED]> wrote: > > --- In [email protected], "Ed Bronson" <edbro9@> wrote: > > > > I have a couple of scripts that use the old float plugin. I am not the > > author of the scripts and I don't know much scripting. Can somebody > > please tell me how to convert the following script so that it doesn't > > rely on the float plugin that is no longer provided? I would greatly > > appreciate it. > > > > Exec.volumeall ("-5") > > Local VolSteps = 34 > > Local VolUnit = > > Float.Truncate(Float.Add(Float.Mul(Float.Divide(Volume, > > 255),VolSteps), "0.5")) > > > Something like > Local VolUnit = ftos( (volume/255.0) * VolSteps + 0.5) > > The .0 on the 255 is important -- it makes the division into floating > point instead of integer. >
