Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local RS = game:GetService("ReplicatedStorage");
- local TS = game:GetService("TweenService");
- local RunService = game:GetService("RunService");
- local Trash: RBXScriptSignal;
- local Camera = game.Workspace.CurrentCamera;
- local Info = TweenInfo.new(1, Enum.EasingStyle.Sine)
- RS.Death.OnClientEvent:Connect(function(Statement)
- local Player = game.Players.LocalPlayer
- local Character: Model = Player.Character or Player.CharacterAdded:Wait();
- local Head = Character.Head;
- local Mouse: Mouse = Player:GetMouse();
- coroutine.wrap(function()
- Trash = RunService.RenderStepped:Connect(function()
- if not Statement then return end
- task.wait(1);
- TS:Create(Camera, Info, {CFrame = CFrame.new(Camera.CFrame.Position, Vector3.new(Mouse.Hit.X - 2, -Mouse.Hit.Y, Mouse.Hit.Z - 2))}):Play()
- end)
- end)()
- if Statement then
- Camera.CameraType = Enum.CameraType.Scriptable;
- TS:Create(Camera, Info, {CFrame = Camera.CFrame * CFrame.new(0,100,0)}):Play();
- else
- Camera.CameraType = Enum.CameraType.Custom;
- Camera.CFrame = Head.CFrame
- end
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement