Ad
Still have questions? Join our Discord server and get real time help.
Log in to vote
0

[SOLVED BY ME] Attempt to concatenate Instance with string? (in a normal script, remoteevent script)

Asked by 2 months ago
Edited 2 months ago

Please encode Lua code in the Lua block code tag (look for the Lua icon in the editor).

Please help with this

Code:

game.ReplicatedStorage.AdminPanelEvents.RankPromotion.OnServerEvent:Connect(function(PlayerToGiveRankTo, Reason, Rank)
    print(PlayerToGiveRankTo.."'s has been promoted to "..Rank.."!")
    game.Players:FindFirstChild(PlayerToGiveRankTo).leaderstats.Rank.Value = Rank
end)

the error is on the line "game.Players:FindFirstChild(PlayerToGiveRankTo).leaderstats.Rank.Value = Rank"

0
don't try to concatenate the variable BRO_ITmeYO 121 — 2mo
0
what do you mean? Philipceo90 13 — 2mo
0
Can you put your script in a code block? rabbi99 520 — 2mo
0
in a block? Philipceo90 13 — 2mo
View all comments (3 more)
0
whats the error Philipceo90 13 — 2mo
0
someone can please help fix this Philipceo90 13 — 2mo
0
Because your using the player isntance. Use PlayerToGiveRankTo.Name mybituploads 304 — 2mo

Answer this question