#Top down camera troubles

1 messages · Page 1 of 1 (latest)

heavy geyser
#
local TopCamera = game.Workspace.CurrentCamera

TopCamera.CameraType = "Scriptable"
--Moves Camera Position 
TopCamera.CFrame = CFrame.new(5, 5, 5)
------------------------------------------------ The problem area
**local TopCamera = game.Workspace.CurrentCamera

TopCamera.CameraType = "Scriptable"
--Moves Camera Rotation
TopCamera.CFrame.Vector3.new(0, 10, 0)**
barren mantle
#

so

heavy geyser
#

so

barren mantle
#
TopCamera.CFrame.Vector3.new(0, 10, 0)
#

this makes no sense

#

at all

#

what are you trying to do here

heavy geyser
#

im trying to make a top down camera

barren mantle
#

well you would want the camera to be above

#

and you would want the camera to point down

heavy geyser
#

yeah

barren mantle
#

is this all the same script?

#

why is it 2 copies

heavy geyser
#

yeah

#

thought it would work

barren mantle
#
TopCamera.CFrame = CFrame.lookAlong(Vector3.new(0, 10, 0), Vector3.new(0, -1, 0))
#

you can do this

heavy geyser
#

that works perfectly i just need it to follow now

#

is there a way to link the camera's cframe with the players cframe

barren mantle
#
local RunService = game:GetService("RunService")
local Players = game:GetService("Players")

local player = Players.LocalPlayer
local camera = workspace.CurrentCamera

RunService.PostSimulation:Connect(function()
  local character = player.Character
  if not character then return end

  TopCamera.CFrame = CFrame.lookAlong(character.PrimaryPart.Position + Vector3.new(0, 10, 0), Vector3.new(0, -1, 0))
end)
#

this is very basic and doesn't let you zoom in/out

heavy geyser
#

works perfectly

#

i need to take some time and learn how to script again