Remote only works in studio, doesn't react on client ingame

The name speaks pretty much for itself.
I’ve had this issue for a little bit now and I simply cannot figure out what is causing all of it. I have searched DevForum for any answers but to no success. I’ve also tried switching remote names, switching the way the remotes trigger etc.

If you can’t watch the video:
On studio, the client reacts and prints out the information that I require. Same goes for the server. Ingame the client does not react but the server does.

The first code in the client is to print out a table, which it doesn’t do. I don’t have a “while true” script above it or anything which would loop and make it not work due to it being unreachable.

If required, I can post snippets of the code. I believe this might be a setting which I can’t find which is why I chose not to put the code on from the start.

Here is a video of the issue occouring.

1 Like

Have you made sure that the scripts are all committed, and the game has been saved & published properly?

Yes. Each time I’ve adjusted the script I’ve published it.
I don’t run in a team create where team collabration is on, so I can’t “commit” them since it does that already.

Just to be certain, it works perfectly on the client’s side inside of studio, but then in the actual the game client’s side doesn’t work?

You will need to post your code. There is literally no information to work off of other than knowing the general problem right now. In other words, we have no way of knowing how the problem is caused.

Yes. This is an issue I’ve never had problems with before.

It says it detects trainings from the trello board, it could be that http service doesn’t work properly in-game but does work normally in studio (I know this happens with discord webhooks, so it could be the same for trello)

Alright, deemed it neccessary.

The following image is an image from the client core. I have marked off a specific area which does actually work both on studio and in-game and it is actually under the remote as well which is weird considering the remote not working.

EDIT: forgot to add the server
This is how the server works;

I’m unsure about that. The way my code works is that the server picks it up and compiles the neccessary information from the card, which to then send to the client. Even if it didn’t exist, wouldn’t it still give me at least an error to indicate that the card doesn’t exist or it couldn’t reach?

How do you get the Cards to loop through? Because that’s where the information is coming from, so it could be that the error lies within where you’re getting the cards?

I use the Trello API reworked. I’ve linked it here below.

But I doubt that is it, because I check on the server if the table exists and the information given to me is correct.

It also shows this table in-game.

I think the issue you have here is probably a race condition. Basically when you use :FireAllClients() the client hasn’t connected to the .OnClientEvent event yet. Which means it won’t receive the information because it’s sent before it’s ready to recieve it.

You should probably be using :FireClient() with the same information, but when a player joins for the first time. Basically that method won’t immediately drop the information, so you shouldn’t have a race condition then. And you can use :FireAllClients() when you update the training sessions available.

1 Like