I’m making something like when Player A clicked Player B’s body, a Gui appears in Player A and a text say Player B’s Name… However, I met a problem. It says “unable to cast value to object”
ClickD.MouseClick:Connect(function(wasclicked)
print(wasclicked) --print who clicked
REGETUI2:FireClient(ClickD:FindFirstChildWhichIsA("StringValue").Name)
end)
ClickD is the ClickDetector
REGETUI2 is the Remote Event
StringValue is the name of the player who was clicked
Anytime! I recommend marking my post as the solution if it helped you so others will easily know the issue if they stumble upon it too! If you have any more issues don’t be afraid to make another post!