Advertisement
StoryProductions

Invisible Script [Roblox]

Aug 11th, 2020
731
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. local userInputService = game:GetService("UserInputService")
  2.  
  3. local character = script.Parent
  4. local humanoid = character:WaitForChild("Humanoid")
  5.  
  6. local debounce = false
  7. userInputService.InputBegan:Connect(function(input, gameProcessed)
  8. if gameProcessed then return end
  9. -- Exit if chatting or typing in a TextBox
  10. if input.KeyCode == Enum.KeyCode.F and humanoid.Health > 0 then
  11. if not debounce then
  12. debounce = true
  13. print("Activate Invisiblity")
  14. game.ReplicatedStorage.InvisibleAbility:InvokeServer()
  15. debounce = false
  16. end
  17. end
  18. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement