I'm trying to make at title system where it fires a remote event and changes the title

I’m trying to make a title system where it triggers a remote event and changes the title

I’m getting the error “Unable to assign property Text. string expected, got Instance” the error occurs on the line “rank.Text = name” in the server script

I’ve looked for solutions on the devforum and YouTube but nothing has worked

my code
image
server script ^


local script ^

1 Like

Whenever you fire a remote-event from a client that client’s player instance is the first element in the argument list that gets sent over to the server; allowing the server to know which user fired it. All other arguments that were sent from the client are subsequent to the sender (on the server side) This is a common mistake, and I urge you to read the documentation related to the client server model so you gain a better understanding of what is going on, and why things may not work as you expect them to.

Therefore you should restructure your event connection handler to be something like this…

events.changeTitle.OnServerEvent:Connect(function(player, name, color)

2 Likes

Hi, you should do what @BostonWhaler said, but you’re also dividing your RGB codes as three different arguments.

When you fire your event you should instead do.

tevent:FireServer("NOOB", Color3.fromRGB(255, 255, 0))
2 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.