Advertisement
ManOhMan

Untitled

Jun 21st, 2019
131
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. -- This script has been converted to FE by iPxter
  2.  
  3.  
  4. if game:GetService("RunService"):IsClient() then error("Script must be server-side in order to work; use h/ and not hl/") end
  5. local Player,Mouse,mouse,UserInputService,ContextActionService = owner
  6. do
  7. print("FE Compatibility code by Mokiros | Translated to FE by iPxter")
  8. script.Parent = Player.Character
  9.  
  10. --RemoteEvent for communicating
  11. local Event = Instance.new("RemoteEvent")
  12. Event.Name = "UserInput_Event"
  13.  
  14. --Fake event to make stuff like Mouse.KeyDown work
  15. local function fakeEvent()
  16. local t = {_fakeEvent=true,Connect=function(self,f)self.Function=f end}
  17. t.connect = t.Connect
  18. return t
  19. end
  20.  
  21. --Creating fake input objects with fake variables
  22. local m = {Target=nil,Hit=CFrame.new(),KeyUp=fakeEvent(),KeyDown=fakeEvent(),Button1Up=fakeEvent(),Button1Down=fakeEvent()}
  23. local UIS = {InputBegan=fakeEvent(),InputEnded=fakeEvent()}
  24. local CAS = {Actions={},BindAction=function(self,name,fun,touch,...)
  25. CAS.Actions[name] = fun and {Name=name,Function=fun,Keys={...}} or nil
  26. end}
  27. --Merged 2 functions into one by checking amount of arguments
  28. CAS.UnbindAction = CAS.BindAction
  29.  
  30. --This function will trigger the events that have been :Connect()'ed
  31. local function te(self,ev,...)
  32. local t = m[ev]
  33. if t and t._fakeEvent and t.Function then
  34. t.Function(...)
  35. end
  36. end
  37. m.TrigEvent = te
  38. UIS.TrigEvent = te
  39.  
  40. Event.OnServerEvent:Connect(function(plr,io)
  41. if plr~=Player then return end
  42. if io.isMouse then
  43. m.Target = io.Target
  44. m.Hit = io.Hit
  45. else
  46. local b = io.UserInputState == Enum.UserInputState.Begin
  47. if io.UserInputType == Enum.UserInputType.MouseButton1 then
  48. return m:TrigEvent(b and "Button1Down" or "Button1Up")
  49. end
  50. for _,t in pairs(CAS.Actions) do
  51. for _,k in pairs(t.Keys) do
  52. if k==io.KeyCode then
  53. t.Function(t.Name,io.UserInputState,io)
  54. end
  55. end
  56. end
  57. m:TrigEvent(b and "KeyDown" or "KeyUp",io.KeyCode.Name:lower())
  58. UIS:TrigEvent(b and "InputBegan" or "InputEnded",io,false)
  59. end
  60. end)
  61. Event.Parent = NLS([==[
  62. local Player = owner
  63. local Event = script:WaitForChild("UserInput_Event")
  64.  
  65. local UIS = game:GetService("UserInputService")
  66. local input = function(io,a)
  67. if a then return end
  68. --Since InputObject is a client-side instance, we create and pass table instead
  69. Event:FireServer({KeyCode=io.KeyCode,UserInputType=io.UserInputType,UserInputState=io.UserInputState})
  70. end
  71. UIS.InputBegan:Connect(input)
  72. UIS.InputEnded:Connect(input)
  73.  
  74. local h,t
  75. --Give the server mouse data 30 times every second, but only if the values changed
  76. --If player is not moving their mouse, client won't fire events
  77. while wait(1/30) do
  78. if h~=Mouse.Hit or t~=Mouse.Target then
  79. h,t=Mouse.Hit,Mouse.Target
  80. Event:FireServer({isMouse=true,Target=t,Hit=h})
  81. end
  82. end]==],Player.Character)
  83. Mouse,mouse,UserInputService,ContextActionService = m,m,UIS,CAS
  84. end
  85. plyr = owner
  86. char = plyr.Character
  87. torso = char.Torso
  88. head = char.Head
  89. Run = game:service'RunService'
  90. sizeCu = 2
  91. local MODE = "Lime green"
  92. coroutine.wrap(function()
  93. while true do
  94. coroutine.wrap(function()
  95. local charge = Instance.new("Part", char)
  96. charge.FormFactor = "Custom"
  97. charge.TopSurface = 0
  98. charge.BottomSurface = 0
  99. charge.Transparency = 0.4
  100. charge.BrickColor = BrickColor.new(MODE)
  101. charge.Anchored = true
  102. charge.CanCollide = false
  103. charge.Size = Vector3.new(sizeCu, sizeCu, sizeCu)
  104. charge.CFrame = head.CFrame * CFrame.new(0, 5.8, 0) * CFrame.Angles(math.random(-2, 2), math.random(-2, 2), math.random(-2, 2))
  105. wait()
  106. for tra = 0.4, 1, 0.1 do
  107. charge.Transparency = tra
  108. wait()
  109. end
  110. charge:Destroy()
  111. end)()
  112. wait(0.06)
  113. end
  114. end)()
  115.  
  116. happy = {"yay", "good", "like", "come here", "yolo", "swag", "win","nice","xD" ,"lol","yus","yes","omg", "ogm", "umg", "thnx", "thx", "thanz", "thanx", "thank you", "thank yoo", "rofl", "hax" , "Z0mg", "hackz" , "hack","impossible","boss","epix","epic", "awesome"} --is THat Good, yes
  117. anger = {"narb","bad","shut up", "noob", "get off","stop", "hate", "ugly", "bish","no", "idiot", "stfu", "gtfo" ,"fk y", "troll", "mad","angry"}
  118. sad = {"sad","why?", "D:"}
  119. plyr.Chatted:connect(function(msg)
  120. if msg:lower():match(string.lower("AFK")) or msg:upper():match(string.upper("AFK")) then
  121. MODE = "Br. yellowish orange"
  122. end
  123.  
  124. for i, t in pairs(happy) do
  125. if msg:lower():match(string.lower(t)) or msg:upper():match(string.upper(t)) then
  126. MODE = "Lime green"
  127. end
  128. end
  129. for f, h in pairs(sad) do
  130. if msg:lower():match(string.lower(h)) or msg:upper():match(string.upper(h)) then
  131. MODE = "Royal purple" ---Make it Purple
  132. end
  133. end
  134. for v, k in pairs(anger) do
  135. if msg:lower():match(string.lower(k)) or msg:upper():match(string.upper(k)) then
  136. MODE = "Really red"
  137. end
  138. end
  139. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement