Basically, my spinning part is going a bit too fast and make the obby uncompletable. Is there a way i can make it more balanced for players?
What is the script inside of the part?
Its not a script, i use a localscript to help for performance and fluidity over the game preventing lag as possible for players.
why not make it spin slower like the other spinning part?
Well, can I see the localscript?
local CollectionService = game:GetService("CollectionService")
local TweenService = game:GetService("TweenService")
workspace.DescendantAdded:Connect(function(des)
local tags= des:GetTags()
for i, tag in tags do
print(i,tag)
if tag == "Spinning" then
print("own spinning")
task.spawn(function()
while true do
des.Orientation += Vector3.new(0, 10, 0)
task.wait(0.03)
end
end)
end
if tag == "SlowSpinning" then
task.spawn(function()
while true do
des.Orientation += Vector3.new(0, 5.5, 0)
task.wait(0.05)
end
end)
end
if tag == "FastSpinning" then
task.spawn(function()
while true do
des.Orientation += Vector3.new(0, 20, 0)
task.wait(0.01)
end
end)
end
if tag == "SuperFastSpinning" then
task.spawn(function()
while true do
des.Orientation += Vector3.new(0, 50, 0)
task.wait(0.001)
end
end)
end
if tag == "Fading" then
print("own fading")
task.spawn(function()
while true do
if not des then
break
end
TweenService:Create(des, TweenInfo.new(12),{Transparency = 1}):Play()
if des:FindFirstChildOfClass("Texture") then
des:FindFirstChildOfClass("Texture"):SetAttribute("OriginalTransparency",des:FindFirstChildOfClass("Texture").Transparency)
TweenService:Create(des:FindFirstChildOfClass("Texture"), TweenInfo.new(12),{Transparency = 1}):Play()
end
task.wait(12)
des.CanCollide = false
task.wait(1)
TweenService:Create(des, TweenInfo.new(10),{Transparency = 0}):Play()
if des:FindFirstChildOfClass("Texture") then
TweenService:Create(des:FindFirstChildOfClass("Texture"), TweenInfo.new(10),{Transparency = des:FindFirstChildOfClass("Texture"):GetAttribute("OriginalTransparency") }):Play()
end
task.wait(10)
des.CanCollide = true
end
end)
end
end
end)
i guess that the spinning part in the vid has the tag “SuperFastSpinning”
you are rotating the path Y axis by 50 very frequently which makes it look teleporting/lagging
most clients run Roblox at 60 fps
you are changing the Y position 60 times every second which is 50*60 rotation change every second I don’t think there can be a fix to this rather than reducing the Rotation change
try reducing it to something lower
not necessary or related to the topic but changing the rotation in a heartbeat event would be better
Have you tried reducing the Y rotation value from Vector3.new(0, 50, 0)
to something lower, like for example Vector3.new(0, 30, 0)
?
Also, consider increasing the wait time from task.wait(0.001)
to task.wait(0.05)
or higher time. This should help smooth out the rotation and reduce extreme speed.
Just decrease the task.wait to 0.1 or something. That should make it slower