Frame cloning by amount of players in game

Thank you SO much for all the help! :smile:

It works completely now, again, thank you!!

Actually, it seems that there are still some problems. When I spectate Player2 on Player1, it doesn’t do anything, I believe. But when I “spectate” Player1 on Player1, it makes Player2 spectate Player1. Not sure why is this happening.

LocalScript:

SpectateEvent.OnClientEvent:Connect(function(value, targetPlayer)
	if value == false then
		Camera.CameraSubject = targetPlayer.Character:WaitForChild("Head")
	elseif value == true then
		Camera.CameraSubject = player.Character:WaitForChild("Head")
	end
end)

ServerScript

                if DEBOUNCE == false then
					DEBOUNCE = true
					Spectating.Text = "SPECTATING: "..targetPlayer.Name
					SpectateEvent:FireClient(player, false, targetPlayer)
				elseif DEBOUNCE == true then
					Spectating.Text = "SPECTATING: N/A"
					SpectateEvent:FireClient(player, true, targetPlayer)
					DEBOUNCE = false
				end

I think it might be an issue in the ServerScript, maybe somewhere in the :FireClient() values. Not sure what to fix tho.

Alright, I have managed to fix this issue.

Alongside other, kinda heavy rework, the SpectateEvent fire has to be SpectateEvent:FireClient(v, targetPlayer), and not how it was before.

Thanks for all of the other help tho! :smiley:

1 Like

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