Hello.
The remote event is sent from the server to the client. I am fairly certain that the remote event sends because it changes the value of News. However, it doesn’t reach the client because it doesn’t play the sound and it doesn’t print anything. No errors. Here is my code:
Server Side (Server Script in ServerScriptService):
readanim:GetMarkerReachedSignal("AddNews"):Connect(function()
readremote:FireClient(player, "hello")
news.Value += newsamount.Value -- this runs, btw
Client Side (Local Script in StarterPlayerScripts - its a sound manager and I want these sounds to be local.)
Any help would be greatly appreciated. It’s probably something pretty stupid. If you need to see the full code, please let me know. This is only a segment because the rest is irrelevant to this.
I think the animation should also be played on the client too, since animations on the server are unreliable with a NetworkOwner, much like the touched event.
It already works on the server + if I run it on the client, since the value change relies on when the animation reaches a specific point, exploiters could easily gain tonnes of value. I don’t really see any gaping issues with playing it on the server still, as it works without fault. The only part messing up is the remote event.
Alright, are you sure the client script isn’t infinitely yielding somewhere (waiting for the character)? Are you sure it isn’t being deleted by something else?
To debug this, you can try making sure that the client script is still responding by adding a loop that resumes every second and that prints.
Additionally, you can try printing player on the server.
OK, it worked now! I had a while wait(69) running in the client script, which was causing it to yield haha. It was pretty stupid, thank you for helping me find it.