So I have an idea for a game where there is a map filled with npc's and a few players and you can like go from controlling one npc to the next. Ive been playing around with the properties of a player but when I change the Character property it deletes the original character. How can I make it so the original one turns back into a npc and doesn't get deleted? BTW - filtering enabled is off for testing.
local Player = game.Players.LocalPlayer local Mouse = Player:GetMouse function Click() if Mouse.Target.Parent:FindFirstChild("Humanoid") then Player.Character = Mouse.Target.Parent end end Mouse.Button1Click:connect(Click)