This is the script in a local inside the playerscripts:
local StarterGui = game:GetService("StarterGui")
lantern=game.Players.LocalPlayer.Character:FindFirstChild("Lantern")
lantern.RemoteEvent.OnClientEvent:Connect(function()
print(game.Players.LocalPlayer.Character)
game.Workspace.CurrentCamera.CameraSubject=game.Players.LocalPlayer.Character
StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, true)
end)
and here is the server script inside the tool:
fire=game.ServerStorage.Tools.Lantern.LanternFire:Clone()
fire:PivotTo(Emitter.Parent.WorldCFrame)
fire.Parent=workspace
script.Parent.RemoteEvent:FireClient(player)
pchar=player.Character
player.Character=fire
pchar.Parent=workspace