#Adding values in runtime causes jitter

1 messages · Page 1 of 1 (latest)

ancient python
#

I have this rotation speed in time that I want to update in code, but when I do it, it seems to cause a big jitter as the value changes. I assume this is caused by how the calculation changes, is there a way to fix this at all?

#

one thing im thinking i could do is store the value of the rotation in code and just increment it there

#

but im wondering if there's a way i can just fix this in code

dapper elbow
hallow gust
#

Yeah, it's impossible to adjust the rotation speed smoothly if you aren't remembering the current rotation

#

Your shader doesn't remember the rotation from frame to frame

#

It just multiplies the current time by _RotateSpeed

#

I've solved this by creating my own time property, as Spazi suggested

#

so rather than changing the multiplier, you change how quickly time advances in the first place

ancient python
hallow gust
#

yep!

#

there are...ways to store state in a shader

#

they're very evil :p

#

(and they are 100% not needed if you can just write a script)