How to tween something in Camera downwards

Hello! I am wondering how I can make the Pet Models size up when they first show up, and tween down like how the text does (in the video down below), but I am unable to figure out how to do so because if I were to do “petOneConnection:Disconnect”, then it would just stop, and go out of the camera, but since its looping then it just stays in that position, but how can I make it so it tweens with it there? If you need a better explanation I would gladly give one.

The script that makes the pets show up when it hatches

	petOneConnection = runService.RenderStepped:Connect(function()
		local lookPart = pet.PrimaryPart
		local lookPart2 = pet2.PrimaryPart
		local lookPart3 = pet3.PrimaryPart
		local cf = CFrame.new(0,0,-pet.PrimaryPart.Size.Z * 2)
		local cf2 = CFrame.new(-4,0,-pet.PrimaryPart.Size.Z * 2)
		local cf3 = CFrame.new(4,0,-pet.PrimaryPart.Size.Z * 2)
		pet:SetPrimaryPartCFrame(camera.CFrame * cf)
		pet2:SetPrimaryPartCFrame(camera.CFrame * cf2)
		pet3:SetPrimaryPartCFrame(camera.CFrame * cf3)
		lookPart.CFrame = CFrame.lookAt(lookPart.Position, camera.CFrame.Position)
		lookPart2.CFrame = CFrame.lookAt(lookPart2.Position, camera.CFrame.Position)
		lookPart3.CFrame = CFrame.lookAt(lookPart3.Position, camera.CFrame.Position)
	end)
	pet.Parent = camera
	pet2.Parent = camera
	pet3.Parent = camera


Any help will be very much appreciated! :smile:

1 Like
petOneConnection = runService.RenderStepped:Connect(function()
		local lookPart = pet.PrimaryPart
		local lookPart2 = pet2.PrimaryPart
		local lookPart3 = pet3.PrimaryPart
		local cf = CFrame.new(0,0,-pet.PrimaryPart.Size.Z * 2)
		local cf2 = CFrame.new(-4,0,-pet.PrimaryPart.Size.Z * 2)
		local cf3 = CFrame.new(4,0,-pet.PrimaryPart.Size.Z * 2)
		pet:SetPrimaryPartCFrame(camera.CFrame * cf)
		pet2:SetPrimaryPartCFrame(camera.CFrame * cf2)
		pet3:SetPrimaryPartCFrame(camera.CFrame * cf3)
		lookPart.CFrame = CFrame.lookAt(lookPart.Position, camera.CFrame.Position)
		lookPart2.CFrame = CFrame.lookAt(lookPart2.Position, camera.CFrame.Position)
		lookPart3.CFrame = CFrame.lookAt(lookPart3.Position, camera.CFrame.Position)
	end)
	pet.Parent = camera
	pet2.Parent = camera
	pet3.Parent = camera

? I am confused. What is this supposed to mean?

You tween camera, then set tween time to 1, then Camera.CFrame = Camera.CFrame + CFrame.new(0,20,0)

Can you give an example of what you mean? I was confused because all you did was copy and paste the script.

no

local tween = game:GetServide("TweenService")


What do you mean by “no”? And does that tutorial show how to do what you said?

1 Like

Ofcourse it does

Summary

This text will be hidden

1 Like

In what section of the tutorial does it show what to do?

Minute 20:17

This text will be blurred

They’re just showing how to tween a GUI? Mostly anyone can do that. In my case, I am trying to tween something in Camera?

No sorry, i got it wrong, actually minute 15:17

This text will be blurred

I need a better and specific explanation of what you are trying to do and why

Let me give a pretty brief summary of what I am trying to accomplish.

When you open the egg, the pets show up. But instead of them just showing up, the pets would be small in size, then would tween upwards, then after a few seconds after the text on the screen displaying the pets name, etcetera, the pets would also tween down. But the issue that I am having is that whenever you try and do so, the runService is making it go back to the 0,0 position, etcetera with the other pets.

Hopefully, that made it more understanding.

So I assume you don’t know how to help me?

Did you try tweening three of your pets outside the runservice loop?

Yes, they just get put back into that position because of the run service loop.

Any help will be greatly appreciated! If you know, I would love to know how to fix my issue!

What you could do (which will hopefully look similar), is to put the camera far away from the pets (so the pets look small), and then tween the camera closer (so the pets look bigger). I think this is what @NameSpookbtw tried telling you too.

None of this is what I am trying to accomplish.