Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

How to teleport to multiple items of the same name?

I have a script I made to teleport to "Item". There is multiple objects with that name and it only teleports me to one of them. I am intending to make a gui with a button to teleport to each one of these items but if I used the same exact script it would only teleport me to the same one instead of each different one. Help would be greatly appreciated

local pl = game.Players.LocalPlayer.Character.HumanoidRootPart
local location = workspace["Cock and ball torture"].Item.Part2.CFrame
local humanoid = game.Players.LocalPlayer.Character.Humanoid
humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
wait(0.1)
pl.CFrame = location

1 answer

You can use a for loop to cycle through all the parts in the workspace and check its names for the ones you're trying to teleport

This discussion is preserved as it was. New answers, comments, and votes are closed.