-
What do you want to achieve?
I have a ViewportFrame were i want to showcase a Model. It should be in the exact Middle. -
What is the issue?
When i start the game the Model just goes to the border of the ViewportFrame.
As you can see on line 6 i am setting the CFrame of the Camera to -5,10,15 and -20,-10,0.
By Starting the Game the CFrame changes to -5,10,15 and -43.314,45,0.
-
What solutions have you tried so far?
I already searched the Internet and the DevForum but couldn’t find anything that would help me.
It should look like this:
But it looks like this:
local Player = game:GetService("Players").LocalPlayer
local Character = Player.Character or Player.CharacterAdded:Wait()
local VPF = script.Parent
local VPFcam = Instance.new("Camera")
VPFcam.Parent = VPF
VPFcam.CFrame = CFrame.new(Vector3.new(-5,10,15), Vector3.new(-20,-10,0))
VPF.CurrentCamera = VPFcam
wait(1)
local PlayerMorph = game:GetService("ReplicatedStorage").Models.HamsterMorphBig:Clone()
PlayerMorph.Parent = VPF.WorldModel
PlayerMorph:SetPrimaryPartCFrame(CFrame.new(Vector3.new(0,0,-9.5), Vector3.new(5,0,0)))