What is better for optimizing tweens?

Hey so I was just wondering what is the best system for optimizing tweens?
Basically I am making an obby with power ups, there are a lot of them and they tween to hover up and down while rotating. I have 3 options

  1. Just tween them all constantly

  2. Run a constant loop checking for nearby powerups, only nearby ones get tweened properly. (using getpartboundsinradius from the player in a constant loop with all powerups whitelisted)

  3. Same as 2 except instead of getpartboundsinradius I just run a for i,v loop on every single powerup and do a magnitude check.

Thanks in advance!

Have a maze game that can put out at times 300+ coins, all doing a repeating tween.
Never had a problem with it. MazeMaster (if you want to check it) This is over a very large area also.

1 Like

Yeah should be fine, just make sure you’re using tags so you dont have to repeat the code to every powerup and also that the hovering is running on the client not the server.

1 Like

You could try each one, and duplicate the parts to see the results, but from my experience I would use tweens.

1 Like

Thanks @2112Jay and @StraightScared
Think I’ll just tween them and if it becomes an issue then I’ll look into optimizations.

That is the same conclusion I came to after testing. I figured I’d need something like what you were talking about. But, testing showed my frames were doing just fine. Good Luck!

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.