so im making a block game ( like 3d agar ), and uh if the block thats welded to character gets too big ( like it gets big and moves up a bit to not make it go in ground ). if i dont make it move up, these camera lagspikes dont happen, but because it moves up, the camera lags or goes back or smth heres a vid for what happens ( u can notice the camera going back )
the player is a model right ? , what method do you use to increase the size of the player ?
i check through local script if touching comparing sizes then sending remote event, in server script heres the part of it that increases:
local cube = player.Character:FindFirstChild("Block")
if othercube.Humanoid.DisplayName == "Orb" then
cube.Size = cube.Size + Vector3.new(0.5,0.5,0.5)
cube.Position += Vector3.new(0,0.25,0)
else
cube.Size = cube.Size + Vector3.new(1,1,1)
cube.Position += Vector3.new(0,0.5,0)
end
try tweening it
very cool text because of the characters limit
idk how to use tweens im not used to them can u give me an example of how to use them
also u mean tween size or position or both
you may need to tween both , try tweenning the size alone if does not work then try with position , it is so easy to use tweens simply get the tweenservice local TweenService = game:GetService("TweenService")
then create a tween local Tween = TweenService:Create(the object you want to tween , tweenInfo.new(time) , {Size = thesize , Position = theposition})
and finally play it Tween:Play
im rn checking the tweenservice documentation
this is the one of the best ways to learn how to use it
ok i did the cube size tween thing there are some problems:
- the camera lag thing still happens, now i think its because of position not size tween
idk how to do position tween when i tried it didnt only tween up it also tweened sideways
@Krant19worlddv i just checked without moving position there are no camera lagspikes, but i need to move it so its above the ground