Advertisement
Guest User

Game owner only door

a guest
Jun 30th, 2016
391
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. script.Parent.Touched:connect(function(hit)
  2. local h = hit.Parent:FindFirstChild("Humanoid")
  3. if h then
  4. if h.Health > 0 then
  5. local Player = game.Players:FindFirstChild(hit.Parent.Name)
  6. if Player.UserId == game.CreatorId then
  7. script.Parent.CanCollide = false
  8. script.Parent.Transparency = .5
  9. wait(1)
  10. script.Parent.CanCollide = true
  11. script.Parent.Transparency = 0
  12. end
  13. end
  14. end
  15. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement