Advertisement
Guest User

Flash Light

a guest
Sep 19th, 2019
349
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.92 KB | None | 0 0
  1. local mouse = game.Players.LocalPlayer:GetMouse()
  2. function Light()
  3. local player = game.Players.LocalPlayer
  4. local playerChar = player.Character
  5. local playerLight = playerChar.Torso:FindFirstChild("Light")
  6. local playerSound = playerChar.Torso:FindFirstChild("Sound")
  7. if playerLight then
  8. playerSound:Destroy()
  9. playerLight:Destroy()
  10. else
  11. light = Instance.new("SpotLight",playerChar:FindFirstChild("Torso"))
  12. light.Name = "Light"
  13. light.Range = 55 --- change to any
  14. light.Brightness = 20 --- change to any
  15. light.Shadows = true
  16. local play = Instance.new("Sound",playerChar:FindFirstChild("Torso"))
  17. play.SoundId = "http://www.roblox.com/asset/?id=276495837" --- Change to whatever sound you want.
  18. play:Play()
  19.  
  20. end
  21. end
  22.  
  23. mouse.KeyDown:connect(function(key)
  24. key = key:lower()
  25. if key == "f" then ---Change to any letter you want. ex:(a,s,d,f,g,h,j,y,q,e,r,y,u,i,o,z,c,v,b,n,n,m,)
  26. Light()
  27. end
  28. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement