- Home /
Which variables are usable to set my update frequency?
For the following situation, which variables can be used to set my Update() frequency?
I need a fixed Update(), which the user can set himself.
It should be possible to set the interval in ms.
My framerate shouldn't drop.
I know of adding time.deltaTime to a variable and checking that value. But that method has proven to be not completely accurate.
Answer by Eric5h5 · Jan 07, 2012 at 10:18 PM
Update runs once every frame and can't be changed in any way. You can try InvokeRepeating instead.
It's rather difficult to explain what I want to achieve exactly. I need my Update() to execute as usual, but only execute the code every 250ms (or a user defined frequency).
You're asking for conflicting things. Just use InvokeRepeating, then you can define the frequency.