NovalGamingYT

Teleport Pad

Jan 7th, 2018
763
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.69 KB | None | 0 0
  1. local Teleport = "Lentilkac58-Easy-Teleport-2" --Put the name of the Part between the ""s.
  2. function Touch(hit) --Indicates that the Part has been Touched.
  3. if script.Parent.Locked == false and script.Parent.Parent:findFirstChild(Teleport).Locked == false then script.Parent.Locked = true script.Parent.Parent:findFirstChild(Teleport).Locked = true --Checks Debounce.
  4. local Pos = script.Parent.Parent:findFirstChild(Teleport) --Gets the Part to teleport to.
  5. hit.Parent:moveTo(Pos.Position) wait(1) script.Parent.Locked = false script.Parent.Parent:findFirstChild(Teleport).Locked = false end end --Takes you there and Ends the Function.
  6. script.Parent.Touched:connect(Touch) --Listens out for Touchers.
Advertisement
Add Comment
Please, Sign In to add comment