Hello, I tried to make a script character change, I did it quickly. But the problem is that the local script does not react to FireClient. Everything works, the character itself changes, but I need to make the camera Subject = Humanoid. This needs to be done in a local script, but it doesn’t work.
I hope you understood me
Server script:
game.Players.PlayerAdded:Connect(function(player)
game.ReplicatedStorage.RoundStarted.Changed:Connect(function(value)
print(value) -- its works
if value then
if player.Character:FindFirstChild("Humanoid") then
print("found") -- its works
local hum = player.Character.Humanoid
player.Character = workspace.Dummy1
game.ReplicatedStorage:WaitForChild("RemoteEvent"):FireClient(player,game.Workspace.Dummy1.Humanoid)
print("fired") -- its works
end
end
end)
end)
Local script
local remoteevent = game.ReplicatedStorage:WaitForChild("RemoteEvent")
remoteevent.OnClientEvent:Connect(function(humanoid) -- this is doesn't work and there is no errors
print(humanoid) -- wont prints
game.Workspace.CurrentCamera.CameraSubject = humanoid
end)
This is how it looks
I tried to search, but found only that it was a error in studio, but this post was in 2020