Aside from the fact that if you send an event every X seconds in every script, you’ll totally screw up your network and probably your players will be kicked off the server for network overflow sooner or later, it’s a total non sense. I can see doing this with an important resource that protects some things on client (like AC resource) and client side controls, but putting it in everything is absolutely a bad use case.

The solution for your problem is to have those heartbeat files in one file, and then put the shared file in the manifest using ‘@script-name/pathtofile’ in each script. That’s better than copying same code across all resources. Another better solution is to check the number of resourcers on the server and client. But there you run into the problem that some resources are server_only and the client doesn’t know about them, so you would have to read the fxmanifests using GetResourceMetadata.

Anyway, when you have delayed events and an overloaded server because dozens of players are sending 200 events to your server every 10 seconds, don’t be surprised.

1 Like