So I find myself in an interesting situation.
I wrote up a basic camera controller that ties a function to frame rate that handles updating the camera’s CFrame for animation (changes its CFrame to move left/right.)
Now, I noticed when I played on 120hz, the script activity spiked up pretty significantly. It got up around 3-4%. On 60hz, it was normal. And ultimately, the activity spike would grow the larger FPS I would set the game to run at.
I don’t really know if it’s a problem or not. It makes sense, as obviously the function will be executing twice as much. But I don’t know if that translates to performance loss. I’ve always heard 2-3% activity is the sweet spot.
But in regards to the logic I’m using, it should be fine? Literally all I do is update the CFrame of the model and change it. I noticed using PivotTo
got quite hefty in terms of %, so I am now just setting the part’s CFrame directly.
What I ended up doing was capping the heartbeat to run at <= 60 times a second. A weird solution, because then the issue was trying to clamp the deltatime from the previous frame. (in the scenario the host machine is running above 60hz)
Weird situation. The logic is not expensive at all, I find it weird how the script activity spikes quite significantly.
Thanks for any insight.