RyanDaCoder

kill auyra

Jul 3rd, 2018
172
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.67 KB | None | 0 0
  1. mainRemotes = game.ReplicatedStorage
  2. meleeRemote = mainRemotes['meleeEvent']
  3.  
  4. killAura = true
  5.  
  6. contextactionservice = game.ContextActionService
  7.  
  8. function toggleKillAura(actionName, inputState, inputObject)
  9. print('Doing the action : ' .. actionName)
  10. if inputState == Enum.UserInputState.Begin then
  11. if killAura == true then
  12. killAura = false
  13. else
  14. killAura = true
  15. end
  16. end
  17. end
  18.  
  19. contextactionservice:BindAction('ToggleKillAura', toggleKillAura, false, Enum.KeyCode.K)
  20.  
  21. while wait() do
  22. if killAura == true then
  23. for _, plr in pairs (game:GetService('Players'):GetChildren()) do
  24. if plr.Name ~= game.Players.LocalPlayer.Name then
  25. meleeRemote:FireServer(plr)
  26. end
  27. end
  28. end
  29. end
Add Comment
Please, Sign In to add comment