Where is your ServerScript located? Your issue is probably because the PlrNames
StringValue isn’t replicated, so trying to send it over turns it into nil. You parented it to the script, but depending on the script’s location it’s not replicating.
That would explain it. ServerScriptService isn’t visible to clients, so PlrNames doesn’t replicate and becomes nil when you try to send it over.
You’re not giving the StringValue
enough time to replicate on top of that. I don’t see a need for StringValue
s anyways. Just send the player’s username directly
Nope, it will never replicate because it’s not in a container that can replicate. Please read this article on the documentation: Remote Events and Callbacks | Documentation - Roblox Creator Hub
So what would I need to do? (Character Limit)
I am extremely familiar with the Roblox engine. I know it will fail to replicate. What I am saying is that in the event it would, not enough time is given to allow the instance to replicate—this is a factor to consider in the coming solution
Again, I don’t see the need to use StringValue
s here, or at least the need to send the one you created. Simply send the player’s username
So something like this?
ReplicatedStorage.JoinServers.JoinServerPlayer:FireAllClients(player.Name)
Yes. Something exactly like that
I do not see any issues with your code beyond this point. It would be easier to diagnose the issue live. Add me on Discord @ziffix
This is also wrong. When you send an instance over a remote, it will prioritize replication if it wasn’t already available on the client. It will not happen if the instance is inherently non-replicable, or if the instance is outside of the streaming radius.
Alr, I sent a friend request!!!
Workspace.StreamingEnabled
is enabled by default, hence my concern
Guys stop the beefing, we have different opinons on topics, and someone’s topics may be more correct over anothers but we do not need to ramble over and over again.
I’m awaiting further communication in DMs
The issue has been resolved. Problems included:
-
Source of username propagation failure: override of
OnServerInvoke
callback later in the script -
Source of
nil
username: additional firing ofJoinServerPlayer
event with no arguments in separate script
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.