Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local pad = script.Parent
- local characterName = "MookGingKo"
- local character = pad.Parent:WaitForChild(characterName)
- local debounce = true
- pad.Touched:Connect(function(obj)
- local plr = game.Players:GetPlayerFromCharacter(obj.Parent)
- if plr and debounce == true then
- debounce = false
- pad.BrickColor = BrickColor.new("Really red")
- local charClone = character:Clone()
- charClone.Name = plr.Name
- plr.Character = charClone
- local rootPart = charClone:FindFirstChild("HumanoidRootPart") or charClone:FindFirstChild("Torso")
- local plrRoot = obj.Parent:FindFirstChild("HumanoidRootPart") or obj.Parent:FindFirstChild("Torso")
- if rootPart and plrRoot then
- rootPart.CFrame = plrRoot.CFrame
- end
- charClone.Parent = workspace
- wait(1)
- pad.BrickColor = BrickColor.new("Lime green")
- debounce = true
- end
- end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement