Replies: 1 comment
-
This should not create high load when at 50 players, if you want smoother frametime you can spread loop into several frames private float lastUpdate;
void Update()
{
float time = Time.time;
if (time - lastUpdate < 0.1f)
return;
foreach (var client in Provider.clients)
{
if (Physics.Raycast(...))
// check components and activate ui
}
} |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I tried to implement it through UnturnedPlayerEvents.PlayerGesture.None, but as it turned out it doesn’t work like that, I thought to implement it through a timer, but I’m afraid of an extra load on the server, I will be grateful if you tell me an alternative implementation.
Beta Was this translation helpful? Give feedback.
All reactions