Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local screenGui = script.Parent
- local minimapFrame = screenGui:WaitForChild("Minimap")
- local directionArrow = minimapFrame:WaitForChild("DirectionArrow")
- local plr = game.Players.LocalPlayer
- local char = plr.Character or plr.CharacterAdded:Wait()
- local hrp = char:WaitForChild("HumanoidRootPart")
- local humanoid = char:WaitForChild("Humanoid")
- local currentCamera = Instance.new("Camera")
- currentCamera.FieldOfView = 1
- currentCamera.CameraType = Enum.CameraType.Scriptable
- currentCamera.Parent = workspace
- minimapFrame.CurrentCamera = currentCamera
- for i, minimapObject in pairs(workspace.MinimapObjects:GetChildren()) do
- minimapObject:Clone().Parent = minimapFrame
- end
- game:GetService("RunService").RenderStepped:Connect(function()
- local camCFrame = CFrame.new(hrp.Position + Vector3.new(0, 5000, 0), hrp.Position)
- currentCamera.CFrame = camCFrame
- directionArrow.Rotation = -hrp.Orientation.Y - 90
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement